From 1eb6adf47579e3c56b38ba6cce7676e8d2d5beb0 Mon Sep 17 00:00:00 2001 From: Eduardo Broto Date: Mon, 18 May 2020 21:03:37 +0200 Subject: Adapt `cargo dev new_lint` to create tests for cargo lints --- clippy_dev/src/new_lint.rs | 178 ++++++++++++++++++++++++++------------------- 1 file changed, 105 insertions(+), 73 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/new_lint.rs b/clippy_dev/src/new_lint.rs index 44b2a5383d2..843beaf3238 100644 --- a/clippy_dev/src/new_lint.rs +++ b/clippy_dev/src/new_lint.rs @@ -1,91 +1,110 @@ use crate::clippy_project_root; -use std::fs::{File, OpenOptions}; -use std::io; +use std::fs::{self, OpenOptions}; use std::io::prelude::*; -use std::io::ErrorKind; -use std::path::Path; +use std::io::{self, ErrorKind}; +use std::path::{Path, PathBuf}; + +struct LintData<'a> { + pass: &'a str, + name: &'a str, + category: &'a str, + project_root: PathBuf, +} + +trait Context { + fn context>(self, text: C) -> Self; +} -/// Creates files required to implement and test a new lint and runs `update_lints`. +impl Context for io::Result { + fn context>(self, text: C) -> Self { + match self { + Err(e) => { + let message = format!("{}: {}", text.as_ref(), e); + Err(io::Error::new(ErrorKind::Other, message)) + }, + ok => ok, + } + } +} + +/// Creates the files required to implement and test a new lint and runs `update_lints`. /// /// # Errors /// -/// This function errors, if the files couldn't be created -pub fn create(pass: Option<&str>, lint_name: Option<&str>, category: Option<&str>) -> Result<(), io::Error> { - let pass = pass.expect("`pass` argument is validated by clap"); - let lint_name = lint_name.expect("`name` argument is validated by clap"); - let category = category.expect("`category` argument is validated by clap"); - - match open_files(lint_name) { - Ok((mut test_file, mut lint_file)) => { - let (pass_type, pass_lifetimes, pass_import, context_import) = match pass { - "early" => ("EarlyLintPass", "", "use rustc_ast::ast::*;", "EarlyContext"), - "late" => ("LateLintPass", "<'_, '_>", "use rustc_hir::*;", "LateContext"), - _ => { - unreachable!("`pass_type` should only ever be `early` or `late`!"); - }, - }; - - let camel_case_name = to_camel_case(lint_name); - - if let Err(e) = test_file.write_all(get_test_file_contents(lint_name).as_bytes()) { - return Err(io::Error::new( - ErrorKind::Other, - format!("Could not write to test file: {}", e), - )); - }; - - if let Err(e) = lint_file.write_all( - get_lint_file_contents( - pass_type, - pass_lifetimes, - lint_name, - &camel_case_name, - category, - pass_import, - context_import, - ) - .as_bytes(), - ) { - return Err(io::Error::new( - ErrorKind::Other, - format!("Could not write to lint file: {}", e), - )); - } - Ok(()) +/// This function errors out if the files couldn't be created or written to. +pub fn create(pass: Option<&str>, lint_name: Option<&str>, category: Option<&str>) -> io::Result<()> { + let lint = LintData { + pass: pass.expect("`pass` argument is validated by clap"), + name: lint_name.expect("`name` argument is validated by clap"), + category: category.expect("`category` argument is validated by clap"), + project_root: clippy_project_root(), + }; + + create_lint(&lint).context("Unable to create lint implementation")?; + create_test(&lint).context("Unable to create a test for the new lint") +} + +fn create_lint(lint: &LintData) -> io::Result<()> { + let (pass_type, pass_lifetimes, pass_import, context_import) = match lint.pass { + "early" => ("EarlyLintPass", "", "use rustc_ast::ast::*;", "EarlyContext"), + "late" => ("LateLintPass", "<'_, '_>", "use rustc_hir::*;", "LateContext"), + _ => { + unreachable!("`pass_type` should only ever be `early` or `late`!"); }, - Err(e) => Err(io::Error::new( - ErrorKind::Other, - format!("Unable to create lint: {}", e), - )), - } + }; + + let camel_case_name = to_camel_case(lint.name); + let lint_contents = get_lint_file_contents( + pass_type, + pass_lifetimes, + lint.name, + &camel_case_name, + lint.category, + pass_import, + context_import, + ); + + let lint_path = format!("clippy_lints/src/{}.rs", lint.name); + write_file(lint.project_root.join(&lint_path), lint_contents.as_bytes()) } -fn open_files(lint_name: &str) -> Result<(File, File), io::Error> { - let project_root = clippy_project_root(); +fn create_test(lint: &LintData) -> io::Result<()> { + fn create_project_layout>(lint_name: &str, location: P, case: &str, hint: &str) -> io::Result<()> { + let mut path = location.into().join(case); + fs::create_dir(&path)?; + write_file(path.join("Cargo.toml"), get_manifest_contents(lint_name, hint))?; - let test_file_path = project_root.join("tests").join("ui").join(format!("{}.rs", lint_name)); - let lint_file_path = project_root - .join("clippy_lints") - .join("src") - .join(format!("{}.rs", lint_name)); + path.push("src"); + fs::create_dir(&path)?; + write_file(path.join("main.rs"), get_test_file_contents(lint_name))?; - if Path::new(&test_file_path).exists() { - return Err(io::Error::new( - ErrorKind::AlreadyExists, - format!("test file {:?} already exists", test_file_path), - )); + Ok(()) } - if Path::new(&lint_file_path).exists() { - return Err(io::Error::new( - ErrorKind::AlreadyExists, - format!("lint file {:?} already exists", lint_file_path), - )); + + if lint.category == "cargo" { + let relative_test_dir = format!("tests/ui-cargo/{}", lint.name); + let test_dir = lint.project_root.join(relative_test_dir); + fs::create_dir(&test_dir)?; + + create_project_layout(lint.name, &test_dir, "fail", "Content that triggers the lint goes here")?; + create_project_layout(lint.name, &test_dir, "pass", "This file should not trigger the lint") + } else { + let test_path = format!("tests/ui/{}.rs", lint.name); + let test_contents = get_test_file_contents(lint.name); + write_file(lint.project_root.join(test_path), test_contents) } +} - let test_file = OpenOptions::new().write(true).create_new(true).open(test_file_path)?; - let lint_file = OpenOptions::new().write(true).create_new(true).open(lint_file_path)?; +fn write_file, C: AsRef<[u8]>>(path: P, contents: C) -> io::Result<()> { + fn inner(path: &Path, contents: &[u8]) -> io::Result<()> { + OpenOptions::new() + .write(true) + .create_new(true) + .open(path)? + .write_all(contents) + } - Ok((test_file, lint_file)) + inner(path.as_ref(), contents.as_ref()).context(format!("writing to file: {}", path.as_ref().display())) } fn to_camel_case(name: &str) -> String { @@ -112,6 +131,19 @@ fn main() {{ ) } +fn get_manifest_contents(lint_name: &str, hint: &str) -> String { + format!( + r#" +# {} + +[package] +name = "{}" +version = "0.1.0" +"#, + hint, lint_name + ) +} + fn get_lint_file_contents( pass_type: &str, pass_lifetimes: &str, -- cgit 1.4.1-3-g733a5 From 7ff71199df911b462800cf6bda7ac32879ba7eb1 Mon Sep 17 00:00:00 2001 From: Eduardo Broto Date: Thu, 21 May 2020 14:46:04 +0200 Subject: Address comments from PR review --- clippy_dev/src/new_lint.rs | 1 + tests/compile-test.rs | 4 ++-- tests/ui-cargo/cargo_common_metadata/fail/Cargo.toml | 1 + tests/ui-cargo/cargo_common_metadata/pass/Cargo.toml | 1 + tests/ui-cargo/multiple_crate_versions/fail/Cargo.toml | 1 + tests/ui-cargo/multiple_crate_versions/pass/Cargo.toml | 1 + tests/ui-cargo/wildcard_dependencies/fail/Cargo.toml | 1 + tests/ui-cargo/wildcard_dependencies/pass/Cargo.toml | 1 + 8 files changed, 9 insertions(+), 2 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/new_lint.rs b/clippy_dev/src/new_lint.rs index 843beaf3238..80713ab569f 100644 --- a/clippy_dev/src/new_lint.rs +++ b/clippy_dev/src/new_lint.rs @@ -139,6 +139,7 @@ fn get_manifest_contents(lint_name: &str, hint: &str) -> String { [package] name = "{}" version = "0.1.0" +publish = false "#, hint, lint_name ) diff --git a/tests/compile-test.rs b/tests/compile-test.rs index 91b9c73c9d4..232b966f69a 100644 --- a/tests/compile-test.rs +++ b/tests/compile-test.rs @@ -147,7 +147,7 @@ fn run_ui_toml(config: &mut compiletest::Config) { Ok(true) => {}, Ok(false) => panic!("Some tests failed"), Err(e) => { - println!("I/O failure during tests: {:?}", e); + panic!("I/O failure during tests: {:?}", e); }, } } @@ -223,7 +223,7 @@ fn run_ui_cargo(config: &mut compiletest::Config) { Ok(true) => {}, Ok(false) => panic!("Some tests failed"), Err(e) => { - println!("I/O failure during tests: {:?}", e); + panic!("I/O failure during tests: {:?}", e); }, } } diff --git a/tests/ui-cargo/cargo_common_metadata/fail/Cargo.toml b/tests/ui-cargo/cargo_common_metadata/fail/Cargo.toml index 8346bf05778..c64adcf7c01 100644 --- a/tests/ui-cargo/cargo_common_metadata/fail/Cargo.toml +++ b/tests/ui-cargo/cargo_common_metadata/fail/Cargo.toml @@ -1,3 +1,4 @@ [package] name = "cargo_common_metadata" version = "0.1.0" +publish = false diff --git a/tests/ui-cargo/cargo_common_metadata/pass/Cargo.toml b/tests/ui-cargo/cargo_common_metadata/pass/Cargo.toml index f99c126fabf..c8233f328bb 100644 --- a/tests/ui-cargo/cargo_common_metadata/pass/Cargo.toml +++ b/tests/ui-cargo/cargo_common_metadata/pass/Cargo.toml @@ -1,6 +1,7 @@ [package] name = "cargo_common_metadata" version = "0.1.0" +publish = false authors = ["Random person from the Internet "] description = "A test package for the cargo_common_metadata lint" repository = "https://github.com/someone/cargo_common_metadata" diff --git a/tests/ui-cargo/multiple_crate_versions/fail/Cargo.toml b/tests/ui-cargo/multiple_crate_versions/fail/Cargo.toml index 05ffde839dc..3a94b723f3f 100644 --- a/tests/ui-cargo/multiple_crate_versions/fail/Cargo.toml +++ b/tests/ui-cargo/multiple_crate_versions/fail/Cargo.toml @@ -1,6 +1,7 @@ [package] name = "multiple_crate_versions" version = "0.1.0" +publish = false [dependencies] ctrlc = "=3.1.0" diff --git a/tests/ui-cargo/multiple_crate_versions/pass/Cargo.toml b/tests/ui-cargo/multiple_crate_versions/pass/Cargo.toml index cad32b9233f..a9b06420b33 100644 --- a/tests/ui-cargo/multiple_crate_versions/pass/Cargo.toml +++ b/tests/ui-cargo/multiple_crate_versions/pass/Cargo.toml @@ -1,6 +1,7 @@ [package] name = "cargo_common_metadata" version = "0.1.0" +publish = false [dependencies] regex = "1.3.7" diff --git a/tests/ui-cargo/wildcard_dependencies/fail/Cargo.toml b/tests/ui-cargo/wildcard_dependencies/fail/Cargo.toml index 9558dd68091..fd2a3414856 100644 --- a/tests/ui-cargo/wildcard_dependencies/fail/Cargo.toml +++ b/tests/ui-cargo/wildcard_dependencies/fail/Cargo.toml @@ -1,6 +1,7 @@ [package] name = "wildcard_dependencies" version = "0.1.0" +publish = false [dependencies] regex = "*" diff --git a/tests/ui-cargo/wildcard_dependencies/pass/Cargo.toml b/tests/ui-cargo/wildcard_dependencies/pass/Cargo.toml index 062e441622a..38cb139146e 100644 --- a/tests/ui-cargo/wildcard_dependencies/pass/Cargo.toml +++ b/tests/ui-cargo/wildcard_dependencies/pass/Cargo.toml @@ -1,6 +1,7 @@ [package] name = "wildcard_dependencies" version = "0.1.0" +publish = false [dependencies] regex = "1" -- cgit 1.4.1-3-g733a5 From 1a04686fc0d2752de8731c833ab67bfae6136720 Mon Sep 17 00:00:00 2001 From: Eduardo Broto Date: Thu, 21 May 2020 14:47:13 +0200 Subject: Avoid triggering match_wildcard_for_single_variants --- clippy_dev/src/new_lint.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/new_lint.rs b/clippy_dev/src/new_lint.rs index 80713ab569f..08a2e0c0918 100644 --- a/clippy_dev/src/new_lint.rs +++ b/clippy_dev/src/new_lint.rs @@ -18,11 +18,11 @@ trait Context { impl Context for io::Result { fn context>(self, text: C) -> Self { match self { + Ok(t) => Ok(t), Err(e) => { let message = format!("{}: {}", text.as_ref(), e); Err(io::Error::new(ErrorKind::Other, message)) }, - ok => ok, } } } -- cgit 1.4.1-3-g733a5 From cff5cff2f3a6687dfaf12b92762e70545e0abefe Mon Sep 17 00:00:00 2001 From: Eduardo Broto Date: Fri, 22 May 2020 22:30:28 +0200 Subject: Make the name of the crate available in cargo UI tests --- clippy_dev/src/new_lint.rs | 17 ++++++++++++----- tests/ui-cargo/cargo_common_metadata/fail/src/main.rs | 1 + tests/ui-cargo/cargo_common_metadata/pass/src/main.rs | 1 + tests/ui-cargo/multiple_crate_versions/fail/src/main.rs | 1 + tests/ui-cargo/multiple_crate_versions/pass/src/main.rs | 1 + tests/ui-cargo/wildcard_dependencies/fail/src/main.rs | 1 + tests/ui-cargo/wildcard_dependencies/pass/src/main.rs | 1 + 7 files changed, 18 insertions(+), 5 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/new_lint.rs b/clippy_dev/src/new_lint.rs index 08a2e0c0918..c0b2dac2f60 100644 --- a/clippy_dev/src/new_lint.rs +++ b/clippy_dev/src/new_lint.rs @@ -76,7 +76,8 @@ fn create_test(lint: &LintData) -> io::Result<()> { path.push("src"); fs::create_dir(&path)?; - write_file(path.join("main.rs"), get_test_file_contents(lint_name))?; + let header = format!("// compile-flags: --crate-name={}", lint_name); + write_file(path.join("main.rs"), get_test_file_contents(lint_name, Some(&header)))?; Ok(()) } @@ -90,7 +91,7 @@ fn create_test(lint: &LintData) -> io::Result<()> { create_project_layout(lint.name, &test_dir, "pass", "This file should not trigger the lint") } else { let test_path = format!("tests/ui/{}.rs", lint.name); - let test_contents = get_test_file_contents(lint.name); + let test_contents = get_test_file_contents(lint.name, None); write_file(lint.project_root.join(test_path), test_contents) } } @@ -119,8 +120,8 @@ fn to_camel_case(name: &str) -> String { .collect() } -fn get_test_file_contents(lint_name: &str) -> String { - format!( +fn get_test_file_contents(lint_name: &str, header_commands: Option<&str>) -> String { + let mut contents = format!( "#![warn(clippy::{})] fn main() {{ @@ -128,7 +129,13 @@ fn main() {{ }} ", lint_name - ) + ); + + if let Some(header) = header_commands { + contents = format!("{}\n{}", header, contents); + } + + contents } fn get_manifest_contents(lint_name: &str, hint: &str) -> String { diff --git a/tests/ui-cargo/cargo_common_metadata/fail/src/main.rs b/tests/ui-cargo/cargo_common_metadata/fail/src/main.rs index c67166fc4b0..27841e18aa9 100644 --- a/tests/ui-cargo/cargo_common_metadata/fail/src/main.rs +++ b/tests/ui-cargo/cargo_common_metadata/fail/src/main.rs @@ -1,3 +1,4 @@ +// compile-flags: --crate-name=cargo_common_metadata #![warn(clippy::cargo_common_metadata)] fn main() {} diff --git a/tests/ui-cargo/cargo_common_metadata/pass/src/main.rs b/tests/ui-cargo/cargo_common_metadata/pass/src/main.rs index c67166fc4b0..27841e18aa9 100644 --- a/tests/ui-cargo/cargo_common_metadata/pass/src/main.rs +++ b/tests/ui-cargo/cargo_common_metadata/pass/src/main.rs @@ -1,3 +1,4 @@ +// compile-flags: --crate-name=cargo_common_metadata #![warn(clippy::cargo_common_metadata)] fn main() {} diff --git a/tests/ui-cargo/multiple_crate_versions/fail/src/main.rs b/tests/ui-cargo/multiple_crate_versions/fail/src/main.rs index 4bc61dd6299..1b2d3ec9459 100644 --- a/tests/ui-cargo/multiple_crate_versions/fail/src/main.rs +++ b/tests/ui-cargo/multiple_crate_versions/fail/src/main.rs @@ -1,3 +1,4 @@ +// compile-flags: --crate-name=multiple_crate_versions #![warn(clippy::multiple_crate_versions)] fn main() {} diff --git a/tests/ui-cargo/multiple_crate_versions/pass/src/main.rs b/tests/ui-cargo/multiple_crate_versions/pass/src/main.rs index 4bc61dd6299..1b2d3ec9459 100644 --- a/tests/ui-cargo/multiple_crate_versions/pass/src/main.rs +++ b/tests/ui-cargo/multiple_crate_versions/pass/src/main.rs @@ -1,3 +1,4 @@ +// compile-flags: --crate-name=multiple_crate_versions #![warn(clippy::multiple_crate_versions)] fn main() {} diff --git a/tests/ui-cargo/wildcard_dependencies/fail/src/main.rs b/tests/ui-cargo/wildcard_dependencies/fail/src/main.rs index 3491ccb0d47..581babfeacb 100644 --- a/tests/ui-cargo/wildcard_dependencies/fail/src/main.rs +++ b/tests/ui-cargo/wildcard_dependencies/fail/src/main.rs @@ -1,3 +1,4 @@ +// compile-flags: --crate-name=wildcard_dependencies #![warn(clippy::wildcard_dependencies)] fn main() {} diff --git a/tests/ui-cargo/wildcard_dependencies/pass/src/main.rs b/tests/ui-cargo/wildcard_dependencies/pass/src/main.rs index 3491ccb0d47..581babfeacb 100644 --- a/tests/ui-cargo/wildcard_dependencies/pass/src/main.rs +++ b/tests/ui-cargo/wildcard_dependencies/pass/src/main.rs @@ -1,3 +1,4 @@ +// compile-flags: --crate-name=wildcard_dependencies #![warn(clippy::wildcard_dependencies)] fn main() {} -- cgit 1.4.1-3-g733a5 From 7b490903809ce5c03c83869357a68e88f8cc0799 Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Wed, 27 May 2020 14:08:31 +0200 Subject: clippy_dev: add ra_setup This takes an absolute path to a rustc repo and adds path-dependencies that point towards the respective rustc subcrates into the Cargo.tomls of the clippy and clippy_lints crate. This allows rustc-analyzer to show proper type annotations etc on rustc-internals inside the clippy repo. Usage: cargo dev ra-setup /absolute/path/to/rust/ cc https://github.com/rust-analyzer/rust-analyzer/issues/3517 cc https://github.com/rust-lang/rust-clippy/issues/5514 --- clippy_dev/src/lib.rs | 3 +- clippy_dev/src/main.rs | 16 ++++++++- clippy_dev/src/ra_setup.rs | 90 ++++++++++++++++++++++++++++++++++++++++++++++ 3 files changed, 107 insertions(+), 2 deletions(-) create mode 100644 clippy_dev/src/ra_setup.rs (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lib.rs b/clippy_dev/src/lib.rs index 6fdd282c684..5baa31d5cde 100644 --- a/clippy_dev/src/lib.rs +++ b/clippy_dev/src/lib.rs @@ -11,6 +11,7 @@ use walkdir::WalkDir; pub mod fmt; pub mod new_lint; +pub mod ra_setup; pub mod stderr_length_check; pub mod update_lints; @@ -400,7 +401,7 @@ fn test_replace_region_no_changes() { changed: false, new_lines: "123\n456\n789".to_string(), }; - let result = replace_region_in_text(text, r#"^\s*123$"#, r#"^\s*456"#, false, || vec![]); + let result = replace_region_in_text(text, r#"^\s*123$"#, r#"^\s*456"#, false, Vec::new); assert_eq!(expected, result); } diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index d99235f7c07..281037ae37c 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -1,7 +1,7 @@ #![cfg_attr(feature = "deny-warnings", deny(warnings))] use clap::{App, Arg, SubCommand}; -use clippy_dev::{fmt, new_lint, stderr_length_check, update_lints}; +use clippy_dev::{fmt, new_lint, ra_setup, stderr_length_check, update_lints}; fn main() { let matches = App::new("Clippy developer tooling") @@ -87,6 +87,19 @@ fn main() { SubCommand::with_name("limit_stderr_length") .about("Ensures that stderr files do not grow longer than a certain amount of lines."), ) + .subcommand( + SubCommand::with_name("ra-setup") + .about("Alter dependencies so rust-analyzer can find rustc internals") + .arg( + Arg::with_name("rustc-repo-path") + .long("repo-path") + .short("r") + .help("The path to a rustc repo that will be used for setting the dependencies") + .takes_value(true) + .value_name("path") + .required(true), + ), + ) .get_matches(); match matches.subcommand() { @@ -115,6 +128,7 @@ fn main() { ("limit_stderr_length", _) => { stderr_length_check::check(); }, + ("ra-setup", Some(matches)) => ra_setup::run(matches.value_of("rustc-repo-path")), _ => {}, } } diff --git a/clippy_dev/src/ra_setup.rs b/clippy_dev/src/ra_setup.rs new file mode 100644 index 00000000000..8617445c8a6 --- /dev/null +++ b/clippy_dev/src/ra_setup.rs @@ -0,0 +1,90 @@ +#![allow(clippy::filter_map)] + +use std::fs; +use std::fs::File; +use std::io::prelude::*; +use std::path::PathBuf; + +// This module takes an absolute path to a rustc repo and alters the dependencies to point towards +// the respective rustc subcrates instead of using extern crate xyz. +// This allows rust analyzer to analyze rustc internals and show proper information inside clippy +// code. See https://github.com/rust-analyzer/rust-analyzer/issues/3517 and https://github.com/rust-lang/rust-clippy/issues/5514 for details + +pub fn run(rustc_path: Option<&str>) { + // we can unwrap here because the arg is required here + let rustc_path = PathBuf::from(rustc_path.unwrap()); + assert!(rustc_path.is_dir(), "path is not a directory"); + let rustc_source_basedir = rustc_path.join("src"); + assert!( + rustc_source_basedir.is_dir(), + "are you sure the path leads to a rustc repo?" + ); + + let clippy_root_manifest = fs::read_to_string("Cargo.toml").expect("failed to read ./Cargo.toml"); + let clippy_root_lib_rs = fs::read_to_string("src/driver.rs").expect("failed to read ./src/driver.rs"); + inject_deps_into_manifest( + &rustc_source_basedir, + "Cargo.toml", + &clippy_root_manifest, + &clippy_root_lib_rs, + ) + .expect("Failed to inject deps into ./Cargo.toml"); + + let clippy_lints_manifest = + fs::read_to_string("clippy_lints/Cargo.toml").expect("failed to read ./clippy_lints/Cargo.toml"); + let clippy_lints_lib_rs = + fs::read_to_string("clippy_lints/src/lib.rs").expect("failed to read ./clippy_lints/src/lib.rs"); + inject_deps_into_manifest( + &rustc_source_basedir, + "clippy_lints/Cargo.toml", + &clippy_lints_manifest, + &clippy_lints_lib_rs, + ) + .expect("Failed to inject deps into ./clippy_lints/Cargo.toml"); +} + +fn inject_deps_into_manifest( + rustc_source_dir: &PathBuf, + manifest_path: &str, + cargo_toml: &str, + lib_rs: &str, +) -> std::io::Result<()> { + let extern_crates = lib_rs + .lines() + // get the deps + .filter(|line| line.starts_with("extern crate")) + // we have something like "extern crate foo;", we only care about the "foo" + // ↓ ↓ + // extern crate rustc_middle; + .map(|s| &s[13..(s.len() - 1)]); + + let new_deps = extern_crates.map(|dep| { + // format the dependencies that are going to be put inside the Cargo.toml + format!( + "{dep} = {{ path = \"{source_path}/lib{dep}\" }}\n", + dep = dep, + source_path = rustc_source_dir.display() + ) + }); + + // format a new [dependencies]-block with the new deps we need to inject + let mut all_deps = String::from("[dependencies]\n"); + new_deps.for_each(|dep_line| { + all_deps.push_str(&dep_line); + }); + + // replace "[dependencies]" with + // [dependencies] + // dep1 = { path = ... } + // dep2 = { path = ... } + // etc + let new_manifest = cargo_toml.replacen("[dependencies]\n", &all_deps, 1); + + // println!("{}", new_manifest); + let mut file = File::create(manifest_path)?; + file.write_all(new_manifest.as_bytes())?; + + println!("Dependency paths injected: {}", manifest_path); + + Ok(()) +} -- cgit 1.4.1-3-g733a5 From c325c120c21657acb1b131ded41261889e51a62b Mon Sep 17 00:00:00 2001 From: Eduardo Broto Date: Fri, 5 Jun 2020 22:30:14 +0200 Subject: Fix cargo ui tests when running inside rust repo --- clippy_dev/src/new_lint.rs | 2 ++ tests/compile-test.rs | 4 ---- tests/ui-cargo/cargo_common_metadata/fail/Cargo.toml | 2 ++ tests/ui-cargo/cargo_common_metadata/pass/Cargo.toml | 2 ++ .../ui-cargo/multiple_crate_versions/5041_allow_dev_build/Cargo.toml | 2 ++ tests/ui-cargo/multiple_crate_versions/fail/Cargo.toml | 2 ++ tests/ui-cargo/multiple_crate_versions/pass/Cargo.toml | 2 ++ tests/ui-cargo/wildcard_dependencies/fail/Cargo.toml | 2 ++ tests/ui-cargo/wildcard_dependencies/pass/Cargo.toml | 2 ++ 9 files changed, 16 insertions(+), 4 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/new_lint.rs b/clippy_dev/src/new_lint.rs index c0b2dac2f60..1e032a7bc20 100644 --- a/clippy_dev/src/new_lint.rs +++ b/clippy_dev/src/new_lint.rs @@ -147,6 +147,8 @@ fn get_manifest_contents(lint_name: &str, hint: &str) -> String { name = "{}" version = "0.1.0" publish = false + +[workspace] "#, hint, lint_name ) diff --git a/tests/compile-test.rs b/tests/compile-test.rs index 194354b291f..11b3f69a828 100644 --- a/tests/compile-test.rs +++ b/tests/compile-test.rs @@ -220,10 +220,6 @@ fn run_ui_cargo(config: &mut compiletest::Config) { Ok(result) } - if cargo::is_rustc_test_suite() { - return; - } - config.mode = TestMode::Ui; config.src_base = Path::new("tests").join("ui-cargo").canonicalize().unwrap(); diff --git a/tests/ui-cargo/cargo_common_metadata/fail/Cargo.toml b/tests/ui-cargo/cargo_common_metadata/fail/Cargo.toml index c64adcf7c01..ae0a6032996 100644 --- a/tests/ui-cargo/cargo_common_metadata/fail/Cargo.toml +++ b/tests/ui-cargo/cargo_common_metadata/fail/Cargo.toml @@ -2,3 +2,5 @@ name = "cargo_common_metadata" version = "0.1.0" publish = false + +[workspace] diff --git a/tests/ui-cargo/cargo_common_metadata/pass/Cargo.toml b/tests/ui-cargo/cargo_common_metadata/pass/Cargo.toml index c8233f328bb..737e84e963c 100644 --- a/tests/ui-cargo/cargo_common_metadata/pass/Cargo.toml +++ b/tests/ui-cargo/cargo_common_metadata/pass/Cargo.toml @@ -9,3 +9,5 @@ readme = "README.md" license = "MIT OR Apache-2.0" keywords = ["metadata", "lint", "clippy"] categories = ["development-tools::testing"] + +[workspace] diff --git a/tests/ui-cargo/multiple_crate_versions/5041_allow_dev_build/Cargo.toml b/tests/ui-cargo/multiple_crate_versions/5041_allow_dev_build/Cargo.toml index 72731fbc75d..278bebbbd9e 100644 --- a/tests/ui-cargo/multiple_crate_versions/5041_allow_dev_build/Cargo.toml +++ b/tests/ui-cargo/multiple_crate_versions/5041_allow_dev_build/Cargo.toml @@ -5,6 +5,8 @@ name = "multiple_crate_versions" version = "0.1.0" publish = false +[workspace] + # One of the versions of winapi is only a dev dependency: allowed [dependencies] ctrlc = "=3.1.0" diff --git a/tests/ui-cargo/multiple_crate_versions/fail/Cargo.toml b/tests/ui-cargo/multiple_crate_versions/fail/Cargo.toml index 3a94b723f3f..4f97b011334 100644 --- a/tests/ui-cargo/multiple_crate_versions/fail/Cargo.toml +++ b/tests/ui-cargo/multiple_crate_versions/fail/Cargo.toml @@ -3,6 +3,8 @@ name = "multiple_crate_versions" version = "0.1.0" publish = false +[workspace] + [dependencies] ctrlc = "=3.1.0" ansi_term = "=0.11.0" diff --git a/tests/ui-cargo/multiple_crate_versions/pass/Cargo.toml b/tests/ui-cargo/multiple_crate_versions/pass/Cargo.toml index a9b06420b33..b4b49bb369a 100644 --- a/tests/ui-cargo/multiple_crate_versions/pass/Cargo.toml +++ b/tests/ui-cargo/multiple_crate_versions/pass/Cargo.toml @@ -3,6 +3,8 @@ name = "cargo_common_metadata" version = "0.1.0" publish = false +[workspace] + [dependencies] regex = "1.3.7" serde = "1.0.110" diff --git a/tests/ui-cargo/wildcard_dependencies/fail/Cargo.toml b/tests/ui-cargo/wildcard_dependencies/fail/Cargo.toml index fd2a3414856..3e1a02cbb3c 100644 --- a/tests/ui-cargo/wildcard_dependencies/fail/Cargo.toml +++ b/tests/ui-cargo/wildcard_dependencies/fail/Cargo.toml @@ -3,5 +3,7 @@ name = "wildcard_dependencies" version = "0.1.0" publish = false +[workspace] + [dependencies] regex = "*" diff --git a/tests/ui-cargo/wildcard_dependencies/pass/Cargo.toml b/tests/ui-cargo/wildcard_dependencies/pass/Cargo.toml index 38cb139146e..f844cab09ba 100644 --- a/tests/ui-cargo/wildcard_dependencies/pass/Cargo.toml +++ b/tests/ui-cargo/wildcard_dependencies/pass/Cargo.toml @@ -3,5 +3,7 @@ name = "wildcard_dependencies" version = "0.1.0" publish = false +[workspace] + [dependencies] regex = "1" -- cgit 1.4.1-3-g733a5 From 6af969379e766bf85652196c04ff267edf5cace7 Mon Sep 17 00:00:00 2001 From: Dmitry Murzin Date: Sun, 9 Aug 2020 22:21:09 +0500 Subject: Prevent compile parts of rustc when using `cargo dev ra-setup` --- clippy_dev/src/ra_setup.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/ra_setup.rs b/clippy_dev/src/ra_setup.rs index 8617445c8a6..f2bd651ab25 100644 --- a/clippy_dev/src/ra_setup.rs +++ b/clippy_dev/src/ra_setup.rs @@ -68,10 +68,11 @@ fn inject_deps_into_manifest( }); // format a new [dependencies]-block with the new deps we need to inject - let mut all_deps = String::from("[dependencies]\n"); + let mut all_deps = String::from("[target.'cfg(NOT_A_PLATFORM)'.dependencies]\n"); new_deps.for_each(|dep_line| { all_deps.push_str(&dep_line); }); + all_deps.push_str("\n[dependencies]\n"); // replace "[dependencies]" with // [dependencies] -- cgit 1.4.1-3-g733a5 From 6dd65b8e6a548071b19507826c53bf9a7c36b323 Mon Sep 17 00:00:00 2001 From: Eduardo Broto Date: Thu, 20 Aug 2020 23:47:04 +0200 Subject: Fix cargo dev new_lint for late lint passes --- .github/workflows/clippy.yml | 7 +++++++ clippy_dev/src/new_lint.rs | 2 +- 2 files changed, 8 insertions(+), 1 deletion(-) (limited to 'clippy_dev/src') diff --git a/.github/workflows/clippy.yml b/.github/workflows/clippy.yml index 5fa8009a8b4..99e371631b1 100644 --- a/.github/workflows/clippy.yml +++ b/.github/workflows/clippy.yml @@ -92,6 +92,13 @@ jobs: env: OS: ${{ runner.os }} + - name: Test cargo dev new lint + run: | + cargo dev new_lint --name new_early_pass --pass early + cargo dev new_lint --name new_late_pass --pass late + cargo check + git reset --hard HEAD + # Cleanup - name: Run cargo-cache --autoclean run: | diff --git a/clippy_dev/src/new_lint.rs b/clippy_dev/src/new_lint.rs index 1e032a7bc20..d951ca0e630 100644 --- a/clippy_dev/src/new_lint.rs +++ b/clippy_dev/src/new_lint.rs @@ -47,7 +47,7 @@ pub fn create(pass: Option<&str>, lint_name: Option<&str>, category: Option<&str fn create_lint(lint: &LintData) -> io::Result<()> { let (pass_type, pass_lifetimes, pass_import, context_import) = match lint.pass { "early" => ("EarlyLintPass", "", "use rustc_ast::ast::*;", "EarlyContext"), - "late" => ("LateLintPass", "<'_, '_>", "use rustc_hir::*;", "LateContext"), + "late" => ("LateLintPass", "<'_>", "use rustc_hir::*;", "LateContext"), _ => { unreachable!("`pass_type` should only ever be `early` or `late`!"); }, -- cgit 1.4.1-3-g733a5 From 46b164313288c4b5454ccdaa5ebee2412855f0fd Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Wed, 9 Sep 2020 11:57:30 +0200 Subject: update cargo dev ra-setup to changed rustc source paths --- clippy_dev/src/ra_setup.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/ra_setup.rs b/clippy_dev/src/ra_setup.rs index f2bd651ab25..c67efc10f15 100644 --- a/clippy_dev/src/ra_setup.rs +++ b/clippy_dev/src/ra_setup.rs @@ -14,7 +14,7 @@ pub fn run(rustc_path: Option<&str>) { // we can unwrap here because the arg is required here let rustc_path = PathBuf::from(rustc_path.unwrap()); assert!(rustc_path.is_dir(), "path is not a directory"); - let rustc_source_basedir = rustc_path.join("src"); + let rustc_source_basedir = rustc_path.join("compiler"); assert!( rustc_source_basedir.is_dir(), "are you sure the path leads to a rustc repo?" @@ -61,7 +61,7 @@ fn inject_deps_into_manifest( let new_deps = extern_crates.map(|dep| { // format the dependencies that are going to be put inside the Cargo.toml format!( - "{dep} = {{ path = \"{source_path}/lib{dep}\" }}\n", + "{dep} = {{ path = \"{source_path}/{dep}\" }}\n", dep = dep, source_path = rustc_source_dir.display() ) -- cgit 1.4.1-3-g733a5 From 4b459596a96a7d6f4797d4f1444311d88df60009 Mon Sep 17 00:00:00 2001 From: Philipp Hansch Date: Tue, 6 Oct 2020 08:18:11 +0200 Subject: clippy_dev: Replace lazy_static with SyncLazy --- clippy_dev/Cargo.toml | 1 - clippy_dev/src/lib.rs | 42 +++++++++++++++++++++++------------------- 2 files changed, 23 insertions(+), 20 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/Cargo.toml b/clippy_dev/Cargo.toml index c861efc8afb..d745000eac7 100644 --- a/clippy_dev/Cargo.toml +++ b/clippy_dev/Cargo.toml @@ -9,7 +9,6 @@ bytecount = "0.6" clap = "2.33" itertools = "0.9" regex = "1" -lazy_static = "1.0" shell-escape = "0.1" walkdir = "2" diff --git a/clippy_dev/src/lib.rs b/clippy_dev/src/lib.rs index 5baa31d5cde..567831354f5 100644 --- a/clippy_dev/src/lib.rs +++ b/clippy_dev/src/lib.rs @@ -1,11 +1,12 @@ #![cfg_attr(feature = "deny-warnings", deny(warnings))] +#![feature(once_cell)] use itertools::Itertools; -use lazy_static::lazy_static; use regex::Regex; use std::collections::HashMap; use std::ffi::OsStr; use std::fs; +use std::lazy::SyncLazy; use std::path::{Path, PathBuf}; use walkdir::WalkDir; @@ -15,28 +16,31 @@ pub mod ra_setup; pub mod stderr_length_check; pub mod update_lints; -lazy_static! { - static ref DEC_CLIPPY_LINT_RE: Regex = Regex::new( +static DEC_CLIPPY_LINT_RE: SyncLazy = SyncLazy::new(|| { + Regex::new( r#"(?x) - declare_clippy_lint!\s*[\{(] - (?:\s+///.*)* - \s+pub\s+(?P[A-Z_][A-Z_0-9]*)\s*,\s* - (?P[a-z_]+)\s*,\s* - "(?P(?:[^"\\]+|\\(?s).(?-s))*)"\s*[})] - "# + declare_clippy_lint!\s*[\{(] + (?:\s+///.*)* + \s+pub\s+(?P[A-Z_][A-Z_0-9]*)\s*,\s* + (?P[a-z_]+)\s*,\s* + "(?P(?:[^"\\]+|\\(?s).(?-s))*)"\s*[})] +"#, ) - .unwrap(); - static ref DEC_DEPRECATED_LINT_RE: Regex = Regex::new( + .unwrap() +}); + +static DEC_DEPRECATED_LINT_RE: SyncLazy = SyncLazy::new(|| { + Regex::new( r#"(?x) - declare_deprecated_lint!\s*[{(]\s* - (?:\s+///.*)* - \s+pub\s+(?P[A-Z_][A-Z_0-9]*)\s*,\s* - "(?P(?:[^"\\]+|\\(?s).(?-s))*)"\s*[})] - "# + declare_deprecated_lint!\s*[{(]\s* + (?:\s+///.*)* + \s+pub\s+(?P[A-Z_][A-Z_0-9]*)\s*,\s* + "(?P(?:[^"\\]+|\\(?s).(?-s))*)"\s*[})] +"#, ) - .unwrap(); - static ref NL_ESCAPE_RE: Regex = Regex::new(r#"\\\n\s*"#).unwrap(); -} + .unwrap() +}); +static NL_ESCAPE_RE: SyncLazy = SyncLazy::new(|| Regex::new(r#"\\\n\s*"#).unwrap()); pub static DOCS_LINK: &str = "https://rust-lang.github.io/rust-clippy/master/index.html"; -- cgit 1.4.1-3-g733a5 From e6a71066c8e9c0aaaabd10923f73c81285b16932 Mon Sep 17 00:00:00 2001 From: David Tolnay Date: Thu, 8 Oct 2020 05:18:22 -0700 Subject: Clippy dev subcommand to build and serve website --- clippy_dev/Cargo.toml | 1 + clippy_dev/src/lib.rs | 1 + clippy_dev/src/main.rs | 20 +++++++++++++++- clippy_dev/src/serve.rs | 64 +++++++++++++++++++++++++++++++++++++++++++++++++ doc/adding_lints.md | 3 ++- 5 files changed, 87 insertions(+), 2 deletions(-) create mode 100644 clippy_dev/src/serve.rs (limited to 'clippy_dev/src') diff --git a/clippy_dev/Cargo.toml b/clippy_dev/Cargo.toml index d745000eac7..b8a4a20114b 100644 --- a/clippy_dev/Cargo.toml +++ b/clippy_dev/Cargo.toml @@ -8,6 +8,7 @@ edition = "2018" bytecount = "0.6" clap = "2.33" itertools = "0.9" +opener = "0.4" regex = "1" shell-escape = "0.1" walkdir = "2" diff --git a/clippy_dev/src/lib.rs b/clippy_dev/src/lib.rs index 567831354f5..43cb2954b74 100644 --- a/clippy_dev/src/lib.rs +++ b/clippy_dev/src/lib.rs @@ -13,6 +13,7 @@ use walkdir::WalkDir; pub mod fmt; pub mod new_lint; pub mod ra_setup; +pub mod serve; pub mod stderr_length_check; pub mod update_lints; diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index 281037ae37c..7a8cbd5251d 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -1,7 +1,7 @@ #![cfg_attr(feature = "deny-warnings", deny(warnings))] use clap::{App, Arg, SubCommand}; -use clippy_dev::{fmt, new_lint, ra_setup, stderr_length_check, update_lints}; +use clippy_dev::{fmt, new_lint, ra_setup, serve, stderr_length_check, update_lints}; fn main() { let matches = App::new("Clippy developer tooling") @@ -100,6 +100,19 @@ fn main() { .required(true), ), ) + .subcommand( + SubCommand::with_name("serve") + .about("Launch a local 'ALL the Clippy Lints' website in a browser") + .arg( + Arg::with_name("port") + .long("port") + .short("p") + .help("Local port for the http server") + .default_value("8000") + .validator_os(serve::validate_port), + ) + .arg(Arg::with_name("lint").help("Which lint's page to load initially (optional)")), + ) .get_matches(); match matches.subcommand() { @@ -129,6 +142,11 @@ fn main() { stderr_length_check::check(); }, ("ra-setup", Some(matches)) => ra_setup::run(matches.value_of("rustc-repo-path")), + ("serve", Some(matches)) => { + let port = matches.value_of("port").unwrap().parse().unwrap(); + let lint = matches.value_of("lint"); + serve::run(port, lint); + }, _ => {}, } } diff --git a/clippy_dev/src/serve.rs b/clippy_dev/src/serve.rs new file mode 100644 index 00000000000..a46c0e4d3f0 --- /dev/null +++ b/clippy_dev/src/serve.rs @@ -0,0 +1,64 @@ +use std::ffi::{OsStr, OsString}; +use std::path::Path; +use std::process::Command; +use std::thread; +use std::time::{Duration, SystemTime}; + +pub fn run(port: u16, lint: Option<&str>) -> ! { + let mut url = Some(match lint { + None => format!("http://localhost:{}", port), + Some(lint) => format!("http://localhost:{}/#{}", port, lint), + }); + + loop { + if mtime("util/gh-pages/lints.json") < mtime("clippy_lints/src") { + Command::new("python3") + .arg("util/export.py") + .spawn() + .unwrap() + .wait() + .unwrap(); + } + if let Some(url) = url.take() { + thread::spawn(move || { + Command::new("python3") + .arg("-m") + .arg("http.server") + .arg(port.to_string()) + .current_dir("util/gh-pages") + .spawn() + .unwrap(); + // Give some time for python to start + thread::sleep(Duration::from_millis(500)); + // Launch browser after first export.py has completed and http.server is up + let _ = opener::open(url); + }); + } + thread::sleep(Duration::from_millis(1000)); + } +} + +fn mtime(path: impl AsRef) -> SystemTime { + let path = path.as_ref(); + if path.is_dir() { + path.read_dir() + .into_iter() + .flatten() + .flatten() + .map(|entry| mtime(&entry.path())) + .max() + .unwrap_or(SystemTime::UNIX_EPOCH) + } else { + path.metadata() + .and_then(|metadata| metadata.modified()) + .unwrap_or(SystemTime::UNIX_EPOCH) + } +} + +#[allow(clippy::missing_errors_doc)] +pub fn validate_port(arg: &OsStr) -> Result<(), OsString> { + match arg.to_string_lossy().parse::() { + Ok(_port) => Ok(()), + Err(err) => Err(OsString::from(err.to_string())), + } +} diff --git a/doc/adding_lints.md b/doc/adding_lints.md index 21e0f6f4fc7..2869c3bf7d4 100644 --- a/doc/adding_lints.md +++ b/doc/adding_lints.md @@ -189,7 +189,8 @@ declare_clippy_lint! { * The section of lines prefixed with `///` constitutes the lint documentation section. This is the default documentation style and will be displayed - [like this][example_lint_page]. + [like this][example_lint_page]. To render and open this documentation locally + in a browser, run `cargo dev serve`. * `FOO_FUNCTIONS` is the name of our lint. Be sure to follow the [lint naming guidelines][lint_naming] here when naming your lint. In short, the name should state the thing that is being checked for and -- cgit 1.4.1-3-g733a5 From c5774f94efd60b60fc7120ba3d6de7f79b05681b Mon Sep 17 00:00:00 2001 From: Philipp Hansch Date: Mon, 12 Oct 2020 16:50:34 +0200 Subject: lintlist.rs: Replace lazy_static with once_cell Follow-up to https://github.com/rust-lang/rust-clippy/pull/6120 --- clippy_dev/src/update_lints.rs | 2 +- src/driver.rs | 1 + src/lintlist/mod.rs | 13 +++++++------ 3 files changed, 9 insertions(+), 7 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/update_lints.rs b/clippy_dev/src/update_lints.rs index a9a70929942..556b67e0b37 100644 --- a/clippy_dev/src/update_lints.rs +++ b/clippy_dev/src/update_lints.rs @@ -29,7 +29,7 @@ pub fn run(update_mode: UpdateMode) { false, update_mode == UpdateMode::Change, || { - format!("pub static ref ALL_LINTS: Vec = vec!{:#?};", sorted_usable_lints) + format!("vec!{:#?}", sorted_usable_lints) .lines() .map(ToString::to_string) .collect::>() diff --git a/src/driver.rs b/src/driver.rs index 377f6d22446..c9b07855af1 100644 --- a/src/driver.rs +++ b/src/driver.rs @@ -1,4 +1,5 @@ #![feature(rustc_private)] +#![feature(once_cell)] #![cfg_attr(feature = "deny-warnings", deny(warnings))] // warn on lints, that are included in `rust-lang/rust`s bootstrap #![warn(rust_2018_idioms, unused_lifetimes)] diff --git a/src/lintlist/mod.rs b/src/lintlist/mod.rs index d0fc8f0c8a9..624223ff706 100644 --- a/src/lintlist/mod.rs +++ b/src/lintlist/mod.rs @@ -1,15 +1,16 @@ -//! This file is managed by `cargo dev update_lints`. Do not edit. +//! This file is managed by `cargo dev update_lints`. Do not edit or format this file. -use lazy_static::lazy_static; +use std::lazy::SyncLazy; pub mod lint; pub use lint::Level; pub use lint::Lint; pub use lint::LINT_LEVELS; -lazy_static! { +#[rustfmt::skip] +pub static ALL_LINTS: SyncLazy> = SyncLazy::new(|| { // begin lint list, do not remove this comment, it’s used in `update_lints` -pub static ref ALL_LINTS: Vec = vec![ +vec![ Lint { name: "absurd_extreme_comparisons", group: "correctness", @@ -2831,6 +2832,6 @@ pub static ref ALL_LINTS: Vec = vec![ deprecation: None, module: "methods", }, -]; +] // end lint list, do not remove this comment, it’s used in `update_lints` -} +}); -- cgit 1.4.1-3-g733a5 From 7f3462aa89b3ba570334fe9274a467be03367c59 Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Thu, 29 Oct 2020 03:22:02 +0100 Subject: cargo dev ra-setup: don't inject deps multiple times if we have already done so Fixes #6220 --- clippy_dev/src/ra_setup.rs | 11 ++++++++++- 1 file changed, 10 insertions(+), 1 deletion(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/ra_setup.rs b/clippy_dev/src/ra_setup.rs index c67efc10f15..9d9e836cc08 100644 --- a/clippy_dev/src/ra_setup.rs +++ b/clippy_dev/src/ra_setup.rs @@ -11,7 +11,7 @@ use std::path::PathBuf; // code. See https://github.com/rust-analyzer/rust-analyzer/issues/3517 and https://github.com/rust-lang/rust-clippy/issues/5514 for details pub fn run(rustc_path: Option<&str>) { - // we can unwrap here because the arg is required here + // we can unwrap here because the arg is required by clap let rustc_path = PathBuf::from(rustc_path.unwrap()); assert!(rustc_path.is_dir(), "path is not a directory"); let rustc_source_basedir = rustc_path.join("compiler"); @@ -49,6 +49,15 @@ fn inject_deps_into_manifest( cargo_toml: &str, lib_rs: &str, ) -> std::io::Result<()> { + // do not inject deps if we have aleady done so + if cargo_toml.contains("[target.'cfg(NOT_A_PLATFORM)'.dependencies]") { + eprintln!( + "cargo dev ra-setup: warning: deps already found inside {}, doing nothing.", + manifest_path + ); + return Ok(()); + } + let extern_crates = lib_rs .lines() // get the deps -- cgit 1.4.1-3-g733a5 From 958e2e20de762fa45f50e41a58c97548f79f8100 Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Fri, 13 Nov 2020 02:12:48 +0100 Subject: fix clippy-dev update_lints --- clippy_dev/src/lib.rs | 30 +++++++++++++++++++++++------- clippy_dev/src/update_lints.rs | 2 +- clippy_lints/src/lib.rs | 36 ++++++++++++++++++------------------ 3 files changed, 42 insertions(+), 26 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lib.rs b/clippy_dev/src/lib.rs index 43cb2954b74..1453ac7efa3 100644 --- a/clippy_dev/src/lib.rs +++ b/clippy_dev/src/lib.rs @@ -146,16 +146,32 @@ pub fn gen_deprecated<'a>(lints: impl Iterator) -> Vec } #[must_use] -pub fn gen_register_lint_list<'a>(lints: impl Iterator) -> Vec { - let pre = " store.register_lints(&[".to_string(); - let post = " ]);".to_string(); - let mut inner = lints +pub fn gen_register_lint_list<'a>( + internal_lints: impl Iterator, + usable_lints: impl Iterator, +) -> Vec { + let header = " store.register_lints(&[".to_string(); + let footer = " ]);".to_string(); + let internal_lints = internal_lints + .sorted_by_key(|l| format!(" &{}::{},", l.module, l.name.to_uppercase())) + .map(|l| { + format!( + " #[cfg(feature = \"internal-lints\")]\n &{}::{},", + l.module, + l.name.to_uppercase() + ) + }) + .collect::>(); + let other_lints = usable_lints + .sorted_by_key(|l| format!(" &{}::{},", l.module, l.name.to_uppercase())) .map(|l| format!(" &{}::{},", l.module, l.name.to_uppercase())) .sorted() .collect::>(); - inner.insert(0, pre); - inner.push(post); - inner + let mut lint_list = vec![header]; + lint_list.extend(internal_lints); + lint_list.extend(other_lints); + lint_list.push(footer); + lint_list } /// Gathers all files in `src/clippy_lints` and gathers all lints inside diff --git a/clippy_dev/src/update_lints.rs b/clippy_dev/src/update_lints.rs index fcf093f8835..edf6c5f57a4 100644 --- a/clippy_dev/src/update_lints.rs +++ b/clippy_dev/src/update_lints.rs @@ -68,7 +68,7 @@ pub fn run(update_mode: UpdateMode) { "end register lints", false, update_mode == UpdateMode::Change, - || gen_register_lint_list(usable_lints.iter().chain(internal_lints.iter())), + || gen_register_lint_list(internal_lints.iter(), usable_lints.iter()), ) .changed; diff --git a/clippy_lints/src/lib.rs b/clippy_lints/src/lib.rs index a58f7eb3666..fed7da3ee4f 100644 --- a/clippy_lints/src/lib.rs +++ b/clippy_lints/src/lib.rs @@ -498,6 +498,24 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf: // begin register lints, do not remove this comment, it’s used in `update_lints` store.register_lints(&[ + #[cfg(feature = "internal-lints")] + &utils::internal_lints::CLIPPY_LINTS_INTERNAL, + #[cfg(feature = "internal-lints")] + &utils::internal_lints::COLLAPSIBLE_SPAN_LINT_CALLS, + #[cfg(feature = "internal-lints")] + &utils::internal_lints::COMPILER_LINT_FUNCTIONS, + #[cfg(feature = "internal-lints")] + &utils::internal_lints::DEFAULT_LINT, + #[cfg(feature = "internal-lints")] + &utils::internal_lints::INVALID_PATHS, + #[cfg(feature = "internal-lints")] + &utils::internal_lints::LINT_WITHOUT_LINT_PASS, + #[cfg(feature = "internal-lints")] + &utils::internal_lints::MATCH_TYPE_ON_DIAGNOSTIC_ITEM, + #[cfg(feature = "internal-lints")] + &utils::internal_lints::OUTER_EXPN_EXPN_DATA, + #[cfg(feature = "internal-lints")] + &utils::internal_lints::PRODUCE_ICE, &approx_const::APPROX_CONSTANT, &arithmetic::FLOAT_ARITHMETIC, &arithmetic::INTEGER_ARITHMETIC, @@ -904,24 +922,6 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf: &unwrap_in_result::UNWRAP_IN_RESULT, &use_self::USE_SELF, &useless_conversion::USELESS_CONVERSION, - #[cfg(feature = "internal-lints")] - &utils::internal_lints::CLIPPY_LINTS_INTERNAL, - #[cfg(feature = "internal-lints")] - &utils::internal_lints::COLLAPSIBLE_SPAN_LINT_CALLS, - #[cfg(feature = "internal-lints")] - &utils::internal_lints::COMPILER_LINT_FUNCTIONS, - #[cfg(feature = "internal-lints")] - &utils::internal_lints::DEFAULT_LINT, - #[cfg(feature = "internal-lints")] - &utils::internal_lints::INVALID_PATHS, - #[cfg(feature = "internal-lints")] - &utils::internal_lints::LINT_WITHOUT_LINT_PASS, - #[cfg(feature = "internal-lints")] - &utils::internal_lints::MATCH_TYPE_ON_DIAGNOSTIC_ITEM, - #[cfg(feature = "internal-lints")] - &utils::internal_lints::OUTER_EXPN_EXPN_DATA, - #[cfg(feature = "internal-lints")] - &utils::internal_lints::PRODUCE_ICE, &vec::USELESS_VEC, &vec_resize_to_zero::VEC_RESIZE_TO_ZERO, &verbose_file_reads::VERBOSE_FILE_READS, -- cgit 1.4.1-3-g733a5 From 252083f7e02a3a9174bb39821fd20356ada3dd4a Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Mon, 16 Nov 2020 12:44:05 +0100 Subject: address review comments and rebase ci: always build with internal lints group up internal lints in lib.rs dogfood: we already pass --all-features, no need to enable internal-lints again --- .github/workflows/clippy_bors.yml | 7 ------ clippy_dev/src/lib.rs | 6 ++--- clippy_lints/src/lib.rs | 25 ++++++++---------- tests/dogfood.rs | 53 +++++++++++++++------------------------ 4 files changed, 33 insertions(+), 58 deletions(-) (limited to 'clippy_dev/src') diff --git a/.github/workflows/clippy_bors.yml b/.github/workflows/clippy_bors.yml index a8b4925176c..784463fe0df 100644 --- a/.github/workflows/clippy_bors.yml +++ b/.github/workflows/clippy_bors.yml @@ -128,13 +128,6 @@ jobs: SYSROOT=$(rustc --print sysroot) echo "$SYSROOT/bin" >> $GITHUB_PATH - - name: Build - run: cargo build --features deny-warnings - - # compiletest would panic due to "Found multiple rlibs for crate `clippy_lints`" - - name: clean rlibs - run: rm -f ./target/debug/deps/libclippy_lints* - - name: Build with internal lints run: cargo build --features deny-warnings,internal-lints diff --git a/clippy_dev/src/lib.rs b/clippy_dev/src/lib.rs index 1453ac7efa3..f51c45e9eb5 100644 --- a/clippy_dev/src/lib.rs +++ b/clippy_dev/src/lib.rs @@ -160,13 +160,11 @@ pub fn gen_register_lint_list<'a>( l.module, l.name.to_uppercase() ) - }) - .collect::>(); + }); let other_lints = usable_lints .sorted_by_key(|l| format!(" &{}::{},", l.module, l.name.to_uppercase())) .map(|l| format!(" &{}::{},", l.module, l.name.to_uppercase())) - .sorted() - .collect::>(); + .sorted(); let mut lint_list = vec![header]; lint_list.extend(internal_lints); lint_list.extend(other_lints); diff --git a/clippy_lints/src/lib.rs b/clippy_lints/src/lib.rs index fed7da3ee4f..8fbd44528b1 100644 --- a/clippy_lints/src/lib.rs +++ b/clippy_lints/src/lib.rs @@ -939,17 +939,23 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf: &zero_div_zero::ZERO_DIVIDED_BY_ZERO, ]); // end register lints, do not remove this comment, it’s used in `update_lints` - store.register_late_pass(|| box await_holding_invalid::AwaitHolding); - store.register_late_pass(|| box serde_api::SerdeAPI); + + // all the internal lints #[cfg(feature = "internal-lints")] { + store.register_early_pass(|| box utils::internal_lints::ClippyLintsInternal); + store.register_early_pass(|| box utils::internal_lints::ProduceIce); + store.register_late_pass(|| box utils::inspector::DeepCodeInspector); + store.register_late_pass(|| box utils::internal_lints::CollapsibleCalls); store.register_late_pass(|| box utils::internal_lints::CompilerLintFunctions::new()); + store.register_late_pass(|| box utils::internal_lints::InvalidPaths); store.register_late_pass(|| box utils::internal_lints::LintWithoutLintPass::default()); + store.register_late_pass(|| box utils::internal_lints::MatchTypeOnDiagItem); store.register_late_pass(|| box utils::internal_lints::OuterExpnDataPass); - store.register_late_pass(|| box utils::internal_lints::InvalidPaths); - store.register_late_pass(|| box utils::inspector::DeepCodeInspector); } store.register_late_pass(|| box utils::author::Author); + store.register_late_pass(|| box await_holding_invalid::AwaitHolding); + store.register_late_pass(|| box serde_api::SerdeAPI); let vec_box_size_threshold = conf.vec_box_size_threshold; store.register_late_pass(move || box types::Types::new(vec_box_size_threshold)); store.register_late_pass(|| box booleans::NonminimalBool); @@ -1134,8 +1140,6 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf: store.register_early_pass(|| box literal_representation::LiteralDigitGrouping); let literal_representation_threshold = conf.literal_representation_threshold; store.register_early_pass(move || box literal_representation::DecimalLiteralRepresentation::new(literal_representation_threshold)); - #[cfg(feature = "internal-lints")] - store.register_early_pass(|| box utils::internal_lints::ClippyLintsInternal); let enum_variant_name_threshold = conf.enum_variant_name_threshold; store.register_early_pass(move || box enum_variants::EnumVariantNames::new(enum_variant_name_threshold)); store.register_early_pass(|| box tabs_in_doc_comments::TabsInDocComments); @@ -1149,8 +1153,6 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf: store.register_late_pass(move || box large_const_arrays::LargeConstArrays::new(array_size_threshold)); store.register_late_pass(|| box floating_point_arithmetic::FloatingPointArithmetic); store.register_early_pass(|| box as_conversions::AsConversions); - #[cfg(feature = "internal-lints")] - store.register_early_pass(|| box utils::internal_lints::ProduceIce); store.register_late_pass(|| box let_underscore::LetUnderscore); store.register_late_pass(|| box atomic_ordering::AtomicOrdering); store.register_early_pass(|| box single_component_path_imports::SingleComponentPathImports); @@ -1166,8 +1168,6 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf: store.register_late_pass(|| box dereference::Dereferencing); store.register_late_pass(|| box option_if_let_else::OptionIfLetElse); store.register_late_pass(|| box future_not_send::FutureNotSend); - #[cfg(feature = "internal-lints")] - store.register_late_pass(|| box utils::internal_lints::CollapsibleCalls); store.register_late_pass(|| box if_let_mutex::IfLetMutex); store.register_late_pass(|| box mut_mutex_lock::MutMutexLock); store.register_late_pass(|| box match_on_vec_items::MatchOnVecItems); @@ -1175,7 +1175,6 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf: store.register_early_pass(|| box redundant_field_names::RedundantFieldNames); store.register_late_pass(|| box vec_resize_to_zero::VecResizeToZero); store.register_late_pass(|| box panic_in_result_fn::PanicInResultFn); - let single_char_binding_names_threshold = conf.single_char_binding_names_threshold; store.register_early_pass(move || box non_expressive_names::NonExpressiveNames { single_char_binding_names_threshold, @@ -1192,8 +1191,6 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf: store.register_late_pass(|| box manual_ok_or::ManualOkOr); store.register_late_pass(|| box float_equality_without_abs::FloatEqualityWithoutAbs); store.register_late_pass(|| box async_yields_async::AsyncYieldsAsync); - #[cfg(feature = "internal-lints")] - store.register_late_pass(|| box utils::internal_lints::MatchTypeOnDiagItem); let disallowed_methods = conf.disallowed_methods.iter().cloned().collect::>(); store.register_late_pass(move || box disallowed_method::DisallowedMethod::new(&disallowed_methods)); store.register_early_pass(|| box asm_syntax::InlineAsmX86AttSyntax); @@ -1202,7 +1199,6 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf: store.register_late_pass(|| box strings::StrToString); store.register_late_pass(|| box strings::StringToString); - store.register_group(true, "clippy::restriction", Some("clippy_restriction"), vec![ LintId::of(&arithmetic::FLOAT_ARITHMETIC), LintId::of(&arithmetic::INTEGER_ARITHMETIC), @@ -1333,6 +1329,7 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf: LintId::of(&wildcard_imports::ENUM_GLOB_USE), LintId::of(&wildcard_imports::WILDCARD_IMPORTS), ]); + #[cfg(feature = "internal-lints")] store.register_group(true, "clippy::internal", Some("clippy_internal"), vec![ LintId::of(&utils::internal_lints::CLIPPY_LINTS_INTERNAL), diff --git a/tests/dogfood.rs b/tests/dogfood.rs index eae25adf839..a6163a83d76 100644 --- a/tests/dogfood.rs +++ b/tests/dogfood.rs @@ -18,39 +18,26 @@ fn dogfood_clippy() { } let root_dir = PathBuf::from(env!("CARGO_MANIFEST_DIR")); - let output = if cfg!(feature = "internal-lints") { - // with internal lints and internal warnings - Command::new(&*CLIPPY_PATH) - .current_dir(root_dir) - .env("CLIPPY_DOGFOOD", "1") - .env("CARGO_INCREMENTAL", "0") - .arg("clippy-preview") - .arg("--all-targets") - .arg("--all-features") - .args(&["--features", "internal-lints"]) - .arg("--") - .args(&["-D", "clippy::all"]) - .args(&["-D", "clippy::pedantic"]) - .args(&["-D", "clippy::internal"]) - .arg("-Cdebuginfo=0") // disable debuginfo to generate less data in the target dir - .output() - .unwrap() - } else { - // without internal lints or warnings - Command::new(&*CLIPPY_PATH) - .current_dir(root_dir) - .env("CLIPPY_DOGFOOD", "1") - .env("CARGO_INCREMENTAL", "0") - .arg("clippy-preview") - .arg("--all-targets") - .arg("--all-features") - .arg("--") - .args(&["-D", "clippy::all"]) - .args(&["-D", "clippy::pedantic"]) - .arg("-Cdebuginfo=0") // disable debuginfo to generate less data in the target dir - .output() - .unwrap() - }; + let mut command = Command::new(&*CLIPPY_PATH); + command + .current_dir(root_dir) + .env("CLIPPY_DOGFOOD", "1") + .env("CARGO_INCREMENTAL", "0") + .arg("clippy-preview") + .arg("--all-targets") + .arg("--all-features") + .arg("--") + .args(&["-D", "clippy::all"]) + .args(&["-D", "clippy::pedantic"]) + .arg("-Cdebuginfo=0"); // disable debuginfo to generate less data in the target dir + + // internal lints only exist if we build with the internal-lints feature + if cfg!(feature = "internal-lints") { + command.args(&["-D", "clippy::internal"]); + } + + let output = command.output().unwrap(); + println!("status: {}", output.status); println!("stdout: {}", String::from_utf8_lossy(&output.stdout)); println!("stderr: {}", String::from_utf8_lossy(&output.stderr)); -- cgit 1.4.1-3-g733a5 From 4bd9ed9b88d47bba3dc91fde6c0a27b63f63fe4b Mon Sep 17 00:00:00 2001 From: Philipp Hansch Date: Wed, 2 Dec 2020 18:20:02 +0100 Subject: Rewrite update-all-references bash scripts in Rust This replaces the `update-all-references` scripts with a single cargo dev bless command. cc #5394 --- clippy_dev/src/bless.rs | 71 +++++++++++++++++++++++++++++++++ clippy_dev/src/lib.rs | 1 + clippy_dev/src/main.rs | 6 ++- doc/adding_lints.md | 13 +++--- doc/basics.md | 2 +- tests/ui-cargo/update-all-references.sh | 17 +------- tests/ui-cargo/update-references.sh | 46 --------------------- tests/ui-toml/update-all-references.sh | 17 +------- tests/ui-toml/update-references.sh | 46 --------------------- tests/ui/update-all-references.sh | 20 +--------- tests/ui/update-references.sh | 56 -------------------------- 11 files changed, 87 insertions(+), 208 deletions(-) create mode 100644 clippy_dev/src/bless.rs delete mode 100755 tests/ui-cargo/update-references.sh delete mode 100755 tests/ui-toml/update-references.sh delete mode 100755 tests/ui/update-references.sh (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/bless.rs b/clippy_dev/src/bless.rs new file mode 100644 index 00000000000..45e403fa74d --- /dev/null +++ b/clippy_dev/src/bless.rs @@ -0,0 +1,71 @@ +//! `bless` updates the 'expected output' files in the repo with changed output files +//! from the last test run. + +use std::env; +use std::ffi::OsStr; +use std::fs; +use std::lazy::SyncLazy; +use std::path::PathBuf; +use walkdir::WalkDir; + +use crate::clippy_project_root; + +// NOTE: this is duplicated with tests/cargo/mod.rs What to do? +pub static CARGO_TARGET_DIR: SyncLazy = SyncLazy::new(|| match env::var_os("CARGO_TARGET_DIR") { + Some(v) => v.into(), + None => env::current_dir().unwrap().join("target"), +}); + +pub fn bless() { + let test_dirs = [ + clippy_project_root().join("tests").join("ui"), + clippy_project_root().join("tests").join("ui-toml"), + clippy_project_root().join("tests").join("ui-cargo"), + ]; + for test_dir in &test_dirs { + WalkDir::new(test_dir) + .into_iter() + .filter_map(Result::ok) + .filter(|f| f.path().extension() == Some(OsStr::new("rs"))) + .for_each(|f| { + update_test_file(f.path().with_extension("stdout")); + update_test_file(f.path().with_extension("stderr")); + update_test_file(f.path().with_extension("fixed")); + }); + } +} + +fn update_test_file(test_file_path: PathBuf) { + let build_output_path = build_dir().join(PathBuf::from(test_file_path.file_name().unwrap())); + let relative_test_file_path = test_file_path.strip_prefix(clippy_project_root()).unwrap(); + + // If compiletest did not write any changes during the test run, + // we don't have to update anything + if !build_output_path.exists() { + return; + } + + let build_output = fs::read(&build_output_path).expect("Unable to read build output file"); + let test_file = fs::read(&test_file_path).expect("Unable to read test file"); + + if build_output != test_file { + // If a test run caused an output file to change, update the test file + println!("updating {}", &relative_test_file_path.display()); + fs::copy(build_output_path, &test_file_path).expect("Could not update test file"); + + if test_file.is_empty() { + // If we copied over an empty output file, we remove it + println!("removing {}", &relative_test_file_path.display()); + fs::remove_file(test_file_path).expect("Could not remove test file"); + } + } +} + +fn build_dir() -> PathBuf { + let profile = format!("{}", env::var("PROFILE").unwrap_or("debug".to_string())); + let mut path = PathBuf::new(); + path.push(CARGO_TARGET_DIR.clone()); + path.push(profile); + path.push("test_build_base"); + path +} diff --git a/clippy_dev/src/lib.rs b/clippy_dev/src/lib.rs index f51c45e9eb5..17cc08ee10f 100644 --- a/clippy_dev/src/lib.rs +++ b/clippy_dev/src/lib.rs @@ -10,6 +10,7 @@ use std::lazy::SyncLazy; use std::path::{Path, PathBuf}; use walkdir::WalkDir; +pub mod bless; pub mod fmt; pub mod new_lint; pub mod ra_setup; diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index 7a8cbd5251d..f66855620e7 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -1,10 +1,11 @@ #![cfg_attr(feature = "deny-warnings", deny(warnings))] use clap::{App, Arg, SubCommand}; -use clippy_dev::{fmt, new_lint, ra_setup, serve, stderr_length_check, update_lints}; +use clippy_dev::{bless, fmt, new_lint, ra_setup, serve, stderr_length_check, update_lints}; fn main() { let matches = App::new("Clippy developer tooling") + .subcommand(SubCommand::with_name("bless").about("bless the test output changes")) .subcommand( SubCommand::with_name("fmt") .about("Run rustfmt on all projects and tests") @@ -116,6 +117,9 @@ fn main() { .get_matches(); match matches.subcommand() { + ("bless", Some(_)) => { + bless::bless(); + }, ("fmt", Some(matches)) => { fmt::run(matches.is_present("check"), matches.is_present("verbose")); }, diff --git a/doc/adding_lints.md b/doc/adding_lints.md index a723b0a4c20..60dfdb76650 100644 --- a/doc/adding_lints.md +++ b/doc/adding_lints.md @@ -98,12 +98,12 @@ While we are working on implementing our lint, we can keep running the UI test. That allows us to check if the output is turning into what we want. Once we are satisfied with the output, we need to run -`tests/ui/update-all-references.sh` to update the `.stderr` file for our lint. +`cargo dev bless` to update the `.stderr` file for our lint. Please note that, we should run `TESTNAME=foo_functions cargo uitest` -every time before running `tests/ui/update-all-references.sh`. +every time before running `cargo dev bless`. Running `TESTNAME=foo_functions cargo uitest` should pass then. When we commit our lint, we need to commit the generated `.stderr` files, too. In general, you -should only commit files changed by `tests/ui/update-all-references.sh` for the +should only commit files changed by `cargo dev bless` for the specific lint you are creating/editing. Note that if the generated files are empty, they should be removed. @@ -122,8 +122,7 @@ we will find by default two new crates, each with its manifest file: If you need more cases, you can copy one of those crates (under `foo_categories`) and rename it. The process of generating the `.stderr` file is the same, and prepending the `TESTNAME` -variable to `cargo uitest` works too, but the script to update the references -is in another path: `tests/ui-cargo/update-all-references.sh`. +variable to `cargo uitest` works too. ## Rustfix tests @@ -133,7 +132,7 @@ additionally run [rustfix] for that test. Rustfix will apply the suggestions from the lint to the code of the test file and compare that to the contents of a `.fixed` file. -Use `tests/ui/update-all-references.sh` to automatically generate the +Use `cargo dev bless` to automatically generate the `.fixed` file after running the tests. [rustfix]: https://github.com/rust-lang/rustfix @@ -368,7 +367,7 @@ fn is_foo_fn(fn_kind: FnKind<'_>) -> bool { Now we should also run the full test suite with `cargo test`. At this point running `cargo test` should produce the expected output. Remember to run -`tests/ui/update-all-references.sh` to update the `.stderr` file. +`cargo dev bless` to update the `.stderr` file. `cargo test` (as opposed to `cargo uitest`) will also ensure that our lint implementation is not violating any Clippy lints itself. diff --git a/doc/basics.md b/doc/basics.md index 8b2a8a23890..dc71f022773 100644 --- a/doc/basics.md +++ b/doc/basics.md @@ -61,7 +61,7 @@ If the output of a [UI test] differs from the expected output, you can update th reference file with: ```bash -sh tests/ui/update-all-references.sh +cargo dev bless ``` For example, this is necessary, if you fix a typo in an error message of a lint diff --git a/tests/ui-cargo/update-all-references.sh b/tests/ui-cargo/update-all-references.sh index 7028b251ea0..4391499a1e1 100755 --- a/tests/ui-cargo/update-all-references.sh +++ b/tests/ui-cargo/update-all-references.sh @@ -1,18 +1,3 @@ #!/bin/bash -# -# A script to update the references for all tests. The idea is that -# you do a run, which will generate files in the build directory -# containing the (normalized) actual output of the compiler. You then -# run this script, which will copy those files over. If you find -# yourself manually editing a foo.stderr file, you're doing it wrong. -# -# See all `update-references.sh`, if you just want to update a single test. -if [[ "$1" == "--help" || "$1" == "-h" ]]; then - echo "usage: $0" -fi - -BUILD_DIR=$PWD/target/debug/test_build_base -MY_DIR=$(dirname "$0") -cd "$MY_DIR" || exit -find . -name '*.rs' -exec ./update-references.sh "$BUILD_DIR" {} + +echo "Please use 'cargo dev bless' instead." diff --git a/tests/ui-cargo/update-references.sh b/tests/ui-cargo/update-references.sh deleted file mode 100755 index 2ab51168bca..00000000000 --- a/tests/ui-cargo/update-references.sh +++ /dev/null @@ -1,46 +0,0 @@ -#!/bin/bash - -# A script to update the references for particular tests. The idea is -# that you do a run, which will generate files in the build directory -# containing the (normalized) actual output of the compiler. This -# script will then copy that output and replace the "expected output" -# files. You can then commit the changes. -# -# If you find yourself manually editing a foo.stderr file, you're -# doing it wrong. - -if [[ "$1" == "--help" || "$1" == "-h" || "$1" == "" || "$2" == "" ]]; then - echo "usage: $0 " - echo "" - echo "For example:" - echo " $0 ../../../build/x86_64-apple-darwin/test/ui *.rs */*.rs" -fi - -MYDIR=$(dirname "$0") - -BUILD_DIR="$1" -shift - -while [[ "$1" != "" ]]; do - STDERR_NAME="${1/%.rs/.stderr}" - STDOUT_NAME="${1/%.rs/.stdout}" - shift - if [[ -f "$BUILD_DIR"/"$STDOUT_NAME" ]] && \ - ! (cmp -s -- "$BUILD_DIR"/"$STDOUT_NAME" "$MYDIR"/"$STDOUT_NAME"); then - echo updating "$MYDIR"/"$STDOUT_NAME" - cp "$BUILD_DIR"/"$STDOUT_NAME" "$MYDIR"/"$STDOUT_NAME" - if [[ ! -s "$MYDIR"/"$STDOUT_NAME" ]]; then - echo removing "$MYDIR"/"$STDOUT_NAME" - rm "$MYDIR"/"$STDOUT_NAME" - fi - fi - if [[ -f "$BUILD_DIR"/"$STDERR_NAME" ]] && \ - ! (cmp -s -- "$BUILD_DIR"/"$STDERR_NAME" "$MYDIR"/"$STDERR_NAME"); then - echo updating "$MYDIR"/"$STDERR_NAME" - cp "$BUILD_DIR"/"$STDERR_NAME" "$MYDIR"/"$STDERR_NAME" - if [[ ! -s "$MYDIR"/"$STDERR_NAME" ]]; then - echo removing "$MYDIR"/"$STDERR_NAME" - rm "$MYDIR"/"$STDERR_NAME" - fi - fi -done diff --git a/tests/ui-toml/update-all-references.sh b/tests/ui-toml/update-all-references.sh index 7028b251ea0..4391499a1e1 100755 --- a/tests/ui-toml/update-all-references.sh +++ b/tests/ui-toml/update-all-references.sh @@ -1,18 +1,3 @@ #!/bin/bash -# -# A script to update the references for all tests. The idea is that -# you do a run, which will generate files in the build directory -# containing the (normalized) actual output of the compiler. You then -# run this script, which will copy those files over. If you find -# yourself manually editing a foo.stderr file, you're doing it wrong. -# -# See all `update-references.sh`, if you just want to update a single test. -if [[ "$1" == "--help" || "$1" == "-h" ]]; then - echo "usage: $0" -fi - -BUILD_DIR=$PWD/target/debug/test_build_base -MY_DIR=$(dirname "$0") -cd "$MY_DIR" || exit -find . -name '*.rs' -exec ./update-references.sh "$BUILD_DIR" {} + +echo "Please use 'cargo dev bless' instead." diff --git a/tests/ui-toml/update-references.sh b/tests/ui-toml/update-references.sh deleted file mode 100755 index 2ab51168bca..00000000000 --- a/tests/ui-toml/update-references.sh +++ /dev/null @@ -1,46 +0,0 @@ -#!/bin/bash - -# A script to update the references for particular tests. The idea is -# that you do a run, which will generate files in the build directory -# containing the (normalized) actual output of the compiler. This -# script will then copy that output and replace the "expected output" -# files. You can then commit the changes. -# -# If you find yourself manually editing a foo.stderr file, you're -# doing it wrong. - -if [[ "$1" == "--help" || "$1" == "-h" || "$1" == "" || "$2" == "" ]]; then - echo "usage: $0 " - echo "" - echo "For example:" - echo " $0 ../../../build/x86_64-apple-darwin/test/ui *.rs */*.rs" -fi - -MYDIR=$(dirname "$0") - -BUILD_DIR="$1" -shift - -while [[ "$1" != "" ]]; do - STDERR_NAME="${1/%.rs/.stderr}" - STDOUT_NAME="${1/%.rs/.stdout}" - shift - if [[ -f "$BUILD_DIR"/"$STDOUT_NAME" ]] && \ - ! (cmp -s -- "$BUILD_DIR"/"$STDOUT_NAME" "$MYDIR"/"$STDOUT_NAME"); then - echo updating "$MYDIR"/"$STDOUT_NAME" - cp "$BUILD_DIR"/"$STDOUT_NAME" "$MYDIR"/"$STDOUT_NAME" - if [[ ! -s "$MYDIR"/"$STDOUT_NAME" ]]; then - echo removing "$MYDIR"/"$STDOUT_NAME" - rm "$MYDIR"/"$STDOUT_NAME" - fi - fi - if [[ -f "$BUILD_DIR"/"$STDERR_NAME" ]] && \ - ! (cmp -s -- "$BUILD_DIR"/"$STDERR_NAME" "$MYDIR"/"$STDERR_NAME"); then - echo updating "$MYDIR"/"$STDERR_NAME" - cp "$BUILD_DIR"/"$STDERR_NAME" "$MYDIR"/"$STDERR_NAME" - if [[ ! -s "$MYDIR"/"$STDERR_NAME" ]]; then - echo removing "$MYDIR"/"$STDERR_NAME" - rm "$MYDIR"/"$STDERR_NAME" - fi - fi -done diff --git a/tests/ui/update-all-references.sh b/tests/ui/update-all-references.sh index 30ba9188db4..4391499a1e1 100755 --- a/tests/ui/update-all-references.sh +++ b/tests/ui/update-all-references.sh @@ -1,21 +1,3 @@ #!/bin/bash -# A script to update the references for all tests. The idea is that -# you do a run, which will generate files in the build directory -# containing the (normalized) actual output of the compiler. You then -# run this script, which will copy those files over. If you find -# yourself manually editing a foo.stderr file, you're doing it wrong. -# -# See all `update-references.sh`, if you just want to update a single test. - -if [[ "$1" == "--help" || "$1" == "-h" ]]; then - echo "usage: $0" -fi - -CARGO_TARGET_DIR=${CARGO_TARGET_DIR:-$PWD/target} -PROFILE=${PROFILE:-debug} -BUILD_DIR=${CARGO_TARGET_DIR}/${PROFILE}/test_build_base - -MY_DIR=$(dirname "$0") -cd "$MY_DIR" || exit -find . -name '*.rs' -exec ./update-references.sh "$BUILD_DIR" {} + +echo "Please use 'cargo dev bless' instead." diff --git a/tests/ui/update-references.sh b/tests/ui/update-references.sh deleted file mode 100755 index e16ed600ef8..00000000000 --- a/tests/ui/update-references.sh +++ /dev/null @@ -1,56 +0,0 @@ -#!/bin/bash - -# A script to update the references for particular tests. The idea is -# that you do a run, which will generate files in the build directory -# containing the (normalized) actual output of the compiler. This -# script will then copy that output and replace the "expected output" -# files. You can then commit the changes. -# -# If you find yourself manually editing a `foo.stderr` file, you're -# doing it wrong. - -if [[ "$1" == "--help" || "$1" == "-h" || "$1" == "" || "$2" == "" ]]; then - echo "usage: $0 " - echo "" - echo "For example:" - echo " $0 ../../../build/x86_64-apple-darwin/test/ui *.rs */*.rs" -fi - -MYDIR=$(dirname "$0") - -BUILD_DIR="$1" -shift - -while [[ "$1" != "" ]]; do - STDERR_NAME="${1/%.rs/.stderr}" - STDOUT_NAME="${1/%.rs/.stdout}" - FIXED_NAME="${1/%.rs/.fixed}" - shift - if [[ -f "$BUILD_DIR"/"$STDOUT_NAME" ]] && \ - ! (cmp -s -- "$BUILD_DIR"/"$STDOUT_NAME" "$MYDIR"/"$STDOUT_NAME"); then - echo updating "$MYDIR"/"$STDOUT_NAME" - cp "$BUILD_DIR"/"$STDOUT_NAME" "$MYDIR"/"$STDOUT_NAME" - if [[ ! -s "$MYDIR"/"$STDOUT_NAME" ]]; then - echo removing "$MYDIR"/"$STDOUT_NAME" - rm "$MYDIR"/"$STDOUT_NAME" - fi - fi - if [[ -f "$BUILD_DIR"/"$STDERR_NAME" ]] && \ - ! (cmp -s -- "$BUILD_DIR"/"$STDERR_NAME" "$MYDIR"/"$STDERR_NAME"); then - echo updating "$MYDIR"/"$STDERR_NAME" - cp "$BUILD_DIR"/"$STDERR_NAME" "$MYDIR"/"$STDERR_NAME" - if [[ ! -s "$MYDIR"/"$STDERR_NAME" ]]; then - echo removing "$MYDIR"/"$STDERR_NAME" - rm "$MYDIR"/"$STDERR_NAME" - fi - fi - if [[ -f "$BUILD_DIR"/"$FIXED_NAME" ]] && \ - ! (cmp -s -- "$BUILD_DIR"/"$FIXED_NAME" "$MYDIR"/"$FIXED_NAME"); then - echo updating "$MYDIR"/"$FIXED_NAME" - cp "$BUILD_DIR"/"$FIXED_NAME" "$MYDIR"/"$FIXED_NAME" - if [[ ! -s "$MYDIR"/"$FIXED_NAME" ]]; then - echo removing "$MYDIR"/"$FIXED_NAME" - rm "$MYDIR"/"$FIXED_NAME" - fi - fi -done -- cgit 1.4.1-3-g733a5 From 41c562d4a578637306dca2d9a7889d8f5bb4a58e Mon Sep 17 00:00:00 2001 From: Philipp Hansch Date: Thu, 10 Dec 2020 11:34:22 +0100 Subject: Improve variable naming --- clippy_dev/src/bless.rs | 36 ++++++++++++++++++------------------ 1 file changed, 18 insertions(+), 18 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/bless.rs b/clippy_dev/src/bless.rs index 45e403fa74d..6a1fa61b12d 100644 --- a/clippy_dev/src/bless.rs +++ b/clippy_dev/src/bless.rs @@ -1,4 +1,4 @@ -//! `bless` updates the 'expected output' files in the repo with changed output files +//! `bless` updates the reference files in the repo with changed output files //! from the last test run. use std::env; @@ -28,35 +28,35 @@ pub fn bless() { .filter_map(Result::ok) .filter(|f| f.path().extension() == Some(OsStr::new("rs"))) .for_each(|f| { - update_test_file(f.path().with_extension("stdout")); - update_test_file(f.path().with_extension("stderr")); - update_test_file(f.path().with_extension("fixed")); + update_reference_file(f.path().with_extension("stdout")); + update_reference_file(f.path().with_extension("stderr")); + update_reference_file(f.path().with_extension("fixed")); }); } } -fn update_test_file(test_file_path: PathBuf) { - let build_output_path = build_dir().join(PathBuf::from(test_file_path.file_name().unwrap())); - let relative_test_file_path = test_file_path.strip_prefix(clippy_project_root()).unwrap(); +fn update_reference_file(reference_file_path: PathBuf) { + let test_output_path = build_dir().join(PathBuf::from(reference_file_path.file_name().unwrap())); + let relative_reference_file_path = reference_file_path.strip_prefix(clippy_project_root()).unwrap(); // If compiletest did not write any changes during the test run, // we don't have to update anything - if !build_output_path.exists() { + if !test_output_path.exists() { return; } - let build_output = fs::read(&build_output_path).expect("Unable to read build output file"); - let test_file = fs::read(&test_file_path).expect("Unable to read test file"); + let test_output_file = fs::read(&test_output_path).expect("Unable to read test output file"); + let reference_file = fs::read(&reference_file_path).expect("Unable to read reference file"); - if build_output != test_file { - // If a test run caused an output file to change, update the test file - println!("updating {}", &relative_test_file_path.display()); - fs::copy(build_output_path, &test_file_path).expect("Could not update test file"); + if test_output_file != reference_file { + // If a test run caused an output file to change, update the reference file + println!("updating {}", &relative_reference_file_path.display()); + fs::copy(test_output_path, &reference_file_path).expect("Could not update reference file"); - if test_file.is_empty() { - // If we copied over an empty output file, we remove it - println!("removing {}", &relative_test_file_path.display()); - fs::remove_file(test_file_path).expect("Could not remove test file"); + if reference_file.is_empty() { + // If we copied over an empty output file, we remove the now empty reference file + println!("removing {}", &relative_reference_file_path.display()); + fs::remove_file(reference_file_path).expect("Could not remove reference file"); } } } -- cgit 1.4.1-3-g733a5 From b8501e1be12594145bcd2bae2b47af2152785622 Mon Sep 17 00:00:00 2001 From: Philipp Hansch Date: Sat, 12 Dec 2020 15:14:54 +0100 Subject: Feed the dog :dog2: --- clippy_dev/src/bless.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/bless.rs b/clippy_dev/src/bless.rs index 6a1fa61b12d..8d5c2e95055 100644 --- a/clippy_dev/src/bless.rs +++ b/clippy_dev/src/bless.rs @@ -62,7 +62,7 @@ fn update_reference_file(reference_file_path: PathBuf) { } fn build_dir() -> PathBuf { - let profile = format!("{}", env::var("PROFILE").unwrap_or("debug".to_string())); + let profile = env::var("PROFILE").unwrap_or_else(|_| "debug".to_string()); let mut path = PathBuf::new(); path.push(CARGO_TARGET_DIR.clone()); path.push(profile); -- cgit 1.4.1-3-g733a5 From 404c50f56200c28ebbee64113c9dfc0120c33e7a Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Sun, 13 Dec 2020 15:22:45 +0100 Subject: NFC: clippy cargo dev: move generation of clap config into a function --- clippy_dev/src/main.rs | 100 +++++++++++++++++++++++++------------------------ 1 file changed, 52 insertions(+), 48 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index f66855620e7..5938b788101 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -1,10 +1,52 @@ #![cfg_attr(feature = "deny-warnings", deny(warnings))] -use clap::{App, Arg, SubCommand}; +use clap::{App, Arg, ArgMatches, SubCommand}; use clippy_dev::{bless, fmt, new_lint, ra_setup, serve, stderr_length_check, update_lints}; fn main() { - let matches = App::new("Clippy developer tooling") + let matches = get_clap_config(); + + match matches.subcommand() { + ("bless", Some(_)) => { + bless::bless(); + }, + ("fmt", Some(matches)) => { + fmt::run(matches.is_present("check"), matches.is_present("verbose")); + }, + ("update_lints", Some(matches)) => { + if matches.is_present("print-only") { + update_lints::print_lints(); + } else if matches.is_present("check") { + update_lints::run(update_lints::UpdateMode::Check); + } else { + update_lints::run(update_lints::UpdateMode::Change); + } + }, + ("new_lint", Some(matches)) => { + match new_lint::create( + matches.value_of("pass"), + matches.value_of("name"), + matches.value_of("category"), + ) { + Ok(_) => update_lints::run(update_lints::UpdateMode::Change), + Err(e) => eprintln!("Unable to create lint: {}", e), + } + }, + ("limit_stderr_length", _) => { + stderr_length_check::check(); + }, + ("ra-setup", Some(matches)) => ra_setup::run(matches.value_of("rustc-repo-path")), + ("serve", Some(matches)) => { + let port = matches.value_of("port").unwrap().parse().unwrap(); + let lint = matches.value_of("lint"); + serve::run(port, lint); + }, + _ => {}, + } +} + +fn get_clap_config<'a>() -> ArgMatches<'a> { + App::new("Clippy developer tooling") .subcommand(SubCommand::with_name("bless").about("bless the test output changes")) .subcommand( SubCommand::with_name("fmt") @@ -26,16 +68,16 @@ fn main() { .about("Updates lint registration and information from the source code") .long_about( "Makes sure that:\n \ - * the lint count in README.md is correct\n \ - * the changelog contains markdown link references at the bottom\n \ - * all lint groups include the correct lints\n \ - * lint modules in `clippy_lints/*` are visible in `src/lib.rs` via `pub mod`\n \ - * all lints are registered in the lint store", + * the lint count in README.md is correct\n \ + * the changelog contains markdown link references at the bottom\n \ + * all lint groups include the correct lints\n \ + * lint modules in `clippy_lints/*` are visible in `src/lifb.rs` via `pub mod`\n \ + * all lints are registered in the lint store", ) .arg(Arg::with_name("print-only").long("print-only").help( "Print a table of lints to STDOUT. \ - This does not include deprecated and internal lints. \ - (Does not modify any files)", + This does not include deprecated and internal lints. \ + (Does not modify any files)", )) .arg( Arg::with_name("check") @@ -114,43 +156,5 @@ fn main() { ) .arg(Arg::with_name("lint").help("Which lint's page to load initially (optional)")), ) - .get_matches(); - - match matches.subcommand() { - ("bless", Some(_)) => { - bless::bless(); - }, - ("fmt", Some(matches)) => { - fmt::run(matches.is_present("check"), matches.is_present("verbose")); - }, - ("update_lints", Some(matches)) => { - if matches.is_present("print-only") { - update_lints::print_lints(); - } else if matches.is_present("check") { - update_lints::run(update_lints::UpdateMode::Check); - } else { - update_lints::run(update_lints::UpdateMode::Change); - } - }, - ("new_lint", Some(matches)) => { - match new_lint::create( - matches.value_of("pass"), - matches.value_of("name"), - matches.value_of("category"), - ) { - Ok(_) => update_lints::run(update_lints::UpdateMode::Change), - Err(e) => eprintln!("Unable to create lint: {}", e), - } - }, - ("limit_stderr_length", _) => { - stderr_length_check::check(); - }, - ("ra-setup", Some(matches)) => ra_setup::run(matches.value_of("rustc-repo-path")), - ("serve", Some(matches)) => { - let port = matches.value_of("port").unwrap().parse().unwrap(); - let lint = matches.value_of("lint"); - serve::run(port, lint); - }, - _ => {}, - } + .get_matches() } -- cgit 1.4.1-3-g733a5 From 91fa25c9de9b8abb410273fe233fd71c39a434e3 Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Sun, 13 Dec 2020 15:49:48 +0100 Subject: clippy dev fmt: don't format if we have a local rustc repo enabled as path dependency via cargo dev ra-setup. rustfmt would try to format the entire rustc repo, probably because it sees it as a local dependency. --- clippy_dev/src/fmt.rs | 21 ++++++++++++++++++++- 1 file changed, 20 insertions(+), 1 deletion(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/fmt.rs b/clippy_dev/src/fmt.rs index 6ae3f58c1f2..6f13af8aa47 100644 --- a/clippy_dev/src/fmt.rs +++ b/clippy_dev/src/fmt.rs @@ -1,9 +1,9 @@ use crate::clippy_project_root; use shell_escape::escape; use std::ffi::OsStr; -use std::io; use std::path::Path; use std::process::{self, Command}; +use std::{fs, io}; use walkdir::WalkDir; #[derive(Debug)] @@ -12,6 +12,7 @@ pub enum CliError { IoError(io::Error), RustfmtNotInstalled, WalkDirError(walkdir::Error), + RaSetupActive, } impl From for CliError { @@ -31,12 +32,23 @@ struct FmtContext { verbose: bool, } +// the "main" function of cargo dev fmt pub fn run(check: bool, verbose: bool) { fn try_run(context: &FmtContext) -> Result { let mut success = true; let project_root = clippy_project_root(); + // if we added a local rustc repo as path dependency to clippy for rust analyzer, we do NOT want to + // format because rustfmt would also format the entire rustc repo as it is a local + // dependency + if fs::read_to_string(project_root.join("Cargo.toml")) + .expect("Failed to read clippy Cargo.toml") + .contains(&"[target.'cfg(NOT_A_PLATFORM)'.dependencies]") + { + return Err(CliError::RaSetupActive); + } + rustfmt_test(context)?; success &= cargo_fmt(context, project_root.as_path())?; @@ -75,6 +87,13 @@ pub fn run(check: bool, verbose: bool) { CliError::WalkDirError(err) => { eprintln!("error: {}", err); }, + CliError::RaSetupActive => { + eprintln!( + "error: a local rustc repo is enabled as path dependency via `cargo dev ra-setup`. +Not formatting because that would format the local repo as well! +Please revert the changes to Cargo.tomls first." + ); + }, } } -- cgit 1.4.1-3-g733a5 From 27dc565d28444fa488972e09a8117474cee1e752 Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Sun, 13 Dec 2020 17:01:44 +0100 Subject: cargo dev: rename ra-setup to ra_setup to be in line with the other commands --- CONTRIBUTING.md | 8 ++++---- clippy_dev/src/fmt.rs | 2 +- clippy_dev/src/main.rs | 4 ++-- clippy_dev/src/ra_setup.rs | 2 +- doc/basics.md | 4 ++-- 5 files changed, 10 insertions(+), 10 deletions(-) (limited to 'clippy_dev/src') diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 0a3c602b9e2..49b64da1fb6 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -19,10 +19,10 @@ All contributors are expected to follow the [Rust Code of Conduct]. - [Writing code](#writing-code) - [Getting code-completion for rustc internals to work](#getting-code-completion-for-rustc-internals-to-work) - [How Clippy works](#how-clippy-works) - - [Fixing build failures caused by Rust](#fixing-build-failures-caused-by-rust) + - [Syncing changes between Clippy and [`rust-lang/rust`]](#syncing-changes-between-clippy-and-rust-langrust) - [Patching git-subtree to work with big repos](#patching-git-subtree-to-work-with-big-repos) - - [Performing the sync](#performing-the-sync) - - [Syncing back changes in Clippy to [`rust-lang/rust`]](#syncing-back-changes-in-clippy-to-rust-langrust) + - [Performing the sync from [`rust-lang/rust`] to Clippy](#performing-the-sync-from-rust-langrust-to-clippy) + - [Performing the sync from Clippy to [`rust-lang/rust`]](#performing-the-sync-from-clippy-to-rust-langrust) - [Defining remotes](#defining-remotes) - [Issue and PR triage](#issue-and-pr-triage) - [Bors and Homu](#bors-and-homu) @@ -111,7 +111,7 @@ To work around this, you need to have a copy of the [rustc-repo][rustc_repo] ava `git clone https://github.com/rust-lang/rust/`. Then you can run a `cargo dev` command to automatically make Clippy use the rustc-repo via path-dependencies which rust-analyzer will be able to understand. -Run `cargo dev ra-setup --repo-path ` where `` is an absolute path to the rustc repo +Run `cargo dev ra_setup --repo-path ` where `` is an absolute path to the rustc repo you just cloned. The command will add path-dependencies pointing towards rustc-crates inside the rustc repo to Clippys `Cargo.toml`s and should allow rust-analyzer to understand most of the types that Clippy uses. diff --git a/clippy_dev/src/fmt.rs b/clippy_dev/src/fmt.rs index 6f13af8aa47..6b528d219df 100644 --- a/clippy_dev/src/fmt.rs +++ b/clippy_dev/src/fmt.rs @@ -89,7 +89,7 @@ pub fn run(check: bool, verbose: bool) { }, CliError::RaSetupActive => { eprintln!( - "error: a local rustc repo is enabled as path dependency via `cargo dev ra-setup`. + "error: a local rustc repo is enabled as path dependency via `cargo dev ra_setup`. Not formatting because that would format the local repo as well! Please revert the changes to Cargo.tomls first." ); diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index 5938b788101..4fdae38e3ab 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -35,7 +35,7 @@ fn main() { ("limit_stderr_length", _) => { stderr_length_check::check(); }, - ("ra-setup", Some(matches)) => ra_setup::run(matches.value_of("rustc-repo-path")), + ("ra_setup", Some(matches)) => ra_setup::run(matches.value_of("rustc-repo-path")), ("serve", Some(matches)) => { let port = matches.value_of("port").unwrap().parse().unwrap(); let lint = matches.value_of("lint"); @@ -131,7 +131,7 @@ fn get_clap_config<'a>() -> ArgMatches<'a> { .about("Ensures that stderr files do not grow longer than a certain amount of lines."), ) .subcommand( - SubCommand::with_name("ra-setup") + SubCommand::with_name("ra_setup") .about("Alter dependencies so rust-analyzer can find rustc internals") .arg( Arg::with_name("rustc-repo-path") diff --git a/clippy_dev/src/ra_setup.rs b/clippy_dev/src/ra_setup.rs index 9d9e836cc08..40bf4a9505a 100644 --- a/clippy_dev/src/ra_setup.rs +++ b/clippy_dev/src/ra_setup.rs @@ -52,7 +52,7 @@ fn inject_deps_into_manifest( // do not inject deps if we have aleady done so if cargo_toml.contains("[target.'cfg(NOT_A_PLATFORM)'.dependencies]") { eprintln!( - "cargo dev ra-setup: warning: deps already found inside {}, doing nothing.", + "cargo dev ra_setup: warning: deps already found inside {}, doing nothing.", manifest_path ); return Ok(()); diff --git a/doc/basics.md b/doc/basics.md index dc71f022773..954474a17aa 100644 --- a/doc/basics.md +++ b/doc/basics.md @@ -8,7 +8,7 @@ the codebase take a look at [Adding Lints] or [Common Tools]. [Common Tools]: https://github.com/rust-lang/rust-clippy/blob/master/doc/common_tools_writing_lints.md - [Basics for hacking on Clippy](#basics-for-hacking-on-clippy) - - [Get the code](#get-the-code) + - [Get the Code](#get-the-code) - [Building and Testing](#building-and-testing) - [`cargo dev`](#cargo-dev) - [PR](#pr) @@ -87,7 +87,7 @@ cargo dev update_lints # create a new lint and register it cargo dev new_lint # (experimental) Setup Clippy to work with rust-analyzer -cargo dev ra-setup +cargo dev ra_setup ``` ## PR -- cgit 1.4.1-3-g733a5 From dfb4ea588c2af7633b2d01d2dfa3d6ffc7d07ee7 Mon Sep 17 00:00:00 2001 From: Philipp Hansch Date: Sat, 19 Dec 2020 08:25:42 +0100 Subject: Fix blessing of new reference files Adding of new reference files wasn't handled correctly. It was trying to read a file that didn't exist yet. Instead of unwrapping, we now treat a missing reference file as empty (`Vec::new`). This makes the following conditional work. We then also have to re-read the reference file after it was being copied. This second read is technically the same as in the old shell script, but wasn't really obvious. The shell script did a `-s` test which reads the file. --- clippy_dev/src/bless.rs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/bless.rs b/clippy_dev/src/bless.rs index 8d5c2e95055..645098e4cfc 100644 --- a/clippy_dev/src/bless.rs +++ b/clippy_dev/src/bless.rs @@ -46,13 +46,16 @@ fn update_reference_file(reference_file_path: PathBuf) { } let test_output_file = fs::read(&test_output_path).expect("Unable to read test output file"); - let reference_file = fs::read(&reference_file_path).expect("Unable to read reference file"); + let reference_file = fs::read(&reference_file_path).unwrap_or_default(); if test_output_file != reference_file { // If a test run caused an output file to change, update the reference file println!("updating {}", &relative_reference_file_path.display()); fs::copy(test_output_path, &reference_file_path).expect("Could not update reference file"); + // We need to re-read the file now because it was potentially updated from copying + let reference_file = fs::read(&reference_file_path).unwrap_or_default(); + if reference_file.is_empty() { // If we copied over an empty output file, we remove the now empty reference file println!("removing {}", &relative_reference_file_path.display()); -- cgit 1.4.1-3-g733a5 From dfaea9c9677f97656ad75f6bacd78f8f87e1d339 Mon Sep 17 00:00:00 2001 From: Aleksei Latyshev Date: Fri, 25 Dec 2020 14:45:04 +0300 Subject: lint &PathBuf instead of &Path in PTR_ARG - extract get_only_generic_arg_snippet to improve readability --- clippy_dev/src/ra_setup.rs | 4 ++-- clippy_lints/src/ptr.rs | 60 ++++++++++++++++++++++++++++++++++------------ tests/ui/ptr_arg.rs | 22 +++++++++++++++++ tests/ui/ptr_arg.stderr | 45 +++++++++++++++++++++++++++------- 4 files changed, 106 insertions(+), 25 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/ra_setup.rs b/clippy_dev/src/ra_setup.rs index 40bf4a9505a..5f5048e79e7 100644 --- a/clippy_dev/src/ra_setup.rs +++ b/clippy_dev/src/ra_setup.rs @@ -3,7 +3,7 @@ use std::fs; use std::fs::File; use std::io::prelude::*; -use std::path::PathBuf; +use std::path::{Path, PathBuf}; // This module takes an absolute path to a rustc repo and alters the dependencies to point towards // the respective rustc subcrates instead of using extern crate xyz. @@ -44,7 +44,7 @@ pub fn run(rustc_path: Option<&str>) { } fn inject_deps_into_manifest( - rustc_source_dir: &PathBuf, + rustc_source_dir: &Path, manifest_path: &str, cargo_toml: &str, lib_rs: &str, diff --git a/clippy_lints/src/ptr.rs b/clippy_lints/src/ptr.rs index dcb643a28ae..c494a713631 100644 --- a/clippy_lints/src/ptr.rs +++ b/clippy_lints/src/ptr.rs @@ -182,20 +182,6 @@ fn check_fn(cx: &LateContext<'_>, decl: &FnDecl<'_>, fn_id: HirId, opt_body_id: if let ty::Ref(_, ty, Mutability::Not) = ty.kind() { if is_type_diagnostic_item(cx, ty, sym::vec_type) { - let mut ty_snippet = None; - if_chain! { - if let TyKind::Path(QPath::Resolved(_, ref path)) = walk_ptrs_hir_ty(arg).kind; - if let Some(&PathSegment{args: Some(ref parameters), ..}) = path.segments.last(); - then { - let types: Vec<_> = parameters.args.iter().filter_map(|arg| match arg { - GenericArg::Type(ty) => Some(ty), - _ => None, - }).collect(); - if types.len() == 1 { - ty_snippet = snippet_opt(cx, types[0].span); - } - } - }; if let Some(spans) = get_spans(cx, opt_body_id, idx, &[("clone", ".to_owned()")]) { span_lint_and_then( cx, @@ -204,7 +190,7 @@ fn check_fn(cx: &LateContext<'_>, decl: &FnDecl<'_>, fn_id: HirId, opt_body_id: "writing `&Vec<_>` instead of `&[_]` involves one more reference and cannot be used \ with non-Vec-based slices.", |diag| { - if let Some(ref snippet) = ty_snippet { + if let Some(ref snippet) = get_only_generic_arg_snippet(cx, arg) { diag.span_suggestion( arg.span, "change this to", @@ -247,6 +233,33 @@ fn check_fn(cx: &LateContext<'_>, decl: &FnDecl<'_>, fn_id: HirId, opt_body_id: }, ); } + } else if match_type(cx, ty, &paths::PATH_BUF) { + if let Some(spans) = get_spans(cx, opt_body_id, idx, &[("clone", ".to_path_buf()"), ("as_path", "")]) { + span_lint_and_then( + cx, + PTR_ARG, + arg.span, + "writing `&PathBuf` instead of `&Path` involves a new object where a slice will do.", + |diag| { + diag.span_suggestion( + arg.span, + "change this to", + "&Path".into(), + Applicability::Unspecified, + ); + for (clonespan, suggestion) in spans { + diag.span_suggestion_short( + clonespan, + &snippet_opt(cx, clonespan).map_or("change the call to".into(), |x| { + Cow::Owned(format!("change `{}` to", x)) + }), + suggestion.into(), + Applicability::Unspecified, + ); + } + }, + ); + } } else if match_type(cx, ty, &paths::COW) { if_chain! { if let TyKind::Rptr(_, MutTy { ref ty, ..} ) = arg.kind; @@ -309,6 +322,23 @@ fn check_fn(cx: &LateContext<'_>, decl: &FnDecl<'_>, fn_id: HirId, opt_body_id: } } +fn get_only_generic_arg_snippet(cx: &LateContext<'_>, arg: &Ty<'_>) -> Option { + if_chain! { + if let TyKind::Path(QPath::Resolved(_, ref path)) = walk_ptrs_hir_ty(arg).kind; + if let Some(&PathSegment{args: Some(ref parameters), ..}) = path.segments.last(); + let types: Vec<_> = parameters.args.iter().filter_map(|arg| match arg { + GenericArg::Type(ty) => Some(ty), + _ => None, + }).collect(); + if types.len() == 1; + then { + snippet_opt(cx, types[0].span) + } else { + None + } + } +} + fn get_rptr_lm<'tcx>(ty: &'tcx Ty<'tcx>) -> Option<(&'tcx Lifetime, Mutability, Span)> { if let TyKind::Rptr(ref lt, ref m) = ty.kind { Some((lt, m.mutbl, ty.span)) diff --git a/tests/ui/ptr_arg.rs b/tests/ui/ptr_arg.rs index 541225e6351..e8854fb73d9 100644 --- a/tests/ui/ptr_arg.rs +++ b/tests/ui/ptr_arg.rs @@ -2,6 +2,7 @@ #![warn(clippy::ptr_arg)] use std::borrow::Cow; +use std::path::PathBuf; fn do_vec(x: &Vec) { //Nothing here @@ -21,6 +22,15 @@ fn do_str_mut(x: &mut String) { //Nothing here either } +fn do_path(x: &PathBuf) { + //Nothing here either +} + +fn do_path_mut(x: &mut PathBuf) { + // no error here + //Nothing here either +} + fn main() {} trait Foo { @@ -55,6 +65,14 @@ fn str_cloned(x: &String) -> String { x.clone() } +fn path_cloned(x: &PathBuf) -> PathBuf { + let a = x.clone(); + let b = x.clone(); + let c = b.clone(); + let d = a.clone().clone().clone(); + x.clone() +} + fn false_positive_capacity(x: &Vec, y: &String) { let a = x.capacity(); let b = y.clone(); @@ -87,10 +105,12 @@ impl Foo2 for String { // Check that the allow attribute on parameters is honored mod issue_5644 { use std::borrow::Cow; + use std::path::PathBuf; fn allowed( #[allow(clippy::ptr_arg)] _v: &Vec, #[allow(clippy::ptr_arg)] _s: &String, + #[allow(clippy::ptr_arg)] _p: &PathBuf, #[allow(clippy::ptr_arg)] _c: &Cow<[i32]>, ) { } @@ -100,6 +120,7 @@ mod issue_5644 { fn allowed( #[allow(clippy::ptr_arg)] _v: &Vec, #[allow(clippy::ptr_arg)] _s: &String, + #[allow(clippy::ptr_arg)] _p: &PathBuf, #[allow(clippy::ptr_arg)] _c: &Cow<[i32]>, ) { } @@ -109,6 +130,7 @@ mod issue_5644 { fn allowed( #[allow(clippy::ptr_arg)] _v: &Vec, #[allow(clippy::ptr_arg)] _s: &String, + #[allow(clippy::ptr_arg)] _p: &PathBuf, #[allow(clippy::ptr_arg)] _c: &Cow<[i32]>, ) { } diff --git a/tests/ui/ptr_arg.stderr b/tests/ui/ptr_arg.stderr index 314f23497f9..70d1b2f5258 100644 --- a/tests/ui/ptr_arg.stderr +++ b/tests/ui/ptr_arg.stderr @@ -1,5 +1,5 @@ error: writing `&Vec<_>` instead of `&[_]` involves one more reference and cannot be used with non-Vec-based slices. - --> $DIR/ptr_arg.rs:6:14 + --> $DIR/ptr_arg.rs:7:14 | LL | fn do_vec(x: &Vec) { | ^^^^^^^^^ help: change this to: `&[i64]` @@ -7,19 +7,25 @@ LL | fn do_vec(x: &Vec) { = note: `-D clippy::ptr-arg` implied by `-D warnings` error: writing `&String` instead of `&str` involves a new object where a slice will do. - --> $DIR/ptr_arg.rs:15:14 + --> $DIR/ptr_arg.rs:16:14 | LL | fn do_str(x: &String) { | ^^^^^^^ help: change this to: `&str` +error: writing `&PathBuf` instead of `&Path` involves a new object where a slice will do. + --> $DIR/ptr_arg.rs:25:15 + | +LL | fn do_path(x: &PathBuf) { + | ^^^^^^^^ help: change this to: `&Path` + error: writing `&Vec<_>` instead of `&[_]` involves one more reference and cannot be used with non-Vec-based slices. - --> $DIR/ptr_arg.rs:28:18 + --> $DIR/ptr_arg.rs:38:18 | LL | fn do_vec(x: &Vec); | ^^^^^^^^^ help: change this to: `&[i64]` error: writing `&Vec<_>` instead of `&[_]` involves one more reference and cannot be used with non-Vec-based slices. - --> $DIR/ptr_arg.rs:41:14 + --> $DIR/ptr_arg.rs:51:14 | LL | fn cloned(x: &Vec) -> Vec { | ^^^^^^^^ @@ -38,7 +44,7 @@ LL | x.to_owned() | error: writing `&String` instead of `&str` involves a new object where a slice will do. - --> $DIR/ptr_arg.rs:50:18 + --> $DIR/ptr_arg.rs:60:18 | LL | fn str_cloned(x: &String) -> String { | ^^^^^^^ @@ -60,8 +66,31 @@ help: change `x.clone()` to LL | x.to_string() | +error: writing `&PathBuf` instead of `&Path` involves a new object where a slice will do. + --> $DIR/ptr_arg.rs:68:19 + | +LL | fn path_cloned(x: &PathBuf) -> PathBuf { + | ^^^^^^^^ + | +help: change this to + | +LL | fn path_cloned(x: &Path) -> PathBuf { + | ^^^^^ +help: change `x.clone()` to + | +LL | let a = x.to_path_buf(); + | ^^^^^^^^^^^^^^^ +help: change `x.clone()` to + | +LL | let b = x.to_path_buf(); + | ^^^^^^^^^^^^^^^ +help: change `x.clone()` to + | +LL | x.to_path_buf() + | + error: writing `&String` instead of `&str` involves a new object where a slice will do. - --> $DIR/ptr_arg.rs:58:44 + --> $DIR/ptr_arg.rs:76:44 | LL | fn false_positive_capacity(x: &Vec, y: &String) { | ^^^^^^^ @@ -80,10 +109,10 @@ LL | let c = y; | ^ error: using a reference to `Cow` is not recommended. - --> $DIR/ptr_arg.rs:72:25 + --> $DIR/ptr_arg.rs:90:25 | LL | fn test_cow_with_ref(c: &Cow<[i32]>) {} | ^^^^^^^^^^^ help: change this to: `&[i32]` -error: aborting due to 7 previous errors +error: aborting due to 9 previous errors -- cgit 1.4.1-3-g733a5 From 6b379322686c8b1552b2014ed560822de490cf27 Mon Sep 17 00:00:00 2001 From: Philipp Hansch Date: Thu, 31 Dec 2020 12:49:43 +0100 Subject: Fix blessing of test output in subdirectories The core issue was the usage of `reference_file_path.file_name()`, which provided a non-existent path if the file to be updated was in a subdirectory. Instead we have to provide the whole path after 'tests/ui/' as the 'filename'. This part of the path is called `test_name` in the code now. --- clippy_dev/src/bless.rs | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/bless.rs b/clippy_dev/src/bless.rs index 645098e4cfc..48a2458594c 100644 --- a/clippy_dev/src/bless.rs +++ b/clippy_dev/src/bless.rs @@ -28,15 +28,17 @@ pub fn bless() { .filter_map(Result::ok) .filter(|f| f.path().extension() == Some(OsStr::new("rs"))) .for_each(|f| { - update_reference_file(f.path().with_extension("stdout")); - update_reference_file(f.path().with_extension("stderr")); - update_reference_file(f.path().with_extension("fixed")); + let test_name = f.path().strip_prefix(test_dir).unwrap(); + + update_reference_file(f.path().with_extension("stdout"), test_name.with_extension("stdout")); + update_reference_file(f.path().with_extension("stderr"), test_name.with_extension("stderr")); + update_reference_file(f.path().with_extension("fixed"), test_name.with_extension("fixed")); }); } } -fn update_reference_file(reference_file_path: PathBuf) { - let test_output_path = build_dir().join(PathBuf::from(reference_file_path.file_name().unwrap())); +fn update_reference_file(reference_file_path: PathBuf, test_name: PathBuf) { + let test_output_path = build_dir().join(test_name); let relative_reference_file_path = reference_file_path.strip_prefix(clippy_project_root()).unwrap(); // If compiletest did not write any changes during the test run, -- cgit 1.4.1-3-g733a5 From 69090550cb4e46d75506a200b990e9edf2485fd8 Mon Sep 17 00:00:00 2001 From: Philipp Hansch Date: Thu, 31 Dec 2020 12:53:29 +0100 Subject: s/test_dir/test_suite_dir This should make the code slightly more understandable --- clippy_dev/src/bless.rs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/bless.rs b/clippy_dev/src/bless.rs index 48a2458594c..5f66ff4f30e 100644 --- a/clippy_dev/src/bless.rs +++ b/clippy_dev/src/bless.rs @@ -17,18 +17,18 @@ pub static CARGO_TARGET_DIR: SyncLazy = SyncLazy::new(|| match env::var }); pub fn bless() { - let test_dirs = [ + let test_suite_dirs = [ clippy_project_root().join("tests").join("ui"), clippy_project_root().join("tests").join("ui-toml"), clippy_project_root().join("tests").join("ui-cargo"), ]; - for test_dir in &test_dirs { - WalkDir::new(test_dir) + for test_suite_dir in &test_suite_dirs { + WalkDir::new(test_suite_dir) .into_iter() .filter_map(Result::ok) .filter(|f| f.path().extension() == Some(OsStr::new("rs"))) .for_each(|f| { - let test_name = f.path().strip_prefix(test_dir).unwrap(); + let test_name = f.path().strip_prefix(test_suite_dir).unwrap(); update_reference_file(f.path().with_extension("stdout"), test_name.with_extension("stdout")); update_reference_file(f.path().with_extension("stderr"), test_name.with_extension("stderr")); -- cgit 1.4.1-3-g733a5 From 7acfa4433fbf277b117ef4ff79f9d74725012b24 Mon Sep 17 00:00:00 2001 From: Cameron Steffen Date: Thu, 31 Dec 2020 09:50:23 -0600 Subject: Add ui-internal to cargo dev bless --- clippy_dev/src/bless.rs | 1 + 1 file changed, 1 insertion(+) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/bless.rs b/clippy_dev/src/bless.rs index 5f66ff4f30e..649c06b188a 100644 --- a/clippy_dev/src/bless.rs +++ b/clippy_dev/src/bless.rs @@ -19,6 +19,7 @@ pub static CARGO_TARGET_DIR: SyncLazy = SyncLazy::new(|| match env::var pub fn bless() { let test_suite_dirs = [ clippy_project_root().join("tests").join("ui"), + clippy_project_root().join("tests").join("ui-internal"), clippy_project_root().join("tests").join("ui-toml"), clippy_project_root().join("tests").join("ui-cargo"), ]; -- cgit 1.4.1-3-g733a5 From cbbb188ea9f0795d5ffe8b25734fbe644d40d964 Mon Sep 17 00:00:00 2001 From: Cameron Steffen Date: Thu, 31 Dec 2020 10:50:00 -0600 Subject: Bless only updated since clippy build --- clippy_dev/src/bless.rs | 36 +++++++++++++++++++++++++++++------- clippy_dev/src/main.rs | 14 +++++++++++--- 2 files changed, 40 insertions(+), 10 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/bless.rs b/clippy_dev/src/bless.rs index 5f66ff4f30e..529f1161a0f 100644 --- a/clippy_dev/src/bless.rs +++ b/clippy_dev/src/bless.rs @@ -5,7 +5,7 @@ use std::env; use std::ffi::OsStr; use std::fs; use std::lazy::SyncLazy; -use std::path::PathBuf; +use std::path::{Path, PathBuf}; use walkdir::WalkDir; use crate::clippy_project_root; @@ -16,7 +16,15 @@ pub static CARGO_TARGET_DIR: SyncLazy = SyncLazy::new(|| match env::var None => env::current_dir().unwrap().join("target"), }); -pub fn bless() { +static CLIPPY_BUILD_TIME: SyncLazy> = SyncLazy::new(|| { + let profile = env::var("PROFILE").unwrap_or_else(|_| "debug".to_string()); + let mut path = PathBuf::from(&**CARGO_TARGET_DIR); + path.push(profile); + path.push("cargo-clippy"); + fs::metadata(path).ok()?.modified().ok() +}); + +pub fn bless(ignore_timestamp: bool) { let test_suite_dirs = [ clippy_project_root().join("tests").join("ui"), clippy_project_root().join("tests").join("ui-toml"), @@ -29,15 +37,18 @@ pub fn bless() { .filter(|f| f.path().extension() == Some(OsStr::new("rs"))) .for_each(|f| { let test_name = f.path().strip_prefix(test_suite_dir).unwrap(); - - update_reference_file(f.path().with_extension("stdout"), test_name.with_extension("stdout")); - update_reference_file(f.path().with_extension("stderr"), test_name.with_extension("stderr")); - update_reference_file(f.path().with_extension("fixed"), test_name.with_extension("fixed")); + for &ext in &["stdout", "stderr", "fixed"] { + update_reference_file( + f.path().with_extension(ext), + test_name.with_extension(ext), + ignore_timestamp, + ); + } }); } } -fn update_reference_file(reference_file_path: PathBuf, test_name: PathBuf) { +fn update_reference_file(reference_file_path: PathBuf, test_name: PathBuf, ignore_timestamp: bool) { let test_output_path = build_dir().join(test_name); let relative_reference_file_path = reference_file_path.strip_prefix(clippy_project_root()).unwrap(); @@ -47,6 +58,11 @@ fn update_reference_file(reference_file_path: PathBuf, test_name: PathBuf) { return; } + // If the test output was not updated since the last clippy build, it may be outdated + if !ignore_timestamp && !updated_since_clippy_build(&test_output_path).unwrap_or(true) { + return; + } + let test_output_file = fs::read(&test_output_path).expect("Unable to read test output file"); let reference_file = fs::read(&reference_file_path).unwrap_or_default(); @@ -66,6 +82,12 @@ fn update_reference_file(reference_file_path: PathBuf, test_name: PathBuf) { } } +fn updated_since_clippy_build(path: &Path) -> Option { + let clippy_build_time = (*CLIPPY_BUILD_TIME)?; + let modified = fs::metadata(path).ok()?.modified().ok()?; + Some(modified >= clippy_build_time) +} + fn build_dir() -> PathBuf { let profile = env::var("PROFILE").unwrap_or_else(|_| "debug".to_string()); let mut path = PathBuf::new(); diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index 4fdae38e3ab..2ea56c42faf 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -7,8 +7,8 @@ fn main() { let matches = get_clap_config(); match matches.subcommand() { - ("bless", Some(_)) => { - bless::bless(); + ("bless", Some(matches)) => { + bless::bless(matches.is_present("ignore-timestamp")); }, ("fmt", Some(matches)) => { fmt::run(matches.is_present("check"), matches.is_present("verbose")); @@ -47,7 +47,15 @@ fn main() { fn get_clap_config<'a>() -> ArgMatches<'a> { App::new("Clippy developer tooling") - .subcommand(SubCommand::with_name("bless").about("bless the test output changes")) + .subcommand( + SubCommand::with_name("bless") + .about("bless the test output changes") + .arg( + Arg::with_name("ignore-timestamp") + .long("ignore-timestamp") + .help("Include files updated before clippy was built"), + ), + ) .subcommand( SubCommand::with_name("fmt") .about("Run rustfmt on all projects and tests") -- cgit 1.4.1-3-g733a5 From a22915bf4893e16d64100365d902e52211374a0c Mon Sep 17 00:00:00 2001 From: Cameron Steffen Date: Mon, 14 Dec 2020 14:03:11 -0600 Subject: Remove unneeded allow's --- clippy_dev/src/ra_setup.rs | 2 -- clippy_lints/src/loops.rs | 1 - 2 files changed, 3 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/ra_setup.rs b/clippy_dev/src/ra_setup.rs index 5f5048e79e7..a8a6a2cb1bd 100644 --- a/clippy_dev/src/ra_setup.rs +++ b/clippy_dev/src/ra_setup.rs @@ -1,5 +1,3 @@ -#![allow(clippy::filter_map)] - use std::fs; use std::fs::File; use std::io::prelude::*; diff --git a/clippy_lints/src/loops.rs b/clippy_lints/src/loops.rs index 1c5ab2874b0..c7e1088e353 100644 --- a/clippy_lints/src/loops.rs +++ b/clippy_lints/src/loops.rs @@ -1069,7 +1069,6 @@ fn get_assignments<'a: 'c, 'tcx: 'c, 'c>( ) -> impl Iterator, &'tcx Expr<'tcx>)>> + 'c { // As the `filter` and `map` below do different things, I think putting together // just increases complexity. (cc #3188 and #4193) - #[allow(clippy::filter_map)] stmts .iter() .filter_map(move |stmt| match stmt.kind { -- cgit 1.4.1-3-g733a5 From bec916d02dc3e330e0dc055080207d708978b41d Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Fri, 18 Dec 2020 13:21:13 +0100 Subject: cargo dev crater: lay out the base plan --- clippy_dev/src/crater.rs | 69 ++++++++++++++++++++++++++++++++++++++++++++++++ clippy_dev/src/lib.rs | 1 + 2 files changed, 70 insertions(+) create mode 100644 clippy_dev/src/crater.rs (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/crater.rs b/clippy_dev/src/crater.rs new file mode 100644 index 00000000000..fe0fc440316 --- /dev/null +++ b/clippy_dev/src/crater.rs @@ -0,0 +1,69 @@ +use std::path::PathBuf; +use std::process::Command; + +// represents an archive we download from crates.io +struct KrateSource { + version: String, + name: String, +} + +// represents the extracted sourcecode of a crate +struct Krate { + version: String, + name: String, +} + +impl KrateSource { + fn new(version: &str, name: &str) -> Self { + KrateSource { + version: version.into(), + name: name.into(), + } + } + fn download_and_extract(self) -> Krate { + // download + // extract + + Krate { + version: self.version, + name: self.name, + } + } +} + +impl Krate { + fn run_clippy_lints(&self) -> String { + todo!(); + } + + +} + +fn build_clippy() { + Command::new("cargo") + .arg("build") + .output() + .expect("Failed to build clippy!"); +} + +// the main fn +pub(crate) fn run() { + let cargo_clippy_path: PathBuf = PathBuf::from("target/debug/cargo-clippy"); + let clippy_driver_path: PathBuf = PathBuf::from("target/debug/cargo-driver"); + + // crates we want to check: + let krates: Vec = vec![KrateSource::new("cargo", "0.49.0"), KrateSource::new("regex", "1.4.2")]; + + build_clippy(); + // assert that clippy is found + assert!( + cargo_clippy_path.is_file(), + "target/debug/cargo-clippy binary not found!" + ); + assert!( + clippy_driver_path.is_file(), + "target/debug/clippy-driver binary not found!" + ); + + let clippy_lint_results: Vec = krates.into_iter().map(|krate| krate.download_and_extract()).map(|krate| krate.run_clippy_lints()).collect::>(); +} diff --git a/clippy_dev/src/lib.rs b/clippy_dev/src/lib.rs index 17cc08ee10f..4873769b367 100644 --- a/clippy_dev/src/lib.rs +++ b/clippy_dev/src/lib.rs @@ -11,6 +11,7 @@ use std::path::{Path, PathBuf}; use walkdir::WalkDir; pub mod bless; +pub mod crater; pub mod fmt; pub mod new_lint; pub mod ra_setup; -- cgit 1.4.1-3-g733a5 From 5353591b1bc7e4fcb886afcd7944619607adb5cb Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Fri, 18 Dec 2020 14:14:15 +0100 Subject: cargo dev crater: work on downloading and extracting crate sources --- clippy_dev/Cargo.toml | 7 +++++-- clippy_dev/src/crater.rs | 39 +++++++++++++++++++++++++++++++++------ 2 files changed, 38 insertions(+), 8 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/Cargo.toml b/clippy_dev/Cargo.toml index b8a4a20114b..517e9d250bc 100644 --- a/clippy_dev/Cargo.toml +++ b/clippy_dev/Cargo.toml @@ -1,16 +1,19 @@ [package] -name = "clippy_dev" -version = "0.0.1" authors = ["Philipp Hansch "] edition = "2018" +name = "clippy_dev" +version = "0.0.1" [dependencies] bytecount = "0.6" clap = "2.33" +flate2 = "1.0.19" itertools = "0.9" opener = "0.4" regex = "1" shell-escape = "0.1" +tar = "0.4.30" +ureq = "2.0.0-rc3" walkdir = "2" [features] diff --git a/clippy_dev/src/crater.rs b/clippy_dev/src/crater.rs index fe0fc440316..22b04242885 100644 --- a/clippy_dev/src/crater.rs +++ b/clippy_dev/src/crater.rs @@ -2,15 +2,18 @@ use std::path::PathBuf; use std::process::Command; // represents an archive we download from crates.io +#[derive(Debug)] struct KrateSource { version: String, name: String, } // represents the extracted sourcecode of a crate +#[derive(Debug)] struct Krate { version: String, name: String, + path: PathBuf, } impl KrateSource { @@ -20,13 +23,34 @@ impl KrateSource { name: name.into(), } } - fn download_and_extract(self) -> Krate { + fn download_and_extract(&self) -> Krate { + let extract_dir = PathBuf::from("target/crater/crates"); + // download + let krate_download_dir = PathBuf::from("target/crater/downloads"); + + let url = format!( + "https://crates.io/api/v1/crates/{}/{}/download", + self.name, self.version + ); + print!("Downloading {}, {}", self.name, self.version); + + let krate_name = format!("{}-{}.crate", &self.name, &self.version); + let mut krate_dest = std::fs::File::create(krate_download_dir.join(krate_name)).unwrap(); + let mut krate_req = ureq::get(&url).call().unwrap().into_reader(); + std::io::copy(&mut krate_req, &mut krate_dest).unwrap(); + // extract + let krate = krate_dest; + let tar = flate2::read::GzDecoder::new(krate); + let mut archiv = tar::Archive::new(tar); + let extracted_path = extract_dir.join(format!("{}-{}/", self.name, self.version)); + archiv.unpack(&extracted_path).expect("Failed to extract!"); Krate { - version: self.version, - name: self.name, + version: self.version.clone(), + name: self.name.clone(), + path: extracted_path, } } } @@ -35,8 +59,6 @@ impl Krate { fn run_clippy_lints(&self) -> String { todo!(); } - - } fn build_clippy() { @@ -65,5 +87,10 @@ pub(crate) fn run() { "target/debug/clippy-driver binary not found!" ); - let clippy_lint_results: Vec = krates.into_iter().map(|krate| krate.download_and_extract()).map(|krate| krate.run_clippy_lints()).collect::>(); + // download and extract the crates, then run clippy on them and collect clippys warnings + let clippy_lint_results: Vec = krates + .into_iter() + .map(|krate| krate.download_and_extract()) + .map(|krate| krate.run_clippy_lints()) + .collect::>(); } -- cgit 1.4.1-3-g733a5 From 30d85942cf4fee5148a6b994c9ec8bd1190a5122 Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Fri, 18 Dec 2020 14:28:59 +0100 Subject: crater: hook into main.rs --- clippy_dev/src/crater.rs | 4 ++-- clippy_dev/src/main.rs | 6 +++++- 2 files changed, 7 insertions(+), 3 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/crater.rs b/clippy_dev/src/crater.rs index 22b04242885..1cf12941c35 100644 --- a/clippy_dev/src/crater.rs +++ b/clippy_dev/src/crater.rs @@ -69,7 +69,7 @@ fn build_clippy() { } // the main fn -pub(crate) fn run() { +pub fn run() { let cargo_clippy_path: PathBuf = PathBuf::from("target/debug/cargo-clippy"); let clippy_driver_path: PathBuf = PathBuf::from("target/debug/cargo-driver"); @@ -88,7 +88,7 @@ pub(crate) fn run() { ); // download and extract the crates, then run clippy on them and collect clippys warnings - let clippy_lint_results: Vec = krates + let _clippy_lint_results: Vec = krates .into_iter() .map(|krate| krate.download_and_extract()) .map(|krate| krate.run_clippy_lints()) diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index 2ea56c42faf..6fb8b6f2899 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -1,7 +1,7 @@ #![cfg_attr(feature = "deny-warnings", deny(warnings))] use clap::{App, Arg, ArgMatches, SubCommand}; -use clippy_dev::{bless, fmt, new_lint, ra_setup, serve, stderr_length_check, update_lints}; +use clippy_dev::{bless, crater, fmt, new_lint, ra_setup, serve, stderr_length_check, update_lints}; fn main() { let matches = get_clap_config(); @@ -10,6 +10,9 @@ fn main() { ("bless", Some(matches)) => { bless::bless(matches.is_present("ignore-timestamp")); }, + ("crater", Some(_)) => { + crater::run(); + }, ("fmt", Some(matches)) => { fmt::run(matches.is_present("check"), matches.is_present("verbose")); }, @@ -56,6 +59,7 @@ fn get_clap_config<'a>() -> ArgMatches<'a> { .help("Include files updated before clippy was built"), ), ) + .subcommand(SubCommand::with_name("crater").about("run clippy on a set of crates and check output")) .subcommand( SubCommand::with_name("fmt") .about("Run rustfmt on all projects and tests") -- cgit 1.4.1-3-g733a5 From 63176834c2a9cc6718a4e7b20238b607331f1f1d Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Fri, 18 Dec 2020 16:17:53 +0100 Subject: cargo dev crater: fixes and debug prints --- clippy_dev/src/crater.rs | 28 ++++++++++++++++++---------- 1 file changed, 18 insertions(+), 10 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/crater.rs b/clippy_dev/src/crater.rs index 1cf12941c35..cade6c38bc1 100644 --- a/clippy_dev/src/crater.rs +++ b/clippy_dev/src/crater.rs @@ -17,7 +17,7 @@ struct Krate { } impl KrateSource { - fn new(version: &str, name: &str) -> Self { + fn new(name: &str, version: &str) -> Self { KrateSource { version: version.into(), name: name.into(), @@ -33,19 +33,24 @@ impl KrateSource { "https://crates.io/api/v1/crates/{}/{}/download", self.name, self.version ); - print!("Downloading {}, {}", self.name, self.version); + println!("Downloading {}, {} / {}", self.name, self.version, url); + std::fs::create_dir("target/crater/").unwrap(); - let krate_name = format!("{}-{}.crate", &self.name, &self.version); + std::fs::create_dir(&krate_download_dir).unwrap(); + std::fs::create_dir(&extract_dir).unwrap(); + + let krate_name = format!("{}-{}.crate.tar.gz", &self.name, &self.version); let mut krate_dest = std::fs::File::create(krate_download_dir.join(krate_name)).unwrap(); let mut krate_req = ureq::get(&url).call().unwrap().into_reader(); std::io::copy(&mut krate_req, &mut krate_dest).unwrap(); - - // extract let krate = krate_dest; - let tar = flate2::read::GzDecoder::new(krate); + dbg!(&krate); + let tar = flate2::read::GzDecoder::new(&krate); let mut archiv = tar::Archive::new(tar); - let extracted_path = extract_dir.join(format!("{}-{}/", self.name, self.version)); + let extracted_path = extract_dir.join(format!("{}-{}", self.name, self.version)); + // println!("ar: p: {:?}", &krate, extracted_path); archiv.unpack(&extracted_path).expect("Failed to extract!"); + // extract Krate { version: self.version.clone(), @@ -71,20 +76,23 @@ fn build_clippy() { // the main fn pub fn run() { let cargo_clippy_path: PathBuf = PathBuf::from("target/debug/cargo-clippy"); - let clippy_driver_path: PathBuf = PathBuf::from("target/debug/cargo-driver"); + let clippy_driver_path: PathBuf = PathBuf::from("target/debug/clippy-driver"); // crates we want to check: let krates: Vec = vec![KrateSource::new("cargo", "0.49.0"), KrateSource::new("regex", "1.4.2")]; + println!("Compiling clippy..."); build_clippy(); + println!("Done compiling"); + // assert that clippy is found assert!( cargo_clippy_path.is_file(), - "target/debug/cargo-clippy binary not found!" + "target/debug/cargo-clippy binary not found! {}", cargo_clippy_path.display() ); assert!( clippy_driver_path.is_file(), - "target/debug/clippy-driver binary not found!" + "target/debug/clippy-driver binary not found! {}", clippy_driver_path.display() ); // download and extract the crates, then run clippy on them and collect clippys warnings -- cgit 1.4.1-3-g733a5 From e69147486ecf0335176fedfca4914a6161436293 Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Fri, 18 Dec 2020 16:53:18 +0100 Subject: cargo clippy dev: fix extraction of downloaded crates --- clippy_dev/src/crater.rs | 34 +++++++++++++++++++--------------- 1 file changed, 19 insertions(+), 15 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/crater.rs b/clippy_dev/src/crater.rs index cade6c38bc1..b18c4edc236 100644 --- a/clippy_dev/src/crater.rs +++ b/clippy_dev/src/crater.rs @@ -34,28 +34,30 @@ impl KrateSource { self.name, self.version ); println!("Downloading {}, {} / {}", self.name, self.version, url); - std::fs::create_dir("target/crater/").unwrap(); + let _ = std::fs::create_dir("target/crater/"); - std::fs::create_dir(&krate_download_dir).unwrap(); - std::fs::create_dir(&extract_dir).unwrap(); + let _ = std::fs::create_dir(&krate_download_dir); + let _ = std::fs::create_dir(&extract_dir); let krate_name = format!("{}-{}.crate.tar.gz", &self.name, &self.version); - let mut krate_dest = std::fs::File::create(krate_download_dir.join(krate_name)).unwrap(); + let krate_file_path = krate_download_dir.join(krate_name); + let mut krate_dest = std::fs::File::create(&krate_file_path).unwrap(); let mut krate_req = ureq::get(&url).call().unwrap().into_reader(); std::io::copy(&mut krate_req, &mut krate_dest).unwrap(); - let krate = krate_dest; - dbg!(&krate); - let tar = flate2::read::GzDecoder::new(&krate); - let mut archiv = tar::Archive::new(tar); - let extracted_path = extract_dir.join(format!("{}-{}", self.name, self.version)); - // println!("ar: p: {:?}", &krate, extracted_path); - archiv.unpack(&extracted_path).expect("Failed to extract!"); - // extract + // unzip the tarball + let dl = std::fs::File::open(krate_file_path).unwrap(); + + let ungz_tar = flate2::read::GzDecoder::new(dl); + // extract the tar archive + let mut archiv = tar::Archive::new(ungz_tar); + let extract_path = extract_dir.join(format!("{}-{}/", self.name, self.version)); + archiv.unpack(&extract_path).expect("Failed to extract!"); + // extracted Krate { version: self.version.clone(), name: self.name.clone(), - path: extracted_path, + path: extract_path, } } } @@ -88,11 +90,13 @@ pub fn run() { // assert that clippy is found assert!( cargo_clippy_path.is_file(), - "target/debug/cargo-clippy binary not found! {}", cargo_clippy_path.display() + "target/debug/cargo-clippy binary not found! {}", + cargo_clippy_path.display() ); assert!( clippy_driver_path.is_file(), - "target/debug/clippy-driver binary not found! {}", clippy_driver_path.display() + "target/debug/clippy-driver binary not found! {}", + clippy_driver_path.display() ); // download and extract the crates, then run clippy on them and collect clippys warnings -- cgit 1.4.1-3-g733a5 From 69c0757334806f0cd0bf680428959723b042555b Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Fri, 18 Dec 2020 17:25:07 +0100 Subject: clippy cargo dev: fix checking of crates --- clippy_dev/src/crater.rs | 25 +++++++++++++++++-------- 1 file changed, 17 insertions(+), 8 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/crater.rs b/clippy_dev/src/crater.rs index b18c4edc236..d7ed95dfe86 100644 --- a/clippy_dev/src/crater.rs +++ b/clippy_dev/src/crater.rs @@ -50,21 +50,30 @@ impl KrateSource { let ungz_tar = flate2::read::GzDecoder::new(dl); // extract the tar archive let mut archiv = tar::Archive::new(ungz_tar); - let extract_path = extract_dir.join(format!("{}-{}/", self.name, self.version)); + let extract_path = extract_dir.clone(); archiv.unpack(&extract_path).expect("Failed to extract!"); // extracted - + dbg!(&extract_path); Krate { version: self.version.clone(), name: self.name.clone(), - path: extract_path, + path: extract_dir.join(format!("{}-{}/", self.name, self.version)) } } } impl Krate { - fn run_clippy_lints(&self) -> String { - todo!(); + fn run_clippy_lints(&self, cargo_clippy_path: &PathBuf) -> String { + let cargo_clippy_path = std::fs::canonicalize(cargo_clippy_path).unwrap(); + let project_root = &self.path; + dbg!(&cargo_clippy_path); + dbg!(&project_root); + + let output = std::process::Command::new(cargo_clippy_path).current_dir(project_root).output(); + dbg!(&output); + let output = String::from_utf8_lossy(&output.unwrap().stderr).into_owned(); + dbg!(&output); + output } } @@ -81,7 +90,7 @@ pub fn run() { let clippy_driver_path: PathBuf = PathBuf::from("target/debug/clippy-driver"); // crates we want to check: - let krates: Vec = vec![KrateSource::new("cargo", "0.49.0"), KrateSource::new("regex", "1.4.2")]; + let krates: Vec = vec![KrateSource::new("regex", "1.4.2"), KrateSource::new("cargo", "0.49.0"), ]; println!("Compiling clippy..."); build_clippy(); @@ -97,12 +106,12 @@ pub fn run() { clippy_driver_path.is_file(), "target/debug/clippy-driver binary not found! {}", clippy_driver_path.display() - ); + ); // download and extract the crates, then run clippy on them and collect clippys warnings let _clippy_lint_results: Vec = krates .into_iter() .map(|krate| krate.download_and_extract()) - .map(|krate| krate.run_clippy_lints()) + .map(|krate| krate.run_clippy_lints(&cargo_clippy_path)) .collect::>(); } -- cgit 1.4.1-3-g733a5 From 2360a7cad05242ae161a6903d03085c57aa1a099 Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Fri, 18 Dec 2020 18:01:45 +0100 Subject: cargo clippy dev: collecting one-line clippy warnings works now --- clippy_dev/src/crater.rs | 23 ++++++++++++++--------- 1 file changed, 14 insertions(+), 9 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/crater.rs b/clippy_dev/src/crater.rs index d7ed95dfe86..3ac62f7ebc7 100644 --- a/clippy_dev/src/crater.rs +++ b/clippy_dev/src/crater.rs @@ -57,22 +57,26 @@ impl KrateSource { Krate { version: self.version.clone(), name: self.name.clone(), - path: extract_dir.join(format!("{}-{}/", self.name, self.version)) + path: extract_dir.join(format!("{}-{}/", self.name, self.version)), } } } impl Krate { - fn run_clippy_lints(&self, cargo_clippy_path: &PathBuf) -> String { + fn run_clippy_lints(&self, cargo_clippy_path: &PathBuf) -> String { let cargo_clippy_path = std::fs::canonicalize(cargo_clippy_path).unwrap(); let project_root = &self.path; dbg!(&cargo_clippy_path); dbg!(&project_root); - let output = std::process::Command::new(cargo_clippy_path).current_dir(project_root).output(); - dbg!(&output); - let output = String::from_utf8_lossy(&output.unwrap().stderr).into_owned(); - dbg!(&output); + let output = std::process::Command::new(cargo_clippy_path) + .args(&["--", "--message-format=short","--", "--cap-lints=warn",]) + .current_dir(project_root) + .output(); + let output: String = String::from_utf8_lossy(&output.unwrap().stderr).lines().filter(|line|line.contains(": warning: ")).collect(); + // output.lines().for_each(|l| println!("{}", l)); + //dbg!(&output); + output } } @@ -90,7 +94,7 @@ pub fn run() { let clippy_driver_path: PathBuf = PathBuf::from("target/debug/clippy-driver"); // crates we want to check: - let krates: Vec = vec![KrateSource::new("regex", "1.4.2"), KrateSource::new("cargo", "0.49.0"), ]; + let krates: Vec = vec![KrateSource::new("regex", "1.4.2"), KrateSource::new("cargo", "0.49.0")]; println!("Compiling clippy..."); build_clippy(); @@ -106,12 +110,13 @@ pub fn run() { clippy_driver_path.is_file(), "target/debug/clippy-driver binary not found! {}", clippy_driver_path.display() - ); + ); // download and extract the crates, then run clippy on them and collect clippys warnings - let _clippy_lint_results: Vec = krates + let clippy_lint_results: Vec = krates .into_iter() .map(|krate| krate.download_and_extract()) .map(|krate| krate.run_clippy_lints(&cargo_clippy_path)) .collect::>(); + dbg!(clippy_lint_results); } -- cgit 1.4.1-3-g733a5 From 734d2052df123db0ed0ff05a7ab0f0d9271d18c5 Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Fri, 18 Dec 2020 18:34:09 +0100 Subject: print all clippy warnings in the end --- clippy_dev/src/crater.rs | 29 +++++++++++++++++++---------- 1 file changed, 19 insertions(+), 10 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/crater.rs b/clippy_dev/src/crater.rs index 3ac62f7ebc7..6b121a79e37 100644 --- a/clippy_dev/src/crater.rs +++ b/clippy_dev/src/crater.rs @@ -63,20 +63,26 @@ impl KrateSource { } impl Krate { - fn run_clippy_lints(&self, cargo_clippy_path: &PathBuf) -> String { + fn run_clippy_lints(&self, cargo_clippy_path: &PathBuf) -> Vec { let cargo_clippy_path = std::fs::canonicalize(cargo_clippy_path).unwrap(); let project_root = &self.path; dbg!(&cargo_clippy_path); dbg!(&project_root); let output = std::process::Command::new(cargo_clippy_path) - .args(&["--", "--message-format=short","--", "--cap-lints=warn",]) + .args(&["--", "--message-format=short", "--", "--cap-lints=warn"]) .current_dir(project_root) - .output(); - let output: String = String::from_utf8_lossy(&output.unwrap().stderr).lines().filter(|line|line.contains(": warning: ")).collect(); - // output.lines().for_each(|l| println!("{}", l)); - //dbg!(&output); - + .output() + .unwrap(); + let mut output = String::from_utf8_lossy(&output.stderr); + let output: Vec<&str> = output.lines().collect(); + let mut output: Vec = output + .into_iter() + .filter(|line| line.contains(": warning: ")) + .map(|l| l.to_string()) + .collect(); + + output.sort(); output } } @@ -113,10 +119,13 @@ pub fn run() { ); // download and extract the crates, then run clippy on them and collect clippys warnings - let clippy_lint_results: Vec = krates + let clippy_lint_results: Vec> = krates .into_iter() .map(|krate| krate.download_and_extract()) .map(|krate| krate.run_clippy_lints(&cargo_clippy_path)) - .collect::>(); - dbg!(clippy_lint_results); + .collect(); + + let results: Vec = clippy_lint_results.into_iter().flatten().collect(); + + results.iter().for_each(|l| println!("{}", l)); } -- cgit 1.4.1-3-g733a5 From 73141337223bfa55d03f2d1097af6a036a6cbbc5 Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Fri, 18 Dec 2020 20:58:46 +0100 Subject: cargo dev crater: cleanup, don't re-download and reextract crates on every run --- clippy_dev/src/crater.rs | 88 ++++++++++++++++++++++++++++-------------------- 1 file changed, 52 insertions(+), 36 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/crater.rs b/clippy_dev/src/crater.rs index 6b121a79e37..63c04f9a1f1 100644 --- a/clippy_dev/src/crater.rs +++ b/clippy_dev/src/crater.rs @@ -13,6 +13,7 @@ struct KrateSource { struct Krate { version: String, name: String, + // path to the extracted sources that clippy can check path: PathBuf, } @@ -23,37 +24,44 @@ impl KrateSource { name: name.into(), } } + fn download_and_extract(&self) -> Krate { let extract_dir = PathBuf::from("target/crater/crates"); - - // download let krate_download_dir = PathBuf::from("target/crater/downloads"); + // url to download the crate from crates.io let url = format!( "https://crates.io/api/v1/crates/{}/{}/download", self.name, self.version ); - println!("Downloading {}, {} / {}", self.name, self.version, url); + println!("Downloading and extracting {} {} from {}", self.name, self.version, url); let _ = std::fs::create_dir("target/crater/"); - let _ = std::fs::create_dir(&krate_download_dir); let _ = std::fs::create_dir(&extract_dir); - let krate_name = format!("{}-{}.crate.tar.gz", &self.name, &self.version); - let krate_file_path = krate_download_dir.join(krate_name); - let mut krate_dest = std::fs::File::create(&krate_file_path).unwrap(); - let mut krate_req = ureq::get(&url).call().unwrap().into_reader(); - std::io::copy(&mut krate_req, &mut krate_dest).unwrap(); - // unzip the tarball - let dl = std::fs::File::open(krate_file_path).unwrap(); - - let ungz_tar = flate2::read::GzDecoder::new(dl); - // extract the tar archive - let mut archiv = tar::Archive::new(ungz_tar); - let extract_path = extract_dir.clone(); - archiv.unpack(&extract_path).expect("Failed to extract!"); - // extracted - dbg!(&extract_path); + let krate_file_path = krate_download_dir.join(format!("{}-{}.crate.tar.gz", &self.name, &self.version)); + // don't download/extract if we already have done so + if !krate_file_path.is_file() { + // create a file path to download and write the crate data into + let mut krate_dest = std::fs::File::create(&krate_file_path).unwrap(); + let mut krate_req = ureq::get(&url).call().unwrap().into_reader(); + // copy the crate into the file + std::io::copy(&mut krate_req, &mut krate_dest).unwrap(); + + // unzip the tarball + let ungz_tar = flate2::read::GzDecoder::new(std::fs::File::open(&krate_file_path).unwrap()); + // extract the tar archive + let mut archiv = tar::Archive::new(ungz_tar); + archiv.unpack(&extract_dir).expect("Failed to extract!"); + + // unzip the tarball + let ungz_tar = flate2::read::GzDecoder::new(std::fs::File::open(&krate_file_path).unwrap()); + // extract the tar archive + let mut archiv = tar::Archive::new(ungz_tar); + archiv.unpack(&extract_dir).expect("Failed to extract!"); + } + // crate is extracted, return a new Krate object which contains the path to the extracted + // sources that clippy can check Krate { version: self.version.clone(), name: self.name.clone(), @@ -64,24 +72,37 @@ impl KrateSource { impl Krate { fn run_clippy_lints(&self, cargo_clippy_path: &PathBuf) -> Vec { + println!("Linting {} {}...", &self.name, &self.version); let cargo_clippy_path = std::fs::canonicalize(cargo_clippy_path).unwrap(); - let project_root = &self.path; - dbg!(&cargo_clippy_path); - dbg!(&project_root); - let output = std::process::Command::new(cargo_clippy_path) + let all_output = std::process::Command::new(cargo_clippy_path) + // lint warnings will look like this: + // src/cargo/ops/cargo_compile.rs:127:35: warning: usage of `FromIterator::from_iter` .args(&["--", "--message-format=short", "--", "--cap-lints=warn"]) - .current_dir(project_root) + .current_dir(&self.path) .output() .unwrap(); - let mut output = String::from_utf8_lossy(&output.stderr); - let output: Vec<&str> = output.lines().collect(); - let mut output: Vec = output + let stderr = String::from_utf8_lossy(&all_output.stderr); + let output_lines = stderr.lines(); + let mut output: Vec = output_lines .into_iter() .filter(|line| line.contains(": warning: ")) - .map(|l| l.to_string()) + // prefix with the crate name and version + // cargo-0.49.0/src/cargo/ops/cargo_compile.rs:127:35: warning: usage of `FromIterator::from_iter` + .map(|line| format!("{}-{}/{}", self.name, self.version, line)) + // remove the "warning: " + .map(|line| { + let remove_pat = "warning: "; + let pos = line + .find(&remove_pat) + .expect("clippy output did not contain \"warning: \""); + let mut new = line[0..pos].to_string(); + new.push_str(&line[pos + remove_pat.len()..]); + new + }) .collect(); + // sort messages alphabtically to avoid noise in the logs output.sort(); output } @@ -97,7 +118,6 @@ fn build_clippy() { // the main fn pub fn run() { let cargo_clippy_path: PathBuf = PathBuf::from("target/debug/cargo-clippy"); - let clippy_driver_path: PathBuf = PathBuf::from("target/debug/clippy-driver"); // crates we want to check: let krates: Vec = vec![KrateSource::new("regex", "1.4.2"), KrateSource::new("cargo", "0.49.0")]; @@ -112,11 +132,6 @@ pub fn run() { "target/debug/cargo-clippy binary not found! {}", cargo_clippy_path.display() ); - assert!( - clippy_driver_path.is_file(), - "target/debug/clippy-driver binary not found! {}", - clippy_driver_path.display() - ); // download and extract the crates, then run clippy on them and collect clippys warnings let clippy_lint_results: Vec> = krates @@ -125,7 +140,8 @@ pub fn run() { .map(|krate| krate.run_clippy_lints(&cargo_clippy_path)) .collect(); - let results: Vec = clippy_lint_results.into_iter().flatten().collect(); + let all_warnings: Vec = clippy_lint_results.into_iter().flatten().collect(); - results.iter().for_each(|l| println!("{}", l)); + // TODO: save these into a file + all_warnings.iter().for_each(|l| println!("{}", l)); } -- cgit 1.4.1-3-g733a5 From dbb8c0020e76e448f96b1b346dab5afd0d08ce40 Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Fri, 18 Dec 2020 21:26:41 +0100 Subject: cargo dev crater: save all warnings into a file --- clippy_dev/src/crater.rs | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/crater.rs b/clippy_dev/src/crater.rs index 63c04f9a1f1..3fb130cc594 100644 --- a/clippy_dev/src/crater.rs +++ b/clippy_dev/src/crater.rs @@ -98,6 +98,7 @@ impl Krate { .expect("clippy output did not contain \"warning: \""); let mut new = line[0..pos].to_string(); new.push_str(&line[pos + remove_pat.len()..]); + new.push('\n'); new }) .collect(); @@ -142,6 +143,7 @@ pub fn run() { let all_warnings: Vec = clippy_lint_results.into_iter().flatten().collect(); - // TODO: save these into a file - all_warnings.iter().for_each(|l| println!("{}", l)); + // save the text into mini-crater/logs.txt + let text = all_warnings.join(""); + std::fs::write("mini-crater/logs.txt", text).unwrap(); } -- cgit 1.4.1-3-g733a5 From 1e5ac1dfd215f554c5b7980c21fb7eda5f4c526e Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Fri, 18 Dec 2020 21:50:06 +0100 Subject: cargo dev crater: add more crates to be checked --- clippy_dev/src/crater.rs | 34 +++++- mini-crater/logs.txt | 290 ++++++++++++++++++++++++++++++++++++++++------- 2 files changed, 281 insertions(+), 43 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/crater.rs b/clippy_dev/src/crater.rs index 3fb130cc594..b23d9b4d987 100644 --- a/clippy_dev/src/crater.rs +++ b/clippy_dev/src/crater.rs @@ -78,7 +78,16 @@ impl Krate { let all_output = std::process::Command::new(cargo_clippy_path) // lint warnings will look like this: // src/cargo/ops/cargo_compile.rs:127:35: warning: usage of `FromIterator::from_iter` - .args(&["--", "--message-format=short", "--", "--cap-lints=warn"]) + .args(&[ + "--", + "--message-format=short", + "--", + "--cap-lints=warn", + /* "--", + "-Wclippy::pedantic", + "--", + "-Wclippy::cargo", */ + ]) .current_dir(&self.path) .output() .unwrap(); @@ -121,7 +130,28 @@ pub fn run() { let cargo_clippy_path: PathBuf = PathBuf::from("target/debug/cargo-clippy"); // crates we want to check: - let krates: Vec = vec![KrateSource::new("regex", "1.4.2"), KrateSource::new("cargo", "0.49.0")]; + let krates: Vec = vec![ + // some of these are form cargotest + KrateSource::new("cargo", "0.49.0"), + KrateSource::new("iron", "0.6.1"), + KrateSource::new("ripgrep", "12.1.1"), + KrateSource::new("tokei", "12.0.4"), + KrateSource::new("xsv", "0.13.0"), + KrateSource::new("serde", "1.0.118"), + KrateSource::new("rayon", "1.5.0"), + // top 10 crates.io dls + KrateSource::new("rand", "0.7.3"), + KrateSource::new("syn", "1.0.54"), + KrateSource::new("libc", "0.2.81"), + KrateSource::new("quote", "1.0.7"), + KrateSource::new("rand_core", "0.6.0"), + KrateSource::new("unicode-xid", "0.2.1"), + KrateSource::new("proc-macro2", "1.0.24"), + KrateSource::new("bitflags", "1.2.1"), + KrateSource::new("log", "0.4.11"), + KrateSource::new("regex", "1.4.2") + // + ]; println!("Compiling clippy..."); build_clippy(); diff --git a/mini-crater/logs.txt b/mini-crater/logs.txt index 48296dbd479..b32d9f30d42 100644 --- a/mini-crater/logs.txt +++ b/mini-crater/logs.txt @@ -1,3 +1,252 @@ +cargo-0.49.0/src/bin/cargo/cli.rs:121:5: calling `push_str()` using a single-character string literal +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:353:56: stripping a prefix manually +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:762:5: this function's return value is unnecessarily wrapped by `Result` +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1664:5: field assignment outside of initializer for an instance created with Default::default() +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1795:5: field assignment outside of initializer for an instance created with Default::default() +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1980:24: stripping a prefix manually +cargo-0.49.0/src/cargo/core/compiler/mod.rs:1131:1: this function's return value is unnecessarily wrapped by `Result` +cargo-0.49.0/src/cargo/core/compiler/mod.rs:364:5: this function's return value is unnecessarily wrapped by `Result` +cargo-0.49.0/src/cargo/core/compiler/mod.rs:693:1: this function's return value is unnecessarily wrapped by `Result` +cargo-0.49.0/src/cargo/core/package.rs:421:5: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) +cargo-0.49.0/src/cargo/core/profiles.rs:143:5: this function's return value is unnecessarily wrapped by `Result` +cargo-0.49.0/src/cargo/core/profiles.rs:372:9: field assignment outside of initializer for an instance created with Default::default() +cargo-0.49.0/src/cargo/core/resolver/errors.rs:305:17: calling `push_str()` using a single-character string literal +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:239:5: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) +cargo-0.49.0/src/cargo/core/resolver/types.rs:187:5: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) +cargo-0.49.0/src/cargo/core/resolver/types.rs:261:5: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) +cargo-0.49.0/src/cargo/core/workspace.rs:1056:5: this function's return value is unnecessarily wrapped by `Result` +cargo-0.49.0/src/cargo/core/workspace.rs:440:9: this function's return value is unnecessarily wrapped by `Result` +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:127:35: usage of `FromIterator::from_iter` +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:233:21: calling `push_str()` using a single-character string literal +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:370:5: this function's return value is unnecessarily wrapped by `Result` +cargo-0.49.0/src/cargo/ops/fix.rs:608:9: field assignment outside of initializer for an instance created with Default::default() +cargo-0.49.0/src/cargo/ops/fix.rs:619:48: stripping a prefix manually +cargo-0.49.0/src/cargo/ops/lockfile.rs:154:13: calling `push_str()` using a single-character string literal +cargo-0.49.0/src/cargo/ops/lockfile.rs:217:9: calling `push_str()` using a single-character string literal +cargo-0.49.0/src/cargo/ops/lockfile.rs:87:1: this function's return value is unnecessarily wrapped by `Result` +cargo-0.49.0/src/cargo/sources/git/source.rs:69:20: comparison to empty slice +cargo-0.49.0/src/cargo/sources/git/utils.rs:1158:9: stripping a suffix manually +cargo-0.49.0/src/cargo/sources/git/utils.rs:758:9: calling `push_str()` using a single-character string literal +cargo-0.49.0/src/cargo/sources/path.rs:339:9: this function's return value is unnecessarily wrapped by `Result` +cargo-0.49.0/src/cargo/sources/registry/index.rs:736:1: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) +cargo-0.49.0/src/cargo/util/config/key.rs:69:9: calling `push_str()` using a single-character string literal +cargo-0.49.0/src/cargo/util/config/value.rs:81:9: match expression looks like `matches!` macro +cargo-0.49.0/src/cargo/util/errors.rs:473:5: manual `RangeInclusive::contains` implementation +cargo-0.49.0/src/cargo/util/paths.rs:93:31: comparison to empty slice +cargo-0.49.0/src/cargo/util/progress.rs:269:17: calling `push_str()` using a single-character string literal +cargo-0.49.0/src/cargo/util/progress.rs:272:17: calling `push_str()` using a single-character string literal +cargo-0.49.0/src/cargo/util/progress.rs:274:17: calling `push_str()` using a single-character string literal +cargo-0.49.0/src/cargo/util/progress.rs:280:13: calling `push_str()` using a single-character string literal +cargo-0.49.0/src/cargo/util/progress.rs:282:9: calling `push_str()` using a single-character string literal +cargo-0.49.0/src/cargo/util/toml/mod.rs:1687:33: unnecessary closure used to substitute value for `Option::None` +iron-0.6.1/src/error.rs:55:20: use of deprecated associated function `std::error::Error::description`: use the Display impl or to_string() +iron-0.6.1/src/iron.rs:105:13: redundant field names in struct initialization +iron-0.6.1/src/iron.rs:148:19: use of deprecated macro `try`: use the `?` operator instead +iron-0.6.1/src/iron.rs:149:13: redundant field names in struct initialization +iron-0.6.1/src/modifiers.rs:132:14: use of `expect` followed by a function call +iron-0.6.1/src/request/mod.rs:121:13: redundant field names in struct initialization +iron-0.6.1/src/request/mod.rs:123:13: redundant field names in struct initialization +iron-0.6.1/src/request/mod.rs:124:13: redundant field names in struct initialization +iron-0.6.1/src/request/mod.rs:126:13: redundant field names in struct initialization +iron-0.6.1/src/request/mod.rs:128:13: redundant field names in struct initialization +iron-0.6.1/src/request/mod.rs:32:1: this seems like a manual implementation of the non-exhaustive pattern +iron-0.6.1/src/request/mod.rs:62:9: use of deprecated macro `try`: use the `?` operator instead +iron-0.6.1/src/request/mod.rs:64:9: use of deprecated macro `try`: use the `?` operator instead +iron-0.6.1/src/request/mod.rs:65:9: use of deprecated macro `try`: use the `?` operator instead +iron-0.6.1/src/request/mod.rs:66:9: use of deprecated macro `try`: use the `?` operator instead +iron-0.6.1/src/request/mod.rs:67:9: use of deprecated macro `try`: use the `?` operator instead +iron-0.6.1/src/request/mod.rs:69:9: use of deprecated macro `try`: use the `?` operator instead +iron-0.6.1/src/request/url.rs:124:9: use of deprecated macro `try`: use the `?` operator instead +iron-0.6.1/src/response.rs:142:23: use of deprecated macro `try`: use the `?` operator instead +iron-0.6.1/src/response.rs:143:5: use of deprecated macro `try`: use the `?` operator instead +iron-0.6.1/src/response.rs:95:5: you should consider adding a `Default` implementation for `response::Response` +ripgrep-12.1.1/build.rs:133:19: called `.as_ref().map(|x| &**x)` on an Option value. This can be done more directly by calling `githash.as_deref()` instead +ripgrep-12.1.1/build.rs:92:19: called `.as_ref().map(|x| &**x)` on an Option value. This can be done more directly by calling `githash.as_deref()` instead +ripgrep-12.1.1/crates/core/args.rs:11:1: this import is redundant +ripgrep-12.1.1/crates/core/args.rs:1209:74: this `if` has identical blocks +ripgrep-12.1.1/crates/core/args.rs:1209:74: this `if` has identical blocks +ripgrep-12.1.1/crates/core/args.rs:1524:5: this function's return value is unnecessarily wrapped by `Result` +ripgrep-12.1.1/crates/core/args.rs:33:1: this import is redundant +ripgrep-12.1.1/crates/core/args.rs:34:1: this import is redundant +ripgrep-12.1.1/crates/core/args.rs:35:1: this import is redundant +ripgrep-12.1.1/crates/core/args.rs:549:16: methods called `to_*` usually take self by reference; consider choosing a less ambiguous name +ripgrep-12.1.1/crates/core/config.rs:13:1: this import is redundant +ripgrep-12.1.1/crates/core/config.rs:58:6: very complex type used. Consider factoring parts into `type` definitions +ripgrep-12.1.1/crates/core/config.rs:79:6: very complex type used. Consider factoring parts into `type` definitions +ripgrep-12.1.1/crates/core/logger.rs:15:16: constants have by default a `'static` lifetime +ripgrep-12.1.1/crates/core/search.rs:292:9: using `write!()` with a format string that ends in a single newline +ripgrep-12.1.1/crates/core/search.rs:377:12: this boolean expression can be simplified +ripgrep-12.1.1/crates/core/search.rs:472:24: you are using an explicit closure for cloning elements +ripgrep-12.1.1/crates/core/search.rs:480:24: you are using an explicit closure for cloning elements +ripgrep-12.1.1/crates/core/search.rs:509:24: you are using an explicit closure for cloning elements +ripgrep-12.1.1/crates/core/search.rs:517:24: you are using an explicit closure for cloning elements +ripgrep-12.1.1/crates/core/subject.rs:4:1: this import is redundant +tokei-12.0.4/src/cli_utils.rs:154:25: this lifetime isn't used in the function definition +tokei-12.0.4/src/cli_utils.rs:154:29: this lifetime isn't used in the function definition +tokei-12.0.4/src/cli_utils.rs:195:47: useless use of `format!` +tokei-12.0.4/src/cli_utils.rs:306:47: useless use of `format!` +tokei-12.0.4/src/config.rs:102:36: use of `or` followed by a function call +tokei-12.0.4/src/config.rs:103:38: use of `or` followed by a function call +tokei-12.0.4/src/config.rs:106:18: use of `or` followed by a function call +tokei-12.0.4/src/config.rs:109:18: use of `or` followed by a function call +tokei-12.0.4/src/config.rs:112:18: use of `or` followed by a function call +tokei-12.0.4/src/config.rs:97:18: use of `or` followed by a function call +tokei-12.0.4/src/config.rs:99:86: use of `or` followed by a function call +tokei-12.0.4/src/language/language_type.rs:75:22: this `.into_iter()` call is equivalent to `.iter()` and will not consume the `slice` +tokei-12.0.4/src/language/syntax.rs:334:45: this `if` has identical blocks +tokei-12.0.4/src/language/syntax.rs:334:45: this `if` has identical blocks +tokei-12.0.4/src/language/syntax.rs:336:39: this `if` has identical blocks +tokei-12.0.4/src/language/syntax.rs:338:16: this if-then-else expression returns a bool literal +tokei-12.0.4/src/language/syntax.rs:338:43: this `if` has identical blocks +tokei-12.0.4/src/language/syntax.rs:446:74: trivial regex +tokei-12.0.4/src/language/syntax.rs:449:73: trivial regex +tokei-12.0.4/src/language/syntax.rs:453:45: trivial regex +tokei-12.0.4/src/utils/fs.rs:105:26: called `.as_ref().map(|v| &**v)` on an Option value. This can be done more directly by calling `config.types.as_deref()` instead +xsv-0.13.0/src/cmd/cat.rs:7:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/count.rs:50:5: passing a unit value to a function +xsv-0.13.0/src/cmd/count.rs:7:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/fixlengths.rs:9:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/flatten.rs:10:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/fmt.rs:7:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/frequency.rs:15:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/frequency.rs:178:24: this `else { if .. }` block can be collapsed +xsv-0.13.0/src/cmd/headers.rs:60:22: trait objects without an explicit `dyn` are deprecated +xsv-0.13.0/src/cmd/headers.rs:9:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/index.rs:11:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/input.rs:7:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/join.rs:17:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/join.rs:281:44: trait objects without an explicit `dyn` are deprecated +xsv-0.13.0/src/cmd/join.rs:297:13: redundant field names in struct initialization +xsv-0.13.0/src/cmd/join.rs:298:13: redundant field names in struct initialization +xsv-0.13.0/src/cmd/join.rs:299:13: redundant field names in struct initialization +xsv-0.13.0/src/cmd/join.rs:300:13: redundant field names in struct initialization +xsv-0.13.0/src/cmd/join.rs:392:13: redundant field names in struct initialization +xsv-0.13.0/src/cmd/partition.rs:126:36: trait objects without an explicit `dyn` are deprecated +xsv-0.13.0/src/cmd/partition.rs:139:13: redundant field names in struct initialization +xsv-0.13.0/src/cmd/partition.rs:15:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/sample.rs:11:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/search.rs:9:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/select.rs:8:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/slice.rs:9:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/sort.rs:11:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/split.rs:131:36: trait objects without an explicit `dyn` are deprecated +xsv-0.13.0/src/cmd/split.rs:14:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/split.rs:94:5: this function's return value is unnecessarily wrapped by `Result` +xsv-0.13.0/src/cmd/stats.rs:22:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/stats.rs:269:13: redundant field names in struct initialization +xsv-0.13.0/src/cmd/stats.rs:270:13: redundant field names in struct initialization +xsv-0.13.0/src/cmd/stats.rs:271:13: redundant field names in struct initialization +xsv-0.13.0/src/cmd/stats.rs:272:13: redundant field names in struct initialization +xsv-0.13.0/src/cmd/stats.rs:273:13: redundant field names in struct initialization +xsv-0.13.0/src/cmd/stats.rs:274:13: redundant field names in struct initialization +xsv-0.13.0/src/cmd/stats.rs:283:9: called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()` +xsv-0.13.0/src/cmd/stats.rs:284:9: called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()` +xsv-0.13.0/src/cmd/stats.rs:285:9: called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()` +xsv-0.13.0/src/cmd/stats.rs:290:21: called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()` +xsv-0.13.0/src/cmd/stats.rs:297:25: called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()` +xsv-0.13.0/src/cmd/stats.rs:301:21: called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()` +xsv-0.13.0/src/cmd/stats.rs:302:21: called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()` +xsv-0.13.0/src/cmd/stats.rs:308:18: methods called `to_*` usually take self by reference; consider choosing a less ambiguous name +xsv-0.13.0/src/cmd/stats.rs:402:16: redundant pattern matching, consider using `is_ok()` +xsv-0.13.0/src/cmd/stats.rs:403:16: redundant pattern matching, consider using `is_ok()` +xsv-0.13.0/src/cmd/table.rs:10:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/config.rs:113:43: use of `unwrap_or` followed by a function call +xsv-0.13.0/src/config.rs:197:48: trait objects without an explicit `dyn` are deprecated +xsv-0.13.0/src/config.rs:202:48: trait objects without an explicit `dyn` are deprecated +xsv-0.13.0/src/config.rs:263:47: trait objects without an explicit `dyn` are deprecated +xsv-0.13.0/src/config.rs:293:47: trait objects without an explicit `dyn` are deprecated +xsv-0.13.0/src/config.rs:90:13: redundant field names in struct initialization +xsv-0.13.0/src/index.rs:31:13: redundant field names in struct initialization +xsv-0.13.0/src/main.rs:164:49: redundant clone +xsv-0.13.0/src/main.rs:75:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/select.rs:154:5: this function's return value is unnecessarily wrapped by `Result` +xsv-0.13.0/src/select.rs:280:20: length comparison to zero +xsv-0.13.0/src/select.rs:29:13: redundant field names in struct initialization +xsv-0.13.0/src/select.rs:360:9: this function's return value is unnecessarily wrapped by `Option` +xsv-0.13.0/src/select.rs:375:9: used sort instead of sort_unstable to sort primitive type `usize` +xsv-0.13.0/src/select.rs:416:5: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) +xsv-0.13.0/src/select.rs:419:9: this function's return value is unnecessarily wrapped by `Option` +xsv-0.13.0/src/util.rs:190:48: trait objects without an explicit `dyn` are deprecated +xsv-0.13.0/src/util.rs:37:33: you are using an explicit closure for copying elements +xsv-0.13.0/src/util.rs:90:1: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) +rayon-1.5.0/src/collections/mod.rs:59:32: replacing a value of type `T` with `T::default()` is better expressed using `std::mem::take` +rayon-1.5.0/src/compile_fail/cannot_collect_filtermap_data.rs:2:1: needless `fn main` in doctest +rayon-1.5.0/src/compile_fail/cannot_zip_filtered_data.rs:2:1: needless `fn main` in doctest +rayon-1.5.0/src/compile_fail/cell_par_iter.rs:2:1: needless `fn main` in doctest +rayon-1.5.0/src/compile_fail/no_send_par_iter.rs:25:1: needless `fn main` in doctest +rayon-1.5.0/src/compile_fail/no_send_par_iter.rs:46:1: needless `fn main` in doctest +rayon-1.5.0/src/compile_fail/no_send_par_iter.rs:4:1: needless `fn main` in doctest +rayon-1.5.0/src/compile_fail/rc_par_iter.rs:2:1: needless `fn main` in doctest +rayon-1.5.0/src/iter/interleave.rs:313:9: `if` chain can be rewritten with `match` +rayon-1.5.0/src/iter/mod.rs:2171:1: trait `IndexedParallelIterator` has a `len` method but no (possibly inherited) `is_empty` method +rayon-1.5.0/src/slice/quicksort.rs:588:17: the operation is ineffective. Consider reducing it to `len / 4` +rayon-1.5.0/src/str.rs:715:9: stripping a suffix manually +rayon-1.5.0/src/vec.rs:137:12: length comparison to zero +rand-0.7.3/src/distributions/bernoulli.rs:96:13: manual `Range::contains` implementation +rand-0.7.3/src/distributions/uniform.rs:146:4: needless `fn main` in doctest +rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization +rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization +rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization +rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization +rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization +rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization +rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization +rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization +rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization +rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization +rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization +rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization +rand-0.7.3/src/distributions/weighted/alias_method.rs:259:28: using `clone` on type `distributions::uniform::Uniform` which implements the `Copy` trait +rand-0.7.3/src/distributions/weighted/alias_method.rs:296:9: you are using an explicit closure for copying elements +rand-0.7.3/src/distributions/weighted/alias_method.rs:321:9: you are using an explicit closure for copying elements +rand-0.7.3/src/distributions/weighted/mod.rs:169:16: unnecessary `>= y + 1` or `x - 1 >=` +rand-0.7.3/src/seq/index.rs:87:5: method `into_iter` can be confused for the standard trait method `std::iter::IntoIterator::into_iter` +rand-0.7.3/src/seq/mod.rs:229:4: needless `fn main` in doctest +rand-0.7.3/src/seq/mod.rs:45:4: needless `fn main` in doctest +syn-1.0.54/src/lit.rs:1397:40: redundant else block +syn-1.0.54/src/lit.rs:1405:28: redundant else block +syn-1.0.54/src/lit.rs:1485:32: redundant else block +libc-0.2.81/build.rs:124:5: this block may be rewritten with the `?` operator +libc-0.2.81/build.rs:133:5: this block may be rewritten with the `?` operator +libc-0.2.81/src/macros.rs:243:17: unsafe function's docs miss `# Safety` section +libc-0.2.81/src/macros.rs:243:17: unsafe function's docs miss `# Safety` section +libc-0.2.81/src/macros.rs:243:17: unsafe function's docs miss `# Safety` section +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:291:5: unsafe function's docs miss `# Safety` section +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:302:5: unsafe function's docs miss `# Safety` section +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:355:13: unsafe function's docs miss `# Safety` section +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:359:13: unsafe function's docs miss `# Safety` section +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:363:13: unsafe function's docs miss `# Safety` section +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:367:13: unsafe function's docs miss `# Safety` section +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:371:13: unsafe function's docs miss `# Safety` section +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2572:9: unneeded `return` statement +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2578:20: `0 as *mut _` detected +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2588:13: `0 as *mut _` detected +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2611:9: unneeded unit expression +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2619:9: unneeded unit expression +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2654:18: the operation is ineffective. Consider reducing it to `(dev & 0x00000000000000ff)` +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2665:16: the operation is ineffective. Consider reducing it to `(minor & 0x000000ff)` +libc-0.2.81/src/unix/linux_like/mod.rs:1218:27: the operation is ineffective. Consider reducing it to `IPOPT_CONTROL` +libc-0.2.81/src/unix/linux_like/mod.rs:1314:9: operator precedence can trip the unwary +libc-0.2.81/src/unix/linux_like/mod.rs:1323:13: `0 as *mut _` detected +libc-0.2.81/src/unix/linux_like/mod.rs:1344:9: unneeded `return` statement +libc-0.2.81/src/unix/linux_like/mod.rs:1350:9: unneeded `return` statement +libc-0.2.81/src/unix/linux_like/mod.rs:1357:9: unneeded `return` statement +libc-0.2.81/src/unix/mod.rs:201:35: casting integer literal to `usize` is unnecessary +libc-0.2.81/src/unix/mod.rs:202:35: casting integer literal to `usize` is unnecessary +quote-1.0.7/src/ident_fragment.rs:51:31: stripping a prefix manually +proc-macro2-1.0.24/src/fallback.rs:654:5: manual `RangeInclusive::contains` implementation +proc-macro2-1.0.24/src/fallback.rs:655:12: manual `RangeInclusive::contains` implementation +proc-macro2-1.0.24/src/fallback.rs:661:5: manual `RangeInclusive::contains` implementation +proc-macro2-1.0.24/src/fallback.rs:662:12: manual `RangeInclusive::contains` implementation +proc-macro2-1.0.24/src/fallback.rs:664:12: manual `RangeInclusive::contains` implementation +proc-macro2-1.0.24/src/fallback.rs:674:37: manual `RangeInclusive::contains` implementation +proc-macro2-1.0.24/src/parse.rs:552:5: this loop could be written as a `for` loop +proc-macro2-1.0.24/src/parse.rs:584:21: manual `RangeInclusive::contains` implementation +log-0.4.11/src/lib.rs:1093:5: you should consider adding a `Default` implementation for `MetadataBuilder<'a>` +log-0.4.11/src/lib.rs:329:27: you are deriving `Hash` but have implemented `PartialEq` explicitly +log-0.4.11/src/lib.rs:448:12: manual `RangeInclusive::contains` implementation +log-0.4.11/src/lib.rs:520:27: you are deriving `Hash` but have implemented `PartialEq` explicitly +log-0.4.11/src/lib.rs:908:5: you should consider adding a `Default` implementation for `RecordBuilder<'a>` regex-1.4.2/src/backtrack.rs:100:13: redundant field names in struct initialization regex-1.4.2/src/backtrack.rs:133:17: it looks like the same item is being pushed into this Vec regex-1.4.2/src/backtrack.rs:223:29: redundant field names in struct initialization @@ -137,44 +386,3 @@ regex-1.4.2/src/utf8.rs:80:16: digits of hex or binary literal not grouped by fo regex-1.4.2/src/utf8.rs:92:23: digits of hex or binary literal not grouped by four regex-1.4.2/src/utf8.rs:92:9: digits of hex or binary literal not grouped by four regex-1.4.2/src/utf8.rs:97:16: digits of hex or binary literal not grouped by four -cargo-0.49.0/src/bin/cargo/cli.rs:121:5: calling `push_str()` using a single-character string literal -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:353:56: stripping a prefix manually -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:762:5: this function's return value is unnecessarily wrapped by `Result` -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1664:5: field assignment outside of initializer for an instance created with Default::default() -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1795:5: field assignment outside of initializer for an instance created with Default::default() -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1980:24: stripping a prefix manually -cargo-0.49.0/src/cargo/core/compiler/mod.rs:1131:1: this function's return value is unnecessarily wrapped by `Result` -cargo-0.49.0/src/cargo/core/compiler/mod.rs:364:5: this function's return value is unnecessarily wrapped by `Result` -cargo-0.49.0/src/cargo/core/compiler/mod.rs:693:1: this function's return value is unnecessarily wrapped by `Result` -cargo-0.49.0/src/cargo/core/package.rs:421:5: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) -cargo-0.49.0/src/cargo/core/profiles.rs:143:5: this function's return value is unnecessarily wrapped by `Result` -cargo-0.49.0/src/cargo/core/profiles.rs:372:9: field assignment outside of initializer for an instance created with Default::default() -cargo-0.49.0/src/cargo/core/resolver/errors.rs:305:17: calling `push_str()` using a single-character string literal -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:239:5: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) -cargo-0.49.0/src/cargo/core/resolver/types.rs:187:5: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) -cargo-0.49.0/src/cargo/core/resolver/types.rs:261:5: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) -cargo-0.49.0/src/cargo/core/workspace.rs:1056:5: this function's return value is unnecessarily wrapped by `Result` -cargo-0.49.0/src/cargo/core/workspace.rs:440:9: this function's return value is unnecessarily wrapped by `Result` -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:127:35: usage of `FromIterator::from_iter` -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:233:21: calling `push_str()` using a single-character string literal -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:370:5: this function's return value is unnecessarily wrapped by `Result` -cargo-0.49.0/src/cargo/ops/fix.rs:608:9: field assignment outside of initializer for an instance created with Default::default() -cargo-0.49.0/src/cargo/ops/fix.rs:619:48: stripping a prefix manually -cargo-0.49.0/src/cargo/ops/lockfile.rs:154:13: calling `push_str()` using a single-character string literal -cargo-0.49.0/src/cargo/ops/lockfile.rs:217:9: calling `push_str()` using a single-character string literal -cargo-0.49.0/src/cargo/ops/lockfile.rs:87:1: this function's return value is unnecessarily wrapped by `Result` -cargo-0.49.0/src/cargo/sources/git/source.rs:69:20: comparison to empty slice -cargo-0.49.0/src/cargo/sources/git/utils.rs:1158:9: stripping a suffix manually -cargo-0.49.0/src/cargo/sources/git/utils.rs:758:9: calling `push_str()` using a single-character string literal -cargo-0.49.0/src/cargo/sources/path.rs:339:9: this function's return value is unnecessarily wrapped by `Result` -cargo-0.49.0/src/cargo/sources/registry/index.rs:736:1: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) -cargo-0.49.0/src/cargo/util/config/key.rs:69:9: calling `push_str()` using a single-character string literal -cargo-0.49.0/src/cargo/util/config/value.rs:81:9: match expression looks like `matches!` macro -cargo-0.49.0/src/cargo/util/errors.rs:473:5: manual `RangeInclusive::contains` implementation -cargo-0.49.0/src/cargo/util/paths.rs:93:31: comparison to empty slice -cargo-0.49.0/src/cargo/util/progress.rs:269:17: calling `push_str()` using a single-character string literal -cargo-0.49.0/src/cargo/util/progress.rs:272:17: calling `push_str()` using a single-character string literal -cargo-0.49.0/src/cargo/util/progress.rs:274:17: calling `push_str()` using a single-character string literal -cargo-0.49.0/src/cargo/util/progress.rs:280:13: calling `push_str()` using a single-character string literal -cargo-0.49.0/src/cargo/util/progress.rs:282:9: calling `push_str()` using a single-character string literal -cargo-0.49.0/src/cargo/util/toml/mod.rs:1687:33: unnecessary closure used to substitute value for `Option::None` -- cgit 1.4.1-3-g733a5 From ccfaa338edead678687dcd690846470cbeee1dcd Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Fri, 18 Dec 2020 22:08:18 +0100 Subject: cargo dev crater: share target dir between clippy runs, enable pedantic and cargo lints, ignore tokei for now. --- clippy_dev/src/crater.rs | 14 +- mini-crater/logs.txt | 2906 +++++++++++++++++++++++++++++++++++++++++++++- 2 files changed, 2892 insertions(+), 28 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/crater.rs b/clippy_dev/src/crater.rs index b23d9b4d987..eb301159a7b 100644 --- a/clippy_dev/src/crater.rs +++ b/clippy_dev/src/crater.rs @@ -1,6 +1,6 @@ +use crate::clippy_project_root; use std::path::PathBuf; use std::process::Command; - // represents an archive we download from crates.io #[derive(Debug)] struct KrateSource { @@ -75,7 +75,10 @@ impl Krate { println!("Linting {} {}...", &self.name, &self.version); let cargo_clippy_path = std::fs::canonicalize(cargo_clippy_path).unwrap(); + let shared_target_dir = clippy_project_root().join("target/crater/shared_target_dir/"); + let all_output = std::process::Command::new(cargo_clippy_path) + .env("CARGO_TARGET_DIR", shared_target_dir) // lint warnings will look like this: // src/cargo/ops/cargo_compile.rs:127:35: warning: usage of `FromIterator::from_iter` .args(&[ @@ -83,10 +86,8 @@ impl Krate { "--message-format=short", "--", "--cap-lints=warn", - /* "--", "-Wclippy::pedantic", - "--", - "-Wclippy::cargo", */ + "-Wclippy::cargo", ]) .current_dir(&self.path) .output() @@ -135,7 +136,7 @@ pub fn run() { KrateSource::new("cargo", "0.49.0"), KrateSource::new("iron", "0.6.1"), KrateSource::new("ripgrep", "12.1.1"), - KrateSource::new("tokei", "12.0.4"), + //KrateSource::new("tokei", "12.0.4"), KrateSource::new("xsv", "0.13.0"), KrateSource::new("serde", "1.0.118"), KrateSource::new("rayon", "1.5.0"), @@ -149,8 +150,7 @@ pub fn run() { KrateSource::new("proc-macro2", "1.0.24"), KrateSource::new("bitflags", "1.2.1"), KrateSource::new("log", "0.4.11"), - KrateSource::new("regex", "1.4.2") - // + KrateSource::new("regex", "1.4.2"), ]; println!("Compiling clippy..."); diff --git a/mini-crater/logs.txt b/mini-crater/logs.txt index b32d9f30d42..963b1fa38bf 100644 --- a/mini-crater/logs.txt +++ b/mini-crater/logs.txt @@ -1,54 +1,1412 @@ +cargo-0.49.0/src/bin/cargo/cli.rs:104:34: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` cargo-0.49.0/src/bin/cargo/cli.rs:121:5: calling `push_str()` using a single-character string literal +cargo-0.49.0/src/bin/cargo/cli.rs:157:30: redundant closure found +cargo-0.49.0/src/bin/cargo/cli.rs:184:41: casting `u64` to `u32` may truncate the value +cargo-0.49.0/src/bin/cargo/cli.rs:196:42: redundant closure found +cargo-0.49.0/src/bin/cargo/cli.rs:200:39: redundant closure found +cargo-0.49.0/src/bin/cargo/cli.rs:231:1: more than 3 bools in a struct +cargo-0.49.0/src/bin/cargo/cli.rs:245:22: casting `u64` to `u32` may truncate the value +cargo-0.49.0/src/bin/cargo/cli.rs:247:47: redundant closure found +cargo-0.49.0/src/bin/cargo/cli.rs:257:22: redundant closure found +cargo-0.49.0/src/bin/cargo/cli.rs:26:20: redundant else block +cargo-0.49.0/src/bin/cargo/cli.rs:7:5: usage of wildcard import +cargo-0.49.0/src/bin/cargo/commands/bench.rs:1:5: usage of wildcard import +cargo-0.49.0/src/bin/cargo/commands/bench.rs:76:59: redundant closure found +cargo-0.49.0/src/bin/cargo/commands/build.rs:1:5: usage of wildcard import +cargo-0.49.0/src/bin/cargo/commands/check.rs:1:5: usage of wildcard import +cargo-0.49.0/src/bin/cargo/commands/clean.rs:1:5: usage of wildcard import +cargo-0.49.0/src/bin/cargo/commands/doc.rs:1:5: usage of wildcard import +cargo-0.49.0/src/bin/cargo/commands/fetch.rs:1:5: usage of wildcard import +cargo-0.49.0/src/bin/cargo/commands/fix.rs:1:5: usage of wildcard import +cargo-0.49.0/src/bin/cargo/commands/generate_lockfile.rs:1:5: usage of wildcard import +cargo-0.49.0/src/bin/cargo/commands/git_checkout.rs:1:5: usage of wildcard import +cargo-0.49.0/src/bin/cargo/commands/help.rs:20:1: item name ends with its containing module's name +cargo-0.49.0/src/bin/cargo/commands/init.rs:1:5: usage of wildcard import +cargo-0.49.0/src/bin/cargo/commands/install.rs:1:5: usage of wildcard import +cargo-0.49.0/src/bin/cargo/commands/install.rs:97:16: use Option::map_or instead of an if let/else +cargo-0.49.0/src/bin/cargo/commands/locate_project.rs:1:5: usage of wildcard import +cargo-0.49.0/src/bin/cargo/commands/login.rs:1:5: usage of wildcard import +cargo-0.49.0/src/bin/cargo/commands/metadata.rs:1:5: usage of wildcard import +cargo-0.49.0/src/bin/cargo/commands/mod.rs:1:5: usage of wildcard import +cargo-0.49.0/src/bin/cargo/commands/new.rs:1:5: usage of wildcard import +cargo-0.49.0/src/bin/cargo/commands/new.rs:20:24: use Option::map_or instead of an if let/else +cargo-0.49.0/src/bin/cargo/commands/owner.rs:1:5: usage of wildcard import +cargo-0.49.0/src/bin/cargo/commands/owner.rs:38:43: redundant closure found +cargo-0.49.0/src/bin/cargo/commands/owner.rs:39:43: redundant closure found +cargo-0.49.0/src/bin/cargo/commands/owner.rs:40:43: redundant closure found +cargo-0.49.0/src/bin/cargo/commands/owner.rs:43:30: redundant closure found +cargo-0.49.0/src/bin/cargo/commands/owner.rs:46:30: redundant closure found +cargo-0.49.0/src/bin/cargo/commands/package.rs:1:5: usage of wildcard import +cargo-0.49.0/src/bin/cargo/commands/pkgid.rs:1:5: usage of wildcard import +cargo-0.49.0/src/bin/cargo/commands/publish.rs:1:5: usage of wildcard import +cargo-0.49.0/src/bin/cargo/commands/publish.rs:40:47: redundant closure found +cargo-0.49.0/src/bin/cargo/commands/read_manifest.rs:1:5: usage of wildcard import +cargo-0.49.0/src/bin/cargo/commands/run.rs:1:5: usage of wildcard import +cargo-0.49.0/src/bin/cargo/commands/rustc.rs:1:5: usage of wildcard import +cargo-0.49.0/src/bin/cargo/commands/rustdoc.rs:3:5: usage of wildcard import +cargo-0.49.0/src/bin/cargo/commands/search.rs:1:5: usage of wildcard import +cargo-0.49.0/src/bin/cargo/commands/test.rs:127:54: redundant closure found +cargo-0.49.0/src/bin/cargo/commands/test.rs:1:5: usage of wildcard import +cargo-0.49.0/src/bin/cargo/commands/tree.rs:149:49: redundant closure found +cargo-0.49.0/src/bin/cargo/commands/tree.rs:2:5: usage of wildcard import +cargo-0.49.0/src/bin/cargo/commands/uninstall.rs:1:5: usage of wildcard import +cargo-0.49.0/src/bin/cargo/commands/update.rs:1:5: usage of wildcard import +cargo-0.49.0/src/bin/cargo/commands/vendor.rs:1:5: usage of wildcard import +cargo-0.49.0/src/bin/cargo/commands/vendor.rs:96:16: called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead +cargo-0.49.0/src/bin/cargo/commands/verify_project.rs:1:5: usage of wildcard import +cargo-0.49.0/src/bin/cargo/commands/version.rs:2:5: usage of wildcard import +cargo-0.49.0/src/bin/cargo/commands/yank.rs:1:5: usage of wildcard import +cargo-0.49.0/src/bin/cargo/commands/yank.rs:32:36: redundant closure found +cargo-0.49.0/src/bin/cargo/commands/yank.rs:33:35: redundant closure found +cargo-0.49.0/src/bin/cargo/commands/yank.rs:34:36: redundant closure found +cargo-0.49.0/src/bin/cargo/commands/yank.rs:35:36: redundant closure found +cargo-0.49.0/src/bin/cargo/main.rs:100:17: wildcard match will miss any future added variants +cargo-0.49.0/src/bin/cargo/main.rs:118:41: redundant closure found +cargo-0.49.0/src/bin/cargo/main.rs:137:43: redundant closure found +cargo-0.49.0/src/bin/cargo/main.rs:148:19: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +cargo-0.49.0/src/bin/cargo/main.rs:174:57: redundant closure found +cargo-0.49.0/src/bin/cargo/main.rs:18:5: usage of wildcard import +cargo-0.49.0/src/bin/cargo/main.rs:72:22: redundant closure found +cargo-0.49.0/src/bin/cargo/main.rs:94:13: wildcard match will miss any future added variants +cargo-0.49.0/src/bin/cargo/main.rs:96:41: redundant closure found +cargo-0.49.0/src/bin/cargo/main.rs:98:60: redundant closure found +cargo-0.49.0/src/cargo/core/compiler/build_config.rs:155:13: usage of wildcard import for enum variants +cargo-0.49.0/src/cargo/core/compiler/build_config.rs:170:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/compiler/build_config.rs:175:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/compiler/build_config.rs:180:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/compiler/build_config.rs:186:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/compiler/build_config.rs:197:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/compiler/build_config.rs:205:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/compiler/build_config.rs:51:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/compiler/build_config.rs:69:48: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers +cargo-0.49.0/src/cargo/core/compiler/build_config.rs:96:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/compiler/build_context/mod.rs:44:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/compiler/build_context/mod.rs:83:20: you should put `x86_64` between ticks in the documentation +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:108:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:121:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:149:9: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:420:69: you should put `mode/target_kind` between ticks in the documentation +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:423:19: you should put `CrateTypes` between ticks in the documentation +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:424:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:469:58: redundant closure found +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:591:20: called `filter(..).map(..)` on an `Iterator` +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:603:19: redundant closure found +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:665:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:82:31: you should put `FileType` between ticks in the documentation +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:83:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:84:9: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:96:31: you should put `FileType` between ticks in the documentation +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:98:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/compiler/build_plan.rs:4:9: you should put `BuildPlan` between ticks in the documentation +cargo-0.49.0/src/cargo/core/compiler/build_plan.rs:5:66: you should put `BuildPlan` between ticks in the documentation +cargo-0.49.0/src/cargo/core/compiler/compilation.rs:150:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/compiler/compilation.rs:169:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/compiler/compilation.rs:185:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/compiler/compilation.rs:193:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/compiler/compilation.rs:194:49: redundant closure found +cargo-0.49.0/src/cargo/core/compiler/compilation.rs:198:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/compiler/compilation.rs:314:16: you should put `rustc_tool` between ticks in the documentation +cargo-0.49.0/src/cargo/core/compiler/compilation.rs:91:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:118:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:147:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:157:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:29:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:33:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:49:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/compiler/context/compilation_files.rs:204:9: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +cargo-0.49.0/src/cargo/core/compiler/context/compilation_files.rs:277:22: you should put `OUT_DIR` between ticks in the documentation +cargo-0.49.0/src/cargo/core/compiler/context/compilation_files.rs:324:66: you should put `FileType` between ticks in the documentation +cargo-0.49.0/src/cargo/core/compiler/context/compilation_files.rs:393:37: this `match` has identical arm bodies +cargo-0.49.0/src/cargo/core/compiler/context/compilation_files.rs:426:71: redundant closure found +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:125:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:125:5: this function has too many lines (107/100) +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:270:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:286:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:308:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:340:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:349:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:354:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:358:21: you should put `RunCustomBuild` between ticks in the documentation +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:361:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:365:9: called `find(..).map(..)` on an `Iterator` +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:374:43: you should put `RunCustomBuild` between ticks in the documentation +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:378:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:383:41: you should put `RunCustomBuild` between ticks in the documentation +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:384:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:391:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:397:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:523:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:538:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:542:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:83:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:92:25: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +cargo-0.49.0/src/cargo/core/compiler/crate_type.rs:16:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/compiler/crate_type.rs:29:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/compiler/crate_type.rs:40:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/compiler/crate_type.rs:49:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/compiler/crate_type.rs:60:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:150:1: this function has too many lines (230/100) +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:154:29: called `find(..).map(..)` on an `Iterator` cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:353:56: stripping a prefix manually +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:448:27: this argument is passed by value, but not consumed in the function body +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:464:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:481:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:48:56: you should put `RunCustomBuild` between ticks in the documentation +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:561:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:567:20: redundant closure found +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:576:28: `mut value` is being shadowed +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:606:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:624:13: called `find(..).map(..)` on an `Iterator` +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:688:5: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:756:5: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:762:5: adding items after statements is confusing, since items exist from the start of the scope cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:762:5: this function's return value is unnecessarily wrapped by `Result` +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:823:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1021:51: redundant closure found +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1252:20: called `filter(..).map(..)` on an `Iterator` +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1278:19: called `filter(..).map(..)` on an `Iterator` +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1656:16: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1664:5: field assignment outside of initializer for an instance created with Default::default() +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1787:5: binding's name is too similar to existing binding cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1795:5: field assignment outside of initializer for an instance created with Default::default() +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1882:17: binding's name is too similar to existing binding +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1894:17: binding's name is too similar to existing binding +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1906:9: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1917:9: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1923:9: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1956:9: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1962:9: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1963:22: casting `usize` to `u8` may truncate the value +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1964:22: casting `usize` to `u8` may truncate the value +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1965:22: casting `usize` to `u8` may truncate the value +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1966:22: casting `usize` to `u8` may truncate the value +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1980:17: binding's name is too similar to existing binding cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1980:24: stripping a prefix manually +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1986:17: binding's name is too similar to existing binding +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:2016:5: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:61:5: you should put `CompileMode` between ticks in the documentation +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:63:12: you should put `CompileKind` between ticks in the documentation +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:67:7: you should put `CARGO_DEFAULT_LIB_METADATA[^4` between ticks in the documentation +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:68:5: you should put `package_id` between ticks in the documentation +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:71:19: you should put `test/bench/for_host/edition` between ticks in the documentation +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:755:52: this `match` has identical arm bodies +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:77:5: you should put `is_std` between ticks in the documentation +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:816:5: this function has too many lines (127/100) +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:863:64: binding's name is too similar to existing binding +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:875:33: binding's name is too similar to existing binding +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:876:32: binding's name is too similar to existing binding +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:896:30: binding's name is too similar to existing binding +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:897:30: binding's name is too similar to existing binding +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:991:37: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:12:5: you should put `src/librustc_jobserver/lib.rs` between ticks in the documentation +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:282:30: called `filter(..).map(..)` on an `Iterator` +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:329:13: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:332:23: this argument is passed by value, but not consumed in the function body +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:34:53: you should put `NeedsToken` between ticks in the documentation +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:35:6: you should put `ReleaseToken` between ticks in the documentation +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:37:6: you should put `NeedsToken` between ticks in the documentation +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:40:56: you should put `NeedsToken` between ticks in the documentation +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:40:5: you should put `NeedsToken` between ticks in the documentation +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:43:6: you should put `ReleaseToken` between ticks in the documentation +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:749:13: unnecessary boolean `not` operation +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:786:26: unused `self` argument +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:81:61: you should put `DrainState` between ticks in the documentation +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:865:13: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:871:13: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:890:9: unused `self` argument +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:93:24: you should put `JobQueue` between ticks in the documentation +cargo-0.49.0/src/cargo/core/compiler/links.rs:8:1: item name ends with its containing module's name +cargo-0.49.0/src/cargo/core/compiler/mod.rs:1016:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/compiler/mod.rs:1094:19: redundant closure found cargo-0.49.0/src/cargo/core/compiler/mod.rs:1131:1: this function's return value is unnecessarily wrapped by `Result` +cargo-0.49.0/src/cargo/core/compiler/mod.rs:1277:5: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/core/compiler/mod.rs:179:1: this function has too many lines (162/100) +cargo-0.49.0/src/cargo/core/compiler/mod.rs:198:78: redundant closure found +cargo-0.49.0/src/cargo/core/compiler/mod.rs:201:25: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +cargo-0.49.0/src/cargo/core/compiler/mod.rs:267:9: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/core/compiler/mod.rs:324:5: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/core/compiler/mod.rs:364:5: adding items after statements is confusing, since items exist from the start of the scope cargo-0.49.0/src/cargo/core/compiler/mod.rs:364:5: this function's return value is unnecessarily wrapped by `Result` +cargo-0.49.0/src/cargo/core/compiler/mod.rs:392:45: redundant closure found +cargo-0.49.0/src/cargo/core/compiler/mod.rs:415:23: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +cargo-0.49.0/src/cargo/core/compiler/mod.rs:667:15: binding's name is too similar to existing binding cargo-0.49.0/src/cargo/core/compiler/mod.rs:693:1: this function's return value is unnecessarily wrapped by `Result` +cargo-0.49.0/src/cargo/core/compiler/mod.rs:725:42: this `match` has identical arm bodies +cargo-0.49.0/src/cargo/core/compiler/mod.rs:736:1: this function has too many lines (141/100) +cargo-0.49.0/src/cargo/core/compiler/mod.rs:73:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/compiler/mod.rs:777:12: unnecessary boolean `not` operation +cargo-0.49.0/src/cargo/core/compiler/mod.rs:873:5: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/core/compiler/output_depinfo.rs:41:13: wildcard match will miss any future added variants +cargo-0.49.0/src/cargo/core/compiler/rustdoc.rs:16:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/core/compiler/rustdoc.rs:57:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/core/compiler/rustdoc.rs:72:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/compiler/standard_lib.rs:134:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/compiler/standard_lib.rs:16:1: this function could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/compiler/standard_lib.rs:30:28: redundant closure found +cargo-0.49.0/src/cargo/core/compiler/standard_lib.rs:34:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/compiler/timings.rs:16:1: more than 3 bools in a struct +cargo-0.49.0/src/cargo/core/compiler/timings.rs:192:64: this argument is passed by value, but not consumed in the function body +cargo-0.49.0/src/cargo/core/compiler/timings.rs:212:58: this argument is passed by value, but not consumed in the function body +cargo-0.49.0/src/cargo/core/compiler/timings.rs:234:13: non-binding `let` on a type that implements `Drop` +cargo-0.49.0/src/cargo/core/compiler/timings.rs:355:13: casting `f64` to `u32` may lose the sign of the value +cargo-0.49.0/src/cargo/core/compiler/timings.rs:355:13: casting `f64` to `u32` may truncate the value +cargo-0.49.0/src/cargo/core/compiler/timings.rs:397:38: casting `f64` to `u32` may lose the sign of the value +cargo-0.49.0/src/cargo/core/compiler/timings.rs:397:38: casting `f64` to `u32` may truncate the value +cargo-0.49.0/src/cargo/core/compiler/timings.rs:484:9: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/core/compiler/timings.rs:605:38: you should put `rmeta_time` between ticks in the documentation +cargo-0.49.0/src/cargo/core/compiler/timings.rs:605:50: you should put `codegen_time` between ticks in the documentation +cargo-0.49.0/src/cargo/core/compiler/timings.rs:641:26: literal non-ASCII character detected +cargo-0.49.0/src/cargo/core/compiler/unit.rs:100:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/compiler/unit.rs:151:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/core/compiler/unit.rs:161:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/compiler/unit.rs:35:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/core/compiler/unit_dependencies.rs:154:29: you should put `state.unit_dependencies` between ticks in the documentation +cargo-0.49.0/src/cargo/core/compiler/unit_dependencies.rs:213:1: this function has too many lines (110/100) +cargo-0.49.0/src/cargo/core/compiler/unit_dependencies.rs:329:13: called `filter(..).map(..)` on an `Iterator` +cargo-0.49.0/src/cargo/core/compiler/unit_dependencies.rs:480:5: called `find(..).map(..)` on an `Iterator` +cargo-0.49.0/src/cargo/core/compiler/unit_dependencies.rs:511:5: called `find(..).map(..)` on an `Iterator` +cargo-0.49.0/src/cargo/core/compiler/unit_dependencies.rs:52:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/compiler/unit_dependencies.rs:52:1: item name ends with its containing module's name +cargo-0.49.0/src/cargo/core/compiler/unit_graph.rs:65:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/compiler/unit_graph.rs:65:1: item name ends with its containing module's name +cargo-0.49.0/src/cargo/core/dependency.rs:157:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/dependency.rs:182:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/dependency.rs:203:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/dependency.rs:224:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/dependency.rs:23:1: more than 3 bools in a struct +cargo-0.49.0/src/cargo/core/dependency.rs:248:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/dependency.rs:270:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/dependency.rs:274:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/dependency.rs:278:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/dependency.rs:287:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/dependency.rs:291:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/dependency.rs:305:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/dependency.rs:311:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/dependency.rs:319:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/dependency.rs:337:75: redundant closure found +cargo-0.49.0/src/cargo/core/dependency.rs:397:56: redundant closure found +cargo-0.49.0/src/cargo/core/dependency.rs:403:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/dependency.rs:408:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/dependency.rs:415:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/dependency.rs:419:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/dependency.rs:424:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/dependency.rs:428:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/dependency.rs:433:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/dependency.rs:438:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/dependency.rs:443:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/dependency.rs:449:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/dependency.rs:450:9: unnecessary `!=` operation +cargo-0.49.0/src/cargo/core/features.rs:119:17: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/features.rs:229:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/features.rs:274:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/features.rs:278:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/features.rs:306:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/features.rs:338:1: more than 3 bools in a struct +cargo-0.49.0/src/cargo/core/features.rs:362:25: consider using `Option` instead of `Option>` or a custom enum if you need to distinguish all 3 cases +cargo-0.49.0/src/cargo/core/features.rs:380:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/features.rs:401:9: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/core/features.rs:409:9: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/core/features.rs:412:45: redundant closure found +cargo-0.49.0/src/cargo/core/features.rs:416:9: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/core/features.rs:419:45: redundant closure found +cargo-0.49.0/src/cargo/core/features.rs:424:9: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/core/features.rs:431:9: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/core/features.rs:477:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/features.rs:509:1: this function could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/features.rs:518:5: called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead +cargo-0.49.0/src/cargo/core/features.rs:542:1: this function could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/features.rs:543:37: redundant closure found +cargo-0.49.0/src/cargo/core/features.rs:547:60: redundant closure found +cargo-0.49.0/src/cargo/core/features.rs:556:1: item name ends with its containing module's name +cargo-0.49.0/src/cargo/core/features.rs:563:1: item name ends with its containing module's name +cargo-0.49.0/src/cargo/core/manifest.rs:116:13: usage of wildcard import for enum variants +cargo-0.49.0/src/cargo/core/manifest.rs:118:58: redundant closure found +cargo-0.49.0/src/cargo/core/manifest.rs:130:13: usage of wildcard import for enum variants +cargo-0.49.0/src/cargo/core/manifest.rs:143:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:159:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:162:34: redundant closure found +cargo-0.49.0/src/cargo/core/manifest.rs:169:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:17:5: usage of wildcard import +cargo-0.49.0/src/cargo/core/manifest.rs:189:1: more than 3 bools in a struct +cargo-0.49.0/src/cargo/core/manifest.rs:215:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:222:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:22:1: item name ends with its containing module's name +cargo-0.49.0/src/cargo/core/manifest.rs:360:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:407:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:410:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:413:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:416:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:419:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:422:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:425:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:431:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:438:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:444:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:447:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:450:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:453:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:456:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:459:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:462:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:466:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:470:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:477:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:481:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:488:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/manifest.rs:512:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:516:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:520:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:524:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:528:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:538:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:557:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:561:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:565:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:569:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:577:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:581:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:588:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:617:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:632:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:648:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:659:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:66:1: item name ends with its containing module's name +cargo-0.49.0/src/cargo/core/manifest.rs:670:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:693:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:708:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:723:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:726:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:729:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:735:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:738:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:741:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:744:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:747:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:751:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:754:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:757:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:760:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:763:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:767:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:776:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:780:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:787:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:798:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:800:56: redundant closure found +cargo-0.49.0/src/cargo/core/manifest.rs:805:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:809:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:818:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:823:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:828:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:831:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:834:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:839:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:85:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/core/manifest.rs:888:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/manifest.rs:936:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/package.rs:1075:28: redundant closure found +cargo-0.49.0/src/cargo/core/package.rs:160:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/package.rs:170:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/package.rs:174:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/package.rs:182:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/package.rs:186:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/package.rs:190:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/package.rs:194:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/package.rs:198:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/package.rs:202:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/package.rs:206:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/package.rs:210:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/package.rs:217:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/package.rs:221:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/package.rs:222:35: redundant closure found +cargo-0.49.0/src/cargo/core/package.rs:226:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/package.rs:227:35: redundant closure found +cargo-0.49.0/src/cargo/core/package.rs:230:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/package.rs:239:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/package.rs:249:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/package.rs:287:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/core/package.rs:385:5: docs for function returning `Result` missing `# Errors` section cargo-0.49.0/src/cargo/core/package.rs:421:5: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) +cargo-0.49.0/src/cargo/core/package.rs:425:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/package.rs:452:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/package.rs:453:60: redundant closure found +cargo-0.49.0/src/cargo/core/package.rs:459:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/package.rs:473:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/package.rs:587:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/package.rs:682:46: casting `f64` to `u64` may lose the sign of the value +cargo-0.49.0/src/cargo/core/package.rs:682:46: casting `f64` to `u64` may truncate the value +cargo-0.49.0/src/cargo/core/package.rs:682:63: casting `f64` to `u64` may lose the sign of the value +cargo-0.49.0/src/cargo/core/package.rs:682:63: casting `f64` to `u64` may truncate the value +cargo-0.49.0/src/cargo/core/package.rs:731:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/package.rs:790:13: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +cargo-0.49.0/src/cargo/core/package.rs:988:9: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +cargo-0.49.0/src/cargo/core/package_id.rs:115:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/package_id.rs:124:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/package_id.rs:139:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/package_id.rs:142:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/package_id.rs:145:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/package_id.rs:149:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/package_id.rs:157:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/package_id.rs:161:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/package_id.rs:169:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/package_id.rs:174:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/core/package_id_spec.rs:101:39: redundant closure found +cargo-0.49.0/src/cargo/core/package_id_spec.rs:143:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/package_id_spec.rs:147:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/package_id_spec.rs:151:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/package_id_spec.rs:160:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/package_id_spec.rs:179:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/package_id_spec.rs:212:9: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/core/package_id_spec.rs:231:9: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +cargo-0.49.0/src/cargo/core/package_id_spec.rs:51:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/package_id_spec.rs:77:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/package_id_spec.rs:88:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/profiles.rs:1004:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/profiles.rs:1014:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/profiles.rs:1018:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/profiles.rs:1028:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/profiles.rs:106:9: adding items after statements is confusing, since items exist from the start of the scope cargo-0.49.0/src/cargo/core/profiles.rs:143:5: this function's return value is unnecessarily wrapped by `Result` +cargo-0.49.0/src/cargo/core/profiles.rs:286:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/profiles.rs:294:40: unnecessary boolean `not` operation +cargo-0.49.0/src/cargo/core/profiles.rs:30:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/profiles.rs:342:25: `maker` is being shadowed +cargo-0.49.0/src/cargo/core/profiles.rs:370:41: unused `self` argument +cargo-0.49.0/src/cargo/core/profiles.rs:370:5: this method could have a `#[must_use]` attribute cargo-0.49.0/src/cargo/core/profiles.rs:372:9: field assignment outside of initializer for an instance created with Default::default() +cargo-0.49.0/src/cargo/core/profiles.rs:382:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/profiles.rs:383:28: unnecessary boolean `not` operation +cargo-0.49.0/src/cargo/core/profiles.rs:397:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/profiles.rs:405:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/profiles.rs:607:1: more than 3 bools in a struct +cargo-0.49.0/src/cargo/core/profiles.rs:909:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/profiles.rs:923:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/profiles.rs:934:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/profiles.rs:987:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/registry.rs:111:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/registry.rs:127:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/registry.rs:168:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/registry.rs:19:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/registry.rs:240:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/registry.rs:26:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/registry.rs:344:49: redundant closure found +cargo-0.49.0/src/cargo/core/registry.rs:369:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/registry.rs:424:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/registry.rs:49:1: item name ends with its containing module's name +cargo-0.49.0/src/cargo/core/registry.rs:520:17: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +cargo-0.49.0/src/cargo/core/registry.rs:763:53: redundant closure found +cargo-0.49.0/src/cargo/core/registry.rs:765:53: redundant closure found +cargo-0.49.0/src/cargo/core/registry.rs:807:14: redundant closure found +cargo-0.49.0/src/cargo/core/registry.rs:814:53: redundant closure found +cargo-0.49.0/src/cargo/core/resolver/conflict_cache.rs:197:29: redundant closure found +cargo-0.49.0/src/cargo/core/resolver/conflict_cache.rs:41:38: called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead +cargo-0.49.0/src/cargo/core/resolver/context.rs:274:53: redundant closure found +cargo-0.49.0/src/cargo/core/resolver/context.rs:297:9: called `filter(..).map(..)` on an `Iterator` +cargo-0.49.0/src/cargo/core/resolver/context.rs:42:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/core/resolver/context.rs:74:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/resolver/encode.rs:156:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/resolver/encode.rs:156:5: this function has too many lines (164/100) +cargo-0.49.0/src/cargo/core/resolver/encode.rs:339:17: wildcard match will miss any future added variants +cargo-0.49.0/src/cargo/core/resolver/encode.rs:438:5: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/core/resolver/encode.rs:449:5: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/core/resolver/encode.rs:529:34: redundant closure found +cargo-0.49.0/src/cargo/core/resolver/encode.rs:602:59: redundant closure found +cargo-0.49.0/src/cargo/core/resolver/encode.rs:623:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/core/resolver/encode.rs:652:27: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +cargo-0.49.0/src/cargo/core/resolver/encode.rs:674:51: redundant closure found +cargo-0.49.0/src/cargo/core/resolver/errors.rs:103:22: redundant closure found +cargo-0.49.0/src/cargo/core/resolver/errors.rs:104:22: redundant closure found +cargo-0.49.0/src/cargo/core/resolver/errors.rs:206:9: unnecessary boolean `not` operation +cargo-0.49.0/src/cargo/core/resolver/errors.rs:257:45: redundant closure found +cargo-0.49.0/src/cargo/core/resolver/errors.rs:27:5: this method could have a `#[must_use]` attribute cargo-0.49.0/src/cargo/core/resolver/errors.rs:305:17: calling `push_str()` using a single-character string literal +cargo-0.49.0/src/cargo/core/resolver/errors.rs:70:1: this function has too many lines (207/100) +cargo-0.49.0/src/cargo/core/resolver/features.rs:104:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/core/resolver/features.rs:111:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/resolver/features.rs:162:56: redundant closure found +cargo-0.49.0/src/cargo/core/resolver/features.rs:179:1: item name ends with its containing module's name +cargo-0.49.0/src/cargo/core/resolver/features.rs:186:23: you should put `RequestedFeatures` between ticks in the documentation +cargo-0.49.0/src/cargo/core/resolver/features.rs:187:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/resolver/features.rs:199:23: you should put `RequestedFeatures` between ticks in the documentation +cargo-0.49.0/src/cargo/core/resolver/features.rs:200:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/resolver/features.rs:209:9: called `filter(..).map(..)` on an `Iterator` +cargo-0.49.0/src/cargo/core/resolver/features.rs:221:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/resolver/features.rs:231:21: you should put `pkg_id/is_build` between ticks in the documentation +cargo-0.49.0/src/cargo/core/resolver/features.rs:233:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/resolver/features.rs:247:58: redundant closure found +cargo-0.49.0/src/cargo/core/resolver/features.rs:278:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/resolver/features.rs:394:27: you should put `FeatureValue` between ticks in the documentation +cargo-0.49.0/src/cargo/core/resolver/features.rs:460:19: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +cargo-0.49.0/src/cargo/core/resolver/features.rs:480:24: you should put `FeatureValues` between ticks in the documentation +cargo-0.49.0/src/cargo/core/resolver/features.rs:496:24: you should put `FeatureValues` between ticks in the documentation +cargo-0.49.0/src/cargo/core/resolver/features.rs:561:28: called `filter(..).map(..)` on an `Iterator` +cargo-0.49.0/src/cargo/core/resolver/features.rs:58:1: item name ends with its containing module's name +cargo-0.49.0/src/cargo/core/resolver/features.rs:67:1: more than 3 bools in a struct +cargo-0.49.0/src/cargo/core/resolver/mod.rs:1017:5: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/core/resolver/mod.rs:1045:57: redundant closure found +cargo-0.49.0/src/cargo/core/resolver/mod.rs:122:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/resolver/mod.rs:142:44: redundant closure found +cargo-0.49.0/src/cargo/core/resolver/mod.rs:180:1: this function has too many lines (225/100) +cargo-0.49.0/src/cargo/core/resolver/mod.rs:311:17: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +cargo-0.49.0/src/cargo/core/resolver/mod.rs:421:52: called `filter_map(..).next()` on an `Iterator`. This is more succinctly expressed by calling `.find_map(..)` instead. +cargo-0.49.0/src/cargo/core/resolver/mod.rs:437:33: called `filter(..).map(..)` on an `Iterator` +cargo-0.49.0/src/cargo/core/resolver/mod.rs:457:69: called `filter_map(..).next()` on an `Iterator`. This is more succinctly expressed by calling `.find_map(..)` instead. +cargo-0.49.0/src/cargo/core/resolver/mod.rs:470:37: binding's name is too similar to existing binding +cargo-0.49.0/src/cargo/core/resolver/mod.rs:480:37: called `filter(..).map(..)` on an `Iterator` +cargo-0.49.0/src/cargo/core/resolver/mod.rs:607:11: this argument is passed by value, but not consumed in the function body +cargo-0.49.0/src/cargo/core/resolver/mod.rs:631:21: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +cargo-0.49.0/src/cargo/core/resolver/mod.rs:942:15: unnecessary boolean `not` operation +cargo-0.49.0/src/cargo/core/resolver/mod.rs:988:20: redundant else block +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:120:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:132:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:199:24: redundant else block +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:235:5: this method could have a `#[must_use]` attribute cargo-0.49.0/src/cargo/core/resolver/resolve.rs:239:5: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:255:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:259:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:263:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:269:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:273:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:274:9: called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:280:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:284:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:288:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:292:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:296:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:300:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:315:13: called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:354:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:362:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:60:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:76:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:90:35: called `filter(..).map(..)` on an `Iterator` +cargo-0.49.0/src/cargo/core/resolver/types.rs:111:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/resolver/types.rs:121:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/resolver/types.rs:141:19: you should put `ResolveOpts` between ticks in the documentation +cargo-0.49.0/src/cargo/core/resolver/types.rs:142:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/resolver/types.rs:149:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/resolver/types.rs:181:9: called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead cargo-0.49.0/src/cargo/core/resolver/types.rs:187:5: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) cargo-0.49.0/src/cargo/core/resolver/types.rs:261:5: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) +cargo-0.49.0/src/cargo/core/shell.rs:113:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/shell.rs:130:9: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +cargo-0.49.0/src/cargo/core/shell.rs:148:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/shell.rs:153:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/shell.rs:163:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/shell.rs:18:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/shell.rs:198:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/shell.rs:206:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/shell.rs:214:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/shell.rs:228:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/shell.rs:239:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/shell.rs:250:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/shell.rs:259:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/shell.rs:267:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/shell.rs:26:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/shell.rs:277:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/shell.rs:282:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/shell.rs:314:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/shell.rs:322:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/shell.rs:330:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/shell.rs:98:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/source/mod.rs:103:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/source/mod.rs:247:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/core/source/mod.rs:261:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/source/mod.rs:268:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/source/mod.rs:273:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/source/mod.rs:291:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/source/mod.rs:302:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/source/mod.rs:307:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/source/mod.rs:31:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/source/mod.rs:37:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/source/mod.rs:39:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/source/mod.rs:47:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/source/mod.rs:50:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/source/mod.rs:52:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/source/mod.rs:63:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/source/mod.rs:74:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/source/mod.rs:83:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/source/source_id.rs:107:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/source/source_id.rs:128:50: redundant closure found +cargo-0.49.0/src/cargo/core/source/source_id.rs:147:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/source/source_id.rs:156:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/source/source_id.rs:162:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/source/source_id.rs:166:19: you should put `SourceId` between ticks in the documentation +cargo-0.49.0/src/cargo/core/source/source_id.rs:167:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/source/source_id.rs:171:19: you should put `SourceId` between ticks in the documentation +cargo-0.49.0/src/cargo/core/source/source_id.rs:172:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/source/source_id.rs:178:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/source/source_id.rs:187:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/source/source_id.rs:18:74: calling `std::sync::Mutex::default()` is more clear than this expression +cargo-0.49.0/src/cargo/core/source/source_id.rs:195:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/source/source_id.rs:207:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/source/source_id.rs:213:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/source/source_id.rs:217:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/source/source_id.rs:225:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/source/source_id.rs:228:16: use Option::map_or_else instead of an if let/else +cargo-0.49.0/src/cargo/core/source/source_id.rs:236:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/source/source_id.rs:241:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/source/source_id.rs:252:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/source/source_id.rs:257:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/source/source_id.rs:262:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/source/source_id.rs:305:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/source/source_id.rs:310:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/source/source_id.rs:318:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/source/source_id.rs:326:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/source/source_id.rs:355:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/source/source_id.rs:393:61: this `match` has identical arm bodies +cargo-0.49.0/src/cargo/core/source/source_id.rs:394:42: this `match` has identical arm bodies +cargo-0.49.0/src/cargo/core/source/source_id.rs:395:42: this `match` has identical arm bodies +cargo-0.49.0/src/cargo/core/source/source_id.rs:397:71: this `match` has identical arm bodies +cargo-0.49.0/src/cargo/core/source/source_id.rs:397:71: this `match` has identical arm bodies +cargo-0.49.0/src/cargo/core/source/source_id.rs:398:47: this `match` has identical arm bodies +cargo-0.49.0/src/cargo/core/source/source_id.rs:398:47: this `match` has identical arm bodies +cargo-0.49.0/src/cargo/core/source/source_id.rs:399:47: this `match` has identical arm bodies +cargo-0.49.0/src/cargo/core/source/source_id.rs:399:47: this `match` has identical arm bodies +cargo-0.49.0/src/cargo/core/source/source_id.rs:401:63: this `match` has identical arm bodies +cargo-0.49.0/src/cargo/core/source/source_id.rs:401:63: this `match` has identical arm bodies +cargo-0.49.0/src/cargo/core/source/source_id.rs:401:63: this `match` has identical arm bodies +cargo-0.49.0/src/cargo/core/source/source_id.rs:402:43: this `match` has identical arm bodies +cargo-0.49.0/src/cargo/core/source/source_id.rs:402:43: this `match` has identical arm bodies +cargo-0.49.0/src/cargo/core/source/source_id.rs:402:43: this `match` has identical arm bodies +cargo-0.49.0/src/cargo/core/source/source_id.rs:403:43: this `match` has identical arm bodies +cargo-0.49.0/src/cargo/core/source/source_id.rs:403:43: this `match` has identical arm bodies +cargo-0.49.0/src/cargo/core/source/source_id.rs:403:43: this `match` has identical arm bodies +cargo-0.49.0/src/cargo/core/source/source_id.rs:406:21: usage of wildcard import for enum variants +cargo-0.49.0/src/cargo/core/source/source_id.rs:412:41: this `match` has identical arm bodies +cargo-0.49.0/src/cargo/core/source/source_id.rs:413:36: this `match` has identical arm bodies +cargo-0.49.0/src/cargo/core/source/source_id.rs:414:36: this `match` has identical arm bodies +cargo-0.49.0/src/cargo/core/source/source_id.rs:420:47: this `match` has identical arm bodies +cargo-0.49.0/src/cargo/core/source/source_id.rs:420:47: this `match` has identical arm bodies +cargo-0.49.0/src/cargo/core/source/source_id.rs:494:42: this `match` has identical arm bodies +cargo-0.49.0/src/cargo/core/source/source_id.rs:512:17: integer type suffix should be separated by an underscore +cargo-0.49.0/src/cargo/core/source/source_id.rs:513:17: integer type suffix should be separated by an underscore +cargo-0.49.0/src/cargo/core/source/source_id.rs:517:17: integer type suffix should be separated by an underscore +cargo-0.49.0/src/cargo/core/source/source_id.rs:518:17: integer type suffix should be separated by an underscore +cargo-0.49.0/src/cargo/core/source/source_id.rs:525:17: integer type suffix should be separated by an underscore +cargo-0.49.0/src/cargo/core/source/source_id.rs:526:17: integer type suffix should be separated by an underscore +cargo-0.49.0/src/cargo/core/source/source_id.rs:530:17: integer type suffix should be separated by an underscore +cargo-0.49.0/src/cargo/core/source/source_id.rs:531:17: integer type suffix should be separated by an underscore +cargo-0.49.0/src/cargo/core/source/source_id.rs:535:33: integer type suffix should be separated by an underscore +cargo-0.49.0/src/cargo/core/source/source_id.rs:536:37: integer type suffix should be separated by an underscore +cargo-0.49.0/src/cargo/core/source/source_id.rs:537:42: integer type suffix should be separated by an underscore +cargo-0.49.0/src/cargo/core/source/source_id.rs:538:38: integer type suffix should be separated by an underscore +cargo-0.49.0/src/cargo/core/source/source_id.rs:548:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/core/source/source_id.rs:597:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/summary.rs:103:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/summary.rs:123:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/summary.rs:150:1: this function has too many lines (141/100) +cargo-0.49.0/src/cargo/core/summary.rs:158:9: usage of wildcard import for enum variants +cargo-0.49.0/src/cargo/core/summary.rs:181:21: unnecessary boolean `not` operation +cargo-0.49.0/src/cargo/core/summary.rs:192:28: redundant else block +cargo-0.49.0/src/cargo/core/summary.rs:258:32: redundant else block +cargo-0.49.0/src/cargo/core/summary.rs:281:28: redundant else block +cargo-0.49.0/src/cargo/core/summary.rs:303:28: redundant else block +cargo-0.49.0/src/cargo/core/summary.rs:321:51: this `match` has identical arm bodies +cargo-0.49.0/src/cargo/core/summary.rs:344:5: you should put `FeatureValue` between ticks in the documentation +cargo-0.49.0/src/cargo/core/summary.rs:350:85: you should put `FeatureValue` between ticks in the documentation +cargo-0.49.0/src/cargo/core/summary.rs:36:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/summary.rs:378:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/summary.rs:386:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/summary.rs:387:13: usage of wildcard import for enum variants +cargo-0.49.0/src/cargo/core/summary.rs:407:13: usage of wildcard import for enum variants +cargo-0.49.0/src/cargo/core/summary.rs:69:34: redundant closure found +cargo-0.49.0/src/cargo/core/summary.rs:75:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/summary.rs:78:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/summary.rs:81:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/summary.rs:84:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/summary.rs:87:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/summary.rs:90:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/summary.rs:93:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/summary.rs:96:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/summary.rs:99:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/workspace.rs:1019:59: called `filter(..).map(..)` on an `Iterator` cargo-0.49.0/src/cargo/core/workspace.rs:1056:5: this function's return value is unnecessarily wrapped by `Result` +cargo-0.49.0/src/cargo/core/workspace.rs:113:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/core/workspace.rs:1157:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/core/workspace.rs:128:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/core/workspace.rs:150:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/workspace.rs:159:16: redundant else block +cargo-0.49.0/src/cargo/core/workspace.rs:197:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/workspace.rs:225:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/workspace.rs:255:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/workspace.rs:267:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/workspace.rs:329:37: you should put `VirtualManifest` between ticks in the documentation +cargo-0.49.0/src/cargo/core/workspace.rs:410:5: docs for function returning `Result` missing `# Errors` section cargo-0.49.0/src/cargo/core/workspace.rs:440:9: this function's return value is unnecessarily wrapped by `Result` +cargo-0.49.0/src/cargo/core/workspace.rs:511:32: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +cargo-0.49.0/src/cargo/core/workspace.rs:561:25: literal non-ASCII character detected +cargo-0.49.0/src/cargo/core/workspace.rs:613:13: called `filter_map(..).map(..)` on an `Iterator` +cargo-0.49.0/src/cargo/core/workspace.rs:615:22: redundant closure found +cargo-0.49.0/src/cargo/core/workspace.rs:688:35: called `filter(..).map(..)` on an `Iterator` +cargo-0.49.0/src/cargo/core/workspace.rs:762:27: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +cargo-0.49.0/src/cargo/core/workspace.rs:784:17: unnecessary boolean `not` operation +cargo-0.49.0/src/cargo/core/workspace.rs:849:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/workspace.rs:893:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/core/workspace.rs:906:24: redundant else block +cargo-0.49.0/src/cargo/core/workspace.rs:932:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/lib.rs:177:1: this function could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/lib.rs:180:36: redundant closure found +cargo-0.49.0/src/cargo/lib.rs:180:36: redundant closure found +cargo-0.49.0/src/cargo/lib.rs:180:36: redundant closure found +cargo-0.49.0/src/cargo/lib.rs:180:36: redundant closure found +cargo-0.49.0/src/cargo/lib.rs:180:36: redundant closure found +cargo-0.49.0/src/cargo/ops/cargo_clean.rs:205:23: redundant closure found +cargo-0.49.0/src/cargo/ops/cargo_clean.rs:27:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/cargo_clean.rs:27:1: this function has too many lines (120/100) +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:1078:14: redundant closure found +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:109:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:119:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:1227:17: this argument is passed by value, but not consumed in the function body cargo-0.49.0/src/cargo/ops/cargo_compile.rs:127:35: usage of `FromIterator::from_iter` +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:128:32: called `filter(..).map(..)` on an `Iterator` +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:173:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:205:36: this `match` has identical arm bodies +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:242:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:249:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:258:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:275:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:275:1: this function has too many lines (219/100) +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:468:9: calling `std::collections::HashMap::default()` is more clear than this expression +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:548:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:556:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:574:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:583:21: you should put `CompileFilter` between ticks in the documentation +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:584:5: more than 3 bools in function parameters +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:584:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:592:9: binding's name is too similar to existing binding +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:593:9: binding's name is too similar to existing binding +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:607:13: binding's name is too similar to existing binding +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:612:21: you should put `CompileFilter` between ticks in the documentation +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:613:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:618:9: binding's name is too similar to existing binding +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:641:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:652:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:655:50: this `match` has identical arm bodies +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:673:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:692:49: this `match` has identical arm bodies +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:703:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:729:1: this function has too many lines (205/100) +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:82:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:874:69: redundant closure found +cargo-0.49.0/src/cargo/ops/cargo_doc.rs:20:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/cargo_fetch.rs:15:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/cargo_fetch.rs:27:46: redundant closure found +cargo-0.49.0/src/cargo/ops/cargo_fetch.rs:36:20: called `filter(..).map(..)` on an `Iterator` +cargo-0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:160:5: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:175:5: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:22:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:37:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:37:1: this function has too many lines (171/100) +cargo-0.49.0/src/cargo/ops/cargo_install.rs:13:5: usage of wildcard import +cargo-0.49.0/src/cargo/ops/cargo_install.rs:148:1: more than 3 bools in function parameters +cargo-0.49.0/src/cargo/ops/cargo_install.rs:148:1: this function has too many lines (316/100) +cargo-0.49.0/src/cargo/ops/cargo_install.rs:202:17: redundant closure found +cargo-0.49.0/src/cargo/ops/cargo_install.rs:312:64: redundant closure found +cargo-0.49.0/src/cargo/ops/cargo_install.rs:318:63: called `filter(..).map(..)` on an `Iterator` +cargo-0.49.0/src/cargo/ops/cargo_install.rs:32:13: non-binding `let` on a type that implements `Drop` +cargo-0.49.0/src/cargo/ops/cargo_install.rs:37:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/cargo_install.rs:454:22: redundant closure found +cargo-0.49.0/src/cargo/ops/cargo_install.rs:483:5: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/ops/cargo_install.rs:683:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/cargo_new.rs:101:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/cargo_new.rs:245:5: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/ops/cargo_new.rs:251:5: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/ops/cargo_new.rs:367:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/cargo_new.rs:405:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/cargo_new.rs:489:5: you should put `IgnoreList` between ticks in the documentation +cargo-0.49.0/src/cargo/ops/cargo_new.rs:525:47: you should put `IgnoreList` between ticks in the documentation +cargo-0.49.0/src/cargo/ops/cargo_new.rs:525:9: you should put `format_existing` between ticks in the documentation +cargo-0.49.0/src/cargo/ops/cargo_new.rs:572:34: this `match` has identical arm bodies +cargo-0.49.0/src/cargo/ops/cargo_new.rs:623:1: this function has too many lines (130/100) +cargo-0.49.0/src/cargo/ops/cargo_new.rs:781:5: called `filter_map(..).next()` on an `Iterator`. This is more succinctly expressed by calling `.find_map(..)` instead. +cargo-0.49.0/src/cargo/ops/cargo_new.rs:800:16: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +cargo-0.49.0/src/cargo/ops/cargo_output_metadata.rs:163:36: redundant closure found +cargo-0.49.0/src/cargo/ops/cargo_output_metadata.rs:27:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/cargo_output_metadata.rs:45:45: redundant closure found +cargo-0.49.0/src/cargo/ops/cargo_package.rs:144:1: this function has too many lines (112/100) +cargo-0.49.0/src/cargo/ops/cargo_package.rs:207:13: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +cargo-0.49.0/src/cargo/ops/cargo_package.rs:25:1: more than 3 bools in a struct +cargo-0.49.0/src/cargo/ops/cargo_package.rs:307:54: redundant closure found +cargo-0.49.0/src/cargo/ops/cargo_package.rs:394:5: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/ops/cargo_package.rs:418:21: called `filter(..).map(..)` on an `Iterator` +cargo-0.49.0/src/cargo/ops/cargo_package.rs:425:61: redundant closure found +cargo-0.49.0/src/cargo/ops/cargo_package.rs:459:5: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/ops/cargo_package.rs:66:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/cargo_package.rs:769:29: called `filter(..).map(..)` on an `Iterator` +cargo-0.49.0/src/cargo/ops/cargo_package.rs:93:20: unnecessary boolean `not` operation +cargo-0.49.0/src/cargo/ops/cargo_pkgid.rs:5:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/cargo_read_manifest.rs:14:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/cargo_read_manifest.rs:171:5: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/ops/cargo_read_manifest.rs:37:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/cargo_read_manifest.rs:57:49: redundant closure found +cargo-0.49.0/src/cargo/ops/cargo_read_manifest.rs:69:37: redundant closure found +cargo-0.49.0/src/cargo/ops/cargo_run.rs:25:24: unnecessary boolean `not` operation +cargo-0.49.0/src/cargo/ops/cargo_run.rs:35:9: unnecessary boolean `not` operation +cargo-0.49.0/src/cargo/ops/cargo_run.rs:37:16: redundant else block +cargo-0.49.0/src/cargo/ops/cargo_run.rs:53:9: unnecessary boolean `not` operation +cargo-0.49.0/src/cargo/ops/cargo_run.rs:65:16: redundant else block +cargo-0.49.0/src/cargo/ops/cargo_run.rs:9:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/cargo_test.rs:16:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/cargo_test.rs:43:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/cargo_test.rs:84:17: binding's name is too similar to existing binding +cargo-0.49.0/src/cargo/ops/cargo_uninstall.rs:14:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/cargo_uninstall.rs:7:5: usage of wildcard import +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:147:9: you should put `PackageId` between ticks in the documentation cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:233:21: calling `push_str()` using a single-character string literal +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:244:22: you should put `PackageId` between ticks in the documentation +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:244:63: you should put `PackageId` between ticks in the documentation +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:253:17: unnecessary boolean `not` operation cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:370:5: this function's return value is unnecessarily wrapped by `Result` +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:392:9: called `find(..).map(..)` on an `Iterator` +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:505:8: called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:525:10: this argument is passed by value, but not consumed in the function body +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:542:27: redundant closure found +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:542:5: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:561:20: redundant else block +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:613:5: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:645:41: you should put `BTreeSet` between ticks in the documentation +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:654:42: called `filter(..).map(..)` on an `Iterator` +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:662:14: called `filter(..).map(..)` on an `Iterator` +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:674:17: called `filter(..).map(..)` on an `Iterator` +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:681:17: called `filter(..).map(..)` on an `Iterator` +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:92:19: you should put `InstallTracker` between ticks in the documentation +cargo-0.49.0/src/cargo/ops/fix.rs:200:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/fix.rs:200:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/ops/fix.rs:424:20: called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead +cargo-0.49.0/src/cargo/ops/fix.rs:455:13: binding's name is too similar to existing binding +cargo-0.49.0/src/cargo/ops/fix.rs:506:17: binding's name is too similar to existing binding cargo-0.49.0/src/cargo/ops/fix.rs:608:9: field assignment outside of initializer for an instance created with Default::default() +cargo-0.49.0/src/cargo/ops/fix.rs:612:42: redundant closure found cargo-0.49.0/src/cargo/ops/fix.rs:619:48: stripping a prefix manually +cargo-0.49.0/src/cargo/ops/fix.rs:66:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/ops/fix.rs:66:1: more than 3 bools in a struct +cargo-0.49.0/src/cargo/ops/fix.rs:708:18: this `match` has identical arm bodies +cargo-0.49.0/src/cargo/ops/fix.rs:77:1: docs for function returning `Result` missing `# Errors` section cargo-0.49.0/src/cargo/ops/lockfile.rs:154:13: calling `push_str()` using a single-character string literal cargo-0.49.0/src/cargo/ops/lockfile.rs:217:9: calling `push_str()` using a single-character string literal +cargo-0.49.0/src/cargo/ops/lockfile.rs:30:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/lockfile.rs:35:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/lockfile.rs:35:1: item name ends with its containing module's name cargo-0.49.0/src/cargo/ops/lockfile.rs:87:1: this function's return value is unnecessarily wrapped by `Result` +cargo-0.49.0/src/cargo/ops/lockfile.rs:8:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/lockfile.rs:8:1: item name ends with its containing module's name +cargo-0.49.0/src/cargo/ops/registry.rs:150:21: redundant closure found +cargo-0.49.0/src/cargo/ops/registry.rs:188:1: this function has too many lines (130/100) +cargo-0.49.0/src/cargo/ops/registry.rs:196:16: called `filter(..).map(..)` on an `Iterator` +cargo-0.49.0/src/cargo/ops/registry.rs:212:32: unnecessary `!=` operation +cargo-0.49.0/src/cargo/ops/registry.rs:222:53: redundant closure found +cargo-0.49.0/src/cargo/ops/registry.rs:224:44: redundant closure found +cargo-0.49.0/src/cargo/ops/registry.rs:31:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/ops/registry.rs:346:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/registry.rs:346:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/ops/registry.rs:351:26: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +cargo-0.49.0/src/cargo/ops/registry.rs:385:12: this argument is passed by value, but not consumed in the function body +cargo-0.49.0/src/cargo/ops/registry.rs:386:15: this argument is passed by value, but not consumed in the function body +cargo-0.49.0/src/cargo/ops/registry.rs:38:1: more than 3 bools in a struct +cargo-0.49.0/src/cargo/ops/registry.rs:477:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/registry.rs:483:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/registry.rs:503:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/registry.rs:505:38: calling `util::config::CargoHttpConfig::default()` is more clear than this expression +cargo-0.49.0/src/cargo/ops/registry.rs:510:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/registry.rs:529:5: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/ops/registry.rs:53:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/registry.rs:573:22: this `match` has identical arm bodies +cargo-0.49.0/src/cargo/ops/registry.rs:608:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/registry.rs:621:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/registry.rs:671:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/registry.rs:671:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/ops/registry.rs:674:10: this argument is passed by value, but not consumed in the function body +cargo-0.49.0/src/cargo/ops/registry.rs:678:17: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +cargo-0.49.0/src/cargo/ops/registry.rs:730:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/registry.rs:731:16: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +cargo-0.49.0/src/cargo/ops/registry.rs:785:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/registry.rs:794:16: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +cargo-0.49.0/src/cargo/ops/registry.rs:828:14: you should put `SourceId` between ticks in the documentation +cargo-0.49.0/src/cargo/ops/registry.rs:848:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/resolve.rs:199:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/resolve.rs:199:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/ops/resolve.rs:199:1: this function has too many lines (137/100) +cargo-0.49.0/src/cargo/ops/resolve.rs:241:28: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +cargo-0.49.0/src/cargo/ops/resolve.rs:28:1: item name ends with its containing module's name +cargo-0.49.0/src/cargo/ops/resolve.rs:384:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/resolve.rs:417:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/resolve.rs:589:9: `keep` is being shadowed +cargo-0.49.0/src/cargo/ops/resolve.rs:58:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/resolve.rs:58:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/ops/resolve.rs:602:5: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/ops/resolve.rs:75:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/resolve.rs:75:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/ops/tree/graph.rs:129:26: you should put `PackageIds` between ticks in the documentation +cargo-0.49.0/src/cargo/ops/tree/graph.rs:131:47: called `filter(..).map(..)` on an `Iterator` +cargo-0.49.0/src/cargo/ops/tree/graph.rs:152:15: indexing into a vector may panic +cargo-0.49.0/src/cargo/ops/tree/graph.rs:173:9: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/ops/tree/graph.rs:234:46: called `filter(..).flat_map(..)` on an `Iterator` +cargo-0.49.0/src/cargo/ops/tree/graph.rs:328:44: this `match` has identical arm bodies +cargo-0.49.0/src/cargo/ops/tree/graph.rs:330:50: this `match` has identical arm bodies +cargo-0.49.0/src/cargo/ops/tree/graph.rs:563:35: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +cargo-0.49.0/src/cargo/ops/tree/mod.rs:112:11: literal non-ASCII character detected +cargo-0.49.0/src/cargo/ops/tree/mod.rs:113:10: literal non-ASCII character detected +cargo-0.49.0/src/cargo/ops/tree/mod.rs:114:10: literal non-ASCII character detected +cargo-0.49.0/src/cargo/ops/tree/mod.rs:115:12: literal non-ASCII character detected +cargo-0.49.0/src/cargo/ops/tree/mod.rs:126:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/tree/mod.rs:21:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/ops/tree/mod.rs:21:1: more than 3 bools in a struct +cargo-0.49.0/src/cargo/ops/tree/mod.rs:360:30: this `match` has identical arm bodies +cargo-0.49.0/src/cargo/ops/tree/mod.rs:58:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/ops/vendor.rs:14:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/ops/vendor.rs:21:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/ops/vendor.rs:314:34: this `match` has identical arm bodies +cargo-0.49.0/src/cargo/ops/vendor.rs:324:13: wildcard match will miss any future added variants +cargo-0.49.0/src/cargo/ops/vendor.rs:70:1: this function has too many lines (175/100) +cargo-0.49.0/src/cargo/sources/config.rs:102:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/sources/config.rs:135:67: redundant closure found +cargo-0.49.0/src/cargo/sources/config.rs:206:36: this argument is passed by value, but not consumed in the function body +cargo-0.49.0/src/cargo/sources/config.rs:282:9: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/sources/config.rs:70:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/sources/config.rs:81:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/sources/config.rs:97:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/sources/directory.rs:14:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/sources/directory.rs:90:56: redundant closure found +cargo-0.49.0/src/cargo/sources/git/source.rs:14:1: item name ends with its containing module's name +cargo-0.49.0/src/cargo/sources/git/source.rs:25:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/sources/git/source.rs:49:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/sources/git/source.rs:53:5: docs for function returning `Result` missing `# Errors` section cargo-0.49.0/src/cargo/sources/git/source.rs:69:20: comparison to empty slice +cargo-0.49.0/src/cargo/sources/git/utils.rs:1025:19: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` cargo-0.49.0/src/cargo/sources/git/utils.rs:1158:9: stripping a suffix manually +cargo-0.49.0/src/cargo/sources/git/utils.rs:176:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/sources/git/utils.rs:180:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/sources/git/utils.rs:184:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/sources/git/utils.rs:188:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/sources/git/utils.rs:242:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/sources/git/utils.rs:253:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/sources/git/utils.rs:262:13: unnecessary boolean `not` operation +cargo-0.49.0/src/cargo/sources/git/utils.rs:289:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/sources/git/utils.rs:294:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/sources/git/utils.rs:298:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/sources/git/utils.rs:308:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/sources/git/utils.rs:472:9: non-binding `let` on a type that implements `Drop` +cargo-0.49.0/src/cargo/sources/git/utils.rs:489:9: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/sources/git/utils.rs:503:9: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/sources/git/utils.rs:528:28: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +cargo-0.49.0/src/cargo/sources/git/utils.rs:537:21: non-binding `let` on a type that implements `Drop` +cargo-0.49.0/src/cargo/sources/git/utils.rs:588:1: this function has too many lines (135/100) cargo-0.49.0/src/cargo/sources/git/utils.rs:758:9: calling `push_str()` using a single-character string literal +cargo-0.49.0/src/cargo/sources/git/utils.rs:858:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/sources/path.rs:129:44: this `match` has identical arm bodies +cargo-0.49.0/src/cargo/sources/path.rs:143:44: this `match` has identical arm bodies +cargo-0.49.0/src/cargo/sources/path.rs:15:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/sources/path.rs:282:50: redundant closure found +cargo-0.49.0/src/cargo/sources/path.rs:313:21: binding's name is too similar to existing binding +cargo-0.49.0/src/cargo/sources/path.rs:314:21: binding's name is too similar to existing binding +cargo-0.49.0/src/cargo/sources/path.rs:319:21: binding's name is too similar to existing binding +cargo-0.49.0/src/cargo/sources/path.rs:339:9: adding items after statements is confusing, since items exist from the start of the scope cargo-0.49.0/src/cargo/sources/path.rs:339:9: this function's return value is unnecessarily wrapped by `Result` +cargo-0.49.0/src/cargo/sources/path.rs:380:9: unused `self` argument +cargo-0.49.0/src/cargo/sources/path.rs:419:50: redundant closure found +cargo-0.49.0/src/cargo/sources/path.rs:429:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/sources/path.rs:460:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/sources/path.rs:473:43: redundant closure found +cargo-0.49.0/src/cargo/sources/path.rs:482:43: redundant closure found +cargo-0.49.0/src/cargo/sources/path.rs:63:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/sources/path.rs:77:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/sources/path.rs:98:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/sources/registry/index.rs:117:23: integer type suffix should be separated by an underscore +cargo-0.49.0/src/cargo/sources/registry/index.rs:121:70: integer type suffix should be separated by an underscore +cargo-0.49.0/src/cargo/sources/registry/index.rs:167:1: item name ends with its containing module's name +cargo-0.49.0/src/cargo/sources/registry/index.rs:215:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/sources/registry/index.rs:324:23: redundant closure found +cargo-0.49.0/src/cargo/sources/registry/index.rs:393:25: called `filter(..).map(..)` on an `Iterator` +cargo-0.49.0/src/cargo/sources/registry/index.rs:468:40: you should put `SourceId` between ticks in the documentation +cargo-0.49.0/src/cargo/sources/registry/index.rs:590:9: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/sources/registry/index.rs:648:17: binding's name is too similar to existing binding cargo-0.49.0/src/cargo/sources/registry/index.rs:736:1: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) +cargo-0.49.0/src/cargo/sources/registry/index.rs:95:37: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers +cargo-0.49.0/src/cargo/sources/registry/local.rs:12:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/sources/registry/mod.rs:192:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/sources/registry/mod.rs:203:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/sources/registry/mod.rs:229:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/sources/registry/mod.rs:372:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/sources/registry/mod.rs:373:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/sources/registry/mod.rs:375:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/sources/registry/mod.rs:381:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/sources/registry/mod.rs:382:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/sources/registry/mod.rs:383:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/sources/registry/mod.rs:384:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/sources/registry/mod.rs:452:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/sources/registry/mod.rs:582:20: redundant else block +cargo-0.49.0/src/cargo/sources/registry/mod.rs:621:9: unnecessary `!=` operation +cargo-0.49.0/src/cargo/sources/registry/remote.rs:139:17: unused `self` argument +cargo-0.49.0/src/cargo/sources/registry/remote.rs:32:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/sources/registry/remote.rs:72:13: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +cargo-0.49.0/src/cargo/sources/replaced.rs:12:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/sources/replaced.rs:5:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/util/canonical_url.rs:19:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/canonical_url.rs:65:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/command_prelude.rs:218:1: this function could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/command_prelude.rs:222:1: this function could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/command_prelude.rs:234:1: this function could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/command_prelude.rs:249:1: this function could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/command_prelude.rs:264:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/command_prelude.rs:279:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/command_prelude.rs:298:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/command_prelude.rs:320:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/command_prelude.rs:328:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/command_prelude.rs:352:13: unnecessary boolean `not` operation +cargo-0.49.0/src/cargo/util/command_prelude.rs:363:13: unnecessary boolean `not` operation +cargo-0.49.0/src/cargo/util/command_prelude.rs:378:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/command_prelude.rs:387:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/command_prelude.rs:387:5: this function has too many lines (104/100) +cargo-0.49.0/src/cargo/util/command_prelude.rs:39:20: you should put `arg_package_spec` between ticks in the documentation +cargo-0.49.0/src/cargo/util/command_prelude.rs:504:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/command_prelude.rs:516:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/command_prelude.rs:530:40: redundant closure found +cargo-0.49.0/src/cargo/util/command_prelude.rs:531:43: redundant closure found +cargo-0.49.0/src/cargo/util/command_prelude.rs:536:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/command_prelude.rs:556:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/command_prelude.rs:575:49: redundant closure found +cargo-0.49.0/src/cargo/util/command_prelude.rs:580:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/command_prelude.rs:631:18: redundant closure found +cargo-0.49.0/src/cargo/util/command_prelude.rs:638:18: redundant closure found +cargo-0.49.0/src/cargo/util/command_prelude.rs:647:1: this function could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/command_prelude.rs:651:1: this function could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/command_prelude.rs:662:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/command_prelude.rs:665:51: this `match` has identical arm bodies +cargo-0.49.0/src/cargo/util/config/de.rs:420:16: this argument is passed by value, but not consumed in the function body +cargo-0.49.0/src/cargo/util/config/de.rs:46:25: you should put `CV::List` between ticks in the documentation +cargo-0.49.0/src/cargo/util/config/de.rs:47:24: you should put `ConfigSeqAccess` between ticks in the documentation +cargo-0.49.0/src/cargo/util/config/de.rs:527:53: integer type suffix should be separated by an underscore +cargo-0.49.0/src/cargo/util/config/de.rs:530:53: integer type suffix should be separated by an underscore +cargo-0.49.0/src/cargo/util/config/de.rs:532:68: integer type suffix should be separated by an underscore +cargo-0.49.0/src/cargo/util/config/key.rs:11:1: item name ends with its containing module's name cargo-0.49.0/src/cargo/util/config/key.rs:69:9: calling `push_str()` using a single-character string literal +cargo-0.49.0/src/cargo/util/config/mod.rs:100:71: you should put `OptValue` between ticks in the documentation +cargo-0.49.0/src/cargo/util/config/mod.rs:100:71: you should put `OptValue` between ticks in the documentation +cargo-0.49.0/src/cargo/util/config/mod.rs:100:71: you should put `OptValue` between ticks in the documentation +cargo-0.49.0/src/cargo/util/config/mod.rs:1049:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/config/mod.rs:1064:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/config/mod.rs:1090:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/config/mod.rs:1166:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/config/mod.rs:1179:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/config/mod.rs:1184:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/config/mod.rs:1189:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/config/mod.rs:1203:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/config/mod.rs:1211:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/config/mod.rs:1216:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/config/mod.rs:1225:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/config/mod.rs:1229:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/config/mod.rs:124:1: more than 3 bools in a struct +cargo-0.49.0/src/cargo/util/config/mod.rs:1254:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/config/mod.rs:1279:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/config/mod.rs:1281:9: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +cargo-0.49.0/src/cargo/util/config/mod.rs:1323:9: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/util/config/mod.rs:1339:39: unused `self` argument +cargo-0.49.0/src/cargo/util/config/mod.rs:1344:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/util/config/mod.rs:1420:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/util/config/mod.rs:1553:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/config/mod.rs:1560:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/config/mod.rs:1567:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/config/mod.rs:1574:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/config/mod.rs:1581:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/config/mod.rs:1588:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/config/mod.rs:1598:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/config/mod.rs:1619:1: this function could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/config/mod.rs:1623:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/config/mod.rs:1623:64: this argument is passed by value, but not consumed in the function body +cargo-0.49.0/src/cargo/util/config/mod.rs:1649:9: use Option::map_or_else instead of an if let/else +cargo-0.49.0/src/cargo/util/config/mod.rs:1699:5: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/util/config/mod.rs:1730:1: item name ends with its containing module's name +cargo-0.49.0/src/cargo/util/config/mod.rs:1757:1: item name ends with its containing module's name +cargo-0.49.0/src/cargo/util/config/mod.rs:1770:1: item name ends with its containing module's name +cargo-0.49.0/src/cargo/util/config/mod.rs:1778:1: item name ends with its containing module's name +cargo-0.49.0/src/cargo/util/config/mod.rs:1804:1: item name ends with its containing module's name +cargo-0.49.0/src/cargo/util/config/mod.rs:1896:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/config/mod.rs:1901:5: you should put `StringList` between ticks in the documentation +cargo-0.49.0/src/cargo/util/config/mod.rs:214:13: wildcard match will miss any future added variants +cargo-0.49.0/src/cargo/util/config/mod.rs:259:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/config/mod.rs:298:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/config/mod.rs:311:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/config/mod.rs:318:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/config/mod.rs:353:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/config/mod.rs:401:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/config/mod.rs:411:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/config/mod.rs:419:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/config/mod.rs:431:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/config/mod.rs:449:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/config/mod.rs:454:16: use Option::map_or instead of an if let/else +cargo-0.49.0/src/cargo/util/config/mod.rs:547:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/config/mod.rs:556:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/config/mod.rs:582:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/config/mod.rs:595:20: you should put `StringList` between ticks in the documentation +cargo-0.49.0/src/cargo/util/config/mod.rs:689:20: unused `self` argument +cargo-0.49.0/src/cargo/util/config/mod.rs:699:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/config/mod.rs:699:5: more than 3 bools in function parameters +cargo-0.49.0/src/cargo/util/config/mod.rs:719:58: redundant closure found +cargo-0.49.0/src/cargo/util/config/mod.rs:816:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/config/mod.rs:875:36: binding's name is too similar to existing binding +cargo-0.49.0/src/cargo/util/config/mod.rs:876:37: binding's name is too similar to existing binding +cargo-0.49.0/src/cargo/util/config/path.rs:10:1: item name ends with its containing module's name +cargo-0.49.0/src/cargo/util/config/path.rs:14:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/config/path.rs:48:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/util/config/target.rs:12:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/util/config/target.rs:24:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/util/config/value.rs:29:1: item name ends with its containing module's name +cargo-0.49.0/src/cargo/util/config/value.rs:80:5: this method could have a `#[must_use]` attribute cargo-0.49.0/src/cargo/util/config/value.rs:81:9: match expression looks like `matches!` macro +cargo-0.49.0/src/cargo/util/cpu.rs:11:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/cpu.rs:22:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/cpu.rs:82:25: casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +cargo-0.49.0/src/cargo/util/cpu.rs:82:9: casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +cargo-0.49.0/src/cargo/util/dependency_queue.rs:109:27: redundant closure found +cargo-0.49.0/src/cargo/util/dependency_queue.rs:136:20: called `filter(..).map(..)` on an `Iterator` +cargo-0.49.0/src/cargo/util/dependency_queue.rs:151:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/dependency_queue.rs:156:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/dependency_queue.rs:46:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/dependency_queue.rs:91:9: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/util/diagnostic_server.rs:218:1: item name ends with its containing module's name +cargo-0.49.0/src/cargo/util/diagnostic_server.rs:230:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/diagnostic_server.rs:242:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/diagnostic_server.rs:58:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/diagnostic_server.rs:96:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/diagnostic_server.rs:96:5: this function has too many lines (110/100) +cargo-0.49.0/src/cargo/util/diagnostic_server.rs:99:21: `msg` is being shadowed +cargo-0.49.0/src/cargo/util/errors.rs:101:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/errors.rs:143:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/errors.rs:150:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/errors.rs:15:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/errors.rs:237:5: variant name ends with the enum's name +cargo-0.49.0/src/cargo/util/errors.rs:245:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/errors.rs:321:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/errors.rs:328:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/errors.rs:356:1: this function could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/errors.rs:391:5: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/util/errors.rs:392:13: usage of wildcard import +cargo-0.49.0/src/cargo/util/errors.rs:465:1: this function could have a `#[must_use]` attribute cargo-0.49.0/src/cargo/util/errors.rs:473:5: manual `RangeInclusive::contains` implementation +cargo-0.49.0/src/cargo/util/errors.rs:66:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/flock.rs:115:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/flock.rs:11:5: usage of wildcard import +cargo-0.49.0/src/cargo/util/flock.rs:134:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/flock.rs:142:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/flock.rs:150:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/flock.rs:156:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/flock.rs:170:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/flock.rs:192:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/flock.rs:29:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/flock.rs:321:5: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/util/flock.rs:335:23: casting `i64` to `u32` may lose the sign of the value +cargo-0.49.0/src/cargo/util/flock.rs:335:23: casting `i64` to `u32` may truncate the value +cargo-0.49.0/src/cargo/util/flock.rs:335:44: casting `i64` to `u32` may truncate the value +cargo-0.49.0/src/cargo/util/flock.rs:379:35: this `match` has identical arm bodies +cargo-0.49.0/src/cargo/util/flock.rs:37:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/flock.rs:43:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/flock.rs:52:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/graph.rs:10:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/graph.rs:115:13: called `find(..).map(..)` on an `Iterator` +cargo-0.49.0/src/cargo/util/graph.rs:41:51: redundant closure found +cargo-0.49.0/src/cargo/util/graph.rs:45:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/graph.rs:95:13: called `find(..).map(..)` on an `Iterator` +cargo-0.49.0/src/cargo/util/hasher.rs:12:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/hasher.rs:9:1: item name ends with its containing module's name +cargo-0.49.0/src/cargo/util/hex.rs:10:9: casting `u64` to `u8` may truncate the value +cargo-0.49.0/src/cargo/util/hex.rs:11:9: casting `u64` to `u8` may truncate the value +cargo-0.49.0/src/cargo/util/hex.rs:12:9: casting `u64` to `u8` may truncate the value +cargo-0.49.0/src/cargo/util/hex.rs:13:9: casting `u64` to `u8` may truncate the value +cargo-0.49.0/src/cargo/util/hex.rs:14:9: casting `u64` to `u8` may truncate the value +cargo-0.49.0/src/cargo/util/hex.rs:15:9: casting `u64` to `u8` may truncate the value +cargo-0.49.0/src/cargo/util/hex.rs:25:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/hex.rs:6:1: item name ends with its containing module's name +cargo-0.49.0/src/cargo/util/hex.rs:6:1: this function could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/hex.rs:8:9: casting `u64` to `u8` may truncate the value +cargo-0.49.0/src/cargo/util/hex.rs:9:9: casting `u64` to `u8` may truncate the value +cargo-0.49.0/src/cargo/util/important_paths.rs:23:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/important_paths.rs:6:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/interning.rs:66:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/interning.rs:77:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/into_url.rs:10:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/into_url_with_base.rs:9:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/job.rs:20:1: this function could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/lev_distance.rs:3:1: this function could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/lockserver.rs:111:32: redundant else block +cargo-0.49.0/src/cargo/util/lockserver.rs:158:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/lockserver.rs:46:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/lockserver.rs:58:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/lockserver.rs:62:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/mod.rs:68:1: this function could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/mod.rs:79:1: this function could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/network.rs:12:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/network.rs:19:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/network.rs:84:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/paths.rs:109:12: redundant else block +cargo-0.49.0/src/cargo/util/paths.rs:114:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/paths.rs:121:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/paths.rs:125:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/paths.rs:130:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/paths.rs:14:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/paths.rs:14:1: item name ends with its containing module's name +cargo-0.49.0/src/cargo/util/paths.rs:151:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/paths.rs:167:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/paths.rs:173:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/paths.rs:178:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/paths.rs:185:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/paths.rs:199:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/paths.rs:215:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/paths.rs:228:1: this function could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/paths.rs:251:9: use Option::map_or instead of an if let/else +cargo-0.49.0/src/cargo/util/paths.rs:267:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/paths.rs:276:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/paths.rs:29:1: this function could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/paths.rs:303:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/paths.rs:312:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/paths.rs:346:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/paths.rs:415:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/paths.rs:445:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/paths.rs:459:45: redundant closure found +cargo-0.49.0/src/cargo/util/paths.rs:469:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/paths.rs:54:1: this function could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/paths.rs:61:1: this function could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/paths.rs:63:19: use Option::map_or_else instead of an if let/else +cargo-0.49.0/src/cargo/util/paths.rs:88:1: docs for function returning `Result` missing `# Errors` section cargo-0.49.0/src/cargo/util/paths.rs:93:31: comparison to empty slice +cargo-0.49.0/src/cargo/util/process_builder.rs:106:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/process_builder.rs:111:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/process_builder.rs:122:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/process_builder.rs:132:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/process_builder.rs:152:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/process_builder.rs:185:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/process_builder.rs:190:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/process_builder.rs:218:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/process_builder.rs:307:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/process_builder.rs:343:39: this argument is passed by value, but not consumed in the function body +cargo-0.49.0/src/cargo/util/progress.rs:122:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/progress.rs:136:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/progress.rs:15:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/util/progress.rs:249:19: casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +cargo-0.49.0/src/cargo/util/progress.rs:249:34: casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +cargo-0.49.0/src/cargo/util/progress.rs:250:19: unnecessary boolean `not` operation +cargo-0.49.0/src/cargo/util/progress.rs:263:22: casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +cargo-0.49.0/src/cargo/util/progress.rs:264:22: casting `f64` to `usize` may lose the sign of the value +cargo-0.49.0/src/cargo/util/progress.rs:264:22: casting `f64` to `usize` may truncate the value cargo-0.49.0/src/cargo/util/progress.rs:269:17: calling `push_str()` using a single-character string literal cargo-0.49.0/src/cargo/util/progress.rs:272:17: calling `push_str()` using a single-character string literal cargo-0.49.0/src/cargo/util/progress.rs:274:17: calling `push_str()` using a single-character string literal cargo-0.49.0/src/cargo/util/progress.rs:280:13: calling `push_str()` using a single-character string literal cargo-0.49.0/src/cargo/util/progress.rs:282:9: calling `push_str()` using a single-character string literal +cargo-0.49.0/src/cargo/util/progress.rs:89:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/progress.rs:97:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/queue.rs:25:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/read2.rs:11:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/read2.rs:31:17: binding's name is too similar to existing binding +cargo-0.49.0/src/cargo/util/restricted_names.rs:13:1: this function could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/restricted_names.rs:26:1: this function could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/restricted_names.rs:35:1: this function could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/restricted_names.rs:45:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/restricted_names.rs:87:1: this function could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/restricted_names.rs:89:21: redundant closure found +cargo-0.49.0/src/cargo/util/restricted_names.rs:8:1: this function could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/rustc.rs:103:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/rustc.rs:114:5: you should put bare URLs between `<`/`>` or make a proper Markdown link +cargo-0.49.0/src/cargo/util/rustc.rs:115:5: you should put bare URLs between `<`/`>` or make a proper Markdown link +cargo-0.49.0/src/cargo/util/rustc.rs:162:17: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/util/rustc.rs:39:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/rustc.rs:55:13: called `find(..).map(..)` on an `Iterator` +cargo-0.49.0/src/cargo/util/sha256.rs:10:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/sha256.rs:20:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/sha256.rs:31:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/sha256.rs:40:24: integer type suffix should be separated by an underscore +cargo-0.49.0/src/cargo/util/to_semver.rs:5:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/toml/mod.rs:1005:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/toml/mod.rs:1005:5: this function has too many lines (282/100) +cargo-0.49.0/src/cargo/util/toml/mod.rs:1094:36: redundant closure found +cargo-0.49.0/src/cargo/util/toml/mod.rs:1121:13: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/util/toml/mod.rs:1197:32: called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead +cargo-0.49.0/src/cargo/util/toml/mod.rs:124:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/toml/mod.rs:1504:9: unused `self` argument +cargo-0.49.0/src/cargo/util/toml/mod.rs:1526:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/toml/mod.rs:1582:19: calling `util::toml::DetailedTomlDependency::default()` is more clear than this expression +cargo-0.49.0/src/cargo/util/toml/mod.rs:1598:5: this function has too many lines (153/100) cargo-0.49.0/src/cargo/util/toml/mod.rs:1687:33: unnecessary closure used to substitute value for `Option::None` +cargo-0.49.0/src/cargo/util/toml/mod.rs:178:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/util/toml/mod.rs:248:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/util/toml/mod.rs:274:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/util/toml/mod.rs:277:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/toml/mod.rs:281:5: this method could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/toml/mod.rs:285:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/toml/mod.rs:294:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/util/toml/mod.rs:31:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/toml/mod.rs:381:35: casting `i64` to `u32` may lose the sign of the value +cargo-0.49.0/src/cargo/util/toml/mod.rs:381:35: casting `i64` to `u32` may truncate the value +cargo-0.49.0/src/cargo/util/toml/mod.rs:388:35: casting `u64` to `u32` may truncate the value +cargo-0.49.0/src/cargo/util/toml/mod.rs:398:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/util/toml/mod.rs:450:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/toml/mod.rs:536:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/toml/mod.rs:783:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/util/toml/mod.rs:824:1: item name starts with its containing module's name +cargo-0.49.0/src/cargo/util/toml/mod.rs:834:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/toml/mod.rs:83:42: redundant closure found +cargo-0.49.0/src/cargo/util/toml/mod.rs:852:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/toml/mod.rs:852:5: this function has too many lines (138/100) +cargo-0.49.0/src/cargo/util/toml/mod.rs:962:9: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/util/toml/mod.rs:971:24: called `filter(..).map(..)` on an `Iterator` +cargo-0.49.0/src/cargo/util/toml/mod.rs:979:9: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/util/toml/mod.rs:98:5: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/util/toml/mod.rs:999:23: calling `util::toml::DetailedTomlDependency::default()` is more clear than this expression +cargo-0.49.0/src/cargo/util/toml/targets.rs:112:27: redundant closure found +cargo-0.49.0/src/cargo/util/toml/targets.rs:325:5: adding items after statements is confusing, since items exist from the start of the scope +cargo-0.49.0/src/cargo/util/toml/targets.rs:586:21: redundant closure found +cargo-0.49.0/src/cargo/util/toml/targets.rs:593:42: redundant closure found +cargo-0.49.0/src/cargo/util/toml/targets.rs:605:19: redundant closure found +cargo-0.49.0/src/cargo/util/toml/targets.rs:612:42: redundant closure found +cargo-0.49.0/src/cargo/util/toml/targets.rs:756:36: redundant closure found +cargo-0.49.0/src/cargo/util/toml/targets.rs:810:24: called `filter(..).map(..)` on an `Iterator` +cargo-0.49.0/src/cargo/util/vcs.rs:10:1: this function could have a `#[must_use]` attribute +cargo-0.49.0/src/cargo/util/vcs.rs:33:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/vcs.rs:37:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/vcs.rs:43:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/vcs.rs:47:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/vcs.rs:59:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/vcs.rs:66:5: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/workspace.rs:52:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/workspace.rs:56:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/workspace.rs:60:1: docs for function returning `Result` missing `# Errors` section +cargo-0.49.0/src/cargo/util/workspace.rs:64:1: docs for function returning `Result` missing `# Errors` section +iron-0.6.1/src/error.rs:24:1: item name ends with its containing module's name iron-0.6.1/src/error.rs:55:20: use of deprecated associated function `std::error::Error::description`: use the Display impl or to_string() iron-0.6.1/src/iron.rs:105:13: redundant field names in struct initialization +iron-0.6.1/src/iron.rs:119:5: docs for function returning `Result` missing `# Errors` section +iron-0.6.1/src/iron.rs:133:5: docs for function returning `Result` missing `# Errors` section +iron-0.6.1/src/iron.rs:143:5: docs for function returning `Result` missing `# Errors` section iron-0.6.1/src/iron.rs:148:19: use of deprecated macro `try`: use the `?` operator instead iron-0.6.1/src/iron.rs:149:13: redundant field names in struct initialization +iron-0.6.1/src/iron.rs:167:49: binding's name is too similar to existing binding +iron-0.6.1/src/iron.rs:80:5: this method could have a `#[must_use]` attribute +iron-0.6.1/src/iron.rs:85:5: this method could have a `#[must_use]` attribute +iron-0.6.1/src/iron.rs:90:5: this method could have a `#[must_use]` attribute +iron-0.6.1/src/middleware/mod.rs:137:5: docs for function returning `Result` missing `# Errors` section +iron-0.6.1/src/middleware/mod.rs:150:1: item name ends with its containing module's name +iron-0.6.1/src/middleware/mod.rs:152:5: docs for function returning `Result` missing `# Errors` section +iron-0.6.1/src/middleware/mod.rs:159:5: docs for function returning `Result` missing `# Errors` section +iron-0.6.1/src/middleware/mod.rs:171:1: item name ends with its containing module's name +iron-0.6.1/src/middleware/mod.rs:173:5: docs for function returning `Result` missing `# Errors` section +iron-0.6.1/src/middleware/mod.rs:182:5: docs for function returning `Result` missing `# Errors` section +iron-0.6.1/src/middleware/mod.rs:192:1: item name ends with its containing module's name +iron-0.6.1/src/middleware/mod.rs:217:25: you should put `ChainBuilder` between ticks in the documentation +iron-0.6.1/src/middleware/mod.rs:328:20: binding's name is too similar to existing binding +iron-0.6.1/src/middleware/mod.rs:360:16: binding's name is too similar to existing binding +iron-0.6.1/src/middleware/mod.rs:368:33: binding's name is too similar to existing binding +iron-0.6.1/src/middleware/mod.rs:428:40: binding's name is too similar to existing binding +iron-0.6.1/src/middleware/mod.rs:434:40: binding's name is too similar to existing binding +iron-0.6.1/src/middleware/mod.rs:444:40: binding's name is too similar to existing binding iron-0.6.1/src/modifiers.rs:132:14: use of `expect` followed by a function call +iron-0.6.1/src/request/mod.rs:113:24: binding's name is too similar to existing binding iron-0.6.1/src/request/mod.rs:121:13: redundant field names in struct initialization iron-0.6.1/src/request/mod.rs:123:13: redundant field names in struct initialization iron-0.6.1/src/request/mod.rs:124:13: redundant field names in struct initialization iron-0.6.1/src/request/mod.rs:126:13: redundant field names in struct initialization iron-0.6.1/src/request/mod.rs:128:13: redundant field names in struct initialization +iron-0.6.1/src/request/mod.rs:153:69: you should put `HttpReader` between ticks in the documentation +iron-0.6.1/src/request/mod.rs:154:5: this method could have a `#[must_use]` attribute iron-0.6.1/src/request/mod.rs:32:1: this seems like a manual implementation of the non-exhaustive pattern iron-0.6.1/src/request/mod.rs:62:9: use of deprecated macro `try`: use the `?` operator instead iron-0.6.1/src/request/mod.rs:64:9: use of deprecated macro `try`: use the `?` operator instead @@ -56,83 +1414,231 @@ iron-0.6.1/src/request/mod.rs:65:9: use of deprecated macro `try`: use the `?` o iron-0.6.1/src/request/mod.rs:66:9: use of deprecated macro `try`: use the `?` operator instead iron-0.6.1/src/request/mod.rs:67:9: use of deprecated macro `try`: use the `?` operator instead iron-0.6.1/src/request/mod.rs:69:9: use of deprecated macro `try`: use the `?` operator instead +iron-0.6.1/src/request/mod.rs:75:34: you should put `HttpRequest` between ticks in the documentation +iron-0.6.1/src/request/mod.rs:77:39: you should put `HttpRequest` between ticks in the documentation +iron-0.6.1/src/request/mod.rs:78:5: docs for function returning `Result` missing `# Errors` section +iron-0.6.1/src/request/mod.rs:82:13: binding's name is too similar to existing binding +iron-0.6.1/src/request/mod.rs:83:29: binding's name is too similar to existing binding +iron-0.6.1/src/request/mod.rs:85:24: binding's name is too similar to existing binding +iron-0.6.1/src/request/url.rs:109:5: this method could have a `#[must_use]` attribute +iron-0.6.1/src/request/url.rs:117:5: this method could have a `#[must_use]` attribute iron-0.6.1/src/request/url.rs:124:9: use of deprecated macro `try`: use the `?` operator instead +iron-0.6.1/src/request/url.rs:21:14: you should put bare URLs between `<`/`>` or make a proper Markdown link +iron-0.6.1/src/request/url.rs:22:5: docs for function returning `Result` missing `# Errors` section +iron-0.6.1/src/request/url.rs:31:5: docs for function returning `Result` missing `# Errors` section +iron-0.6.1/src/request/url.rs:47:5: this method could have a `#[must_use]` attribute +iron-0.6.1/src/request/url.rs:52:5: this method could have a `#[must_use]` attribute +iron-0.6.1/src/request/url.rs:57:5: this method could have a `#[must_use]` attribute +iron-0.6.1/src/request/url.rs:63:5: this method could have a `#[must_use]` attribute +iron-0.6.1/src/request/url.rs:73:5: this method could have a `#[must_use]` attribute +iron-0.6.1/src/request/url.rs:83:5: this method could have a `#[must_use]` attribute +iron-0.6.1/src/request/url.rs:96:5: this method could have a `#[must_use]` attribute +iron-0.6.1/src/response.rs:121:19: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +iron-0.6.1/src/response.rs:125:43: redundant closure found +iron-0.6.1/src/response.rs:139:41: redundant closure found iron-0.6.1/src/response.rs:142:23: use of deprecated macro `try`: use the `?` operator instead iron-0.6.1/src/response.rs:143:5: use of deprecated macro `try`: use the `?` operator instead +iron-0.6.1/src/response.rs:24:5: docs for function returning `Result` missing `# Errors` section +iron-0.6.1/src/response.rs:95:5: this method could have a `#[must_use]` attribute iron-0.6.1/src/response.rs:95:5: you should consider adding a `Default` implementation for `response::Response` ripgrep-12.1.1/build.rs:133:19: called `.as_ref().map(|x| &**x)` on an Option value. This can be done more directly by calling `githash.as_deref()` instead +ripgrep-12.1.1/build.rs:18:18: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +ripgrep-12.1.1/build.rs:225:14: redundant closure found ripgrep-12.1.1/build.rs:92:19: called `.as_ref().map(|x| &**x)` on an Option value. This can be done more directly by calling `githash.as_deref()` instead +ripgrep-12.1.1/crates/core/app.rs:1408:5: adding items after statements is confusing, since items exist from the start of the scope +ripgrep-12.1.1/crates/core/app.rs:1408:5: adding items after statements is confusing, since items exist from the start of the scope +ripgrep-12.1.1/crates/core/app.rs:1409:5: adding items after statements is confusing, since items exist from the start of the scope +ripgrep-12.1.1/crates/core/app.rs:1409:5: adding items after statements is confusing, since items exist from the start of the scope +ripgrep-12.1.1/crates/core/app.rs:152:32: you should put `clap::Arg` between ticks in the documentation +ripgrep-12.1.1/crates/core/app.rs:152:32: you should put `clap::Arg` between ticks in the documentation +ripgrep-12.1.1/crates/core/app.rs:156:39: you should put `clap::Arg` between ticks in the documentation +ripgrep-12.1.1/crates/core/app.rs:156:39: you should put `clap::Arg` between ticks in the documentation +ripgrep-12.1.1/crates/core/app.rs:156:5: you should put `RGArg` between ticks in the documentation +ripgrep-12.1.1/crates/core/app.rs:156:5: you should put `RGArg` between ticks in the documentation +ripgrep-12.1.1/crates/core/app.rs:1668:5: adding items after statements is confusing, since items exist from the start of the scope +ripgrep-12.1.1/crates/core/app.rs:1668:5: adding items after statements is confusing, since items exist from the start of the scope +ripgrep-12.1.1/crates/core/app.rs:1669:5: adding items after statements is confusing, since items exist from the start of the scope +ripgrep-12.1.1/crates/core/app.rs:1669:5: adding items after statements is confusing, since items exist from the start of the scope +ripgrep-12.1.1/crates/core/app.rs:1821:5: adding items after statements is confusing, since items exist from the start of the scope +ripgrep-12.1.1/crates/core/app.rs:1821:5: adding items after statements is confusing, since items exist from the start of the scope +ripgrep-12.1.1/crates/core/app.rs:1822:5: adding items after statements is confusing, since items exist from the start of the scope +ripgrep-12.1.1/crates/core/app.rs:1822:5: adding items after statements is confusing, since items exist from the start of the scope +ripgrep-12.1.1/crates/core/app.rs:2999:5: adding items after statements is confusing, since items exist from the start of the scope +ripgrep-12.1.1/crates/core/app.rs:2999:5: adding items after statements is confusing, since items exist from the start of the scope +ripgrep-12.1.1/crates/core/app.rs:3000:5: adding items after statements is confusing, since items exist from the start of the scope +ripgrep-12.1.1/crates/core/app.rs:3000:5: adding items after statements is confusing, since items exist from the start of the scope +ripgrep-12.1.1/crates/core/app.rs:367:54: this `match` has identical arm bodies +ripgrep-12.1.1/crates/core/app.rs:367:54: this `match` has identical arm bodies +ripgrep-12.1.1/crates/core/app.rs:414:59: this `match` has identical arm bodies +ripgrep-12.1.1/crates/core/app.rs:414:59: this `match` has identical arm bodies +ripgrep-12.1.1/crates/core/app.rs:417:57: this `match` has identical arm bodies +ripgrep-12.1.1/crates/core/app.rs:417:57: this `match` has identical arm bodies +ripgrep-12.1.1/crates/core/app.rs:417:57: this `match` has identical arm bodies +ripgrep-12.1.1/crates/core/app.rs:417:57: this `match` has identical arm bodies +ripgrep-12.1.1/crates/core/app.rs:444:41: this `match` has identical arm bodies +ripgrep-12.1.1/crates/core/app.rs:444:41: this `match` has identical arm bodies +ripgrep-12.1.1/crates/core/app.rs:470:41: this `match` has identical arm bodies +ripgrep-12.1.1/crates/core/app.rs:470:41: this `match` has identical arm bodies +ripgrep-12.1.1/crates/core/app.rs:75:9: you should put `RIPGREP_BUILD_GIT_HASH` between ticks in the documentation +ripgrep-12.1.1/crates/core/app.rs:75:9: you should put `RIPGREP_BUILD_GIT_HASH` between ticks in the documentation +ripgrep-12.1.1/crates/core/app.rs:87:5: unnecessary boolean `not` operation +ripgrep-12.1.1/crates/core/app.rs:87:5: unnecessary boolean `not` operation +ripgrep-12.1.1/crates/core/args.rs:1143:22: unused `self` argument ripgrep-12.1.1/crates/core/args.rs:11:1: this import is redundant ripgrep-12.1.1/crates/core/args.rs:1209:74: this `if` has identical blocks ripgrep-12.1.1/crates/core/args.rs:1209:74: this `if` has identical blocks +ripgrep-12.1.1/crates/core/args.rs:1282:13: binding's name is too similar to existing binding +ripgrep-12.1.1/crates/core/args.rs:1430:22: unused `self` argument +ripgrep-12.1.1/crates/core/args.rs:1438:21: you should put `OsStr` between ticks in the documentation +ripgrep-12.1.1/crates/core/args.rs:1520:44: redundant closure found ripgrep-12.1.1/crates/core/args.rs:1524:5: this function's return value is unnecessarily wrapped by `Result` +ripgrep-12.1.1/crates/core/args.rs:1635:14: you should put `values_of_lossy` between ticks in the documentation +ripgrep-12.1.1/crates/core/args.rs:1693:41: redundant closure found +ripgrep-12.1.1/crates/core/args.rs:1770:17: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers +ripgrep-12.1.1/crates/core/args.rs:287:13: binding's name is too similar to existing binding ripgrep-12.1.1/crates/core/args.rs:33:1: this import is redundant ripgrep-12.1.1/crates/core/args.rs:34:1: this import is redundant ripgrep-12.1.1/crates/core/args.rs:35:1: this import is redundant +ripgrep-12.1.1/crates/core/args.rs:410:14: this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) +ripgrep-12.1.1/crates/core/args.rs:475:18: this `match` has identical arm bodies +ripgrep-12.1.1/crates/core/args.rs:512:19: you should put `ArgMatches` between ticks in the documentation ripgrep-12.1.1/crates/core/args.rs:549:16: methods called `to_*` usually take self by reference; consider choosing a less ambiguous name +ripgrep-12.1.1/crates/core/args.rs:76:18: this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) +ripgrep-12.1.1/crates/core/args.rs:77:13: usage of wildcard import for enum variants +ripgrep-12.1.1/crates/core/args.rs:923:42: you should put `BinaryDetection::quit` between ticks in the documentation ripgrep-12.1.1/crates/core/config.rs:13:1: this import is redundant ripgrep-12.1.1/crates/core/config.rs:58:6: very complex type used. Consider factoring parts into `type` definitions ripgrep-12.1.1/crates/core/config.rs:79:6: very complex type used. Consider factoring parts into `type` definitions +ripgrep-12.1.1/crates/core/logger.rs:11:30: you should put `max_level` between ticks in the documentation ripgrep-12.1.1/crates/core/logger.rs:15:16: constants have by default a `'static` lifetime +ripgrep-12.1.1/crates/core/main.rs:55:19: this argument is passed by value, but not consumed in the function body +ripgrep-12.1.1/crates/core/main.rs:56:9: usage of wildcard import for enum variants +ripgrep-12.1.1/crates/core/messages.rs:46:1: item name ends with its containing module's name +ripgrep-12.1.1/crates/core/messages.rs:51:1: item name ends with its containing module's name +ripgrep-12.1.1/crates/core/messages.rs:62:1: item name ends with its containing module's name +ripgrep-12.1.1/crates/core/path_printer.rs:27:1: item name starts with its containing module's name +ripgrep-12.1.1/crates/core/path_printer.rs:89:9: unnecessary boolean `not` operation +ripgrep-12.1.1/crates/core/search.rs:185:1: item name starts with its containing module's name ripgrep-12.1.1/crates/core/search.rs:292:9: using `write!()` with a format string that ends in a single newline +ripgrep-12.1.1/crates/core/search.rs:311:1: item name starts with its containing module's name ripgrep-12.1.1/crates/core/search.rs:377:12: this boolean expression can be simplified +ripgrep-12.1.1/crates/core/search.rs:423:13: usage of wildcard import for enum variants +ripgrep-12.1.1/crates/core/search.rs:447:13: usage of wildcard import for enum variants ripgrep-12.1.1/crates/core/search.rs:472:24: you are using an explicit closure for cloning elements +ripgrep-12.1.1/crates/core/search.rs:472:41: redundant closure found ripgrep-12.1.1/crates/core/search.rs:480:24: you are using an explicit closure for cloning elements +ripgrep-12.1.1/crates/core/search.rs:480:41: redundant closure found +ripgrep-12.1.1/crates/core/search.rs:49:1: item name starts with its containing module's name ripgrep-12.1.1/crates/core/search.rs:509:24: you are using an explicit closure for cloning elements +ripgrep-12.1.1/crates/core/search.rs:509:41: redundant closure found ripgrep-12.1.1/crates/core/search.rs:517:24: you are using an explicit closure for cloning elements +ripgrep-12.1.1/crates/core/search.rs:517:41: redundant closure found +ripgrep-12.1.1/crates/core/search.rs:533:36: casting `u32` to `f64` may become silently lossy if you later change the type +ripgrep-12.1.1/crates/core/search.rs:533:5: casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +ripgrep-12.1.1/crates/core/subject.rs:20:1: item name starts with its containing module's name ripgrep-12.1.1/crates/core/subject.rs:4:1: this import is redundant -tokei-12.0.4/src/cli_utils.rs:154:25: this lifetime isn't used in the function definition -tokei-12.0.4/src/cli_utils.rs:154:29: this lifetime isn't used in the function definition -tokei-12.0.4/src/cli_utils.rs:195:47: useless use of `format!` -tokei-12.0.4/src/cli_utils.rs:306:47: useless use of `format!` -tokei-12.0.4/src/config.rs:102:36: use of `or` followed by a function call -tokei-12.0.4/src/config.rs:103:38: use of `or` followed by a function call -tokei-12.0.4/src/config.rs:106:18: use of `or` followed by a function call -tokei-12.0.4/src/config.rs:109:18: use of `or` followed by a function call -tokei-12.0.4/src/config.rs:112:18: use of `or` followed by a function call -tokei-12.0.4/src/config.rs:97:18: use of `or` followed by a function call -tokei-12.0.4/src/config.rs:99:86: use of `or` followed by a function call -tokei-12.0.4/src/language/language_type.rs:75:22: this `.into_iter()` call is equivalent to `.iter()` and will not consume the `slice` -tokei-12.0.4/src/language/syntax.rs:334:45: this `if` has identical blocks -tokei-12.0.4/src/language/syntax.rs:334:45: this `if` has identical blocks -tokei-12.0.4/src/language/syntax.rs:336:39: this `if` has identical blocks -tokei-12.0.4/src/language/syntax.rs:338:16: this if-then-else expression returns a bool literal -tokei-12.0.4/src/language/syntax.rs:338:43: this `if` has identical blocks -tokei-12.0.4/src/language/syntax.rs:446:74: trivial regex -tokei-12.0.4/src/language/syntax.rs:449:73: trivial regex -tokei-12.0.4/src/language/syntax.rs:453:45: trivial regex -tokei-12.0.4/src/utils/fs.rs:105:26: called `.as_ref().map(|v| &**v)` on an Option value. This can be done more directly by calling `config.types.as_deref()` instead +xsv-0.13.0/src/cmd/cat.rs:101:34: redundant closure found +xsv-0.13.0/src/cmd/cat.rs:42:1: more than 3 bools in a struct +xsv-0.13.0/src/cmd/cat.rs:53:9: binding's name is too similar to existing binding xsv-0.13.0/src/cmd/cat.rs:7:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/count.rs:32:9: binding's name is too similar to existing binding +xsv-0.13.0/src/cmd/count.rs:38:9: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +xsv-0.13.0/src/cmd/count.rs:42:33: integer type suffix should be separated by an underscore xsv-0.13.0/src/cmd/count.rs:50:5: passing a unit value to a function xsv-0.13.0/src/cmd/count.rs:7:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/fixlengths.rs:45:9: binding's name is too similar to existing binding +xsv-0.13.0/src/cmd/fixlengths.rs:50:18: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +xsv-0.13.0/src/cmd/fixlengths.rs:62:30: integer type suffix should be separated by an underscore xsv-0.13.0/src/cmd/fixlengths.rs:9:16: statics have by default a `'static` lifetime xsv-0.13.0/src/cmd/flatten.rs:10:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/flatten.rs:51:9: binding's name is too similar to existing binding +xsv-0.13.0/src/cmd/fmt.rs:50:9: binding's name is too similar to existing binding +xsv-0.13.0/src/cmd/fmt.rs:55:13: binding's name is too similar to existing binding xsv-0.13.0/src/cmd/fmt.rs:7:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/frequency.rs:148:43: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers +xsv-0.13.0/src/cmd/frequency.rs:149:43: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers xsv-0.13.0/src/cmd/frequency.rs:15:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/frequency.rs:169:13: binding's name is too similar to existing binding +xsv-0.13.0/src/cmd/frequency.rs:176:17: unnecessary boolean `not` operation xsv-0.13.0/src/cmd/frequency.rs:178:24: this `else { if .. }` block can be collapsed +xsv-0.13.0/src/cmd/frequency.rs:77:9: binding's name is too similar to existing binding +xsv-0.13.0/src/cmd/frequency.rs:93:31: it is more concise to loop over containers instead of using explicit iteration methods +xsv-0.13.0/src/cmd/headers.rs:43:9: binding's name is too similar to existing binding +xsv-0.13.0/src/cmd/headers.rs:49:17: it is more concise to loop over containers instead of using explicit iteration methods xsv-0.13.0/src/cmd/headers.rs:60:22: trait objects without an explicit `dyn` are deprecated xsv-0.13.0/src/cmd/headers.rs:9:16: statics have by default a `'static` lifetime xsv-0.13.0/src/cmd/index.rs:11:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/index.rs:45:9: binding's name is too similar to existing binding +xsv-0.13.0/src/cmd/input.rs:42:9: binding's name is too similar to existing binding +xsv-0.13.0/src/cmd/input.rs:47:9: binding's name is too similar to existing binding xsv-0.13.0/src/cmd/input.rs:7:16: statics have by default a `'static` lifetime xsv-0.13.0/src/cmd/join.rs:17:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/join.rs:194:29: binding's name is too similar to existing binding +xsv-0.13.0/src/cmd/join.rs:224:22: binding's name is too similar to existing binding xsv-0.13.0/src/cmd/join.rs:281:44: trait objects without an explicit `dyn` are deprecated +xsv-0.13.0/src/cmd/join.rs:293:14: binding's name is too similar to existing binding +xsv-0.13.0/src/cmd/join.rs:293:20: binding's name is too similar to existing binding xsv-0.13.0/src/cmd/join.rs:297:13: redundant field names in struct initialization xsv-0.13.0/src/cmd/join.rs:298:13: redundant field names in struct initialization xsv-0.13.0/src/cmd/join.rs:299:13: redundant field names in struct initialization xsv-0.13.0/src/cmd/join.rs:300:13: redundant field names in struct initialization +xsv-0.13.0/src/cmd/join.rs:308:9: unused `self` argument +xsv-0.13.0/src/cmd/join.rs:342:38: integer type suffix should be separated by an underscore +xsv-0.13.0/src/cmd/join.rs:342:46: integer type suffix should be separated by an underscore +xsv-0.13.0/src/cmd/join.rs:347:9: unnecessary boolean `not` operation +xsv-0.13.0/src/cmd/join.rs:372:44: redundant closure found +xsv-0.13.0/src/cmd/join.rs:375:33: binding's name is too similar to existing binding xsv-0.13.0/src/cmd/join.rs:392:13: redundant field names in struct initialization +xsv-0.13.0/src/cmd/join.rs:403:29: it is more concise to loop over containers instead of using explicit iteration methods +xsv-0.13.0/src/cmd/join.rs:426:13: unnecessary boolean `not` operation +xsv-0.13.0/src/cmd/join.rs:77:1: more than 3 bools in a struct +xsv-0.13.0/src/cmd/join.rs:94:9: binding's name is too similar to existing binding +xsv-0.13.0/src/cmd/partition.rs:105:22: binding's name is too similar to existing binding xsv-0.13.0/src/cmd/partition.rs:126:36: trait objects without an explicit `dyn` are deprecated xsv-0.13.0/src/cmd/partition.rs:139:13: redundant field names in struct initialization xsv-0.13.0/src/cmd/partition.rs:15:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/partition.rs:169:9: unnecessary boolean `not` operation +xsv-0.13.0/src/cmd/partition.rs:56:9: binding's name is too similar to existing binding +xsv-0.13.0/src/cmd/partition.rs:77:9: unused `self` argument +xsv-0.13.0/src/cmd/sample.rs:105:44: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers +xsv-0.13.0/src/cmd/sample.rs:115:21: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers xsv-0.13.0/src/cmd/sample.rs:11:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/sample.rs:51:9: binding's name is too similar to existing binding +xsv-0.13.0/src/cmd/sample.rs:58:19: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +xsv-0.13.0/src/cmd/sample.rs:69:9: wildcard match will miss any future added variants +xsv-0.13.0/src/cmd/sample.rs:75:16: it is more concise to loop over containers instead of using explicit iteration methods +xsv-0.13.0/src/cmd/sample.rs:91:42: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers +xsv-0.13.0/src/cmd/sample.rs:92:43: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers +xsv-0.13.0/src/cmd/search.rs:51:9: binding's name is too similar to existing binding xsv-0.13.0/src/cmd/search.rs:9:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/select.rs:60:9: binding's name is too similar to existing binding xsv-0.13.0/src/cmd/select.rs:8:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/slice.rs:57:9: binding's name is too similar to existing binding xsv-0.13.0/src/cmd/slice.rs:9:16: statics have by default a `'static` lifetime xsv-0.13.0/src/cmd/sort.rs:11:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/sort.rs:138:47: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +xsv-0.13.0/src/cmd/sort.rs:139:51: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +xsv-0.13.0/src/cmd/sort.rs:48:9: binding's name is too similar to existing binding +xsv-0.13.0/src/cmd/sort.rs:91:14: it is more concise to loop over containers instead of using explicit iteration methods xsv-0.13.0/src/cmd/split.rs:131:36: trait objects without an explicit `dyn` are deprecated xsv-0.13.0/src/cmd/split.rs:14:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/split.rs:61:9: binding's name is too similar to existing binding xsv-0.13.0/src/cmd/split.rs:94:5: this function's return value is unnecessarily wrapped by `Result` +xsv-0.13.0/src/cmd/split.rs:96:14: this argument is passed by value, but not consumed in the function body +xsv-0.13.0/src/cmd/split.rs:99:13: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers +xsv-0.13.0/src/cmd/stats.rs:110:36: redundant closure found +xsv-0.13.0/src/cmd/stats.rs:127:14: this argument is passed by value, but not consumed in the function body +xsv-0.13.0/src/cmd/stats.rs:138:43: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers +xsv-0.13.0/src/cmd/stats.rs:139:43: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers +xsv-0.13.0/src/cmd/stats.rs:162:25: it is more concise to loop over containers instead of using explicit iteration methods xsv-0.13.0/src/cmd/stats.rs:22:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/stats.rs:231:1: more than 3 bools in a struct +xsv-0.13.0/src/cmd/stats.rs:262:35: calling `cmd::stats::TypedSum::default()` is more clear than this expression +xsv-0.13.0/src/cmd/stats.rs:263:40: calling `cmd::stats::TypedMinMax::default()` is more clear than this expression +xsv-0.13.0/src/cmd/stats.rs:264:39: calling `stats::OnlineStats::default()` is more clear than this expression +xsv-0.13.0/src/cmd/stats.rs:265:58: calling `stats::Unsorted::default()` is more clear than this expression +xsv-0.13.0/src/cmd/stats.rs:266:41: calling `stats::Unsorted::default()` is more clear than this expression +xsv-0.13.0/src/cmd/stats.rs:268:18: calling `cmd::stats::FieldType::default()` is more clear than this expression xsv-0.13.0/src/cmd/stats.rs:269:13: redundant field names in struct initialization xsv-0.13.0/src/cmd/stats.rs:270:13: redundant field names in struct initialization xsv-0.13.0/src/cmd/stats.rs:271:13: redundant field names in struct initialization @@ -143,33 +1649,86 @@ xsv-0.13.0/src/cmd/stats.rs:283:9: called `map(f)` on an `Option` value where `f xsv-0.13.0/src/cmd/stats.rs:284:9: called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()` xsv-0.13.0/src/cmd/stats.rs:285:9: called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()` xsv-0.13.0/src/cmd/stats.rs:290:21: called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()` +xsv-0.13.0/src/cmd/stats.rs:293:25: this `match` has identical arm bodies xsv-0.13.0/src/cmd/stats.rs:297:25: called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()` xsv-0.13.0/src/cmd/stats.rs:301:21: called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()` xsv-0.13.0/src/cmd/stats.rs:302:21: called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()` xsv-0.13.0/src/cmd/stats.rs:308:18: methods called `to_*` usually take self by reference; consider choosing a less ambiguous name +xsv-0.13.0/src/cmd/stats.rs:318:9: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +xsv-0.13.0/src/cmd/stats.rs:322:45: redundant closure found +xsv-0.13.0/src/cmd/stats.rs:322:9: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +xsv-0.13.0/src/cmd/stats.rs:327:9: unnecessary boolean `not` operation +xsv-0.13.0/src/cmd/stats.rs:330:13: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +xsv-0.13.0/src/cmd/stats.rs:338:45: redundant closure found xsv-0.13.0/src/cmd/stats.rs:402:16: redundant pattern matching, consider using `is_ok()` xsv-0.13.0/src/cmd/stats.rs:403:16: redundant pattern matching, consider using `is_ok()` +xsv-0.13.0/src/cmd/stats.rs:407:18: this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) +xsv-0.13.0/src/cmd/stats.rs:411:16: this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) +xsv-0.13.0/src/cmd/stats.rs:427:56: this `match` has identical arm bodies +xsv-0.13.0/src/cmd/stats.rs:429:56: this `match` has identical arm bodies +xsv-0.13.0/src/cmd/stats.rs:430:60: this `match` has identical arm bodies +xsv-0.13.0/src/cmd/stats.rs:430:60: this `match` has identical arm bodies +xsv-0.13.0/src/cmd/stats.rs:454:5: you should put `TypedSum` between ticks in the documentation +xsv-0.13.0/src/cmd/stats.rs:473:43: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +xsv-0.13.0/src/cmd/stats.rs:504:56: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +xsv-0.13.0/src/cmd/stats.rs:505:51: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +xsv-0.13.0/src/cmd/stats.rs:511:5: you should put `TypedMinMax` between ticks in the documentation +xsv-0.13.0/src/cmd/stats.rs:536:35: casting `f64` to `i64` may truncate the value +xsv-0.13.0/src/cmd/stats.rs:544:33: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +xsv-0.13.0/src/cmd/stats.rs:592:22: calling `stats::MinMax::default()` is more clear than this expression +xsv-0.13.0/src/cmd/stats.rs:593:22: calling `stats::MinMax::default()` is more clear than this expression +xsv-0.13.0/src/cmd/stats.rs:594:23: calling `stats::MinMax::default()` is more clear than this expression +xsv-0.13.0/src/cmd/stats.rs:595:21: calling `stats::MinMax::default()` is more clear than this expression +xsv-0.13.0/src/cmd/stats.rs:71:1: more than 3 bools in a struct +xsv-0.13.0/src/cmd/stats.rs:86:9: binding's name is too similar to existing binding xsv-0.13.0/src/cmd/table.rs:10:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/table.rs:50:9: binding's name is too similar to existing binding +xsv-0.13.0/src/cmd/table.rs:54:9: binding's name is too similar to existing binding xsv-0.13.0/src/config.rs:113:43: use of `unwrap_or` followed by a function call xsv-0.13.0/src/config.rs:197:48: trait objects without an explicit `dyn` are deprecated xsv-0.13.0/src/config.rs:202:48: trait objects without an explicit `dyn` are deprecated xsv-0.13.0/src/config.rs:263:47: trait objects without an explicit `dyn` are deprecated xsv-0.13.0/src/config.rs:293:47: trait objects without an explicit `dyn` are deprecated +xsv-0.13.0/src/config.rs:58:1: more than 3 bools in a struct +xsv-0.13.0/src/config.rs:77:28: explicit deref method call xsv-0.13.0/src/config.rs:90:13: redundant field names in struct initialization xsv-0.13.0/src/index.rs:31:13: redundant field names in struct initialization xsv-0.13.0/src/main.rs:164:49: redundant clone xsv-0.13.0/src/main.rs:75:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/select.rs:13:1: item name starts with its containing module's name xsv-0.13.0/src/select.rs:154:5: this function's return value is unnecessarily wrapped by `Result` +xsv-0.13.0/src/select.rs:250:33: binding's name is too similar to existing binding +xsv-0.13.0/src/select.rs:250:43: binding's name is too similar to existing binding +xsv-0.13.0/src/select.rs:255:39: an inclusive range would be more readable xsv-0.13.0/src/select.rs:280:20: length comparison to zero xsv-0.13.0/src/select.rs:29:13: redundant field names in struct initialization +xsv-0.13.0/src/select.rs:360:62: this argument (8 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) xsv-0.13.0/src/select.rs:360:9: this function's return value is unnecessarily wrapped by `Option` xsv-0.13.0/src/select.rs:375:9: used sort instead of sort_unstable to sort primitive type `usize` +xsv-0.13.0/src/select.rs:379:18: it is more concise to loop over containers instead of using explicit iteration methods xsv-0.13.0/src/select.rs:416:5: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) xsv-0.13.0/src/select.rs:419:9: this function's return value is unnecessarily wrapped by `Option` +xsv-0.13.0/src/select.rs:420:27: consider using `Option` instead of `Option>` or a custom enum if you need to distinguish all 3 cases +xsv-0.13.0/src/select.rs:99:17: binding's name is too similar to existing binding +xsv-0.13.0/src/util.rs:150:5: you should put bare URLs between `<`/`>` or make a proper Markdown link xsv-0.13.0/src/util.rs:190:48: trait objects without an explicit `dyn` are deprecated xsv-0.13.0/src/util.rs:37:33: you are using an explicit closure for copying elements xsv-0.13.0/src/util.rs:90:1: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) +rayon-1.5.0/src/collections/binary_heap.rs:7:5: usage of wildcard import +rayon-1.5.0/src/collections/binary_heap.rs:8:5: usage of wildcard import +rayon-1.5.0/src/collections/btree_map.rs:7:5: usage of wildcard import +rayon-1.5.0/src/collections/btree_map.rs:8:5: usage of wildcard import +rayon-1.5.0/src/collections/btree_set.rs:7:5: usage of wildcard import +rayon-1.5.0/src/collections/btree_set.rs:8:5: usage of wildcard import +rayon-1.5.0/src/collections/hash_map.rs:10:5: usage of wildcard import +rayon-1.5.0/src/collections/hash_map.rs:9:5: usage of wildcard import +rayon-1.5.0/src/collections/hash_set.rs:10:5: usage of wildcard import +rayon-1.5.0/src/collections/hash_set.rs:9:5: usage of wildcard import +rayon-1.5.0/src/collections/linked_list.rs:7:5: usage of wildcard import +rayon-1.5.0/src/collections/linked_list.rs:8:5: usage of wildcard import rayon-1.5.0/src/collections/mod.rs:59:32: replacing a value of type `T` with `T::default()` is better expressed using `std::mem::take` +rayon-1.5.0/src/collections/vec_deque.rs:8:5: usage of wildcard import +rayon-1.5.0/src/collections/vec_deque.rs:9:5: usage of wildcard import rayon-1.5.0/src/compile_fail/cannot_collect_filtermap_data.rs:2:1: needless `fn main` in doctest rayon-1.5.0/src/compile_fail/cannot_zip_filtered_data.rs:2:1: needless `fn main` in doctest rayon-1.5.0/src/compile_fail/cell_par_iter.rs:2:1: needless `fn main` in doctest @@ -177,13 +1736,339 @@ rayon-1.5.0/src/compile_fail/no_send_par_iter.rs:25:1: needless `fn main` in doc rayon-1.5.0/src/compile_fail/no_send_par_iter.rs:46:1: needless `fn main` in doctest rayon-1.5.0/src/compile_fail/no_send_par_iter.rs:4:1: needless `fn main` in doctest rayon-1.5.0/src/compile_fail/rc_par_iter.rs:2:1: needless `fn main` in doctest +rayon-1.5.0/src/iter/chain.rs:103:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/chain.rs:122:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/chain.rs:128:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/chain.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/chain.rs:221:36: you should put `ExactSizeIterator` between ticks in the documentation +rayon-1.5.0/src/iter/chain.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/chain.rs:51:38: use Option::map_or_else instead of an if let/else +rayon-1.5.0/src/iter/chain.rs:58:14: `a` is being shadowed +rayon-1.5.0/src/iter/chain.rs:58:17: `b` is being shadowed +rayon-1.5.0/src/iter/chain.rs:78:14: `a` is being shadowed +rayon-1.5.0/src/iter/chain.rs:78:17: `b` is being shadowed +rayon-1.5.0/src/iter/chain.rs:97:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/chunks.rs:3:5: usage of wildcard import +rayon-1.5.0/src/iter/chunks.rs:4:5: usage of wildcard import +rayon-1.5.0/src/iter/chunks.rs:77:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/chunks.rs:83:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/cloned.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/cloned.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/cloned.rs:71:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/cloned.rs:75:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/collect/consumer.rs:141:5: you should put `CollectReducer` between ticks in the documentation +rayon-1.5.0/src/iter/collect/consumer.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/collect/consumer.rs:28:5: you should put `CollectResult` between ticks in the documentation +rayon-1.5.0/src/iter/collect/consumer.rs:36:37: generally you want to avoid `&mut &mut _` if possible +rayon-1.5.0/src/iter/collect/consumer.rs:36:37: generally you want to avoid `&mut &mut _` if possible +rayon-1.5.0/src/iter/collect/mod.rs:154:9: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +rayon-1.5.0/src/iter/copied.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/copied.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/copied.rs:71:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/copied.rs:75:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/empty.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/empty.rs:24:1: this function could have a `#[must_use]` attribute +rayon-1.5.0/src/iter/empty.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/enumerate.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/enumerate.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/enumerate.rs:64:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/enumerate.rs:68:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/extend.rs:143:63: I see you're using a LinkedList! Perhaps you meant some other data structure? +rayon-1.5.0/src/iter/extend.rs:182:57: I see you're using a LinkedList! Perhaps you meant some other data structure? +rayon-1.5.0/src/iter/extend.rs:218:32: I see you're using a LinkedList! Perhaps you meant some other data structure? +rayon-1.5.0/src/iter/extend.rs:218:59: I see you're using a LinkedList! Perhaps you meant some other data structure? +rayon-1.5.0/src/iter/extend.rs:25:42: I see you're using a LinkedList! Perhaps you meant some other data structure? +rayon-1.5.0/src/iter/extend.rs:287:62: I see you're using a LinkedList! Perhaps you meant some other data structure? +rayon-1.5.0/src/iter/extend.rs:322:56: I see you're using a LinkedList! Perhaps you meant some other data structure? +rayon-1.5.0/src/iter/extend.rs:41:27: I see you're using a LinkedList! Perhaps you meant some other data structure? +rayon-1.5.0/src/iter/extend.rs:47:30: I see you're using a LinkedList! Perhaps you meant some other data structure? +rayon-1.5.0/src/iter/extend.rs:47:56: I see you're using a LinkedList! Perhaps you meant some other data structure? +rayon-1.5.0/src/iter/extend.rs:47:74: I see you're using a LinkedList! Perhaps you meant some other data structure? +rayon-1.5.0/src/iter/extend.rs:53:29: I see you're using a LinkedList! Perhaps you meant some other data structure? +rayon-1.5.0/src/iter/extend.rs:57:36: I see you're using a LinkedList! Perhaps you meant some other data structure? +rayon-1.5.0/src/iter/extend.rs:59:61: I see you're using a LinkedList! Perhaps you meant some other data structure? +rayon-1.5.0/src/iter/filter.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/filter.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/filter_map.rs:123:9: use Option::map_or instead of an if let/else +rayon-1.5.0/src/iter/filter_map.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/filter_map.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/find.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/find.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/find_first_last/mod.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/find_first_last/mod.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/find_first_last/mod.rs:32:67: you should put `MatchPosition` between ticks in the documentation +rayon-1.5.0/src/iter/flat_map.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/flat_map.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/flat_map_iter.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/flat_map_iter.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/flatten.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/flatten.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/flatten_iter.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/flatten_iter.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/fold.rs:158:13: binding's name is too similar to existing binding +rayon-1.5.0/src/iter/fold.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/fold.rs:204:1: item name starts with its containing module's name +rayon-1.5.0/src/iter/fold.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/for_each.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/for_each.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/inspect.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/inspect.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/inspect.rs:83:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/inspect.rs:88:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/interleave.rs:111:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/interleave.rs:119:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/interleave.rs:195:30: you should put `self.i_len` between ticks in the documentation +rayon-1.5.0/src/iter/interleave.rs:195:43: you should put `self.j_len` between ticks in the documentation +rayon-1.5.0/src/iter/interleave.rs:199:23: you should put `self.i_len` between ticks in the documentation +rayon-1.5.0/src/iter/interleave.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/interleave.rs:200:23: you should put `self.j_len` between ticks in the documentation +rayon-1.5.0/src/iter/interleave.rs:249:41: you should put `DoubleEndedIterator` between ticks in the documentation +rayon-1.5.0/src/iter/interleave.rs:250:5: you should put `ExactSizeIterator` between ticks in the documentation +rayon-1.5.0/src/iter/interleave.rs:263:33: you should put `InterleaveSeq` between ticks in the documentation +rayon-1.5.0/src/iter/interleave.rs:280:17: wildcard match will miss any future added variants +rayon-1.5.0/src/iter/interleave.rs:285:17: wildcard match will miss any future added variants +rayon-1.5.0/src/iter/interleave.rs:2:5: usage of wildcard import rayon-1.5.0/src/iter/interleave.rs:313:9: `if` chain can be rewritten with `match` +rayon-1.5.0/src/iter/interleave.rs:82:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/interleave.rs:90:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/interleave_shortest.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/intersperse.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/intersperse.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/intersperse.rs:90:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/intersperse.rs:96:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/len.rs:12:1: item name ends with its containing module's name +rayon-1.5.0/src/iter/len.rs:146:1: item name ends with its containing module's name +rayon-1.5.0/src/iter/len.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/len.rs:200:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/len.rs:205:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/len.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/len.rs:66:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/len.rs:71:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/map.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/map.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/map.rs:84:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/map.rs:89:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/map_with.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/map_with.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/map_with.rs:419:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/map_with.rs:425:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/map_with.rs:90:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/map_with.rs:96:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/mod.rs:1874:24: this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) rayon-1.5.0/src/iter/mod.rs:2171:1: trait `IndexedParallelIterator` has a `len` method but no (possibly inherited) `is_empty` method +rayon-1.5.0/src/iter/mod.rs:2371:26: this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) +rayon-1.5.0/src/iter/mod.rs:2411:26: this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) +rayon-1.5.0/src/iter/mod.rs:82:5: usage of wildcard import +rayon-1.5.0/src/iter/multizip.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/multizip.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/noop.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/once.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/once.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/panic_fuse.rs:102:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/panic_fuse.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/panic_fuse.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/panic_fuse.rs:98:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/par_bridge.rs:136:28: redundant else block +rayon-1.5.0/src/iter/par_bridge.rs:163:28: redundant else block +rayon-1.5.0/src/iter/plumbing/mod.rs:216:58: you should put `find_first` between ticks in the documentation +rayon-1.5.0/src/iter/plumbing/mod.rs:359:5: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/plumbing/mod.rs:364:5: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/plumbing/mod.rs:399:5: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/plumbing/mod.rs:53:19: you should put `DoubleEndedIterator` between ticks in the documentation +rayon-1.5.0/src/iter/plumbing/mod.rs:53:43: you should put `ExactSizeIterator` between ticks in the documentation +rayon-1.5.0/src/iter/plumbing/mod.rs:54:31: you should put `IntoIterator` between ticks in the documentation +rayon-1.5.0/src/iter/plumbing/mod.rs:55:5: you should put `IntoIterator` between ticks in the documentation +rayon-1.5.0/src/iter/positions.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/positions.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/product.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/reduce.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/repeat.rs:103:1: item name starts with its containing module's name +rayon-1.5.0/src/iter/repeat.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/repeat.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/rev.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/rev.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/rev.rs:63:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/rev.rs:68:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/skip.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/skip.rs:3:5: usage of wildcard import +rayon-1.5.0/src/iter/skip.rs:68:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/skip.rs:73:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/splitter.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/splitter.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/step_by.rs:4:5: usage of wildcard import +rayon-1.5.0/src/iter/step_by.rs:5:5: usage of wildcard import +rayon-1.5.0/src/iter/step_by.rs:73:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/step_by.rs:79:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/sum.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/take.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/take.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/take.rs:67:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/take.rs:72:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/try_fold.rs:190:1: item name starts with its containing module's name +rayon-1.5.0/src/iter/try_fold.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/try_fold.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/try_reduce.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/try_reduce_with.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/unzip.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/unzip.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/update.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/update.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/update.rs:82:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/update.rs:87:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/while_some.rs:130:22: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +rayon-1.5.0/src/iter/while_some.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/while_some.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/zip.rs:102:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/zip.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/zip.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/zip.rs:74:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/zip.rs:79:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/zip.rs:97:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/zip_eq.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/zip_eq.rs:2:5: usage of wildcard import +rayon-1.5.0/src/option.rs:8:5: usage of wildcard import +rayon-1.5.0/src/option.rs:9:5: usage of wildcard import +rayon-1.5.0/src/par_either.rs:1:5: usage of wildcard import +rayon-1.5.0/src/par_either.rs:3:5: usage of wildcard import +rayon-1.5.0/src/private.rs:9:1: item name starts with its containing module's name +rayon-1.5.0/src/range.rs:19:5: usage of wildcard import +rayon-1.5.0/src/range.rs:20:5: usage of wildcard import +rayon-1.5.0/src/range_inclusive.rs:194:9: an inclusive range would be more readable +rayon-1.5.0/src/range_inclusive.rs:194:9: an inclusive range would be more readable +rayon-1.5.0/src/range_inclusive.rs:19:5: usage of wildcard import +rayon-1.5.0/src/range_inclusive.rs:209:9: an inclusive range would be more readable +rayon-1.5.0/src/range_inclusive.rs:209:9: an inclusive range would be more readable +rayon-1.5.0/src/range_inclusive.rs:20:5: usage of wildcard import +rayon-1.5.0/src/range_inclusive.rs:231:9: an inclusive range would be more readable +rayon-1.5.0/src/range_inclusive.rs:231:9: an inclusive range would be more readable +rayon-1.5.0/src/result.rs:8:5: usage of wildcard import +rayon-1.5.0/src/result.rs:9:5: usage of wildcard import +rayon-1.5.0/src/slice/mergesort.rs:102:5: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/slice/mergesort.rs:109:5: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/slice/mergesort.rs:114:5: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/slice/mergesort.rs:211:5: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/slice/mergesort.rs:217:5: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/slice/mergesort.rs:251:5: you should put `TimSort` between ticks in the documentation +rayon-1.5.0/src/slice/mergesort.rs:252:5: you should put bare URLs between `<`/`>` or make a proper Markdown link +rayon-1.5.0/src/slice/mergesort.rs:286:59: you should put `TimSort` between ticks in the documentation +rayon-1.5.0/src/slice/mergesort.rs:333:24: redundant else block +rayon-1.5.0/src/slice/mergesort.rs:513:5: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/slice/mergesort.rs:521:5: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/slice/mergesort.rs:7:5: usage of wildcard import +rayon-1.5.0/src/slice/mergesort.rs:98:5: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/slice/mod.rs:15:5: usage of wildcard import +rayon-1.5.0/src/slice/mod.rs:16:5: usage of wildcard import +rayon-1.5.0/src/slice/mod.rs:17:5: usage of wildcard import +rayon-1.5.0/src/slice/mod.rs:25:1: item name ends with its containing module's name +rayon-1.5.0/src/slice/mod.rs:657:5: this method could have a `#[must_use]` attribute +rayon-1.5.0/src/slice/mod.rs:971:5: this method could have a `#[must_use]` attribute +rayon-1.5.0/src/slice/quicksort.rs:230:36: you should put `BlockQuicksort` between ticks in the documentation +rayon-1.5.0/src/slice/quicksort.rs:233:1: this function has too many lines (117/100) +rayon-1.5.0/src/slice/quicksort.rs:258:26: integer type suffix should be separated by an underscore +rayon-1.5.0/src/slice/quicksort.rs:265:26: integer type suffix should be separated by an underscore +rayon-1.5.0/src/slice/quicksort.rs:268:5: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/slice/quicksort.rs:308:30: casting `usize` to `u8` may truncate the value +rayon-1.5.0/src/slice/quicksort.rs:325:30: casting `usize` to `u8` may truncate the value +rayon-1.5.0/src/slice/quicksort.rs:393:36: casting `u8` to `isize` may wrap around the value on targets with 32-bit wide pointers +rayon-1.5.0/src/slice/quicksort.rs:405:40: casting `u8` to `isize` may wrap around the value on targets with 32-bit wide pointers +rayon-1.5.0/src/slice/quicksort.rs:430:14: `pivot` is being shadowed +rayon-1.5.0/src/slice/quicksort.rs:439:13: `pivot` is being shadowed +rayon-1.5.0/src/slice/quicksort.rs:482:10: `pivot` is being shadowed +rayon-1.5.0/src/slice/quicksort.rs:491:9: `pivot` is being shadowed +rayon-1.5.0/src/slice/quicksort.rs:534:26: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers +rayon-1.5.0/src/slice/quicksort.rs:545:17: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers rayon-1.5.0/src/slice/quicksort.rs:588:17: the operation is ineffective. Consider reducing it to `len / 4` +rayon-1.5.0/src/slice/quicksort.rs:716:14: `pivot` is being shadowed +rayon-1.5.0/src/split_producer.rs:56:16: use Option::map_or_else instead of an if let/else +rayon-1.5.0/src/split_producer.rs:92:9: use Option::map_or instead of an if let/else +rayon-1.5.0/src/str.rs:16:5: usage of wildcard import +rayon-1.5.0/src/str.rs:17:5: usage of wildcard import +rayon-1.5.0/src/str.rs:18:5: usage of wildcard import +rayon-1.5.0/src/str.rs:25:5: casting `u8` to `i8` may wrap around the value rayon-1.5.0/src/str.rs:715:9: stripping a suffix manually +rayon-1.5.0/src/string.rs:5:5: usage of wildcard import rayon-1.5.0/src/vec.rs:137:12: length comparison to zero +rayon-1.5.0/src/vec.rs:8:5: usage of wildcard import +rayon-1.5.0/src/vec.rs:9:5: usage of wildcard import +rand-0.7.3/src/distributions/bernoulli.rs:103:20: casting `f64` to `u64` may lose the sign of the value +rand-0.7.3/src/distributions/bernoulli.rs:103:20: casting `f64` to `u64` may truncate the value +rand-0.7.3/src/distributions/bernoulli.rs:116:5: docs for function returning `Result` missing `# Errors` section +rand-0.7.3/src/distributions/bernoulli.rs:123:21: casting `f64` to `u64` may lose the sign of the value +rand-0.7.3/src/distributions/bernoulli.rs:123:21: casting `f64` to `u64` may truncate the value +rand-0.7.3/src/distributions/bernoulli.rs:63:26: casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +rand-0.7.3/src/distributions/bernoulli.rs:63:27: integer type suffix should be separated by an underscore +rand-0.7.3/src/distributions/bernoulli.rs:67:1: item name starts with its containing module's name +rand-0.7.3/src/distributions/bernoulli.rs:95:5: docs for function returning `Result` missing `# Errors` section rand-0.7.3/src/distributions/bernoulli.rs:96:13: manual `Range::contains` implementation +rand-0.7.3/src/distributions/binomial.rs:107:23: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +rand-0.7.3/src/distributions/binomial.rs:112:44: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +rand-0.7.3/src/distributions/binomial.rs:116:13: adding items after statements is confusing, since items exist from the start of the scope +rand-0.7.3/src/distributions/binomial.rs:150:28: redundant else block +rand-0.7.3/src/distributions/binomial.rs:153:24: unnecessary boolean `not` operation +rand-0.7.3/src/distributions/binomial.rs:158:28: redundant else block +rand-0.7.3/src/distributions/binomial.rs:164:33: casting `i64` to `u64` may lose the sign of the value +rand-0.7.3/src/distributions/binomial.rs:166:28: redundant else block +rand-0.7.3/src/distributions/binomial.rs:175:47: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +rand-0.7.3/src/distributions/binomial.rs:185:38: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +rand-0.7.3/src/distributions/binomial.rs:194:38: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +rand-0.7.3/src/distributions/binomial.rs:202:28: redundant else block +rand-0.7.3/src/distributions/binomial.rs:209:25: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +rand-0.7.3/src/distributions/binomial.rs:221:26: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +rand-0.7.3/src/distributions/binomial.rs:222:26: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +rand-0.7.3/src/distributions/binomial.rs:223:25: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +rand-0.7.3/src/distributions/binomial.rs:224:25: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +rand-0.7.3/src/distributions/binomial.rs:226:17: adding items after statements is confusing, since items exist from the start of the scope +rand-0.7.3/src/distributions/binomial.rs:233:32: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +rand-0.7.3/src/distributions/binomial.rs:234:27: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +rand-0.7.3/src/distributions/binomial.rs:251:22: casting `i64` to `u64` may lose the sign of the value +rand-0.7.3/src/distributions/binomial.rs:255:9: unnecessary `!=` operation +rand-0.7.3/src/distributions/binomial.rs:35:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/distributions/binomial.rs:45:17: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +rand-0.7.3/src/distributions/binomial.rs:46:5: casting `f64` to `i64` may truncate the value +rand-0.7.3/src/distributions/binomial.rs:50:5: this function has too many lines (143/100) +rand-0.7.3/src/distributions/binomial.rs:76:9: adding items after statements is confusing, since items exist from the start of the scope +rand-0.7.3/src/distributions/binomial.rs:78:12: casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +rand-0.7.3/src/distributions/binomial.rs:81:21: casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +rand-0.7.3/src/distributions/binomial.rs:82:32: casting `u64` to `i32` may truncate the value +rand-0.7.3/src/distributions/binomial.rs:88:26: casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +rand-0.7.3/src/distributions/binomial.rs:99:21: casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +rand-0.7.3/src/distributions/cauchy.rs:33:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/distributions/dirichlet.rs:52:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/distributions/dirichlet.rs:64:32: float type suffix should be separated by an underscore +rand-0.7.3/src/distributions/dirichlet.rs:65:23: float type suffix should be separated by an underscore +rand-0.7.3/src/distributions/exponential.rs:76:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/distributions/float.rs:73:1: item name ends with its containing module's name +rand-0.7.3/src/distributions/gamma.rs:13:5: usage of wildcard import for enum variants +rand-0.7.3/src/distributions/gamma.rs:14:5: usage of wildcard import for enum variants +rand-0.7.3/src/distributions/gamma.rs:189:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/distributions/gamma.rs:230:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/distributions/gamma.rs:259:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/distributions/gamma.rs:287:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/distributions/gamma.rs:90:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/distributions/integer.rs:23:9: casting `u32` to `u8` may truncate the value +rand-0.7.3/src/distributions/integer.rs:30:9: casting `u32` to `u16` may truncate the value +rand-0.7.3/src/distributions/integer.rs:69:9: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers +rand-0.7.3/src/distributions/mod.rs:263:5: you have declared `#[inline(always)]` on `next`. This is usually a bad idea +rand-0.7.3/src/distributions/normal.rs:100:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/distributions/normal.rs:119:1: item name ends with its containing module's name +rand-0.7.3/src/distributions/normal.rs:131:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/distributions/normal.rs:31:1: item name ends with its containing module's name +rand-0.7.3/src/distributions/normal.rs:47:25: float type suffix should be separated by an underscore +rand-0.7.3/src/distributions/normal.rs:48:25: float type suffix should be separated by an underscore +rand-0.7.3/src/distributions/other.rs:89:9: casting `u32` to `i32` may wrap around the value +rand-0.7.3/src/distributions/pareto.rs:32:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/distributions/poisson.rs:35:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/distributions/poisson.rs:87:30: casting `f64` to `u64` may lose the sign of the value +rand-0.7.3/src/distributions/poisson.rs:87:30: casting `f64` to `u64` may truncate the value +rand-0.7.3/src/distributions/triangular.rs:32:5: this method could have a `#[must_use]` attribute rand-0.7.3/src/distributions/uniform.rs:146:4: needless `fn main` in doctest +rand-0.7.3/src/distributions/uniform.rs:199:1: item name ends with its containing module's name +rand-0.7.3/src/distributions/uniform.rs:214:1: item name starts with its containing module's name +rand-0.7.3/src/distributions/uniform.rs:283:14: you should put `SampleUniform` between ticks in the documentation +rand-0.7.3/src/distributions/uniform.rs:283:46: you should put `SampleUniform` between ticks in the documentation +rand-0.7.3/src/distributions/uniform.rs:296:5: you have declared `#[inline(always)]` on `borrow`. This is usually a bad idea +rand-0.7.3/src/distributions/uniform.rs:304:5: you have declared `#[inline(always)]` on `borrow`. This is usually a bad idea +rand-0.7.3/src/distributions/uniform.rs:350:1: item name starts with its containing module's name rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization @@ -196,90 +2081,799 @@ rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization +rand-0.7.3/src/distributions/uniform.rs:441:31: because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false +rand-0.7.3/src/distributions/uniform.rs:441:31: because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false +rand-0.7.3/src/distributions/uniform.rs:441:31: because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false +rand-0.7.3/src/distributions/uniform.rs:441:31: because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false +rand-0.7.3/src/distributions/uniform.rs:441:31: because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false +rand-0.7.3/src/distributions/uniform.rs:441:31: because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false +rand-0.7.3/src/distributions/uniform.rs:441:31: because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false +rand-0.7.3/src/distributions/uniform.rs:441:31: because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false +rand-0.7.3/src/distributions/uniform.rs:56:10: you should put `SampleBorrow` between ticks in the documentation +rand-0.7.3/src/distributions/uniform.rs:647:1: item name starts with its containing module's name +rand-0.7.3/src/distributions/uniform.rs:840:1: item name starts with its containing module's name +rand-0.7.3/src/distributions/uniform.rs:913:13: use Option::map_or_else instead of an if let/else +rand-0.7.3/src/distributions/uniform.rs:943:54: casting `u64` to `u32` may truncate the value +rand-0.7.3/src/distributions/unit_circle.rs:30:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/distributions/unit_sphere.rs:24:1: item name starts with its containing module's name +rand-0.7.3/src/distributions/unit_sphere.rs:29:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/distributions/utils.rs:254:5: you have declared `#[inline(always)]` on `lanes`. This is usually a bad idea +rand-0.7.3/src/distributions/utils.rs:258:5: you have declared `#[inline(always)]` on `splat`. This is usually a bad idea +rand-0.7.3/src/distributions/utils.rs:262:5: you have declared `#[inline(always)]` on `extract`. This is usually a bad idea +rand-0.7.3/src/distributions/utils.rs:267:5: you have declared `#[inline(always)]` on `replace`. This is usually a bad idea +rand-0.7.3/src/distributions/utils.rs:281:5: you have declared `#[inline(always)]` on `any`. This is usually a bad idea +rand-0.7.3/src/distributions/utils.rs:286:5: you have declared `#[inline(always)]` on `all`. This is usually a bad idea +rand-0.7.3/src/distributions/utils.rs:291:5: you have declared `#[inline(always)]` on `none`. This is usually a bad idea +rand-0.7.3/src/distributions/utils.rs:488:17: you should put `x_i` between ticks in the documentation +rand-0.7.3/src/distributions/utils.rs:489:50: you should put `x_i` between ticks in the documentation +rand-0.7.3/src/distributions/utils.rs:489:63: you should put `f(x_i` between ticks in the documentation +rand-0.7.3/src/distributions/utils.rs:490:40: you should put `f(x_i` between ticks in the documentation +rand-0.7.3/src/distributions/utils.rs:490:49: you should put `f(x_{i+1` between ticks in the documentation +rand-0.7.3/src/distributions/utils.rs:518:17: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers +rand-0.7.3/src/distributions/weibull.rs:29:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/distributions/weighted/alias_method.rs:113:21: it is more concise to loop over references to containers instead of using explicit iteration methods +rand-0.7.3/src/distributions/weighted/alias_method.rs:125:9: adding items after statements is confusing, since items exist from the start of the scope +rand-0.7.3/src/distributions/weighted/alias_method.rs:131:9: adding items after statements is confusing, since items exist from the start of the scope +rand-0.7.3/src/distributions/weighted/alias_method.rs:180:36: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers +rand-0.7.3/src/distributions/weighted/alias_method.rs:182:34: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers rand-0.7.3/src/distributions/weighted/alias_method.rs:259:28: using `clone` on type `distributions::uniform::Uniform` which implements the `Copy` trait rand-0.7.3/src/distributions/weighted/alias_method.rs:296:9: you are using an explicit closure for copying elements rand-0.7.3/src/distributions/weighted/alias_method.rs:321:9: you are using an explicit closure for copying elements +rand-0.7.3/src/distributions/weighted/alias_method.rs:78:5: docs for function returning `Result` missing `# Errors` section +rand-0.7.3/src/distributions/weighted/alias_method.rs:78:5: this function has too many lines (106/100) +rand-0.7.3/src/distributions/weighted/alias_method.rs:85:17: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers +rand-0.7.3/src/distributions/weighted/alias_method.rs:87:31: called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead +rand-0.7.3/src/distributions/weighted/mod.rs:100:5: docs for function returning `Result` missing `# Errors` section +rand-0.7.3/src/distributions/weighted/mod.rs:144:5: docs for function returning `Result` missing `# Errors` section rand-0.7.3/src/distributions/weighted/mod.rs:169:16: unnecessary `>= y + 1` or `x - 1 >=` +rand-0.7.3/src/distributions/weighted/mod.rs:386:1: item name starts with its containing module's name +rand-0.7.3/src/distributions/weighted/mod.rs:85:1: item name starts with its containing module's name +rand-0.7.3/src/lib.rs:333:5: docs for function returning `Result` missing `# Errors` section +rand-0.7.3/src/lib.rs:552:1: this function could have a `#[must_use]` attribute +rand-0.7.3/src/rngs/adapter/read.rs:47:1: item name starts with its containing module's name +rand-0.7.3/src/rngs/adapter/read.rs:89:1: item name starts with its containing module's name +rand-0.7.3/src/rngs/adapter/reseeding.rs:100:5: docs for function returning `Result` missing `# Errors` section +rand-0.7.3/src/rngs/adapter/reseeding.rs:112:5: you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea +rand-0.7.3/src/rngs/adapter/reseeding.rs:117:5: you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea +rand-0.7.3/src/rngs/adapter/reseeding.rs:198:13: casting `u64` to `i64` may wrap around the value +rand-0.7.3/src/rngs/adapter/reseeding.rs:231:9: casting `usize` to `isize` may wrap around the value +rand-0.7.3/src/rngs/adapter/reseeding.rs:27:28: you should put `ChaCha` between ticks in the documentation +rand-0.7.3/src/rngs/adapter/reseeding.rs:79:1: item name starts with its containing module's name +rand-0.7.3/src/rngs/entropy.rs:24:1: item name starts with its containing module's name +rand-0.7.3/src/rngs/entropy.rs:34:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/rngs/mock.rs:36:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/rngs/mock.rs:47:9: casting `u64` to `u32` may truncate the value +rand-0.7.3/src/rngs/mod.rs:61:74: you should put `ChaCha20` between ticks in the documentation +rand-0.7.3/src/rngs/std.rs:25:39: you should put `ChaCha` between ticks in the documentation +rand-0.7.3/src/rngs/std.rs:32:10: you should put `rand_chacha` between ticks in the documentation +rand-0.7.3/src/rngs/std.rs:36:1: item name starts with its containing module's name +rand-0.7.3/src/rngs/std.rs:39:5: you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea +rand-0.7.3/src/rngs/std.rs:44:5: you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea +rand-0.7.3/src/rngs/std.rs:49:5: you have declared `#[inline(always)]` on `fill_bytes`. This is usually a bad idea +rand-0.7.3/src/rngs/std.rs:54:5: you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea +rand-0.7.3/src/rngs/std.rs:63:5: you have declared `#[inline(always)]` on `from_seed`. This is usually a bad idea +rand-0.7.3/src/rngs/std.rs:68:5: you have declared `#[inline(always)]` on `from_rng`. This is usually a bad idea +rand-0.7.3/src/rngs/thread.rs:57:1: item name starts with its containing module's name +rand-0.7.3/src/rngs/thread.rs:80:1: item name starts with its containing module's name +rand-0.7.3/src/rngs/thread.rs:80:1: this function could have a `#[must_use]` attribute +rand-0.7.3/src/rngs/thread.rs:81:35: redundant closure found +rand-0.7.3/src/rngs/thread.rs:93:5: you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea +rand-0.7.3/src/rngs/thread.rs:98:5: you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea +rand-0.7.3/src/seq/index.rs:127:1: item name starts with its containing module's name +rand-0.7.3/src/seq/index.rs:139:13: usage of wildcard import for enum variants +rand-0.7.3/src/seq/index.rs:159:1: item name starts with its containing module's name +rand-0.7.3/src/seq/index.rs:171:13: usage of wildcard import for enum variants +rand-0.7.3/src/seq/index.rs:180:13: usage of wildcard import for enum variants +rand-0.7.3/src/seq/index.rs:223:18: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers +rand-0.7.3/src/seq/index.rs:224:18: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers +rand-0.7.3/src/seq/index.rs:233:25: casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide) +rand-0.7.3/src/seq/index.rs:236:27: casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide) +rand-0.7.3/src/seq/index.rs:244:12: casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide) +rand-0.7.3/src/seq/index.rs:244:37: casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide) +rand-0.7.3/src/seq/index.rs:29:1: item name starts with its containing module's name +rand-0.7.3/src/seq/index.rs:39:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/seq/index.rs:48:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/seq/index.rs:60:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/seq/index.rs:69:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/seq/index.rs:78:5: this method could have a `#[must_use]` attribute rand-0.7.3/src/seq/index.rs:87:5: method `into_iter` can be confused for the standard trait method `std::iter::IntoIterator::into_iter` +rand-0.7.3/src/seq/index.rs:87:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/seq/index.rs:97:13: usage of wildcard import for enum variants +rand-0.7.3/src/seq/mod.rs:141:5: docs for function returning `Result` missing `# Errors` section +rand-0.7.3/src/seq/mod.rs:168:5: docs for function returning `Result` missing `# Errors` section rand-0.7.3/src/seq/mod.rs:229:4: needless `fn main` in doctest +rand-0.7.3/src/seq/mod.rs:292:29: casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +rand-0.7.3/src/seq/mod.rs:410:23: calling `std::marker::PhantomData::default()` is more clear than this expression rand-0.7.3/src/seq/mod.rs:45:4: needless `fn main` in doctest +rand-0.7.3/src/seq/mod.rs:527:26: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers syn-1.0.54/src/lit.rs:1397:40: redundant else block syn-1.0.54/src/lit.rs:1405:28: redundant else block syn-1.0.54/src/lit.rs:1485:32: redundant else block +libc-0.2.81/build.rs:114:19: called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead libc-0.2.81/build.rs:124:5: this block may be rewritten with the `?` operator libc-0.2.81/build.rs:133:5: this block may be rewritten with the `?` operator +libc-0.2.81/src/macros.rs:243:17: this function could have a `#[must_use]` attribute +libc-0.2.81/src/macros.rs:243:17: this function could have a `#[must_use]` attribute +libc-0.2.81/src/macros.rs:243:17: this function could have a `#[must_use]` attribute +libc-0.2.81/src/macros.rs:243:17: this function could have a `#[must_use]` attribute +libc-0.2.81/src/macros.rs:243:17: this function could have a `#[must_use]` attribute +libc-0.2.81/src/macros.rs:243:17: this function could have a `#[must_use]` attribute +libc-0.2.81/src/macros.rs:243:17: this function could have a `#[must_use]` attribute +libc-0.2.81/src/macros.rs:243:17: this function could have a `#[must_use]` attribute +libc-0.2.81/src/macros.rs:243:17: this function could have a `#[must_use]` attribute +libc-0.2.81/src/macros.rs:243:17: this function could have a `#[must_use]` attribute +libc-0.2.81/src/macros.rs:243:17: this function could have a `#[must_use]` attribute +libc-0.2.81/src/macros.rs:243:17: this function could have a `#[must_use]` attribute +libc-0.2.81/src/macros.rs:243:17: this function could have a `#[must_use]` attribute +libc-0.2.81/src/macros.rs:243:17: this function could have a `#[must_use]` attribute +libc-0.2.81/src/macros.rs:243:17: this function could have a `#[must_use]` attribute +libc-0.2.81/src/macros.rs:243:17: this function could have a `#[must_use]` attribute +libc-0.2.81/src/macros.rs:243:17: this function could have a `#[must_use]` attribute +libc-0.2.81/src/macros.rs:243:17: this function could have a `#[must_use]` attribute +libc-0.2.81/src/macros.rs:243:17: this function could have a `#[must_use]` attribute +libc-0.2.81/src/macros.rs:243:17: this function could have a `#[must_use]` attribute libc-0.2.81/src/macros.rs:243:17: unsafe function's docs miss `# Safety` section libc-0.2.81/src/macros.rs:243:17: unsafe function's docs miss `# Safety` section libc-0.2.81/src/macros.rs:243:17: unsafe function's docs miss `# Safety` section +libc-0.2.81/src/macros.rs:259:17: this function could have a `#[must_use]` attribute +libc-0.2.81/src/macros.rs:259:17: this function could have a `#[must_use]` attribute +libc-0.2.81/src/macros.rs:259:17: this function could have a `#[must_use]` attribute +libc-0.2.81/src/macros.rs:259:17: this function could have a `#[must_use]` attribute +libc-0.2.81/src/macros.rs:259:17: this function could have a `#[must_use]` attribute +libc-0.2.81/src/macros.rs:259:17: this function could have a `#[must_use]` attribute +libc-0.2.81/src/macros.rs:259:17: this function could have a `#[must_use]` attribute +libc-0.2.81/src/macros.rs:259:17: this function could have a `#[must_use]` attribute +libc-0.2.81/src/macros.rs:259:17: this function could have a `#[must_use]` attribute +libc-0.2.81/src/macros.rs:259:17: this function could have a `#[must_use]` attribute +libc-0.2.81/src/macros.rs:259:17: this function could have a `#[must_use]` attribute +libc-0.2.81/src/macros.rs:259:17: this function could have a `#[must_use]` attribute +libc-0.2.81/src/macros.rs:259:17: this function could have a `#[must_use]` attribute +libc-0.2.81/src/macros.rs:259:17: this function could have a `#[must_use]` attribute +libc-0.2.81/src/macros.rs:259:17: this function could have a `#[must_use]` attribute +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:428:29: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:429:30: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:431:30: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:432:32: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:433:29: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:434:32: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:595:33: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:596:33: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:597:35: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:622:32: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:673:34: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:696:33: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:697:35: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:698:33: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:699:35: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:712:34: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:721:35: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:722:32: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:723:32: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:751:31: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:752:30: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:753:30: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:754:30: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:755:29: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:756:29: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:757:29: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:758:29: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:759:29: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:760:29: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:768:30: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:769:31: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:771:31: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:772:29: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:773:29: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:774:29: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:775:32: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:776:31: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:777:32: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:778:32: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:779:31: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:780:32: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:781:32: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:782:31: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:783:31: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:784:32: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:785:33: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:786:33: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:787:30: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:788:32: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:789:32: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:790:32: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:791:32: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:792:33: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:794:31: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:795:31: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:796:31: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:797:32: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:798:31: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:799:31: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:800:31: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:801:31: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:803:27: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:804:28: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:805:28: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:806:29: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:807:29: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:808:29: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:809:29: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:810:29: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:811:29: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:812:30: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:813:30: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:814:30: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:815:30: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:816:30: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:817:31: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:818:31: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:821:31: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:822:31: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:823:32: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:824:32: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:825:32: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:826:32: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:827:32: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:828:32: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:829:33: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:830:33: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:831:33: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:832:33: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:833:33: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:834:33: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:835:33: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:836:33: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:841:32: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:842:32: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:843:32: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:844:33: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:1120:38: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:178:34: integer type suffix should be separated by an underscore +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:291:5: this method could have a `#[must_use]` attribute libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:291:5: unsafe function's docs miss `# Safety` section +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:302:5: this method could have a `#[must_use]` attribute libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:302:5: unsafe function's docs miss `# Safety` section +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:355:13: this method could have a `#[must_use]` attribute libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:355:13: unsafe function's docs miss `# Safety` section +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:359:13: this method could have a `#[must_use]` attribute libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:359:13: unsafe function's docs miss `# Safety` section +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:363:13: this method could have a `#[must_use]` attribute libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:363:13: unsafe function's docs miss `# Safety` section +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:367:13: this method could have a `#[must_use]` attribute libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:367:13: unsafe function's docs miss `# Safety` section +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:371:13: this method could have a `#[must_use]` attribute libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:371:13: unsafe function's docs miss `# Safety` section +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:534:36: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:645:31: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:727:40: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:728:40: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:729:39: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:731:44: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:732:36: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:733:41: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:734:43: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:735:42: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:736:40: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:737:36: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:738:37: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:741:39: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:742:40: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:743:40: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:744:40: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:745:40: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:746:43: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:747:42: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:748:40: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:749:39: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:750:41: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:751:41: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:752:43: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:753:42: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:755:42: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:756:41: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:757:41: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:758:39: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:759:39: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:761:41: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:762:44: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:763:45: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:764:40: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:765:40: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:766:40: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:767:44: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:768:44: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:769:39: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:770:35: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:771:35: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:772:37: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:773:39: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:774:45: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:775:41: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:776:39: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:803:34: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:841:30: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:842:37: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:982:40: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:984:46: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1209:36: casting `i32` to `i16` may truncate the value +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1210:36: casting `i32` to `i16` may truncate the value +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1235:39: integer type suffix should be separated by an underscore +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1236:41: integer type suffix should be separated by an underscore +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1274:42: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1324:31: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1333:37: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1334:35: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1346:34: casting `u32` to `i32` may wrap around the value +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1346:34: integer type suffix should be separated by an underscore +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1346:34: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1347:37: casting `u32` to `i32` may wrap around the value +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1347:37: integer type suffix should be separated by an underscore +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1347:37: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1348:36: casting `u32` to `i32` may wrap around the value +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1348:36: integer type suffix should be separated by an underscore +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1348:36: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1349:37: casting `u32` to `i32` may wrap around the value +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1349:37: integer type suffix should be separated by an underscore +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1349:37: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1350:35: casting `u32` to `i32` may wrap around the value +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1350:35: integer type suffix should be separated by an underscore +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1350:35: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1351:36: casting `u32` to `i32` may wrap around the value +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1351:36: integer type suffix should be separated by an underscore +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1351:36: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1352:31: casting `u32` to `i32` may wrap around the value +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1352:31: integer type suffix should be separated by an underscore +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1352:31: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1419:36: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1420:36: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1421:36: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1422:36: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1423:36: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1490:37: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1561:46: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1562:45: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1567:31: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1568:32: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1586:26: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1587:34: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1588:31: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1589:31: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1897:38: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1898:51: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1900:39: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1969:34: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1970:34: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1971:36: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1972:36: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1973:36: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1974:37: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1975:37: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1976:36: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1977:36: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1978:39: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1979:39: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1980:39: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1981:39: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1982:39: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1983:39: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1984:38: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1985:38: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1986:35: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1987:35: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1988:35: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1989:35: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1990:38: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1991:37: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1992:37: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1993:38: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1994:37: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1995:37: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1996:37: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1997:37: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1998:33: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1999:33: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2000:33: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2001:34: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2002:34: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2003:34: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2004:35: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2005:35: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2032:30: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2033:32: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2034:31: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2035:29: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2036:32: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2037:28: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2038:27: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2039:29: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2041:29: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2042:28: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2043:27: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2044:34: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2045:27: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2046:33: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2048:28: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2049:32: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2050:32: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2051:32: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2052:26: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2053:36: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2318:42: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2321:38: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2331:39: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2487:42: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2488:42: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2489:43: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2490:43: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2491:43: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2493:47: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2494:44: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2495:46: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2496:47: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2497:49: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2498:48: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2499:50: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2500:45: long literal lacking separators libc-0.2.81/src/unix/linux_like/linux/mod.rs:2572:9: unneeded `return` statement libc-0.2.81/src/unix/linux_like/linux/mod.rs:2578:20: `0 as *mut _` detected libc-0.2.81/src/unix/linux_like/linux/mod.rs:2588:13: `0 as *mut _` detected +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2596:52: used binding `_dummy` which is prefixed with an underscore. A leading underscore signals that a binding will not be used. +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2597:11: casting `i32` to `usize` may lose the sign of the value +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2601:21: it is more concise to loop over references to containers instead of using explicit iteration methods libc-0.2.81/src/unix/linux_like/linux/mod.rs:2611:9: unneeded unit expression libc-0.2.81/src/unix/linux_like/linux/mod.rs:2619:9: unneeded unit expression +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2634:9: casting `u32` to `i32` may wrap around the value +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2647:25: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2648:25: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2649:9: casting `u64` to `u32` may truncate the value libc-0.2.81/src/unix/linux_like/linux/mod.rs:2654:18: the operation is ineffective. Consider reducing it to `(dev & 0x00000000000000ff)` +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2654:25: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2655:25: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2656:9: casting `u64` to `u32` may truncate the value +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2660:21: casting `u32` to `u64` may become silently lossy if you later change the type +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2661:21: casting `u32` to `u64` may become silently lossy if you later change the type +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2663:25: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2664:25: long literal lacking separators libc-0.2.81/src/unix/linux_like/linux/mod.rs:2665:16: the operation is ineffective. Consider reducing it to `(minor & 0x000000ff)` +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2665:25: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2666:25: long literal lacking separators +libc-0.2.81/src/unix/linux_like/linux/mod.rs:40:1: enum with no variants +libc-0.2.81/src/unix/linux_like/linux/mod.rs:954:34: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1000:31: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1001:32: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1002:32: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1016:29: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1017:32: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1018:33: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1019:33: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1020:33: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1029:29: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1030:29: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1031:30: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1032:29: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1033:29: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1034:29: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1035:29: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1041:32: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1042:32: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1043:32: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1044:32: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1045:31: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1046:32: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1047:31: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1048:31: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1049:31: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1050:31: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1051:33: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1053:29: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1054:33: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1055:30: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1056:31: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1057:31: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1058:32: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1059:31: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1060:31: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1073:42: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1074:43: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1075:37: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1076:37: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1077:41: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1078:35: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1079:35: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1080:36: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1081:35: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1082:35: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1083:31: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1084:38: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1086:30: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1087:32: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1089:30: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1090:33: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1091:30: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1094:40: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1095:37: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1096:41: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1097:40: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1098:39: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1099:34: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1100:36: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1101:38: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1102:37: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1105:44: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1106:41: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1107:42: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1108:42: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1109:41: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1110:46: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1111:41: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1112:44: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1113:40: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1114:47: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1115:36: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1126:34: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1127:29: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1128:31: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1179:32: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:1180:31: long literal lacking separators libc-0.2.81/src/unix/linux_like/mod.rs:1218:27: the operation is ineffective. Consider reducing it to `IPOPT_CONTROL` libc-0.2.81/src/unix/linux_like/mod.rs:1314:9: operator precedence can trip the unwary libc-0.2.81/src/unix/linux_like/mod.rs:1323:13: `0 as *mut _` detected +libc-0.2.81/src/unix/linux_like/mod.rs:1332:9: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers +libc-0.2.81/src/unix/linux_like/mod.rs:1337:9: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers +libc-0.2.81/src/unix/linux_like/mod.rs:1341:18: casting `i32` to `usize` may lose the sign of the value libc-0.2.81/src/unix/linux_like/mod.rs:1344:9: unneeded `return` statement +libc-0.2.81/src/unix/linux_like/mod.rs:1348:18: casting `i32` to `usize` may lose the sign of the value libc-0.2.81/src/unix/linux_like/mod.rs:1350:9: unneeded `return` statement +libc-0.2.81/src/unix/linux_like/mod.rs:1354:18: casting `i32` to `usize` may lose the sign of the value libc-0.2.81/src/unix/linux_like/mod.rs:1357:9: unneeded `return` statement +libc-0.2.81/src/unix/linux_like/mod.rs:1361:21: it is more concise to loop over references to containers instead of using explicit iteration methods +libc-0.2.81/src/unix/linux_like/mod.rs:1381:9: casting `i32` to `i8` may truncate the value +libc-0.2.81/src/unix/linux_like/mod.rs:1389:9: bit mask could be simplified with a call to `trailing_zeros` +libc-0.2.81/src/unix/linux_like/mod.rs:446:31: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:591:36: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:592:38: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:593:35: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:594:33: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:595:34: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:596:36: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:597:37: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:598:37: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:599:39: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:600:34: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:601:35: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:602:35: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:607:37: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:608:35: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:764:35: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:765:39: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:991:30: long literal lacking separators +libc-0.2.81/src/unix/linux_like/mod.rs:9:1: enum with no variants +libc-0.2.81/src/unix/mod.rs:198:29: long literal lacking separators +libc-0.2.81/src/unix/mod.rs:199:28: long literal lacking separators libc-0.2.81/src/unix/mod.rs:201:35: casting integer literal to `usize` is unnecessary libc-0.2.81/src/unix/mod.rs:202:35: casting integer literal to `usize` is unnecessary +libc-0.2.81/src/unix/mod.rs:282:40: long literal lacking separators +libc-0.2.81/src/unix/mod.rs:284:41: long literal lacking separators +libc-0.2.81/src/unix/mod.rs:285:36: long literal lacking separators +libc-0.2.81/src/unix/mod.rs:34:1: enum with no variants +libc-0.2.81/src/unix/mod.rs:386:1: enum with no variants +libc-0.2.81/src/unix/mod.rs:394:1: enum with no variants +quote-1.0.7/src/ext.rs:10:1: item name ends with its containing module's name +quote-1.0.7/src/ext.rs:7:5: you should put `TokenStream` between ticks in the documentation +quote-1.0.7/src/ident_fragment.rs:13:5: docs for function returning `Result` missing `# Errors` section quote-1.0.7/src/ident_fragment.rs:51:31: stripping a prefix manually +quote-1.0.7/src/runtime.rs:52:5: item name ends with its containing module's name +quote-1.0.7/src/runtime.rs:63:5: item name ends with its containing module's name +quote-1.0.7/src/runtime.rs:66:33: you should put `DoesNotHaveIter` between ticks in the documentation +quote-1.0.7/src/runtime.rs:80:5: item name ends with its containing module's name +rand_core-0.6.0/src/block.rs:117:1: item name starts with its containing module's name +rand_core-0.6.0/src/block.rs:153:5: you have declared `#[inline(always)]` on `index`. This is usually a bad idea +rand_core-0.6.0/src/block.rs:230:5: you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea +rand_core-0.6.0/src/block.rs:240:5: you have declared `#[inline(always)]` on `from_seed`. This is usually a bad idea +rand_core-0.6.0/src/block.rs:245:5: you have declared `#[inline(always)]` on `seed_from_u64`. This is usually a bad idea +rand_core-0.6.0/src/block.rs:250:5: you have declared `#[inline(always)]` on `from_rng`. This is usually a bad idea +rand_core-0.6.0/src/block.rs:280:1: item name starts with its containing module's name +rand_core-0.6.0/src/block.rs:319:5: you have declared `#[inline(always)]` on `index`. This is usually a bad idea +rand_core-0.6.0/src/block.rs:405:5: you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea +rand_core-0.6.0/src/block.rs:415:5: you have declared `#[inline(always)]` on `from_seed`. This is usually a bad idea +rand_core-0.6.0/src/block.rs:420:5: you have declared `#[inline(always)]` on `seed_from_u64`. This is usually a bad idea +rand_core-0.6.0/src/block.rs:425:5: you have declared `#[inline(always)]` on `from_rng`. This is usually a bad idea +rand_core-0.6.0/src/block.rs:67:14: you should put `module][crate::block` between ticks in the documentation +rand_core-0.6.0/src/block.rs:68:1: item name starts with its containing module's name +rand_core-0.6.0/src/error.rs:106:5: this method could have a `#[must_use]` attribute +rand_core-0.6.0/src/error.rs:87:5: this method could have a `#[must_use]` attribute +rand_core-0.6.0/src/error.rs:95:74: casting `u32` to `i32` may wrap around the value +rand_core-0.6.0/src/lib.rs:179:5: docs for function returning `Result` missing `# Errors` section +rand_core-0.6.0/src/lib.rs:301:5: this method could have a `#[must_use]` attribute +rand_core-0.6.0/src/lib.rs:303:26: long literal lacking separators +rand_core-0.6.0/src/lib.rs:304:26: long literal lacking separators +rand_core-0.6.0/src/lib.rs:313:30: casting `u64` to `u32` may truncate the value +rand_core-0.6.0/src/lib.rs:314:23: casting `u64` to `u32` may truncate the value +rand_core-0.6.0/src/lib.rs:346:5: docs for function returning `Result` missing `# Errors` section +rand_core-0.6.0/src/lib.rs:381:5: you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea +rand_core-0.6.0/src/lib.rs:386:5: you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea +rand_core-0.6.0/src/lib.rs:391:5: you have declared `#[inline(always)]` on `fill_bytes`. This is usually a bad idea +rand_core-0.6.0/src/lib.rs:396:5: you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea +unicode-xid-0.2.1/src/lib.rs:57:64: you should put `XID_Start` between ticks in the documentation +unicode-xid-0.2.1/src/lib.rs:60:10: you should put `XID_Start` between ticks in the documentation +unicode-xid-0.2.1/src/lib.rs:62:27: you should put `ID_Start` between ticks in the documentation +unicode-xid-0.2.1/src/lib.rs:62:67: you should put `NFKx` between ticks in the documentation +unicode-xid-0.2.1/src/lib.rs:65:61: you should put `XID_Continue` between ticks in the documentation +unicode-xid-0.2.1/src/lib.rs:68:10: you should put `XID_Continue` between ticks in the documentation +unicode-xid-0.2.1/src/lib.rs:70:28: you should put `ID_Continue` between ticks in the documentation +unicode-xid-0.2.1/src/lib.rs:70:72: you should put `NFKx` between ticks in the documentation +proc-macro2-1.0.24/src/detection.rs:2:5: usage of wildcard import +proc-macro2-1.0.24/src/fallback.rs:108:17: wildcard match will miss any future added variants +proc-macro2-1.0.24/src/fallback.rs:269:20: unused `self` argument +proc-macro2-1.0.24/src/fallback.rs:430:24: this argument (0 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) +proc-macro2-1.0.24/src/fallback.rs:437:23: this argument (0 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) +proc-macro2-1.0.24/src/fallback.rs:437:23: unused `self` argument +proc-macro2-1.0.24/src/fallback.rs:471:17: this argument (0 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) +proc-macro2-1.0.24/src/fallback.rs:471:17: unused `self` argument proc-macro2-1.0.24/src/fallback.rs:654:5: manual `RangeInclusive::contains` implementation proc-macro2-1.0.24/src/fallback.rs:655:12: manual `RangeInclusive::contains` implementation proc-macro2-1.0.24/src/fallback.rs:661:5: manual `RangeInclusive::contains` implementation proc-macro2-1.0.24/src/fallback.rs:662:12: manual `RangeInclusive::contains` implementation proc-macro2-1.0.24/src/fallback.rs:664:12: manual `RangeInclusive::contains` implementation proc-macro2-1.0.24/src/fallback.rs:674:37: manual `RangeInclusive::contains` implementation +proc-macro2-1.0.24/src/fallback.rs:678:5: adding items after statements is confusing, since items exist from the start of the scope +proc-macro2-1.0.24/src/fallback.rs:85:9: adding items after statements is confusing, since items exist from the start of the scope +proc-macro2-1.0.24/src/fallback.rs:882:43: unused `self` argument +proc-macro2-1.0.24/src/lib.rs:1017:9: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:1081:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:1099:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:1117:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:1135:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:1141:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:1146:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:1151:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:1156:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:152:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:157:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:373:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:383:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:397:24: this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) +proc-macro2-1.0.24/src/lib.rs:397:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:403:23: this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) +proc-macro2-1.0.24/src/lib.rs:403:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:418:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:425:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:464:17: this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) +proc-macro2-1.0.24/src/lib.rs:500:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:626:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:633:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:641:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:652:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:662:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:672:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:734:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:743:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:752:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:757:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:788:19: you should put `XID_Start` between ticks in the documentation +proc-macro2-1.0.24/src/lib.rs:788:69: you should put `XID_Continue` between ticks in the documentation +proc-macro2-1.0.24/src/lib.rs:891:36: you should put `syn::parse_str` between ticks in the documentation +proc-macro2-1.0.24/src/lib.rs:894:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:911:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:996:9: this method could have a `#[must_use]` attribute proc-macro2-1.0.24/src/parse.rs:552:5: this loop could be written as a `for` loop proc-macro2-1.0.24/src/parse.rs:584:21: manual `RangeInclusive::contains` implementation +proc-macro2-1.0.24/src/parse.rs:602:20: called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead +proc-macro2-1.0.24/src/parse.rs:696:29: casting `u8` to `u64` may become silently lossy if you later change the type +proc-macro2-1.0.24/src/parse.rs:702:34: casting `u8` to `u64` may become silently lossy if you later change the type +proc-macro2-1.0.24/src/parse.rs:708:34: casting `u8` to `u64` may become silently lossy if you later change the type +proc-macro2-1.0.24/src/parse.rs:803:15: it is more concise to loop over references to containers instead of using explicit iteration methods +proc-macro2-1.0.24/src/parse.rs:808:15: it is more concise to loop over references to containers instead of using explicit iteration methods +proc-macro2-1.0.24/src/wrapper.rs:415:24: this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) +proc-macro2-1.0.24/src/wrapper.rs:429:23: this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) +proc-macro2-1.0.24/src/wrapper.rs:492:17: this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) +log-0.4.11/src/lib.rs:1047:5: this method could have a `#[must_use]` attribute +log-0.4.11/src/lib.rs:1053:5: this method could have a `#[must_use]` attribute +log-0.4.11/src/lib.rs:1059:5: this method could have a `#[must_use]` attribute +log-0.4.11/src/lib.rs:1093:5: this method could have a `#[must_use]` attribute log-0.4.11/src/lib.rs:1093:5: you should consider adding a `Default` implementation for `MetadataBuilder<'a>` +log-0.4.11/src/lib.rs:1118:5: this method could have a `#[must_use]` attribute +log-0.4.11/src/lib.rs:1177:1: you have declared `#[inline(always)]` on `max_level`. This is usually a bad idea +log-0.4.11/src/lib.rs:1178:1: this function could have a `#[must_use]` attribute +log-0.4.11/src/lib.rs:1306:1: docs for function returning `Result` missing `# Errors` section +log-0.4.11/src/lib.rs:1358:1: this function could have a `#[must_use]` attribute +log-0.4.11/src/lib.rs:1359:5: unnecessary `!=` operation +log-0.4.11/src/lib.rs:1407:1: this function could have a `#[must_use]` attribute log-0.4.11/src/lib.rs:329:27: you are deriving `Hash` but have implemented `PartialEq` explicitly +log-0.4.11/src/lib.rs:356:1: you are implementing `Clone` explicitly on a `Copy` type log-0.4.11/src/lib.rs:448:12: manual `RangeInclusive::contains` implementation +log-0.4.11/src/lib.rs:468:13: called `filter(..).map(..)` on an `Iterator` +log-0.4.11/src/lib.rs:500:5: this method could have a `#[must_use]` attribute +log-0.4.11/src/lib.rs:506:28: this argument (8 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) +log-0.4.11/src/lib.rs:506:5: this method could have a `#[must_use]` attribute log-0.4.11/src/lib.rs:520:27: you are deriving `Hash` but have implemented `PartialEq` explicitly +log-0.4.11/src/lib.rs:538:1: you are implementing `Clone` explicitly on a `Copy` type +log-0.4.11/src/lib.rs:653:5: this method could have a `#[must_use]` attribute +log-0.4.11/src/lib.rs:661:21: this argument (8 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) +log-0.4.11/src/lib.rs:661:5: this method could have a `#[must_use]` attribute +log-0.4.11/src/lib.rs:677:44: this `match` has identical arm bodies +log-0.4.11/src/lib.rs:758:5: this method could have a `#[must_use]` attribute +log-0.4.11/src/lib.rs:764:5: this method could have a `#[must_use]` attribute +log-0.4.11/src/lib.rs:770:5: this method could have a `#[must_use]` attribute +log-0.4.11/src/lib.rs:776:5: this method could have a `#[must_use]` attribute +log-0.4.11/src/lib.rs:782:5: this method could have a `#[must_use]` attribute +log-0.4.11/src/lib.rs:788:5: this method could have a `#[must_use]` attribute +log-0.4.11/src/lib.rs:794:5: this method could have a `#[must_use]` attribute +log-0.4.11/src/lib.rs:803:5: this method could have a `#[must_use]` attribute +log-0.4.11/src/lib.rs:809:5: this method could have a `#[must_use]` attribute +log-0.4.11/src/lib.rs:818:5: this method could have a `#[must_use]` attribute +log-0.4.11/src/lib.rs:908:5: this method could have a `#[must_use]` attribute log-0.4.11/src/lib.rs:908:5: you should consider adding a `Default` implementation for `RecordBuilder<'a>` +log-0.4.11/src/lib.rs:995:5: this method could have a `#[must_use]` attribute regex-1.4.2/src/backtrack.rs:100:13: redundant field names in struct initialization regex-1.4.2/src/backtrack.rs:133:17: it looks like the same item is being pushed into this Vec +regex-1.4.2/src/backtrack.rs:145:20: unnecessary boolean `not` operation +regex-1.4.2/src/backtrack.rs:199:13: usage of wildcard import for enum variants regex-1.4.2/src/backtrack.rs:223:29: redundant field names in struct initialization regex-1.4.2/src/backtrack.rs:230:66: redundant field names in struct initialization +regex-1.4.2/src/backtrack.rs:284:21: casting `u32` to `u64` may become silently lossy if you later change the type +regex-1.4.2/src/backtrack.rs:287:5: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers regex-1.4.2/src/backtrack.rs:97:13: redundant field names in struct initialization regex-1.4.2/src/backtrack.rs:98:13: redundant field names in struct initialization regex-1.4.2/src/backtrack.rs:99:13: redundant field names in struct initialization regex-1.4.2/src/compile.rs:1000:17: redundant field names in struct initialization +regex-1.4.2/src/compile.rs:103:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/compile.rs:1048:17: you should put `HashMap` between ticks in the documentation +regex-1.4.2/src/compile.rs:1075:26: integer type suffix should be separated by an underscore regex-1.4.2/src/compile.rs:1089:44: redundant field names in struct initialization regex-1.4.2/src/compile.rs:1089:54: redundant field names in struct initialization +regex-1.4.2/src/compile.rs:1100:32: long literal lacking separators +regex-1.4.2/src/compile.rs:1101:21: long literal lacking separators +regex-1.4.2/src/compile.rs:1103:18: casting `u8` to `u64` may become silently lossy if you later change the type +regex-1.4.2/src/compile.rs:1104:18: casting `u8` to `u64` may become silently lossy if you later change the type +regex-1.4.2/src/compile.rs:1105:9: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers +regex-1.4.2/src/compile.rs:1132:37: casting `u16` to `u8` may truncate the value +regex-1.4.2/src/compile.rs:1132:55: casting `u16` to `u8` may truncate the value +regex-1.4.2/src/compile.rs:1135:28: casting `u16` to `u8` may truncate the value +regex-1.4.2/src/compile.rs:1135:38: casting `u16` to `u8` may truncate the value +regex-1.4.2/src/compile.rs:113:5: docs for function returning `Result` missing `# Errors` section +regex-1.4.2/src/compile.rs:1146:25: integer type suffix should be separated by an underscore +regex-1.4.2/src/compile.rs:1166:8: casting `u32` to `u64` may become silently lossy if you later change the type regex-1.4.2/src/compile.rs:136:46: use of `unwrap_or` followed by a function call +regex-1.4.2/src/compile.rs:155:30: redundant closure found +regex-1.4.2/src/compile.rs:157:30: redundant closure found regex-1.4.2/src/compile.rs:172:42: use of `unwrap_or` followed by a function call regex-1.4.2/src/compile.rs:180:43: use of `unwrap_or` followed by a function call regex-1.4.2/src/compile.rs:188:5: this function's return value is unnecessarily wrapped by `Result` +regex-1.4.2/src/compile.rs:190:40: redundant closure found +regex-1.4.2/src/compile.rs:204:53: you should put `MaybeInsts` between ticks in the documentation +regex-1.4.2/src/compile.rs:244:63: you should put `c_concat` between ticks in the documentation +regex-1.4.2/src/compile.rs:251:5: this function has too many lines (111/100) +regex-1.4.2/src/compile.rs:253:13: usage of wildcard import for enum variants regex-1.4.2/src/compile.rs:375:39: use of `unwrap_or` followed by a function call regex-1.4.2/src/compile.rs:379:29: redundant field names in struct initialization regex-1.4.2/src/compile.rs:379:41: redundant field names in struct initialization +regex-1.4.2/src/compile.rs:384:12: unnecessary boolean `not` operation regex-1.4.2/src/compile.rs:413:56: redundant field names in struct initialization regex-1.4.2/src/compile.rs:421:45: redundant field names in struct initialization regex-1.4.2/src/compile.rs:428:51: redundant field names in struct initialization regex-1.4.2/src/compile.rs:430:29: redundant field names in struct initialization regex-1.4.2/src/compile.rs:438:5: this function's return value is unnecessarily wrapped by `Result` +regex-1.4.2/src/compile.rs:43:5: this method could have a `#[must_use]` attribute regex-1.4.2/src/compile.rs:43:5: you should consider adding a `Default` implementation for `compile::Compiler` regex-1.4.2/src/compile.rs:468:5: this function's return value is unnecessarily wrapped by `Result` regex-1.4.2/src/compile.rs:469:57: redundant field names in struct initialization regex-1.4.2/src/compile.rs:470:25: redundant field names in struct initialization regex-1.4.2/src/compile.rs:494:25: redundant field names in struct initialization regex-1.4.2/src/compile.rs:494:37: redundant field names in struct initialization +regex-1.4.2/src/compile.rs:547:13: usage of wildcard import for enum variants +regex-1.4.2/src/compile.rs:56:57: you should put `size_limit` between ticks in the documentation +regex-1.4.2/src/compile.rs:59:5: this method could have a `#[must_use]` attribute regex-1.4.2/src/compile.rs:637:14: use of `unwrap_or` followed by a function call +regex-1.4.2/src/compile.rs:638:9: use Option::map_or instead of an if let/else regex-1.4.2/src/compile.rs:661:41: use of `unwrap_or` followed by a function call +regex-1.4.2/src/compile.rs:703:9: you should put `c_function` between ticks in the documentation +regex-1.4.2/src/compile.rs:75:5: this method could have a `#[must_use]` attribute regex-1.4.2/src/compile.rs:786:5: this function's return value is unnecessarily wrapped by `Result` regex-1.4.2/src/compile.rs:838:21: redundant field names in struct initialization regex-1.4.2/src/compile.rs:845:21: redundant field names in struct initialization +regex-1.4.2/src/compile.rs:848:13: wildcard match will miss any future added variants +regex-1.4.2/src/compile.rs:84:5: this method could have a `#[must_use]` attribute regex-1.4.2/src/compile.rs:860:41: redundant field names in struct initialization regex-1.4.2/src/compile.rs:860:55: redundant field names in struct initialization regex-1.4.2/src/compile.rs:920:39: redundant field names in struct initialization @@ -292,97 +2886,367 @@ regex-1.4.2/src/compile.rs:927:43: redundant field names in struct initializatio regex-1.4.2/src/compile.rs:930:41: redundant field names in struct initialization regex-1.4.2/src/compile.rs:930:53: redundant field names in struct initialization regex-1.4.2/src/compile.rs:930:67: redundant field names in struct initialization +regex-1.4.2/src/compile.rs:96:5: this method could have a `#[must_use]` attribute regex-1.4.2/src/compile.rs:991:5: this function's return value is unnecessarily wrapped by `Result` +regex-1.4.2/src/dfa.rs:1007:17: binding's name is too similar to existing binding +regex-1.4.2/src/dfa.rs:1010:22: binding's name is too similar to existing binding +regex-1.4.2/src/dfa.rs:1059:13: usage of wildcard import for enum variants +regex-1.4.2/src/dfa.rs:1060:13: usage of wildcard import for enum variants +regex-1.4.2/src/dfa.rs:1084:38: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers +regex-1.4.2/src/dfa.rs:1087:38: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers +regex-1.4.2/src/dfa.rs:1090:38: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers +regex-1.4.2/src/dfa.rs:1093:38: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers +regex-1.4.2/src/dfa.rs:1096:38: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers +regex-1.4.2/src/dfa.rs:1101:38: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers +regex-1.4.2/src/dfa.rs:1104:38: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers +regex-1.4.2/src/dfa.rs:1107:38: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers +regex-1.4.2/src/dfa.rs:1117:30: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers +regex-1.4.2/src/dfa.rs:1120:47: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers +regex-1.4.2/src/dfa.rs:1121:30: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers +regex-1.4.2/src/dfa.rs:1129:13: you should put `is_match` between ticks in the documentation +regex-1.4.2/src/dfa.rs:1134:13: you should put `is_match` between ticks in the documentation +regex-1.4.2/src/dfa.rs:1185:68: you should put `is_match` between ticks in the documentation +regex-1.4.2/src/dfa.rs:1193:13: usage of wildcard import for enum variants +regex-1.4.2/src/dfa.rs:1244:50: you should put `current_state` between ticks in the documentation +regex-1.4.2/src/dfa.rs:1338:58: you should put `STATE_DEAD` between ticks in the documentation +regex-1.4.2/src/dfa.rs:1339:9: you should put `STATE_UNKNOWN` between ticks in the documentation +regex-1.4.2/src/dfa.rs:1366:25: you should put `STATE_DEAD` between ticks in the documentation +regex-1.4.2/src/dfa.rs:1366:46: you should put `STATE_UNKNOWN` between ticks in the documentation +regex-1.4.2/src/dfa.rs:1367:41: you have declared `#[inline(always)]` on `start_state`. This is usually a bad idea regex-1.4.2/src/dfa.rs:1380:14: the operation is ineffective. Consider reducing it to `(empty_flags.start as u8)` +regex-1.4.2/src/dfa.rs:1388:15: indexing into a vector may panic +regex-1.4.2/src/dfa.rs:1412:20: unused `self` argument +regex-1.4.2/src/dfa.rs:1438:9: unused `self` argument +regex-1.4.2/src/dfa.rs:1472:9: you should put `StatePtr` between ticks in the documentation +regex-1.4.2/src/dfa.rs:1490:54: casting `i32` to `u8` may lose the sign of the value +regex-1.4.2/src/dfa.rs:1490:54: casting `i32` to `u8` may truncate the value +regex-1.4.2/src/dfa.rs:1521:20: you should put `num_byte_classes` between ticks in the documentation +regex-1.4.2/src/dfa.rs:1529:41: you have declared `#[inline(always)]` on `byte_class`. This is usually a bad idea +regex-1.4.2/src/dfa.rs:1537:14: you should put `byte_class` between ticks in the documentation +regex-1.4.2/src/dfa.rs:1538:41: you have declared `#[inline(always)]` on `u8_class`. This is usually a bad idea +regex-1.4.2/src/dfa.rs:1562:18: you should put `STATE_START` between ticks in the documentation regex-1.4.2/src/dfa.rs:1614:13: redundant field names in struct initialization regex-1.4.2/src/dfa.rs:1651:38: redundant field names in struct initialization +regex-1.4.2/src/dfa.rs:1700:17: this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) regex-1.4.2/src/dfa.rs:1701:18: digits of hex or binary literal not grouped by four regex-1.4.2/src/dfa.rs:1705:19: digits of hex or binary literal not grouped by four +regex-1.4.2/src/dfa.rs:1708:16: this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) regex-1.4.2/src/dfa.rs:1709:18: digits of hex or binary literal not grouped by four regex-1.4.2/src/dfa.rs:1713:19: digits of hex or binary literal not grouped by four +regex-1.4.2/src/dfa.rs:1716:18: this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) regex-1.4.2/src/dfa.rs:1717:18: digits of hex or binary literal not grouped by four regex-1.4.2/src/dfa.rs:1721:19: digits of hex or binary literal not grouped by four +regex-1.4.2/src/dfa.rs:1727:14: casting `u8` to `u16` may become silently lossy if you later change the type +regex-1.4.2/src/dfa.rs:1732:15: this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) +regex-1.4.2/src/dfa.rs:1736:22: this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) regex-1.4.2/src/dfa.rs:1741:9: match expression looks like `matches!` macro +regex-1.4.2/src/dfa.rs:1747:16: this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) +regex-1.4.2/src/dfa.rs:1751:18: casting `u16` to `u8` may truncate the value +regex-1.4.2/src/dfa.rs:1815:38: casting `usize` to `u8` may truncate the value +regex-1.4.2/src/dfa.rs:1821:21: casting `u32` to `u64` may become silently lossy if you later change the type +regex-1.4.2/src/dfa.rs:1824:5: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers +regex-1.4.2/src/dfa.rs:1848:5: you should put bare URLs between `<`/`>` or make a proper Markdown link +regex-1.4.2/src/dfa.rs:1850:18: casting `i32` to `u32` may lose the sign of the value +regex-1.4.2/src/dfa.rs:1857:5: you should put bare URLs between `<`/`>` or make a proper Markdown link +regex-1.4.2/src/dfa.rs:1860:17: casting `u32` to `i32` may wrap around the value +regex-1.4.2/src/dfa.rs:1867:5: you should put bare URLs between `<`/`>` or make a proper Markdown link +regex-1.4.2/src/dfa.rs:1870:19: casting `u32` to `u8` may truncate the value +regex-1.4.2/src/dfa.rs:1873:15: casting `u32` to `u8` may truncate the value +regex-1.4.2/src/dfa.rs:1876:5: you should put bare URLs between `<`/`>` or make a proper Markdown link +regex-1.4.2/src/dfa.rs:1882:26: casting `u8` to `u32` may become silently lossy if you later change the type +regex-1.4.2/src/dfa.rs:1884:15: casting `u8` to `u32` may become silently lossy if you later change the type +regex-1.4.2/src/dfa.rs:277:17: casting `u32` to `i32` may wrap around the value +regex-1.4.2/src/dfa.rs:277:31: casting `u32` to `i32` may wrap around the value +regex-1.4.2/src/dfa.rs:295:20: casting `usize` to `i32` may truncate the value on targets with 64-bit wide pointers +regex-1.4.2/src/dfa.rs:295:20: casting `usize` to `i32` may wrap around the value on targets with 32-bit wide pointers +regex-1.4.2/src/dfa.rs:299:21: casting `i32` to `usize` may lose the sign of the value +regex-1.4.2/src/dfa.rs:34:46: you should put bare URLs between `<`/`>` or make a proper Markdown link +regex-1.4.2/src/dfa.rs:398:1: more than 3 bools in a struct +regex-1.4.2/src/dfa.rs:446:41: you have declared `#[inline(always)]` on `forward`. This is usually a bad idea regex-1.4.2/src/dfa.rs:457:13: redundant field names in struct initialization regex-1.4.2/src/dfa.rs:459:13: redundant field names in struct initialization regex-1.4.2/src/dfa.rs:460:13: redundant field names in struct initialization +regex-1.4.2/src/dfa.rs:476:41: you have declared `#[inline(always)]` on `reverse`. This is usually a bad idea regex-1.4.2/src/dfa.rs:487:13: redundant field names in struct initialization regex-1.4.2/src/dfa.rs:489:13: redundant field names in struct initialization regex-1.4.2/src/dfa.rs:490:13: redundant field names in struct initialization +regex-1.4.2/src/dfa.rs:506:41: you have declared `#[inline(always)]` on `forward_many`. This is usually a bad idea regex-1.4.2/src/dfa.rs:518:13: redundant field names in struct initialization regex-1.4.2/src/dfa.rs:520:13: redundant field names in struct initialization +regex-1.4.2/src/dfa.rs:554:41: you have declared `#[inline(always)]` on `exec_at`. This is usually a bad idea +regex-1.4.2/src/dfa.rs:555:5: this function has too many lines (101/100) +regex-1.4.2/src/dfa.rs:58:9: usage of wildcard import for enum variants +regex-1.4.2/src/dfa.rs:667:21: binding's name is too similar to existing binding +regex-1.4.2/src/dfa.rs:747:41: you have declared `#[inline(always)]` on `exec_at_reverse`. This is usually a bad idea +regex-1.4.2/src/dfa.rs:795:21: binding's name is too similar to existing binding +regex-1.4.2/src/dfa.rs:848:9: you should put `next_si` between ticks in the documentation +regex-1.4.2/src/dfa.rs:852:41: you have declared `#[inline(always)]` on `next_si`. This is usually a bad idea +regex-1.4.2/src/dfa.rs:885:12: you should put `STATE_DEAD` between ticks in the documentation +regex-1.4.2/src/dfa.rs:889:9: you should put `STATE_UNKNOWN` between ticks in the documentation +regex-1.4.2/src/dfa.rs:897:13: usage of wildcard import for enum variants +regex-1.4.2/src/dfa.rs:979:29: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers regex-1.4.2/src/error.rs:6:1: this seems like a manual implementation of the non-exhaustive pattern +regex-1.4.2/src/exec.rs:1000:14: you should put `captures_nfa` between ticks in the documentation +regex-1.4.2/src/exec.rs:100:1: item name starts with its containing module's name regex-1.4.2/src/exec.rs:1028:5: this function has too many arguments (9/7) +regex-1.4.2/src/exec.rs:1039:13: usage of wildcard import for enum variants +regex-1.4.2/src/exec.rs:1144:13: usage of wildcard import for enum variants +regex-1.4.2/src/exec.rs:1179:26: this `match` has identical arm bodies +regex-1.4.2/src/exec.rs:122:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/exec.rs:1250:41: you have declared `#[inline(always)]` on `searcher`. This is usually a bad idea +regex-1.4.2/src/exec.rs:1260:41: you have declared `#[inline(always)]` on `searcher_str`. This is usually a bad idea +regex-1.4.2/src/exec.rs:1270:17: you should put `RegexSet` between ticks in the documentation +regex-1.4.2/src/exec.rs:1280:17: you should put `RegexSet` between ticks in the documentation regex-1.4.2/src/exec.rs:137:9: field assignment outside of initializer for an instance created with Default::default() +regex-1.4.2/src/exec.rs:142:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/exec.rs:158:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/exec.rs:168:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/exec.rs:181:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/exec.rs:195:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/exec.rs:204:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/exec.rs:210:5: this method could have a `#[must_use]` attribute regex-1.4.2/src/exec.rs:245:62: this `if` has identical blocks +regex-1.4.2/src/exec.rs:251:21: unnecessary boolean `not` operation regex-1.4.2/src/exec.rs:262:60: this `if` has identical blocks +regex-1.4.2/src/exec.rs:268:21: unnecessary boolean `not` operation regex-1.4.2/src/exec.rs:278:13: redundant field names in struct initialization regex-1.4.2/src/exec.rs:281:13: redundant field names in struct initialization +regex-1.4.2/src/exec.rs:286:5: docs for function returning `Result` missing `# Errors` section regex-1.4.2/src/exec.rs:300:30: redundant field names in struct initialization +regex-1.4.2/src/exec.rs:308:17: binding's name is too similar to existing binding regex-1.4.2/src/exec.rs:329:13: redundant field names in struct initialization regex-1.4.2/src/exec.rs:330:13: redundant field names in struct initialization regex-1.4.2/src/exec.rs:331:13: redundant field names in struct initialization regex-1.4.2/src/exec.rs:334:13: redundant field names in struct initialization regex-1.4.2/src/exec.rs:340:19: redundant field names in struct initialization +regex-1.4.2/src/exec.rs:344:27: unused `self` argument +regex-1.4.2/src/exec.rs:383:41: you have declared `#[inline(always)]` on `shortest_match_at`. This is usually a bad idea +regex-1.4.2/src/exec.rs:388:41: you have declared `#[inline(always)]` on `is_match_at`. This is usually a bad idea +regex-1.4.2/src/exec.rs:393:41: you have declared `#[inline(always)]` on `find_at`. This is usually a bad idea +regex-1.4.2/src/exec.rs:398:41: you have declared `#[inline(always)]` on `captures_read_at`. This is usually a bad idea +regex-1.4.2/src/exec.rs:425:41: you have declared `#[inline(always)]` on `shortest_match_at`. This is usually a bad idea +regex-1.4.2/src/exec.rs:44:1: item name starts with its containing module's name +regex-1.4.2/src/exec.rs:473:9: you should put `shortest_match(...).is_some` between ticks in the documentation +regex-1.4.2/src/exec.rs:474:41: you have declared `#[inline(always)]` on `is_match_at`. This is usually a bad idea +regex-1.4.2/src/exec.rs:524:41: you have declared `#[inline(always)]` on `find_at`. This is usually a bad idea +regex-1.4.2/src/exec.rs:52:1: item name starts with its containing module's name +regex-1.4.2/src/exec.rs:686:13: usage of wildcard import for enum variants +regex-1.4.2/src/exec.rs:727:13: usage of wildcard import for enum variants +regex-1.4.2/src/exec.rs:767:13: usage of wildcard import for enum variants +regex-1.4.2/src/exec.rs:783:41: you have declared `#[inline(always)]` on `shortest_dfa`. This is usually a bad idea +regex-1.4.2/src/exec.rs:791:41: you have declared `#[inline(always)]` on `shortest_dfa_reverse_suffix`. This is usually a bad idea +regex-1.4.2/src/exec.rs:823:13: usage of wildcard import for enum variants +regex-1.4.2/src/exec.rs:868:13: usage of wildcard import for enum variants +regex-1.4.2/src/exec.rs:897:31: you should put `shortest_nfa(...).is_some` between ticks in the documentation +regex-1.4.2/src/exec.rs:899:9: you should put `shortest_nfa` between ticks in the documentation +regex-1.4.2/src/exec.rs:905:14: you should put `match_nfa` between ticks in the documentation +regex-1.4.2/src/exec.rs:930:14: you should put `shortest_nfa` between ticks in the documentation +regex-1.4.2/src/exec.rs:981:14: you should put `find_nfa` between ticks in the documentation regex-1.4.2/src/expand.rs:130:22: this call to `as_ref` does nothing +regex-1.4.2/src/expand.rs:185:27: this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) regex-1.4.2/src/expand.rs:186:5: match expression looks like `matches!` macro regex-1.4.2/src/expand.rs:22:13: calling `push_str()` using a single-character string literal +regex-1.4.2/src/expand.rs:27:23: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` regex-1.4.2/src/expand.rs:30:17: calling `push_str()` using a single-character string literal +regex-1.4.2/src/expand.rs:38:30: called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead +regex-1.4.2/src/expand.rs:42:21: called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead +regex-1.4.2/src/expand.rs:50:1: item name starts with its containing module's name +regex-1.4.2/src/expand.rs:69:23: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +regex-1.4.2/src/expand.rs:80:28: called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead +regex-1.4.2/src/expand.rs:84:21: called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead +regex-1.4.2/src/expand.rs:8:1: item name starts with its containing module's name +regex-1.4.2/src/input.rs:142:1: item name ends with its containing module's name +regex-1.4.2/src/input.rs:146:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/input.rs:15:1: item name starts with its containing module's name regex-1.4.2/src/input.rs:165:31: redundant field names in struct initialization +regex-1.4.2/src/input.rs:178:13: usage of wildcard import for enum variants +regex-1.4.2/src/input.rs:228:1: item name ends with its containing module's name regex-1.4.2/src/input.rs:236:21: redundant field names in struct initialization regex-1.4.2/src/input.rs:236:33: redundant field names in struct initialization +regex-1.4.2/src/input.rs:24:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/input.rs:271:13: usage of wildcard import for enum variants +regex-1.4.2/src/input.rs:29:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/input.rs:362:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/input.rs:370:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/input.rs:371:42: redundant closure found +regex-1.4.2/src/input.rs:37:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/input.rs:388:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/input.rs:42:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/input.rs:47:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/input.rs:53:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/input.rs:58:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/input.rs:63:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/literal/imp.rs:101:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/literal/imp.rs:114:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/literal/imp.rs:127:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/literal/imp.rs:139:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/literal/imp.rs:144:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/literal/imp.rs:149:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/literal/imp.rs:154:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/literal/imp.rs:155:13: usage of wildcard import for enum variants +regex-1.4.2/src/literal/imp.rs:160:30: this `match` has identical arm bodies +regex-1.4.2/src/literal/imp.rs:167:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/literal/imp.rs:168:13: usage of wildcard import for enum variants +regex-1.4.2/src/literal/imp.rs:211:20: redundant else block +regex-1.4.2/src/literal/imp.rs:276:50: this `match` has identical arm bodies +regex-1.4.2/src/literal/imp.rs:342:41: you have declared `#[inline(always)]` on `find`. This is usually a bad idea regex-1.4.2/src/literal/imp.rs:435:13: redundant field names in struct initialization regex-1.4.2/src/literal/imp.rs:436:13: redundant field names in struct initialization regex-1.4.2/src/literal/imp.rs:437:13: redundant field names in struct initialization regex-1.4.2/src/literal/imp.rs:438:13: redundant field names in struct initialization regex-1.4.2/src/literal/imp.rs:439:13: redundant field names in struct initialization regex-1.4.2/src/literal/imp.rs:440:13: redundant field names in struct initialization +regex-1.4.2/src/literal/imp.rs:455:41: you have declared `#[inline(always)]` on `find`. This is usually a bad idea +regex-1.4.2/src/literal/imp.rs:46:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/literal/imp.rs:481:41: you have declared `#[inline(always)]` on `is_suffix`. This is usually a bad idea +regex-1.4.2/src/literal/imp.rs:51:5: this method could have a `#[must_use]` attribute regex-1.4.2/src/literal/imp.rs:579:13: redundant field names in struct initialization +regex-1.4.2/src/literal/imp.rs:57:5: this method could have a `#[must_use]` attribute regex-1.4.2/src/literal/imp.rs:580:13: redundant field names in struct initialization regex-1.4.2/src/literal/imp.rs:583:13: redundant field names in struct initialization +regex-1.4.2/src/literal/imp.rs:602:9: adding items after statements is confusing, since items exist from the start of the scope +regex-1.4.2/src/literal/imp.rs:622:24: redundant else block +regex-1.4.2/src/literal/imp.rs:62:18: this argument is passed by value, but not consumed in the function body +regex-1.4.2/src/literal/imp.rs:637:24: redundant else block regex-1.4.2/src/literal/imp.rs:648:9: unneeded `return` statement +regex-1.4.2/src/literal/imp.rs:651:44: you should put `BoyerMooreSearch` between ticks in the documentation regex-1.4.2/src/literal/imp.rs:65:13: redundant field names in struct initialization regex-1.4.2/src/literal/imp.rs:68:13: redundant field names in struct initialization +regex-1.4.2/src/literal/imp.rs:783:32: redundant else block regex-1.4.2/src/literal/imp.rs:786:42: manual saturating arithmetic +regex-1.4.2/src/literal/imp.rs:78:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/literal/imp.rs:84:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/literal/imp.rs:850:20: long literal lacking separators +regex-1.4.2/src/literal/imp.rs:85:13: usage of wildcard import for enum variants regex-1.4.2/src/pikevm.rs:103:15: redundant field names in struct initialization regex-1.4.2/src/pikevm.rs:103:52: redundant field names in struct initialization regex-1.4.2/src/pikevm.rs:114:5: this function has too many arguments (8/7) +regex-1.4.2/src/pikevm.rs:117:13: binding's name is too similar to existing binding +regex-1.4.2/src/pikevm.rs:124:17: binding's name is too similar to existing binding +regex-1.4.2/src/pikevm.rs:220:9: you should put `thread_caps` between ticks in the documentation +regex-1.4.2/src/pikevm.rs:222:16: you should put `at_next` between ticks in the documentation +regex-1.4.2/src/pikevm.rs:223:9: you should put `at_next` between ticks in the documentation regex-1.4.2/src/pikevm.rs:224:5: this function has too many arguments (8/7) +regex-1.4.2/src/pikevm.rs:234:13: usage of wildcard import for enum variants +regex-1.4.2/src/pikevm.rs:303:13: usage of wildcard import for enum variants +regex-1.4.2/src/pikevm.rs:331:29: this expression mutably borrows a mutable reference. Consider reborrowing regex-1.4.2/src/pikevm.rs:88:5: this function has too many arguments (8/7) +regex-1.4.2/src/prog.rs:102:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/prog.rs:113:5: this method could have a `#[must_use]` attribute regex-1.4.2/src/prog.rs:120:9: match expression looks like `matches!` macro +regex-1.4.2/src/prog.rs:128:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/prog.rs:134:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/prog.rs:141:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/prog.rs:147:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/prog.rs:164:41: you have declared `#[inline(always)]` on `deref`. This is usually a bad idea +regex-1.4.2/src/prog.rs:172:13: usage of wildcard import for enum variants +regex-1.4.2/src/prog.rs:18:1: more than 3 bools in a struct regex-1.4.2/src/prog.rs:236:13: using `write!()` with a format string that ends in a single newline +regex-1.4.2/src/prog.rs:300:5: this method could have a `#[must_use]` attribute regex-1.4.2/src/prog.rs:301:9: match expression looks like `matches!` macro +regex-1.4.2/src/prog.rs:382:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/prog.rs:409:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/prog.rs:80:5: this method could have a `#[must_use]` attribute regex-1.4.2/src/prog.rs:80:5: you should consider adding a `Default` implementation for `prog::Program` +regex-1.4.2/src/re_builder.rs:267:17: docs for function returning `Result` missing `# Errors` section +regex-1.4.2/src/re_builder.rs:267:17: docs for function returning `Result` missing `# Errors` section +regex-1.4.2/src/re_builder.rs:4:1: more than 3 bools in a struct +regex-1.4.2/src/re_builder.rs:57:17: this method could have a `#[must_use]` attribute +regex-1.4.2/src/re_builder.rs:57:17: this method could have a `#[must_use]` attribute +regex-1.4.2/src/re_builder.rs:68:17: docs for function returning `Result` missing `# Errors` section +regex-1.4.2/src/re_builder.rs:68:17: docs for function returning `Result` missing `# Errors` section +regex-1.4.2/src/re_bytes.rs:1023:9: called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead +regex-1.4.2/src/re_bytes.rs:1045:9: called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead regex-1.4.2/src/re_bytes.rs:1100:5: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) regex-1.4.2/src/re_bytes.rs:1125:5: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) regex-1.4.2/src/re_bytes.rs:1140:5: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) +regex-1.4.2/src/re_bytes.rs:118:5: docs for function returning `Result` missing `# Errors` section regex-1.4.2/src/re_bytes.rs:257:13: redundant field names in struct initialization +regex-1.4.2/src/re_bytes.rs:29:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/re_bytes.rs:35:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/re_bytes.rs:42:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/re_bytes.rs:48:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/re_bytes.rs:559:29: you should put `shortest_match` between ticks in the documentation regex-1.4.2/src/re_bytes.rs:55:33: redundant field names in struct initialization regex-1.4.2/src/re_bytes.rs:55:47: redundant field names in struct initialization +regex-1.4.2/src/re_bytes.rs:573:29: you should put `is_match` between ticks in the documentation regex-1.4.2/src/re_bytes.rs:721:13: redundant field names in struct initialization +regex-1.4.2/src/re_bytes.rs:818:5: you should put `CaptureLocations` between ticks in the documentation regex-1.4.2/src/re_bytes.rs:844:1: item `re_bytes::CaptureLocations` has a public `len` method but no corresponding `is_empty` method +regex-1.4.2/src/re_bytes.rs:850:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/re_bytes.rs:859:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/re_bytes.rs:870:5: this method could have a `#[must_use]` attribute regex-1.4.2/src/re_bytes.rs:892:1: item `re_bytes::Captures<'t>` has a public `len` method but no corresponding `is_empty` method +regex-1.4.2/src/re_bytes.rs:912:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/re_bytes.rs:918:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/re_bytes.rs:927:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/re_bytes.rs:961:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/re_set.rs:108:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/re_set.rs:108:5: this method could have a `#[must_use]` attribute regex-1.4.2/src/re_set.rs:192:13: redundant field names in struct initialization regex-1.4.2/src/re_set.rs:192:13: redundant field names in struct initialization +regex-1.4.2/src/re_set.rs:269:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/re_set.rs:269:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/re_set.rs:281:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/re_set.rs:281:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/re_set.rs:286:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/re_set.rs:286:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/re_set.rs:295:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/re_set.rs:295:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/re_set.rs:94:5: docs for function returning `Result` missing `# Errors` section +regex-1.4.2/src/re_set.rs:94:5: docs for function returning `Result` missing `# Errors` section regex-1.4.2/src/re_trait.rs:137:29: redundant field names in struct initialization +regex-1.4.2/src/re_unicode.rs:1025:9: called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead +regex-1.4.2/src/re_unicode.rs:1047:9: called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead regex-1.4.2/src/re_unicode.rs:1095:13: redundant field names in struct initialization regex-1.4.2/src/re_unicode.rs:1142:5: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) regex-1.4.2/src/re_unicode.rs:1167:5: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) +regex-1.4.2/src/re_unicode.rs:174:5: docs for function returning `Result` missing `# Errors` section +regex-1.4.2/src/re_unicode.rs:21:1: this function could have a `#[must_use]` attribute regex-1.4.2/src/re_unicode.rs:314:13: redundant field names in struct initialization +regex-1.4.2/src/re_unicode.rs:38:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/re_unicode.rs:44:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/re_unicode.rs:51:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/re_unicode.rs:57:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/re_unicode.rs:618:29: you should put `shortest_match` between ticks in the documentation +regex-1.4.2/src/re_unicode.rs:632:29: you should put `is_match` between ticks in the documentation regex-1.4.2/src/re_unicode.rs:64:33: redundant field names in struct initialization regex-1.4.2/src/re_unicode.rs:64:47: redundant field names in struct initialization +regex-1.4.2/src/re_unicode.rs:835:5: you should put `CaptureLocations` between ticks in the documentation regex-1.4.2/src/re_unicode.rs:861:1: item `re_unicode::CaptureLocations` has a public `len` method but no corresponding `is_empty` method +regex-1.4.2/src/re_unicode.rs:867:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/re_unicode.rs:876:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/re_unicode.rs:887:5: this method could have a `#[must_use]` attribute regex-1.4.2/src/re_unicode.rs:909:1: item `re_unicode::Captures<'t>` has a public `len` method but no corresponding `is_empty` method +regex-1.4.2/src/re_unicode.rs:929:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/re_unicode.rs:935:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/re_unicode.rs:944:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/re_unicode.rs:978:5: this method could have a `#[must_use]` attribute +regex-1.4.2/src/sparse.rs:11:37: you should put bare URLs between `<`/`>` or make a proper Markdown link +regex-1.4.2/src/sparse.rs:16:1: item name starts with its containing module's name regex-1.4.2/src/utf8.rs:100:16: digits of hex or binary literal not grouped by four regex-1.4.2/src/utf8.rs:103:16: digits of hex or binary literal not grouped by four +regex-1.4.2/src/utf8.rs:106:22: casting `u8` to `u32` may become silently lossy if you later change the type +regex-1.4.2/src/utf8.rs:107:19: casting `u8` to `u32` may become silently lossy if you later change the type +regex-1.4.2/src/utf8.rs:108:19: casting `u8` to `u32` may become silently lossy if you later change the type +regex-1.4.2/src/utf8.rs:109:19: casting `u8` to `u32` may become silently lossy if you later change the type +regex-1.4.2/src/utf8.rs:111:27: long literal lacking separators +regex-1.4.2/src/utf8.rs:121:1: item name ends with its containing module's name regex-1.4.2/src/utf8.rs:143:24: digits of hex or binary literal not grouped by four regex-1.4.2/src/utf8.rs:143:9: digits of hex or binary literal not grouped by four +regex-1.4.2/src/utf8.rs:23:1: item name ends with its containing module's name regex-1.4.2/src/utf8.rs:30:20: digits of hex or binary literal not grouped by four +regex-1.4.2/src/utf8.rs:51:1: item name ends with its containing module's name regex-1.4.2/src/utf8.rs:58:23: digits of hex or binary literal not grouped by four regex-1.4.2/src/utf8.rs:58:9: digits of hex or binary literal not grouped by four regex-1.4.2/src/utf8.rs:63:16: digits of hex or binary literal not grouped by four +regex-1.4.2/src/utf8.rs:66:22: casting `u8` to `u32` may become silently lossy if you later change the type +regex-1.4.2/src/utf8.rs:66:54: casting `u8` to `u32` may become silently lossy if you later change the type regex-1.4.2/src/utf8.rs:77:16: digits of hex or binary literal not grouped by four regex-1.4.2/src/utf8.rs:80:16: digits of hex or binary literal not grouped by four +regex-1.4.2/src/utf8.rs:83:22: casting `u8` to `u32` may become silently lossy if you later change the type +regex-1.4.2/src/utf8.rs:84:19: casting `u8` to `u32` may become silently lossy if you later change the type +regex-1.4.2/src/utf8.rs:85:19: casting `u8` to `u32` may become silently lossy if you later change the type regex-1.4.2/src/utf8.rs:92:23: digits of hex or binary literal not grouped by four regex-1.4.2/src/utf8.rs:92:9: digits of hex or binary literal not grouped by four regex-1.4.2/src/utf8.rs:97:16: digits of hex or binary literal not grouped by four -- cgit 1.4.1-3-g733a5 From a9fce6d2d0528c9d8cf6390c3e00a3a6099687ce Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Fri, 18 Dec 2020 22:53:45 +0100 Subject: allow clippy::filter_map --- clippy_dev/src/crater.rs | 3 +++ 1 file changed, 3 insertions(+) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/crater.rs b/clippy_dev/src/crater.rs index eb301159a7b..631499395df 100644 --- a/clippy_dev/src/crater.rs +++ b/clippy_dev/src/crater.rs @@ -1,6 +1,9 @@ +#![allow(clippy::filter_map)] + use crate::clippy_project_root; use std::path::PathBuf; use std::process::Command; + // represents an archive we download from crates.io #[derive(Debug)] struct KrateSource { -- cgit 1.4.1-3-g733a5 From 588efa7da9af41e79f51935efeb9919ccef97f44 Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Tue, 22 Dec 2020 13:07:55 +0100 Subject: use a .toml file to list the crates we want to check Also sort lint results alphabetically. --- clippy_dev/Cargo.toml | 2 + clippy_dev/crater_crates.toml | 20 + clippy_dev/src/crater.rs | 58 +- mini-crater/logs.txt | 2600 ++++++++++++++++++++--------------------- 4 files changed, 1348 insertions(+), 1332 deletions(-) create mode 100644 clippy_dev/crater_crates.toml (limited to 'clippy_dev/src') diff --git a/clippy_dev/Cargo.toml b/clippy_dev/Cargo.toml index 517e9d250bc..6c6941837f1 100644 --- a/clippy_dev/Cargo.toml +++ b/clippy_dev/Cargo.toml @@ -11,8 +11,10 @@ flate2 = "1.0.19" itertools = "0.9" opener = "0.4" regex = "1" +serde = {version = "1.0", features = ["derive"]} shell-escape = "0.1" tar = "0.4.30" +toml = "0.5" ureq = "2.0.0-rc3" walkdir = "2" diff --git a/clippy_dev/crater_crates.toml b/clippy_dev/crater_crates.toml new file mode 100644 index 00000000000..e69056c9925 --- /dev/null +++ b/clippy_dev/crater_crates.toml @@ -0,0 +1,20 @@ +[crates] +# some of these are from cargotest +cargo = '0.49.0' +iron = '0.6.1' +ripgrep = '12.1.1' +xsv = '0.13.0' +#tokei = '12.0.4' +rayon = '1.5.0' +serde = '1.0.118' +# top 10 crates.io dls +bitflags = '1.2.1' +libc = '0.2.81' +log = '0.4.11' +proc-macro2 = '1.0.24' +quote = '1.0.7' +rand = '0.7.3' +rand_core = '0.6.0' +regex = '1.3.2' +syn = '1.0.54' +unicode-xid = '0.2.1' diff --git a/clippy_dev/src/crater.rs b/clippy_dev/src/crater.rs index 631499395df..f64ab897906 100644 --- a/clippy_dev/src/crater.rs +++ b/clippy_dev/src/crater.rs @@ -1,16 +1,24 @@ #![allow(clippy::filter_map)] use crate::clippy_project_root; -use std::path::PathBuf; +use serde::{Deserialize, Serialize}; +use std::collections::HashMap; use std::process::Command; +use std::{fs::write, path::PathBuf}; // represents an archive we download from crates.io -#[derive(Debug)] +#[derive(Debug, Serialize, Deserialize, Eq, Hash, PartialEq)] struct KrateSource { version: String, name: String, } +// use this to store the crates when interacting with the crates.toml file +#[derive(Debug, Serialize, Deserialize)] +struct CrateList { + crates: HashMap, +} + // represents the extracted sourcecode of a crate #[derive(Debug)] struct Krate { @@ -129,33 +137,25 @@ fn build_clippy() { .expect("Failed to build clippy!"); } +// get a list of KrateSources we want to check from a "crater_crates.toml" file. +fn read_crates() -> Vec { + let toml_path = PathBuf::from("clippy_dev/crater_crates.toml"); + let toml_content: String = + std::fs::read_to_string(&toml_path).unwrap_or_else(|_| panic!("Failed to read {}", toml_path.display())); + let crate_list: CrateList = + toml::from_str(&toml_content).unwrap_or_else(|e| panic!("Failed to parse {}: \n{}", toml_path.display(), e)); + // parse the hashmap of the toml file into a list of crates + crate_list + .crates + .iter() + .map(|(name, version)| KrateSource::new(&name, &version)) + .collect() +} + // the main fn pub fn run() { let cargo_clippy_path: PathBuf = PathBuf::from("target/debug/cargo-clippy"); - // crates we want to check: - let krates: Vec = vec![ - // some of these are form cargotest - KrateSource::new("cargo", "0.49.0"), - KrateSource::new("iron", "0.6.1"), - KrateSource::new("ripgrep", "12.1.1"), - //KrateSource::new("tokei", "12.0.4"), - KrateSource::new("xsv", "0.13.0"), - KrateSource::new("serde", "1.0.118"), - KrateSource::new("rayon", "1.5.0"), - // top 10 crates.io dls - KrateSource::new("rand", "0.7.3"), - KrateSource::new("syn", "1.0.54"), - KrateSource::new("libc", "0.2.81"), - KrateSource::new("quote", "1.0.7"), - KrateSource::new("rand_core", "0.6.0"), - KrateSource::new("unicode-xid", "0.2.1"), - KrateSource::new("proc-macro2", "1.0.24"), - KrateSource::new("bitflags", "1.2.1"), - KrateSource::new("log", "0.4.11"), - KrateSource::new("regex", "1.4.2"), - ]; - println!("Compiling clippy..."); build_clippy(); println!("Done compiling"); @@ -168,15 +168,17 @@ pub fn run() { ); // download and extract the crates, then run clippy on them and collect clippys warnings - let clippy_lint_results: Vec> = krates + + let clippy_lint_results: Vec> = read_crates() .into_iter() .map(|krate| krate.download_and_extract()) .map(|krate| krate.run_clippy_lints(&cargo_clippy_path)) .collect(); - let all_warnings: Vec = clippy_lint_results.into_iter().flatten().collect(); + let mut all_warnings: Vec = clippy_lint_results.into_iter().flatten().collect(); + all_warnings.sort(); // save the text into mini-crater/logs.txt let text = all_warnings.join(""); - std::fs::write("mini-crater/logs.txt", text).unwrap(); + write("mini-crater/logs.txt", text).unwrap(); } diff --git a/mini-crater/logs.txt b/mini-crater/logs.txt index 963b1fa38bf..dfa6450def7 100644 --- a/mini-crater/logs.txt +++ b/mini-crater/logs.txt @@ -1441,754 +1441,6 @@ iron-0.6.1/src/response.rs:143:5: use of deprecated macro `try`: use the `?` ope iron-0.6.1/src/response.rs:24:5: docs for function returning `Result` missing `# Errors` section iron-0.6.1/src/response.rs:95:5: this method could have a `#[must_use]` attribute iron-0.6.1/src/response.rs:95:5: you should consider adding a `Default` implementation for `response::Response` -ripgrep-12.1.1/build.rs:133:19: called `.as_ref().map(|x| &**x)` on an Option value. This can be done more directly by calling `githash.as_deref()` instead -ripgrep-12.1.1/build.rs:18:18: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -ripgrep-12.1.1/build.rs:225:14: redundant closure found -ripgrep-12.1.1/build.rs:92:19: called `.as_ref().map(|x| &**x)` on an Option value. This can be done more directly by calling `githash.as_deref()` instead -ripgrep-12.1.1/crates/core/app.rs:1408:5: adding items after statements is confusing, since items exist from the start of the scope -ripgrep-12.1.1/crates/core/app.rs:1408:5: adding items after statements is confusing, since items exist from the start of the scope -ripgrep-12.1.1/crates/core/app.rs:1409:5: adding items after statements is confusing, since items exist from the start of the scope -ripgrep-12.1.1/crates/core/app.rs:1409:5: adding items after statements is confusing, since items exist from the start of the scope -ripgrep-12.1.1/crates/core/app.rs:152:32: you should put `clap::Arg` between ticks in the documentation -ripgrep-12.1.1/crates/core/app.rs:152:32: you should put `clap::Arg` between ticks in the documentation -ripgrep-12.1.1/crates/core/app.rs:156:39: you should put `clap::Arg` between ticks in the documentation -ripgrep-12.1.1/crates/core/app.rs:156:39: you should put `clap::Arg` between ticks in the documentation -ripgrep-12.1.1/crates/core/app.rs:156:5: you should put `RGArg` between ticks in the documentation -ripgrep-12.1.1/crates/core/app.rs:156:5: you should put `RGArg` between ticks in the documentation -ripgrep-12.1.1/crates/core/app.rs:1668:5: adding items after statements is confusing, since items exist from the start of the scope -ripgrep-12.1.1/crates/core/app.rs:1668:5: adding items after statements is confusing, since items exist from the start of the scope -ripgrep-12.1.1/crates/core/app.rs:1669:5: adding items after statements is confusing, since items exist from the start of the scope -ripgrep-12.1.1/crates/core/app.rs:1669:5: adding items after statements is confusing, since items exist from the start of the scope -ripgrep-12.1.1/crates/core/app.rs:1821:5: adding items after statements is confusing, since items exist from the start of the scope -ripgrep-12.1.1/crates/core/app.rs:1821:5: adding items after statements is confusing, since items exist from the start of the scope -ripgrep-12.1.1/crates/core/app.rs:1822:5: adding items after statements is confusing, since items exist from the start of the scope -ripgrep-12.1.1/crates/core/app.rs:1822:5: adding items after statements is confusing, since items exist from the start of the scope -ripgrep-12.1.1/crates/core/app.rs:2999:5: adding items after statements is confusing, since items exist from the start of the scope -ripgrep-12.1.1/crates/core/app.rs:2999:5: adding items after statements is confusing, since items exist from the start of the scope -ripgrep-12.1.1/crates/core/app.rs:3000:5: adding items after statements is confusing, since items exist from the start of the scope -ripgrep-12.1.1/crates/core/app.rs:3000:5: adding items after statements is confusing, since items exist from the start of the scope -ripgrep-12.1.1/crates/core/app.rs:367:54: this `match` has identical arm bodies -ripgrep-12.1.1/crates/core/app.rs:367:54: this `match` has identical arm bodies -ripgrep-12.1.1/crates/core/app.rs:414:59: this `match` has identical arm bodies -ripgrep-12.1.1/crates/core/app.rs:414:59: this `match` has identical arm bodies -ripgrep-12.1.1/crates/core/app.rs:417:57: this `match` has identical arm bodies -ripgrep-12.1.1/crates/core/app.rs:417:57: this `match` has identical arm bodies -ripgrep-12.1.1/crates/core/app.rs:417:57: this `match` has identical arm bodies -ripgrep-12.1.1/crates/core/app.rs:417:57: this `match` has identical arm bodies -ripgrep-12.1.1/crates/core/app.rs:444:41: this `match` has identical arm bodies -ripgrep-12.1.1/crates/core/app.rs:444:41: this `match` has identical arm bodies -ripgrep-12.1.1/crates/core/app.rs:470:41: this `match` has identical arm bodies -ripgrep-12.1.1/crates/core/app.rs:470:41: this `match` has identical arm bodies -ripgrep-12.1.1/crates/core/app.rs:75:9: you should put `RIPGREP_BUILD_GIT_HASH` between ticks in the documentation -ripgrep-12.1.1/crates/core/app.rs:75:9: you should put `RIPGREP_BUILD_GIT_HASH` between ticks in the documentation -ripgrep-12.1.1/crates/core/app.rs:87:5: unnecessary boolean `not` operation -ripgrep-12.1.1/crates/core/app.rs:87:5: unnecessary boolean `not` operation -ripgrep-12.1.1/crates/core/args.rs:1143:22: unused `self` argument -ripgrep-12.1.1/crates/core/args.rs:11:1: this import is redundant -ripgrep-12.1.1/crates/core/args.rs:1209:74: this `if` has identical blocks -ripgrep-12.1.1/crates/core/args.rs:1209:74: this `if` has identical blocks -ripgrep-12.1.1/crates/core/args.rs:1282:13: binding's name is too similar to existing binding -ripgrep-12.1.1/crates/core/args.rs:1430:22: unused `self` argument -ripgrep-12.1.1/crates/core/args.rs:1438:21: you should put `OsStr` between ticks in the documentation -ripgrep-12.1.1/crates/core/args.rs:1520:44: redundant closure found -ripgrep-12.1.1/crates/core/args.rs:1524:5: this function's return value is unnecessarily wrapped by `Result` -ripgrep-12.1.1/crates/core/args.rs:1635:14: you should put `values_of_lossy` between ticks in the documentation -ripgrep-12.1.1/crates/core/args.rs:1693:41: redundant closure found -ripgrep-12.1.1/crates/core/args.rs:1770:17: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers -ripgrep-12.1.1/crates/core/args.rs:287:13: binding's name is too similar to existing binding -ripgrep-12.1.1/crates/core/args.rs:33:1: this import is redundant -ripgrep-12.1.1/crates/core/args.rs:34:1: this import is redundant -ripgrep-12.1.1/crates/core/args.rs:35:1: this import is redundant -ripgrep-12.1.1/crates/core/args.rs:410:14: this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -ripgrep-12.1.1/crates/core/args.rs:475:18: this `match` has identical arm bodies -ripgrep-12.1.1/crates/core/args.rs:512:19: you should put `ArgMatches` between ticks in the documentation -ripgrep-12.1.1/crates/core/args.rs:549:16: methods called `to_*` usually take self by reference; consider choosing a less ambiguous name -ripgrep-12.1.1/crates/core/args.rs:76:18: this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -ripgrep-12.1.1/crates/core/args.rs:77:13: usage of wildcard import for enum variants -ripgrep-12.1.1/crates/core/args.rs:923:42: you should put `BinaryDetection::quit` between ticks in the documentation -ripgrep-12.1.1/crates/core/config.rs:13:1: this import is redundant -ripgrep-12.1.1/crates/core/config.rs:58:6: very complex type used. Consider factoring parts into `type` definitions -ripgrep-12.1.1/crates/core/config.rs:79:6: very complex type used. Consider factoring parts into `type` definitions -ripgrep-12.1.1/crates/core/logger.rs:11:30: you should put `max_level` between ticks in the documentation -ripgrep-12.1.1/crates/core/logger.rs:15:16: constants have by default a `'static` lifetime -ripgrep-12.1.1/crates/core/main.rs:55:19: this argument is passed by value, but not consumed in the function body -ripgrep-12.1.1/crates/core/main.rs:56:9: usage of wildcard import for enum variants -ripgrep-12.1.1/crates/core/messages.rs:46:1: item name ends with its containing module's name -ripgrep-12.1.1/crates/core/messages.rs:51:1: item name ends with its containing module's name -ripgrep-12.1.1/crates/core/messages.rs:62:1: item name ends with its containing module's name -ripgrep-12.1.1/crates/core/path_printer.rs:27:1: item name starts with its containing module's name -ripgrep-12.1.1/crates/core/path_printer.rs:89:9: unnecessary boolean `not` operation -ripgrep-12.1.1/crates/core/search.rs:185:1: item name starts with its containing module's name -ripgrep-12.1.1/crates/core/search.rs:292:9: using `write!()` with a format string that ends in a single newline -ripgrep-12.1.1/crates/core/search.rs:311:1: item name starts with its containing module's name -ripgrep-12.1.1/crates/core/search.rs:377:12: this boolean expression can be simplified -ripgrep-12.1.1/crates/core/search.rs:423:13: usage of wildcard import for enum variants -ripgrep-12.1.1/crates/core/search.rs:447:13: usage of wildcard import for enum variants -ripgrep-12.1.1/crates/core/search.rs:472:24: you are using an explicit closure for cloning elements -ripgrep-12.1.1/crates/core/search.rs:472:41: redundant closure found -ripgrep-12.1.1/crates/core/search.rs:480:24: you are using an explicit closure for cloning elements -ripgrep-12.1.1/crates/core/search.rs:480:41: redundant closure found -ripgrep-12.1.1/crates/core/search.rs:49:1: item name starts with its containing module's name -ripgrep-12.1.1/crates/core/search.rs:509:24: you are using an explicit closure for cloning elements -ripgrep-12.1.1/crates/core/search.rs:509:41: redundant closure found -ripgrep-12.1.1/crates/core/search.rs:517:24: you are using an explicit closure for cloning elements -ripgrep-12.1.1/crates/core/search.rs:517:41: redundant closure found -ripgrep-12.1.1/crates/core/search.rs:533:36: casting `u32` to `f64` may become silently lossy if you later change the type -ripgrep-12.1.1/crates/core/search.rs:533:5: casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -ripgrep-12.1.1/crates/core/subject.rs:20:1: item name starts with its containing module's name -ripgrep-12.1.1/crates/core/subject.rs:4:1: this import is redundant -xsv-0.13.0/src/cmd/cat.rs:101:34: redundant closure found -xsv-0.13.0/src/cmd/cat.rs:42:1: more than 3 bools in a struct -xsv-0.13.0/src/cmd/cat.rs:53:9: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/cat.rs:7:16: statics have by default a `'static` lifetime -xsv-0.13.0/src/cmd/count.rs:32:9: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/count.rs:38:9: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -xsv-0.13.0/src/cmd/count.rs:42:33: integer type suffix should be separated by an underscore -xsv-0.13.0/src/cmd/count.rs:50:5: passing a unit value to a function -xsv-0.13.0/src/cmd/count.rs:7:16: statics have by default a `'static` lifetime -xsv-0.13.0/src/cmd/fixlengths.rs:45:9: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/fixlengths.rs:50:18: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -xsv-0.13.0/src/cmd/fixlengths.rs:62:30: integer type suffix should be separated by an underscore -xsv-0.13.0/src/cmd/fixlengths.rs:9:16: statics have by default a `'static` lifetime -xsv-0.13.0/src/cmd/flatten.rs:10:16: statics have by default a `'static` lifetime -xsv-0.13.0/src/cmd/flatten.rs:51:9: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/fmt.rs:50:9: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/fmt.rs:55:13: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/fmt.rs:7:16: statics have by default a `'static` lifetime -xsv-0.13.0/src/cmd/frequency.rs:148:43: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers -xsv-0.13.0/src/cmd/frequency.rs:149:43: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers -xsv-0.13.0/src/cmd/frequency.rs:15:16: statics have by default a `'static` lifetime -xsv-0.13.0/src/cmd/frequency.rs:169:13: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/frequency.rs:176:17: unnecessary boolean `not` operation -xsv-0.13.0/src/cmd/frequency.rs:178:24: this `else { if .. }` block can be collapsed -xsv-0.13.0/src/cmd/frequency.rs:77:9: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/frequency.rs:93:31: it is more concise to loop over containers instead of using explicit iteration methods -xsv-0.13.0/src/cmd/headers.rs:43:9: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/headers.rs:49:17: it is more concise to loop over containers instead of using explicit iteration methods -xsv-0.13.0/src/cmd/headers.rs:60:22: trait objects without an explicit `dyn` are deprecated -xsv-0.13.0/src/cmd/headers.rs:9:16: statics have by default a `'static` lifetime -xsv-0.13.0/src/cmd/index.rs:11:16: statics have by default a `'static` lifetime -xsv-0.13.0/src/cmd/index.rs:45:9: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/input.rs:42:9: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/input.rs:47:9: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/input.rs:7:16: statics have by default a `'static` lifetime -xsv-0.13.0/src/cmd/join.rs:17:16: statics have by default a `'static` lifetime -xsv-0.13.0/src/cmd/join.rs:194:29: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/join.rs:224:22: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/join.rs:281:44: trait objects without an explicit `dyn` are deprecated -xsv-0.13.0/src/cmd/join.rs:293:14: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/join.rs:293:20: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/join.rs:297:13: redundant field names in struct initialization -xsv-0.13.0/src/cmd/join.rs:298:13: redundant field names in struct initialization -xsv-0.13.0/src/cmd/join.rs:299:13: redundant field names in struct initialization -xsv-0.13.0/src/cmd/join.rs:300:13: redundant field names in struct initialization -xsv-0.13.0/src/cmd/join.rs:308:9: unused `self` argument -xsv-0.13.0/src/cmd/join.rs:342:38: integer type suffix should be separated by an underscore -xsv-0.13.0/src/cmd/join.rs:342:46: integer type suffix should be separated by an underscore -xsv-0.13.0/src/cmd/join.rs:347:9: unnecessary boolean `not` operation -xsv-0.13.0/src/cmd/join.rs:372:44: redundant closure found -xsv-0.13.0/src/cmd/join.rs:375:33: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/join.rs:392:13: redundant field names in struct initialization -xsv-0.13.0/src/cmd/join.rs:403:29: it is more concise to loop over containers instead of using explicit iteration methods -xsv-0.13.0/src/cmd/join.rs:426:13: unnecessary boolean `not` operation -xsv-0.13.0/src/cmd/join.rs:77:1: more than 3 bools in a struct -xsv-0.13.0/src/cmd/join.rs:94:9: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/partition.rs:105:22: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/partition.rs:126:36: trait objects without an explicit `dyn` are deprecated -xsv-0.13.0/src/cmd/partition.rs:139:13: redundant field names in struct initialization -xsv-0.13.0/src/cmd/partition.rs:15:16: statics have by default a `'static` lifetime -xsv-0.13.0/src/cmd/partition.rs:169:9: unnecessary boolean `not` operation -xsv-0.13.0/src/cmd/partition.rs:56:9: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/partition.rs:77:9: unused `self` argument -xsv-0.13.0/src/cmd/sample.rs:105:44: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers -xsv-0.13.0/src/cmd/sample.rs:115:21: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers -xsv-0.13.0/src/cmd/sample.rs:11:16: statics have by default a `'static` lifetime -xsv-0.13.0/src/cmd/sample.rs:51:9: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/sample.rs:58:19: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -xsv-0.13.0/src/cmd/sample.rs:69:9: wildcard match will miss any future added variants -xsv-0.13.0/src/cmd/sample.rs:75:16: it is more concise to loop over containers instead of using explicit iteration methods -xsv-0.13.0/src/cmd/sample.rs:91:42: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers -xsv-0.13.0/src/cmd/sample.rs:92:43: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers -xsv-0.13.0/src/cmd/search.rs:51:9: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/search.rs:9:16: statics have by default a `'static` lifetime -xsv-0.13.0/src/cmd/select.rs:60:9: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/select.rs:8:16: statics have by default a `'static` lifetime -xsv-0.13.0/src/cmd/slice.rs:57:9: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/slice.rs:9:16: statics have by default a `'static` lifetime -xsv-0.13.0/src/cmd/sort.rs:11:16: statics have by default a `'static` lifetime -xsv-0.13.0/src/cmd/sort.rs:138:47: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -xsv-0.13.0/src/cmd/sort.rs:139:51: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -xsv-0.13.0/src/cmd/sort.rs:48:9: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/sort.rs:91:14: it is more concise to loop over containers instead of using explicit iteration methods -xsv-0.13.0/src/cmd/split.rs:131:36: trait objects without an explicit `dyn` are deprecated -xsv-0.13.0/src/cmd/split.rs:14:16: statics have by default a `'static` lifetime -xsv-0.13.0/src/cmd/split.rs:61:9: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/split.rs:94:5: this function's return value is unnecessarily wrapped by `Result` -xsv-0.13.0/src/cmd/split.rs:96:14: this argument is passed by value, but not consumed in the function body -xsv-0.13.0/src/cmd/split.rs:99:13: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers -xsv-0.13.0/src/cmd/stats.rs:110:36: redundant closure found -xsv-0.13.0/src/cmd/stats.rs:127:14: this argument is passed by value, but not consumed in the function body -xsv-0.13.0/src/cmd/stats.rs:138:43: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers -xsv-0.13.0/src/cmd/stats.rs:139:43: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers -xsv-0.13.0/src/cmd/stats.rs:162:25: it is more concise to loop over containers instead of using explicit iteration methods -xsv-0.13.0/src/cmd/stats.rs:22:16: statics have by default a `'static` lifetime -xsv-0.13.0/src/cmd/stats.rs:231:1: more than 3 bools in a struct -xsv-0.13.0/src/cmd/stats.rs:262:35: calling `cmd::stats::TypedSum::default()` is more clear than this expression -xsv-0.13.0/src/cmd/stats.rs:263:40: calling `cmd::stats::TypedMinMax::default()` is more clear than this expression -xsv-0.13.0/src/cmd/stats.rs:264:39: calling `stats::OnlineStats::default()` is more clear than this expression -xsv-0.13.0/src/cmd/stats.rs:265:58: calling `stats::Unsorted::default()` is more clear than this expression -xsv-0.13.0/src/cmd/stats.rs:266:41: calling `stats::Unsorted::default()` is more clear than this expression -xsv-0.13.0/src/cmd/stats.rs:268:18: calling `cmd::stats::FieldType::default()` is more clear than this expression -xsv-0.13.0/src/cmd/stats.rs:269:13: redundant field names in struct initialization -xsv-0.13.0/src/cmd/stats.rs:270:13: redundant field names in struct initialization -xsv-0.13.0/src/cmd/stats.rs:271:13: redundant field names in struct initialization -xsv-0.13.0/src/cmd/stats.rs:272:13: redundant field names in struct initialization -xsv-0.13.0/src/cmd/stats.rs:273:13: redundant field names in struct initialization -xsv-0.13.0/src/cmd/stats.rs:274:13: redundant field names in struct initialization -xsv-0.13.0/src/cmd/stats.rs:283:9: called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()` -xsv-0.13.0/src/cmd/stats.rs:284:9: called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()` -xsv-0.13.0/src/cmd/stats.rs:285:9: called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()` -xsv-0.13.0/src/cmd/stats.rs:290:21: called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()` -xsv-0.13.0/src/cmd/stats.rs:293:25: this `match` has identical arm bodies -xsv-0.13.0/src/cmd/stats.rs:297:25: called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()` -xsv-0.13.0/src/cmd/stats.rs:301:21: called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()` -xsv-0.13.0/src/cmd/stats.rs:302:21: called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()` -xsv-0.13.0/src/cmd/stats.rs:308:18: methods called `to_*` usually take self by reference; consider choosing a less ambiguous name -xsv-0.13.0/src/cmd/stats.rs:318:9: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -xsv-0.13.0/src/cmd/stats.rs:322:45: redundant closure found -xsv-0.13.0/src/cmd/stats.rs:322:9: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -xsv-0.13.0/src/cmd/stats.rs:327:9: unnecessary boolean `not` operation -xsv-0.13.0/src/cmd/stats.rs:330:13: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -xsv-0.13.0/src/cmd/stats.rs:338:45: redundant closure found -xsv-0.13.0/src/cmd/stats.rs:402:16: redundant pattern matching, consider using `is_ok()` -xsv-0.13.0/src/cmd/stats.rs:403:16: redundant pattern matching, consider using `is_ok()` -xsv-0.13.0/src/cmd/stats.rs:407:18: this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -xsv-0.13.0/src/cmd/stats.rs:411:16: this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -xsv-0.13.0/src/cmd/stats.rs:427:56: this `match` has identical arm bodies -xsv-0.13.0/src/cmd/stats.rs:429:56: this `match` has identical arm bodies -xsv-0.13.0/src/cmd/stats.rs:430:60: this `match` has identical arm bodies -xsv-0.13.0/src/cmd/stats.rs:430:60: this `match` has identical arm bodies -xsv-0.13.0/src/cmd/stats.rs:454:5: you should put `TypedSum` between ticks in the documentation -xsv-0.13.0/src/cmd/stats.rs:473:43: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -xsv-0.13.0/src/cmd/stats.rs:504:56: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -xsv-0.13.0/src/cmd/stats.rs:505:51: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -xsv-0.13.0/src/cmd/stats.rs:511:5: you should put `TypedMinMax` between ticks in the documentation -xsv-0.13.0/src/cmd/stats.rs:536:35: casting `f64` to `i64` may truncate the value -xsv-0.13.0/src/cmd/stats.rs:544:33: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -xsv-0.13.0/src/cmd/stats.rs:592:22: calling `stats::MinMax::default()` is more clear than this expression -xsv-0.13.0/src/cmd/stats.rs:593:22: calling `stats::MinMax::default()` is more clear than this expression -xsv-0.13.0/src/cmd/stats.rs:594:23: calling `stats::MinMax::default()` is more clear than this expression -xsv-0.13.0/src/cmd/stats.rs:595:21: calling `stats::MinMax::default()` is more clear than this expression -xsv-0.13.0/src/cmd/stats.rs:71:1: more than 3 bools in a struct -xsv-0.13.0/src/cmd/stats.rs:86:9: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/table.rs:10:16: statics have by default a `'static` lifetime -xsv-0.13.0/src/cmd/table.rs:50:9: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/table.rs:54:9: binding's name is too similar to existing binding -xsv-0.13.0/src/config.rs:113:43: use of `unwrap_or` followed by a function call -xsv-0.13.0/src/config.rs:197:48: trait objects without an explicit `dyn` are deprecated -xsv-0.13.0/src/config.rs:202:48: trait objects without an explicit `dyn` are deprecated -xsv-0.13.0/src/config.rs:263:47: trait objects without an explicit `dyn` are deprecated -xsv-0.13.0/src/config.rs:293:47: trait objects without an explicit `dyn` are deprecated -xsv-0.13.0/src/config.rs:58:1: more than 3 bools in a struct -xsv-0.13.0/src/config.rs:77:28: explicit deref method call -xsv-0.13.0/src/config.rs:90:13: redundant field names in struct initialization -xsv-0.13.0/src/index.rs:31:13: redundant field names in struct initialization -xsv-0.13.0/src/main.rs:164:49: redundant clone -xsv-0.13.0/src/main.rs:75:16: statics have by default a `'static` lifetime -xsv-0.13.0/src/select.rs:13:1: item name starts with its containing module's name -xsv-0.13.0/src/select.rs:154:5: this function's return value is unnecessarily wrapped by `Result` -xsv-0.13.0/src/select.rs:250:33: binding's name is too similar to existing binding -xsv-0.13.0/src/select.rs:250:43: binding's name is too similar to existing binding -xsv-0.13.0/src/select.rs:255:39: an inclusive range would be more readable -xsv-0.13.0/src/select.rs:280:20: length comparison to zero -xsv-0.13.0/src/select.rs:29:13: redundant field names in struct initialization -xsv-0.13.0/src/select.rs:360:62: this argument (8 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -xsv-0.13.0/src/select.rs:360:9: this function's return value is unnecessarily wrapped by `Option` -xsv-0.13.0/src/select.rs:375:9: used sort instead of sort_unstable to sort primitive type `usize` -xsv-0.13.0/src/select.rs:379:18: it is more concise to loop over containers instead of using explicit iteration methods -xsv-0.13.0/src/select.rs:416:5: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) -xsv-0.13.0/src/select.rs:419:9: this function's return value is unnecessarily wrapped by `Option` -xsv-0.13.0/src/select.rs:420:27: consider using `Option` instead of `Option>` or a custom enum if you need to distinguish all 3 cases -xsv-0.13.0/src/select.rs:99:17: binding's name is too similar to existing binding -xsv-0.13.0/src/util.rs:150:5: you should put bare URLs between `<`/`>` or make a proper Markdown link -xsv-0.13.0/src/util.rs:190:48: trait objects without an explicit `dyn` are deprecated -xsv-0.13.0/src/util.rs:37:33: you are using an explicit closure for copying elements -xsv-0.13.0/src/util.rs:90:1: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) -rayon-1.5.0/src/collections/binary_heap.rs:7:5: usage of wildcard import -rayon-1.5.0/src/collections/binary_heap.rs:8:5: usage of wildcard import -rayon-1.5.0/src/collections/btree_map.rs:7:5: usage of wildcard import -rayon-1.5.0/src/collections/btree_map.rs:8:5: usage of wildcard import -rayon-1.5.0/src/collections/btree_set.rs:7:5: usage of wildcard import -rayon-1.5.0/src/collections/btree_set.rs:8:5: usage of wildcard import -rayon-1.5.0/src/collections/hash_map.rs:10:5: usage of wildcard import -rayon-1.5.0/src/collections/hash_map.rs:9:5: usage of wildcard import -rayon-1.5.0/src/collections/hash_set.rs:10:5: usage of wildcard import -rayon-1.5.0/src/collections/hash_set.rs:9:5: usage of wildcard import -rayon-1.5.0/src/collections/linked_list.rs:7:5: usage of wildcard import -rayon-1.5.0/src/collections/linked_list.rs:8:5: usage of wildcard import -rayon-1.5.0/src/collections/mod.rs:59:32: replacing a value of type `T` with `T::default()` is better expressed using `std::mem::take` -rayon-1.5.0/src/collections/vec_deque.rs:8:5: usage of wildcard import -rayon-1.5.0/src/collections/vec_deque.rs:9:5: usage of wildcard import -rayon-1.5.0/src/compile_fail/cannot_collect_filtermap_data.rs:2:1: needless `fn main` in doctest -rayon-1.5.0/src/compile_fail/cannot_zip_filtered_data.rs:2:1: needless `fn main` in doctest -rayon-1.5.0/src/compile_fail/cell_par_iter.rs:2:1: needless `fn main` in doctest -rayon-1.5.0/src/compile_fail/no_send_par_iter.rs:25:1: needless `fn main` in doctest -rayon-1.5.0/src/compile_fail/no_send_par_iter.rs:46:1: needless `fn main` in doctest -rayon-1.5.0/src/compile_fail/no_send_par_iter.rs:4:1: needless `fn main` in doctest -rayon-1.5.0/src/compile_fail/rc_par_iter.rs:2:1: needless `fn main` in doctest -rayon-1.5.0/src/iter/chain.rs:103:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/chain.rs:122:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/chain.rs:128:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/chain.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/chain.rs:221:36: you should put `ExactSizeIterator` between ticks in the documentation -rayon-1.5.0/src/iter/chain.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/chain.rs:51:38: use Option::map_or_else instead of an if let/else -rayon-1.5.0/src/iter/chain.rs:58:14: `a` is being shadowed -rayon-1.5.0/src/iter/chain.rs:58:17: `b` is being shadowed -rayon-1.5.0/src/iter/chain.rs:78:14: `a` is being shadowed -rayon-1.5.0/src/iter/chain.rs:78:17: `b` is being shadowed -rayon-1.5.0/src/iter/chain.rs:97:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/chunks.rs:3:5: usage of wildcard import -rayon-1.5.0/src/iter/chunks.rs:4:5: usage of wildcard import -rayon-1.5.0/src/iter/chunks.rs:77:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/chunks.rs:83:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/cloned.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/cloned.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/cloned.rs:71:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/cloned.rs:75:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/collect/consumer.rs:141:5: you should put `CollectReducer` between ticks in the documentation -rayon-1.5.0/src/iter/collect/consumer.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/collect/consumer.rs:28:5: you should put `CollectResult` between ticks in the documentation -rayon-1.5.0/src/iter/collect/consumer.rs:36:37: generally you want to avoid `&mut &mut _` if possible -rayon-1.5.0/src/iter/collect/consumer.rs:36:37: generally you want to avoid `&mut &mut _` if possible -rayon-1.5.0/src/iter/collect/mod.rs:154:9: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -rayon-1.5.0/src/iter/copied.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/copied.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/copied.rs:71:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/copied.rs:75:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/empty.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/empty.rs:24:1: this function could have a `#[must_use]` attribute -rayon-1.5.0/src/iter/empty.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/enumerate.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/enumerate.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/enumerate.rs:64:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/enumerate.rs:68:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/extend.rs:143:63: I see you're using a LinkedList! Perhaps you meant some other data structure? -rayon-1.5.0/src/iter/extend.rs:182:57: I see you're using a LinkedList! Perhaps you meant some other data structure? -rayon-1.5.0/src/iter/extend.rs:218:32: I see you're using a LinkedList! Perhaps you meant some other data structure? -rayon-1.5.0/src/iter/extend.rs:218:59: I see you're using a LinkedList! Perhaps you meant some other data structure? -rayon-1.5.0/src/iter/extend.rs:25:42: I see you're using a LinkedList! Perhaps you meant some other data structure? -rayon-1.5.0/src/iter/extend.rs:287:62: I see you're using a LinkedList! Perhaps you meant some other data structure? -rayon-1.5.0/src/iter/extend.rs:322:56: I see you're using a LinkedList! Perhaps you meant some other data structure? -rayon-1.5.0/src/iter/extend.rs:41:27: I see you're using a LinkedList! Perhaps you meant some other data structure? -rayon-1.5.0/src/iter/extend.rs:47:30: I see you're using a LinkedList! Perhaps you meant some other data structure? -rayon-1.5.0/src/iter/extend.rs:47:56: I see you're using a LinkedList! Perhaps you meant some other data structure? -rayon-1.5.0/src/iter/extend.rs:47:74: I see you're using a LinkedList! Perhaps you meant some other data structure? -rayon-1.5.0/src/iter/extend.rs:53:29: I see you're using a LinkedList! Perhaps you meant some other data structure? -rayon-1.5.0/src/iter/extend.rs:57:36: I see you're using a LinkedList! Perhaps you meant some other data structure? -rayon-1.5.0/src/iter/extend.rs:59:61: I see you're using a LinkedList! Perhaps you meant some other data structure? -rayon-1.5.0/src/iter/filter.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/filter.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/filter_map.rs:123:9: use Option::map_or instead of an if let/else -rayon-1.5.0/src/iter/filter_map.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/filter_map.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/find.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/find.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/find_first_last/mod.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/find_first_last/mod.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/find_first_last/mod.rs:32:67: you should put `MatchPosition` between ticks in the documentation -rayon-1.5.0/src/iter/flat_map.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/flat_map.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/flat_map_iter.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/flat_map_iter.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/flatten.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/flatten.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/flatten_iter.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/flatten_iter.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/fold.rs:158:13: binding's name is too similar to existing binding -rayon-1.5.0/src/iter/fold.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/fold.rs:204:1: item name starts with its containing module's name -rayon-1.5.0/src/iter/fold.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/for_each.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/for_each.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/inspect.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/inspect.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/inspect.rs:83:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/inspect.rs:88:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/interleave.rs:111:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/interleave.rs:119:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/interleave.rs:195:30: you should put `self.i_len` between ticks in the documentation -rayon-1.5.0/src/iter/interleave.rs:195:43: you should put `self.j_len` between ticks in the documentation -rayon-1.5.0/src/iter/interleave.rs:199:23: you should put `self.i_len` between ticks in the documentation -rayon-1.5.0/src/iter/interleave.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/interleave.rs:200:23: you should put `self.j_len` between ticks in the documentation -rayon-1.5.0/src/iter/interleave.rs:249:41: you should put `DoubleEndedIterator` between ticks in the documentation -rayon-1.5.0/src/iter/interleave.rs:250:5: you should put `ExactSizeIterator` between ticks in the documentation -rayon-1.5.0/src/iter/interleave.rs:263:33: you should put `InterleaveSeq` between ticks in the documentation -rayon-1.5.0/src/iter/interleave.rs:280:17: wildcard match will miss any future added variants -rayon-1.5.0/src/iter/interleave.rs:285:17: wildcard match will miss any future added variants -rayon-1.5.0/src/iter/interleave.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/interleave.rs:313:9: `if` chain can be rewritten with `match` -rayon-1.5.0/src/iter/interleave.rs:82:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/interleave.rs:90:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/interleave_shortest.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/intersperse.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/intersperse.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/intersperse.rs:90:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/intersperse.rs:96:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/len.rs:12:1: item name ends with its containing module's name -rayon-1.5.0/src/iter/len.rs:146:1: item name ends with its containing module's name -rayon-1.5.0/src/iter/len.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/len.rs:200:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/len.rs:205:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/len.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/len.rs:66:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/len.rs:71:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/map.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/map.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/map.rs:84:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/map.rs:89:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/map_with.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/map_with.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/map_with.rs:419:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/map_with.rs:425:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/map_with.rs:90:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/map_with.rs:96:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/mod.rs:1874:24: this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -rayon-1.5.0/src/iter/mod.rs:2171:1: trait `IndexedParallelIterator` has a `len` method but no (possibly inherited) `is_empty` method -rayon-1.5.0/src/iter/mod.rs:2371:26: this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -rayon-1.5.0/src/iter/mod.rs:2411:26: this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -rayon-1.5.0/src/iter/mod.rs:82:5: usage of wildcard import -rayon-1.5.0/src/iter/multizip.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/multizip.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/noop.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/once.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/once.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/panic_fuse.rs:102:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/panic_fuse.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/panic_fuse.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/panic_fuse.rs:98:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/par_bridge.rs:136:28: redundant else block -rayon-1.5.0/src/iter/par_bridge.rs:163:28: redundant else block -rayon-1.5.0/src/iter/plumbing/mod.rs:216:58: you should put `find_first` between ticks in the documentation -rayon-1.5.0/src/iter/plumbing/mod.rs:359:5: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/plumbing/mod.rs:364:5: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/plumbing/mod.rs:399:5: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/plumbing/mod.rs:53:19: you should put `DoubleEndedIterator` between ticks in the documentation -rayon-1.5.0/src/iter/plumbing/mod.rs:53:43: you should put `ExactSizeIterator` between ticks in the documentation -rayon-1.5.0/src/iter/plumbing/mod.rs:54:31: you should put `IntoIterator` between ticks in the documentation -rayon-1.5.0/src/iter/plumbing/mod.rs:55:5: you should put `IntoIterator` between ticks in the documentation -rayon-1.5.0/src/iter/positions.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/positions.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/product.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/reduce.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/repeat.rs:103:1: item name starts with its containing module's name -rayon-1.5.0/src/iter/repeat.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/repeat.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/rev.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/rev.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/rev.rs:63:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/rev.rs:68:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/skip.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/skip.rs:3:5: usage of wildcard import -rayon-1.5.0/src/iter/skip.rs:68:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/skip.rs:73:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/splitter.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/splitter.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/step_by.rs:4:5: usage of wildcard import -rayon-1.5.0/src/iter/step_by.rs:5:5: usage of wildcard import -rayon-1.5.0/src/iter/step_by.rs:73:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/step_by.rs:79:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/sum.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/take.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/take.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/take.rs:67:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/take.rs:72:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/try_fold.rs:190:1: item name starts with its containing module's name -rayon-1.5.0/src/iter/try_fold.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/try_fold.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/try_reduce.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/try_reduce_with.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/unzip.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/unzip.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/update.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/update.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/update.rs:82:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/update.rs:87:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/while_some.rs:130:22: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -rayon-1.5.0/src/iter/while_some.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/while_some.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/zip.rs:102:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/zip.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/zip.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/zip.rs:74:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/zip.rs:79:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/zip.rs:97:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/zip_eq.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/zip_eq.rs:2:5: usage of wildcard import -rayon-1.5.0/src/option.rs:8:5: usage of wildcard import -rayon-1.5.0/src/option.rs:9:5: usage of wildcard import -rayon-1.5.0/src/par_either.rs:1:5: usage of wildcard import -rayon-1.5.0/src/par_either.rs:3:5: usage of wildcard import -rayon-1.5.0/src/private.rs:9:1: item name starts with its containing module's name -rayon-1.5.0/src/range.rs:19:5: usage of wildcard import -rayon-1.5.0/src/range.rs:20:5: usage of wildcard import -rayon-1.5.0/src/range_inclusive.rs:194:9: an inclusive range would be more readable -rayon-1.5.0/src/range_inclusive.rs:194:9: an inclusive range would be more readable -rayon-1.5.0/src/range_inclusive.rs:19:5: usage of wildcard import -rayon-1.5.0/src/range_inclusive.rs:209:9: an inclusive range would be more readable -rayon-1.5.0/src/range_inclusive.rs:209:9: an inclusive range would be more readable -rayon-1.5.0/src/range_inclusive.rs:20:5: usage of wildcard import -rayon-1.5.0/src/range_inclusive.rs:231:9: an inclusive range would be more readable -rayon-1.5.0/src/range_inclusive.rs:231:9: an inclusive range would be more readable -rayon-1.5.0/src/result.rs:8:5: usage of wildcard import -rayon-1.5.0/src/result.rs:9:5: usage of wildcard import -rayon-1.5.0/src/slice/mergesort.rs:102:5: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/slice/mergesort.rs:109:5: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/slice/mergesort.rs:114:5: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/slice/mergesort.rs:211:5: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/slice/mergesort.rs:217:5: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/slice/mergesort.rs:251:5: you should put `TimSort` between ticks in the documentation -rayon-1.5.0/src/slice/mergesort.rs:252:5: you should put bare URLs between `<`/`>` or make a proper Markdown link -rayon-1.5.0/src/slice/mergesort.rs:286:59: you should put `TimSort` between ticks in the documentation -rayon-1.5.0/src/slice/mergesort.rs:333:24: redundant else block -rayon-1.5.0/src/slice/mergesort.rs:513:5: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/slice/mergesort.rs:521:5: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/slice/mergesort.rs:7:5: usage of wildcard import -rayon-1.5.0/src/slice/mergesort.rs:98:5: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/slice/mod.rs:15:5: usage of wildcard import -rayon-1.5.0/src/slice/mod.rs:16:5: usage of wildcard import -rayon-1.5.0/src/slice/mod.rs:17:5: usage of wildcard import -rayon-1.5.0/src/slice/mod.rs:25:1: item name ends with its containing module's name -rayon-1.5.0/src/slice/mod.rs:657:5: this method could have a `#[must_use]` attribute -rayon-1.5.0/src/slice/mod.rs:971:5: this method could have a `#[must_use]` attribute -rayon-1.5.0/src/slice/quicksort.rs:230:36: you should put `BlockQuicksort` between ticks in the documentation -rayon-1.5.0/src/slice/quicksort.rs:233:1: this function has too many lines (117/100) -rayon-1.5.0/src/slice/quicksort.rs:258:26: integer type suffix should be separated by an underscore -rayon-1.5.0/src/slice/quicksort.rs:265:26: integer type suffix should be separated by an underscore -rayon-1.5.0/src/slice/quicksort.rs:268:5: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/slice/quicksort.rs:308:30: casting `usize` to `u8` may truncate the value -rayon-1.5.0/src/slice/quicksort.rs:325:30: casting `usize` to `u8` may truncate the value -rayon-1.5.0/src/slice/quicksort.rs:393:36: casting `u8` to `isize` may wrap around the value on targets with 32-bit wide pointers -rayon-1.5.0/src/slice/quicksort.rs:405:40: casting `u8` to `isize` may wrap around the value on targets with 32-bit wide pointers -rayon-1.5.0/src/slice/quicksort.rs:430:14: `pivot` is being shadowed -rayon-1.5.0/src/slice/quicksort.rs:439:13: `pivot` is being shadowed -rayon-1.5.0/src/slice/quicksort.rs:482:10: `pivot` is being shadowed -rayon-1.5.0/src/slice/quicksort.rs:491:9: `pivot` is being shadowed -rayon-1.5.0/src/slice/quicksort.rs:534:26: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -rayon-1.5.0/src/slice/quicksort.rs:545:17: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers -rayon-1.5.0/src/slice/quicksort.rs:588:17: the operation is ineffective. Consider reducing it to `len / 4` -rayon-1.5.0/src/slice/quicksort.rs:716:14: `pivot` is being shadowed -rayon-1.5.0/src/split_producer.rs:56:16: use Option::map_or_else instead of an if let/else -rayon-1.5.0/src/split_producer.rs:92:9: use Option::map_or instead of an if let/else -rayon-1.5.0/src/str.rs:16:5: usage of wildcard import -rayon-1.5.0/src/str.rs:17:5: usage of wildcard import -rayon-1.5.0/src/str.rs:18:5: usage of wildcard import -rayon-1.5.0/src/str.rs:25:5: casting `u8` to `i8` may wrap around the value -rayon-1.5.0/src/str.rs:715:9: stripping a suffix manually -rayon-1.5.0/src/string.rs:5:5: usage of wildcard import -rayon-1.5.0/src/vec.rs:137:12: length comparison to zero -rayon-1.5.0/src/vec.rs:8:5: usage of wildcard import -rayon-1.5.0/src/vec.rs:9:5: usage of wildcard import -rand-0.7.3/src/distributions/bernoulli.rs:103:20: casting `f64` to `u64` may lose the sign of the value -rand-0.7.3/src/distributions/bernoulli.rs:103:20: casting `f64` to `u64` may truncate the value -rand-0.7.3/src/distributions/bernoulli.rs:116:5: docs for function returning `Result` missing `# Errors` section -rand-0.7.3/src/distributions/bernoulli.rs:123:21: casting `f64` to `u64` may lose the sign of the value -rand-0.7.3/src/distributions/bernoulli.rs:123:21: casting `f64` to `u64` may truncate the value -rand-0.7.3/src/distributions/bernoulli.rs:63:26: casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -rand-0.7.3/src/distributions/bernoulli.rs:63:27: integer type suffix should be separated by an underscore -rand-0.7.3/src/distributions/bernoulli.rs:67:1: item name starts with its containing module's name -rand-0.7.3/src/distributions/bernoulli.rs:95:5: docs for function returning `Result` missing `# Errors` section -rand-0.7.3/src/distributions/bernoulli.rs:96:13: manual `Range::contains` implementation -rand-0.7.3/src/distributions/binomial.rs:107:23: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -rand-0.7.3/src/distributions/binomial.rs:112:44: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -rand-0.7.3/src/distributions/binomial.rs:116:13: adding items after statements is confusing, since items exist from the start of the scope -rand-0.7.3/src/distributions/binomial.rs:150:28: redundant else block -rand-0.7.3/src/distributions/binomial.rs:153:24: unnecessary boolean `not` operation -rand-0.7.3/src/distributions/binomial.rs:158:28: redundant else block -rand-0.7.3/src/distributions/binomial.rs:164:33: casting `i64` to `u64` may lose the sign of the value -rand-0.7.3/src/distributions/binomial.rs:166:28: redundant else block -rand-0.7.3/src/distributions/binomial.rs:175:47: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -rand-0.7.3/src/distributions/binomial.rs:185:38: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -rand-0.7.3/src/distributions/binomial.rs:194:38: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -rand-0.7.3/src/distributions/binomial.rs:202:28: redundant else block -rand-0.7.3/src/distributions/binomial.rs:209:25: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -rand-0.7.3/src/distributions/binomial.rs:221:26: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -rand-0.7.3/src/distributions/binomial.rs:222:26: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -rand-0.7.3/src/distributions/binomial.rs:223:25: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -rand-0.7.3/src/distributions/binomial.rs:224:25: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -rand-0.7.3/src/distributions/binomial.rs:226:17: adding items after statements is confusing, since items exist from the start of the scope -rand-0.7.3/src/distributions/binomial.rs:233:32: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -rand-0.7.3/src/distributions/binomial.rs:234:27: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -rand-0.7.3/src/distributions/binomial.rs:251:22: casting `i64` to `u64` may lose the sign of the value -rand-0.7.3/src/distributions/binomial.rs:255:9: unnecessary `!=` operation -rand-0.7.3/src/distributions/binomial.rs:35:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/distributions/binomial.rs:45:17: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -rand-0.7.3/src/distributions/binomial.rs:46:5: casting `f64` to `i64` may truncate the value -rand-0.7.3/src/distributions/binomial.rs:50:5: this function has too many lines (143/100) -rand-0.7.3/src/distributions/binomial.rs:76:9: adding items after statements is confusing, since items exist from the start of the scope -rand-0.7.3/src/distributions/binomial.rs:78:12: casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -rand-0.7.3/src/distributions/binomial.rs:81:21: casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -rand-0.7.3/src/distributions/binomial.rs:82:32: casting `u64` to `i32` may truncate the value -rand-0.7.3/src/distributions/binomial.rs:88:26: casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -rand-0.7.3/src/distributions/binomial.rs:99:21: casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -rand-0.7.3/src/distributions/cauchy.rs:33:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/distributions/dirichlet.rs:52:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/distributions/dirichlet.rs:64:32: float type suffix should be separated by an underscore -rand-0.7.3/src/distributions/dirichlet.rs:65:23: float type suffix should be separated by an underscore -rand-0.7.3/src/distributions/exponential.rs:76:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/distributions/float.rs:73:1: item name ends with its containing module's name -rand-0.7.3/src/distributions/gamma.rs:13:5: usage of wildcard import for enum variants -rand-0.7.3/src/distributions/gamma.rs:14:5: usage of wildcard import for enum variants -rand-0.7.3/src/distributions/gamma.rs:189:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/distributions/gamma.rs:230:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/distributions/gamma.rs:259:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/distributions/gamma.rs:287:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/distributions/gamma.rs:90:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/distributions/integer.rs:23:9: casting `u32` to `u8` may truncate the value -rand-0.7.3/src/distributions/integer.rs:30:9: casting `u32` to `u16` may truncate the value -rand-0.7.3/src/distributions/integer.rs:69:9: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers -rand-0.7.3/src/distributions/mod.rs:263:5: you have declared `#[inline(always)]` on `next`. This is usually a bad idea -rand-0.7.3/src/distributions/normal.rs:100:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/distributions/normal.rs:119:1: item name ends with its containing module's name -rand-0.7.3/src/distributions/normal.rs:131:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/distributions/normal.rs:31:1: item name ends with its containing module's name -rand-0.7.3/src/distributions/normal.rs:47:25: float type suffix should be separated by an underscore -rand-0.7.3/src/distributions/normal.rs:48:25: float type suffix should be separated by an underscore -rand-0.7.3/src/distributions/other.rs:89:9: casting `u32` to `i32` may wrap around the value -rand-0.7.3/src/distributions/pareto.rs:32:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/distributions/poisson.rs:35:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/distributions/poisson.rs:87:30: casting `f64` to `u64` may lose the sign of the value -rand-0.7.3/src/distributions/poisson.rs:87:30: casting `f64` to `u64` may truncate the value -rand-0.7.3/src/distributions/triangular.rs:32:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/distributions/uniform.rs:146:4: needless `fn main` in doctest -rand-0.7.3/src/distributions/uniform.rs:199:1: item name ends with its containing module's name -rand-0.7.3/src/distributions/uniform.rs:214:1: item name starts with its containing module's name -rand-0.7.3/src/distributions/uniform.rs:283:14: you should put `SampleUniform` between ticks in the documentation -rand-0.7.3/src/distributions/uniform.rs:283:46: you should put `SampleUniform` between ticks in the documentation -rand-0.7.3/src/distributions/uniform.rs:296:5: you have declared `#[inline(always)]` on `borrow`. This is usually a bad idea -rand-0.7.3/src/distributions/uniform.rs:304:5: you have declared `#[inline(always)]` on `borrow`. This is usually a bad idea -rand-0.7.3/src/distributions/uniform.rs:350:1: item name starts with its containing module's name -rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization -rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization -rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization -rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization -rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization -rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization -rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization -rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization -rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization -rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization -rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization -rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization -rand-0.7.3/src/distributions/uniform.rs:441:31: because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false -rand-0.7.3/src/distributions/uniform.rs:441:31: because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false -rand-0.7.3/src/distributions/uniform.rs:441:31: because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false -rand-0.7.3/src/distributions/uniform.rs:441:31: because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false -rand-0.7.3/src/distributions/uniform.rs:441:31: because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false -rand-0.7.3/src/distributions/uniform.rs:441:31: because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false -rand-0.7.3/src/distributions/uniform.rs:441:31: because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false -rand-0.7.3/src/distributions/uniform.rs:441:31: because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false -rand-0.7.3/src/distributions/uniform.rs:56:10: you should put `SampleBorrow` between ticks in the documentation -rand-0.7.3/src/distributions/uniform.rs:647:1: item name starts with its containing module's name -rand-0.7.3/src/distributions/uniform.rs:840:1: item name starts with its containing module's name -rand-0.7.3/src/distributions/uniform.rs:913:13: use Option::map_or_else instead of an if let/else -rand-0.7.3/src/distributions/uniform.rs:943:54: casting `u64` to `u32` may truncate the value -rand-0.7.3/src/distributions/unit_circle.rs:30:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/distributions/unit_sphere.rs:24:1: item name starts with its containing module's name -rand-0.7.3/src/distributions/unit_sphere.rs:29:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/distributions/utils.rs:254:5: you have declared `#[inline(always)]` on `lanes`. This is usually a bad idea -rand-0.7.3/src/distributions/utils.rs:258:5: you have declared `#[inline(always)]` on `splat`. This is usually a bad idea -rand-0.7.3/src/distributions/utils.rs:262:5: you have declared `#[inline(always)]` on `extract`. This is usually a bad idea -rand-0.7.3/src/distributions/utils.rs:267:5: you have declared `#[inline(always)]` on `replace`. This is usually a bad idea -rand-0.7.3/src/distributions/utils.rs:281:5: you have declared `#[inline(always)]` on `any`. This is usually a bad idea -rand-0.7.3/src/distributions/utils.rs:286:5: you have declared `#[inline(always)]` on `all`. This is usually a bad idea -rand-0.7.3/src/distributions/utils.rs:291:5: you have declared `#[inline(always)]` on `none`. This is usually a bad idea -rand-0.7.3/src/distributions/utils.rs:488:17: you should put `x_i` between ticks in the documentation -rand-0.7.3/src/distributions/utils.rs:489:50: you should put `x_i` between ticks in the documentation -rand-0.7.3/src/distributions/utils.rs:489:63: you should put `f(x_i` between ticks in the documentation -rand-0.7.3/src/distributions/utils.rs:490:40: you should put `f(x_i` between ticks in the documentation -rand-0.7.3/src/distributions/utils.rs:490:49: you should put `f(x_{i+1` between ticks in the documentation -rand-0.7.3/src/distributions/utils.rs:518:17: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers -rand-0.7.3/src/distributions/weibull.rs:29:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/distributions/weighted/alias_method.rs:113:21: it is more concise to loop over references to containers instead of using explicit iteration methods -rand-0.7.3/src/distributions/weighted/alias_method.rs:125:9: adding items after statements is confusing, since items exist from the start of the scope -rand-0.7.3/src/distributions/weighted/alias_method.rs:131:9: adding items after statements is confusing, since items exist from the start of the scope -rand-0.7.3/src/distributions/weighted/alias_method.rs:180:36: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -rand-0.7.3/src/distributions/weighted/alias_method.rs:182:34: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -rand-0.7.3/src/distributions/weighted/alias_method.rs:259:28: using `clone` on type `distributions::uniform::Uniform` which implements the `Copy` trait -rand-0.7.3/src/distributions/weighted/alias_method.rs:296:9: you are using an explicit closure for copying elements -rand-0.7.3/src/distributions/weighted/alias_method.rs:321:9: you are using an explicit closure for copying elements -rand-0.7.3/src/distributions/weighted/alias_method.rs:78:5: docs for function returning `Result` missing `# Errors` section -rand-0.7.3/src/distributions/weighted/alias_method.rs:78:5: this function has too many lines (106/100) -rand-0.7.3/src/distributions/weighted/alias_method.rs:85:17: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -rand-0.7.3/src/distributions/weighted/alias_method.rs:87:31: called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead -rand-0.7.3/src/distributions/weighted/mod.rs:100:5: docs for function returning `Result` missing `# Errors` section -rand-0.7.3/src/distributions/weighted/mod.rs:144:5: docs for function returning `Result` missing `# Errors` section -rand-0.7.3/src/distributions/weighted/mod.rs:169:16: unnecessary `>= y + 1` or `x - 1 >=` -rand-0.7.3/src/distributions/weighted/mod.rs:386:1: item name starts with its containing module's name -rand-0.7.3/src/distributions/weighted/mod.rs:85:1: item name starts with its containing module's name -rand-0.7.3/src/lib.rs:333:5: docs for function returning `Result` missing `# Errors` section -rand-0.7.3/src/lib.rs:552:1: this function could have a `#[must_use]` attribute -rand-0.7.3/src/rngs/adapter/read.rs:47:1: item name starts with its containing module's name -rand-0.7.3/src/rngs/adapter/read.rs:89:1: item name starts with its containing module's name -rand-0.7.3/src/rngs/adapter/reseeding.rs:100:5: docs for function returning `Result` missing `# Errors` section -rand-0.7.3/src/rngs/adapter/reseeding.rs:112:5: you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea -rand-0.7.3/src/rngs/adapter/reseeding.rs:117:5: you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea -rand-0.7.3/src/rngs/adapter/reseeding.rs:198:13: casting `u64` to `i64` may wrap around the value -rand-0.7.3/src/rngs/adapter/reseeding.rs:231:9: casting `usize` to `isize` may wrap around the value -rand-0.7.3/src/rngs/adapter/reseeding.rs:27:28: you should put `ChaCha` between ticks in the documentation -rand-0.7.3/src/rngs/adapter/reseeding.rs:79:1: item name starts with its containing module's name -rand-0.7.3/src/rngs/entropy.rs:24:1: item name starts with its containing module's name -rand-0.7.3/src/rngs/entropy.rs:34:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/rngs/mock.rs:36:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/rngs/mock.rs:47:9: casting `u64` to `u32` may truncate the value -rand-0.7.3/src/rngs/mod.rs:61:74: you should put `ChaCha20` between ticks in the documentation -rand-0.7.3/src/rngs/std.rs:25:39: you should put `ChaCha` between ticks in the documentation -rand-0.7.3/src/rngs/std.rs:32:10: you should put `rand_chacha` between ticks in the documentation -rand-0.7.3/src/rngs/std.rs:36:1: item name starts with its containing module's name -rand-0.7.3/src/rngs/std.rs:39:5: you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea -rand-0.7.3/src/rngs/std.rs:44:5: you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea -rand-0.7.3/src/rngs/std.rs:49:5: you have declared `#[inline(always)]` on `fill_bytes`. This is usually a bad idea -rand-0.7.3/src/rngs/std.rs:54:5: you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea -rand-0.7.3/src/rngs/std.rs:63:5: you have declared `#[inline(always)]` on `from_seed`. This is usually a bad idea -rand-0.7.3/src/rngs/std.rs:68:5: you have declared `#[inline(always)]` on `from_rng`. This is usually a bad idea -rand-0.7.3/src/rngs/thread.rs:57:1: item name starts with its containing module's name -rand-0.7.3/src/rngs/thread.rs:80:1: item name starts with its containing module's name -rand-0.7.3/src/rngs/thread.rs:80:1: this function could have a `#[must_use]` attribute -rand-0.7.3/src/rngs/thread.rs:81:35: redundant closure found -rand-0.7.3/src/rngs/thread.rs:93:5: you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea -rand-0.7.3/src/rngs/thread.rs:98:5: you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea -rand-0.7.3/src/seq/index.rs:127:1: item name starts with its containing module's name -rand-0.7.3/src/seq/index.rs:139:13: usage of wildcard import for enum variants -rand-0.7.3/src/seq/index.rs:159:1: item name starts with its containing module's name -rand-0.7.3/src/seq/index.rs:171:13: usage of wildcard import for enum variants -rand-0.7.3/src/seq/index.rs:180:13: usage of wildcard import for enum variants -rand-0.7.3/src/seq/index.rs:223:18: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -rand-0.7.3/src/seq/index.rs:224:18: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -rand-0.7.3/src/seq/index.rs:233:25: casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide) -rand-0.7.3/src/seq/index.rs:236:27: casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide) -rand-0.7.3/src/seq/index.rs:244:12: casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide) -rand-0.7.3/src/seq/index.rs:244:37: casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide) -rand-0.7.3/src/seq/index.rs:29:1: item name starts with its containing module's name -rand-0.7.3/src/seq/index.rs:39:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/seq/index.rs:48:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/seq/index.rs:60:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/seq/index.rs:69:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/seq/index.rs:78:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/seq/index.rs:87:5: method `into_iter` can be confused for the standard trait method `std::iter::IntoIterator::into_iter` -rand-0.7.3/src/seq/index.rs:87:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/seq/index.rs:97:13: usage of wildcard import for enum variants -rand-0.7.3/src/seq/mod.rs:141:5: docs for function returning `Result` missing `# Errors` section -rand-0.7.3/src/seq/mod.rs:168:5: docs for function returning `Result` missing `# Errors` section -rand-0.7.3/src/seq/mod.rs:229:4: needless `fn main` in doctest -rand-0.7.3/src/seq/mod.rs:292:29: casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -rand-0.7.3/src/seq/mod.rs:410:23: calling `std::marker::PhantomData::default()` is more clear than this expression -rand-0.7.3/src/seq/mod.rs:45:4: needless `fn main` in doctest -rand-0.7.3/src/seq/mod.rs:527:26: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -syn-1.0.54/src/lit.rs:1397:40: redundant else block -syn-1.0.54/src/lit.rs:1405:28: redundant else block -syn-1.0.54/src/lit.rs:1485:32: redundant else block libc-0.2.81/build.rs:114:19: called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead libc-0.2.81/build.rs:124:5: this block may be rewritten with the `?` operator libc-0.2.81/build.rs:133:5: this block may be rewritten with the `?` operator @@ -2658,6 +1910,109 @@ libc-0.2.81/src/unix/mod.rs:285:36: long literal lacking separators libc-0.2.81/src/unix/mod.rs:34:1: enum with no variants libc-0.2.81/src/unix/mod.rs:386:1: enum with no variants libc-0.2.81/src/unix/mod.rs:394:1: enum with no variants +log-0.4.11/src/lib.rs:1047:5: this method could have a `#[must_use]` attribute +log-0.4.11/src/lib.rs:1053:5: this method could have a `#[must_use]` attribute +log-0.4.11/src/lib.rs:1059:5: this method could have a `#[must_use]` attribute +log-0.4.11/src/lib.rs:1093:5: this method could have a `#[must_use]` attribute +log-0.4.11/src/lib.rs:1093:5: you should consider adding a `Default` implementation for `MetadataBuilder<'a>` +log-0.4.11/src/lib.rs:1118:5: this method could have a `#[must_use]` attribute +log-0.4.11/src/lib.rs:1177:1: you have declared `#[inline(always)]` on `max_level`. This is usually a bad idea +log-0.4.11/src/lib.rs:1178:1: this function could have a `#[must_use]` attribute +log-0.4.11/src/lib.rs:1306:1: docs for function returning `Result` missing `# Errors` section +log-0.4.11/src/lib.rs:1358:1: this function could have a `#[must_use]` attribute +log-0.4.11/src/lib.rs:1359:5: unnecessary `!=` operation +log-0.4.11/src/lib.rs:1407:1: this function could have a `#[must_use]` attribute +log-0.4.11/src/lib.rs:329:27: you are deriving `Hash` but have implemented `PartialEq` explicitly +log-0.4.11/src/lib.rs:356:1: you are implementing `Clone` explicitly on a `Copy` type +log-0.4.11/src/lib.rs:448:12: manual `RangeInclusive::contains` implementation +log-0.4.11/src/lib.rs:468:13: called `filter(..).map(..)` on an `Iterator` +log-0.4.11/src/lib.rs:500:5: this method could have a `#[must_use]` attribute +log-0.4.11/src/lib.rs:506:28: this argument (8 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) +log-0.4.11/src/lib.rs:506:5: this method could have a `#[must_use]` attribute +log-0.4.11/src/lib.rs:520:27: you are deriving `Hash` but have implemented `PartialEq` explicitly +log-0.4.11/src/lib.rs:538:1: you are implementing `Clone` explicitly on a `Copy` type +log-0.4.11/src/lib.rs:653:5: this method could have a `#[must_use]` attribute +log-0.4.11/src/lib.rs:661:21: this argument (8 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) +log-0.4.11/src/lib.rs:661:5: this method could have a `#[must_use]` attribute +log-0.4.11/src/lib.rs:677:44: this `match` has identical arm bodies +log-0.4.11/src/lib.rs:758:5: this method could have a `#[must_use]` attribute +log-0.4.11/src/lib.rs:764:5: this method could have a `#[must_use]` attribute +log-0.4.11/src/lib.rs:770:5: this method could have a `#[must_use]` attribute +log-0.4.11/src/lib.rs:776:5: this method could have a `#[must_use]` attribute +log-0.4.11/src/lib.rs:782:5: this method could have a `#[must_use]` attribute +log-0.4.11/src/lib.rs:788:5: this method could have a `#[must_use]` attribute +log-0.4.11/src/lib.rs:794:5: this method could have a `#[must_use]` attribute +log-0.4.11/src/lib.rs:803:5: this method could have a `#[must_use]` attribute +log-0.4.11/src/lib.rs:809:5: this method could have a `#[must_use]` attribute +log-0.4.11/src/lib.rs:818:5: this method could have a `#[must_use]` attribute +log-0.4.11/src/lib.rs:908:5: this method could have a `#[must_use]` attribute +log-0.4.11/src/lib.rs:908:5: you should consider adding a `Default` implementation for `RecordBuilder<'a>` +log-0.4.11/src/lib.rs:995:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/detection.rs:2:5: usage of wildcard import +proc-macro2-1.0.24/src/fallback.rs:108:17: wildcard match will miss any future added variants +proc-macro2-1.0.24/src/fallback.rs:269:20: unused `self` argument +proc-macro2-1.0.24/src/fallback.rs:430:24: this argument (0 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) +proc-macro2-1.0.24/src/fallback.rs:437:23: this argument (0 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) +proc-macro2-1.0.24/src/fallback.rs:437:23: unused `self` argument +proc-macro2-1.0.24/src/fallback.rs:471:17: this argument (0 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) +proc-macro2-1.0.24/src/fallback.rs:471:17: unused `self` argument +proc-macro2-1.0.24/src/fallback.rs:654:5: manual `RangeInclusive::contains` implementation +proc-macro2-1.0.24/src/fallback.rs:655:12: manual `RangeInclusive::contains` implementation +proc-macro2-1.0.24/src/fallback.rs:661:5: manual `RangeInclusive::contains` implementation +proc-macro2-1.0.24/src/fallback.rs:662:12: manual `RangeInclusive::contains` implementation +proc-macro2-1.0.24/src/fallback.rs:664:12: manual `RangeInclusive::contains` implementation +proc-macro2-1.0.24/src/fallback.rs:674:37: manual `RangeInclusive::contains` implementation +proc-macro2-1.0.24/src/fallback.rs:678:5: adding items after statements is confusing, since items exist from the start of the scope +proc-macro2-1.0.24/src/fallback.rs:85:9: adding items after statements is confusing, since items exist from the start of the scope +proc-macro2-1.0.24/src/fallback.rs:882:43: unused `self` argument +proc-macro2-1.0.24/src/lib.rs:1017:9: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:1081:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:1099:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:1117:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:1135:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:1141:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:1146:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:1151:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:1156:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:152:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:157:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:373:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:383:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:397:24: this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) +proc-macro2-1.0.24/src/lib.rs:397:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:403:23: this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) +proc-macro2-1.0.24/src/lib.rs:403:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:418:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:425:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:464:17: this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) +proc-macro2-1.0.24/src/lib.rs:500:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:626:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:633:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:641:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:652:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:662:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:672:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:734:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:743:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:752:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:757:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:788:19: you should put `XID_Start` between ticks in the documentation +proc-macro2-1.0.24/src/lib.rs:788:69: you should put `XID_Continue` between ticks in the documentation +proc-macro2-1.0.24/src/lib.rs:891:36: you should put `syn::parse_str` between ticks in the documentation +proc-macro2-1.0.24/src/lib.rs:894:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:911:5: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/lib.rs:996:9: this method could have a `#[must_use]` attribute +proc-macro2-1.0.24/src/parse.rs:552:5: this loop could be written as a `for` loop +proc-macro2-1.0.24/src/parse.rs:584:21: manual `RangeInclusive::contains` implementation +proc-macro2-1.0.24/src/parse.rs:602:20: called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead +proc-macro2-1.0.24/src/parse.rs:696:29: casting `u8` to `u64` may become silently lossy if you later change the type +proc-macro2-1.0.24/src/parse.rs:702:34: casting `u8` to `u64` may become silently lossy if you later change the type +proc-macro2-1.0.24/src/parse.rs:708:34: casting `u8` to `u64` may become silently lossy if you later change the type +proc-macro2-1.0.24/src/parse.rs:803:15: it is more concise to loop over references to containers instead of using explicit iteration methods +proc-macro2-1.0.24/src/parse.rs:808:15: it is more concise to loop over references to containers instead of using explicit iteration methods +proc-macro2-1.0.24/src/wrapper.rs:415:24: this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) +proc-macro2-1.0.24/src/wrapper.rs:429:23: this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) +proc-macro2-1.0.24/src/wrapper.rs:492:17: this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) quote-1.0.7/src/ext.rs:10:1: item name ends with its containing module's name quote-1.0.7/src/ext.rs:7:5: you should put `TokenStream` between ticks in the documentation quote-1.0.7/src/ident_fragment.rs:13:5: docs for function returning `Result` missing `# Errors` section @@ -2666,6 +2021,206 @@ quote-1.0.7/src/runtime.rs:52:5: item name ends with its containing module's nam quote-1.0.7/src/runtime.rs:63:5: item name ends with its containing module's name quote-1.0.7/src/runtime.rs:66:33: you should put `DoesNotHaveIter` between ticks in the documentation quote-1.0.7/src/runtime.rs:80:5: item name ends with its containing module's name +rand-0.7.3/src/distributions/bernoulli.rs:103:20: casting `f64` to `u64` may lose the sign of the value +rand-0.7.3/src/distributions/bernoulli.rs:103:20: casting `f64` to `u64` may truncate the value +rand-0.7.3/src/distributions/bernoulli.rs:116:5: docs for function returning `Result` missing `# Errors` section +rand-0.7.3/src/distributions/bernoulli.rs:123:21: casting `f64` to `u64` may lose the sign of the value +rand-0.7.3/src/distributions/bernoulli.rs:123:21: casting `f64` to `u64` may truncate the value +rand-0.7.3/src/distributions/bernoulli.rs:63:26: casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +rand-0.7.3/src/distributions/bernoulli.rs:63:27: integer type suffix should be separated by an underscore +rand-0.7.3/src/distributions/bernoulli.rs:67:1: item name starts with its containing module's name +rand-0.7.3/src/distributions/bernoulli.rs:95:5: docs for function returning `Result` missing `# Errors` section +rand-0.7.3/src/distributions/bernoulli.rs:96:13: manual `Range::contains` implementation +rand-0.7.3/src/distributions/binomial.rs:107:23: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +rand-0.7.3/src/distributions/binomial.rs:112:44: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +rand-0.7.3/src/distributions/binomial.rs:116:13: adding items after statements is confusing, since items exist from the start of the scope +rand-0.7.3/src/distributions/binomial.rs:150:28: redundant else block +rand-0.7.3/src/distributions/binomial.rs:153:24: unnecessary boolean `not` operation +rand-0.7.3/src/distributions/binomial.rs:158:28: redundant else block +rand-0.7.3/src/distributions/binomial.rs:164:33: casting `i64` to `u64` may lose the sign of the value +rand-0.7.3/src/distributions/binomial.rs:166:28: redundant else block +rand-0.7.3/src/distributions/binomial.rs:175:47: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +rand-0.7.3/src/distributions/binomial.rs:185:38: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +rand-0.7.3/src/distributions/binomial.rs:194:38: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +rand-0.7.3/src/distributions/binomial.rs:202:28: redundant else block +rand-0.7.3/src/distributions/binomial.rs:209:25: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +rand-0.7.3/src/distributions/binomial.rs:221:26: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +rand-0.7.3/src/distributions/binomial.rs:222:26: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +rand-0.7.3/src/distributions/binomial.rs:223:25: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +rand-0.7.3/src/distributions/binomial.rs:224:25: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +rand-0.7.3/src/distributions/binomial.rs:226:17: adding items after statements is confusing, since items exist from the start of the scope +rand-0.7.3/src/distributions/binomial.rs:233:32: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +rand-0.7.3/src/distributions/binomial.rs:234:27: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +rand-0.7.3/src/distributions/binomial.rs:251:22: casting `i64` to `u64` may lose the sign of the value +rand-0.7.3/src/distributions/binomial.rs:255:9: unnecessary `!=` operation +rand-0.7.3/src/distributions/binomial.rs:35:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/distributions/binomial.rs:45:17: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +rand-0.7.3/src/distributions/binomial.rs:46:5: casting `f64` to `i64` may truncate the value +rand-0.7.3/src/distributions/binomial.rs:50:5: this function has too many lines (143/100) +rand-0.7.3/src/distributions/binomial.rs:76:9: adding items after statements is confusing, since items exist from the start of the scope +rand-0.7.3/src/distributions/binomial.rs:78:12: casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +rand-0.7.3/src/distributions/binomial.rs:81:21: casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +rand-0.7.3/src/distributions/binomial.rs:82:32: casting `u64` to `i32` may truncate the value +rand-0.7.3/src/distributions/binomial.rs:88:26: casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +rand-0.7.3/src/distributions/binomial.rs:99:21: casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +rand-0.7.3/src/distributions/cauchy.rs:33:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/distributions/dirichlet.rs:52:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/distributions/dirichlet.rs:64:32: float type suffix should be separated by an underscore +rand-0.7.3/src/distributions/dirichlet.rs:65:23: float type suffix should be separated by an underscore +rand-0.7.3/src/distributions/exponential.rs:76:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/distributions/float.rs:73:1: item name ends with its containing module's name +rand-0.7.3/src/distributions/gamma.rs:13:5: usage of wildcard import for enum variants +rand-0.7.3/src/distributions/gamma.rs:14:5: usage of wildcard import for enum variants +rand-0.7.3/src/distributions/gamma.rs:189:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/distributions/gamma.rs:230:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/distributions/gamma.rs:259:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/distributions/gamma.rs:287:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/distributions/gamma.rs:90:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/distributions/integer.rs:23:9: casting `u32` to `u8` may truncate the value +rand-0.7.3/src/distributions/integer.rs:30:9: casting `u32` to `u16` may truncate the value +rand-0.7.3/src/distributions/integer.rs:69:9: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers +rand-0.7.3/src/distributions/mod.rs:263:5: you have declared `#[inline(always)]` on `next`. This is usually a bad idea +rand-0.7.3/src/distributions/normal.rs:100:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/distributions/normal.rs:119:1: item name ends with its containing module's name +rand-0.7.3/src/distributions/normal.rs:131:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/distributions/normal.rs:31:1: item name ends with its containing module's name +rand-0.7.3/src/distributions/normal.rs:47:25: float type suffix should be separated by an underscore +rand-0.7.3/src/distributions/normal.rs:48:25: float type suffix should be separated by an underscore +rand-0.7.3/src/distributions/other.rs:89:9: casting `u32` to `i32` may wrap around the value +rand-0.7.3/src/distributions/pareto.rs:32:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/distributions/poisson.rs:35:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/distributions/poisson.rs:87:30: casting `f64` to `u64` may lose the sign of the value +rand-0.7.3/src/distributions/poisson.rs:87:30: casting `f64` to `u64` may truncate the value +rand-0.7.3/src/distributions/triangular.rs:32:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/distributions/uniform.rs:146:4: needless `fn main` in doctest +rand-0.7.3/src/distributions/uniform.rs:199:1: item name ends with its containing module's name +rand-0.7.3/src/distributions/uniform.rs:214:1: item name starts with its containing module's name +rand-0.7.3/src/distributions/uniform.rs:283:14: you should put `SampleUniform` between ticks in the documentation +rand-0.7.3/src/distributions/uniform.rs:283:46: you should put `SampleUniform` between ticks in the documentation +rand-0.7.3/src/distributions/uniform.rs:296:5: you have declared `#[inline(always)]` on `borrow`. This is usually a bad idea +rand-0.7.3/src/distributions/uniform.rs:304:5: you have declared `#[inline(always)]` on `borrow`. This is usually a bad idea +rand-0.7.3/src/distributions/uniform.rs:350:1: item name starts with its containing module's name +rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization +rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization +rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization +rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization +rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization +rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization +rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization +rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization +rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization +rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization +rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization +rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization +rand-0.7.3/src/distributions/uniform.rs:441:31: because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false +rand-0.7.3/src/distributions/uniform.rs:441:31: because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false +rand-0.7.3/src/distributions/uniform.rs:441:31: because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false +rand-0.7.3/src/distributions/uniform.rs:441:31: because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false +rand-0.7.3/src/distributions/uniform.rs:441:31: because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false +rand-0.7.3/src/distributions/uniform.rs:441:31: because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false +rand-0.7.3/src/distributions/uniform.rs:441:31: because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false +rand-0.7.3/src/distributions/uniform.rs:441:31: because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false +rand-0.7.3/src/distributions/uniform.rs:56:10: you should put `SampleBorrow` between ticks in the documentation +rand-0.7.3/src/distributions/uniform.rs:647:1: item name starts with its containing module's name +rand-0.7.3/src/distributions/uniform.rs:840:1: item name starts with its containing module's name +rand-0.7.3/src/distributions/uniform.rs:913:13: use Option::map_or_else instead of an if let/else +rand-0.7.3/src/distributions/uniform.rs:943:54: casting `u64` to `u32` may truncate the value +rand-0.7.3/src/distributions/unit_circle.rs:30:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/distributions/unit_sphere.rs:24:1: item name starts with its containing module's name +rand-0.7.3/src/distributions/unit_sphere.rs:29:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/distributions/utils.rs:247:15: methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name +rand-0.7.3/src/distributions/utils.rs:248:20: methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name +rand-0.7.3/src/distributions/utils.rs:249:18: methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name +rand-0.7.3/src/distributions/utils.rs:254:5: you have declared `#[inline(always)]` on `lanes`. This is usually a bad idea +rand-0.7.3/src/distributions/utils.rs:258:5: you have declared `#[inline(always)]` on `splat`. This is usually a bad idea +rand-0.7.3/src/distributions/utils.rs:262:5: you have declared `#[inline(always)]` on `extract`. This is usually a bad idea +rand-0.7.3/src/distributions/utils.rs:267:5: you have declared `#[inline(always)]` on `replace`. This is usually a bad idea +rand-0.7.3/src/distributions/utils.rs:281:5: you have declared `#[inline(always)]` on `any`. This is usually a bad idea +rand-0.7.3/src/distributions/utils.rs:286:5: you have declared `#[inline(always)]` on `all`. This is usually a bad idea +rand-0.7.3/src/distributions/utils.rs:291:5: you have declared `#[inline(always)]` on `none`. This is usually a bad idea +rand-0.7.3/src/distributions/utils.rs:488:17: you should put `x_i` between ticks in the documentation +rand-0.7.3/src/distributions/utils.rs:489:50: you should put `x_i` between ticks in the documentation +rand-0.7.3/src/distributions/utils.rs:489:63: you should put `f(x_i` between ticks in the documentation +rand-0.7.3/src/distributions/utils.rs:490:40: you should put `f(x_i` between ticks in the documentation +rand-0.7.3/src/distributions/utils.rs:490:49: you should put `f(x_{i+1` between ticks in the documentation +rand-0.7.3/src/distributions/utils.rs:518:17: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers +rand-0.7.3/src/distributions/weibull.rs:29:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/distributions/weighted/alias_method.rs:113:21: it is more concise to loop over references to containers instead of using explicit iteration methods +rand-0.7.3/src/distributions/weighted/alias_method.rs:125:9: adding items after statements is confusing, since items exist from the start of the scope +rand-0.7.3/src/distributions/weighted/alias_method.rs:131:9: adding items after statements is confusing, since items exist from the start of the scope +rand-0.7.3/src/distributions/weighted/alias_method.rs:180:36: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers +rand-0.7.3/src/distributions/weighted/alias_method.rs:182:34: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers +rand-0.7.3/src/distributions/weighted/alias_method.rs:259:28: using `clone` on type `distributions::uniform::Uniform` which implements the `Copy` trait +rand-0.7.3/src/distributions/weighted/alias_method.rs:296:9: you are using an explicit closure for copying elements +rand-0.7.3/src/distributions/weighted/alias_method.rs:321:9: you are using an explicit closure for copying elements +rand-0.7.3/src/distributions/weighted/alias_method.rs:78:5: docs for function returning `Result` missing `# Errors` section +rand-0.7.3/src/distributions/weighted/alias_method.rs:78:5: this function has too many lines (106/100) +rand-0.7.3/src/distributions/weighted/alias_method.rs:85:17: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers +rand-0.7.3/src/distributions/weighted/alias_method.rs:87:31: called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead +rand-0.7.3/src/distributions/weighted/mod.rs:100:5: docs for function returning `Result` missing `# Errors` section +rand-0.7.3/src/distributions/weighted/mod.rs:144:5: docs for function returning `Result` missing `# Errors` section +rand-0.7.3/src/distributions/weighted/mod.rs:169:16: unnecessary `>= y + 1` or `x - 1 >=` +rand-0.7.3/src/distributions/weighted/mod.rs:386:1: item name starts with its containing module's name +rand-0.7.3/src/distributions/weighted/mod.rs:85:1: item name starts with its containing module's name +rand-0.7.3/src/lib.rs:333:5: docs for function returning `Result` missing `# Errors` section +rand-0.7.3/src/lib.rs:404:14: methods called `to_*` usually take self by reference; consider choosing a less ambiguous name +rand-0.7.3/src/lib.rs:552:1: this function could have a `#[must_use]` attribute +rand-0.7.3/src/rngs/adapter/read.rs:47:1: item name starts with its containing module's name +rand-0.7.3/src/rngs/adapter/read.rs:89:1: item name starts with its containing module's name +rand-0.7.3/src/rngs/adapter/reseeding.rs:100:5: docs for function returning `Result` missing `# Errors` section +rand-0.7.3/src/rngs/adapter/reseeding.rs:112:5: you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea +rand-0.7.3/src/rngs/adapter/reseeding.rs:117:5: you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea +rand-0.7.3/src/rngs/adapter/reseeding.rs:198:13: casting `u64` to `i64` may wrap around the value +rand-0.7.3/src/rngs/adapter/reseeding.rs:231:9: casting `usize` to `isize` may wrap around the value +rand-0.7.3/src/rngs/adapter/reseeding.rs:27:28: you should put `ChaCha` between ticks in the documentation +rand-0.7.3/src/rngs/adapter/reseeding.rs:79:1: item name starts with its containing module's name +rand-0.7.3/src/rngs/entropy.rs:24:1: item name starts with its containing module's name +rand-0.7.3/src/rngs/entropy.rs:34:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/rngs/mock.rs:36:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/rngs/mock.rs:47:9: casting `u64` to `u32` may truncate the value +rand-0.7.3/src/rngs/mod.rs:61:74: you should put `ChaCha20` between ticks in the documentation +rand-0.7.3/src/rngs/std.rs:25:39: you should put `ChaCha` between ticks in the documentation +rand-0.7.3/src/rngs/std.rs:32:10: you should put `rand_chacha` between ticks in the documentation +rand-0.7.3/src/rngs/std.rs:36:1: item name starts with its containing module's name +rand-0.7.3/src/rngs/std.rs:39:5: you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea +rand-0.7.3/src/rngs/std.rs:44:5: you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea +rand-0.7.3/src/rngs/std.rs:49:5: you have declared `#[inline(always)]` on `fill_bytes`. This is usually a bad idea +rand-0.7.3/src/rngs/std.rs:54:5: you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea +rand-0.7.3/src/rngs/std.rs:63:5: you have declared `#[inline(always)]` on `from_seed`. This is usually a bad idea +rand-0.7.3/src/rngs/std.rs:68:5: you have declared `#[inline(always)]` on `from_rng`. This is usually a bad idea +rand-0.7.3/src/rngs/thread.rs:57:1: item name starts with its containing module's name +rand-0.7.3/src/rngs/thread.rs:80:1: item name starts with its containing module's name +rand-0.7.3/src/rngs/thread.rs:80:1: this function could have a `#[must_use]` attribute +rand-0.7.3/src/rngs/thread.rs:81:35: redundant closure found +rand-0.7.3/src/rngs/thread.rs:93:5: you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea +rand-0.7.3/src/rngs/thread.rs:98:5: you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea +rand-0.7.3/src/seq/index.rs:127:1: item name starts with its containing module's name +rand-0.7.3/src/seq/index.rs:139:13: usage of wildcard import for enum variants +rand-0.7.3/src/seq/index.rs:159:1: item name starts with its containing module's name +rand-0.7.3/src/seq/index.rs:171:13: usage of wildcard import for enum variants +rand-0.7.3/src/seq/index.rs:180:13: usage of wildcard import for enum variants +rand-0.7.3/src/seq/index.rs:223:18: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers +rand-0.7.3/src/seq/index.rs:224:18: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers +rand-0.7.3/src/seq/index.rs:233:25: casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide) +rand-0.7.3/src/seq/index.rs:236:27: casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide) +rand-0.7.3/src/seq/index.rs:244:12: casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide) +rand-0.7.3/src/seq/index.rs:244:37: casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide) +rand-0.7.3/src/seq/index.rs:29:1: item name starts with its containing module's name +rand-0.7.3/src/seq/index.rs:39:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/seq/index.rs:48:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/seq/index.rs:60:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/seq/index.rs:69:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/seq/index.rs:78:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/seq/index.rs:87:5: method `into_iter` can be confused for the standard trait method `std::iter::IntoIterator::into_iter` +rand-0.7.3/src/seq/index.rs:87:5: this method could have a `#[must_use]` attribute +rand-0.7.3/src/seq/index.rs:97:13: usage of wildcard import for enum variants +rand-0.7.3/src/seq/mod.rs:141:5: docs for function returning `Result` missing `# Errors` section +rand-0.7.3/src/seq/mod.rs:168:5: docs for function returning `Result` missing `# Errors` section +rand-0.7.3/src/seq/mod.rs:229:4: needless `fn main` in doctest +rand-0.7.3/src/seq/mod.rs:292:29: casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +rand-0.7.3/src/seq/mod.rs:410:23: calling `std::marker::PhantomData::default()` is more clear than this expression +rand-0.7.3/src/seq/mod.rs:45:4: needless `fn main` in doctest +rand-0.7.3/src/seq/mod.rs:527:26: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers rand_core-0.6.0/src/block.rs:117:1: item name starts with its containing module's name rand_core-0.6.0/src/block.rs:153:5: you have declared `#[inline(always)]` on `index`. This is usually a bad idea rand_core-0.6.0/src/block.rs:230:5: you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea @@ -2694,559 +2249,996 @@ rand_core-0.6.0/src/lib.rs:381:5: you have declared `#[inline(always)]` on `next rand_core-0.6.0/src/lib.rs:386:5: you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea rand_core-0.6.0/src/lib.rs:391:5: you have declared `#[inline(always)]` on `fill_bytes`. This is usually a bad idea rand_core-0.6.0/src/lib.rs:396:5: you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea -unicode-xid-0.2.1/src/lib.rs:57:64: you should put `XID_Start` between ticks in the documentation -unicode-xid-0.2.1/src/lib.rs:60:10: you should put `XID_Start` between ticks in the documentation -unicode-xid-0.2.1/src/lib.rs:62:27: you should put `ID_Start` between ticks in the documentation -unicode-xid-0.2.1/src/lib.rs:62:67: you should put `NFKx` between ticks in the documentation -unicode-xid-0.2.1/src/lib.rs:65:61: you should put `XID_Continue` between ticks in the documentation -unicode-xid-0.2.1/src/lib.rs:68:10: you should put `XID_Continue` between ticks in the documentation -unicode-xid-0.2.1/src/lib.rs:70:28: you should put `ID_Continue` between ticks in the documentation -unicode-xid-0.2.1/src/lib.rs:70:72: you should put `NFKx` between ticks in the documentation -proc-macro2-1.0.24/src/detection.rs:2:5: usage of wildcard import -proc-macro2-1.0.24/src/fallback.rs:108:17: wildcard match will miss any future added variants -proc-macro2-1.0.24/src/fallback.rs:269:20: unused `self` argument -proc-macro2-1.0.24/src/fallback.rs:430:24: this argument (0 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -proc-macro2-1.0.24/src/fallback.rs:437:23: this argument (0 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -proc-macro2-1.0.24/src/fallback.rs:437:23: unused `self` argument -proc-macro2-1.0.24/src/fallback.rs:471:17: this argument (0 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -proc-macro2-1.0.24/src/fallback.rs:471:17: unused `self` argument -proc-macro2-1.0.24/src/fallback.rs:654:5: manual `RangeInclusive::contains` implementation -proc-macro2-1.0.24/src/fallback.rs:655:12: manual `RangeInclusive::contains` implementation -proc-macro2-1.0.24/src/fallback.rs:661:5: manual `RangeInclusive::contains` implementation -proc-macro2-1.0.24/src/fallback.rs:662:12: manual `RangeInclusive::contains` implementation -proc-macro2-1.0.24/src/fallback.rs:664:12: manual `RangeInclusive::contains` implementation -proc-macro2-1.0.24/src/fallback.rs:674:37: manual `RangeInclusive::contains` implementation -proc-macro2-1.0.24/src/fallback.rs:678:5: adding items after statements is confusing, since items exist from the start of the scope -proc-macro2-1.0.24/src/fallback.rs:85:9: adding items after statements is confusing, since items exist from the start of the scope -proc-macro2-1.0.24/src/fallback.rs:882:43: unused `self` argument -proc-macro2-1.0.24/src/lib.rs:1017:9: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:1081:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:1099:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:1117:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:1135:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:1141:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:1146:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:1151:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:1156:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:152:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:157:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:373:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:383:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:397:24: this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -proc-macro2-1.0.24/src/lib.rs:397:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:403:23: this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -proc-macro2-1.0.24/src/lib.rs:403:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:418:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:425:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:464:17: this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -proc-macro2-1.0.24/src/lib.rs:500:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:626:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:633:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:641:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:652:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:662:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:672:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:734:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:743:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:752:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:757:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:788:19: you should put `XID_Start` between ticks in the documentation -proc-macro2-1.0.24/src/lib.rs:788:69: you should put `XID_Continue` between ticks in the documentation -proc-macro2-1.0.24/src/lib.rs:891:36: you should put `syn::parse_str` between ticks in the documentation -proc-macro2-1.0.24/src/lib.rs:894:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:911:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:996:9: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/parse.rs:552:5: this loop could be written as a `for` loop -proc-macro2-1.0.24/src/parse.rs:584:21: manual `RangeInclusive::contains` implementation -proc-macro2-1.0.24/src/parse.rs:602:20: called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead -proc-macro2-1.0.24/src/parse.rs:696:29: casting `u8` to `u64` may become silently lossy if you later change the type -proc-macro2-1.0.24/src/parse.rs:702:34: casting `u8` to `u64` may become silently lossy if you later change the type -proc-macro2-1.0.24/src/parse.rs:708:34: casting `u8` to `u64` may become silently lossy if you later change the type -proc-macro2-1.0.24/src/parse.rs:803:15: it is more concise to loop over references to containers instead of using explicit iteration methods -proc-macro2-1.0.24/src/parse.rs:808:15: it is more concise to loop over references to containers instead of using explicit iteration methods -proc-macro2-1.0.24/src/wrapper.rs:415:24: this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -proc-macro2-1.0.24/src/wrapper.rs:429:23: this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -proc-macro2-1.0.24/src/wrapper.rs:492:17: this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -log-0.4.11/src/lib.rs:1047:5: this method could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:1053:5: this method could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:1059:5: this method could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:1093:5: this method could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:1093:5: you should consider adding a `Default` implementation for `MetadataBuilder<'a>` -log-0.4.11/src/lib.rs:1118:5: this method could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:1177:1: you have declared `#[inline(always)]` on `max_level`. This is usually a bad idea -log-0.4.11/src/lib.rs:1178:1: this function could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:1306:1: docs for function returning `Result` missing `# Errors` section -log-0.4.11/src/lib.rs:1358:1: this function could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:1359:5: unnecessary `!=` operation -log-0.4.11/src/lib.rs:1407:1: this function could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:329:27: you are deriving `Hash` but have implemented `PartialEq` explicitly -log-0.4.11/src/lib.rs:356:1: you are implementing `Clone` explicitly on a `Copy` type -log-0.4.11/src/lib.rs:448:12: manual `RangeInclusive::contains` implementation -log-0.4.11/src/lib.rs:468:13: called `filter(..).map(..)` on an `Iterator` -log-0.4.11/src/lib.rs:500:5: this method could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:506:28: this argument (8 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -log-0.4.11/src/lib.rs:506:5: this method could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:520:27: you are deriving `Hash` but have implemented `PartialEq` explicitly -log-0.4.11/src/lib.rs:538:1: you are implementing `Clone` explicitly on a `Copy` type -log-0.4.11/src/lib.rs:653:5: this method could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:661:21: this argument (8 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -log-0.4.11/src/lib.rs:661:5: this method could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:677:44: this `match` has identical arm bodies -log-0.4.11/src/lib.rs:758:5: this method could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:764:5: this method could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:770:5: this method could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:776:5: this method could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:782:5: this method could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:788:5: this method could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:794:5: this method could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:803:5: this method could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:809:5: this method could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:818:5: this method could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:908:5: this method could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:908:5: you should consider adding a `Default` implementation for `RecordBuilder<'a>` -log-0.4.11/src/lib.rs:995:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/backtrack.rs:100:13: redundant field names in struct initialization -regex-1.4.2/src/backtrack.rs:133:17: it looks like the same item is being pushed into this Vec -regex-1.4.2/src/backtrack.rs:145:20: unnecessary boolean `not` operation -regex-1.4.2/src/backtrack.rs:199:13: usage of wildcard import for enum variants -regex-1.4.2/src/backtrack.rs:223:29: redundant field names in struct initialization -regex-1.4.2/src/backtrack.rs:230:66: redundant field names in struct initialization -regex-1.4.2/src/backtrack.rs:284:21: casting `u32` to `u64` may become silently lossy if you later change the type -regex-1.4.2/src/backtrack.rs:287:5: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -regex-1.4.2/src/backtrack.rs:97:13: redundant field names in struct initialization -regex-1.4.2/src/backtrack.rs:98:13: redundant field names in struct initialization -regex-1.4.2/src/backtrack.rs:99:13: redundant field names in struct initialization -regex-1.4.2/src/compile.rs:1000:17: redundant field names in struct initialization -regex-1.4.2/src/compile.rs:103:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/compile.rs:1048:17: you should put `HashMap` between ticks in the documentation -regex-1.4.2/src/compile.rs:1075:26: integer type suffix should be separated by an underscore -regex-1.4.2/src/compile.rs:1089:44: redundant field names in struct initialization -regex-1.4.2/src/compile.rs:1089:54: redundant field names in struct initialization -regex-1.4.2/src/compile.rs:1100:32: long literal lacking separators -regex-1.4.2/src/compile.rs:1101:21: long literal lacking separators -regex-1.4.2/src/compile.rs:1103:18: casting `u8` to `u64` may become silently lossy if you later change the type -regex-1.4.2/src/compile.rs:1104:18: casting `u8` to `u64` may become silently lossy if you later change the type -regex-1.4.2/src/compile.rs:1105:9: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers -regex-1.4.2/src/compile.rs:1132:37: casting `u16` to `u8` may truncate the value -regex-1.4.2/src/compile.rs:1132:55: casting `u16` to `u8` may truncate the value -regex-1.4.2/src/compile.rs:1135:28: casting `u16` to `u8` may truncate the value -regex-1.4.2/src/compile.rs:1135:38: casting `u16` to `u8` may truncate the value -regex-1.4.2/src/compile.rs:113:5: docs for function returning `Result` missing `# Errors` section -regex-1.4.2/src/compile.rs:1146:25: integer type suffix should be separated by an underscore -regex-1.4.2/src/compile.rs:1166:8: casting `u32` to `u64` may become silently lossy if you later change the type -regex-1.4.2/src/compile.rs:136:46: use of `unwrap_or` followed by a function call -regex-1.4.2/src/compile.rs:155:30: redundant closure found -regex-1.4.2/src/compile.rs:157:30: redundant closure found -regex-1.4.2/src/compile.rs:172:42: use of `unwrap_or` followed by a function call -regex-1.4.2/src/compile.rs:180:43: use of `unwrap_or` followed by a function call -regex-1.4.2/src/compile.rs:188:5: this function's return value is unnecessarily wrapped by `Result` -regex-1.4.2/src/compile.rs:190:40: redundant closure found -regex-1.4.2/src/compile.rs:204:53: you should put `MaybeInsts` between ticks in the documentation -regex-1.4.2/src/compile.rs:244:63: you should put `c_concat` between ticks in the documentation -regex-1.4.2/src/compile.rs:251:5: this function has too many lines (111/100) -regex-1.4.2/src/compile.rs:253:13: usage of wildcard import for enum variants -regex-1.4.2/src/compile.rs:375:39: use of `unwrap_or` followed by a function call -regex-1.4.2/src/compile.rs:379:29: redundant field names in struct initialization -regex-1.4.2/src/compile.rs:379:41: redundant field names in struct initialization -regex-1.4.2/src/compile.rs:384:12: unnecessary boolean `not` operation -regex-1.4.2/src/compile.rs:413:56: redundant field names in struct initialization -regex-1.4.2/src/compile.rs:421:45: redundant field names in struct initialization -regex-1.4.2/src/compile.rs:428:51: redundant field names in struct initialization -regex-1.4.2/src/compile.rs:430:29: redundant field names in struct initialization -regex-1.4.2/src/compile.rs:438:5: this function's return value is unnecessarily wrapped by `Result` -regex-1.4.2/src/compile.rs:43:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/compile.rs:43:5: you should consider adding a `Default` implementation for `compile::Compiler` -regex-1.4.2/src/compile.rs:468:5: this function's return value is unnecessarily wrapped by `Result` -regex-1.4.2/src/compile.rs:469:57: redundant field names in struct initialization -regex-1.4.2/src/compile.rs:470:25: redundant field names in struct initialization -regex-1.4.2/src/compile.rs:494:25: redundant field names in struct initialization -regex-1.4.2/src/compile.rs:494:37: redundant field names in struct initialization -regex-1.4.2/src/compile.rs:547:13: usage of wildcard import for enum variants -regex-1.4.2/src/compile.rs:56:57: you should put `size_limit` between ticks in the documentation -regex-1.4.2/src/compile.rs:59:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/compile.rs:637:14: use of `unwrap_or` followed by a function call -regex-1.4.2/src/compile.rs:638:9: use Option::map_or instead of an if let/else -regex-1.4.2/src/compile.rs:661:41: use of `unwrap_or` followed by a function call -regex-1.4.2/src/compile.rs:703:9: you should put `c_function` between ticks in the documentation -regex-1.4.2/src/compile.rs:75:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/compile.rs:786:5: this function's return value is unnecessarily wrapped by `Result` -regex-1.4.2/src/compile.rs:838:21: redundant field names in struct initialization -regex-1.4.2/src/compile.rs:845:21: redundant field names in struct initialization -regex-1.4.2/src/compile.rs:848:13: wildcard match will miss any future added variants -regex-1.4.2/src/compile.rs:84:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/compile.rs:860:41: redundant field names in struct initialization -regex-1.4.2/src/compile.rs:860:55: redundant field names in struct initialization -regex-1.4.2/src/compile.rs:920:39: redundant field names in struct initialization -regex-1.4.2/src/compile.rs:920:51: redundant field names in struct initialization -regex-1.4.2/src/compile.rs:923:49: redundant field names in struct initialization -regex-1.4.2/src/compile.rs:923:61: redundant field names in struct initialization -regex-1.4.2/src/compile.rs:925:59: redundant field names in struct initialization -regex-1.4.2/src/compile.rs:925:71: redundant field names in struct initialization -regex-1.4.2/src/compile.rs:927:43: redundant field names in struct initialization -regex-1.4.2/src/compile.rs:930:41: redundant field names in struct initialization -regex-1.4.2/src/compile.rs:930:53: redundant field names in struct initialization -regex-1.4.2/src/compile.rs:930:67: redundant field names in struct initialization -regex-1.4.2/src/compile.rs:96:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/compile.rs:991:5: this function's return value is unnecessarily wrapped by `Result` -regex-1.4.2/src/dfa.rs:1007:17: binding's name is too similar to existing binding -regex-1.4.2/src/dfa.rs:1010:22: binding's name is too similar to existing binding -regex-1.4.2/src/dfa.rs:1059:13: usage of wildcard import for enum variants -regex-1.4.2/src/dfa.rs:1060:13: usage of wildcard import for enum variants -regex-1.4.2/src/dfa.rs:1084:38: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -regex-1.4.2/src/dfa.rs:1087:38: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -regex-1.4.2/src/dfa.rs:1090:38: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -regex-1.4.2/src/dfa.rs:1093:38: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -regex-1.4.2/src/dfa.rs:1096:38: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -regex-1.4.2/src/dfa.rs:1101:38: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -regex-1.4.2/src/dfa.rs:1104:38: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -regex-1.4.2/src/dfa.rs:1107:38: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -regex-1.4.2/src/dfa.rs:1117:30: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -regex-1.4.2/src/dfa.rs:1120:47: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -regex-1.4.2/src/dfa.rs:1121:30: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -regex-1.4.2/src/dfa.rs:1129:13: you should put `is_match` between ticks in the documentation -regex-1.4.2/src/dfa.rs:1134:13: you should put `is_match` between ticks in the documentation -regex-1.4.2/src/dfa.rs:1185:68: you should put `is_match` between ticks in the documentation -regex-1.4.2/src/dfa.rs:1193:13: usage of wildcard import for enum variants -regex-1.4.2/src/dfa.rs:1244:50: you should put `current_state` between ticks in the documentation -regex-1.4.2/src/dfa.rs:1338:58: you should put `STATE_DEAD` between ticks in the documentation -regex-1.4.2/src/dfa.rs:1339:9: you should put `STATE_UNKNOWN` between ticks in the documentation -regex-1.4.2/src/dfa.rs:1366:25: you should put `STATE_DEAD` between ticks in the documentation -regex-1.4.2/src/dfa.rs:1366:46: you should put `STATE_UNKNOWN` between ticks in the documentation -regex-1.4.2/src/dfa.rs:1367:41: you have declared `#[inline(always)]` on `start_state`. This is usually a bad idea -regex-1.4.2/src/dfa.rs:1380:14: the operation is ineffective. Consider reducing it to `(empty_flags.start as u8)` -regex-1.4.2/src/dfa.rs:1388:15: indexing into a vector may panic -regex-1.4.2/src/dfa.rs:1412:20: unused `self` argument -regex-1.4.2/src/dfa.rs:1438:9: unused `self` argument -regex-1.4.2/src/dfa.rs:1472:9: you should put `StatePtr` between ticks in the documentation -regex-1.4.2/src/dfa.rs:1490:54: casting `i32` to `u8` may lose the sign of the value -regex-1.4.2/src/dfa.rs:1490:54: casting `i32` to `u8` may truncate the value -regex-1.4.2/src/dfa.rs:1521:20: you should put `num_byte_classes` between ticks in the documentation -regex-1.4.2/src/dfa.rs:1529:41: you have declared `#[inline(always)]` on `byte_class`. This is usually a bad idea -regex-1.4.2/src/dfa.rs:1537:14: you should put `byte_class` between ticks in the documentation -regex-1.4.2/src/dfa.rs:1538:41: you have declared `#[inline(always)]` on `u8_class`. This is usually a bad idea -regex-1.4.2/src/dfa.rs:1562:18: you should put `STATE_START` between ticks in the documentation -regex-1.4.2/src/dfa.rs:1614:13: redundant field names in struct initialization -regex-1.4.2/src/dfa.rs:1651:38: redundant field names in struct initialization -regex-1.4.2/src/dfa.rs:1700:17: this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -regex-1.4.2/src/dfa.rs:1701:18: digits of hex or binary literal not grouped by four -regex-1.4.2/src/dfa.rs:1705:19: digits of hex or binary literal not grouped by four -regex-1.4.2/src/dfa.rs:1708:16: this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -regex-1.4.2/src/dfa.rs:1709:18: digits of hex or binary literal not grouped by four -regex-1.4.2/src/dfa.rs:1713:19: digits of hex or binary literal not grouped by four -regex-1.4.2/src/dfa.rs:1716:18: this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -regex-1.4.2/src/dfa.rs:1717:18: digits of hex or binary literal not grouped by four -regex-1.4.2/src/dfa.rs:1721:19: digits of hex or binary literal not grouped by four -regex-1.4.2/src/dfa.rs:1727:14: casting `u8` to `u16` may become silently lossy if you later change the type -regex-1.4.2/src/dfa.rs:1732:15: this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -regex-1.4.2/src/dfa.rs:1736:22: this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -regex-1.4.2/src/dfa.rs:1741:9: match expression looks like `matches!` macro -regex-1.4.2/src/dfa.rs:1747:16: this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -regex-1.4.2/src/dfa.rs:1751:18: casting `u16` to `u8` may truncate the value -regex-1.4.2/src/dfa.rs:1815:38: casting `usize` to `u8` may truncate the value -regex-1.4.2/src/dfa.rs:1821:21: casting `u32` to `u64` may become silently lossy if you later change the type -regex-1.4.2/src/dfa.rs:1824:5: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -regex-1.4.2/src/dfa.rs:1848:5: you should put bare URLs between `<`/`>` or make a proper Markdown link -regex-1.4.2/src/dfa.rs:1850:18: casting `i32` to `u32` may lose the sign of the value -regex-1.4.2/src/dfa.rs:1857:5: you should put bare URLs between `<`/`>` or make a proper Markdown link -regex-1.4.2/src/dfa.rs:1860:17: casting `u32` to `i32` may wrap around the value -regex-1.4.2/src/dfa.rs:1867:5: you should put bare URLs between `<`/`>` or make a proper Markdown link -regex-1.4.2/src/dfa.rs:1870:19: casting `u32` to `u8` may truncate the value -regex-1.4.2/src/dfa.rs:1873:15: casting `u32` to `u8` may truncate the value -regex-1.4.2/src/dfa.rs:1876:5: you should put bare URLs between `<`/`>` or make a proper Markdown link -regex-1.4.2/src/dfa.rs:1882:26: casting `u8` to `u32` may become silently lossy if you later change the type -regex-1.4.2/src/dfa.rs:1884:15: casting `u8` to `u32` may become silently lossy if you later change the type -regex-1.4.2/src/dfa.rs:277:17: casting `u32` to `i32` may wrap around the value -regex-1.4.2/src/dfa.rs:277:31: casting `u32` to `i32` may wrap around the value -regex-1.4.2/src/dfa.rs:295:20: casting `usize` to `i32` may truncate the value on targets with 64-bit wide pointers -regex-1.4.2/src/dfa.rs:295:20: casting `usize` to `i32` may wrap around the value on targets with 32-bit wide pointers -regex-1.4.2/src/dfa.rs:299:21: casting `i32` to `usize` may lose the sign of the value -regex-1.4.2/src/dfa.rs:34:46: you should put bare URLs between `<`/`>` or make a proper Markdown link -regex-1.4.2/src/dfa.rs:398:1: more than 3 bools in a struct -regex-1.4.2/src/dfa.rs:446:41: you have declared `#[inline(always)]` on `forward`. This is usually a bad idea -regex-1.4.2/src/dfa.rs:457:13: redundant field names in struct initialization -regex-1.4.2/src/dfa.rs:459:13: redundant field names in struct initialization -regex-1.4.2/src/dfa.rs:460:13: redundant field names in struct initialization -regex-1.4.2/src/dfa.rs:476:41: you have declared `#[inline(always)]` on `reverse`. This is usually a bad idea -regex-1.4.2/src/dfa.rs:487:13: redundant field names in struct initialization -regex-1.4.2/src/dfa.rs:489:13: redundant field names in struct initialization -regex-1.4.2/src/dfa.rs:490:13: redundant field names in struct initialization -regex-1.4.2/src/dfa.rs:506:41: you have declared `#[inline(always)]` on `forward_many`. This is usually a bad idea -regex-1.4.2/src/dfa.rs:518:13: redundant field names in struct initialization -regex-1.4.2/src/dfa.rs:520:13: redundant field names in struct initialization -regex-1.4.2/src/dfa.rs:554:41: you have declared `#[inline(always)]` on `exec_at`. This is usually a bad idea -regex-1.4.2/src/dfa.rs:555:5: this function has too many lines (101/100) -regex-1.4.2/src/dfa.rs:58:9: usage of wildcard import for enum variants -regex-1.4.2/src/dfa.rs:667:21: binding's name is too similar to existing binding -regex-1.4.2/src/dfa.rs:747:41: you have declared `#[inline(always)]` on `exec_at_reverse`. This is usually a bad idea -regex-1.4.2/src/dfa.rs:795:21: binding's name is too similar to existing binding -regex-1.4.2/src/dfa.rs:848:9: you should put `next_si` between ticks in the documentation -regex-1.4.2/src/dfa.rs:852:41: you have declared `#[inline(always)]` on `next_si`. This is usually a bad idea -regex-1.4.2/src/dfa.rs:885:12: you should put `STATE_DEAD` between ticks in the documentation -regex-1.4.2/src/dfa.rs:889:9: you should put `STATE_UNKNOWN` between ticks in the documentation -regex-1.4.2/src/dfa.rs:897:13: usage of wildcard import for enum variants -regex-1.4.2/src/dfa.rs:979:29: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -regex-1.4.2/src/error.rs:6:1: this seems like a manual implementation of the non-exhaustive pattern -regex-1.4.2/src/exec.rs:1000:14: you should put `captures_nfa` between ticks in the documentation -regex-1.4.2/src/exec.rs:100:1: item name starts with its containing module's name -regex-1.4.2/src/exec.rs:1028:5: this function has too many arguments (9/7) -regex-1.4.2/src/exec.rs:1039:13: usage of wildcard import for enum variants -regex-1.4.2/src/exec.rs:1144:13: usage of wildcard import for enum variants -regex-1.4.2/src/exec.rs:1179:26: this `match` has identical arm bodies -regex-1.4.2/src/exec.rs:122:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/exec.rs:1250:41: you have declared `#[inline(always)]` on `searcher`. This is usually a bad idea -regex-1.4.2/src/exec.rs:1260:41: you have declared `#[inline(always)]` on `searcher_str`. This is usually a bad idea -regex-1.4.2/src/exec.rs:1270:17: you should put `RegexSet` between ticks in the documentation -regex-1.4.2/src/exec.rs:1280:17: you should put `RegexSet` between ticks in the documentation -regex-1.4.2/src/exec.rs:137:9: field assignment outside of initializer for an instance created with Default::default() -regex-1.4.2/src/exec.rs:142:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/exec.rs:158:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/exec.rs:168:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/exec.rs:181:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/exec.rs:195:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/exec.rs:204:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/exec.rs:210:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/exec.rs:245:62: this `if` has identical blocks -regex-1.4.2/src/exec.rs:251:21: unnecessary boolean `not` operation -regex-1.4.2/src/exec.rs:262:60: this `if` has identical blocks -regex-1.4.2/src/exec.rs:268:21: unnecessary boolean `not` operation -regex-1.4.2/src/exec.rs:278:13: redundant field names in struct initialization -regex-1.4.2/src/exec.rs:281:13: redundant field names in struct initialization -regex-1.4.2/src/exec.rs:286:5: docs for function returning `Result` missing `# Errors` section -regex-1.4.2/src/exec.rs:300:30: redundant field names in struct initialization -regex-1.4.2/src/exec.rs:308:17: binding's name is too similar to existing binding -regex-1.4.2/src/exec.rs:329:13: redundant field names in struct initialization -regex-1.4.2/src/exec.rs:330:13: redundant field names in struct initialization -regex-1.4.2/src/exec.rs:331:13: redundant field names in struct initialization -regex-1.4.2/src/exec.rs:334:13: redundant field names in struct initialization -regex-1.4.2/src/exec.rs:340:19: redundant field names in struct initialization -regex-1.4.2/src/exec.rs:344:27: unused `self` argument -regex-1.4.2/src/exec.rs:383:41: you have declared `#[inline(always)]` on `shortest_match_at`. This is usually a bad idea -regex-1.4.2/src/exec.rs:388:41: you have declared `#[inline(always)]` on `is_match_at`. This is usually a bad idea -regex-1.4.2/src/exec.rs:393:41: you have declared `#[inline(always)]` on `find_at`. This is usually a bad idea -regex-1.4.2/src/exec.rs:398:41: you have declared `#[inline(always)]` on `captures_read_at`. This is usually a bad idea -regex-1.4.2/src/exec.rs:425:41: you have declared `#[inline(always)]` on `shortest_match_at`. This is usually a bad idea -regex-1.4.2/src/exec.rs:44:1: item name starts with its containing module's name -regex-1.4.2/src/exec.rs:473:9: you should put `shortest_match(...).is_some` between ticks in the documentation -regex-1.4.2/src/exec.rs:474:41: you have declared `#[inline(always)]` on `is_match_at`. This is usually a bad idea -regex-1.4.2/src/exec.rs:524:41: you have declared `#[inline(always)]` on `find_at`. This is usually a bad idea -regex-1.4.2/src/exec.rs:52:1: item name starts with its containing module's name -regex-1.4.2/src/exec.rs:686:13: usage of wildcard import for enum variants -regex-1.4.2/src/exec.rs:727:13: usage of wildcard import for enum variants -regex-1.4.2/src/exec.rs:767:13: usage of wildcard import for enum variants -regex-1.4.2/src/exec.rs:783:41: you have declared `#[inline(always)]` on `shortest_dfa`. This is usually a bad idea -regex-1.4.2/src/exec.rs:791:41: you have declared `#[inline(always)]` on `shortest_dfa_reverse_suffix`. This is usually a bad idea -regex-1.4.2/src/exec.rs:823:13: usage of wildcard import for enum variants -regex-1.4.2/src/exec.rs:868:13: usage of wildcard import for enum variants -regex-1.4.2/src/exec.rs:897:31: you should put `shortest_nfa(...).is_some` between ticks in the documentation -regex-1.4.2/src/exec.rs:899:9: you should put `shortest_nfa` between ticks in the documentation -regex-1.4.2/src/exec.rs:905:14: you should put `match_nfa` between ticks in the documentation -regex-1.4.2/src/exec.rs:930:14: you should put `shortest_nfa` between ticks in the documentation -regex-1.4.2/src/exec.rs:981:14: you should put `find_nfa` between ticks in the documentation -regex-1.4.2/src/expand.rs:130:22: this call to `as_ref` does nothing -regex-1.4.2/src/expand.rs:185:27: this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -regex-1.4.2/src/expand.rs:186:5: match expression looks like `matches!` macro -regex-1.4.2/src/expand.rs:22:13: calling `push_str()` using a single-character string literal -regex-1.4.2/src/expand.rs:27:23: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -regex-1.4.2/src/expand.rs:30:17: calling `push_str()` using a single-character string literal -regex-1.4.2/src/expand.rs:38:30: called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead -regex-1.4.2/src/expand.rs:42:21: called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead -regex-1.4.2/src/expand.rs:50:1: item name starts with its containing module's name -regex-1.4.2/src/expand.rs:69:23: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -regex-1.4.2/src/expand.rs:80:28: called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead -regex-1.4.2/src/expand.rs:84:21: called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead -regex-1.4.2/src/expand.rs:8:1: item name starts with its containing module's name -regex-1.4.2/src/input.rs:142:1: item name ends with its containing module's name -regex-1.4.2/src/input.rs:146:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/input.rs:15:1: item name starts with its containing module's name -regex-1.4.2/src/input.rs:165:31: redundant field names in struct initialization -regex-1.4.2/src/input.rs:178:13: usage of wildcard import for enum variants -regex-1.4.2/src/input.rs:228:1: item name ends with its containing module's name -regex-1.4.2/src/input.rs:236:21: redundant field names in struct initialization -regex-1.4.2/src/input.rs:236:33: redundant field names in struct initialization -regex-1.4.2/src/input.rs:24:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/input.rs:271:13: usage of wildcard import for enum variants -regex-1.4.2/src/input.rs:29:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/input.rs:362:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/input.rs:370:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/input.rs:371:42: redundant closure found -regex-1.4.2/src/input.rs:37:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/input.rs:388:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/input.rs:42:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/input.rs:47:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/input.rs:53:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/input.rs:58:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/input.rs:63:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/literal/imp.rs:101:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/literal/imp.rs:114:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/literal/imp.rs:127:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/literal/imp.rs:139:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/literal/imp.rs:144:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/literal/imp.rs:149:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/literal/imp.rs:154:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/literal/imp.rs:155:13: usage of wildcard import for enum variants -regex-1.4.2/src/literal/imp.rs:160:30: this `match` has identical arm bodies -regex-1.4.2/src/literal/imp.rs:167:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/literal/imp.rs:168:13: usage of wildcard import for enum variants -regex-1.4.2/src/literal/imp.rs:211:20: redundant else block -regex-1.4.2/src/literal/imp.rs:276:50: this `match` has identical arm bodies -regex-1.4.2/src/literal/imp.rs:342:41: you have declared `#[inline(always)]` on `find`. This is usually a bad idea -regex-1.4.2/src/literal/imp.rs:435:13: redundant field names in struct initialization -regex-1.4.2/src/literal/imp.rs:436:13: redundant field names in struct initialization -regex-1.4.2/src/literal/imp.rs:437:13: redundant field names in struct initialization -regex-1.4.2/src/literal/imp.rs:438:13: redundant field names in struct initialization -regex-1.4.2/src/literal/imp.rs:439:13: redundant field names in struct initialization -regex-1.4.2/src/literal/imp.rs:440:13: redundant field names in struct initialization -regex-1.4.2/src/literal/imp.rs:455:41: you have declared `#[inline(always)]` on `find`. This is usually a bad idea -regex-1.4.2/src/literal/imp.rs:46:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/literal/imp.rs:481:41: you have declared `#[inline(always)]` on `is_suffix`. This is usually a bad idea -regex-1.4.2/src/literal/imp.rs:51:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/literal/imp.rs:579:13: redundant field names in struct initialization -regex-1.4.2/src/literal/imp.rs:57:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/literal/imp.rs:580:13: redundant field names in struct initialization -regex-1.4.2/src/literal/imp.rs:583:13: redundant field names in struct initialization -regex-1.4.2/src/literal/imp.rs:602:9: adding items after statements is confusing, since items exist from the start of the scope -regex-1.4.2/src/literal/imp.rs:622:24: redundant else block -regex-1.4.2/src/literal/imp.rs:62:18: this argument is passed by value, but not consumed in the function body -regex-1.4.2/src/literal/imp.rs:637:24: redundant else block -regex-1.4.2/src/literal/imp.rs:648:9: unneeded `return` statement -regex-1.4.2/src/literal/imp.rs:651:44: you should put `BoyerMooreSearch` between ticks in the documentation -regex-1.4.2/src/literal/imp.rs:65:13: redundant field names in struct initialization -regex-1.4.2/src/literal/imp.rs:68:13: redundant field names in struct initialization -regex-1.4.2/src/literal/imp.rs:783:32: redundant else block -regex-1.4.2/src/literal/imp.rs:786:42: manual saturating arithmetic -regex-1.4.2/src/literal/imp.rs:78:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/literal/imp.rs:84:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/literal/imp.rs:850:20: long literal lacking separators -regex-1.4.2/src/literal/imp.rs:85:13: usage of wildcard import for enum variants -regex-1.4.2/src/pikevm.rs:103:15: redundant field names in struct initialization -regex-1.4.2/src/pikevm.rs:103:52: redundant field names in struct initialization -regex-1.4.2/src/pikevm.rs:114:5: this function has too many arguments (8/7) -regex-1.4.2/src/pikevm.rs:117:13: binding's name is too similar to existing binding -regex-1.4.2/src/pikevm.rs:124:17: binding's name is too similar to existing binding -regex-1.4.2/src/pikevm.rs:220:9: you should put `thread_caps` between ticks in the documentation -regex-1.4.2/src/pikevm.rs:222:16: you should put `at_next` between ticks in the documentation -regex-1.4.2/src/pikevm.rs:223:9: you should put `at_next` between ticks in the documentation -regex-1.4.2/src/pikevm.rs:224:5: this function has too many arguments (8/7) -regex-1.4.2/src/pikevm.rs:234:13: usage of wildcard import for enum variants -regex-1.4.2/src/pikevm.rs:303:13: usage of wildcard import for enum variants -regex-1.4.2/src/pikevm.rs:331:29: this expression mutably borrows a mutable reference. Consider reborrowing -regex-1.4.2/src/pikevm.rs:88:5: this function has too many arguments (8/7) -regex-1.4.2/src/prog.rs:102:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/prog.rs:113:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/prog.rs:120:9: match expression looks like `matches!` macro -regex-1.4.2/src/prog.rs:128:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/prog.rs:134:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/prog.rs:141:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/prog.rs:147:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/prog.rs:164:41: you have declared `#[inline(always)]` on `deref`. This is usually a bad idea -regex-1.4.2/src/prog.rs:172:13: usage of wildcard import for enum variants -regex-1.4.2/src/prog.rs:18:1: more than 3 bools in a struct -regex-1.4.2/src/prog.rs:236:13: using `write!()` with a format string that ends in a single newline -regex-1.4.2/src/prog.rs:300:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/prog.rs:301:9: match expression looks like `matches!` macro -regex-1.4.2/src/prog.rs:382:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/prog.rs:409:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/prog.rs:80:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/prog.rs:80:5: you should consider adding a `Default` implementation for `prog::Program` -regex-1.4.2/src/re_builder.rs:267:17: docs for function returning `Result` missing `# Errors` section -regex-1.4.2/src/re_builder.rs:267:17: docs for function returning `Result` missing `# Errors` section -regex-1.4.2/src/re_builder.rs:4:1: more than 3 bools in a struct -regex-1.4.2/src/re_builder.rs:57:17: this method could have a `#[must_use]` attribute -regex-1.4.2/src/re_builder.rs:57:17: this method could have a `#[must_use]` attribute -regex-1.4.2/src/re_builder.rs:68:17: docs for function returning `Result` missing `# Errors` section -regex-1.4.2/src/re_builder.rs:68:17: docs for function returning `Result` missing `# Errors` section -regex-1.4.2/src/re_bytes.rs:1023:9: called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead -regex-1.4.2/src/re_bytes.rs:1045:9: called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead -regex-1.4.2/src/re_bytes.rs:1100:5: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) -regex-1.4.2/src/re_bytes.rs:1125:5: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) -regex-1.4.2/src/re_bytes.rs:1140:5: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) -regex-1.4.2/src/re_bytes.rs:118:5: docs for function returning `Result` missing `# Errors` section -regex-1.4.2/src/re_bytes.rs:257:13: redundant field names in struct initialization -regex-1.4.2/src/re_bytes.rs:29:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/re_bytes.rs:35:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/re_bytes.rs:42:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/re_bytes.rs:48:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/re_bytes.rs:559:29: you should put `shortest_match` between ticks in the documentation -regex-1.4.2/src/re_bytes.rs:55:33: redundant field names in struct initialization -regex-1.4.2/src/re_bytes.rs:55:47: redundant field names in struct initialization -regex-1.4.2/src/re_bytes.rs:573:29: you should put `is_match` between ticks in the documentation -regex-1.4.2/src/re_bytes.rs:721:13: redundant field names in struct initialization -regex-1.4.2/src/re_bytes.rs:818:5: you should put `CaptureLocations` between ticks in the documentation -regex-1.4.2/src/re_bytes.rs:844:1: item `re_bytes::CaptureLocations` has a public `len` method but no corresponding `is_empty` method -regex-1.4.2/src/re_bytes.rs:850:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/re_bytes.rs:859:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/re_bytes.rs:870:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/re_bytes.rs:892:1: item `re_bytes::Captures<'t>` has a public `len` method but no corresponding `is_empty` method -regex-1.4.2/src/re_bytes.rs:912:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/re_bytes.rs:918:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/re_bytes.rs:927:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/re_bytes.rs:961:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/re_set.rs:108:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/re_set.rs:108:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/re_set.rs:192:13: redundant field names in struct initialization -regex-1.4.2/src/re_set.rs:192:13: redundant field names in struct initialization -regex-1.4.2/src/re_set.rs:269:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/re_set.rs:269:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/re_set.rs:281:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/re_set.rs:281:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/re_set.rs:286:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/re_set.rs:286:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/re_set.rs:295:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/re_set.rs:295:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/re_set.rs:94:5: docs for function returning `Result` missing `# Errors` section -regex-1.4.2/src/re_set.rs:94:5: docs for function returning `Result` missing `# Errors` section -regex-1.4.2/src/re_trait.rs:137:29: redundant field names in struct initialization -regex-1.4.2/src/re_unicode.rs:1025:9: called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead -regex-1.4.2/src/re_unicode.rs:1047:9: called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead -regex-1.4.2/src/re_unicode.rs:1095:13: redundant field names in struct initialization -regex-1.4.2/src/re_unicode.rs:1142:5: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) -regex-1.4.2/src/re_unicode.rs:1167:5: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) -regex-1.4.2/src/re_unicode.rs:174:5: docs for function returning `Result` missing `# Errors` section -regex-1.4.2/src/re_unicode.rs:21:1: this function could have a `#[must_use]` attribute -regex-1.4.2/src/re_unicode.rs:314:13: redundant field names in struct initialization -regex-1.4.2/src/re_unicode.rs:38:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/re_unicode.rs:44:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/re_unicode.rs:51:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/re_unicode.rs:57:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/re_unicode.rs:618:29: you should put `shortest_match` between ticks in the documentation -regex-1.4.2/src/re_unicode.rs:632:29: you should put `is_match` between ticks in the documentation -regex-1.4.2/src/re_unicode.rs:64:33: redundant field names in struct initialization -regex-1.4.2/src/re_unicode.rs:64:47: redundant field names in struct initialization -regex-1.4.2/src/re_unicode.rs:835:5: you should put `CaptureLocations` between ticks in the documentation -regex-1.4.2/src/re_unicode.rs:861:1: item `re_unicode::CaptureLocations` has a public `len` method but no corresponding `is_empty` method -regex-1.4.2/src/re_unicode.rs:867:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/re_unicode.rs:876:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/re_unicode.rs:887:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/re_unicode.rs:909:1: item `re_unicode::Captures<'t>` has a public `len` method but no corresponding `is_empty` method -regex-1.4.2/src/re_unicode.rs:929:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/re_unicode.rs:935:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/re_unicode.rs:944:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/re_unicode.rs:978:5: this method could have a `#[must_use]` attribute -regex-1.4.2/src/sparse.rs:11:37: you should put bare URLs between `<`/`>` or make a proper Markdown link -regex-1.4.2/src/sparse.rs:16:1: item name starts with its containing module's name -regex-1.4.2/src/utf8.rs:100:16: digits of hex or binary literal not grouped by four -regex-1.4.2/src/utf8.rs:103:16: digits of hex or binary literal not grouped by four -regex-1.4.2/src/utf8.rs:106:22: casting `u8` to `u32` may become silently lossy if you later change the type -regex-1.4.2/src/utf8.rs:107:19: casting `u8` to `u32` may become silently lossy if you later change the type -regex-1.4.2/src/utf8.rs:108:19: casting `u8` to `u32` may become silently lossy if you later change the type -regex-1.4.2/src/utf8.rs:109:19: casting `u8` to `u32` may become silently lossy if you later change the type -regex-1.4.2/src/utf8.rs:111:27: long literal lacking separators -regex-1.4.2/src/utf8.rs:121:1: item name ends with its containing module's name -regex-1.4.2/src/utf8.rs:143:24: digits of hex or binary literal not grouped by four -regex-1.4.2/src/utf8.rs:143:9: digits of hex or binary literal not grouped by four -regex-1.4.2/src/utf8.rs:23:1: item name ends with its containing module's name -regex-1.4.2/src/utf8.rs:30:20: digits of hex or binary literal not grouped by four -regex-1.4.2/src/utf8.rs:51:1: item name ends with its containing module's name -regex-1.4.2/src/utf8.rs:58:23: digits of hex or binary literal not grouped by four -regex-1.4.2/src/utf8.rs:58:9: digits of hex or binary literal not grouped by four -regex-1.4.2/src/utf8.rs:63:16: digits of hex or binary literal not grouped by four -regex-1.4.2/src/utf8.rs:66:22: casting `u8` to `u32` may become silently lossy if you later change the type -regex-1.4.2/src/utf8.rs:66:54: casting `u8` to `u32` may become silently lossy if you later change the type -regex-1.4.2/src/utf8.rs:77:16: digits of hex or binary literal not grouped by four -regex-1.4.2/src/utf8.rs:80:16: digits of hex or binary literal not grouped by four -regex-1.4.2/src/utf8.rs:83:22: casting `u8` to `u32` may become silently lossy if you later change the type -regex-1.4.2/src/utf8.rs:84:19: casting `u8` to `u32` may become silently lossy if you later change the type -regex-1.4.2/src/utf8.rs:85:19: casting `u8` to `u32` may become silently lossy if you later change the type -regex-1.4.2/src/utf8.rs:92:23: digits of hex or binary literal not grouped by four -regex-1.4.2/src/utf8.rs:92:9: digits of hex or binary literal not grouped by four -regex-1.4.2/src/utf8.rs:97:16: digits of hex or binary literal not grouped by four +rayon-1.5.0/src/collections/binary_heap.rs:7:5: usage of wildcard import +rayon-1.5.0/src/collections/binary_heap.rs:8:5: usage of wildcard import +rayon-1.5.0/src/collections/btree_map.rs:7:5: usage of wildcard import +rayon-1.5.0/src/collections/btree_map.rs:8:5: usage of wildcard import +rayon-1.5.0/src/collections/btree_set.rs:7:5: usage of wildcard import +rayon-1.5.0/src/collections/btree_set.rs:8:5: usage of wildcard import +rayon-1.5.0/src/collections/hash_map.rs:10:5: usage of wildcard import +rayon-1.5.0/src/collections/hash_map.rs:9:5: usage of wildcard import +rayon-1.5.0/src/collections/hash_set.rs:10:5: usage of wildcard import +rayon-1.5.0/src/collections/hash_set.rs:9:5: usage of wildcard import +rayon-1.5.0/src/collections/linked_list.rs:7:5: usage of wildcard import +rayon-1.5.0/src/collections/linked_list.rs:8:5: usage of wildcard import +rayon-1.5.0/src/collections/mod.rs:59:32: replacing a value of type `T` with `T::default()` is better expressed using `std::mem::take` +rayon-1.5.0/src/collections/vec_deque.rs:8:5: usage of wildcard import +rayon-1.5.0/src/collections/vec_deque.rs:9:5: usage of wildcard import +rayon-1.5.0/src/compile_fail/cannot_collect_filtermap_data.rs:2:1: needless `fn main` in doctest +rayon-1.5.0/src/compile_fail/cannot_zip_filtered_data.rs:2:1: needless `fn main` in doctest +rayon-1.5.0/src/compile_fail/cell_par_iter.rs:2:1: needless `fn main` in doctest +rayon-1.5.0/src/compile_fail/no_send_par_iter.rs:25:1: needless `fn main` in doctest +rayon-1.5.0/src/compile_fail/no_send_par_iter.rs:46:1: needless `fn main` in doctest +rayon-1.5.0/src/compile_fail/no_send_par_iter.rs:4:1: needless `fn main` in doctest +rayon-1.5.0/src/compile_fail/rc_par_iter.rs:2:1: needless `fn main` in doctest +rayon-1.5.0/src/iter/chain.rs:103:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/chain.rs:122:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/chain.rs:128:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/chain.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/chain.rs:221:36: you should put `ExactSizeIterator` between ticks in the documentation +rayon-1.5.0/src/iter/chain.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/chain.rs:51:38: use Option::map_or_else instead of an if let/else +rayon-1.5.0/src/iter/chain.rs:58:14: `a` is being shadowed +rayon-1.5.0/src/iter/chain.rs:58:17: `b` is being shadowed +rayon-1.5.0/src/iter/chain.rs:78:14: `a` is being shadowed +rayon-1.5.0/src/iter/chain.rs:78:17: `b` is being shadowed +rayon-1.5.0/src/iter/chain.rs:97:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/chunks.rs:3:5: usage of wildcard import +rayon-1.5.0/src/iter/chunks.rs:4:5: usage of wildcard import +rayon-1.5.0/src/iter/chunks.rs:77:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/chunks.rs:83:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/cloned.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/cloned.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/cloned.rs:71:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/cloned.rs:75:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/collect/consumer.rs:141:5: you should put `CollectReducer` between ticks in the documentation +rayon-1.5.0/src/iter/collect/consumer.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/collect/consumer.rs:28:5: you should put `CollectResult` between ticks in the documentation +rayon-1.5.0/src/iter/collect/consumer.rs:36:37: generally you want to avoid `&mut &mut _` if possible +rayon-1.5.0/src/iter/collect/consumer.rs:36:37: generally you want to avoid `&mut &mut _` if possible +rayon-1.5.0/src/iter/collect/mod.rs:154:9: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +rayon-1.5.0/src/iter/copied.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/copied.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/copied.rs:71:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/copied.rs:75:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/empty.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/empty.rs:24:1: this function could have a `#[must_use]` attribute +rayon-1.5.0/src/iter/empty.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/enumerate.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/enumerate.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/enumerate.rs:64:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/enumerate.rs:68:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/extend.rs:143:63: I see you're using a LinkedList! Perhaps you meant some other data structure? +rayon-1.5.0/src/iter/extend.rs:182:57: I see you're using a LinkedList! Perhaps you meant some other data structure? +rayon-1.5.0/src/iter/extend.rs:218:32: I see you're using a LinkedList! Perhaps you meant some other data structure? +rayon-1.5.0/src/iter/extend.rs:218:59: I see you're using a LinkedList! Perhaps you meant some other data structure? +rayon-1.5.0/src/iter/extend.rs:25:42: I see you're using a LinkedList! Perhaps you meant some other data structure? +rayon-1.5.0/src/iter/extend.rs:287:62: I see you're using a LinkedList! Perhaps you meant some other data structure? +rayon-1.5.0/src/iter/extend.rs:322:56: I see you're using a LinkedList! Perhaps you meant some other data structure? +rayon-1.5.0/src/iter/extend.rs:41:27: I see you're using a LinkedList! Perhaps you meant some other data structure? +rayon-1.5.0/src/iter/extend.rs:47:30: I see you're using a LinkedList! Perhaps you meant some other data structure? +rayon-1.5.0/src/iter/extend.rs:47:56: I see you're using a LinkedList! Perhaps you meant some other data structure? +rayon-1.5.0/src/iter/extend.rs:47:74: I see you're using a LinkedList! Perhaps you meant some other data structure? +rayon-1.5.0/src/iter/extend.rs:53:29: I see you're using a LinkedList! Perhaps you meant some other data structure? +rayon-1.5.0/src/iter/extend.rs:57:36: I see you're using a LinkedList! Perhaps you meant some other data structure? +rayon-1.5.0/src/iter/extend.rs:59:61: I see you're using a LinkedList! Perhaps you meant some other data structure? +rayon-1.5.0/src/iter/filter.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/filter.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/filter_map.rs:123:9: use Option::map_or instead of an if let/else +rayon-1.5.0/src/iter/filter_map.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/filter_map.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/find.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/find.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/find_first_last/mod.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/find_first_last/mod.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/find_first_last/mod.rs:32:67: you should put `MatchPosition` between ticks in the documentation +rayon-1.5.0/src/iter/flat_map.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/flat_map.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/flat_map_iter.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/flat_map_iter.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/flatten.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/flatten.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/flatten_iter.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/flatten_iter.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/fold.rs:158:13: binding's name is too similar to existing binding +rayon-1.5.0/src/iter/fold.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/fold.rs:204:1: item name starts with its containing module's name +rayon-1.5.0/src/iter/fold.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/for_each.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/for_each.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/inspect.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/inspect.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/inspect.rs:83:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/inspect.rs:88:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/interleave.rs:111:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/interleave.rs:119:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/interleave.rs:195:30: you should put `self.i_len` between ticks in the documentation +rayon-1.5.0/src/iter/interleave.rs:195:43: you should put `self.j_len` between ticks in the documentation +rayon-1.5.0/src/iter/interleave.rs:199:23: you should put `self.i_len` between ticks in the documentation +rayon-1.5.0/src/iter/interleave.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/interleave.rs:200:23: you should put `self.j_len` between ticks in the documentation +rayon-1.5.0/src/iter/interleave.rs:249:41: you should put `DoubleEndedIterator` between ticks in the documentation +rayon-1.5.0/src/iter/interleave.rs:250:5: you should put `ExactSizeIterator` between ticks in the documentation +rayon-1.5.0/src/iter/interleave.rs:263:33: you should put `InterleaveSeq` between ticks in the documentation +rayon-1.5.0/src/iter/interleave.rs:280:17: wildcard match will miss any future added variants +rayon-1.5.0/src/iter/interleave.rs:285:17: wildcard match will miss any future added variants +rayon-1.5.0/src/iter/interleave.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/interleave.rs:313:9: `if` chain can be rewritten with `match` +rayon-1.5.0/src/iter/interleave.rs:82:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/interleave.rs:90:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/interleave_shortest.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/intersperse.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/intersperse.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/intersperse.rs:90:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/intersperse.rs:96:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/len.rs:12:1: item name ends with its containing module's name +rayon-1.5.0/src/iter/len.rs:146:1: item name ends with its containing module's name +rayon-1.5.0/src/iter/len.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/len.rs:200:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/len.rs:205:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/len.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/len.rs:66:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/len.rs:71:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/map.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/map.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/map.rs:84:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/map.rs:89:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/map_with.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/map_with.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/map_with.rs:419:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/map_with.rs:425:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/map_with.rs:90:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/map_with.rs:96:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/mod.rs:1874:24: this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) +rayon-1.5.0/src/iter/mod.rs:2171:1: trait `IndexedParallelIterator` has a `len` method but no (possibly inherited) `is_empty` method +rayon-1.5.0/src/iter/mod.rs:2371:26: this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) +rayon-1.5.0/src/iter/mod.rs:2411:26: this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) +rayon-1.5.0/src/iter/mod.rs:82:5: usage of wildcard import +rayon-1.5.0/src/iter/multizip.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/multizip.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/noop.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/once.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/once.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/panic_fuse.rs:102:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/panic_fuse.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/panic_fuse.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/panic_fuse.rs:98:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/par_bridge.rs:136:28: redundant else block +rayon-1.5.0/src/iter/par_bridge.rs:163:28: redundant else block +rayon-1.5.0/src/iter/plumbing/mod.rs:216:58: you should put `find_first` between ticks in the documentation +rayon-1.5.0/src/iter/plumbing/mod.rs:359:5: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/plumbing/mod.rs:364:5: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/plumbing/mod.rs:399:5: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/plumbing/mod.rs:53:19: you should put `DoubleEndedIterator` between ticks in the documentation +rayon-1.5.0/src/iter/plumbing/mod.rs:53:43: you should put `ExactSizeIterator` between ticks in the documentation +rayon-1.5.0/src/iter/plumbing/mod.rs:54:31: you should put `IntoIterator` between ticks in the documentation +rayon-1.5.0/src/iter/plumbing/mod.rs:55:5: you should put `IntoIterator` between ticks in the documentation +rayon-1.5.0/src/iter/positions.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/positions.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/product.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/reduce.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/repeat.rs:103:1: item name starts with its containing module's name +rayon-1.5.0/src/iter/repeat.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/repeat.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/rev.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/rev.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/rev.rs:63:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/rev.rs:68:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/skip.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/skip.rs:3:5: usage of wildcard import +rayon-1.5.0/src/iter/skip.rs:68:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/skip.rs:73:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/splitter.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/splitter.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/step_by.rs:4:5: usage of wildcard import +rayon-1.5.0/src/iter/step_by.rs:5:5: usage of wildcard import +rayon-1.5.0/src/iter/step_by.rs:73:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/step_by.rs:79:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/sum.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/take.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/take.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/take.rs:67:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/take.rs:72:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/try_fold.rs:190:1: item name starts with its containing module's name +rayon-1.5.0/src/iter/try_fold.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/try_fold.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/try_reduce.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/try_reduce_with.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/unzip.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/unzip.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/update.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/update.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/update.rs:82:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/update.rs:87:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/while_some.rs:130:22: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +rayon-1.5.0/src/iter/while_some.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/while_some.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/zip.rs:102:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/zip.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/zip.rs:2:5: usage of wildcard import +rayon-1.5.0/src/iter/zip.rs:74:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/zip.rs:79:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/zip.rs:97:9: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/iter/zip_eq.rs:1:5: usage of wildcard import +rayon-1.5.0/src/iter/zip_eq.rs:2:5: usage of wildcard import +rayon-1.5.0/src/option.rs:8:5: usage of wildcard import +rayon-1.5.0/src/option.rs:9:5: usage of wildcard import +rayon-1.5.0/src/par_either.rs:1:5: usage of wildcard import +rayon-1.5.0/src/par_either.rs:3:5: usage of wildcard import +rayon-1.5.0/src/private.rs:9:1: item name starts with its containing module's name +rayon-1.5.0/src/range.rs:19:5: usage of wildcard import +rayon-1.5.0/src/range.rs:20:5: usage of wildcard import +rayon-1.5.0/src/range_inclusive.rs:194:9: an inclusive range would be more readable +rayon-1.5.0/src/range_inclusive.rs:194:9: an inclusive range would be more readable +rayon-1.5.0/src/range_inclusive.rs:19:5: usage of wildcard import +rayon-1.5.0/src/range_inclusive.rs:209:9: an inclusive range would be more readable +rayon-1.5.0/src/range_inclusive.rs:209:9: an inclusive range would be more readable +rayon-1.5.0/src/range_inclusive.rs:20:5: usage of wildcard import +rayon-1.5.0/src/range_inclusive.rs:231:9: an inclusive range would be more readable +rayon-1.5.0/src/range_inclusive.rs:231:9: an inclusive range would be more readable +rayon-1.5.0/src/result.rs:8:5: usage of wildcard import +rayon-1.5.0/src/result.rs:9:5: usage of wildcard import +rayon-1.5.0/src/slice/mergesort.rs:102:5: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/slice/mergesort.rs:109:5: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/slice/mergesort.rs:114:5: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/slice/mergesort.rs:211:5: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/slice/mergesort.rs:217:5: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/slice/mergesort.rs:251:5: you should put `TimSort` between ticks in the documentation +rayon-1.5.0/src/slice/mergesort.rs:252:5: you should put bare URLs between `<`/`>` or make a proper Markdown link +rayon-1.5.0/src/slice/mergesort.rs:286:59: you should put `TimSort` between ticks in the documentation +rayon-1.5.0/src/slice/mergesort.rs:333:24: redundant else block +rayon-1.5.0/src/slice/mergesort.rs:513:5: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/slice/mergesort.rs:521:5: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/slice/mergesort.rs:7:5: usage of wildcard import +rayon-1.5.0/src/slice/mergesort.rs:98:5: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/slice/mod.rs:15:5: usage of wildcard import +rayon-1.5.0/src/slice/mod.rs:16:5: usage of wildcard import +rayon-1.5.0/src/slice/mod.rs:17:5: usage of wildcard import +rayon-1.5.0/src/slice/mod.rs:25:1: item name ends with its containing module's name +rayon-1.5.0/src/slice/mod.rs:657:5: this method could have a `#[must_use]` attribute +rayon-1.5.0/src/slice/mod.rs:971:5: this method could have a `#[must_use]` attribute +rayon-1.5.0/src/slice/quicksort.rs:230:36: you should put `BlockQuicksort` between ticks in the documentation +rayon-1.5.0/src/slice/quicksort.rs:233:1: this function has too many lines (117/100) +rayon-1.5.0/src/slice/quicksort.rs:258:26: integer type suffix should be separated by an underscore +rayon-1.5.0/src/slice/quicksort.rs:265:26: integer type suffix should be separated by an underscore +rayon-1.5.0/src/slice/quicksort.rs:268:5: adding items after statements is confusing, since items exist from the start of the scope +rayon-1.5.0/src/slice/quicksort.rs:308:30: casting `usize` to `u8` may truncate the value +rayon-1.5.0/src/slice/quicksort.rs:325:30: casting `usize` to `u8` may truncate the value +rayon-1.5.0/src/slice/quicksort.rs:393:36: casting `u8` to `isize` may wrap around the value on targets with 32-bit wide pointers +rayon-1.5.0/src/slice/quicksort.rs:405:40: casting `u8` to `isize` may wrap around the value on targets with 32-bit wide pointers +rayon-1.5.0/src/slice/quicksort.rs:430:14: `pivot` is being shadowed +rayon-1.5.0/src/slice/quicksort.rs:439:13: `pivot` is being shadowed +rayon-1.5.0/src/slice/quicksort.rs:482:10: `pivot` is being shadowed +rayon-1.5.0/src/slice/quicksort.rs:491:9: `pivot` is being shadowed +rayon-1.5.0/src/slice/quicksort.rs:534:26: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers +rayon-1.5.0/src/slice/quicksort.rs:545:17: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers +rayon-1.5.0/src/slice/quicksort.rs:588:17: the operation is ineffective. Consider reducing it to `len / 4` +rayon-1.5.0/src/slice/quicksort.rs:716:14: `pivot` is being shadowed +rayon-1.5.0/src/split_producer.rs:56:16: use Option::map_or_else instead of an if let/else +rayon-1.5.0/src/split_producer.rs:92:9: use Option::map_or instead of an if let/else +rayon-1.5.0/src/str.rs:16:5: usage of wildcard import +rayon-1.5.0/src/str.rs:17:5: usage of wildcard import +rayon-1.5.0/src/str.rs:18:5: usage of wildcard import +rayon-1.5.0/src/str.rs:25:5: casting `u8` to `i8` may wrap around the value +rayon-1.5.0/src/str.rs:715:9: stripping a suffix manually +rayon-1.5.0/src/string.rs:5:5: usage of wildcard import +rayon-1.5.0/src/vec.rs:137:12: length comparison to zero +rayon-1.5.0/src/vec.rs:8:5: usage of wildcard import +rayon-1.5.0/src/vec.rs:9:5: usage of wildcard import +regex-1.3.2/src/backtrack.rs:100:13: redundant field names in struct initialization +regex-1.3.2/src/backtrack.rs:133:17: it looks like the same item is being pushed into this Vec +regex-1.3.2/src/backtrack.rs:145:20: unnecessary boolean `not` operation +regex-1.3.2/src/backtrack.rs:199:13: usage of wildcard import for enum variants +regex-1.3.2/src/backtrack.rs:223:29: redundant field names in struct initialization +regex-1.3.2/src/backtrack.rs:230:66: redundant field names in struct initialization +regex-1.3.2/src/backtrack.rs:284:21: casting `u32` to `u64` may become silently lossy if you later change the type +regex-1.3.2/src/backtrack.rs:287:5: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers +regex-1.3.2/src/backtrack.rs:97:13: redundant field names in struct initialization +regex-1.3.2/src/backtrack.rs:98:13: redundant field names in struct initialization +regex-1.3.2/src/backtrack.rs:99:13: redundant field names in struct initialization +regex-1.3.2/src/compile.rs:1005:32: long literal lacking separators +regex-1.3.2/src/compile.rs:1006:21: long literal lacking separators +regex-1.3.2/src/compile.rs:1008:18: casting `u8` to `u64` may become silently lossy if you later change the type +regex-1.3.2/src/compile.rs:1009:18: casting `u8` to `u64` may become silently lossy if you later change the type +regex-1.3.2/src/compile.rs:1010:9: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers +regex-1.3.2/src/compile.rs:102:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/compile.rs:1037:37: casting `u16` to `u8` may truncate the value +regex-1.3.2/src/compile.rs:1037:55: casting `u16` to `u8` may truncate the value +regex-1.3.2/src/compile.rs:1040:28: casting `u16` to `u8` may truncate the value +regex-1.3.2/src/compile.rs:1040:38: casting `u16` to `u8` may truncate the value +regex-1.3.2/src/compile.rs:1051:25: integer type suffix should be separated by an underscore +regex-1.3.2/src/compile.rs:1071:8: casting `u32` to `u64` may become silently lossy if you later change the type +regex-1.3.2/src/compile.rs:112:5: docs for function returning `Result` missing `# Errors` section +regex-1.3.2/src/compile.rs:154:30: redundant closure found +regex-1.3.2/src/compile.rs:156:30: redundant closure found +regex-1.3.2/src/compile.rs:185:5: this function's return value is unnecessarily wrapped by `Result` +regex-1.3.2/src/compile.rs:187:40: redundant closure found +regex-1.3.2/src/compile.rs:201:53: you should put `MaybeInsts` between ticks in the documentation +regex-1.3.2/src/compile.rs:241:63: you should put `c_concat` between ticks in the documentation +regex-1.3.2/src/compile.rs:245:5: this function has too many lines (111/100) +regex-1.3.2/src/compile.rs:247:13: usage of wildcard import for enum variants +regex-1.3.2/src/compile.rs:373:24: redundant field names in struct initialization +regex-1.3.2/src/compile.rs:373:36: redundant field names in struct initialization +regex-1.3.2/src/compile.rs:378:12: unnecessary boolean `not` operation +regex-1.3.2/src/compile.rs:400:37: redundant field names in struct initialization +regex-1.3.2/src/compile.rs:407:51: redundant field names in struct initialization +regex-1.3.2/src/compile.rs:409:24: redundant field names in struct initialization +regex-1.3.2/src/compile.rs:417:5: this function's return value is unnecessarily wrapped by `Result` +regex-1.3.2/src/compile.rs:42:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/compile.rs:42:5: you should consider adding a `Default` implementation for `compile::Compiler` +regex-1.3.2/src/compile.rs:444:5: this function's return value is unnecessarily wrapped by `Result` +regex-1.3.2/src/compile.rs:445:57: redundant field names in struct initialization +regex-1.3.2/src/compile.rs:446:20: redundant field names in struct initialization +regex-1.3.2/src/compile.rs:466:20: redundant field names in struct initialization +regex-1.3.2/src/compile.rs:466:32: redundant field names in struct initialization +regex-1.3.2/src/compile.rs:519:13: usage of wildcard import for enum variants +regex-1.3.2/src/compile.rs:55:57: you should put `size_limit` between ticks in the documentation +regex-1.3.2/src/compile.rs:58:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/compile.rs:748:41: redundant field names in struct initialization +regex-1.3.2/src/compile.rs:74:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/compile.rs:751:54: redundant field names in struct initialization +regex-1.3.2/src/compile.rs:765:41: redundant field names in struct initialization +regex-1.3.2/src/compile.rs:765:55: redundant field names in struct initialization +regex-1.3.2/src/compile.rs:825:39: redundant field names in struct initialization +regex-1.3.2/src/compile.rs:825:51: redundant field names in struct initialization +regex-1.3.2/src/compile.rs:828:49: redundant field names in struct initialization +regex-1.3.2/src/compile.rs:828:61: redundant field names in struct initialization +regex-1.3.2/src/compile.rs:830:59: redundant field names in struct initialization +regex-1.3.2/src/compile.rs:830:71: redundant field names in struct initialization +regex-1.3.2/src/compile.rs:832:43: redundant field names in struct initialization +regex-1.3.2/src/compile.rs:835:41: redundant field names in struct initialization +regex-1.3.2/src/compile.rs:835:53: redundant field names in struct initialization +regex-1.3.2/src/compile.rs:835:67: redundant field names in struct initialization +regex-1.3.2/src/compile.rs:83:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/compile.rs:896:5: this function's return value is unnecessarily wrapped by `Result` +regex-1.3.2/src/compile.rs:905:17: redundant field names in struct initialization +regex-1.3.2/src/compile.rs:953:17: you should put `HashMap` between ticks in the documentation +regex-1.3.2/src/compile.rs:95:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/compile.rs:980:26: integer type suffix should be separated by an underscore +regex-1.3.2/src/compile.rs:994:44: redundant field names in struct initialization +regex-1.3.2/src/compile.rs:994:54: redundant field names in struct initialization +regex-1.3.2/src/dfa.rs:1007:17: binding's name is too similar to existing binding +regex-1.3.2/src/dfa.rs:1010:22: binding's name is too similar to existing binding +regex-1.3.2/src/dfa.rs:1059:13: usage of wildcard import for enum variants +regex-1.3.2/src/dfa.rs:1060:13: usage of wildcard import for enum variants +regex-1.3.2/src/dfa.rs:1084:38: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers +regex-1.3.2/src/dfa.rs:1087:38: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers +regex-1.3.2/src/dfa.rs:1090:38: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers +regex-1.3.2/src/dfa.rs:1093:38: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers +regex-1.3.2/src/dfa.rs:1096:38: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers +regex-1.3.2/src/dfa.rs:1101:38: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers +regex-1.3.2/src/dfa.rs:1104:38: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers +regex-1.3.2/src/dfa.rs:1107:38: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers +regex-1.3.2/src/dfa.rs:1117:30: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers +regex-1.3.2/src/dfa.rs:1120:47: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers +regex-1.3.2/src/dfa.rs:1121:30: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers +regex-1.3.2/src/dfa.rs:1129:13: you should put `is_match` between ticks in the documentation +regex-1.3.2/src/dfa.rs:1134:13: you should put `is_match` between ticks in the documentation +regex-1.3.2/src/dfa.rs:1185:68: you should put `is_match` between ticks in the documentation +regex-1.3.2/src/dfa.rs:1193:13: usage of wildcard import for enum variants +regex-1.3.2/src/dfa.rs:1244:50: you should put `current_state` between ticks in the documentation +regex-1.3.2/src/dfa.rs:1338:58: you should put `STATE_DEAD` between ticks in the documentation +regex-1.3.2/src/dfa.rs:1339:9: you should put `STATE_UNKNOWN` between ticks in the documentation +regex-1.3.2/src/dfa.rs:1366:25: you should put `STATE_DEAD` between ticks in the documentation +regex-1.3.2/src/dfa.rs:1366:46: you should put `STATE_UNKNOWN` between ticks in the documentation +regex-1.3.2/src/dfa.rs:1367:41: you have declared `#[inline(always)]` on `start_state`. This is usually a bad idea +regex-1.3.2/src/dfa.rs:1380:14: the operation is ineffective. Consider reducing it to `(empty_flags.start as u8)` +regex-1.3.2/src/dfa.rs:1388:15: indexing into a vector may panic +regex-1.3.2/src/dfa.rs:1412:20: unused `self` argument +regex-1.3.2/src/dfa.rs:1438:9: unused `self` argument +regex-1.3.2/src/dfa.rs:1472:9: you should put `StatePtr` between ticks in the documentation +regex-1.3.2/src/dfa.rs:1490:54: casting `i32` to `u8` may lose the sign of the value +regex-1.3.2/src/dfa.rs:1490:54: casting `i32` to `u8` may truncate the value +regex-1.3.2/src/dfa.rs:1521:20: you should put `num_byte_classes` between ticks in the documentation +regex-1.3.2/src/dfa.rs:1529:41: you have declared `#[inline(always)]` on `byte_class`. This is usually a bad idea +regex-1.3.2/src/dfa.rs:1537:14: you should put `byte_class` between ticks in the documentation +regex-1.3.2/src/dfa.rs:1538:41: you have declared `#[inline(always)]` on `u8_class`. This is usually a bad idea +regex-1.3.2/src/dfa.rs:1562:18: you should put `STATE_START` between ticks in the documentation +regex-1.3.2/src/dfa.rs:1614:13: redundant field names in struct initialization +regex-1.3.2/src/dfa.rs:1651:38: redundant field names in struct initialization +regex-1.3.2/src/dfa.rs:1700:17: this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) +regex-1.3.2/src/dfa.rs:1701:18: digits of hex or binary literal not grouped by four +regex-1.3.2/src/dfa.rs:1705:19: digits of hex or binary literal not grouped by four +regex-1.3.2/src/dfa.rs:1708:16: this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) +regex-1.3.2/src/dfa.rs:1709:18: digits of hex or binary literal not grouped by four +regex-1.3.2/src/dfa.rs:1713:19: digits of hex or binary literal not grouped by four +regex-1.3.2/src/dfa.rs:1716:18: this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) +regex-1.3.2/src/dfa.rs:1717:18: digits of hex or binary literal not grouped by four +regex-1.3.2/src/dfa.rs:1721:19: digits of hex or binary literal not grouped by four +regex-1.3.2/src/dfa.rs:1727:14: casting `u8` to `u16` may become silently lossy if you later change the type +regex-1.3.2/src/dfa.rs:1732:15: this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) +regex-1.3.2/src/dfa.rs:1736:22: this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) +regex-1.3.2/src/dfa.rs:1741:9: match expression looks like `matches!` macro +regex-1.3.2/src/dfa.rs:1747:16: this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) +regex-1.3.2/src/dfa.rs:1751:18: casting `u16` to `u8` may truncate the value +regex-1.3.2/src/dfa.rs:1815:38: casting `usize` to `u8` may truncate the value +regex-1.3.2/src/dfa.rs:1821:21: casting `u32` to `u64` may become silently lossy if you later change the type +regex-1.3.2/src/dfa.rs:1824:5: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers +regex-1.3.2/src/dfa.rs:1848:5: you should put bare URLs between `<`/`>` or make a proper Markdown link +regex-1.3.2/src/dfa.rs:1850:18: casting `i32` to `u32` may lose the sign of the value +regex-1.3.2/src/dfa.rs:1857:5: you should put bare URLs between `<`/`>` or make a proper Markdown link +regex-1.3.2/src/dfa.rs:1860:17: casting `u32` to `i32` may wrap around the value +regex-1.3.2/src/dfa.rs:1867:5: you should put bare URLs between `<`/`>` or make a proper Markdown link +regex-1.3.2/src/dfa.rs:1870:19: casting `u32` to `u8` may truncate the value +regex-1.3.2/src/dfa.rs:1873:15: casting `u32` to `u8` may truncate the value +regex-1.3.2/src/dfa.rs:1876:5: you should put bare URLs between `<`/`>` or make a proper Markdown link +regex-1.3.2/src/dfa.rs:1882:26: casting `u8` to `u32` may become silently lossy if you later change the type +regex-1.3.2/src/dfa.rs:1884:15: casting `u8` to `u32` may become silently lossy if you later change the type +regex-1.3.2/src/dfa.rs:277:17: casting `u32` to `i32` may wrap around the value +regex-1.3.2/src/dfa.rs:277:31: casting `u32` to `i32` may wrap around the value +regex-1.3.2/src/dfa.rs:295:20: casting `usize` to `i32` may truncate the value on targets with 64-bit wide pointers +regex-1.3.2/src/dfa.rs:295:20: casting `usize` to `i32` may wrap around the value on targets with 32-bit wide pointers +regex-1.3.2/src/dfa.rs:299:21: casting `i32` to `usize` may lose the sign of the value +regex-1.3.2/src/dfa.rs:34:46: you should put bare URLs between `<`/`>` or make a proper Markdown link +regex-1.3.2/src/dfa.rs:398:1: more than 3 bools in a struct +regex-1.3.2/src/dfa.rs:446:41: you have declared `#[inline(always)]` on `forward`. This is usually a bad idea +regex-1.3.2/src/dfa.rs:457:13: redundant field names in struct initialization +regex-1.3.2/src/dfa.rs:459:13: redundant field names in struct initialization +regex-1.3.2/src/dfa.rs:460:13: redundant field names in struct initialization +regex-1.3.2/src/dfa.rs:476:41: you have declared `#[inline(always)]` on `reverse`. This is usually a bad idea +regex-1.3.2/src/dfa.rs:487:13: redundant field names in struct initialization +regex-1.3.2/src/dfa.rs:489:13: redundant field names in struct initialization +regex-1.3.2/src/dfa.rs:490:13: redundant field names in struct initialization +regex-1.3.2/src/dfa.rs:506:41: you have declared `#[inline(always)]` on `forward_many`. This is usually a bad idea +regex-1.3.2/src/dfa.rs:518:13: redundant field names in struct initialization +regex-1.3.2/src/dfa.rs:520:13: redundant field names in struct initialization +regex-1.3.2/src/dfa.rs:554:41: you have declared `#[inline(always)]` on `exec_at`. This is usually a bad idea +regex-1.3.2/src/dfa.rs:555:5: this function has too many lines (101/100) +regex-1.3.2/src/dfa.rs:58:9: usage of wildcard import for enum variants +regex-1.3.2/src/dfa.rs:667:21: binding's name is too similar to existing binding +regex-1.3.2/src/dfa.rs:747:41: you have declared `#[inline(always)]` on `exec_at_reverse`. This is usually a bad idea +regex-1.3.2/src/dfa.rs:795:21: binding's name is too similar to existing binding +regex-1.3.2/src/dfa.rs:848:9: you should put `next_si` between ticks in the documentation +regex-1.3.2/src/dfa.rs:852:41: you have declared `#[inline(always)]` on `next_si`. This is usually a bad idea +regex-1.3.2/src/dfa.rs:885:12: you should put `STATE_DEAD` between ticks in the documentation +regex-1.3.2/src/dfa.rs:889:9: you should put `STATE_UNKNOWN` between ticks in the documentation +regex-1.3.2/src/dfa.rs:897:13: usage of wildcard import for enum variants +regex-1.3.2/src/dfa.rs:979:29: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers +regex-1.3.2/src/error.rs:6:1: this seems like a manual implementation of the non-exhaustive pattern +regex-1.3.2/src/exec.rs:1000:14: you should put `captures_nfa` between ticks in the documentation +regex-1.3.2/src/exec.rs:100:1: item name starts with its containing module's name +regex-1.3.2/src/exec.rs:1028:5: this function has too many arguments (9/7) +regex-1.3.2/src/exec.rs:1039:13: usage of wildcard import for enum variants +regex-1.3.2/src/exec.rs:1144:13: usage of wildcard import for enum variants +regex-1.3.2/src/exec.rs:1179:26: this `match` has identical arm bodies +regex-1.3.2/src/exec.rs:122:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/exec.rs:1250:41: you have declared `#[inline(always)]` on `searcher`. This is usually a bad idea +regex-1.3.2/src/exec.rs:1260:41: you have declared `#[inline(always)]` on `searcher_str`. This is usually a bad idea +regex-1.3.2/src/exec.rs:1270:17: you should put `RegexSet` between ticks in the documentation +regex-1.3.2/src/exec.rs:1280:17: you should put `RegexSet` between ticks in the documentation +regex-1.3.2/src/exec.rs:137:9: field assignment outside of initializer for an instance created with Default::default() +regex-1.3.2/src/exec.rs:142:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/exec.rs:158:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/exec.rs:168:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/exec.rs:181:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/exec.rs:195:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/exec.rs:204:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/exec.rs:210:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/exec.rs:245:62: this `if` has identical blocks +regex-1.3.2/src/exec.rs:251:21: unnecessary boolean `not` operation +regex-1.3.2/src/exec.rs:262:60: this `if` has identical blocks +regex-1.3.2/src/exec.rs:268:21: unnecessary boolean `not` operation +regex-1.3.2/src/exec.rs:278:13: redundant field names in struct initialization +regex-1.3.2/src/exec.rs:281:13: redundant field names in struct initialization +regex-1.3.2/src/exec.rs:286:5: docs for function returning `Result` missing `# Errors` section +regex-1.3.2/src/exec.rs:300:30: redundant field names in struct initialization +regex-1.3.2/src/exec.rs:308:17: binding's name is too similar to existing binding +regex-1.3.2/src/exec.rs:329:13: redundant field names in struct initialization +regex-1.3.2/src/exec.rs:330:13: redundant field names in struct initialization +regex-1.3.2/src/exec.rs:331:13: redundant field names in struct initialization +regex-1.3.2/src/exec.rs:334:13: redundant field names in struct initialization +regex-1.3.2/src/exec.rs:340:19: redundant field names in struct initialization +regex-1.3.2/src/exec.rs:344:27: unused `self` argument +regex-1.3.2/src/exec.rs:383:41: you have declared `#[inline(always)]` on `shortest_match_at`. This is usually a bad idea +regex-1.3.2/src/exec.rs:388:41: you have declared `#[inline(always)]` on `is_match_at`. This is usually a bad idea +regex-1.3.2/src/exec.rs:393:41: you have declared `#[inline(always)]` on `find_at`. This is usually a bad idea +regex-1.3.2/src/exec.rs:398:41: you have declared `#[inline(always)]` on `captures_read_at`. This is usually a bad idea +regex-1.3.2/src/exec.rs:425:41: you have declared `#[inline(always)]` on `shortest_match_at`. This is usually a bad idea +regex-1.3.2/src/exec.rs:44:1: item name starts with its containing module's name +regex-1.3.2/src/exec.rs:473:9: you should put `shortest_match(...).is_some` between ticks in the documentation +regex-1.3.2/src/exec.rs:474:41: you have declared `#[inline(always)]` on `is_match_at`. This is usually a bad idea +regex-1.3.2/src/exec.rs:524:41: you have declared `#[inline(always)]` on `find_at`. This is usually a bad idea +regex-1.3.2/src/exec.rs:52:1: item name starts with its containing module's name +regex-1.3.2/src/exec.rs:686:13: usage of wildcard import for enum variants +regex-1.3.2/src/exec.rs:727:13: usage of wildcard import for enum variants +regex-1.3.2/src/exec.rs:767:13: usage of wildcard import for enum variants +regex-1.3.2/src/exec.rs:783:41: you have declared `#[inline(always)]` on `shortest_dfa`. This is usually a bad idea +regex-1.3.2/src/exec.rs:791:41: you have declared `#[inline(always)]` on `shortest_dfa_reverse_suffix`. This is usually a bad idea +regex-1.3.2/src/exec.rs:823:13: usage of wildcard import for enum variants +regex-1.3.2/src/exec.rs:868:13: usage of wildcard import for enum variants +regex-1.3.2/src/exec.rs:897:31: you should put `shortest_nfa(...).is_some` between ticks in the documentation +regex-1.3.2/src/exec.rs:899:9: you should put `shortest_nfa` between ticks in the documentation +regex-1.3.2/src/exec.rs:905:14: you should put `match_nfa` between ticks in the documentation +regex-1.3.2/src/exec.rs:930:14: you should put `shortest_nfa` between ticks in the documentation +regex-1.3.2/src/exec.rs:981:14: you should put `find_nfa` between ticks in the documentation +regex-1.3.2/src/expand.rs:170:27: this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) +regex-1.3.2/src/expand.rs:171:5: match expression looks like `matches!` macro +regex-1.3.2/src/expand.rs:22:13: calling `push_str()` using a single-character string literal +regex-1.3.2/src/expand.rs:27:23: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +regex-1.3.2/src/expand.rs:30:17: calling `push_str()` using a single-character string literal +regex-1.3.2/src/expand.rs:38:30: called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead +regex-1.3.2/src/expand.rs:42:21: called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead +regex-1.3.2/src/expand.rs:50:1: item name starts with its containing module's name +regex-1.3.2/src/expand.rs:69:23: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +regex-1.3.2/src/expand.rs:80:28: called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead +regex-1.3.2/src/expand.rs:84:21: called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead +regex-1.3.2/src/expand.rs:8:1: item name starts with its containing module's name +regex-1.3.2/src/input.rs:142:1: item name ends with its containing module's name +regex-1.3.2/src/input.rs:146:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/input.rs:15:1: item name starts with its containing module's name +regex-1.3.2/src/input.rs:165:31: redundant field names in struct initialization +regex-1.3.2/src/input.rs:178:13: usage of wildcard import for enum variants +regex-1.3.2/src/input.rs:228:1: item name ends with its containing module's name +regex-1.3.2/src/input.rs:236:21: redundant field names in struct initialization +regex-1.3.2/src/input.rs:236:33: redundant field names in struct initialization +regex-1.3.2/src/input.rs:24:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/input.rs:271:13: usage of wildcard import for enum variants +regex-1.3.2/src/input.rs:29:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/input.rs:362:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/input.rs:370:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/input.rs:371:42: redundant closure found +regex-1.3.2/src/input.rs:37:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/input.rs:388:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/input.rs:42:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/input.rs:47:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/input.rs:53:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/input.rs:58:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/input.rs:63:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/literal/imp.rs:101:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/literal/imp.rs:114:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/literal/imp.rs:127:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/literal/imp.rs:139:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/literal/imp.rs:144:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/literal/imp.rs:149:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/literal/imp.rs:154:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/literal/imp.rs:155:13: usage of wildcard import for enum variants +regex-1.3.2/src/literal/imp.rs:160:30: this `match` has identical arm bodies +regex-1.3.2/src/literal/imp.rs:167:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/literal/imp.rs:168:13: usage of wildcard import for enum variants +regex-1.3.2/src/literal/imp.rs:211:20: redundant else block +regex-1.3.2/src/literal/imp.rs:276:50: this `match` has identical arm bodies +regex-1.3.2/src/literal/imp.rs:342:41: you have declared `#[inline(always)]` on `find`. This is usually a bad idea +regex-1.3.2/src/literal/imp.rs:435:13: redundant field names in struct initialization +regex-1.3.2/src/literal/imp.rs:436:13: redundant field names in struct initialization +regex-1.3.2/src/literal/imp.rs:437:13: redundant field names in struct initialization +regex-1.3.2/src/literal/imp.rs:438:13: redundant field names in struct initialization +regex-1.3.2/src/literal/imp.rs:439:13: redundant field names in struct initialization +regex-1.3.2/src/literal/imp.rs:440:13: redundant field names in struct initialization +regex-1.3.2/src/literal/imp.rs:455:41: you have declared `#[inline(always)]` on `find`. This is usually a bad idea +regex-1.3.2/src/literal/imp.rs:46:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/literal/imp.rs:481:41: you have declared `#[inline(always)]` on `is_suffix`. This is usually a bad idea +regex-1.3.2/src/literal/imp.rs:51:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/literal/imp.rs:579:13: redundant field names in struct initialization +regex-1.3.2/src/literal/imp.rs:57:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/literal/imp.rs:580:13: redundant field names in struct initialization +regex-1.3.2/src/literal/imp.rs:583:13: redundant field names in struct initialization +regex-1.3.2/src/literal/imp.rs:602:9: adding items after statements is confusing, since items exist from the start of the scope +regex-1.3.2/src/literal/imp.rs:622:24: redundant else block +regex-1.3.2/src/literal/imp.rs:62:18: this argument is passed by value, but not consumed in the function body +regex-1.3.2/src/literal/imp.rs:637:24: redundant else block +regex-1.3.2/src/literal/imp.rs:648:9: unneeded `return` statement +regex-1.3.2/src/literal/imp.rs:651:44: you should put `BoyerMooreSearch` between ticks in the documentation +regex-1.3.2/src/literal/imp.rs:65:13: redundant field names in struct initialization +regex-1.3.2/src/literal/imp.rs:68:13: redundant field names in struct initialization +regex-1.3.2/src/literal/imp.rs:783:32: redundant else block +regex-1.3.2/src/literal/imp.rs:786:42: manual saturating arithmetic +regex-1.3.2/src/literal/imp.rs:78:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/literal/imp.rs:84:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/literal/imp.rs:850:20: long literal lacking separators +regex-1.3.2/src/literal/imp.rs:85:13: usage of wildcard import for enum variants +regex-1.3.2/src/pikevm.rs:103:15: redundant field names in struct initialization +regex-1.3.2/src/pikevm.rs:103:52: redundant field names in struct initialization +regex-1.3.2/src/pikevm.rs:114:5: this function has too many arguments (8/7) +regex-1.3.2/src/pikevm.rs:117:13: binding's name is too similar to existing binding +regex-1.3.2/src/pikevm.rs:124:17: binding's name is too similar to existing binding +regex-1.3.2/src/pikevm.rs:220:9: you should put `thread_caps` between ticks in the documentation +regex-1.3.2/src/pikevm.rs:222:16: you should put `at_next` between ticks in the documentation +regex-1.3.2/src/pikevm.rs:223:9: you should put `at_next` between ticks in the documentation +regex-1.3.2/src/pikevm.rs:224:5: this function has too many arguments (8/7) +regex-1.3.2/src/pikevm.rs:234:13: usage of wildcard import for enum variants +regex-1.3.2/src/pikevm.rs:303:13: usage of wildcard import for enum variants +regex-1.3.2/src/pikevm.rs:331:29: this expression mutably borrows a mutable reference. Consider reborrowing +regex-1.3.2/src/pikevm.rs:88:5: this function has too many arguments (8/7) +regex-1.3.2/src/prog.rs:102:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/prog.rs:113:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/prog.rs:120:9: match expression looks like `matches!` macro +regex-1.3.2/src/prog.rs:128:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/prog.rs:134:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/prog.rs:141:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/prog.rs:147:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/prog.rs:164:41: you have declared `#[inline(always)]` on `deref`. This is usually a bad idea +regex-1.3.2/src/prog.rs:172:13: usage of wildcard import for enum variants +regex-1.3.2/src/prog.rs:18:1: more than 3 bools in a struct +regex-1.3.2/src/prog.rs:236:13: using `write!()` with a format string that ends in a single newline +regex-1.3.2/src/prog.rs:300:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/prog.rs:301:9: match expression looks like `matches!` macro +regex-1.3.2/src/prog.rs:382:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/prog.rs:409:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/prog.rs:80:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/prog.rs:80:5: you should consider adding a `Default` implementation for `prog::Program` +regex-1.3.2/src/re_builder.rs:267:17: docs for function returning `Result` missing `# Errors` section +regex-1.3.2/src/re_builder.rs:267:17: docs for function returning `Result` missing `# Errors` section +regex-1.3.2/src/re_builder.rs:4:1: more than 3 bools in a struct +regex-1.3.2/src/re_builder.rs:57:17: this method could have a `#[must_use]` attribute +regex-1.3.2/src/re_builder.rs:57:17: this method could have a `#[must_use]` attribute +regex-1.3.2/src/re_builder.rs:68:17: docs for function returning `Result` missing `# Errors` section +regex-1.3.2/src/re_builder.rs:68:17: docs for function returning `Result` missing `# Errors` section +regex-1.3.2/src/re_bytes.rs:1017:9: called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead +regex-1.3.2/src/re_bytes.rs:1039:9: called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead +regex-1.3.2/src/re_bytes.rs:1093:5: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) +regex-1.3.2/src/re_bytes.rs:1118:5: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) +regex-1.3.2/src/re_bytes.rs:1133:5: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) +regex-1.3.2/src/re_bytes.rs:118:5: docs for function returning `Result` missing `# Errors` section +regex-1.3.2/src/re_bytes.rs:256:13: redundant field names in struct initialization +regex-1.3.2/src/re_bytes.rs:29:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/re_bytes.rs:35:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/re_bytes.rs:42:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/re_bytes.rs:48:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/re_bytes.rs:558:29: you should put `shortest_match` between ticks in the documentation +regex-1.3.2/src/re_bytes.rs:55:33: redundant field names in struct initialization +regex-1.3.2/src/re_bytes.rs:55:47: redundant field names in struct initialization +regex-1.3.2/src/re_bytes.rs:572:29: you should put `is_match` between ticks in the documentation +regex-1.3.2/src/re_bytes.rs:720:13: redundant field names in struct initialization +regex-1.3.2/src/re_bytes.rs:817:5: you should put `CaptureLocations` between ticks in the documentation +regex-1.3.2/src/re_bytes.rs:843:1: item `re_bytes::CaptureLocations` has a public `len` method but no corresponding `is_empty` method +regex-1.3.2/src/re_bytes.rs:849:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/re_bytes.rs:858:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/re_bytes.rs:869:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/re_bytes.rs:891:1: item `re_bytes::Captures<'t>` has a public `len` method but no corresponding `is_empty` method +regex-1.3.2/src/re_bytes.rs:911:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/re_bytes.rs:917:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/re_bytes.rs:926:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/re_bytes.rs:955:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/re_set.rs:179:13: redundant field names in struct initialization +regex-1.3.2/src/re_set.rs:179:13: redundant field names in struct initialization +regex-1.3.2/src/re_set.rs:251:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/re_set.rs:251:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/re_set.rs:263:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/re_set.rs:263:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/re_set.rs:268:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/re_set.rs:268:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/re_set.rs:277:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/re_set.rs:277:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/re_set.rs:94:5: docs for function returning `Result` missing `# Errors` section +regex-1.3.2/src/re_set.rs:94:5: docs for function returning `Result` missing `# Errors` section +regex-1.3.2/src/re_trait.rs:136:29: redundant field names in struct initialization +regex-1.3.2/src/re_unicode.rs:1019:9: called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead +regex-1.3.2/src/re_unicode.rs:1041:9: called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead +regex-1.3.2/src/re_unicode.rs:1088:13: redundant field names in struct initialization +regex-1.3.2/src/re_unicode.rs:1135:5: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) +regex-1.3.2/src/re_unicode.rs:1160:5: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) +regex-1.3.2/src/re_unicode.rs:174:5: docs for function returning `Result` missing `# Errors` section +regex-1.3.2/src/re_unicode.rs:21:1: this function could have a `#[must_use]` attribute +regex-1.3.2/src/re_unicode.rs:313:13: redundant field names in struct initialization +regex-1.3.2/src/re_unicode.rs:38:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/re_unicode.rs:44:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/re_unicode.rs:51:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/re_unicode.rs:57:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/re_unicode.rs:617:29: you should put `shortest_match` between ticks in the documentation +regex-1.3.2/src/re_unicode.rs:631:29: you should put `is_match` between ticks in the documentation +regex-1.3.2/src/re_unicode.rs:64:33: redundant field names in struct initialization +regex-1.3.2/src/re_unicode.rs:64:47: redundant field names in struct initialization +regex-1.3.2/src/re_unicode.rs:834:5: you should put `CaptureLocations` between ticks in the documentation +regex-1.3.2/src/re_unicode.rs:860:1: item `re_unicode::CaptureLocations` has a public `len` method but no corresponding `is_empty` method +regex-1.3.2/src/re_unicode.rs:866:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/re_unicode.rs:875:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/re_unicode.rs:886:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/re_unicode.rs:908:1: item `re_unicode::Captures<'t>` has a public `len` method but no corresponding `is_empty` method +regex-1.3.2/src/re_unicode.rs:928:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/re_unicode.rs:934:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/re_unicode.rs:943:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/re_unicode.rs:972:5: this method could have a `#[must_use]` attribute +regex-1.3.2/src/sparse.rs:10:37: you should put bare URLs between `<`/`>` or make a proper Markdown link +regex-1.3.2/src/sparse.rs:15:1: item name starts with its containing module's name +regex-1.3.2/src/utf8.rs:100:16: digits of hex or binary literal not grouped by four +regex-1.3.2/src/utf8.rs:103:16: digits of hex or binary literal not grouped by four +regex-1.3.2/src/utf8.rs:106:22: casting `u8` to `u32` may become silently lossy if you later change the type +regex-1.3.2/src/utf8.rs:107:19: casting `u8` to `u32` may become silently lossy if you later change the type +regex-1.3.2/src/utf8.rs:108:19: casting `u8` to `u32` may become silently lossy if you later change the type +regex-1.3.2/src/utf8.rs:109:19: casting `u8` to `u32` may become silently lossy if you later change the type +regex-1.3.2/src/utf8.rs:111:27: long literal lacking separators +regex-1.3.2/src/utf8.rs:121:1: item name ends with its containing module's name +regex-1.3.2/src/utf8.rs:143:24: digits of hex or binary literal not grouped by four +regex-1.3.2/src/utf8.rs:143:9: digits of hex or binary literal not grouped by four +regex-1.3.2/src/utf8.rs:23:1: item name ends with its containing module's name +regex-1.3.2/src/utf8.rs:30:20: digits of hex or binary literal not grouped by four +regex-1.3.2/src/utf8.rs:51:1: item name ends with its containing module's name +regex-1.3.2/src/utf8.rs:58:23: digits of hex or binary literal not grouped by four +regex-1.3.2/src/utf8.rs:58:9: digits of hex or binary literal not grouped by four +regex-1.3.2/src/utf8.rs:63:16: digits of hex or binary literal not grouped by four +regex-1.3.2/src/utf8.rs:66:22: casting `u8` to `u32` may become silently lossy if you later change the type +regex-1.3.2/src/utf8.rs:66:54: casting `u8` to `u32` may become silently lossy if you later change the type +regex-1.3.2/src/utf8.rs:77:16: digits of hex or binary literal not grouped by four +regex-1.3.2/src/utf8.rs:80:16: digits of hex or binary literal not grouped by four +regex-1.3.2/src/utf8.rs:83:22: casting `u8` to `u32` may become silently lossy if you later change the type +regex-1.3.2/src/utf8.rs:84:19: casting `u8` to `u32` may become silently lossy if you later change the type +regex-1.3.2/src/utf8.rs:85:19: casting `u8` to `u32` may become silently lossy if you later change the type +regex-1.3.2/src/utf8.rs:92:23: digits of hex or binary literal not grouped by four +regex-1.3.2/src/utf8.rs:92:9: digits of hex or binary literal not grouped by four +regex-1.3.2/src/utf8.rs:97:16: digits of hex or binary literal not grouped by four +ripgrep-12.1.1/build.rs:133:19: called `.as_ref().map(|x| &**x)` on an Option value. This can be done more directly by calling `githash.as_deref()` instead +ripgrep-12.1.1/build.rs:18:18: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +ripgrep-12.1.1/build.rs:225:14: redundant closure found +ripgrep-12.1.1/build.rs:92:19: called `.as_ref().map(|x| &**x)` on an Option value. This can be done more directly by calling `githash.as_deref()` instead +ripgrep-12.1.1/crates/core/app.rs:1408:5: adding items after statements is confusing, since items exist from the start of the scope +ripgrep-12.1.1/crates/core/app.rs:1408:5: adding items after statements is confusing, since items exist from the start of the scope +ripgrep-12.1.1/crates/core/app.rs:1409:5: adding items after statements is confusing, since items exist from the start of the scope +ripgrep-12.1.1/crates/core/app.rs:1409:5: adding items after statements is confusing, since items exist from the start of the scope +ripgrep-12.1.1/crates/core/app.rs:152:32: you should put `clap::Arg` between ticks in the documentation +ripgrep-12.1.1/crates/core/app.rs:152:32: you should put `clap::Arg` between ticks in the documentation +ripgrep-12.1.1/crates/core/app.rs:156:39: you should put `clap::Arg` between ticks in the documentation +ripgrep-12.1.1/crates/core/app.rs:156:39: you should put `clap::Arg` between ticks in the documentation +ripgrep-12.1.1/crates/core/app.rs:156:5: you should put `RGArg` between ticks in the documentation +ripgrep-12.1.1/crates/core/app.rs:156:5: you should put `RGArg` between ticks in the documentation +ripgrep-12.1.1/crates/core/app.rs:1668:5: adding items after statements is confusing, since items exist from the start of the scope +ripgrep-12.1.1/crates/core/app.rs:1668:5: adding items after statements is confusing, since items exist from the start of the scope +ripgrep-12.1.1/crates/core/app.rs:1669:5: adding items after statements is confusing, since items exist from the start of the scope +ripgrep-12.1.1/crates/core/app.rs:1669:5: adding items after statements is confusing, since items exist from the start of the scope +ripgrep-12.1.1/crates/core/app.rs:1821:5: adding items after statements is confusing, since items exist from the start of the scope +ripgrep-12.1.1/crates/core/app.rs:1821:5: adding items after statements is confusing, since items exist from the start of the scope +ripgrep-12.1.1/crates/core/app.rs:1822:5: adding items after statements is confusing, since items exist from the start of the scope +ripgrep-12.1.1/crates/core/app.rs:1822:5: adding items after statements is confusing, since items exist from the start of the scope +ripgrep-12.1.1/crates/core/app.rs:2999:5: adding items after statements is confusing, since items exist from the start of the scope +ripgrep-12.1.1/crates/core/app.rs:2999:5: adding items after statements is confusing, since items exist from the start of the scope +ripgrep-12.1.1/crates/core/app.rs:3000:5: adding items after statements is confusing, since items exist from the start of the scope +ripgrep-12.1.1/crates/core/app.rs:3000:5: adding items after statements is confusing, since items exist from the start of the scope +ripgrep-12.1.1/crates/core/app.rs:367:54: this `match` has identical arm bodies +ripgrep-12.1.1/crates/core/app.rs:367:54: this `match` has identical arm bodies +ripgrep-12.1.1/crates/core/app.rs:414:59: this `match` has identical arm bodies +ripgrep-12.1.1/crates/core/app.rs:414:59: this `match` has identical arm bodies +ripgrep-12.1.1/crates/core/app.rs:417:57: this `match` has identical arm bodies +ripgrep-12.1.1/crates/core/app.rs:417:57: this `match` has identical arm bodies +ripgrep-12.1.1/crates/core/app.rs:417:57: this `match` has identical arm bodies +ripgrep-12.1.1/crates/core/app.rs:417:57: this `match` has identical arm bodies +ripgrep-12.1.1/crates/core/app.rs:444:41: this `match` has identical arm bodies +ripgrep-12.1.1/crates/core/app.rs:444:41: this `match` has identical arm bodies +ripgrep-12.1.1/crates/core/app.rs:470:41: this `match` has identical arm bodies +ripgrep-12.1.1/crates/core/app.rs:470:41: this `match` has identical arm bodies +ripgrep-12.1.1/crates/core/app.rs:75:9: you should put `RIPGREP_BUILD_GIT_HASH` between ticks in the documentation +ripgrep-12.1.1/crates/core/app.rs:75:9: you should put `RIPGREP_BUILD_GIT_HASH` between ticks in the documentation +ripgrep-12.1.1/crates/core/app.rs:87:5: unnecessary boolean `not` operation +ripgrep-12.1.1/crates/core/app.rs:87:5: unnecessary boolean `not` operation +ripgrep-12.1.1/crates/core/args.rs:1143:22: unused `self` argument +ripgrep-12.1.1/crates/core/args.rs:11:1: this import is redundant +ripgrep-12.1.1/crates/core/args.rs:1209:74: this `if` has identical blocks +ripgrep-12.1.1/crates/core/args.rs:1209:74: this `if` has identical blocks +ripgrep-12.1.1/crates/core/args.rs:1282:13: binding's name is too similar to existing binding +ripgrep-12.1.1/crates/core/args.rs:1430:22: unused `self` argument +ripgrep-12.1.1/crates/core/args.rs:1438:21: you should put `OsStr` between ticks in the documentation +ripgrep-12.1.1/crates/core/args.rs:1520:44: redundant closure found +ripgrep-12.1.1/crates/core/args.rs:1524:5: this function's return value is unnecessarily wrapped by `Result` +ripgrep-12.1.1/crates/core/args.rs:1635:14: you should put `values_of_lossy` between ticks in the documentation +ripgrep-12.1.1/crates/core/args.rs:1693:41: redundant closure found +ripgrep-12.1.1/crates/core/args.rs:1770:17: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers +ripgrep-12.1.1/crates/core/args.rs:287:13: binding's name is too similar to existing binding +ripgrep-12.1.1/crates/core/args.rs:33:1: this import is redundant +ripgrep-12.1.1/crates/core/args.rs:34:1: this import is redundant +ripgrep-12.1.1/crates/core/args.rs:35:1: this import is redundant +ripgrep-12.1.1/crates/core/args.rs:410:14: this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) +ripgrep-12.1.1/crates/core/args.rs:475:18: this `match` has identical arm bodies +ripgrep-12.1.1/crates/core/args.rs:512:19: you should put `ArgMatches` between ticks in the documentation +ripgrep-12.1.1/crates/core/args.rs:549:16: methods called `to_*` usually take self by reference; consider choosing a less ambiguous name +ripgrep-12.1.1/crates/core/args.rs:76:18: this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) +ripgrep-12.1.1/crates/core/args.rs:77:13: usage of wildcard import for enum variants +ripgrep-12.1.1/crates/core/args.rs:923:42: you should put `BinaryDetection::quit` between ticks in the documentation +ripgrep-12.1.1/crates/core/config.rs:13:1: this import is redundant +ripgrep-12.1.1/crates/core/config.rs:58:6: very complex type used. Consider factoring parts into `type` definitions +ripgrep-12.1.1/crates/core/config.rs:79:6: very complex type used. Consider factoring parts into `type` definitions +ripgrep-12.1.1/crates/core/logger.rs:11:30: you should put `max_level` between ticks in the documentation +ripgrep-12.1.1/crates/core/logger.rs:15:16: constants have by default a `'static` lifetime +ripgrep-12.1.1/crates/core/main.rs:55:19: this argument is passed by value, but not consumed in the function body +ripgrep-12.1.1/crates/core/main.rs:56:9: usage of wildcard import for enum variants +ripgrep-12.1.1/crates/core/messages.rs:46:1: item name ends with its containing module's name +ripgrep-12.1.1/crates/core/messages.rs:51:1: item name ends with its containing module's name +ripgrep-12.1.1/crates/core/messages.rs:62:1: item name ends with its containing module's name +ripgrep-12.1.1/crates/core/path_printer.rs:27:1: item name starts with its containing module's name +ripgrep-12.1.1/crates/core/path_printer.rs:89:9: unnecessary boolean `not` operation +ripgrep-12.1.1/crates/core/search.rs:185:1: item name starts with its containing module's name +ripgrep-12.1.1/crates/core/search.rs:292:9: using `write!()` with a format string that ends in a single newline +ripgrep-12.1.1/crates/core/search.rs:311:1: item name starts with its containing module's name +ripgrep-12.1.1/crates/core/search.rs:377:12: this boolean expression can be simplified +ripgrep-12.1.1/crates/core/search.rs:423:13: usage of wildcard import for enum variants +ripgrep-12.1.1/crates/core/search.rs:447:13: usage of wildcard import for enum variants +ripgrep-12.1.1/crates/core/search.rs:472:24: you are using an explicit closure for cloning elements +ripgrep-12.1.1/crates/core/search.rs:472:41: redundant closure found +ripgrep-12.1.1/crates/core/search.rs:480:24: you are using an explicit closure for cloning elements +ripgrep-12.1.1/crates/core/search.rs:480:41: redundant closure found +ripgrep-12.1.1/crates/core/search.rs:49:1: item name starts with its containing module's name +ripgrep-12.1.1/crates/core/search.rs:509:24: you are using an explicit closure for cloning elements +ripgrep-12.1.1/crates/core/search.rs:509:41: redundant closure found +ripgrep-12.1.1/crates/core/search.rs:517:24: you are using an explicit closure for cloning elements +ripgrep-12.1.1/crates/core/search.rs:517:41: redundant closure found +ripgrep-12.1.1/crates/core/search.rs:533:36: casting `u32` to `f64` may become silently lossy if you later change the type +ripgrep-12.1.1/crates/core/search.rs:533:5: casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +ripgrep-12.1.1/crates/core/subject.rs:20:1: item name starts with its containing module's name +ripgrep-12.1.1/crates/core/subject.rs:4:1: this import is redundant +syn-1.0.54/src/lit.rs:1397:40: redundant else block +syn-1.0.54/src/lit.rs:1405:28: redundant else block +syn-1.0.54/src/lit.rs:1485:32: redundant else block +unicode-xid-0.2.1/src/lib.rs:57:64: you should put `XID_Start` between ticks in the documentation +unicode-xid-0.2.1/src/lib.rs:60:10: you should put `XID_Start` between ticks in the documentation +unicode-xid-0.2.1/src/lib.rs:62:27: you should put `ID_Start` between ticks in the documentation +unicode-xid-0.2.1/src/lib.rs:62:67: you should put `NFKx` between ticks in the documentation +unicode-xid-0.2.1/src/lib.rs:63:21: methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name +unicode-xid-0.2.1/src/lib.rs:65:61: you should put `XID_Continue` between ticks in the documentation +unicode-xid-0.2.1/src/lib.rs:68:10: you should put `XID_Continue` between ticks in the documentation +unicode-xid-0.2.1/src/lib.rs:70:28: you should put `ID_Continue` between ticks in the documentation +unicode-xid-0.2.1/src/lib.rs:70:72: you should put `NFKx` between ticks in the documentation +unicode-xid-0.2.1/src/lib.rs:71:24: methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name +xsv-0.13.0/src/cmd/cat.rs:101:34: redundant closure found +xsv-0.13.0/src/cmd/cat.rs:42:1: more than 3 bools in a struct +xsv-0.13.0/src/cmd/cat.rs:53:9: binding's name is too similar to existing binding +xsv-0.13.0/src/cmd/cat.rs:7:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/count.rs:32:9: binding's name is too similar to existing binding +xsv-0.13.0/src/cmd/count.rs:38:9: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +xsv-0.13.0/src/cmd/count.rs:42:33: integer type suffix should be separated by an underscore +xsv-0.13.0/src/cmd/count.rs:50:5: passing a unit value to a function +xsv-0.13.0/src/cmd/count.rs:7:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/fixlengths.rs:45:9: binding's name is too similar to existing binding +xsv-0.13.0/src/cmd/fixlengths.rs:50:18: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +xsv-0.13.0/src/cmd/fixlengths.rs:62:30: integer type suffix should be separated by an underscore +xsv-0.13.0/src/cmd/fixlengths.rs:9:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/flatten.rs:10:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/flatten.rs:51:9: binding's name is too similar to existing binding +xsv-0.13.0/src/cmd/fmt.rs:50:9: binding's name is too similar to existing binding +xsv-0.13.0/src/cmd/fmt.rs:55:13: binding's name is too similar to existing binding +xsv-0.13.0/src/cmd/fmt.rs:7:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/frequency.rs:148:43: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers +xsv-0.13.0/src/cmd/frequency.rs:149:43: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers +xsv-0.13.0/src/cmd/frequency.rs:15:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/frequency.rs:169:13: binding's name is too similar to existing binding +xsv-0.13.0/src/cmd/frequency.rs:176:17: unnecessary boolean `not` operation +xsv-0.13.0/src/cmd/frequency.rs:178:24: this `else { if .. }` block can be collapsed +xsv-0.13.0/src/cmd/frequency.rs:77:9: binding's name is too similar to existing binding +xsv-0.13.0/src/cmd/frequency.rs:93:31: it is more concise to loop over containers instead of using explicit iteration methods +xsv-0.13.0/src/cmd/headers.rs:43:9: binding's name is too similar to existing binding +xsv-0.13.0/src/cmd/headers.rs:49:17: it is more concise to loop over containers instead of using explicit iteration methods +xsv-0.13.0/src/cmd/headers.rs:60:22: trait objects without an explicit `dyn` are deprecated +xsv-0.13.0/src/cmd/headers.rs:9:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/index.rs:11:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/index.rs:45:9: binding's name is too similar to existing binding +xsv-0.13.0/src/cmd/input.rs:42:9: binding's name is too similar to existing binding +xsv-0.13.0/src/cmd/input.rs:47:9: binding's name is too similar to existing binding +xsv-0.13.0/src/cmd/input.rs:7:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/join.rs:17:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/join.rs:194:29: binding's name is too similar to existing binding +xsv-0.13.0/src/cmd/join.rs:224:22: binding's name is too similar to existing binding +xsv-0.13.0/src/cmd/join.rs:281:44: trait objects without an explicit `dyn` are deprecated +xsv-0.13.0/src/cmd/join.rs:293:14: binding's name is too similar to existing binding +xsv-0.13.0/src/cmd/join.rs:293:20: binding's name is too similar to existing binding +xsv-0.13.0/src/cmd/join.rs:297:13: redundant field names in struct initialization +xsv-0.13.0/src/cmd/join.rs:298:13: redundant field names in struct initialization +xsv-0.13.0/src/cmd/join.rs:299:13: redundant field names in struct initialization +xsv-0.13.0/src/cmd/join.rs:300:13: redundant field names in struct initialization +xsv-0.13.0/src/cmd/join.rs:308:9: unused `self` argument +xsv-0.13.0/src/cmd/join.rs:342:38: integer type suffix should be separated by an underscore +xsv-0.13.0/src/cmd/join.rs:342:46: integer type suffix should be separated by an underscore +xsv-0.13.0/src/cmd/join.rs:347:9: unnecessary boolean `not` operation +xsv-0.13.0/src/cmd/join.rs:372:44: redundant closure found +xsv-0.13.0/src/cmd/join.rs:375:33: binding's name is too similar to existing binding +xsv-0.13.0/src/cmd/join.rs:392:13: redundant field names in struct initialization +xsv-0.13.0/src/cmd/join.rs:403:29: it is more concise to loop over containers instead of using explicit iteration methods +xsv-0.13.0/src/cmd/join.rs:426:13: unnecessary boolean `not` operation +xsv-0.13.0/src/cmd/join.rs:77:1: more than 3 bools in a struct +xsv-0.13.0/src/cmd/join.rs:94:9: binding's name is too similar to existing binding +xsv-0.13.0/src/cmd/partition.rs:105:22: binding's name is too similar to existing binding +xsv-0.13.0/src/cmd/partition.rs:126:36: trait objects without an explicit `dyn` are deprecated +xsv-0.13.0/src/cmd/partition.rs:139:13: redundant field names in struct initialization +xsv-0.13.0/src/cmd/partition.rs:15:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/partition.rs:169:9: unnecessary boolean `not` operation +xsv-0.13.0/src/cmd/partition.rs:56:9: binding's name is too similar to existing binding +xsv-0.13.0/src/cmd/partition.rs:77:9: unused `self` argument +xsv-0.13.0/src/cmd/sample.rs:105:44: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers +xsv-0.13.0/src/cmd/sample.rs:115:21: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers +xsv-0.13.0/src/cmd/sample.rs:11:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/sample.rs:51:9: binding's name is too similar to existing binding +xsv-0.13.0/src/cmd/sample.rs:58:19: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +xsv-0.13.0/src/cmd/sample.rs:69:9: wildcard match will miss any future added variants +xsv-0.13.0/src/cmd/sample.rs:75:16: it is more concise to loop over containers instead of using explicit iteration methods +xsv-0.13.0/src/cmd/sample.rs:91:42: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers +xsv-0.13.0/src/cmd/sample.rs:92:43: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers +xsv-0.13.0/src/cmd/search.rs:51:9: binding's name is too similar to existing binding +xsv-0.13.0/src/cmd/search.rs:9:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/select.rs:60:9: binding's name is too similar to existing binding +xsv-0.13.0/src/cmd/select.rs:8:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/slice.rs:57:9: binding's name is too similar to existing binding +xsv-0.13.0/src/cmd/slice.rs:9:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/sort.rs:11:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/sort.rs:138:47: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +xsv-0.13.0/src/cmd/sort.rs:139:51: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +xsv-0.13.0/src/cmd/sort.rs:48:9: binding's name is too similar to existing binding +xsv-0.13.0/src/cmd/sort.rs:91:14: it is more concise to loop over containers instead of using explicit iteration methods +xsv-0.13.0/src/cmd/split.rs:131:36: trait objects without an explicit `dyn` are deprecated +xsv-0.13.0/src/cmd/split.rs:14:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/split.rs:61:9: binding's name is too similar to existing binding +xsv-0.13.0/src/cmd/split.rs:94:5: this function's return value is unnecessarily wrapped by `Result` +xsv-0.13.0/src/cmd/split.rs:96:14: this argument is passed by value, but not consumed in the function body +xsv-0.13.0/src/cmd/split.rs:99:13: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers +xsv-0.13.0/src/cmd/stats.rs:110:36: redundant closure found +xsv-0.13.0/src/cmd/stats.rs:127:14: this argument is passed by value, but not consumed in the function body +xsv-0.13.0/src/cmd/stats.rs:138:43: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers +xsv-0.13.0/src/cmd/stats.rs:139:43: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers +xsv-0.13.0/src/cmd/stats.rs:162:25: it is more concise to loop over containers instead of using explicit iteration methods +xsv-0.13.0/src/cmd/stats.rs:22:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/stats.rs:231:1: more than 3 bools in a struct +xsv-0.13.0/src/cmd/stats.rs:262:35: calling `cmd::stats::TypedSum::default()` is more clear than this expression +xsv-0.13.0/src/cmd/stats.rs:263:40: calling `cmd::stats::TypedMinMax::default()` is more clear than this expression +xsv-0.13.0/src/cmd/stats.rs:264:39: calling `stats::OnlineStats::default()` is more clear than this expression +xsv-0.13.0/src/cmd/stats.rs:265:58: calling `stats::Unsorted::default()` is more clear than this expression +xsv-0.13.0/src/cmd/stats.rs:266:41: calling `stats::Unsorted::default()` is more clear than this expression +xsv-0.13.0/src/cmd/stats.rs:268:18: calling `cmd::stats::FieldType::default()` is more clear than this expression +xsv-0.13.0/src/cmd/stats.rs:269:13: redundant field names in struct initialization +xsv-0.13.0/src/cmd/stats.rs:270:13: redundant field names in struct initialization +xsv-0.13.0/src/cmd/stats.rs:271:13: redundant field names in struct initialization +xsv-0.13.0/src/cmd/stats.rs:272:13: redundant field names in struct initialization +xsv-0.13.0/src/cmd/stats.rs:273:13: redundant field names in struct initialization +xsv-0.13.0/src/cmd/stats.rs:274:13: redundant field names in struct initialization +xsv-0.13.0/src/cmd/stats.rs:283:9: called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()` +xsv-0.13.0/src/cmd/stats.rs:284:9: called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()` +xsv-0.13.0/src/cmd/stats.rs:285:9: called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()` +xsv-0.13.0/src/cmd/stats.rs:290:21: called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()` +xsv-0.13.0/src/cmd/stats.rs:293:25: this `match` has identical arm bodies +xsv-0.13.0/src/cmd/stats.rs:297:25: called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()` +xsv-0.13.0/src/cmd/stats.rs:301:21: called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()` +xsv-0.13.0/src/cmd/stats.rs:302:21: called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()` +xsv-0.13.0/src/cmd/stats.rs:308:18: methods called `to_*` usually take self by reference; consider choosing a less ambiguous name +xsv-0.13.0/src/cmd/stats.rs:318:9: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +xsv-0.13.0/src/cmd/stats.rs:322:45: redundant closure found +xsv-0.13.0/src/cmd/stats.rs:322:9: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +xsv-0.13.0/src/cmd/stats.rs:327:9: unnecessary boolean `not` operation +xsv-0.13.0/src/cmd/stats.rs:330:13: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` +xsv-0.13.0/src/cmd/stats.rs:338:45: redundant closure found +xsv-0.13.0/src/cmd/stats.rs:402:16: redundant pattern matching, consider using `is_ok()` +xsv-0.13.0/src/cmd/stats.rs:403:16: redundant pattern matching, consider using `is_ok()` +xsv-0.13.0/src/cmd/stats.rs:407:18: this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) +xsv-0.13.0/src/cmd/stats.rs:411:16: this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) +xsv-0.13.0/src/cmd/stats.rs:427:56: this `match` has identical arm bodies +xsv-0.13.0/src/cmd/stats.rs:429:56: this `match` has identical arm bodies +xsv-0.13.0/src/cmd/stats.rs:430:60: this `match` has identical arm bodies +xsv-0.13.0/src/cmd/stats.rs:430:60: this `match` has identical arm bodies +xsv-0.13.0/src/cmd/stats.rs:454:5: you should put `TypedSum` between ticks in the documentation +xsv-0.13.0/src/cmd/stats.rs:473:43: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +xsv-0.13.0/src/cmd/stats.rs:504:56: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +xsv-0.13.0/src/cmd/stats.rs:505:51: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +xsv-0.13.0/src/cmd/stats.rs:511:5: you should put `TypedMinMax` between ticks in the documentation +xsv-0.13.0/src/cmd/stats.rs:536:35: casting `f64` to `i64` may truncate the value +xsv-0.13.0/src/cmd/stats.rs:544:33: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) +xsv-0.13.0/src/cmd/stats.rs:592:22: calling `stats::MinMax::default()` is more clear than this expression +xsv-0.13.0/src/cmd/stats.rs:593:22: calling `stats::MinMax::default()` is more clear than this expression +xsv-0.13.0/src/cmd/stats.rs:594:23: calling `stats::MinMax::default()` is more clear than this expression +xsv-0.13.0/src/cmd/stats.rs:595:21: calling `stats::MinMax::default()` is more clear than this expression +xsv-0.13.0/src/cmd/stats.rs:71:1: more than 3 bools in a struct +xsv-0.13.0/src/cmd/stats.rs:86:9: binding's name is too similar to existing binding +xsv-0.13.0/src/cmd/table.rs:10:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/cmd/table.rs:50:9: binding's name is too similar to existing binding +xsv-0.13.0/src/cmd/table.rs:54:9: binding's name is too similar to existing binding +xsv-0.13.0/src/config.rs:113:43: use of `unwrap_or` followed by a function call +xsv-0.13.0/src/config.rs:197:48: trait objects without an explicit `dyn` are deprecated +xsv-0.13.0/src/config.rs:202:48: trait objects without an explicit `dyn` are deprecated +xsv-0.13.0/src/config.rs:263:47: trait objects without an explicit `dyn` are deprecated +xsv-0.13.0/src/config.rs:293:47: trait objects without an explicit `dyn` are deprecated +xsv-0.13.0/src/config.rs:58:1: more than 3 bools in a struct +xsv-0.13.0/src/config.rs:77:28: explicit deref method call +xsv-0.13.0/src/config.rs:90:13: redundant field names in struct initialization +xsv-0.13.0/src/index.rs:31:13: redundant field names in struct initialization +xsv-0.13.0/src/main.rs:164:49: redundant clone +xsv-0.13.0/src/main.rs:75:16: statics have by default a `'static` lifetime +xsv-0.13.0/src/select.rs:13:1: item name starts with its containing module's name +xsv-0.13.0/src/select.rs:154:5: this function's return value is unnecessarily wrapped by `Result` +xsv-0.13.0/src/select.rs:250:33: binding's name is too similar to existing binding +xsv-0.13.0/src/select.rs:250:43: binding's name is too similar to existing binding +xsv-0.13.0/src/select.rs:255:39: an inclusive range would be more readable +xsv-0.13.0/src/select.rs:280:20: length comparison to zero +xsv-0.13.0/src/select.rs:29:13: redundant field names in struct initialization +xsv-0.13.0/src/select.rs:360:62: this argument (8 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) +xsv-0.13.0/src/select.rs:360:9: this function's return value is unnecessarily wrapped by `Option` +xsv-0.13.0/src/select.rs:375:9: used sort instead of sort_unstable to sort primitive type `usize` +xsv-0.13.0/src/select.rs:379:18: it is more concise to loop over containers instead of using explicit iteration methods +xsv-0.13.0/src/select.rs:416:5: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) +xsv-0.13.0/src/select.rs:419:9: this function's return value is unnecessarily wrapped by `Option` +xsv-0.13.0/src/select.rs:420:27: consider using `Option` instead of `Option>` or a custom enum if you need to distinguish all 3 cases +xsv-0.13.0/src/select.rs:99:17: binding's name is too similar to existing binding +xsv-0.13.0/src/util.rs:150:5: you should put bare URLs between `<`/`>` or make a proper Markdown link +xsv-0.13.0/src/util.rs:190:48: trait objects without an explicit `dyn` are deprecated +xsv-0.13.0/src/util.rs:37:33: you are using an explicit closure for copying elements +xsv-0.13.0/src/util.rs:90:1: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) -- cgit 1.4.1-3-g733a5 From f986d78c5e6d401ea3c57c7d00d24d1890675f0c Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Wed, 23 Dec 2020 01:21:31 +0100 Subject: cargo dev crater: support multiple versions per crate --- clippy_dev/crater_crates.toml | 34 +++++++++++++++++----------------- clippy_dev/src/crater.rs | 32 ++++++++++++++++++++++++++------ 2 files changed, 43 insertions(+), 23 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/crater_crates.toml b/clippy_dev/crater_crates.toml index e69056c9925..1fbf7930d3e 100644 --- a/clippy_dev/crater_crates.toml +++ b/clippy_dev/crater_crates.toml @@ -1,20 +1,20 @@ [crates] # some of these are from cargotest -cargo = '0.49.0' -iron = '0.6.1' -ripgrep = '12.1.1' -xsv = '0.13.0' -#tokei = '12.0.4' -rayon = '1.5.0' -serde = '1.0.118' +cargo = ['0.49.0'] +iron = ['0.6.1'] +ripgrep = ['12.1.1'] +xsv = ['0.13.0'] +#tokei = ['12.0.4'] +rayon = ['1.5.0'] +serde = ['1.0.118'] # top 10 crates.io dls -bitflags = '1.2.1' -libc = '0.2.81' -log = '0.4.11' -proc-macro2 = '1.0.24' -quote = '1.0.7' -rand = '0.7.3' -rand_core = '0.6.0' -regex = '1.3.2' -syn = '1.0.54' -unicode-xid = '0.2.1' +bitflags = ['1.2.1'] +libc = ['0.2.81'] +log = ['0.4.11'] +proc-macro2 = ['1.0.24'] +quote = ['1.0.7'] +rand = ['0.7.3'] +rand_core = ['0.6.0'] +regex = ['1.3.2'] +syn = ['1.0.54'] +unicode-xid = ['0.2.1'] diff --git a/clippy_dev/src/crater.rs b/clippy_dev/src/crater.rs index f64ab897906..a681bf10496 100644 --- a/clippy_dev/src/crater.rs +++ b/clippy_dev/src/crater.rs @@ -6,17 +6,24 @@ use std::collections::HashMap; use std::process::Command; use std::{fs::write, path::PathBuf}; +// crate data we stored in the toml, can have multiple versions. +// if so, one TomlKrate maps to several KrateSources +struct TomlKrate { + name: String, + versions: Vec, +} + // represents an archive we download from crates.io #[derive(Debug, Serialize, Deserialize, Eq, Hash, PartialEq)] struct KrateSource { - version: String, name: String, + version: String, } // use this to store the crates when interacting with the crates.toml file #[derive(Debug, Serialize, Deserialize)] struct CrateList { - crates: HashMap, + crates: HashMap>, } // represents the extracted sourcecode of a crate @@ -145,11 +152,24 @@ fn read_crates() -> Vec { let crate_list: CrateList = toml::from_str(&toml_content).unwrap_or_else(|e| panic!("Failed to parse {}: \n{}", toml_path.display(), e)); // parse the hashmap of the toml file into a list of crates - crate_list + let tomlkrates: Vec = crate_list .crates - .iter() - .map(|(name, version)| KrateSource::new(&name, &version)) - .collect() + .into_iter() + .map(|(name, versions)| TomlKrate { name, versions }) + .collect(); + + // flatten TomlKrates into KrateSources (one TomlKrates may represent several versions of a crate => + // multiple kratesources) + let mut krate_sources = Vec::new(); + tomlkrates.into_iter().for_each(|tk| { + tk.versions.iter().for_each(|ver| { + krate_sources.push(KrateSource { + name: tk.name.clone(), + version: ver.to_string(), + }); + }) + }); + krate_sources } // the main fn -- cgit 1.4.1-3-g733a5 From 22824d21da0397d61c15a56dbb88405f4866293d Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Wed, 23 Dec 2020 13:02:02 +0100 Subject: rename symbols: krate -> crate --- clippy_dev/src/crater.rs | 51 ++++++++++++++++++++++++------------------------ 1 file changed, 26 insertions(+), 25 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/crater.rs b/clippy_dev/src/crater.rs index a681bf10496..6202acfad06 100644 --- a/clippy_dev/src/crater.rs +++ b/clippy_dev/src/crater.rs @@ -1,21 +1,29 @@ +// Run clippy on a fixed set of crates and collect the warnings. +// This helps observing the impact clippy changs have on a set of real-world code. +// +// When a new lint is introduced, we can search the results for new warnings and check for false +// positives. + #![allow(clippy::filter_map)] use crate::clippy_project_root; -use serde::{Deserialize, Serialize}; + use std::collections::HashMap; use std::process::Command; use std::{fs::write, path::PathBuf}; +use serde::{Deserialize, Serialize}; + // crate data we stored in the toml, can have multiple versions. // if so, one TomlKrate maps to several KrateSources -struct TomlKrate { +struct TomlCrate { name: String, versions: Vec, } // represents an archive we download from crates.io #[derive(Debug, Serialize, Deserialize, Eq, Hash, PartialEq)] -struct KrateSource { +struct CrateSource { name: String, version: String, } @@ -28,22 +36,15 @@ struct CrateList { // represents the extracted sourcecode of a crate #[derive(Debug)] -struct Krate { +struct Crate { version: String, name: String, // path to the extracted sources that clippy can check path: PathBuf, } -impl KrateSource { - fn new(name: &str, version: &str) -> Self { - KrateSource { - version: version.into(), - name: name.into(), - } - } - - fn download_and_extract(&self) -> Krate { +impl CrateSource { + fn download_and_extract(&self) -> Crate { let extract_dir = PathBuf::from("target/crater/crates"); let krate_download_dir = PathBuf::from("target/crater/downloads"); @@ -80,7 +81,7 @@ impl KrateSource { } // crate is extracted, return a new Krate object which contains the path to the extracted // sources that clippy can check - Krate { + Crate { version: self.version.clone(), name: self.name.clone(), path: extract_dir.join(format!("{}-{}/", self.name, self.version)), @@ -88,7 +89,7 @@ impl KrateSource { } } -impl Krate { +impl Crate { fn run_clippy_lints(&self, cargo_clippy_path: &PathBuf) -> Vec { println!("Linting {} {}...", &self.name, &self.version); let cargo_clippy_path = std::fs::canonicalize(cargo_clippy_path).unwrap(); @@ -144,32 +145,32 @@ fn build_clippy() { .expect("Failed to build clippy!"); } -// get a list of KrateSources we want to check from a "crater_crates.toml" file. -fn read_crates() -> Vec { +// get a list of CrateSources we want to check from a "crater_crates.toml" file. +fn read_crates() -> Vec { let toml_path = PathBuf::from("clippy_dev/crater_crates.toml"); let toml_content: String = std::fs::read_to_string(&toml_path).unwrap_or_else(|_| panic!("Failed to read {}", toml_path.display())); let crate_list: CrateList = toml::from_str(&toml_content).unwrap_or_else(|e| panic!("Failed to parse {}: \n{}", toml_path.display(), e)); // parse the hashmap of the toml file into a list of crates - let tomlkrates: Vec = crate_list + let tomlcrates: Vec = crate_list .crates .into_iter() - .map(|(name, versions)| TomlKrate { name, versions }) + .map(|(name, versions)| TomlCrate { name, versions }) .collect(); - // flatten TomlKrates into KrateSources (one TomlKrates may represent several versions of a crate => - // multiple kratesources) - let mut krate_sources = Vec::new(); - tomlkrates.into_iter().for_each(|tk| { + // flatten TomlCrates into CrateSources (one TomlCrates may represent several versions of a crate => + // multiple Cratesources) + let mut crate_sources = Vec::new(); + tomlcrates.into_iter().for_each(|tk| { tk.versions.iter().for_each(|ver| { - krate_sources.push(KrateSource { + crate_sources.push(CrateSource { name: tk.name.clone(), version: ver.to_string(), }); }) }); - krate_sources + crate_sources } // the main fn -- cgit 1.4.1-3-g733a5 From 62337f284281637a73a8d4770315850fbf4067aa Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Wed, 23 Dec 2020 13:03:19 +0100 Subject: remove duplicate code and other cleanup --- clippy_dev/Cargo.toml | 4 ++-- clippy_dev/src/crater.rs | 28 +++++++++++----------------- mini-crater/logs.txt | 1 + 3 files changed, 14 insertions(+), 19 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/Cargo.toml b/clippy_dev/Cargo.toml index 6c6941837f1..e41ed77fcb9 100644 --- a/clippy_dev/Cargo.toml +++ b/clippy_dev/Cargo.toml @@ -1,8 +1,8 @@ [package] -authors = ["Philipp Hansch "] -edition = "2018" name = "clippy_dev" version = "0.0.1" +authors = ["Philipp Hansch "] +edition = "2018" [dependencies] bytecount = "0.6" diff --git a/clippy_dev/src/crater.rs b/clippy_dev/src/crater.rs index 6202acfad06..8a6ce0a8921 100644 --- a/clippy_dev/src/crater.rs +++ b/clippy_dev/src/crater.rs @@ -14,8 +14,14 @@ use std::{fs::write, path::PathBuf}; use serde::{Deserialize, Serialize}; -// crate data we stored in the toml, can have multiple versions. -// if so, one TomlKrate maps to several KrateSources +// use this to store the crates when interacting with the crates.toml file +#[derive(Debug, Serialize, Deserialize)] +struct CrateList { + crates: HashMap>, +} + +// crate data we stored in the toml, can have multiple versions per crate +// A single TomlCrate is laster mapped to several CrateSources in that case struct TomlCrate { name: String, versions: Vec, @@ -28,12 +34,6 @@ struct CrateSource { version: String, } -// use this to store the crates when interacting with the crates.toml file -#[derive(Debug, Serialize, Deserialize)] -struct CrateList { - crates: HashMap>, -} - // represents the extracted sourcecode of a crate #[derive(Debug)] struct Crate { @@ -70,14 +70,8 @@ impl CrateSource { // unzip the tarball let ungz_tar = flate2::read::GzDecoder::new(std::fs::File::open(&krate_file_path).unwrap()); // extract the tar archive - let mut archiv = tar::Archive::new(ungz_tar); - archiv.unpack(&extract_dir).expect("Failed to extract!"); - - // unzip the tarball - let ungz_tar = flate2::read::GzDecoder::new(std::fs::File::open(&krate_file_path).unwrap()); - // extract the tar archive - let mut archiv = tar::Archive::new(ungz_tar); - archiv.unpack(&extract_dir).expect("Failed to extract!"); + let mut archive = tar::Archive::new(ungz_tar); + archive.unpack(&extract_dir).expect("Failed to extract!"); } // crate is extracted, return a new Krate object which contains the path to the extracted // sources that clippy can check @@ -132,7 +126,7 @@ impl Crate { }) .collect(); - // sort messages alphabtically to avoid noise in the logs + // sort messages alphabetically to avoid noise in the logs output.sort(); output } diff --git a/mini-crater/logs.txt b/mini-crater/logs.txt index dfa6450def7..42d978f4db4 100644 --- a/mini-crater/logs.txt +++ b/mini-crater/logs.txt @@ -1423,6 +1423,7 @@ iron-0.6.1/src/request/mod.rs:85:24: binding's name is too similar to existing b iron-0.6.1/src/request/url.rs:109:5: this method could have a `#[must_use]` attribute iron-0.6.1/src/request/url.rs:117:5: this method could have a `#[must_use]` attribute iron-0.6.1/src/request/url.rs:124:9: use of deprecated macro `try`: use the `?` operator instead +iron-0.6.1/src/request/url.rs:129:1: an implementation of `From` is preferred since it gives you `Into<_>` for free where the reverse isn't true iron-0.6.1/src/request/url.rs:21:14: you should put bare URLs between `<`/`>` or make a proper Markdown link iron-0.6.1/src/request/url.rs:22:5: docs for function returning `Result` missing `# Errors` section iron-0.6.1/src/request/url.rs:31:5: docs for function returning `Result` missing `# Errors` section -- cgit 1.4.1-3-g733a5 From 6c5bf2778fa09fd3a79dd2fa76779c07ee182391 Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Wed, 23 Dec 2020 15:00:51 +0100 Subject: clippy dev crater: use and parse clippy messages as json message, to get the lint name of a warning --- clippy_dev/Cargo.toml | 1 + clippy_dev/src/crater.rs | 76 +- mini-crater/logs.txt | 6494 +++++++++++++++++++++++----------------------- 3 files changed, 3306 insertions(+), 3265 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/Cargo.toml b/clippy_dev/Cargo.toml index e41ed77fcb9..d6663145142 100644 --- a/clippy_dev/Cargo.toml +++ b/clippy_dev/Cargo.toml @@ -12,6 +12,7 @@ itertools = "0.9" opener = "0.4" regex = "1" serde = {version = "1.0", features = ["derive"]} +serde_json = "1.0" shell-escape = "0.1" tar = "0.4.30" toml = "0.5" diff --git a/clippy_dev/src/crater.rs b/clippy_dev/src/crater.rs index 8a6ce0a8921..db0dd3641f1 100644 --- a/clippy_dev/src/crater.rs +++ b/clippy_dev/src/crater.rs @@ -10,9 +10,10 @@ use crate::clippy_project_root; use std::collections::HashMap; use std::process::Command; -use std::{fs::write, path::PathBuf}; +use std::{fmt, fs::write, path::PathBuf}; use serde::{Deserialize, Serialize}; +use serde_json::Value; // use this to store the crates when interacting with the crates.toml file #[derive(Debug, Serialize, Deserialize)] @@ -43,6 +44,27 @@ struct Crate { path: PathBuf, } +#[derive(Debug)] +struct ClippyWarning { + crate_name: String, + crate_version: String, + file: String, + line: String, + column: String, + linttype: String, + message: String, +} + +impl std::fmt::Display for ClippyWarning { + fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { + writeln!( + f, + r#"{}/{}/{}:{}:{} {} "{}""#, + &self.crate_name, &self.crate_version, &self.file, &self.line, &self.column, &self.linttype, &self.message + ) + } +} + impl CrateSource { fn download_and_extract(&self) -> Crate { let extract_dir = PathBuf::from("target/crater/crates"); @@ -96,7 +118,7 @@ impl Crate { // src/cargo/ops/cargo_compile.rs:127:35: warning: usage of `FromIterator::from_iter` .args(&[ "--", - "--message-format=short", + "--message-format=json", "--", "--cap-lints=warn", "-Wclippy::pedantic", @@ -105,27 +127,17 @@ impl Crate { .current_dir(&self.path) .output() .unwrap(); - let stderr = String::from_utf8_lossy(&all_output.stderr); - let output_lines = stderr.lines(); - let mut output: Vec = output_lines + let stdout = String::from_utf8_lossy(&all_output.stdout); + let output_lines = stdout.lines(); + //dbg!(&output_lines); + let warnings: Vec = output_lines .into_iter() - .filter(|line| line.contains(": warning: ")) - // prefix with the crate name and version - // cargo-0.49.0/src/cargo/ops/cargo_compile.rs:127:35: warning: usage of `FromIterator::from_iter` - .map(|line| format!("{}-{}/{}", self.name, self.version, line)) - // remove the "warning: " - .map(|line| { - let remove_pat = "warning: "; - let pos = line - .find(&remove_pat) - .expect("clippy output did not contain \"warning: \""); - let mut new = line[0..pos].to_string(); - new.push_str(&line[pos + remove_pat.len()..]); - new.push('\n'); - new - }) + // get all clippy warnings + .filter(|line| line.contains("clippy::")) + .map(|json_msg| parse_json_message(json_msg, &self)) .collect(); + let mut output: Vec = warnings.iter().map(|warning| warning.to_string()).collect(); // sort messages alphabetically to avoid noise in the logs output.sort(); output @@ -167,6 +179,30 @@ fn read_crates() -> Vec { crate_sources } +// extract interesting data from a json lint message +fn parse_json_message(json_message: &str, krate: &Crate) -> ClippyWarning { + let jmsg: Value = serde_json::from_str(&json_message).unwrap_or_else(|e| panic!("Failed to parse json:\n{:?}", e)); + + ClippyWarning { + crate_name: krate.name.to_string(), + crate_version: krate.version.to_string(), + file: jmsg["message"]["spans"][0]["file_name"] + .to_string() + .trim_matches('"') + .into(), + line: jmsg["message"]["spans"][0]["line_start"] + .to_string() + .trim_matches('"') + .into(), + column: jmsg["message"]["spans"][0]["text"][0]["highlight_start"] + .to_string() + .trim_matches('"') + .into(), + linttype: jmsg["message"]["code"]["code"].to_string().trim_matches('"').into(), + message: jmsg["message"]["message"].to_string().trim_matches('"').into(), + } +} + // the main fn pub fn run() { let cargo_clippy_path: PathBuf = PathBuf::from("target/debug/cargo-clippy"); diff --git a/mini-crater/logs.txt b/mini-crater/logs.txt index 42d978f4db4..52045f05faa 100644 --- a/mini-crater/logs.txt +++ b/mini-crater/logs.txt @@ -1,3245 +1,3249 @@ -cargo-0.49.0/src/bin/cargo/cli.rs:104:34: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -cargo-0.49.0/src/bin/cargo/cli.rs:121:5: calling `push_str()` using a single-character string literal -cargo-0.49.0/src/bin/cargo/cli.rs:157:30: redundant closure found -cargo-0.49.0/src/bin/cargo/cli.rs:184:41: casting `u64` to `u32` may truncate the value -cargo-0.49.0/src/bin/cargo/cli.rs:196:42: redundant closure found -cargo-0.49.0/src/bin/cargo/cli.rs:200:39: redundant closure found -cargo-0.49.0/src/bin/cargo/cli.rs:231:1: more than 3 bools in a struct -cargo-0.49.0/src/bin/cargo/cli.rs:245:22: casting `u64` to `u32` may truncate the value -cargo-0.49.0/src/bin/cargo/cli.rs:247:47: redundant closure found -cargo-0.49.0/src/bin/cargo/cli.rs:257:22: redundant closure found -cargo-0.49.0/src/bin/cargo/cli.rs:26:20: redundant else block -cargo-0.49.0/src/bin/cargo/cli.rs:7:5: usage of wildcard import -cargo-0.49.0/src/bin/cargo/commands/bench.rs:1:5: usage of wildcard import -cargo-0.49.0/src/bin/cargo/commands/bench.rs:76:59: redundant closure found -cargo-0.49.0/src/bin/cargo/commands/build.rs:1:5: usage of wildcard import -cargo-0.49.0/src/bin/cargo/commands/check.rs:1:5: usage of wildcard import -cargo-0.49.0/src/bin/cargo/commands/clean.rs:1:5: usage of wildcard import -cargo-0.49.0/src/bin/cargo/commands/doc.rs:1:5: usage of wildcard import -cargo-0.49.0/src/bin/cargo/commands/fetch.rs:1:5: usage of wildcard import -cargo-0.49.0/src/bin/cargo/commands/fix.rs:1:5: usage of wildcard import -cargo-0.49.0/src/bin/cargo/commands/generate_lockfile.rs:1:5: usage of wildcard import -cargo-0.49.0/src/bin/cargo/commands/git_checkout.rs:1:5: usage of wildcard import -cargo-0.49.0/src/bin/cargo/commands/help.rs:20:1: item name ends with its containing module's name -cargo-0.49.0/src/bin/cargo/commands/init.rs:1:5: usage of wildcard import -cargo-0.49.0/src/bin/cargo/commands/install.rs:1:5: usage of wildcard import -cargo-0.49.0/src/bin/cargo/commands/install.rs:97:16: use Option::map_or instead of an if let/else -cargo-0.49.0/src/bin/cargo/commands/locate_project.rs:1:5: usage of wildcard import -cargo-0.49.0/src/bin/cargo/commands/login.rs:1:5: usage of wildcard import -cargo-0.49.0/src/bin/cargo/commands/metadata.rs:1:5: usage of wildcard import -cargo-0.49.0/src/bin/cargo/commands/mod.rs:1:5: usage of wildcard import -cargo-0.49.0/src/bin/cargo/commands/new.rs:1:5: usage of wildcard import -cargo-0.49.0/src/bin/cargo/commands/new.rs:20:24: use Option::map_or instead of an if let/else -cargo-0.49.0/src/bin/cargo/commands/owner.rs:1:5: usage of wildcard import -cargo-0.49.0/src/bin/cargo/commands/owner.rs:38:43: redundant closure found -cargo-0.49.0/src/bin/cargo/commands/owner.rs:39:43: redundant closure found -cargo-0.49.0/src/bin/cargo/commands/owner.rs:40:43: redundant closure found -cargo-0.49.0/src/bin/cargo/commands/owner.rs:43:30: redundant closure found -cargo-0.49.0/src/bin/cargo/commands/owner.rs:46:30: redundant closure found -cargo-0.49.0/src/bin/cargo/commands/package.rs:1:5: usage of wildcard import -cargo-0.49.0/src/bin/cargo/commands/pkgid.rs:1:5: usage of wildcard import -cargo-0.49.0/src/bin/cargo/commands/publish.rs:1:5: usage of wildcard import -cargo-0.49.0/src/bin/cargo/commands/publish.rs:40:47: redundant closure found -cargo-0.49.0/src/bin/cargo/commands/read_manifest.rs:1:5: usage of wildcard import -cargo-0.49.0/src/bin/cargo/commands/run.rs:1:5: usage of wildcard import -cargo-0.49.0/src/bin/cargo/commands/rustc.rs:1:5: usage of wildcard import -cargo-0.49.0/src/bin/cargo/commands/rustdoc.rs:3:5: usage of wildcard import -cargo-0.49.0/src/bin/cargo/commands/search.rs:1:5: usage of wildcard import -cargo-0.49.0/src/bin/cargo/commands/test.rs:127:54: redundant closure found -cargo-0.49.0/src/bin/cargo/commands/test.rs:1:5: usage of wildcard import -cargo-0.49.0/src/bin/cargo/commands/tree.rs:149:49: redundant closure found -cargo-0.49.0/src/bin/cargo/commands/tree.rs:2:5: usage of wildcard import -cargo-0.49.0/src/bin/cargo/commands/uninstall.rs:1:5: usage of wildcard import -cargo-0.49.0/src/bin/cargo/commands/update.rs:1:5: usage of wildcard import -cargo-0.49.0/src/bin/cargo/commands/vendor.rs:1:5: usage of wildcard import -cargo-0.49.0/src/bin/cargo/commands/vendor.rs:96:16: called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead -cargo-0.49.0/src/bin/cargo/commands/verify_project.rs:1:5: usage of wildcard import -cargo-0.49.0/src/bin/cargo/commands/version.rs:2:5: usage of wildcard import -cargo-0.49.0/src/bin/cargo/commands/yank.rs:1:5: usage of wildcard import -cargo-0.49.0/src/bin/cargo/commands/yank.rs:32:36: redundant closure found -cargo-0.49.0/src/bin/cargo/commands/yank.rs:33:35: redundant closure found -cargo-0.49.0/src/bin/cargo/commands/yank.rs:34:36: redundant closure found -cargo-0.49.0/src/bin/cargo/commands/yank.rs:35:36: redundant closure found -cargo-0.49.0/src/bin/cargo/main.rs:100:17: wildcard match will miss any future added variants -cargo-0.49.0/src/bin/cargo/main.rs:118:41: redundant closure found -cargo-0.49.0/src/bin/cargo/main.rs:137:43: redundant closure found -cargo-0.49.0/src/bin/cargo/main.rs:148:19: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -cargo-0.49.0/src/bin/cargo/main.rs:174:57: redundant closure found -cargo-0.49.0/src/bin/cargo/main.rs:18:5: usage of wildcard import -cargo-0.49.0/src/bin/cargo/main.rs:72:22: redundant closure found -cargo-0.49.0/src/bin/cargo/main.rs:94:13: wildcard match will miss any future added variants -cargo-0.49.0/src/bin/cargo/main.rs:96:41: redundant closure found -cargo-0.49.0/src/bin/cargo/main.rs:98:60: redundant closure found -cargo-0.49.0/src/cargo/core/compiler/build_config.rs:155:13: usage of wildcard import for enum variants -cargo-0.49.0/src/cargo/core/compiler/build_config.rs:170:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/compiler/build_config.rs:175:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/compiler/build_config.rs:180:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/compiler/build_config.rs:186:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/compiler/build_config.rs:197:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/compiler/build_config.rs:205:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/compiler/build_config.rs:51:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/compiler/build_config.rs:69:48: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -cargo-0.49.0/src/cargo/core/compiler/build_config.rs:96:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/compiler/build_context/mod.rs:44:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/compiler/build_context/mod.rs:83:20: you should put `x86_64` between ticks in the documentation -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:108:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:121:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:149:9: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:420:69: you should put `mode/target_kind` between ticks in the documentation -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:423:19: you should put `CrateTypes` between ticks in the documentation -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:424:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:469:58: redundant closure found -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:591:20: called `filter(..).map(..)` on an `Iterator` -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:603:19: redundant closure found -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:665:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:82:31: you should put `FileType` between ticks in the documentation -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:83:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:84:9: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:96:31: you should put `FileType` between ticks in the documentation -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:98:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/compiler/build_plan.rs:4:9: you should put `BuildPlan` between ticks in the documentation -cargo-0.49.0/src/cargo/core/compiler/build_plan.rs:5:66: you should put `BuildPlan` between ticks in the documentation -cargo-0.49.0/src/cargo/core/compiler/compilation.rs:150:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/compiler/compilation.rs:169:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/compiler/compilation.rs:185:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/compiler/compilation.rs:193:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/compiler/compilation.rs:194:49: redundant closure found -cargo-0.49.0/src/cargo/core/compiler/compilation.rs:198:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/compiler/compilation.rs:314:16: you should put `rustc_tool` between ticks in the documentation -cargo-0.49.0/src/cargo/core/compiler/compilation.rs:91:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:118:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:147:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:157:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:29:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:33:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:49:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/compiler/context/compilation_files.rs:204:9: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -cargo-0.49.0/src/cargo/core/compiler/context/compilation_files.rs:277:22: you should put `OUT_DIR` between ticks in the documentation -cargo-0.49.0/src/cargo/core/compiler/context/compilation_files.rs:324:66: you should put `FileType` between ticks in the documentation -cargo-0.49.0/src/cargo/core/compiler/context/compilation_files.rs:393:37: this `match` has identical arm bodies -cargo-0.49.0/src/cargo/core/compiler/context/compilation_files.rs:426:71: redundant closure found -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:125:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:125:5: this function has too many lines (107/100) -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:270:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:286:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:308:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:340:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:349:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:354:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:358:21: you should put `RunCustomBuild` between ticks in the documentation -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:361:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:365:9: called `find(..).map(..)` on an `Iterator` -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:374:43: you should put `RunCustomBuild` between ticks in the documentation -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:378:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:383:41: you should put `RunCustomBuild` between ticks in the documentation -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:384:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:391:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:397:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:523:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:538:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:542:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:83:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:92:25: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -cargo-0.49.0/src/cargo/core/compiler/crate_type.rs:16:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/compiler/crate_type.rs:29:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/compiler/crate_type.rs:40:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/compiler/crate_type.rs:49:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/compiler/crate_type.rs:60:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:150:1: this function has too many lines (230/100) -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:154:29: called `find(..).map(..)` on an `Iterator` -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:353:56: stripping a prefix manually -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:448:27: this argument is passed by value, but not consumed in the function body -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:464:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:481:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:48:56: you should put `RunCustomBuild` between ticks in the documentation -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:561:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:567:20: redundant closure found -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:576:28: `mut value` is being shadowed -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:606:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:624:13: called `find(..).map(..)` on an `Iterator` -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:688:5: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:756:5: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:762:5: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:762:5: this function's return value is unnecessarily wrapped by `Result` -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:823:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1021:51: redundant closure found -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1252:20: called `filter(..).map(..)` on an `Iterator` -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1278:19: called `filter(..).map(..)` on an `Iterator` -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1656:16: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1664:5: field assignment outside of initializer for an instance created with Default::default() -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1787:5: binding's name is too similar to existing binding -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1795:5: field assignment outside of initializer for an instance created with Default::default() -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1882:17: binding's name is too similar to existing binding -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1894:17: binding's name is too similar to existing binding -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1906:9: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1917:9: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1923:9: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1956:9: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1962:9: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1963:22: casting `usize` to `u8` may truncate the value -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1964:22: casting `usize` to `u8` may truncate the value -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1965:22: casting `usize` to `u8` may truncate the value -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1966:22: casting `usize` to `u8` may truncate the value -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1980:17: binding's name is too similar to existing binding -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1980:24: stripping a prefix manually -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1986:17: binding's name is too similar to existing binding -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:2016:5: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:61:5: you should put `CompileMode` between ticks in the documentation -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:63:12: you should put `CompileKind` between ticks in the documentation -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:67:7: you should put `CARGO_DEFAULT_LIB_METADATA[^4` between ticks in the documentation -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:68:5: you should put `package_id` between ticks in the documentation -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:71:19: you should put `test/bench/for_host/edition` between ticks in the documentation -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:755:52: this `match` has identical arm bodies -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:77:5: you should put `is_std` between ticks in the documentation -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:816:5: this function has too many lines (127/100) -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:863:64: binding's name is too similar to existing binding -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:875:33: binding's name is too similar to existing binding -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:876:32: binding's name is too similar to existing binding -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:896:30: binding's name is too similar to existing binding -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:897:30: binding's name is too similar to existing binding -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:991:37: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:12:5: you should put `src/librustc_jobserver/lib.rs` between ticks in the documentation -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:282:30: called `filter(..).map(..)` on an `Iterator` -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:329:13: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:332:23: this argument is passed by value, but not consumed in the function body -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:34:53: you should put `NeedsToken` between ticks in the documentation -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:35:6: you should put `ReleaseToken` between ticks in the documentation -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:37:6: you should put `NeedsToken` between ticks in the documentation -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:40:56: you should put `NeedsToken` between ticks in the documentation -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:40:5: you should put `NeedsToken` between ticks in the documentation -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:43:6: you should put `ReleaseToken` between ticks in the documentation -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:749:13: unnecessary boolean `not` operation -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:786:26: unused `self` argument -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:81:61: you should put `DrainState` between ticks in the documentation -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:865:13: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:871:13: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:890:9: unused `self` argument -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:93:24: you should put `JobQueue` between ticks in the documentation -cargo-0.49.0/src/cargo/core/compiler/links.rs:8:1: item name ends with its containing module's name -cargo-0.49.0/src/cargo/core/compiler/mod.rs:1016:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/compiler/mod.rs:1094:19: redundant closure found -cargo-0.49.0/src/cargo/core/compiler/mod.rs:1131:1: this function's return value is unnecessarily wrapped by `Result` -cargo-0.49.0/src/cargo/core/compiler/mod.rs:1277:5: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/core/compiler/mod.rs:179:1: this function has too many lines (162/100) -cargo-0.49.0/src/cargo/core/compiler/mod.rs:198:78: redundant closure found -cargo-0.49.0/src/cargo/core/compiler/mod.rs:201:25: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -cargo-0.49.0/src/cargo/core/compiler/mod.rs:267:9: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/core/compiler/mod.rs:324:5: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/core/compiler/mod.rs:364:5: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/core/compiler/mod.rs:364:5: this function's return value is unnecessarily wrapped by `Result` -cargo-0.49.0/src/cargo/core/compiler/mod.rs:392:45: redundant closure found -cargo-0.49.0/src/cargo/core/compiler/mod.rs:415:23: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -cargo-0.49.0/src/cargo/core/compiler/mod.rs:667:15: binding's name is too similar to existing binding -cargo-0.49.0/src/cargo/core/compiler/mod.rs:693:1: this function's return value is unnecessarily wrapped by `Result` -cargo-0.49.0/src/cargo/core/compiler/mod.rs:725:42: this `match` has identical arm bodies -cargo-0.49.0/src/cargo/core/compiler/mod.rs:736:1: this function has too many lines (141/100) -cargo-0.49.0/src/cargo/core/compiler/mod.rs:73:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/compiler/mod.rs:777:12: unnecessary boolean `not` operation -cargo-0.49.0/src/cargo/core/compiler/mod.rs:873:5: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/core/compiler/output_depinfo.rs:41:13: wildcard match will miss any future added variants -cargo-0.49.0/src/cargo/core/compiler/rustdoc.rs:16:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/core/compiler/rustdoc.rs:57:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/core/compiler/rustdoc.rs:72:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/compiler/standard_lib.rs:134:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/compiler/standard_lib.rs:16:1: this function could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/compiler/standard_lib.rs:30:28: redundant closure found -cargo-0.49.0/src/cargo/core/compiler/standard_lib.rs:34:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/compiler/timings.rs:16:1: more than 3 bools in a struct -cargo-0.49.0/src/cargo/core/compiler/timings.rs:192:64: this argument is passed by value, but not consumed in the function body -cargo-0.49.0/src/cargo/core/compiler/timings.rs:212:58: this argument is passed by value, but not consumed in the function body -cargo-0.49.0/src/cargo/core/compiler/timings.rs:234:13: non-binding `let` on a type that implements `Drop` -cargo-0.49.0/src/cargo/core/compiler/timings.rs:355:13: casting `f64` to `u32` may lose the sign of the value -cargo-0.49.0/src/cargo/core/compiler/timings.rs:355:13: casting `f64` to `u32` may truncate the value -cargo-0.49.0/src/cargo/core/compiler/timings.rs:397:38: casting `f64` to `u32` may lose the sign of the value -cargo-0.49.0/src/cargo/core/compiler/timings.rs:397:38: casting `f64` to `u32` may truncate the value -cargo-0.49.0/src/cargo/core/compiler/timings.rs:484:9: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/core/compiler/timings.rs:605:38: you should put `rmeta_time` between ticks in the documentation -cargo-0.49.0/src/cargo/core/compiler/timings.rs:605:50: you should put `codegen_time` between ticks in the documentation -cargo-0.49.0/src/cargo/core/compiler/timings.rs:641:26: literal non-ASCII character detected -cargo-0.49.0/src/cargo/core/compiler/unit.rs:100:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/compiler/unit.rs:151:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/core/compiler/unit.rs:161:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/compiler/unit.rs:35:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/core/compiler/unit_dependencies.rs:154:29: you should put `state.unit_dependencies` between ticks in the documentation -cargo-0.49.0/src/cargo/core/compiler/unit_dependencies.rs:213:1: this function has too many lines (110/100) -cargo-0.49.0/src/cargo/core/compiler/unit_dependencies.rs:329:13: called `filter(..).map(..)` on an `Iterator` -cargo-0.49.0/src/cargo/core/compiler/unit_dependencies.rs:480:5: called `find(..).map(..)` on an `Iterator` -cargo-0.49.0/src/cargo/core/compiler/unit_dependencies.rs:511:5: called `find(..).map(..)` on an `Iterator` -cargo-0.49.0/src/cargo/core/compiler/unit_dependencies.rs:52:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/compiler/unit_dependencies.rs:52:1: item name ends with its containing module's name -cargo-0.49.0/src/cargo/core/compiler/unit_graph.rs:65:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/compiler/unit_graph.rs:65:1: item name ends with its containing module's name -cargo-0.49.0/src/cargo/core/dependency.rs:157:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/dependency.rs:182:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/dependency.rs:203:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/dependency.rs:224:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/dependency.rs:23:1: more than 3 bools in a struct -cargo-0.49.0/src/cargo/core/dependency.rs:248:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/dependency.rs:270:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/dependency.rs:274:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/dependency.rs:278:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/dependency.rs:287:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/dependency.rs:291:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/dependency.rs:305:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/dependency.rs:311:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/dependency.rs:319:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/dependency.rs:337:75: redundant closure found -cargo-0.49.0/src/cargo/core/dependency.rs:397:56: redundant closure found -cargo-0.49.0/src/cargo/core/dependency.rs:403:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/dependency.rs:408:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/dependency.rs:415:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/dependency.rs:419:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/dependency.rs:424:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/dependency.rs:428:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/dependency.rs:433:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/dependency.rs:438:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/dependency.rs:443:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/dependency.rs:449:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/dependency.rs:450:9: unnecessary `!=` operation -cargo-0.49.0/src/cargo/core/features.rs:119:17: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/features.rs:229:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/features.rs:274:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/features.rs:278:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/features.rs:306:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/features.rs:338:1: more than 3 bools in a struct -cargo-0.49.0/src/cargo/core/features.rs:362:25: consider using `Option` instead of `Option>` or a custom enum if you need to distinguish all 3 cases -cargo-0.49.0/src/cargo/core/features.rs:380:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/features.rs:401:9: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/core/features.rs:409:9: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/core/features.rs:412:45: redundant closure found -cargo-0.49.0/src/cargo/core/features.rs:416:9: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/core/features.rs:419:45: redundant closure found -cargo-0.49.0/src/cargo/core/features.rs:424:9: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/core/features.rs:431:9: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/core/features.rs:477:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/features.rs:509:1: this function could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/features.rs:518:5: called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead -cargo-0.49.0/src/cargo/core/features.rs:542:1: this function could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/features.rs:543:37: redundant closure found -cargo-0.49.0/src/cargo/core/features.rs:547:60: redundant closure found -cargo-0.49.0/src/cargo/core/features.rs:556:1: item name ends with its containing module's name -cargo-0.49.0/src/cargo/core/features.rs:563:1: item name ends with its containing module's name -cargo-0.49.0/src/cargo/core/manifest.rs:116:13: usage of wildcard import for enum variants -cargo-0.49.0/src/cargo/core/manifest.rs:118:58: redundant closure found -cargo-0.49.0/src/cargo/core/manifest.rs:130:13: usage of wildcard import for enum variants -cargo-0.49.0/src/cargo/core/manifest.rs:143:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:159:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:162:34: redundant closure found -cargo-0.49.0/src/cargo/core/manifest.rs:169:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:17:5: usage of wildcard import -cargo-0.49.0/src/cargo/core/manifest.rs:189:1: more than 3 bools in a struct -cargo-0.49.0/src/cargo/core/manifest.rs:215:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:222:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:22:1: item name ends with its containing module's name -cargo-0.49.0/src/cargo/core/manifest.rs:360:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:407:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:410:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:413:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:416:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:419:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:422:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:425:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:431:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:438:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:444:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:447:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:450:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:453:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:456:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:459:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:462:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:466:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:470:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:477:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:481:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:488:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/manifest.rs:512:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:516:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:520:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:524:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:528:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:538:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:557:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:561:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:565:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:569:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:577:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:581:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:588:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:617:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:632:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:648:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:659:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:66:1: item name ends with its containing module's name -cargo-0.49.0/src/cargo/core/manifest.rs:670:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:693:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:708:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:723:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:726:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:729:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:735:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:738:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:741:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:744:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:747:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:751:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:754:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:757:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:760:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:763:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:767:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:776:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:780:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:787:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:798:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:800:56: redundant closure found -cargo-0.49.0/src/cargo/core/manifest.rs:805:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:809:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:818:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:823:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:828:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:831:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:834:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:839:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:85:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/core/manifest.rs:888:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/manifest.rs:936:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/package.rs:1075:28: redundant closure found -cargo-0.49.0/src/cargo/core/package.rs:160:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/package.rs:170:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/package.rs:174:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/package.rs:182:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/package.rs:186:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/package.rs:190:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/package.rs:194:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/package.rs:198:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/package.rs:202:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/package.rs:206:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/package.rs:210:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/package.rs:217:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/package.rs:221:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/package.rs:222:35: redundant closure found -cargo-0.49.0/src/cargo/core/package.rs:226:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/package.rs:227:35: redundant closure found -cargo-0.49.0/src/cargo/core/package.rs:230:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/package.rs:239:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/package.rs:249:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/package.rs:287:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/core/package.rs:385:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/package.rs:421:5: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) -cargo-0.49.0/src/cargo/core/package.rs:425:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/package.rs:452:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/package.rs:453:60: redundant closure found -cargo-0.49.0/src/cargo/core/package.rs:459:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/package.rs:473:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/package.rs:587:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/package.rs:682:46: casting `f64` to `u64` may lose the sign of the value -cargo-0.49.0/src/cargo/core/package.rs:682:46: casting `f64` to `u64` may truncate the value -cargo-0.49.0/src/cargo/core/package.rs:682:63: casting `f64` to `u64` may lose the sign of the value -cargo-0.49.0/src/cargo/core/package.rs:682:63: casting `f64` to `u64` may truncate the value -cargo-0.49.0/src/cargo/core/package.rs:731:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/package.rs:790:13: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -cargo-0.49.0/src/cargo/core/package.rs:988:9: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -cargo-0.49.0/src/cargo/core/package_id.rs:115:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/package_id.rs:124:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/package_id.rs:139:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/package_id.rs:142:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/package_id.rs:145:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/package_id.rs:149:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/package_id.rs:157:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/package_id.rs:161:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/package_id.rs:169:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/package_id.rs:174:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/core/package_id_spec.rs:101:39: redundant closure found -cargo-0.49.0/src/cargo/core/package_id_spec.rs:143:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/package_id_spec.rs:147:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/package_id_spec.rs:151:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/package_id_spec.rs:160:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/package_id_spec.rs:179:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/package_id_spec.rs:212:9: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/core/package_id_spec.rs:231:9: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -cargo-0.49.0/src/cargo/core/package_id_spec.rs:51:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/package_id_spec.rs:77:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/package_id_spec.rs:88:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/profiles.rs:1004:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/profiles.rs:1014:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/profiles.rs:1018:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/profiles.rs:1028:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/profiles.rs:106:9: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/core/profiles.rs:143:5: this function's return value is unnecessarily wrapped by `Result` -cargo-0.49.0/src/cargo/core/profiles.rs:286:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/profiles.rs:294:40: unnecessary boolean `not` operation -cargo-0.49.0/src/cargo/core/profiles.rs:30:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/profiles.rs:342:25: `maker` is being shadowed -cargo-0.49.0/src/cargo/core/profiles.rs:370:41: unused `self` argument -cargo-0.49.0/src/cargo/core/profiles.rs:370:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/profiles.rs:372:9: field assignment outside of initializer for an instance created with Default::default() -cargo-0.49.0/src/cargo/core/profiles.rs:382:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/profiles.rs:383:28: unnecessary boolean `not` operation -cargo-0.49.0/src/cargo/core/profiles.rs:397:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/profiles.rs:405:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/profiles.rs:607:1: more than 3 bools in a struct -cargo-0.49.0/src/cargo/core/profiles.rs:909:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/profiles.rs:923:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/profiles.rs:934:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/profiles.rs:987:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/registry.rs:111:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/registry.rs:127:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/registry.rs:168:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/registry.rs:19:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/registry.rs:240:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/registry.rs:26:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/registry.rs:344:49: redundant closure found -cargo-0.49.0/src/cargo/core/registry.rs:369:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/registry.rs:424:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/registry.rs:49:1: item name ends with its containing module's name -cargo-0.49.0/src/cargo/core/registry.rs:520:17: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -cargo-0.49.0/src/cargo/core/registry.rs:763:53: redundant closure found -cargo-0.49.0/src/cargo/core/registry.rs:765:53: redundant closure found -cargo-0.49.0/src/cargo/core/registry.rs:807:14: redundant closure found -cargo-0.49.0/src/cargo/core/registry.rs:814:53: redundant closure found -cargo-0.49.0/src/cargo/core/resolver/conflict_cache.rs:197:29: redundant closure found -cargo-0.49.0/src/cargo/core/resolver/conflict_cache.rs:41:38: called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead -cargo-0.49.0/src/cargo/core/resolver/context.rs:274:53: redundant closure found -cargo-0.49.0/src/cargo/core/resolver/context.rs:297:9: called `filter(..).map(..)` on an `Iterator` -cargo-0.49.0/src/cargo/core/resolver/context.rs:42:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/core/resolver/context.rs:74:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/resolver/encode.rs:156:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/resolver/encode.rs:156:5: this function has too many lines (164/100) -cargo-0.49.0/src/cargo/core/resolver/encode.rs:339:17: wildcard match will miss any future added variants -cargo-0.49.0/src/cargo/core/resolver/encode.rs:438:5: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/core/resolver/encode.rs:449:5: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/core/resolver/encode.rs:529:34: redundant closure found -cargo-0.49.0/src/cargo/core/resolver/encode.rs:602:59: redundant closure found -cargo-0.49.0/src/cargo/core/resolver/encode.rs:623:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/core/resolver/encode.rs:652:27: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -cargo-0.49.0/src/cargo/core/resolver/encode.rs:674:51: redundant closure found -cargo-0.49.0/src/cargo/core/resolver/errors.rs:103:22: redundant closure found -cargo-0.49.0/src/cargo/core/resolver/errors.rs:104:22: redundant closure found -cargo-0.49.0/src/cargo/core/resolver/errors.rs:206:9: unnecessary boolean `not` operation -cargo-0.49.0/src/cargo/core/resolver/errors.rs:257:45: redundant closure found -cargo-0.49.0/src/cargo/core/resolver/errors.rs:27:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/resolver/errors.rs:305:17: calling `push_str()` using a single-character string literal -cargo-0.49.0/src/cargo/core/resolver/errors.rs:70:1: this function has too many lines (207/100) -cargo-0.49.0/src/cargo/core/resolver/features.rs:104:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/core/resolver/features.rs:111:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/resolver/features.rs:162:56: redundant closure found -cargo-0.49.0/src/cargo/core/resolver/features.rs:179:1: item name ends with its containing module's name -cargo-0.49.0/src/cargo/core/resolver/features.rs:186:23: you should put `RequestedFeatures` between ticks in the documentation -cargo-0.49.0/src/cargo/core/resolver/features.rs:187:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/resolver/features.rs:199:23: you should put `RequestedFeatures` between ticks in the documentation -cargo-0.49.0/src/cargo/core/resolver/features.rs:200:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/resolver/features.rs:209:9: called `filter(..).map(..)` on an `Iterator` -cargo-0.49.0/src/cargo/core/resolver/features.rs:221:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/resolver/features.rs:231:21: you should put `pkg_id/is_build` between ticks in the documentation -cargo-0.49.0/src/cargo/core/resolver/features.rs:233:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/resolver/features.rs:247:58: redundant closure found -cargo-0.49.0/src/cargo/core/resolver/features.rs:278:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/resolver/features.rs:394:27: you should put `FeatureValue` between ticks in the documentation -cargo-0.49.0/src/cargo/core/resolver/features.rs:460:19: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -cargo-0.49.0/src/cargo/core/resolver/features.rs:480:24: you should put `FeatureValues` between ticks in the documentation -cargo-0.49.0/src/cargo/core/resolver/features.rs:496:24: you should put `FeatureValues` between ticks in the documentation -cargo-0.49.0/src/cargo/core/resolver/features.rs:561:28: called `filter(..).map(..)` on an `Iterator` -cargo-0.49.0/src/cargo/core/resolver/features.rs:58:1: item name ends with its containing module's name -cargo-0.49.0/src/cargo/core/resolver/features.rs:67:1: more than 3 bools in a struct -cargo-0.49.0/src/cargo/core/resolver/mod.rs:1017:5: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/core/resolver/mod.rs:1045:57: redundant closure found -cargo-0.49.0/src/cargo/core/resolver/mod.rs:122:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/resolver/mod.rs:142:44: redundant closure found -cargo-0.49.0/src/cargo/core/resolver/mod.rs:180:1: this function has too many lines (225/100) -cargo-0.49.0/src/cargo/core/resolver/mod.rs:311:17: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -cargo-0.49.0/src/cargo/core/resolver/mod.rs:421:52: called `filter_map(..).next()` on an `Iterator`. This is more succinctly expressed by calling `.find_map(..)` instead. -cargo-0.49.0/src/cargo/core/resolver/mod.rs:437:33: called `filter(..).map(..)` on an `Iterator` -cargo-0.49.0/src/cargo/core/resolver/mod.rs:457:69: called `filter_map(..).next()` on an `Iterator`. This is more succinctly expressed by calling `.find_map(..)` instead. -cargo-0.49.0/src/cargo/core/resolver/mod.rs:470:37: binding's name is too similar to existing binding -cargo-0.49.0/src/cargo/core/resolver/mod.rs:480:37: called `filter(..).map(..)` on an `Iterator` -cargo-0.49.0/src/cargo/core/resolver/mod.rs:607:11: this argument is passed by value, but not consumed in the function body -cargo-0.49.0/src/cargo/core/resolver/mod.rs:631:21: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -cargo-0.49.0/src/cargo/core/resolver/mod.rs:942:15: unnecessary boolean `not` operation -cargo-0.49.0/src/cargo/core/resolver/mod.rs:988:20: redundant else block -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:120:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:132:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:199:24: redundant else block -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:235:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:239:5: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:255:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:259:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:263:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:269:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:273:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:274:9: called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:280:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:284:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:288:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:292:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:296:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:300:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:315:13: called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:354:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:362:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:60:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:76:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:90:35: called `filter(..).map(..)` on an `Iterator` -cargo-0.49.0/src/cargo/core/resolver/types.rs:111:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/resolver/types.rs:121:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/resolver/types.rs:141:19: you should put `ResolveOpts` between ticks in the documentation -cargo-0.49.0/src/cargo/core/resolver/types.rs:142:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/resolver/types.rs:149:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/resolver/types.rs:181:9: called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead -cargo-0.49.0/src/cargo/core/resolver/types.rs:187:5: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) -cargo-0.49.0/src/cargo/core/resolver/types.rs:261:5: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) -cargo-0.49.0/src/cargo/core/shell.rs:113:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/shell.rs:130:9: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -cargo-0.49.0/src/cargo/core/shell.rs:148:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/shell.rs:153:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/shell.rs:163:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/shell.rs:18:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/shell.rs:198:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/shell.rs:206:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/shell.rs:214:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/shell.rs:228:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/shell.rs:239:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/shell.rs:250:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/shell.rs:259:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/shell.rs:267:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/shell.rs:26:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/shell.rs:277:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/shell.rs:282:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/shell.rs:314:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/shell.rs:322:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/shell.rs:330:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/shell.rs:98:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/source/mod.rs:103:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/source/mod.rs:247:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/core/source/mod.rs:261:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/source/mod.rs:268:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/source/mod.rs:273:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/source/mod.rs:291:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/source/mod.rs:302:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/source/mod.rs:307:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/source/mod.rs:31:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/source/mod.rs:37:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/source/mod.rs:39:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/source/mod.rs:47:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/source/mod.rs:50:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/source/mod.rs:52:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/source/mod.rs:63:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/source/mod.rs:74:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/source/mod.rs:83:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/source/source_id.rs:107:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/source/source_id.rs:128:50: redundant closure found -cargo-0.49.0/src/cargo/core/source/source_id.rs:147:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/source/source_id.rs:156:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/source/source_id.rs:162:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/source/source_id.rs:166:19: you should put `SourceId` between ticks in the documentation -cargo-0.49.0/src/cargo/core/source/source_id.rs:167:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/source/source_id.rs:171:19: you should put `SourceId` between ticks in the documentation -cargo-0.49.0/src/cargo/core/source/source_id.rs:172:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/source/source_id.rs:178:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/source/source_id.rs:187:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/source/source_id.rs:18:74: calling `std::sync::Mutex::default()` is more clear than this expression -cargo-0.49.0/src/cargo/core/source/source_id.rs:195:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/source/source_id.rs:207:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/source/source_id.rs:213:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/source/source_id.rs:217:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/source/source_id.rs:225:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/source/source_id.rs:228:16: use Option::map_or_else instead of an if let/else -cargo-0.49.0/src/cargo/core/source/source_id.rs:236:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/source/source_id.rs:241:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/source/source_id.rs:252:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/source/source_id.rs:257:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/source/source_id.rs:262:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/source/source_id.rs:305:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/source/source_id.rs:310:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/source/source_id.rs:318:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/source/source_id.rs:326:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/source/source_id.rs:355:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/source/source_id.rs:393:61: this `match` has identical arm bodies -cargo-0.49.0/src/cargo/core/source/source_id.rs:394:42: this `match` has identical arm bodies -cargo-0.49.0/src/cargo/core/source/source_id.rs:395:42: this `match` has identical arm bodies -cargo-0.49.0/src/cargo/core/source/source_id.rs:397:71: this `match` has identical arm bodies -cargo-0.49.0/src/cargo/core/source/source_id.rs:397:71: this `match` has identical arm bodies -cargo-0.49.0/src/cargo/core/source/source_id.rs:398:47: this `match` has identical arm bodies -cargo-0.49.0/src/cargo/core/source/source_id.rs:398:47: this `match` has identical arm bodies -cargo-0.49.0/src/cargo/core/source/source_id.rs:399:47: this `match` has identical arm bodies -cargo-0.49.0/src/cargo/core/source/source_id.rs:399:47: this `match` has identical arm bodies -cargo-0.49.0/src/cargo/core/source/source_id.rs:401:63: this `match` has identical arm bodies -cargo-0.49.0/src/cargo/core/source/source_id.rs:401:63: this `match` has identical arm bodies -cargo-0.49.0/src/cargo/core/source/source_id.rs:401:63: this `match` has identical arm bodies -cargo-0.49.0/src/cargo/core/source/source_id.rs:402:43: this `match` has identical arm bodies -cargo-0.49.0/src/cargo/core/source/source_id.rs:402:43: this `match` has identical arm bodies -cargo-0.49.0/src/cargo/core/source/source_id.rs:402:43: this `match` has identical arm bodies -cargo-0.49.0/src/cargo/core/source/source_id.rs:403:43: this `match` has identical arm bodies -cargo-0.49.0/src/cargo/core/source/source_id.rs:403:43: this `match` has identical arm bodies -cargo-0.49.0/src/cargo/core/source/source_id.rs:403:43: this `match` has identical arm bodies -cargo-0.49.0/src/cargo/core/source/source_id.rs:406:21: usage of wildcard import for enum variants -cargo-0.49.0/src/cargo/core/source/source_id.rs:412:41: this `match` has identical arm bodies -cargo-0.49.0/src/cargo/core/source/source_id.rs:413:36: this `match` has identical arm bodies -cargo-0.49.0/src/cargo/core/source/source_id.rs:414:36: this `match` has identical arm bodies -cargo-0.49.0/src/cargo/core/source/source_id.rs:420:47: this `match` has identical arm bodies -cargo-0.49.0/src/cargo/core/source/source_id.rs:420:47: this `match` has identical arm bodies -cargo-0.49.0/src/cargo/core/source/source_id.rs:494:42: this `match` has identical arm bodies -cargo-0.49.0/src/cargo/core/source/source_id.rs:512:17: integer type suffix should be separated by an underscore -cargo-0.49.0/src/cargo/core/source/source_id.rs:513:17: integer type suffix should be separated by an underscore -cargo-0.49.0/src/cargo/core/source/source_id.rs:517:17: integer type suffix should be separated by an underscore -cargo-0.49.0/src/cargo/core/source/source_id.rs:518:17: integer type suffix should be separated by an underscore -cargo-0.49.0/src/cargo/core/source/source_id.rs:525:17: integer type suffix should be separated by an underscore -cargo-0.49.0/src/cargo/core/source/source_id.rs:526:17: integer type suffix should be separated by an underscore -cargo-0.49.0/src/cargo/core/source/source_id.rs:530:17: integer type suffix should be separated by an underscore -cargo-0.49.0/src/cargo/core/source/source_id.rs:531:17: integer type suffix should be separated by an underscore -cargo-0.49.0/src/cargo/core/source/source_id.rs:535:33: integer type suffix should be separated by an underscore -cargo-0.49.0/src/cargo/core/source/source_id.rs:536:37: integer type suffix should be separated by an underscore -cargo-0.49.0/src/cargo/core/source/source_id.rs:537:42: integer type suffix should be separated by an underscore -cargo-0.49.0/src/cargo/core/source/source_id.rs:538:38: integer type suffix should be separated by an underscore -cargo-0.49.0/src/cargo/core/source/source_id.rs:548:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/core/source/source_id.rs:597:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/summary.rs:103:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/summary.rs:123:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/summary.rs:150:1: this function has too many lines (141/100) -cargo-0.49.0/src/cargo/core/summary.rs:158:9: usage of wildcard import for enum variants -cargo-0.49.0/src/cargo/core/summary.rs:181:21: unnecessary boolean `not` operation -cargo-0.49.0/src/cargo/core/summary.rs:192:28: redundant else block -cargo-0.49.0/src/cargo/core/summary.rs:258:32: redundant else block -cargo-0.49.0/src/cargo/core/summary.rs:281:28: redundant else block -cargo-0.49.0/src/cargo/core/summary.rs:303:28: redundant else block -cargo-0.49.0/src/cargo/core/summary.rs:321:51: this `match` has identical arm bodies -cargo-0.49.0/src/cargo/core/summary.rs:344:5: you should put `FeatureValue` between ticks in the documentation -cargo-0.49.0/src/cargo/core/summary.rs:350:85: you should put `FeatureValue` between ticks in the documentation -cargo-0.49.0/src/cargo/core/summary.rs:36:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/summary.rs:378:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/summary.rs:386:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/summary.rs:387:13: usage of wildcard import for enum variants -cargo-0.49.0/src/cargo/core/summary.rs:407:13: usage of wildcard import for enum variants -cargo-0.49.0/src/cargo/core/summary.rs:69:34: redundant closure found -cargo-0.49.0/src/cargo/core/summary.rs:75:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/summary.rs:78:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/summary.rs:81:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/summary.rs:84:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/summary.rs:87:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/summary.rs:90:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/summary.rs:93:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/summary.rs:96:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/summary.rs:99:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/workspace.rs:1019:59: called `filter(..).map(..)` on an `Iterator` -cargo-0.49.0/src/cargo/core/workspace.rs:1056:5: this function's return value is unnecessarily wrapped by `Result` -cargo-0.49.0/src/cargo/core/workspace.rs:113:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/core/workspace.rs:1157:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/core/workspace.rs:128:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/core/workspace.rs:150:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/workspace.rs:159:16: redundant else block -cargo-0.49.0/src/cargo/core/workspace.rs:197:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/workspace.rs:225:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/workspace.rs:255:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/workspace.rs:267:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/workspace.rs:329:37: you should put `VirtualManifest` between ticks in the documentation -cargo-0.49.0/src/cargo/core/workspace.rs:410:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/workspace.rs:440:9: this function's return value is unnecessarily wrapped by `Result` -cargo-0.49.0/src/cargo/core/workspace.rs:511:32: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -cargo-0.49.0/src/cargo/core/workspace.rs:561:25: literal non-ASCII character detected -cargo-0.49.0/src/cargo/core/workspace.rs:613:13: called `filter_map(..).map(..)` on an `Iterator` -cargo-0.49.0/src/cargo/core/workspace.rs:615:22: redundant closure found -cargo-0.49.0/src/cargo/core/workspace.rs:688:35: called `filter(..).map(..)` on an `Iterator` -cargo-0.49.0/src/cargo/core/workspace.rs:762:27: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -cargo-0.49.0/src/cargo/core/workspace.rs:784:17: unnecessary boolean `not` operation -cargo-0.49.0/src/cargo/core/workspace.rs:849:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/workspace.rs:893:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/core/workspace.rs:906:24: redundant else block -cargo-0.49.0/src/cargo/core/workspace.rs:932:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/lib.rs:177:1: this function could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/lib.rs:180:36: redundant closure found -cargo-0.49.0/src/cargo/lib.rs:180:36: redundant closure found -cargo-0.49.0/src/cargo/lib.rs:180:36: redundant closure found -cargo-0.49.0/src/cargo/lib.rs:180:36: redundant closure found -cargo-0.49.0/src/cargo/lib.rs:180:36: redundant closure found -cargo-0.49.0/src/cargo/ops/cargo_clean.rs:205:23: redundant closure found -cargo-0.49.0/src/cargo/ops/cargo_clean.rs:27:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/cargo_clean.rs:27:1: this function has too many lines (120/100) -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:1078:14: redundant closure found -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:109:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:119:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:1227:17: this argument is passed by value, but not consumed in the function body -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:127:35: usage of `FromIterator::from_iter` -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:128:32: called `filter(..).map(..)` on an `Iterator` -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:173:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:205:36: this `match` has identical arm bodies -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:242:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:249:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:258:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:275:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:275:1: this function has too many lines (219/100) -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:468:9: calling `std::collections::HashMap::default()` is more clear than this expression -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:548:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:556:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:574:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:583:21: you should put `CompileFilter` between ticks in the documentation -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:584:5: more than 3 bools in function parameters -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:584:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:592:9: binding's name is too similar to existing binding -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:593:9: binding's name is too similar to existing binding -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:607:13: binding's name is too similar to existing binding -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:612:21: you should put `CompileFilter` between ticks in the documentation -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:613:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:618:9: binding's name is too similar to existing binding -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:641:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:652:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:655:50: this `match` has identical arm bodies -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:673:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:692:49: this `match` has identical arm bodies -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:703:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:729:1: this function has too many lines (205/100) -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:82:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:874:69: redundant closure found -cargo-0.49.0/src/cargo/ops/cargo_doc.rs:20:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/cargo_fetch.rs:15:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/cargo_fetch.rs:27:46: redundant closure found -cargo-0.49.0/src/cargo/ops/cargo_fetch.rs:36:20: called `filter(..).map(..)` on an `Iterator` -cargo-0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:160:5: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:175:5: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:22:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:37:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:37:1: this function has too many lines (171/100) -cargo-0.49.0/src/cargo/ops/cargo_install.rs:13:5: usage of wildcard import -cargo-0.49.0/src/cargo/ops/cargo_install.rs:148:1: more than 3 bools in function parameters -cargo-0.49.0/src/cargo/ops/cargo_install.rs:148:1: this function has too many lines (316/100) -cargo-0.49.0/src/cargo/ops/cargo_install.rs:202:17: redundant closure found -cargo-0.49.0/src/cargo/ops/cargo_install.rs:312:64: redundant closure found -cargo-0.49.0/src/cargo/ops/cargo_install.rs:318:63: called `filter(..).map(..)` on an `Iterator` -cargo-0.49.0/src/cargo/ops/cargo_install.rs:32:13: non-binding `let` on a type that implements `Drop` -cargo-0.49.0/src/cargo/ops/cargo_install.rs:37:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/cargo_install.rs:454:22: redundant closure found -cargo-0.49.0/src/cargo/ops/cargo_install.rs:483:5: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/ops/cargo_install.rs:683:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/cargo_new.rs:101:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/cargo_new.rs:245:5: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/ops/cargo_new.rs:251:5: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/ops/cargo_new.rs:367:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/cargo_new.rs:405:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/cargo_new.rs:489:5: you should put `IgnoreList` between ticks in the documentation -cargo-0.49.0/src/cargo/ops/cargo_new.rs:525:47: you should put `IgnoreList` between ticks in the documentation -cargo-0.49.0/src/cargo/ops/cargo_new.rs:525:9: you should put `format_existing` between ticks in the documentation -cargo-0.49.0/src/cargo/ops/cargo_new.rs:572:34: this `match` has identical arm bodies -cargo-0.49.0/src/cargo/ops/cargo_new.rs:623:1: this function has too many lines (130/100) -cargo-0.49.0/src/cargo/ops/cargo_new.rs:781:5: called `filter_map(..).next()` on an `Iterator`. This is more succinctly expressed by calling `.find_map(..)` instead. -cargo-0.49.0/src/cargo/ops/cargo_new.rs:800:16: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -cargo-0.49.0/src/cargo/ops/cargo_output_metadata.rs:163:36: redundant closure found -cargo-0.49.0/src/cargo/ops/cargo_output_metadata.rs:27:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/cargo_output_metadata.rs:45:45: redundant closure found -cargo-0.49.0/src/cargo/ops/cargo_package.rs:144:1: this function has too many lines (112/100) -cargo-0.49.0/src/cargo/ops/cargo_package.rs:207:13: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -cargo-0.49.0/src/cargo/ops/cargo_package.rs:25:1: more than 3 bools in a struct -cargo-0.49.0/src/cargo/ops/cargo_package.rs:307:54: redundant closure found -cargo-0.49.0/src/cargo/ops/cargo_package.rs:394:5: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/ops/cargo_package.rs:418:21: called `filter(..).map(..)` on an `Iterator` -cargo-0.49.0/src/cargo/ops/cargo_package.rs:425:61: redundant closure found -cargo-0.49.0/src/cargo/ops/cargo_package.rs:459:5: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/ops/cargo_package.rs:66:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/cargo_package.rs:769:29: called `filter(..).map(..)` on an `Iterator` -cargo-0.49.0/src/cargo/ops/cargo_package.rs:93:20: unnecessary boolean `not` operation -cargo-0.49.0/src/cargo/ops/cargo_pkgid.rs:5:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/cargo_read_manifest.rs:14:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/cargo_read_manifest.rs:171:5: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/ops/cargo_read_manifest.rs:37:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/cargo_read_manifest.rs:57:49: redundant closure found -cargo-0.49.0/src/cargo/ops/cargo_read_manifest.rs:69:37: redundant closure found -cargo-0.49.0/src/cargo/ops/cargo_run.rs:25:24: unnecessary boolean `not` operation -cargo-0.49.0/src/cargo/ops/cargo_run.rs:35:9: unnecessary boolean `not` operation -cargo-0.49.0/src/cargo/ops/cargo_run.rs:37:16: redundant else block -cargo-0.49.0/src/cargo/ops/cargo_run.rs:53:9: unnecessary boolean `not` operation -cargo-0.49.0/src/cargo/ops/cargo_run.rs:65:16: redundant else block -cargo-0.49.0/src/cargo/ops/cargo_run.rs:9:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/cargo_test.rs:16:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/cargo_test.rs:43:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/cargo_test.rs:84:17: binding's name is too similar to existing binding -cargo-0.49.0/src/cargo/ops/cargo_uninstall.rs:14:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/cargo_uninstall.rs:7:5: usage of wildcard import -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:147:9: you should put `PackageId` between ticks in the documentation -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:233:21: calling `push_str()` using a single-character string literal -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:244:22: you should put `PackageId` between ticks in the documentation -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:244:63: you should put `PackageId` between ticks in the documentation -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:253:17: unnecessary boolean `not` operation -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:370:5: this function's return value is unnecessarily wrapped by `Result` -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:392:9: called `find(..).map(..)` on an `Iterator` -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:505:8: called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:525:10: this argument is passed by value, but not consumed in the function body -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:542:27: redundant closure found -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:542:5: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:561:20: redundant else block -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:613:5: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:645:41: you should put `BTreeSet` between ticks in the documentation -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:654:42: called `filter(..).map(..)` on an `Iterator` -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:662:14: called `filter(..).map(..)` on an `Iterator` -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:674:17: called `filter(..).map(..)` on an `Iterator` -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:681:17: called `filter(..).map(..)` on an `Iterator` -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:92:19: you should put `InstallTracker` between ticks in the documentation -cargo-0.49.0/src/cargo/ops/fix.rs:200:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/fix.rs:200:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/ops/fix.rs:424:20: called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead -cargo-0.49.0/src/cargo/ops/fix.rs:455:13: binding's name is too similar to existing binding -cargo-0.49.0/src/cargo/ops/fix.rs:506:17: binding's name is too similar to existing binding -cargo-0.49.0/src/cargo/ops/fix.rs:608:9: field assignment outside of initializer for an instance created with Default::default() -cargo-0.49.0/src/cargo/ops/fix.rs:612:42: redundant closure found -cargo-0.49.0/src/cargo/ops/fix.rs:619:48: stripping a prefix manually -cargo-0.49.0/src/cargo/ops/fix.rs:66:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/ops/fix.rs:66:1: more than 3 bools in a struct -cargo-0.49.0/src/cargo/ops/fix.rs:708:18: this `match` has identical arm bodies -cargo-0.49.0/src/cargo/ops/fix.rs:77:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/lockfile.rs:154:13: calling `push_str()` using a single-character string literal -cargo-0.49.0/src/cargo/ops/lockfile.rs:217:9: calling `push_str()` using a single-character string literal -cargo-0.49.0/src/cargo/ops/lockfile.rs:30:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/lockfile.rs:35:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/lockfile.rs:35:1: item name ends with its containing module's name -cargo-0.49.0/src/cargo/ops/lockfile.rs:87:1: this function's return value is unnecessarily wrapped by `Result` -cargo-0.49.0/src/cargo/ops/lockfile.rs:8:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/lockfile.rs:8:1: item name ends with its containing module's name -cargo-0.49.0/src/cargo/ops/registry.rs:150:21: redundant closure found -cargo-0.49.0/src/cargo/ops/registry.rs:188:1: this function has too many lines (130/100) -cargo-0.49.0/src/cargo/ops/registry.rs:196:16: called `filter(..).map(..)` on an `Iterator` -cargo-0.49.0/src/cargo/ops/registry.rs:212:32: unnecessary `!=` operation -cargo-0.49.0/src/cargo/ops/registry.rs:222:53: redundant closure found -cargo-0.49.0/src/cargo/ops/registry.rs:224:44: redundant closure found -cargo-0.49.0/src/cargo/ops/registry.rs:31:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/ops/registry.rs:346:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/registry.rs:346:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/ops/registry.rs:351:26: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -cargo-0.49.0/src/cargo/ops/registry.rs:385:12: this argument is passed by value, but not consumed in the function body -cargo-0.49.0/src/cargo/ops/registry.rs:386:15: this argument is passed by value, but not consumed in the function body -cargo-0.49.0/src/cargo/ops/registry.rs:38:1: more than 3 bools in a struct -cargo-0.49.0/src/cargo/ops/registry.rs:477:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/registry.rs:483:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/registry.rs:503:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/registry.rs:505:38: calling `util::config::CargoHttpConfig::default()` is more clear than this expression -cargo-0.49.0/src/cargo/ops/registry.rs:510:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/registry.rs:529:5: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/ops/registry.rs:53:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/registry.rs:573:22: this `match` has identical arm bodies -cargo-0.49.0/src/cargo/ops/registry.rs:608:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/registry.rs:621:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/registry.rs:671:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/registry.rs:671:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/ops/registry.rs:674:10: this argument is passed by value, but not consumed in the function body -cargo-0.49.0/src/cargo/ops/registry.rs:678:17: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -cargo-0.49.0/src/cargo/ops/registry.rs:730:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/registry.rs:731:16: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -cargo-0.49.0/src/cargo/ops/registry.rs:785:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/registry.rs:794:16: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -cargo-0.49.0/src/cargo/ops/registry.rs:828:14: you should put `SourceId` between ticks in the documentation -cargo-0.49.0/src/cargo/ops/registry.rs:848:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/resolve.rs:199:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/resolve.rs:199:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/ops/resolve.rs:199:1: this function has too many lines (137/100) -cargo-0.49.0/src/cargo/ops/resolve.rs:241:28: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -cargo-0.49.0/src/cargo/ops/resolve.rs:28:1: item name ends with its containing module's name -cargo-0.49.0/src/cargo/ops/resolve.rs:384:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/resolve.rs:417:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/resolve.rs:589:9: `keep` is being shadowed -cargo-0.49.0/src/cargo/ops/resolve.rs:58:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/resolve.rs:58:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/ops/resolve.rs:602:5: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/ops/resolve.rs:75:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/resolve.rs:75:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/ops/tree/graph.rs:129:26: you should put `PackageIds` between ticks in the documentation -cargo-0.49.0/src/cargo/ops/tree/graph.rs:131:47: called `filter(..).map(..)` on an `Iterator` -cargo-0.49.0/src/cargo/ops/tree/graph.rs:152:15: indexing into a vector may panic -cargo-0.49.0/src/cargo/ops/tree/graph.rs:173:9: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/ops/tree/graph.rs:234:46: called `filter(..).flat_map(..)` on an `Iterator` -cargo-0.49.0/src/cargo/ops/tree/graph.rs:328:44: this `match` has identical arm bodies -cargo-0.49.0/src/cargo/ops/tree/graph.rs:330:50: this `match` has identical arm bodies -cargo-0.49.0/src/cargo/ops/tree/graph.rs:563:35: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -cargo-0.49.0/src/cargo/ops/tree/mod.rs:112:11: literal non-ASCII character detected -cargo-0.49.0/src/cargo/ops/tree/mod.rs:113:10: literal non-ASCII character detected -cargo-0.49.0/src/cargo/ops/tree/mod.rs:114:10: literal non-ASCII character detected -cargo-0.49.0/src/cargo/ops/tree/mod.rs:115:12: literal non-ASCII character detected -cargo-0.49.0/src/cargo/ops/tree/mod.rs:126:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/tree/mod.rs:21:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/ops/tree/mod.rs:21:1: more than 3 bools in a struct -cargo-0.49.0/src/cargo/ops/tree/mod.rs:360:30: this `match` has identical arm bodies -cargo-0.49.0/src/cargo/ops/tree/mod.rs:58:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/ops/vendor.rs:14:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/ops/vendor.rs:21:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/ops/vendor.rs:314:34: this `match` has identical arm bodies -cargo-0.49.0/src/cargo/ops/vendor.rs:324:13: wildcard match will miss any future added variants -cargo-0.49.0/src/cargo/ops/vendor.rs:70:1: this function has too many lines (175/100) -cargo-0.49.0/src/cargo/sources/config.rs:102:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/sources/config.rs:135:67: redundant closure found -cargo-0.49.0/src/cargo/sources/config.rs:206:36: this argument is passed by value, but not consumed in the function body -cargo-0.49.0/src/cargo/sources/config.rs:282:9: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/sources/config.rs:70:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/sources/config.rs:81:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/sources/config.rs:97:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/sources/directory.rs:14:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/sources/directory.rs:90:56: redundant closure found -cargo-0.49.0/src/cargo/sources/git/source.rs:14:1: item name ends with its containing module's name -cargo-0.49.0/src/cargo/sources/git/source.rs:25:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/sources/git/source.rs:49:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/sources/git/source.rs:53:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/sources/git/source.rs:69:20: comparison to empty slice -cargo-0.49.0/src/cargo/sources/git/utils.rs:1025:19: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -cargo-0.49.0/src/cargo/sources/git/utils.rs:1158:9: stripping a suffix manually -cargo-0.49.0/src/cargo/sources/git/utils.rs:176:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/sources/git/utils.rs:180:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/sources/git/utils.rs:184:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/sources/git/utils.rs:188:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/sources/git/utils.rs:242:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/sources/git/utils.rs:253:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/sources/git/utils.rs:262:13: unnecessary boolean `not` operation -cargo-0.49.0/src/cargo/sources/git/utils.rs:289:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/sources/git/utils.rs:294:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/sources/git/utils.rs:298:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/sources/git/utils.rs:308:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/sources/git/utils.rs:472:9: non-binding `let` on a type that implements `Drop` -cargo-0.49.0/src/cargo/sources/git/utils.rs:489:9: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/sources/git/utils.rs:503:9: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/sources/git/utils.rs:528:28: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -cargo-0.49.0/src/cargo/sources/git/utils.rs:537:21: non-binding `let` on a type that implements `Drop` -cargo-0.49.0/src/cargo/sources/git/utils.rs:588:1: this function has too many lines (135/100) -cargo-0.49.0/src/cargo/sources/git/utils.rs:758:9: calling `push_str()` using a single-character string literal -cargo-0.49.0/src/cargo/sources/git/utils.rs:858:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/sources/path.rs:129:44: this `match` has identical arm bodies -cargo-0.49.0/src/cargo/sources/path.rs:143:44: this `match` has identical arm bodies -cargo-0.49.0/src/cargo/sources/path.rs:15:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/sources/path.rs:282:50: redundant closure found -cargo-0.49.0/src/cargo/sources/path.rs:313:21: binding's name is too similar to existing binding -cargo-0.49.0/src/cargo/sources/path.rs:314:21: binding's name is too similar to existing binding -cargo-0.49.0/src/cargo/sources/path.rs:319:21: binding's name is too similar to existing binding -cargo-0.49.0/src/cargo/sources/path.rs:339:9: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/sources/path.rs:339:9: this function's return value is unnecessarily wrapped by `Result` -cargo-0.49.0/src/cargo/sources/path.rs:380:9: unused `self` argument -cargo-0.49.0/src/cargo/sources/path.rs:419:50: redundant closure found -cargo-0.49.0/src/cargo/sources/path.rs:429:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/sources/path.rs:460:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/sources/path.rs:473:43: redundant closure found -cargo-0.49.0/src/cargo/sources/path.rs:482:43: redundant closure found -cargo-0.49.0/src/cargo/sources/path.rs:63:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/sources/path.rs:77:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/sources/path.rs:98:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/sources/registry/index.rs:117:23: integer type suffix should be separated by an underscore -cargo-0.49.0/src/cargo/sources/registry/index.rs:121:70: integer type suffix should be separated by an underscore -cargo-0.49.0/src/cargo/sources/registry/index.rs:167:1: item name ends with its containing module's name -cargo-0.49.0/src/cargo/sources/registry/index.rs:215:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/sources/registry/index.rs:324:23: redundant closure found -cargo-0.49.0/src/cargo/sources/registry/index.rs:393:25: called `filter(..).map(..)` on an `Iterator` -cargo-0.49.0/src/cargo/sources/registry/index.rs:468:40: you should put `SourceId` between ticks in the documentation -cargo-0.49.0/src/cargo/sources/registry/index.rs:590:9: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/sources/registry/index.rs:648:17: binding's name is too similar to existing binding -cargo-0.49.0/src/cargo/sources/registry/index.rs:736:1: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) -cargo-0.49.0/src/cargo/sources/registry/index.rs:95:37: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -cargo-0.49.0/src/cargo/sources/registry/local.rs:12:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/sources/registry/mod.rs:192:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/sources/registry/mod.rs:203:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/sources/registry/mod.rs:229:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/sources/registry/mod.rs:372:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/sources/registry/mod.rs:373:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/sources/registry/mod.rs:375:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/sources/registry/mod.rs:381:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/sources/registry/mod.rs:382:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/sources/registry/mod.rs:383:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/sources/registry/mod.rs:384:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/sources/registry/mod.rs:452:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/sources/registry/mod.rs:582:20: redundant else block -cargo-0.49.0/src/cargo/sources/registry/mod.rs:621:9: unnecessary `!=` operation -cargo-0.49.0/src/cargo/sources/registry/remote.rs:139:17: unused `self` argument -cargo-0.49.0/src/cargo/sources/registry/remote.rs:32:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/sources/registry/remote.rs:72:13: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -cargo-0.49.0/src/cargo/sources/replaced.rs:12:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/sources/replaced.rs:5:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/util/canonical_url.rs:19:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/canonical_url.rs:65:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/command_prelude.rs:218:1: this function could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/command_prelude.rs:222:1: this function could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/command_prelude.rs:234:1: this function could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/command_prelude.rs:249:1: this function could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/command_prelude.rs:264:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/command_prelude.rs:279:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/command_prelude.rs:298:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/command_prelude.rs:320:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/command_prelude.rs:328:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/command_prelude.rs:352:13: unnecessary boolean `not` operation -cargo-0.49.0/src/cargo/util/command_prelude.rs:363:13: unnecessary boolean `not` operation -cargo-0.49.0/src/cargo/util/command_prelude.rs:378:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/command_prelude.rs:387:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/command_prelude.rs:387:5: this function has too many lines (104/100) -cargo-0.49.0/src/cargo/util/command_prelude.rs:39:20: you should put `arg_package_spec` between ticks in the documentation -cargo-0.49.0/src/cargo/util/command_prelude.rs:504:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/command_prelude.rs:516:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/command_prelude.rs:530:40: redundant closure found -cargo-0.49.0/src/cargo/util/command_prelude.rs:531:43: redundant closure found -cargo-0.49.0/src/cargo/util/command_prelude.rs:536:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/command_prelude.rs:556:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/command_prelude.rs:575:49: redundant closure found -cargo-0.49.0/src/cargo/util/command_prelude.rs:580:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/command_prelude.rs:631:18: redundant closure found -cargo-0.49.0/src/cargo/util/command_prelude.rs:638:18: redundant closure found -cargo-0.49.0/src/cargo/util/command_prelude.rs:647:1: this function could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/command_prelude.rs:651:1: this function could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/command_prelude.rs:662:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/command_prelude.rs:665:51: this `match` has identical arm bodies -cargo-0.49.0/src/cargo/util/config/de.rs:420:16: this argument is passed by value, but not consumed in the function body -cargo-0.49.0/src/cargo/util/config/de.rs:46:25: you should put `CV::List` between ticks in the documentation -cargo-0.49.0/src/cargo/util/config/de.rs:47:24: you should put `ConfigSeqAccess` between ticks in the documentation -cargo-0.49.0/src/cargo/util/config/de.rs:527:53: integer type suffix should be separated by an underscore -cargo-0.49.0/src/cargo/util/config/de.rs:530:53: integer type suffix should be separated by an underscore -cargo-0.49.0/src/cargo/util/config/de.rs:532:68: integer type suffix should be separated by an underscore -cargo-0.49.0/src/cargo/util/config/key.rs:11:1: item name ends with its containing module's name -cargo-0.49.0/src/cargo/util/config/key.rs:69:9: calling `push_str()` using a single-character string literal -cargo-0.49.0/src/cargo/util/config/mod.rs:100:71: you should put `OptValue` between ticks in the documentation -cargo-0.49.0/src/cargo/util/config/mod.rs:100:71: you should put `OptValue` between ticks in the documentation -cargo-0.49.0/src/cargo/util/config/mod.rs:100:71: you should put `OptValue` between ticks in the documentation -cargo-0.49.0/src/cargo/util/config/mod.rs:1049:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/config/mod.rs:1064:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/config/mod.rs:1090:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/config/mod.rs:1166:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/config/mod.rs:1179:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/config/mod.rs:1184:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/config/mod.rs:1189:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/config/mod.rs:1203:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/config/mod.rs:1211:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/config/mod.rs:1216:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/config/mod.rs:1225:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/config/mod.rs:1229:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/config/mod.rs:124:1: more than 3 bools in a struct -cargo-0.49.0/src/cargo/util/config/mod.rs:1254:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/config/mod.rs:1279:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/config/mod.rs:1281:9: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -cargo-0.49.0/src/cargo/util/config/mod.rs:1323:9: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/util/config/mod.rs:1339:39: unused `self` argument -cargo-0.49.0/src/cargo/util/config/mod.rs:1344:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/util/config/mod.rs:1420:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/util/config/mod.rs:1553:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/config/mod.rs:1560:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/config/mod.rs:1567:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/config/mod.rs:1574:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/config/mod.rs:1581:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/config/mod.rs:1588:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/config/mod.rs:1598:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/config/mod.rs:1619:1: this function could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/config/mod.rs:1623:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/config/mod.rs:1623:64: this argument is passed by value, but not consumed in the function body -cargo-0.49.0/src/cargo/util/config/mod.rs:1649:9: use Option::map_or_else instead of an if let/else -cargo-0.49.0/src/cargo/util/config/mod.rs:1699:5: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/util/config/mod.rs:1730:1: item name ends with its containing module's name -cargo-0.49.0/src/cargo/util/config/mod.rs:1757:1: item name ends with its containing module's name -cargo-0.49.0/src/cargo/util/config/mod.rs:1770:1: item name ends with its containing module's name -cargo-0.49.0/src/cargo/util/config/mod.rs:1778:1: item name ends with its containing module's name -cargo-0.49.0/src/cargo/util/config/mod.rs:1804:1: item name ends with its containing module's name -cargo-0.49.0/src/cargo/util/config/mod.rs:1896:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/config/mod.rs:1901:5: you should put `StringList` between ticks in the documentation -cargo-0.49.0/src/cargo/util/config/mod.rs:214:13: wildcard match will miss any future added variants -cargo-0.49.0/src/cargo/util/config/mod.rs:259:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/config/mod.rs:298:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/config/mod.rs:311:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/config/mod.rs:318:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/config/mod.rs:353:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/config/mod.rs:401:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/config/mod.rs:411:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/config/mod.rs:419:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/config/mod.rs:431:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/config/mod.rs:449:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/config/mod.rs:454:16: use Option::map_or instead of an if let/else -cargo-0.49.0/src/cargo/util/config/mod.rs:547:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/config/mod.rs:556:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/config/mod.rs:582:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/config/mod.rs:595:20: you should put `StringList` between ticks in the documentation -cargo-0.49.0/src/cargo/util/config/mod.rs:689:20: unused `self` argument -cargo-0.49.0/src/cargo/util/config/mod.rs:699:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/config/mod.rs:699:5: more than 3 bools in function parameters -cargo-0.49.0/src/cargo/util/config/mod.rs:719:58: redundant closure found -cargo-0.49.0/src/cargo/util/config/mod.rs:816:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/config/mod.rs:875:36: binding's name is too similar to existing binding -cargo-0.49.0/src/cargo/util/config/mod.rs:876:37: binding's name is too similar to existing binding -cargo-0.49.0/src/cargo/util/config/path.rs:10:1: item name ends with its containing module's name -cargo-0.49.0/src/cargo/util/config/path.rs:14:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/config/path.rs:48:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/util/config/target.rs:12:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/util/config/target.rs:24:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/util/config/value.rs:29:1: item name ends with its containing module's name -cargo-0.49.0/src/cargo/util/config/value.rs:80:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/config/value.rs:81:9: match expression looks like `matches!` macro -cargo-0.49.0/src/cargo/util/cpu.rs:11:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/cpu.rs:22:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/cpu.rs:82:25: casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -cargo-0.49.0/src/cargo/util/cpu.rs:82:9: casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -cargo-0.49.0/src/cargo/util/dependency_queue.rs:109:27: redundant closure found -cargo-0.49.0/src/cargo/util/dependency_queue.rs:136:20: called `filter(..).map(..)` on an `Iterator` -cargo-0.49.0/src/cargo/util/dependency_queue.rs:151:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/dependency_queue.rs:156:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/dependency_queue.rs:46:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/dependency_queue.rs:91:9: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/util/diagnostic_server.rs:218:1: item name ends with its containing module's name -cargo-0.49.0/src/cargo/util/diagnostic_server.rs:230:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/diagnostic_server.rs:242:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/diagnostic_server.rs:58:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/diagnostic_server.rs:96:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/diagnostic_server.rs:96:5: this function has too many lines (110/100) -cargo-0.49.0/src/cargo/util/diagnostic_server.rs:99:21: `msg` is being shadowed -cargo-0.49.0/src/cargo/util/errors.rs:101:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/errors.rs:143:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/errors.rs:150:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/errors.rs:15:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/errors.rs:237:5: variant name ends with the enum's name -cargo-0.49.0/src/cargo/util/errors.rs:245:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/errors.rs:321:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/errors.rs:328:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/errors.rs:356:1: this function could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/errors.rs:391:5: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/util/errors.rs:392:13: usage of wildcard import -cargo-0.49.0/src/cargo/util/errors.rs:465:1: this function could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/errors.rs:473:5: manual `RangeInclusive::contains` implementation -cargo-0.49.0/src/cargo/util/errors.rs:66:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/flock.rs:115:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/flock.rs:11:5: usage of wildcard import -cargo-0.49.0/src/cargo/util/flock.rs:134:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/flock.rs:142:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/flock.rs:150:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/flock.rs:156:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/flock.rs:170:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/flock.rs:192:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/flock.rs:29:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/flock.rs:321:5: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/util/flock.rs:335:23: casting `i64` to `u32` may lose the sign of the value -cargo-0.49.0/src/cargo/util/flock.rs:335:23: casting `i64` to `u32` may truncate the value -cargo-0.49.0/src/cargo/util/flock.rs:335:44: casting `i64` to `u32` may truncate the value -cargo-0.49.0/src/cargo/util/flock.rs:379:35: this `match` has identical arm bodies -cargo-0.49.0/src/cargo/util/flock.rs:37:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/flock.rs:43:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/flock.rs:52:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/graph.rs:10:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/graph.rs:115:13: called `find(..).map(..)` on an `Iterator` -cargo-0.49.0/src/cargo/util/graph.rs:41:51: redundant closure found -cargo-0.49.0/src/cargo/util/graph.rs:45:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/graph.rs:95:13: called `find(..).map(..)` on an `Iterator` -cargo-0.49.0/src/cargo/util/hasher.rs:12:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/hasher.rs:9:1: item name ends with its containing module's name -cargo-0.49.0/src/cargo/util/hex.rs:10:9: casting `u64` to `u8` may truncate the value -cargo-0.49.0/src/cargo/util/hex.rs:11:9: casting `u64` to `u8` may truncate the value -cargo-0.49.0/src/cargo/util/hex.rs:12:9: casting `u64` to `u8` may truncate the value -cargo-0.49.0/src/cargo/util/hex.rs:13:9: casting `u64` to `u8` may truncate the value -cargo-0.49.0/src/cargo/util/hex.rs:14:9: casting `u64` to `u8` may truncate the value -cargo-0.49.0/src/cargo/util/hex.rs:15:9: casting `u64` to `u8` may truncate the value -cargo-0.49.0/src/cargo/util/hex.rs:25:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/hex.rs:6:1: item name ends with its containing module's name -cargo-0.49.0/src/cargo/util/hex.rs:6:1: this function could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/hex.rs:8:9: casting `u64` to `u8` may truncate the value -cargo-0.49.0/src/cargo/util/hex.rs:9:9: casting `u64` to `u8` may truncate the value -cargo-0.49.0/src/cargo/util/important_paths.rs:23:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/important_paths.rs:6:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/interning.rs:66:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/interning.rs:77:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/into_url.rs:10:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/into_url_with_base.rs:9:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/job.rs:20:1: this function could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/lev_distance.rs:3:1: this function could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/lockserver.rs:111:32: redundant else block -cargo-0.49.0/src/cargo/util/lockserver.rs:158:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/lockserver.rs:46:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/lockserver.rs:58:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/lockserver.rs:62:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/mod.rs:68:1: this function could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/mod.rs:79:1: this function could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/network.rs:12:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/network.rs:19:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/network.rs:84:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/paths.rs:109:12: redundant else block -cargo-0.49.0/src/cargo/util/paths.rs:114:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/paths.rs:121:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/paths.rs:125:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/paths.rs:130:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/paths.rs:14:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/paths.rs:14:1: item name ends with its containing module's name -cargo-0.49.0/src/cargo/util/paths.rs:151:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/paths.rs:167:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/paths.rs:173:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/paths.rs:178:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/paths.rs:185:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/paths.rs:199:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/paths.rs:215:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/paths.rs:228:1: this function could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/paths.rs:251:9: use Option::map_or instead of an if let/else -cargo-0.49.0/src/cargo/util/paths.rs:267:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/paths.rs:276:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/paths.rs:29:1: this function could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/paths.rs:303:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/paths.rs:312:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/paths.rs:346:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/paths.rs:415:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/paths.rs:445:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/paths.rs:459:45: redundant closure found -cargo-0.49.0/src/cargo/util/paths.rs:469:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/paths.rs:54:1: this function could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/paths.rs:61:1: this function could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/paths.rs:63:19: use Option::map_or_else instead of an if let/else -cargo-0.49.0/src/cargo/util/paths.rs:88:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/paths.rs:93:31: comparison to empty slice -cargo-0.49.0/src/cargo/util/process_builder.rs:106:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/process_builder.rs:111:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/process_builder.rs:122:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/process_builder.rs:132:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/process_builder.rs:152:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/process_builder.rs:185:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/process_builder.rs:190:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/process_builder.rs:218:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/process_builder.rs:307:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/process_builder.rs:343:39: this argument is passed by value, but not consumed in the function body -cargo-0.49.0/src/cargo/util/progress.rs:122:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/progress.rs:136:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/progress.rs:15:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/util/progress.rs:249:19: casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -cargo-0.49.0/src/cargo/util/progress.rs:249:34: casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -cargo-0.49.0/src/cargo/util/progress.rs:250:19: unnecessary boolean `not` operation -cargo-0.49.0/src/cargo/util/progress.rs:263:22: casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -cargo-0.49.0/src/cargo/util/progress.rs:264:22: casting `f64` to `usize` may lose the sign of the value -cargo-0.49.0/src/cargo/util/progress.rs:264:22: casting `f64` to `usize` may truncate the value -cargo-0.49.0/src/cargo/util/progress.rs:269:17: calling `push_str()` using a single-character string literal -cargo-0.49.0/src/cargo/util/progress.rs:272:17: calling `push_str()` using a single-character string literal -cargo-0.49.0/src/cargo/util/progress.rs:274:17: calling `push_str()` using a single-character string literal -cargo-0.49.0/src/cargo/util/progress.rs:280:13: calling `push_str()` using a single-character string literal -cargo-0.49.0/src/cargo/util/progress.rs:282:9: calling `push_str()` using a single-character string literal -cargo-0.49.0/src/cargo/util/progress.rs:89:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/progress.rs:97:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/queue.rs:25:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/read2.rs:11:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/read2.rs:31:17: binding's name is too similar to existing binding -cargo-0.49.0/src/cargo/util/restricted_names.rs:13:1: this function could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/restricted_names.rs:26:1: this function could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/restricted_names.rs:35:1: this function could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/restricted_names.rs:45:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/restricted_names.rs:87:1: this function could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/restricted_names.rs:89:21: redundant closure found -cargo-0.49.0/src/cargo/util/restricted_names.rs:8:1: this function could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/rustc.rs:103:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/rustc.rs:114:5: you should put bare URLs between `<`/`>` or make a proper Markdown link -cargo-0.49.0/src/cargo/util/rustc.rs:115:5: you should put bare URLs between `<`/`>` or make a proper Markdown link -cargo-0.49.0/src/cargo/util/rustc.rs:162:17: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/util/rustc.rs:39:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/rustc.rs:55:13: called `find(..).map(..)` on an `Iterator` -cargo-0.49.0/src/cargo/util/sha256.rs:10:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/sha256.rs:20:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/sha256.rs:31:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/sha256.rs:40:24: integer type suffix should be separated by an underscore -cargo-0.49.0/src/cargo/util/to_semver.rs:5:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/toml/mod.rs:1005:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/toml/mod.rs:1005:5: this function has too many lines (282/100) -cargo-0.49.0/src/cargo/util/toml/mod.rs:1094:36: redundant closure found -cargo-0.49.0/src/cargo/util/toml/mod.rs:1121:13: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/util/toml/mod.rs:1197:32: called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead -cargo-0.49.0/src/cargo/util/toml/mod.rs:124:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/toml/mod.rs:1504:9: unused `self` argument -cargo-0.49.0/src/cargo/util/toml/mod.rs:1526:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/toml/mod.rs:1582:19: calling `util::toml::DetailedTomlDependency::default()` is more clear than this expression -cargo-0.49.0/src/cargo/util/toml/mod.rs:1598:5: this function has too many lines (153/100) -cargo-0.49.0/src/cargo/util/toml/mod.rs:1687:33: unnecessary closure used to substitute value for `Option::None` -cargo-0.49.0/src/cargo/util/toml/mod.rs:178:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/util/toml/mod.rs:248:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/util/toml/mod.rs:274:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/util/toml/mod.rs:277:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/toml/mod.rs:281:5: this method could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/toml/mod.rs:285:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/toml/mod.rs:294:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/util/toml/mod.rs:31:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/toml/mod.rs:381:35: casting `i64` to `u32` may lose the sign of the value -cargo-0.49.0/src/cargo/util/toml/mod.rs:381:35: casting `i64` to `u32` may truncate the value -cargo-0.49.0/src/cargo/util/toml/mod.rs:388:35: casting `u64` to `u32` may truncate the value -cargo-0.49.0/src/cargo/util/toml/mod.rs:398:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/util/toml/mod.rs:450:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/toml/mod.rs:536:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/toml/mod.rs:783:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/util/toml/mod.rs:824:1: item name starts with its containing module's name -cargo-0.49.0/src/cargo/util/toml/mod.rs:834:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/toml/mod.rs:83:42: redundant closure found -cargo-0.49.0/src/cargo/util/toml/mod.rs:852:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/toml/mod.rs:852:5: this function has too many lines (138/100) -cargo-0.49.0/src/cargo/util/toml/mod.rs:962:9: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/util/toml/mod.rs:971:24: called `filter(..).map(..)` on an `Iterator` -cargo-0.49.0/src/cargo/util/toml/mod.rs:979:9: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/util/toml/mod.rs:98:5: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/util/toml/mod.rs:999:23: calling `util::toml::DetailedTomlDependency::default()` is more clear than this expression -cargo-0.49.0/src/cargo/util/toml/targets.rs:112:27: redundant closure found -cargo-0.49.0/src/cargo/util/toml/targets.rs:325:5: adding items after statements is confusing, since items exist from the start of the scope -cargo-0.49.0/src/cargo/util/toml/targets.rs:586:21: redundant closure found -cargo-0.49.0/src/cargo/util/toml/targets.rs:593:42: redundant closure found -cargo-0.49.0/src/cargo/util/toml/targets.rs:605:19: redundant closure found -cargo-0.49.0/src/cargo/util/toml/targets.rs:612:42: redundant closure found -cargo-0.49.0/src/cargo/util/toml/targets.rs:756:36: redundant closure found -cargo-0.49.0/src/cargo/util/toml/targets.rs:810:24: called `filter(..).map(..)` on an `Iterator` -cargo-0.49.0/src/cargo/util/vcs.rs:10:1: this function could have a `#[must_use]` attribute -cargo-0.49.0/src/cargo/util/vcs.rs:33:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/vcs.rs:37:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/vcs.rs:43:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/vcs.rs:47:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/vcs.rs:59:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/vcs.rs:66:5: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/workspace.rs:52:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/workspace.rs:56:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/workspace.rs:60:1: docs for function returning `Result` missing `# Errors` section -cargo-0.49.0/src/cargo/util/workspace.rs:64:1: docs for function returning `Result` missing `# Errors` section -iron-0.6.1/src/error.rs:24:1: item name ends with its containing module's name -iron-0.6.1/src/error.rs:55:20: use of deprecated associated function `std::error::Error::description`: use the Display impl or to_string() -iron-0.6.1/src/iron.rs:105:13: redundant field names in struct initialization -iron-0.6.1/src/iron.rs:119:5: docs for function returning `Result` missing `# Errors` section -iron-0.6.1/src/iron.rs:133:5: docs for function returning `Result` missing `# Errors` section -iron-0.6.1/src/iron.rs:143:5: docs for function returning `Result` missing `# Errors` section -iron-0.6.1/src/iron.rs:148:19: use of deprecated macro `try`: use the `?` operator instead -iron-0.6.1/src/iron.rs:149:13: redundant field names in struct initialization -iron-0.6.1/src/iron.rs:167:49: binding's name is too similar to existing binding -iron-0.6.1/src/iron.rs:80:5: this method could have a `#[must_use]` attribute -iron-0.6.1/src/iron.rs:85:5: this method could have a `#[must_use]` attribute -iron-0.6.1/src/iron.rs:90:5: this method could have a `#[must_use]` attribute -iron-0.6.1/src/middleware/mod.rs:137:5: docs for function returning `Result` missing `# Errors` section -iron-0.6.1/src/middleware/mod.rs:150:1: item name ends with its containing module's name -iron-0.6.1/src/middleware/mod.rs:152:5: docs for function returning `Result` missing `# Errors` section -iron-0.6.1/src/middleware/mod.rs:159:5: docs for function returning `Result` missing `# Errors` section -iron-0.6.1/src/middleware/mod.rs:171:1: item name ends with its containing module's name -iron-0.6.1/src/middleware/mod.rs:173:5: docs for function returning `Result` missing `# Errors` section -iron-0.6.1/src/middleware/mod.rs:182:5: docs for function returning `Result` missing `# Errors` section -iron-0.6.1/src/middleware/mod.rs:192:1: item name ends with its containing module's name -iron-0.6.1/src/middleware/mod.rs:217:25: you should put `ChainBuilder` between ticks in the documentation -iron-0.6.1/src/middleware/mod.rs:328:20: binding's name is too similar to existing binding -iron-0.6.1/src/middleware/mod.rs:360:16: binding's name is too similar to existing binding -iron-0.6.1/src/middleware/mod.rs:368:33: binding's name is too similar to existing binding -iron-0.6.1/src/middleware/mod.rs:428:40: binding's name is too similar to existing binding -iron-0.6.1/src/middleware/mod.rs:434:40: binding's name is too similar to existing binding -iron-0.6.1/src/middleware/mod.rs:444:40: binding's name is too similar to existing binding -iron-0.6.1/src/modifiers.rs:132:14: use of `expect` followed by a function call -iron-0.6.1/src/request/mod.rs:113:24: binding's name is too similar to existing binding -iron-0.6.1/src/request/mod.rs:121:13: redundant field names in struct initialization -iron-0.6.1/src/request/mod.rs:123:13: redundant field names in struct initialization -iron-0.6.1/src/request/mod.rs:124:13: redundant field names in struct initialization -iron-0.6.1/src/request/mod.rs:126:13: redundant field names in struct initialization -iron-0.6.1/src/request/mod.rs:128:13: redundant field names in struct initialization -iron-0.6.1/src/request/mod.rs:153:69: you should put `HttpReader` between ticks in the documentation -iron-0.6.1/src/request/mod.rs:154:5: this method could have a `#[must_use]` attribute -iron-0.6.1/src/request/mod.rs:32:1: this seems like a manual implementation of the non-exhaustive pattern -iron-0.6.1/src/request/mod.rs:62:9: use of deprecated macro `try`: use the `?` operator instead -iron-0.6.1/src/request/mod.rs:64:9: use of deprecated macro `try`: use the `?` operator instead -iron-0.6.1/src/request/mod.rs:65:9: use of deprecated macro `try`: use the `?` operator instead -iron-0.6.1/src/request/mod.rs:66:9: use of deprecated macro `try`: use the `?` operator instead -iron-0.6.1/src/request/mod.rs:67:9: use of deprecated macro `try`: use the `?` operator instead -iron-0.6.1/src/request/mod.rs:69:9: use of deprecated macro `try`: use the `?` operator instead -iron-0.6.1/src/request/mod.rs:75:34: you should put `HttpRequest` between ticks in the documentation -iron-0.6.1/src/request/mod.rs:77:39: you should put `HttpRequest` between ticks in the documentation -iron-0.6.1/src/request/mod.rs:78:5: docs for function returning `Result` missing `# Errors` section -iron-0.6.1/src/request/mod.rs:82:13: binding's name is too similar to existing binding -iron-0.6.1/src/request/mod.rs:83:29: binding's name is too similar to existing binding -iron-0.6.1/src/request/mod.rs:85:24: binding's name is too similar to existing binding -iron-0.6.1/src/request/url.rs:109:5: this method could have a `#[must_use]` attribute -iron-0.6.1/src/request/url.rs:117:5: this method could have a `#[must_use]` attribute -iron-0.6.1/src/request/url.rs:124:9: use of deprecated macro `try`: use the `?` operator instead -iron-0.6.1/src/request/url.rs:129:1: an implementation of `From` is preferred since it gives you `Into<_>` for free where the reverse isn't true -iron-0.6.1/src/request/url.rs:21:14: you should put bare URLs between `<`/`>` or make a proper Markdown link -iron-0.6.1/src/request/url.rs:22:5: docs for function returning `Result` missing `# Errors` section -iron-0.6.1/src/request/url.rs:31:5: docs for function returning `Result` missing `# Errors` section -iron-0.6.1/src/request/url.rs:47:5: this method could have a `#[must_use]` attribute -iron-0.6.1/src/request/url.rs:52:5: this method could have a `#[must_use]` attribute -iron-0.6.1/src/request/url.rs:57:5: this method could have a `#[must_use]` attribute -iron-0.6.1/src/request/url.rs:63:5: this method could have a `#[must_use]` attribute -iron-0.6.1/src/request/url.rs:73:5: this method could have a `#[must_use]` attribute -iron-0.6.1/src/request/url.rs:83:5: this method could have a `#[must_use]` attribute -iron-0.6.1/src/request/url.rs:96:5: this method could have a `#[must_use]` attribute -iron-0.6.1/src/response.rs:121:19: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -iron-0.6.1/src/response.rs:125:43: redundant closure found -iron-0.6.1/src/response.rs:139:41: redundant closure found -iron-0.6.1/src/response.rs:142:23: use of deprecated macro `try`: use the `?` operator instead -iron-0.6.1/src/response.rs:143:5: use of deprecated macro `try`: use the `?` operator instead -iron-0.6.1/src/response.rs:24:5: docs for function returning `Result` missing `# Errors` section -iron-0.6.1/src/response.rs:95:5: this method could have a `#[must_use]` attribute -iron-0.6.1/src/response.rs:95:5: you should consider adding a `Default` implementation for `response::Response` -libc-0.2.81/build.rs:114:19: called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead -libc-0.2.81/build.rs:124:5: this block may be rewritten with the `?` operator -libc-0.2.81/build.rs:133:5: this block may be rewritten with the `?` operator -libc-0.2.81/src/macros.rs:243:17: this function could have a `#[must_use]` attribute -libc-0.2.81/src/macros.rs:243:17: this function could have a `#[must_use]` attribute -libc-0.2.81/src/macros.rs:243:17: this function could have a `#[must_use]` attribute -libc-0.2.81/src/macros.rs:243:17: this function could have a `#[must_use]` attribute -libc-0.2.81/src/macros.rs:243:17: this function could have a `#[must_use]` attribute -libc-0.2.81/src/macros.rs:243:17: this function could have a `#[must_use]` attribute -libc-0.2.81/src/macros.rs:243:17: this function could have a `#[must_use]` attribute -libc-0.2.81/src/macros.rs:243:17: this function could have a `#[must_use]` attribute -libc-0.2.81/src/macros.rs:243:17: this function could have a `#[must_use]` attribute -libc-0.2.81/src/macros.rs:243:17: this function could have a `#[must_use]` attribute -libc-0.2.81/src/macros.rs:243:17: this function could have a `#[must_use]` attribute -libc-0.2.81/src/macros.rs:243:17: this function could have a `#[must_use]` attribute -libc-0.2.81/src/macros.rs:243:17: this function could have a `#[must_use]` attribute -libc-0.2.81/src/macros.rs:243:17: this function could have a `#[must_use]` attribute -libc-0.2.81/src/macros.rs:243:17: this function could have a `#[must_use]` attribute -libc-0.2.81/src/macros.rs:243:17: this function could have a `#[must_use]` attribute -libc-0.2.81/src/macros.rs:243:17: this function could have a `#[must_use]` attribute -libc-0.2.81/src/macros.rs:243:17: this function could have a `#[must_use]` attribute -libc-0.2.81/src/macros.rs:243:17: this function could have a `#[must_use]` attribute -libc-0.2.81/src/macros.rs:243:17: this function could have a `#[must_use]` attribute -libc-0.2.81/src/macros.rs:243:17: unsafe function's docs miss `# Safety` section -libc-0.2.81/src/macros.rs:243:17: unsafe function's docs miss `# Safety` section -libc-0.2.81/src/macros.rs:243:17: unsafe function's docs miss `# Safety` section -libc-0.2.81/src/macros.rs:259:17: this function could have a `#[must_use]` attribute -libc-0.2.81/src/macros.rs:259:17: this function could have a `#[must_use]` attribute -libc-0.2.81/src/macros.rs:259:17: this function could have a `#[must_use]` attribute -libc-0.2.81/src/macros.rs:259:17: this function could have a `#[must_use]` attribute -libc-0.2.81/src/macros.rs:259:17: this function could have a `#[must_use]` attribute -libc-0.2.81/src/macros.rs:259:17: this function could have a `#[must_use]` attribute -libc-0.2.81/src/macros.rs:259:17: this function could have a `#[must_use]` attribute -libc-0.2.81/src/macros.rs:259:17: this function could have a `#[must_use]` attribute -libc-0.2.81/src/macros.rs:259:17: this function could have a `#[must_use]` attribute -libc-0.2.81/src/macros.rs:259:17: this function could have a `#[must_use]` attribute -libc-0.2.81/src/macros.rs:259:17: this function could have a `#[must_use]` attribute -libc-0.2.81/src/macros.rs:259:17: this function could have a `#[must_use]` attribute -libc-0.2.81/src/macros.rs:259:17: this function could have a `#[must_use]` attribute -libc-0.2.81/src/macros.rs:259:17: this function could have a `#[must_use]` attribute -libc-0.2.81/src/macros.rs:259:17: this function could have a `#[must_use]` attribute -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:428:29: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:429:30: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:431:30: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:432:32: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:433:29: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:434:32: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:595:33: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:596:33: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:597:35: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:622:32: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:673:34: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:696:33: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:697:35: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:698:33: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:699:35: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:712:34: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:721:35: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:722:32: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:723:32: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:751:31: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:752:30: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:753:30: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:754:30: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:755:29: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:756:29: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:757:29: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:758:29: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:759:29: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:760:29: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:768:30: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:769:31: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:771:31: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:772:29: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:773:29: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:774:29: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:775:32: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:776:31: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:777:32: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:778:32: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:779:31: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:780:32: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:781:32: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:782:31: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:783:31: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:784:32: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:785:33: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:786:33: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:787:30: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:788:32: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:789:32: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:790:32: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:791:32: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:792:33: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:794:31: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:795:31: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:796:31: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:797:32: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:798:31: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:799:31: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:800:31: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:801:31: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:803:27: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:804:28: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:805:28: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:806:29: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:807:29: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:808:29: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:809:29: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:810:29: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:811:29: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:812:30: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:813:30: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:814:30: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:815:30: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:816:30: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:817:31: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:818:31: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:821:31: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:822:31: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:823:32: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:824:32: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:825:32: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:826:32: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:827:32: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:828:32: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:829:33: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:830:33: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:831:33: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:832:33: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:833:33: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:834:33: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:835:33: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:836:33: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:841:32: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:842:32: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:843:32: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:844:33: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:1120:38: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:178:34: integer type suffix should be separated by an underscore -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:291:5: this method could have a `#[must_use]` attribute -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:291:5: unsafe function's docs miss `# Safety` section -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:302:5: this method could have a `#[must_use]` attribute -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:302:5: unsafe function's docs miss `# Safety` section -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:355:13: this method could have a `#[must_use]` attribute -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:355:13: unsafe function's docs miss `# Safety` section -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:359:13: this method could have a `#[must_use]` attribute -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:359:13: unsafe function's docs miss `# Safety` section -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:363:13: this method could have a `#[must_use]` attribute -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:363:13: unsafe function's docs miss `# Safety` section -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:367:13: this method could have a `#[must_use]` attribute -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:367:13: unsafe function's docs miss `# Safety` section -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:371:13: this method could have a `#[must_use]` attribute -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:371:13: unsafe function's docs miss `# Safety` section -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:534:36: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:645:31: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:727:40: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:728:40: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:729:39: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:731:44: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:732:36: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:733:41: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:734:43: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:735:42: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:736:40: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:737:36: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:738:37: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:741:39: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:742:40: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:743:40: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:744:40: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:745:40: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:746:43: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:747:42: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:748:40: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:749:39: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:750:41: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:751:41: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:752:43: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:753:42: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:755:42: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:756:41: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:757:41: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:758:39: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:759:39: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:761:41: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:762:44: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:763:45: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:764:40: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:765:40: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:766:40: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:767:44: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:768:44: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:769:39: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:770:35: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:771:35: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:772:37: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:773:39: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:774:45: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:775:41: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:776:39: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:803:34: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:841:30: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:842:37: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:982:40: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:984:46: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1209:36: casting `i32` to `i16` may truncate the value -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1210:36: casting `i32` to `i16` may truncate the value -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1235:39: integer type suffix should be separated by an underscore -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1236:41: integer type suffix should be separated by an underscore -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1274:42: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1324:31: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1333:37: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1334:35: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1346:34: casting `u32` to `i32` may wrap around the value -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1346:34: integer type suffix should be separated by an underscore -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1346:34: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1347:37: casting `u32` to `i32` may wrap around the value -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1347:37: integer type suffix should be separated by an underscore -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1347:37: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1348:36: casting `u32` to `i32` may wrap around the value -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1348:36: integer type suffix should be separated by an underscore -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1348:36: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1349:37: casting `u32` to `i32` may wrap around the value -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1349:37: integer type suffix should be separated by an underscore -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1349:37: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1350:35: casting `u32` to `i32` may wrap around the value -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1350:35: integer type suffix should be separated by an underscore -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1350:35: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1351:36: casting `u32` to `i32` may wrap around the value -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1351:36: integer type suffix should be separated by an underscore -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1351:36: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1352:31: casting `u32` to `i32` may wrap around the value -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1352:31: integer type suffix should be separated by an underscore -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1352:31: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1419:36: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1420:36: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1421:36: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1422:36: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1423:36: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1490:37: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1561:46: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1562:45: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1567:31: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1568:32: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1586:26: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1587:34: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1588:31: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1589:31: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1897:38: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1898:51: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1900:39: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1969:34: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1970:34: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1971:36: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1972:36: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1973:36: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1974:37: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1975:37: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1976:36: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1977:36: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1978:39: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1979:39: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1980:39: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1981:39: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1982:39: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1983:39: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1984:38: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1985:38: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1986:35: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1987:35: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1988:35: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1989:35: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1990:38: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1991:37: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1992:37: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1993:38: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1994:37: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1995:37: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1996:37: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1997:37: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1998:33: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1999:33: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2000:33: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2001:34: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2002:34: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2003:34: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2004:35: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2005:35: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2032:30: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2033:32: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2034:31: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2035:29: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2036:32: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2037:28: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2038:27: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2039:29: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2041:29: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2042:28: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2043:27: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2044:34: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2045:27: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2046:33: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2048:28: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2049:32: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2050:32: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2051:32: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2052:26: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2053:36: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2318:42: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2321:38: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2331:39: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2487:42: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2488:42: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2489:43: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2490:43: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2491:43: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2493:47: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2494:44: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2495:46: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2496:47: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2497:49: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2498:48: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2499:50: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2500:45: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2572:9: unneeded `return` statement -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2578:20: `0 as *mut _` detected -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2588:13: `0 as *mut _` detected -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2596:52: used binding `_dummy` which is prefixed with an underscore. A leading underscore signals that a binding will not be used. -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2597:11: casting `i32` to `usize` may lose the sign of the value -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2601:21: it is more concise to loop over references to containers instead of using explicit iteration methods -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2611:9: unneeded unit expression -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2619:9: unneeded unit expression -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2634:9: casting `u32` to `i32` may wrap around the value -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2647:25: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2648:25: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2649:9: casting `u64` to `u32` may truncate the value -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2654:18: the operation is ineffective. Consider reducing it to `(dev & 0x00000000000000ff)` -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2654:25: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2655:25: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2656:9: casting `u64` to `u32` may truncate the value -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2660:21: casting `u32` to `u64` may become silently lossy if you later change the type -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2661:21: casting `u32` to `u64` may become silently lossy if you later change the type -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2663:25: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2664:25: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2665:16: the operation is ineffective. Consider reducing it to `(minor & 0x000000ff)` -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2665:25: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2666:25: long literal lacking separators -libc-0.2.81/src/unix/linux_like/linux/mod.rs:40:1: enum with no variants -libc-0.2.81/src/unix/linux_like/linux/mod.rs:954:34: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1000:31: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1001:32: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1002:32: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1016:29: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1017:32: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1018:33: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1019:33: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1020:33: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1029:29: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1030:29: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1031:30: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1032:29: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1033:29: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1034:29: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1035:29: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1041:32: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1042:32: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1043:32: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1044:32: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1045:31: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1046:32: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1047:31: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1048:31: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1049:31: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1050:31: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1051:33: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1053:29: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1054:33: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1055:30: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1056:31: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1057:31: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1058:32: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1059:31: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1060:31: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1073:42: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1074:43: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1075:37: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1076:37: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1077:41: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1078:35: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1079:35: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1080:36: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1081:35: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1082:35: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1083:31: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1084:38: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1086:30: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1087:32: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1089:30: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1090:33: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1091:30: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1094:40: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1095:37: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1096:41: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1097:40: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1098:39: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1099:34: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1100:36: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1101:38: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1102:37: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1105:44: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1106:41: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1107:42: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1108:42: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1109:41: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1110:46: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1111:41: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1112:44: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1113:40: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1114:47: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1115:36: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1126:34: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1127:29: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1128:31: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1179:32: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1180:31: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:1218:27: the operation is ineffective. Consider reducing it to `IPOPT_CONTROL` -libc-0.2.81/src/unix/linux_like/mod.rs:1314:9: operator precedence can trip the unwary -libc-0.2.81/src/unix/linux_like/mod.rs:1323:13: `0 as *mut _` detected -libc-0.2.81/src/unix/linux_like/mod.rs:1332:9: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -libc-0.2.81/src/unix/linux_like/mod.rs:1337:9: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -libc-0.2.81/src/unix/linux_like/mod.rs:1341:18: casting `i32` to `usize` may lose the sign of the value -libc-0.2.81/src/unix/linux_like/mod.rs:1344:9: unneeded `return` statement -libc-0.2.81/src/unix/linux_like/mod.rs:1348:18: casting `i32` to `usize` may lose the sign of the value -libc-0.2.81/src/unix/linux_like/mod.rs:1350:9: unneeded `return` statement -libc-0.2.81/src/unix/linux_like/mod.rs:1354:18: casting `i32` to `usize` may lose the sign of the value -libc-0.2.81/src/unix/linux_like/mod.rs:1357:9: unneeded `return` statement -libc-0.2.81/src/unix/linux_like/mod.rs:1361:21: it is more concise to loop over references to containers instead of using explicit iteration methods -libc-0.2.81/src/unix/linux_like/mod.rs:1381:9: casting `i32` to `i8` may truncate the value -libc-0.2.81/src/unix/linux_like/mod.rs:1389:9: bit mask could be simplified with a call to `trailing_zeros` -libc-0.2.81/src/unix/linux_like/mod.rs:446:31: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:591:36: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:592:38: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:593:35: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:594:33: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:595:34: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:596:36: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:597:37: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:598:37: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:599:39: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:600:34: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:601:35: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:602:35: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:607:37: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:608:35: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:764:35: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:765:39: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:991:30: long literal lacking separators -libc-0.2.81/src/unix/linux_like/mod.rs:9:1: enum with no variants -libc-0.2.81/src/unix/mod.rs:198:29: long literal lacking separators -libc-0.2.81/src/unix/mod.rs:199:28: long literal lacking separators -libc-0.2.81/src/unix/mod.rs:201:35: casting integer literal to `usize` is unnecessary -libc-0.2.81/src/unix/mod.rs:202:35: casting integer literal to `usize` is unnecessary -libc-0.2.81/src/unix/mod.rs:282:40: long literal lacking separators -libc-0.2.81/src/unix/mod.rs:284:41: long literal lacking separators -libc-0.2.81/src/unix/mod.rs:285:36: long literal lacking separators -libc-0.2.81/src/unix/mod.rs:34:1: enum with no variants -libc-0.2.81/src/unix/mod.rs:386:1: enum with no variants -libc-0.2.81/src/unix/mod.rs:394:1: enum with no variants -log-0.4.11/src/lib.rs:1047:5: this method could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:1053:5: this method could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:1059:5: this method could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:1093:5: this method could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:1093:5: you should consider adding a `Default` implementation for `MetadataBuilder<'a>` -log-0.4.11/src/lib.rs:1118:5: this method could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:1177:1: you have declared `#[inline(always)]` on `max_level`. This is usually a bad idea -log-0.4.11/src/lib.rs:1178:1: this function could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:1306:1: docs for function returning `Result` missing `# Errors` section -log-0.4.11/src/lib.rs:1358:1: this function could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:1359:5: unnecessary `!=` operation -log-0.4.11/src/lib.rs:1407:1: this function could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:329:27: you are deriving `Hash` but have implemented `PartialEq` explicitly -log-0.4.11/src/lib.rs:356:1: you are implementing `Clone` explicitly on a `Copy` type -log-0.4.11/src/lib.rs:448:12: manual `RangeInclusive::contains` implementation -log-0.4.11/src/lib.rs:468:13: called `filter(..).map(..)` on an `Iterator` -log-0.4.11/src/lib.rs:500:5: this method could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:506:28: this argument (8 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -log-0.4.11/src/lib.rs:506:5: this method could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:520:27: you are deriving `Hash` but have implemented `PartialEq` explicitly -log-0.4.11/src/lib.rs:538:1: you are implementing `Clone` explicitly on a `Copy` type -log-0.4.11/src/lib.rs:653:5: this method could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:661:21: this argument (8 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -log-0.4.11/src/lib.rs:661:5: this method could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:677:44: this `match` has identical arm bodies -log-0.4.11/src/lib.rs:758:5: this method could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:764:5: this method could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:770:5: this method could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:776:5: this method could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:782:5: this method could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:788:5: this method could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:794:5: this method could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:803:5: this method could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:809:5: this method could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:818:5: this method could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:908:5: this method could have a `#[must_use]` attribute -log-0.4.11/src/lib.rs:908:5: you should consider adding a `Default` implementation for `RecordBuilder<'a>` -log-0.4.11/src/lib.rs:995:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/detection.rs:2:5: usage of wildcard import -proc-macro2-1.0.24/src/fallback.rs:108:17: wildcard match will miss any future added variants -proc-macro2-1.0.24/src/fallback.rs:269:20: unused `self` argument -proc-macro2-1.0.24/src/fallback.rs:430:24: this argument (0 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -proc-macro2-1.0.24/src/fallback.rs:437:23: this argument (0 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -proc-macro2-1.0.24/src/fallback.rs:437:23: unused `self` argument -proc-macro2-1.0.24/src/fallback.rs:471:17: this argument (0 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -proc-macro2-1.0.24/src/fallback.rs:471:17: unused `self` argument -proc-macro2-1.0.24/src/fallback.rs:654:5: manual `RangeInclusive::contains` implementation -proc-macro2-1.0.24/src/fallback.rs:655:12: manual `RangeInclusive::contains` implementation -proc-macro2-1.0.24/src/fallback.rs:661:5: manual `RangeInclusive::contains` implementation -proc-macro2-1.0.24/src/fallback.rs:662:12: manual `RangeInclusive::contains` implementation -proc-macro2-1.0.24/src/fallback.rs:664:12: manual `RangeInclusive::contains` implementation -proc-macro2-1.0.24/src/fallback.rs:674:37: manual `RangeInclusive::contains` implementation -proc-macro2-1.0.24/src/fallback.rs:678:5: adding items after statements is confusing, since items exist from the start of the scope -proc-macro2-1.0.24/src/fallback.rs:85:9: adding items after statements is confusing, since items exist from the start of the scope -proc-macro2-1.0.24/src/fallback.rs:882:43: unused `self` argument -proc-macro2-1.0.24/src/lib.rs:1017:9: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:1081:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:1099:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:1117:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:1135:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:1141:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:1146:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:1151:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:1156:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:152:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:157:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:373:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:383:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:397:24: this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -proc-macro2-1.0.24/src/lib.rs:397:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:403:23: this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -proc-macro2-1.0.24/src/lib.rs:403:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:418:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:425:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:464:17: this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -proc-macro2-1.0.24/src/lib.rs:500:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:626:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:633:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:641:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:652:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:662:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:672:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:734:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:743:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:752:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:757:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:788:19: you should put `XID_Start` between ticks in the documentation -proc-macro2-1.0.24/src/lib.rs:788:69: you should put `XID_Continue` between ticks in the documentation -proc-macro2-1.0.24/src/lib.rs:891:36: you should put `syn::parse_str` between ticks in the documentation -proc-macro2-1.0.24/src/lib.rs:894:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:911:5: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/lib.rs:996:9: this method could have a `#[must_use]` attribute -proc-macro2-1.0.24/src/parse.rs:552:5: this loop could be written as a `for` loop -proc-macro2-1.0.24/src/parse.rs:584:21: manual `RangeInclusive::contains` implementation -proc-macro2-1.0.24/src/parse.rs:602:20: called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead -proc-macro2-1.0.24/src/parse.rs:696:29: casting `u8` to `u64` may become silently lossy if you later change the type -proc-macro2-1.0.24/src/parse.rs:702:34: casting `u8` to `u64` may become silently lossy if you later change the type -proc-macro2-1.0.24/src/parse.rs:708:34: casting `u8` to `u64` may become silently lossy if you later change the type -proc-macro2-1.0.24/src/parse.rs:803:15: it is more concise to loop over references to containers instead of using explicit iteration methods -proc-macro2-1.0.24/src/parse.rs:808:15: it is more concise to loop over references to containers instead of using explicit iteration methods -proc-macro2-1.0.24/src/wrapper.rs:415:24: this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -proc-macro2-1.0.24/src/wrapper.rs:429:23: this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -proc-macro2-1.0.24/src/wrapper.rs:492:17: this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -quote-1.0.7/src/ext.rs:10:1: item name ends with its containing module's name -quote-1.0.7/src/ext.rs:7:5: you should put `TokenStream` between ticks in the documentation -quote-1.0.7/src/ident_fragment.rs:13:5: docs for function returning `Result` missing `# Errors` section -quote-1.0.7/src/ident_fragment.rs:51:31: stripping a prefix manually -quote-1.0.7/src/runtime.rs:52:5: item name ends with its containing module's name -quote-1.0.7/src/runtime.rs:63:5: item name ends with its containing module's name -quote-1.0.7/src/runtime.rs:66:33: you should put `DoesNotHaveIter` between ticks in the documentation -quote-1.0.7/src/runtime.rs:80:5: item name ends with its containing module's name -rand-0.7.3/src/distributions/bernoulli.rs:103:20: casting `f64` to `u64` may lose the sign of the value -rand-0.7.3/src/distributions/bernoulli.rs:103:20: casting `f64` to `u64` may truncate the value -rand-0.7.3/src/distributions/bernoulli.rs:116:5: docs for function returning `Result` missing `# Errors` section -rand-0.7.3/src/distributions/bernoulli.rs:123:21: casting `f64` to `u64` may lose the sign of the value -rand-0.7.3/src/distributions/bernoulli.rs:123:21: casting `f64` to `u64` may truncate the value -rand-0.7.3/src/distributions/bernoulli.rs:63:26: casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -rand-0.7.3/src/distributions/bernoulli.rs:63:27: integer type suffix should be separated by an underscore -rand-0.7.3/src/distributions/bernoulli.rs:67:1: item name starts with its containing module's name -rand-0.7.3/src/distributions/bernoulli.rs:95:5: docs for function returning `Result` missing `# Errors` section -rand-0.7.3/src/distributions/bernoulli.rs:96:13: manual `Range::contains` implementation -rand-0.7.3/src/distributions/binomial.rs:107:23: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -rand-0.7.3/src/distributions/binomial.rs:112:44: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -rand-0.7.3/src/distributions/binomial.rs:116:13: adding items after statements is confusing, since items exist from the start of the scope -rand-0.7.3/src/distributions/binomial.rs:150:28: redundant else block -rand-0.7.3/src/distributions/binomial.rs:153:24: unnecessary boolean `not` operation -rand-0.7.3/src/distributions/binomial.rs:158:28: redundant else block -rand-0.7.3/src/distributions/binomial.rs:164:33: casting `i64` to `u64` may lose the sign of the value -rand-0.7.3/src/distributions/binomial.rs:166:28: redundant else block -rand-0.7.3/src/distributions/binomial.rs:175:47: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -rand-0.7.3/src/distributions/binomial.rs:185:38: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -rand-0.7.3/src/distributions/binomial.rs:194:38: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -rand-0.7.3/src/distributions/binomial.rs:202:28: redundant else block -rand-0.7.3/src/distributions/binomial.rs:209:25: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -rand-0.7.3/src/distributions/binomial.rs:221:26: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -rand-0.7.3/src/distributions/binomial.rs:222:26: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -rand-0.7.3/src/distributions/binomial.rs:223:25: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -rand-0.7.3/src/distributions/binomial.rs:224:25: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -rand-0.7.3/src/distributions/binomial.rs:226:17: adding items after statements is confusing, since items exist from the start of the scope -rand-0.7.3/src/distributions/binomial.rs:233:32: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -rand-0.7.3/src/distributions/binomial.rs:234:27: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -rand-0.7.3/src/distributions/binomial.rs:251:22: casting `i64` to `u64` may lose the sign of the value -rand-0.7.3/src/distributions/binomial.rs:255:9: unnecessary `!=` operation -rand-0.7.3/src/distributions/binomial.rs:35:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/distributions/binomial.rs:45:17: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -rand-0.7.3/src/distributions/binomial.rs:46:5: casting `f64` to `i64` may truncate the value -rand-0.7.3/src/distributions/binomial.rs:50:5: this function has too many lines (143/100) -rand-0.7.3/src/distributions/binomial.rs:76:9: adding items after statements is confusing, since items exist from the start of the scope -rand-0.7.3/src/distributions/binomial.rs:78:12: casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -rand-0.7.3/src/distributions/binomial.rs:81:21: casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -rand-0.7.3/src/distributions/binomial.rs:82:32: casting `u64` to `i32` may truncate the value -rand-0.7.3/src/distributions/binomial.rs:88:26: casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -rand-0.7.3/src/distributions/binomial.rs:99:21: casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -rand-0.7.3/src/distributions/cauchy.rs:33:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/distributions/dirichlet.rs:52:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/distributions/dirichlet.rs:64:32: float type suffix should be separated by an underscore -rand-0.7.3/src/distributions/dirichlet.rs:65:23: float type suffix should be separated by an underscore -rand-0.7.3/src/distributions/exponential.rs:76:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/distributions/float.rs:73:1: item name ends with its containing module's name -rand-0.7.3/src/distributions/gamma.rs:13:5: usage of wildcard import for enum variants -rand-0.7.3/src/distributions/gamma.rs:14:5: usage of wildcard import for enum variants -rand-0.7.3/src/distributions/gamma.rs:189:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/distributions/gamma.rs:230:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/distributions/gamma.rs:259:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/distributions/gamma.rs:287:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/distributions/gamma.rs:90:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/distributions/integer.rs:23:9: casting `u32` to `u8` may truncate the value -rand-0.7.3/src/distributions/integer.rs:30:9: casting `u32` to `u16` may truncate the value -rand-0.7.3/src/distributions/integer.rs:69:9: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers -rand-0.7.3/src/distributions/mod.rs:263:5: you have declared `#[inline(always)]` on `next`. This is usually a bad idea -rand-0.7.3/src/distributions/normal.rs:100:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/distributions/normal.rs:119:1: item name ends with its containing module's name -rand-0.7.3/src/distributions/normal.rs:131:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/distributions/normal.rs:31:1: item name ends with its containing module's name -rand-0.7.3/src/distributions/normal.rs:47:25: float type suffix should be separated by an underscore -rand-0.7.3/src/distributions/normal.rs:48:25: float type suffix should be separated by an underscore -rand-0.7.3/src/distributions/other.rs:89:9: casting `u32` to `i32` may wrap around the value -rand-0.7.3/src/distributions/pareto.rs:32:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/distributions/poisson.rs:35:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/distributions/poisson.rs:87:30: casting `f64` to `u64` may lose the sign of the value -rand-0.7.3/src/distributions/poisson.rs:87:30: casting `f64` to `u64` may truncate the value -rand-0.7.3/src/distributions/triangular.rs:32:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/distributions/uniform.rs:146:4: needless `fn main` in doctest -rand-0.7.3/src/distributions/uniform.rs:199:1: item name ends with its containing module's name -rand-0.7.3/src/distributions/uniform.rs:214:1: item name starts with its containing module's name -rand-0.7.3/src/distributions/uniform.rs:283:14: you should put `SampleUniform` between ticks in the documentation -rand-0.7.3/src/distributions/uniform.rs:283:46: you should put `SampleUniform` between ticks in the documentation -rand-0.7.3/src/distributions/uniform.rs:296:5: you have declared `#[inline(always)]` on `borrow`. This is usually a bad idea -rand-0.7.3/src/distributions/uniform.rs:304:5: you have declared `#[inline(always)]` on `borrow`. This is usually a bad idea -rand-0.7.3/src/distributions/uniform.rs:350:1: item name starts with its containing module's name -rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization -rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization -rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization -rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization -rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization -rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization -rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization -rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization -rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization -rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization -rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization -rand-0.7.3/src/distributions/uniform.rs:407:21: redundant field names in struct initialization -rand-0.7.3/src/distributions/uniform.rs:441:31: because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false -rand-0.7.3/src/distributions/uniform.rs:441:31: because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false -rand-0.7.3/src/distributions/uniform.rs:441:31: because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false -rand-0.7.3/src/distributions/uniform.rs:441:31: because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false -rand-0.7.3/src/distributions/uniform.rs:441:31: because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false -rand-0.7.3/src/distributions/uniform.rs:441:31: because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false -rand-0.7.3/src/distributions/uniform.rs:441:31: because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false -rand-0.7.3/src/distributions/uniform.rs:441:31: because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false -rand-0.7.3/src/distributions/uniform.rs:56:10: you should put `SampleBorrow` between ticks in the documentation -rand-0.7.3/src/distributions/uniform.rs:647:1: item name starts with its containing module's name -rand-0.7.3/src/distributions/uniform.rs:840:1: item name starts with its containing module's name -rand-0.7.3/src/distributions/uniform.rs:913:13: use Option::map_or_else instead of an if let/else -rand-0.7.3/src/distributions/uniform.rs:943:54: casting `u64` to `u32` may truncate the value -rand-0.7.3/src/distributions/unit_circle.rs:30:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/distributions/unit_sphere.rs:24:1: item name starts with its containing module's name -rand-0.7.3/src/distributions/unit_sphere.rs:29:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/distributions/utils.rs:247:15: methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name -rand-0.7.3/src/distributions/utils.rs:248:20: methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name -rand-0.7.3/src/distributions/utils.rs:249:18: methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name -rand-0.7.3/src/distributions/utils.rs:254:5: you have declared `#[inline(always)]` on `lanes`. This is usually a bad idea -rand-0.7.3/src/distributions/utils.rs:258:5: you have declared `#[inline(always)]` on `splat`. This is usually a bad idea -rand-0.7.3/src/distributions/utils.rs:262:5: you have declared `#[inline(always)]` on `extract`. This is usually a bad idea -rand-0.7.3/src/distributions/utils.rs:267:5: you have declared `#[inline(always)]` on `replace`. This is usually a bad idea -rand-0.7.3/src/distributions/utils.rs:281:5: you have declared `#[inline(always)]` on `any`. This is usually a bad idea -rand-0.7.3/src/distributions/utils.rs:286:5: you have declared `#[inline(always)]` on `all`. This is usually a bad idea -rand-0.7.3/src/distributions/utils.rs:291:5: you have declared `#[inline(always)]` on `none`. This is usually a bad idea -rand-0.7.3/src/distributions/utils.rs:488:17: you should put `x_i` between ticks in the documentation -rand-0.7.3/src/distributions/utils.rs:489:50: you should put `x_i` between ticks in the documentation -rand-0.7.3/src/distributions/utils.rs:489:63: you should put `f(x_i` between ticks in the documentation -rand-0.7.3/src/distributions/utils.rs:490:40: you should put `f(x_i` between ticks in the documentation -rand-0.7.3/src/distributions/utils.rs:490:49: you should put `f(x_{i+1` between ticks in the documentation -rand-0.7.3/src/distributions/utils.rs:518:17: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers -rand-0.7.3/src/distributions/weibull.rs:29:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/distributions/weighted/alias_method.rs:113:21: it is more concise to loop over references to containers instead of using explicit iteration methods -rand-0.7.3/src/distributions/weighted/alias_method.rs:125:9: adding items after statements is confusing, since items exist from the start of the scope -rand-0.7.3/src/distributions/weighted/alias_method.rs:131:9: adding items after statements is confusing, since items exist from the start of the scope -rand-0.7.3/src/distributions/weighted/alias_method.rs:180:36: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -rand-0.7.3/src/distributions/weighted/alias_method.rs:182:34: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -rand-0.7.3/src/distributions/weighted/alias_method.rs:259:28: using `clone` on type `distributions::uniform::Uniform` which implements the `Copy` trait -rand-0.7.3/src/distributions/weighted/alias_method.rs:296:9: you are using an explicit closure for copying elements -rand-0.7.3/src/distributions/weighted/alias_method.rs:321:9: you are using an explicit closure for copying elements -rand-0.7.3/src/distributions/weighted/alias_method.rs:78:5: docs for function returning `Result` missing `# Errors` section -rand-0.7.3/src/distributions/weighted/alias_method.rs:78:5: this function has too many lines (106/100) -rand-0.7.3/src/distributions/weighted/alias_method.rs:85:17: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -rand-0.7.3/src/distributions/weighted/alias_method.rs:87:31: called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead -rand-0.7.3/src/distributions/weighted/mod.rs:100:5: docs for function returning `Result` missing `# Errors` section -rand-0.7.3/src/distributions/weighted/mod.rs:144:5: docs for function returning `Result` missing `# Errors` section -rand-0.7.3/src/distributions/weighted/mod.rs:169:16: unnecessary `>= y + 1` or `x - 1 >=` -rand-0.7.3/src/distributions/weighted/mod.rs:386:1: item name starts with its containing module's name -rand-0.7.3/src/distributions/weighted/mod.rs:85:1: item name starts with its containing module's name -rand-0.7.3/src/lib.rs:333:5: docs for function returning `Result` missing `# Errors` section -rand-0.7.3/src/lib.rs:404:14: methods called `to_*` usually take self by reference; consider choosing a less ambiguous name -rand-0.7.3/src/lib.rs:552:1: this function could have a `#[must_use]` attribute -rand-0.7.3/src/rngs/adapter/read.rs:47:1: item name starts with its containing module's name -rand-0.7.3/src/rngs/adapter/read.rs:89:1: item name starts with its containing module's name -rand-0.7.3/src/rngs/adapter/reseeding.rs:100:5: docs for function returning `Result` missing `# Errors` section -rand-0.7.3/src/rngs/adapter/reseeding.rs:112:5: you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea -rand-0.7.3/src/rngs/adapter/reseeding.rs:117:5: you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea -rand-0.7.3/src/rngs/adapter/reseeding.rs:198:13: casting `u64` to `i64` may wrap around the value -rand-0.7.3/src/rngs/adapter/reseeding.rs:231:9: casting `usize` to `isize` may wrap around the value -rand-0.7.3/src/rngs/adapter/reseeding.rs:27:28: you should put `ChaCha` between ticks in the documentation -rand-0.7.3/src/rngs/adapter/reseeding.rs:79:1: item name starts with its containing module's name -rand-0.7.3/src/rngs/entropy.rs:24:1: item name starts with its containing module's name -rand-0.7.3/src/rngs/entropy.rs:34:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/rngs/mock.rs:36:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/rngs/mock.rs:47:9: casting `u64` to `u32` may truncate the value -rand-0.7.3/src/rngs/mod.rs:61:74: you should put `ChaCha20` between ticks in the documentation -rand-0.7.3/src/rngs/std.rs:25:39: you should put `ChaCha` between ticks in the documentation -rand-0.7.3/src/rngs/std.rs:32:10: you should put `rand_chacha` between ticks in the documentation -rand-0.7.3/src/rngs/std.rs:36:1: item name starts with its containing module's name -rand-0.7.3/src/rngs/std.rs:39:5: you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea -rand-0.7.3/src/rngs/std.rs:44:5: you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea -rand-0.7.3/src/rngs/std.rs:49:5: you have declared `#[inline(always)]` on `fill_bytes`. This is usually a bad idea -rand-0.7.3/src/rngs/std.rs:54:5: you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea -rand-0.7.3/src/rngs/std.rs:63:5: you have declared `#[inline(always)]` on `from_seed`. This is usually a bad idea -rand-0.7.3/src/rngs/std.rs:68:5: you have declared `#[inline(always)]` on `from_rng`. This is usually a bad idea -rand-0.7.3/src/rngs/thread.rs:57:1: item name starts with its containing module's name -rand-0.7.3/src/rngs/thread.rs:80:1: item name starts with its containing module's name -rand-0.7.3/src/rngs/thread.rs:80:1: this function could have a `#[must_use]` attribute -rand-0.7.3/src/rngs/thread.rs:81:35: redundant closure found -rand-0.7.3/src/rngs/thread.rs:93:5: you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea -rand-0.7.3/src/rngs/thread.rs:98:5: you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea -rand-0.7.3/src/seq/index.rs:127:1: item name starts with its containing module's name -rand-0.7.3/src/seq/index.rs:139:13: usage of wildcard import for enum variants -rand-0.7.3/src/seq/index.rs:159:1: item name starts with its containing module's name -rand-0.7.3/src/seq/index.rs:171:13: usage of wildcard import for enum variants -rand-0.7.3/src/seq/index.rs:180:13: usage of wildcard import for enum variants -rand-0.7.3/src/seq/index.rs:223:18: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -rand-0.7.3/src/seq/index.rs:224:18: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -rand-0.7.3/src/seq/index.rs:233:25: casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide) -rand-0.7.3/src/seq/index.rs:236:27: casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide) -rand-0.7.3/src/seq/index.rs:244:12: casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide) -rand-0.7.3/src/seq/index.rs:244:37: casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide) -rand-0.7.3/src/seq/index.rs:29:1: item name starts with its containing module's name -rand-0.7.3/src/seq/index.rs:39:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/seq/index.rs:48:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/seq/index.rs:60:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/seq/index.rs:69:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/seq/index.rs:78:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/seq/index.rs:87:5: method `into_iter` can be confused for the standard trait method `std::iter::IntoIterator::into_iter` -rand-0.7.3/src/seq/index.rs:87:5: this method could have a `#[must_use]` attribute -rand-0.7.3/src/seq/index.rs:97:13: usage of wildcard import for enum variants -rand-0.7.3/src/seq/mod.rs:141:5: docs for function returning `Result` missing `# Errors` section -rand-0.7.3/src/seq/mod.rs:168:5: docs for function returning `Result` missing `# Errors` section -rand-0.7.3/src/seq/mod.rs:229:4: needless `fn main` in doctest -rand-0.7.3/src/seq/mod.rs:292:29: casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -rand-0.7.3/src/seq/mod.rs:410:23: calling `std::marker::PhantomData::default()` is more clear than this expression -rand-0.7.3/src/seq/mod.rs:45:4: needless `fn main` in doctest -rand-0.7.3/src/seq/mod.rs:527:26: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -rand_core-0.6.0/src/block.rs:117:1: item name starts with its containing module's name -rand_core-0.6.0/src/block.rs:153:5: you have declared `#[inline(always)]` on `index`. This is usually a bad idea -rand_core-0.6.0/src/block.rs:230:5: you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea -rand_core-0.6.0/src/block.rs:240:5: you have declared `#[inline(always)]` on `from_seed`. This is usually a bad idea -rand_core-0.6.0/src/block.rs:245:5: you have declared `#[inline(always)]` on `seed_from_u64`. This is usually a bad idea -rand_core-0.6.0/src/block.rs:250:5: you have declared `#[inline(always)]` on `from_rng`. This is usually a bad idea -rand_core-0.6.0/src/block.rs:280:1: item name starts with its containing module's name -rand_core-0.6.0/src/block.rs:319:5: you have declared `#[inline(always)]` on `index`. This is usually a bad idea -rand_core-0.6.0/src/block.rs:405:5: you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea -rand_core-0.6.0/src/block.rs:415:5: you have declared `#[inline(always)]` on `from_seed`. This is usually a bad idea -rand_core-0.6.0/src/block.rs:420:5: you have declared `#[inline(always)]` on `seed_from_u64`. This is usually a bad idea -rand_core-0.6.0/src/block.rs:425:5: you have declared `#[inline(always)]` on `from_rng`. This is usually a bad idea -rand_core-0.6.0/src/block.rs:67:14: you should put `module][crate::block` between ticks in the documentation -rand_core-0.6.0/src/block.rs:68:1: item name starts with its containing module's name -rand_core-0.6.0/src/error.rs:106:5: this method could have a `#[must_use]` attribute -rand_core-0.6.0/src/error.rs:87:5: this method could have a `#[must_use]` attribute -rand_core-0.6.0/src/error.rs:95:74: casting `u32` to `i32` may wrap around the value -rand_core-0.6.0/src/lib.rs:179:5: docs for function returning `Result` missing `# Errors` section -rand_core-0.6.0/src/lib.rs:301:5: this method could have a `#[must_use]` attribute -rand_core-0.6.0/src/lib.rs:303:26: long literal lacking separators -rand_core-0.6.0/src/lib.rs:304:26: long literal lacking separators -rand_core-0.6.0/src/lib.rs:313:30: casting `u64` to `u32` may truncate the value -rand_core-0.6.0/src/lib.rs:314:23: casting `u64` to `u32` may truncate the value -rand_core-0.6.0/src/lib.rs:346:5: docs for function returning `Result` missing `# Errors` section -rand_core-0.6.0/src/lib.rs:381:5: you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea -rand_core-0.6.0/src/lib.rs:386:5: you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea -rand_core-0.6.0/src/lib.rs:391:5: you have declared `#[inline(always)]` on `fill_bytes`. This is usually a bad idea -rand_core-0.6.0/src/lib.rs:396:5: you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea -rayon-1.5.0/src/collections/binary_heap.rs:7:5: usage of wildcard import -rayon-1.5.0/src/collections/binary_heap.rs:8:5: usage of wildcard import -rayon-1.5.0/src/collections/btree_map.rs:7:5: usage of wildcard import -rayon-1.5.0/src/collections/btree_map.rs:8:5: usage of wildcard import -rayon-1.5.0/src/collections/btree_set.rs:7:5: usage of wildcard import -rayon-1.5.0/src/collections/btree_set.rs:8:5: usage of wildcard import -rayon-1.5.0/src/collections/hash_map.rs:10:5: usage of wildcard import -rayon-1.5.0/src/collections/hash_map.rs:9:5: usage of wildcard import -rayon-1.5.0/src/collections/hash_set.rs:10:5: usage of wildcard import -rayon-1.5.0/src/collections/hash_set.rs:9:5: usage of wildcard import -rayon-1.5.0/src/collections/linked_list.rs:7:5: usage of wildcard import -rayon-1.5.0/src/collections/linked_list.rs:8:5: usage of wildcard import -rayon-1.5.0/src/collections/mod.rs:59:32: replacing a value of type `T` with `T::default()` is better expressed using `std::mem::take` -rayon-1.5.0/src/collections/vec_deque.rs:8:5: usage of wildcard import -rayon-1.5.0/src/collections/vec_deque.rs:9:5: usage of wildcard import -rayon-1.5.0/src/compile_fail/cannot_collect_filtermap_data.rs:2:1: needless `fn main` in doctest -rayon-1.5.0/src/compile_fail/cannot_zip_filtered_data.rs:2:1: needless `fn main` in doctest -rayon-1.5.0/src/compile_fail/cell_par_iter.rs:2:1: needless `fn main` in doctest -rayon-1.5.0/src/compile_fail/no_send_par_iter.rs:25:1: needless `fn main` in doctest -rayon-1.5.0/src/compile_fail/no_send_par_iter.rs:46:1: needless `fn main` in doctest -rayon-1.5.0/src/compile_fail/no_send_par_iter.rs:4:1: needless `fn main` in doctest -rayon-1.5.0/src/compile_fail/rc_par_iter.rs:2:1: needless `fn main` in doctest -rayon-1.5.0/src/iter/chain.rs:103:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/chain.rs:122:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/chain.rs:128:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/chain.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/chain.rs:221:36: you should put `ExactSizeIterator` between ticks in the documentation -rayon-1.5.0/src/iter/chain.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/chain.rs:51:38: use Option::map_or_else instead of an if let/else -rayon-1.5.0/src/iter/chain.rs:58:14: `a` is being shadowed -rayon-1.5.0/src/iter/chain.rs:58:17: `b` is being shadowed -rayon-1.5.0/src/iter/chain.rs:78:14: `a` is being shadowed -rayon-1.5.0/src/iter/chain.rs:78:17: `b` is being shadowed -rayon-1.5.0/src/iter/chain.rs:97:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/chunks.rs:3:5: usage of wildcard import -rayon-1.5.0/src/iter/chunks.rs:4:5: usage of wildcard import -rayon-1.5.0/src/iter/chunks.rs:77:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/chunks.rs:83:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/cloned.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/cloned.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/cloned.rs:71:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/cloned.rs:75:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/collect/consumer.rs:141:5: you should put `CollectReducer` between ticks in the documentation -rayon-1.5.0/src/iter/collect/consumer.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/collect/consumer.rs:28:5: you should put `CollectResult` between ticks in the documentation -rayon-1.5.0/src/iter/collect/consumer.rs:36:37: generally you want to avoid `&mut &mut _` if possible -rayon-1.5.0/src/iter/collect/consumer.rs:36:37: generally you want to avoid `&mut &mut _` if possible -rayon-1.5.0/src/iter/collect/mod.rs:154:9: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -rayon-1.5.0/src/iter/copied.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/copied.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/copied.rs:71:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/copied.rs:75:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/empty.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/empty.rs:24:1: this function could have a `#[must_use]` attribute -rayon-1.5.0/src/iter/empty.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/enumerate.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/enumerate.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/enumerate.rs:64:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/enumerate.rs:68:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/extend.rs:143:63: I see you're using a LinkedList! Perhaps you meant some other data structure? -rayon-1.5.0/src/iter/extend.rs:182:57: I see you're using a LinkedList! Perhaps you meant some other data structure? -rayon-1.5.0/src/iter/extend.rs:218:32: I see you're using a LinkedList! Perhaps you meant some other data structure? -rayon-1.5.0/src/iter/extend.rs:218:59: I see you're using a LinkedList! Perhaps you meant some other data structure? -rayon-1.5.0/src/iter/extend.rs:25:42: I see you're using a LinkedList! Perhaps you meant some other data structure? -rayon-1.5.0/src/iter/extend.rs:287:62: I see you're using a LinkedList! Perhaps you meant some other data structure? -rayon-1.5.0/src/iter/extend.rs:322:56: I see you're using a LinkedList! Perhaps you meant some other data structure? -rayon-1.5.0/src/iter/extend.rs:41:27: I see you're using a LinkedList! Perhaps you meant some other data structure? -rayon-1.5.0/src/iter/extend.rs:47:30: I see you're using a LinkedList! Perhaps you meant some other data structure? -rayon-1.5.0/src/iter/extend.rs:47:56: I see you're using a LinkedList! Perhaps you meant some other data structure? -rayon-1.5.0/src/iter/extend.rs:47:74: I see you're using a LinkedList! Perhaps you meant some other data structure? -rayon-1.5.0/src/iter/extend.rs:53:29: I see you're using a LinkedList! Perhaps you meant some other data structure? -rayon-1.5.0/src/iter/extend.rs:57:36: I see you're using a LinkedList! Perhaps you meant some other data structure? -rayon-1.5.0/src/iter/extend.rs:59:61: I see you're using a LinkedList! Perhaps you meant some other data structure? -rayon-1.5.0/src/iter/filter.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/filter.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/filter_map.rs:123:9: use Option::map_or instead of an if let/else -rayon-1.5.0/src/iter/filter_map.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/filter_map.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/find.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/find.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/find_first_last/mod.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/find_first_last/mod.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/find_first_last/mod.rs:32:67: you should put `MatchPosition` between ticks in the documentation -rayon-1.5.0/src/iter/flat_map.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/flat_map.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/flat_map_iter.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/flat_map_iter.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/flatten.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/flatten.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/flatten_iter.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/flatten_iter.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/fold.rs:158:13: binding's name is too similar to existing binding -rayon-1.5.0/src/iter/fold.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/fold.rs:204:1: item name starts with its containing module's name -rayon-1.5.0/src/iter/fold.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/for_each.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/for_each.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/inspect.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/inspect.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/inspect.rs:83:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/inspect.rs:88:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/interleave.rs:111:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/interleave.rs:119:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/interleave.rs:195:30: you should put `self.i_len` between ticks in the documentation -rayon-1.5.0/src/iter/interleave.rs:195:43: you should put `self.j_len` between ticks in the documentation -rayon-1.5.0/src/iter/interleave.rs:199:23: you should put `self.i_len` between ticks in the documentation -rayon-1.5.0/src/iter/interleave.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/interleave.rs:200:23: you should put `self.j_len` between ticks in the documentation -rayon-1.5.0/src/iter/interleave.rs:249:41: you should put `DoubleEndedIterator` between ticks in the documentation -rayon-1.5.0/src/iter/interleave.rs:250:5: you should put `ExactSizeIterator` between ticks in the documentation -rayon-1.5.0/src/iter/interleave.rs:263:33: you should put `InterleaveSeq` between ticks in the documentation -rayon-1.5.0/src/iter/interleave.rs:280:17: wildcard match will miss any future added variants -rayon-1.5.0/src/iter/interleave.rs:285:17: wildcard match will miss any future added variants -rayon-1.5.0/src/iter/interleave.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/interleave.rs:313:9: `if` chain can be rewritten with `match` -rayon-1.5.0/src/iter/interleave.rs:82:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/interleave.rs:90:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/interleave_shortest.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/intersperse.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/intersperse.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/intersperse.rs:90:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/intersperse.rs:96:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/len.rs:12:1: item name ends with its containing module's name -rayon-1.5.0/src/iter/len.rs:146:1: item name ends with its containing module's name -rayon-1.5.0/src/iter/len.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/len.rs:200:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/len.rs:205:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/len.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/len.rs:66:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/len.rs:71:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/map.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/map.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/map.rs:84:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/map.rs:89:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/map_with.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/map_with.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/map_with.rs:419:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/map_with.rs:425:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/map_with.rs:90:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/map_with.rs:96:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/mod.rs:1874:24: this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -rayon-1.5.0/src/iter/mod.rs:2171:1: trait `IndexedParallelIterator` has a `len` method but no (possibly inherited) `is_empty` method -rayon-1.5.0/src/iter/mod.rs:2371:26: this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -rayon-1.5.0/src/iter/mod.rs:2411:26: this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -rayon-1.5.0/src/iter/mod.rs:82:5: usage of wildcard import -rayon-1.5.0/src/iter/multizip.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/multizip.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/noop.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/once.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/once.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/panic_fuse.rs:102:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/panic_fuse.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/panic_fuse.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/panic_fuse.rs:98:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/par_bridge.rs:136:28: redundant else block -rayon-1.5.0/src/iter/par_bridge.rs:163:28: redundant else block -rayon-1.5.0/src/iter/plumbing/mod.rs:216:58: you should put `find_first` between ticks in the documentation -rayon-1.5.0/src/iter/plumbing/mod.rs:359:5: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/plumbing/mod.rs:364:5: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/plumbing/mod.rs:399:5: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/plumbing/mod.rs:53:19: you should put `DoubleEndedIterator` between ticks in the documentation -rayon-1.5.0/src/iter/plumbing/mod.rs:53:43: you should put `ExactSizeIterator` between ticks in the documentation -rayon-1.5.0/src/iter/plumbing/mod.rs:54:31: you should put `IntoIterator` between ticks in the documentation -rayon-1.5.0/src/iter/plumbing/mod.rs:55:5: you should put `IntoIterator` between ticks in the documentation -rayon-1.5.0/src/iter/positions.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/positions.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/product.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/reduce.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/repeat.rs:103:1: item name starts with its containing module's name -rayon-1.5.0/src/iter/repeat.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/repeat.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/rev.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/rev.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/rev.rs:63:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/rev.rs:68:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/skip.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/skip.rs:3:5: usage of wildcard import -rayon-1.5.0/src/iter/skip.rs:68:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/skip.rs:73:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/splitter.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/splitter.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/step_by.rs:4:5: usage of wildcard import -rayon-1.5.0/src/iter/step_by.rs:5:5: usage of wildcard import -rayon-1.5.0/src/iter/step_by.rs:73:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/step_by.rs:79:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/sum.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/take.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/take.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/take.rs:67:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/take.rs:72:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/try_fold.rs:190:1: item name starts with its containing module's name -rayon-1.5.0/src/iter/try_fold.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/try_fold.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/try_reduce.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/try_reduce_with.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/unzip.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/unzip.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/update.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/update.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/update.rs:82:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/update.rs:87:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/while_some.rs:130:22: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -rayon-1.5.0/src/iter/while_some.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/while_some.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/zip.rs:102:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/zip.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/zip.rs:2:5: usage of wildcard import -rayon-1.5.0/src/iter/zip.rs:74:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/zip.rs:79:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/zip.rs:97:9: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/iter/zip_eq.rs:1:5: usage of wildcard import -rayon-1.5.0/src/iter/zip_eq.rs:2:5: usage of wildcard import -rayon-1.5.0/src/option.rs:8:5: usage of wildcard import -rayon-1.5.0/src/option.rs:9:5: usage of wildcard import -rayon-1.5.0/src/par_either.rs:1:5: usage of wildcard import -rayon-1.5.0/src/par_either.rs:3:5: usage of wildcard import -rayon-1.5.0/src/private.rs:9:1: item name starts with its containing module's name -rayon-1.5.0/src/range.rs:19:5: usage of wildcard import -rayon-1.5.0/src/range.rs:20:5: usage of wildcard import -rayon-1.5.0/src/range_inclusive.rs:194:9: an inclusive range would be more readable -rayon-1.5.0/src/range_inclusive.rs:194:9: an inclusive range would be more readable -rayon-1.5.0/src/range_inclusive.rs:19:5: usage of wildcard import -rayon-1.5.0/src/range_inclusive.rs:209:9: an inclusive range would be more readable -rayon-1.5.0/src/range_inclusive.rs:209:9: an inclusive range would be more readable -rayon-1.5.0/src/range_inclusive.rs:20:5: usage of wildcard import -rayon-1.5.0/src/range_inclusive.rs:231:9: an inclusive range would be more readable -rayon-1.5.0/src/range_inclusive.rs:231:9: an inclusive range would be more readable -rayon-1.5.0/src/result.rs:8:5: usage of wildcard import -rayon-1.5.0/src/result.rs:9:5: usage of wildcard import -rayon-1.5.0/src/slice/mergesort.rs:102:5: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/slice/mergesort.rs:109:5: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/slice/mergesort.rs:114:5: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/slice/mergesort.rs:211:5: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/slice/mergesort.rs:217:5: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/slice/mergesort.rs:251:5: you should put `TimSort` between ticks in the documentation -rayon-1.5.0/src/slice/mergesort.rs:252:5: you should put bare URLs between `<`/`>` or make a proper Markdown link -rayon-1.5.0/src/slice/mergesort.rs:286:59: you should put `TimSort` between ticks in the documentation -rayon-1.5.0/src/slice/mergesort.rs:333:24: redundant else block -rayon-1.5.0/src/slice/mergesort.rs:513:5: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/slice/mergesort.rs:521:5: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/slice/mergesort.rs:7:5: usage of wildcard import -rayon-1.5.0/src/slice/mergesort.rs:98:5: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/slice/mod.rs:15:5: usage of wildcard import -rayon-1.5.0/src/slice/mod.rs:16:5: usage of wildcard import -rayon-1.5.0/src/slice/mod.rs:17:5: usage of wildcard import -rayon-1.5.0/src/slice/mod.rs:25:1: item name ends with its containing module's name -rayon-1.5.0/src/slice/mod.rs:657:5: this method could have a `#[must_use]` attribute -rayon-1.5.0/src/slice/mod.rs:971:5: this method could have a `#[must_use]` attribute -rayon-1.5.0/src/slice/quicksort.rs:230:36: you should put `BlockQuicksort` between ticks in the documentation -rayon-1.5.0/src/slice/quicksort.rs:233:1: this function has too many lines (117/100) -rayon-1.5.0/src/slice/quicksort.rs:258:26: integer type suffix should be separated by an underscore -rayon-1.5.0/src/slice/quicksort.rs:265:26: integer type suffix should be separated by an underscore -rayon-1.5.0/src/slice/quicksort.rs:268:5: adding items after statements is confusing, since items exist from the start of the scope -rayon-1.5.0/src/slice/quicksort.rs:308:30: casting `usize` to `u8` may truncate the value -rayon-1.5.0/src/slice/quicksort.rs:325:30: casting `usize` to `u8` may truncate the value -rayon-1.5.0/src/slice/quicksort.rs:393:36: casting `u8` to `isize` may wrap around the value on targets with 32-bit wide pointers -rayon-1.5.0/src/slice/quicksort.rs:405:40: casting `u8` to `isize` may wrap around the value on targets with 32-bit wide pointers -rayon-1.5.0/src/slice/quicksort.rs:430:14: `pivot` is being shadowed -rayon-1.5.0/src/slice/quicksort.rs:439:13: `pivot` is being shadowed -rayon-1.5.0/src/slice/quicksort.rs:482:10: `pivot` is being shadowed -rayon-1.5.0/src/slice/quicksort.rs:491:9: `pivot` is being shadowed -rayon-1.5.0/src/slice/quicksort.rs:534:26: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -rayon-1.5.0/src/slice/quicksort.rs:545:17: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers -rayon-1.5.0/src/slice/quicksort.rs:588:17: the operation is ineffective. Consider reducing it to `len / 4` -rayon-1.5.0/src/slice/quicksort.rs:716:14: `pivot` is being shadowed -rayon-1.5.0/src/split_producer.rs:56:16: use Option::map_or_else instead of an if let/else -rayon-1.5.0/src/split_producer.rs:92:9: use Option::map_or instead of an if let/else -rayon-1.5.0/src/str.rs:16:5: usage of wildcard import -rayon-1.5.0/src/str.rs:17:5: usage of wildcard import -rayon-1.5.0/src/str.rs:18:5: usage of wildcard import -rayon-1.5.0/src/str.rs:25:5: casting `u8` to `i8` may wrap around the value -rayon-1.5.0/src/str.rs:715:9: stripping a suffix manually -rayon-1.5.0/src/string.rs:5:5: usage of wildcard import -rayon-1.5.0/src/vec.rs:137:12: length comparison to zero -rayon-1.5.0/src/vec.rs:8:5: usage of wildcard import -rayon-1.5.0/src/vec.rs:9:5: usage of wildcard import -regex-1.3.2/src/backtrack.rs:100:13: redundant field names in struct initialization -regex-1.3.2/src/backtrack.rs:133:17: it looks like the same item is being pushed into this Vec -regex-1.3.2/src/backtrack.rs:145:20: unnecessary boolean `not` operation -regex-1.3.2/src/backtrack.rs:199:13: usage of wildcard import for enum variants -regex-1.3.2/src/backtrack.rs:223:29: redundant field names in struct initialization -regex-1.3.2/src/backtrack.rs:230:66: redundant field names in struct initialization -regex-1.3.2/src/backtrack.rs:284:21: casting `u32` to `u64` may become silently lossy if you later change the type -regex-1.3.2/src/backtrack.rs:287:5: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -regex-1.3.2/src/backtrack.rs:97:13: redundant field names in struct initialization -regex-1.3.2/src/backtrack.rs:98:13: redundant field names in struct initialization -regex-1.3.2/src/backtrack.rs:99:13: redundant field names in struct initialization -regex-1.3.2/src/compile.rs:1005:32: long literal lacking separators -regex-1.3.2/src/compile.rs:1006:21: long literal lacking separators -regex-1.3.2/src/compile.rs:1008:18: casting `u8` to `u64` may become silently lossy if you later change the type -regex-1.3.2/src/compile.rs:1009:18: casting `u8` to `u64` may become silently lossy if you later change the type -regex-1.3.2/src/compile.rs:1010:9: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers -regex-1.3.2/src/compile.rs:102:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/compile.rs:1037:37: casting `u16` to `u8` may truncate the value -regex-1.3.2/src/compile.rs:1037:55: casting `u16` to `u8` may truncate the value -regex-1.3.2/src/compile.rs:1040:28: casting `u16` to `u8` may truncate the value -regex-1.3.2/src/compile.rs:1040:38: casting `u16` to `u8` may truncate the value -regex-1.3.2/src/compile.rs:1051:25: integer type suffix should be separated by an underscore -regex-1.3.2/src/compile.rs:1071:8: casting `u32` to `u64` may become silently lossy if you later change the type -regex-1.3.2/src/compile.rs:112:5: docs for function returning `Result` missing `# Errors` section -regex-1.3.2/src/compile.rs:154:30: redundant closure found -regex-1.3.2/src/compile.rs:156:30: redundant closure found -regex-1.3.2/src/compile.rs:185:5: this function's return value is unnecessarily wrapped by `Result` -regex-1.3.2/src/compile.rs:187:40: redundant closure found -regex-1.3.2/src/compile.rs:201:53: you should put `MaybeInsts` between ticks in the documentation -regex-1.3.2/src/compile.rs:241:63: you should put `c_concat` between ticks in the documentation -regex-1.3.2/src/compile.rs:245:5: this function has too many lines (111/100) -regex-1.3.2/src/compile.rs:247:13: usage of wildcard import for enum variants -regex-1.3.2/src/compile.rs:373:24: redundant field names in struct initialization -regex-1.3.2/src/compile.rs:373:36: redundant field names in struct initialization -regex-1.3.2/src/compile.rs:378:12: unnecessary boolean `not` operation -regex-1.3.2/src/compile.rs:400:37: redundant field names in struct initialization -regex-1.3.2/src/compile.rs:407:51: redundant field names in struct initialization -regex-1.3.2/src/compile.rs:409:24: redundant field names in struct initialization -regex-1.3.2/src/compile.rs:417:5: this function's return value is unnecessarily wrapped by `Result` -regex-1.3.2/src/compile.rs:42:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/compile.rs:42:5: you should consider adding a `Default` implementation for `compile::Compiler` -regex-1.3.2/src/compile.rs:444:5: this function's return value is unnecessarily wrapped by `Result` -regex-1.3.2/src/compile.rs:445:57: redundant field names in struct initialization -regex-1.3.2/src/compile.rs:446:20: redundant field names in struct initialization -regex-1.3.2/src/compile.rs:466:20: redundant field names in struct initialization -regex-1.3.2/src/compile.rs:466:32: redundant field names in struct initialization -regex-1.3.2/src/compile.rs:519:13: usage of wildcard import for enum variants -regex-1.3.2/src/compile.rs:55:57: you should put `size_limit` between ticks in the documentation -regex-1.3.2/src/compile.rs:58:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/compile.rs:748:41: redundant field names in struct initialization -regex-1.3.2/src/compile.rs:74:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/compile.rs:751:54: redundant field names in struct initialization -regex-1.3.2/src/compile.rs:765:41: redundant field names in struct initialization -regex-1.3.2/src/compile.rs:765:55: redundant field names in struct initialization -regex-1.3.2/src/compile.rs:825:39: redundant field names in struct initialization -regex-1.3.2/src/compile.rs:825:51: redundant field names in struct initialization -regex-1.3.2/src/compile.rs:828:49: redundant field names in struct initialization -regex-1.3.2/src/compile.rs:828:61: redundant field names in struct initialization -regex-1.3.2/src/compile.rs:830:59: redundant field names in struct initialization -regex-1.3.2/src/compile.rs:830:71: redundant field names in struct initialization -regex-1.3.2/src/compile.rs:832:43: redundant field names in struct initialization -regex-1.3.2/src/compile.rs:835:41: redundant field names in struct initialization -regex-1.3.2/src/compile.rs:835:53: redundant field names in struct initialization -regex-1.3.2/src/compile.rs:835:67: redundant field names in struct initialization -regex-1.3.2/src/compile.rs:83:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/compile.rs:896:5: this function's return value is unnecessarily wrapped by `Result` -regex-1.3.2/src/compile.rs:905:17: redundant field names in struct initialization -regex-1.3.2/src/compile.rs:953:17: you should put `HashMap` between ticks in the documentation -regex-1.3.2/src/compile.rs:95:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/compile.rs:980:26: integer type suffix should be separated by an underscore -regex-1.3.2/src/compile.rs:994:44: redundant field names in struct initialization -regex-1.3.2/src/compile.rs:994:54: redundant field names in struct initialization -regex-1.3.2/src/dfa.rs:1007:17: binding's name is too similar to existing binding -regex-1.3.2/src/dfa.rs:1010:22: binding's name is too similar to existing binding -regex-1.3.2/src/dfa.rs:1059:13: usage of wildcard import for enum variants -regex-1.3.2/src/dfa.rs:1060:13: usage of wildcard import for enum variants -regex-1.3.2/src/dfa.rs:1084:38: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -regex-1.3.2/src/dfa.rs:1087:38: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -regex-1.3.2/src/dfa.rs:1090:38: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -regex-1.3.2/src/dfa.rs:1093:38: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -regex-1.3.2/src/dfa.rs:1096:38: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -regex-1.3.2/src/dfa.rs:1101:38: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -regex-1.3.2/src/dfa.rs:1104:38: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -regex-1.3.2/src/dfa.rs:1107:38: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -regex-1.3.2/src/dfa.rs:1117:30: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -regex-1.3.2/src/dfa.rs:1120:47: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -regex-1.3.2/src/dfa.rs:1121:30: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -regex-1.3.2/src/dfa.rs:1129:13: you should put `is_match` between ticks in the documentation -regex-1.3.2/src/dfa.rs:1134:13: you should put `is_match` between ticks in the documentation -regex-1.3.2/src/dfa.rs:1185:68: you should put `is_match` between ticks in the documentation -regex-1.3.2/src/dfa.rs:1193:13: usage of wildcard import for enum variants -regex-1.3.2/src/dfa.rs:1244:50: you should put `current_state` between ticks in the documentation -regex-1.3.2/src/dfa.rs:1338:58: you should put `STATE_DEAD` between ticks in the documentation -regex-1.3.2/src/dfa.rs:1339:9: you should put `STATE_UNKNOWN` between ticks in the documentation -regex-1.3.2/src/dfa.rs:1366:25: you should put `STATE_DEAD` between ticks in the documentation -regex-1.3.2/src/dfa.rs:1366:46: you should put `STATE_UNKNOWN` between ticks in the documentation -regex-1.3.2/src/dfa.rs:1367:41: you have declared `#[inline(always)]` on `start_state`. This is usually a bad idea -regex-1.3.2/src/dfa.rs:1380:14: the operation is ineffective. Consider reducing it to `(empty_flags.start as u8)` -regex-1.3.2/src/dfa.rs:1388:15: indexing into a vector may panic -regex-1.3.2/src/dfa.rs:1412:20: unused `self` argument -regex-1.3.2/src/dfa.rs:1438:9: unused `self` argument -regex-1.3.2/src/dfa.rs:1472:9: you should put `StatePtr` between ticks in the documentation -regex-1.3.2/src/dfa.rs:1490:54: casting `i32` to `u8` may lose the sign of the value -regex-1.3.2/src/dfa.rs:1490:54: casting `i32` to `u8` may truncate the value -regex-1.3.2/src/dfa.rs:1521:20: you should put `num_byte_classes` between ticks in the documentation -regex-1.3.2/src/dfa.rs:1529:41: you have declared `#[inline(always)]` on `byte_class`. This is usually a bad idea -regex-1.3.2/src/dfa.rs:1537:14: you should put `byte_class` between ticks in the documentation -regex-1.3.2/src/dfa.rs:1538:41: you have declared `#[inline(always)]` on `u8_class`. This is usually a bad idea -regex-1.3.2/src/dfa.rs:1562:18: you should put `STATE_START` between ticks in the documentation -regex-1.3.2/src/dfa.rs:1614:13: redundant field names in struct initialization -regex-1.3.2/src/dfa.rs:1651:38: redundant field names in struct initialization -regex-1.3.2/src/dfa.rs:1700:17: this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -regex-1.3.2/src/dfa.rs:1701:18: digits of hex or binary literal not grouped by four -regex-1.3.2/src/dfa.rs:1705:19: digits of hex or binary literal not grouped by four -regex-1.3.2/src/dfa.rs:1708:16: this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -regex-1.3.2/src/dfa.rs:1709:18: digits of hex or binary literal not grouped by four -regex-1.3.2/src/dfa.rs:1713:19: digits of hex or binary literal not grouped by four -regex-1.3.2/src/dfa.rs:1716:18: this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -regex-1.3.2/src/dfa.rs:1717:18: digits of hex or binary literal not grouped by four -regex-1.3.2/src/dfa.rs:1721:19: digits of hex or binary literal not grouped by four -regex-1.3.2/src/dfa.rs:1727:14: casting `u8` to `u16` may become silently lossy if you later change the type -regex-1.3.2/src/dfa.rs:1732:15: this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -regex-1.3.2/src/dfa.rs:1736:22: this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -regex-1.3.2/src/dfa.rs:1741:9: match expression looks like `matches!` macro -regex-1.3.2/src/dfa.rs:1747:16: this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -regex-1.3.2/src/dfa.rs:1751:18: casting `u16` to `u8` may truncate the value -regex-1.3.2/src/dfa.rs:1815:38: casting `usize` to `u8` may truncate the value -regex-1.3.2/src/dfa.rs:1821:21: casting `u32` to `u64` may become silently lossy if you later change the type -regex-1.3.2/src/dfa.rs:1824:5: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -regex-1.3.2/src/dfa.rs:1848:5: you should put bare URLs between `<`/`>` or make a proper Markdown link -regex-1.3.2/src/dfa.rs:1850:18: casting `i32` to `u32` may lose the sign of the value -regex-1.3.2/src/dfa.rs:1857:5: you should put bare URLs between `<`/`>` or make a proper Markdown link -regex-1.3.2/src/dfa.rs:1860:17: casting `u32` to `i32` may wrap around the value -regex-1.3.2/src/dfa.rs:1867:5: you should put bare URLs between `<`/`>` or make a proper Markdown link -regex-1.3.2/src/dfa.rs:1870:19: casting `u32` to `u8` may truncate the value -regex-1.3.2/src/dfa.rs:1873:15: casting `u32` to `u8` may truncate the value -regex-1.3.2/src/dfa.rs:1876:5: you should put bare URLs between `<`/`>` or make a proper Markdown link -regex-1.3.2/src/dfa.rs:1882:26: casting `u8` to `u32` may become silently lossy if you later change the type -regex-1.3.2/src/dfa.rs:1884:15: casting `u8` to `u32` may become silently lossy if you later change the type -regex-1.3.2/src/dfa.rs:277:17: casting `u32` to `i32` may wrap around the value -regex-1.3.2/src/dfa.rs:277:31: casting `u32` to `i32` may wrap around the value -regex-1.3.2/src/dfa.rs:295:20: casting `usize` to `i32` may truncate the value on targets with 64-bit wide pointers -regex-1.3.2/src/dfa.rs:295:20: casting `usize` to `i32` may wrap around the value on targets with 32-bit wide pointers -regex-1.3.2/src/dfa.rs:299:21: casting `i32` to `usize` may lose the sign of the value -regex-1.3.2/src/dfa.rs:34:46: you should put bare URLs between `<`/`>` or make a proper Markdown link -regex-1.3.2/src/dfa.rs:398:1: more than 3 bools in a struct -regex-1.3.2/src/dfa.rs:446:41: you have declared `#[inline(always)]` on `forward`. This is usually a bad idea -regex-1.3.2/src/dfa.rs:457:13: redundant field names in struct initialization -regex-1.3.2/src/dfa.rs:459:13: redundant field names in struct initialization -regex-1.3.2/src/dfa.rs:460:13: redundant field names in struct initialization -regex-1.3.2/src/dfa.rs:476:41: you have declared `#[inline(always)]` on `reverse`. This is usually a bad idea -regex-1.3.2/src/dfa.rs:487:13: redundant field names in struct initialization -regex-1.3.2/src/dfa.rs:489:13: redundant field names in struct initialization -regex-1.3.2/src/dfa.rs:490:13: redundant field names in struct initialization -regex-1.3.2/src/dfa.rs:506:41: you have declared `#[inline(always)]` on `forward_many`. This is usually a bad idea -regex-1.3.2/src/dfa.rs:518:13: redundant field names in struct initialization -regex-1.3.2/src/dfa.rs:520:13: redundant field names in struct initialization -regex-1.3.2/src/dfa.rs:554:41: you have declared `#[inline(always)]` on `exec_at`. This is usually a bad idea -regex-1.3.2/src/dfa.rs:555:5: this function has too many lines (101/100) -regex-1.3.2/src/dfa.rs:58:9: usage of wildcard import for enum variants -regex-1.3.2/src/dfa.rs:667:21: binding's name is too similar to existing binding -regex-1.3.2/src/dfa.rs:747:41: you have declared `#[inline(always)]` on `exec_at_reverse`. This is usually a bad idea -regex-1.3.2/src/dfa.rs:795:21: binding's name is too similar to existing binding -regex-1.3.2/src/dfa.rs:848:9: you should put `next_si` between ticks in the documentation -regex-1.3.2/src/dfa.rs:852:41: you have declared `#[inline(always)]` on `next_si`. This is usually a bad idea -regex-1.3.2/src/dfa.rs:885:12: you should put `STATE_DEAD` between ticks in the documentation -regex-1.3.2/src/dfa.rs:889:9: you should put `STATE_UNKNOWN` between ticks in the documentation -regex-1.3.2/src/dfa.rs:897:13: usage of wildcard import for enum variants -regex-1.3.2/src/dfa.rs:979:29: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers -regex-1.3.2/src/error.rs:6:1: this seems like a manual implementation of the non-exhaustive pattern -regex-1.3.2/src/exec.rs:1000:14: you should put `captures_nfa` between ticks in the documentation -regex-1.3.2/src/exec.rs:100:1: item name starts with its containing module's name -regex-1.3.2/src/exec.rs:1028:5: this function has too many arguments (9/7) -regex-1.3.2/src/exec.rs:1039:13: usage of wildcard import for enum variants -regex-1.3.2/src/exec.rs:1144:13: usage of wildcard import for enum variants -regex-1.3.2/src/exec.rs:1179:26: this `match` has identical arm bodies -regex-1.3.2/src/exec.rs:122:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/exec.rs:1250:41: you have declared `#[inline(always)]` on `searcher`. This is usually a bad idea -regex-1.3.2/src/exec.rs:1260:41: you have declared `#[inline(always)]` on `searcher_str`. This is usually a bad idea -regex-1.3.2/src/exec.rs:1270:17: you should put `RegexSet` between ticks in the documentation -regex-1.3.2/src/exec.rs:1280:17: you should put `RegexSet` between ticks in the documentation -regex-1.3.2/src/exec.rs:137:9: field assignment outside of initializer for an instance created with Default::default() -regex-1.3.2/src/exec.rs:142:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/exec.rs:158:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/exec.rs:168:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/exec.rs:181:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/exec.rs:195:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/exec.rs:204:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/exec.rs:210:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/exec.rs:245:62: this `if` has identical blocks -regex-1.3.2/src/exec.rs:251:21: unnecessary boolean `not` operation -regex-1.3.2/src/exec.rs:262:60: this `if` has identical blocks -regex-1.3.2/src/exec.rs:268:21: unnecessary boolean `not` operation -regex-1.3.2/src/exec.rs:278:13: redundant field names in struct initialization -regex-1.3.2/src/exec.rs:281:13: redundant field names in struct initialization -regex-1.3.2/src/exec.rs:286:5: docs for function returning `Result` missing `# Errors` section -regex-1.3.2/src/exec.rs:300:30: redundant field names in struct initialization -regex-1.3.2/src/exec.rs:308:17: binding's name is too similar to existing binding -regex-1.3.2/src/exec.rs:329:13: redundant field names in struct initialization -regex-1.3.2/src/exec.rs:330:13: redundant field names in struct initialization -regex-1.3.2/src/exec.rs:331:13: redundant field names in struct initialization -regex-1.3.2/src/exec.rs:334:13: redundant field names in struct initialization -regex-1.3.2/src/exec.rs:340:19: redundant field names in struct initialization -regex-1.3.2/src/exec.rs:344:27: unused `self` argument -regex-1.3.2/src/exec.rs:383:41: you have declared `#[inline(always)]` on `shortest_match_at`. This is usually a bad idea -regex-1.3.2/src/exec.rs:388:41: you have declared `#[inline(always)]` on `is_match_at`. This is usually a bad idea -regex-1.3.2/src/exec.rs:393:41: you have declared `#[inline(always)]` on `find_at`. This is usually a bad idea -regex-1.3.2/src/exec.rs:398:41: you have declared `#[inline(always)]` on `captures_read_at`. This is usually a bad idea -regex-1.3.2/src/exec.rs:425:41: you have declared `#[inline(always)]` on `shortest_match_at`. This is usually a bad idea -regex-1.3.2/src/exec.rs:44:1: item name starts with its containing module's name -regex-1.3.2/src/exec.rs:473:9: you should put `shortest_match(...).is_some` between ticks in the documentation -regex-1.3.2/src/exec.rs:474:41: you have declared `#[inline(always)]` on `is_match_at`. This is usually a bad idea -regex-1.3.2/src/exec.rs:524:41: you have declared `#[inline(always)]` on `find_at`. This is usually a bad idea -regex-1.3.2/src/exec.rs:52:1: item name starts with its containing module's name -regex-1.3.2/src/exec.rs:686:13: usage of wildcard import for enum variants -regex-1.3.2/src/exec.rs:727:13: usage of wildcard import for enum variants -regex-1.3.2/src/exec.rs:767:13: usage of wildcard import for enum variants -regex-1.3.2/src/exec.rs:783:41: you have declared `#[inline(always)]` on `shortest_dfa`. This is usually a bad idea -regex-1.3.2/src/exec.rs:791:41: you have declared `#[inline(always)]` on `shortest_dfa_reverse_suffix`. This is usually a bad idea -regex-1.3.2/src/exec.rs:823:13: usage of wildcard import for enum variants -regex-1.3.2/src/exec.rs:868:13: usage of wildcard import for enum variants -regex-1.3.2/src/exec.rs:897:31: you should put `shortest_nfa(...).is_some` between ticks in the documentation -regex-1.3.2/src/exec.rs:899:9: you should put `shortest_nfa` between ticks in the documentation -regex-1.3.2/src/exec.rs:905:14: you should put `match_nfa` between ticks in the documentation -regex-1.3.2/src/exec.rs:930:14: you should put `shortest_nfa` between ticks in the documentation -regex-1.3.2/src/exec.rs:981:14: you should put `find_nfa` between ticks in the documentation -regex-1.3.2/src/expand.rs:170:27: this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -regex-1.3.2/src/expand.rs:171:5: match expression looks like `matches!` macro -regex-1.3.2/src/expand.rs:22:13: calling `push_str()` using a single-character string literal -regex-1.3.2/src/expand.rs:27:23: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -regex-1.3.2/src/expand.rs:30:17: calling `push_str()` using a single-character string literal -regex-1.3.2/src/expand.rs:38:30: called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead -regex-1.3.2/src/expand.rs:42:21: called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead -regex-1.3.2/src/expand.rs:50:1: item name starts with its containing module's name -regex-1.3.2/src/expand.rs:69:23: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -regex-1.3.2/src/expand.rs:80:28: called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead -regex-1.3.2/src/expand.rs:84:21: called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead -regex-1.3.2/src/expand.rs:8:1: item name starts with its containing module's name -regex-1.3.2/src/input.rs:142:1: item name ends with its containing module's name -regex-1.3.2/src/input.rs:146:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/input.rs:15:1: item name starts with its containing module's name -regex-1.3.2/src/input.rs:165:31: redundant field names in struct initialization -regex-1.3.2/src/input.rs:178:13: usage of wildcard import for enum variants -regex-1.3.2/src/input.rs:228:1: item name ends with its containing module's name -regex-1.3.2/src/input.rs:236:21: redundant field names in struct initialization -regex-1.3.2/src/input.rs:236:33: redundant field names in struct initialization -regex-1.3.2/src/input.rs:24:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/input.rs:271:13: usage of wildcard import for enum variants -regex-1.3.2/src/input.rs:29:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/input.rs:362:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/input.rs:370:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/input.rs:371:42: redundant closure found -regex-1.3.2/src/input.rs:37:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/input.rs:388:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/input.rs:42:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/input.rs:47:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/input.rs:53:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/input.rs:58:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/input.rs:63:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/literal/imp.rs:101:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/literal/imp.rs:114:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/literal/imp.rs:127:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/literal/imp.rs:139:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/literal/imp.rs:144:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/literal/imp.rs:149:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/literal/imp.rs:154:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/literal/imp.rs:155:13: usage of wildcard import for enum variants -regex-1.3.2/src/literal/imp.rs:160:30: this `match` has identical arm bodies -regex-1.3.2/src/literal/imp.rs:167:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/literal/imp.rs:168:13: usage of wildcard import for enum variants -regex-1.3.2/src/literal/imp.rs:211:20: redundant else block -regex-1.3.2/src/literal/imp.rs:276:50: this `match` has identical arm bodies -regex-1.3.2/src/literal/imp.rs:342:41: you have declared `#[inline(always)]` on `find`. This is usually a bad idea -regex-1.3.2/src/literal/imp.rs:435:13: redundant field names in struct initialization -regex-1.3.2/src/literal/imp.rs:436:13: redundant field names in struct initialization -regex-1.3.2/src/literal/imp.rs:437:13: redundant field names in struct initialization -regex-1.3.2/src/literal/imp.rs:438:13: redundant field names in struct initialization -regex-1.3.2/src/literal/imp.rs:439:13: redundant field names in struct initialization -regex-1.3.2/src/literal/imp.rs:440:13: redundant field names in struct initialization -regex-1.3.2/src/literal/imp.rs:455:41: you have declared `#[inline(always)]` on `find`. This is usually a bad idea -regex-1.3.2/src/literal/imp.rs:46:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/literal/imp.rs:481:41: you have declared `#[inline(always)]` on `is_suffix`. This is usually a bad idea -regex-1.3.2/src/literal/imp.rs:51:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/literal/imp.rs:579:13: redundant field names in struct initialization -regex-1.3.2/src/literal/imp.rs:57:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/literal/imp.rs:580:13: redundant field names in struct initialization -regex-1.3.2/src/literal/imp.rs:583:13: redundant field names in struct initialization -regex-1.3.2/src/literal/imp.rs:602:9: adding items after statements is confusing, since items exist from the start of the scope -regex-1.3.2/src/literal/imp.rs:622:24: redundant else block -regex-1.3.2/src/literal/imp.rs:62:18: this argument is passed by value, but not consumed in the function body -regex-1.3.2/src/literal/imp.rs:637:24: redundant else block -regex-1.3.2/src/literal/imp.rs:648:9: unneeded `return` statement -regex-1.3.2/src/literal/imp.rs:651:44: you should put `BoyerMooreSearch` between ticks in the documentation -regex-1.3.2/src/literal/imp.rs:65:13: redundant field names in struct initialization -regex-1.3.2/src/literal/imp.rs:68:13: redundant field names in struct initialization -regex-1.3.2/src/literal/imp.rs:783:32: redundant else block -regex-1.3.2/src/literal/imp.rs:786:42: manual saturating arithmetic -regex-1.3.2/src/literal/imp.rs:78:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/literal/imp.rs:84:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/literal/imp.rs:850:20: long literal lacking separators -regex-1.3.2/src/literal/imp.rs:85:13: usage of wildcard import for enum variants -regex-1.3.2/src/pikevm.rs:103:15: redundant field names in struct initialization -regex-1.3.2/src/pikevm.rs:103:52: redundant field names in struct initialization -regex-1.3.2/src/pikevm.rs:114:5: this function has too many arguments (8/7) -regex-1.3.2/src/pikevm.rs:117:13: binding's name is too similar to existing binding -regex-1.3.2/src/pikevm.rs:124:17: binding's name is too similar to existing binding -regex-1.3.2/src/pikevm.rs:220:9: you should put `thread_caps` between ticks in the documentation -regex-1.3.2/src/pikevm.rs:222:16: you should put `at_next` between ticks in the documentation -regex-1.3.2/src/pikevm.rs:223:9: you should put `at_next` between ticks in the documentation -regex-1.3.2/src/pikevm.rs:224:5: this function has too many arguments (8/7) -regex-1.3.2/src/pikevm.rs:234:13: usage of wildcard import for enum variants -regex-1.3.2/src/pikevm.rs:303:13: usage of wildcard import for enum variants -regex-1.3.2/src/pikevm.rs:331:29: this expression mutably borrows a mutable reference. Consider reborrowing -regex-1.3.2/src/pikevm.rs:88:5: this function has too many arguments (8/7) -regex-1.3.2/src/prog.rs:102:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/prog.rs:113:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/prog.rs:120:9: match expression looks like `matches!` macro -regex-1.3.2/src/prog.rs:128:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/prog.rs:134:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/prog.rs:141:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/prog.rs:147:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/prog.rs:164:41: you have declared `#[inline(always)]` on `deref`. This is usually a bad idea -regex-1.3.2/src/prog.rs:172:13: usage of wildcard import for enum variants -regex-1.3.2/src/prog.rs:18:1: more than 3 bools in a struct -regex-1.3.2/src/prog.rs:236:13: using `write!()` with a format string that ends in a single newline -regex-1.3.2/src/prog.rs:300:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/prog.rs:301:9: match expression looks like `matches!` macro -regex-1.3.2/src/prog.rs:382:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/prog.rs:409:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/prog.rs:80:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/prog.rs:80:5: you should consider adding a `Default` implementation for `prog::Program` -regex-1.3.2/src/re_builder.rs:267:17: docs for function returning `Result` missing `# Errors` section -regex-1.3.2/src/re_builder.rs:267:17: docs for function returning `Result` missing `# Errors` section -regex-1.3.2/src/re_builder.rs:4:1: more than 3 bools in a struct -regex-1.3.2/src/re_builder.rs:57:17: this method could have a `#[must_use]` attribute -regex-1.3.2/src/re_builder.rs:57:17: this method could have a `#[must_use]` attribute -regex-1.3.2/src/re_builder.rs:68:17: docs for function returning `Result` missing `# Errors` section -regex-1.3.2/src/re_builder.rs:68:17: docs for function returning `Result` missing `# Errors` section -regex-1.3.2/src/re_bytes.rs:1017:9: called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead -regex-1.3.2/src/re_bytes.rs:1039:9: called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead -regex-1.3.2/src/re_bytes.rs:1093:5: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) -regex-1.3.2/src/re_bytes.rs:1118:5: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) -regex-1.3.2/src/re_bytes.rs:1133:5: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) -regex-1.3.2/src/re_bytes.rs:118:5: docs for function returning `Result` missing `# Errors` section -regex-1.3.2/src/re_bytes.rs:256:13: redundant field names in struct initialization -regex-1.3.2/src/re_bytes.rs:29:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/re_bytes.rs:35:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/re_bytes.rs:42:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/re_bytes.rs:48:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/re_bytes.rs:558:29: you should put `shortest_match` between ticks in the documentation -regex-1.3.2/src/re_bytes.rs:55:33: redundant field names in struct initialization -regex-1.3.2/src/re_bytes.rs:55:47: redundant field names in struct initialization -regex-1.3.2/src/re_bytes.rs:572:29: you should put `is_match` between ticks in the documentation -regex-1.3.2/src/re_bytes.rs:720:13: redundant field names in struct initialization -regex-1.3.2/src/re_bytes.rs:817:5: you should put `CaptureLocations` between ticks in the documentation -regex-1.3.2/src/re_bytes.rs:843:1: item `re_bytes::CaptureLocations` has a public `len` method but no corresponding `is_empty` method -regex-1.3.2/src/re_bytes.rs:849:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/re_bytes.rs:858:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/re_bytes.rs:869:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/re_bytes.rs:891:1: item `re_bytes::Captures<'t>` has a public `len` method but no corresponding `is_empty` method -regex-1.3.2/src/re_bytes.rs:911:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/re_bytes.rs:917:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/re_bytes.rs:926:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/re_bytes.rs:955:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/re_set.rs:179:13: redundant field names in struct initialization -regex-1.3.2/src/re_set.rs:179:13: redundant field names in struct initialization -regex-1.3.2/src/re_set.rs:251:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/re_set.rs:251:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/re_set.rs:263:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/re_set.rs:263:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/re_set.rs:268:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/re_set.rs:268:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/re_set.rs:277:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/re_set.rs:277:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/re_set.rs:94:5: docs for function returning `Result` missing `# Errors` section -regex-1.3.2/src/re_set.rs:94:5: docs for function returning `Result` missing `# Errors` section -regex-1.3.2/src/re_trait.rs:136:29: redundant field names in struct initialization -regex-1.3.2/src/re_unicode.rs:1019:9: called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead -regex-1.3.2/src/re_unicode.rs:1041:9: called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead -regex-1.3.2/src/re_unicode.rs:1088:13: redundant field names in struct initialization -regex-1.3.2/src/re_unicode.rs:1135:5: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) -regex-1.3.2/src/re_unicode.rs:1160:5: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) -regex-1.3.2/src/re_unicode.rs:174:5: docs for function returning `Result` missing `# Errors` section -regex-1.3.2/src/re_unicode.rs:21:1: this function could have a `#[must_use]` attribute -regex-1.3.2/src/re_unicode.rs:313:13: redundant field names in struct initialization -regex-1.3.2/src/re_unicode.rs:38:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/re_unicode.rs:44:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/re_unicode.rs:51:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/re_unicode.rs:57:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/re_unicode.rs:617:29: you should put `shortest_match` between ticks in the documentation -regex-1.3.2/src/re_unicode.rs:631:29: you should put `is_match` between ticks in the documentation -regex-1.3.2/src/re_unicode.rs:64:33: redundant field names in struct initialization -regex-1.3.2/src/re_unicode.rs:64:47: redundant field names in struct initialization -regex-1.3.2/src/re_unicode.rs:834:5: you should put `CaptureLocations` between ticks in the documentation -regex-1.3.2/src/re_unicode.rs:860:1: item `re_unicode::CaptureLocations` has a public `len` method but no corresponding `is_empty` method -regex-1.3.2/src/re_unicode.rs:866:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/re_unicode.rs:875:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/re_unicode.rs:886:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/re_unicode.rs:908:1: item `re_unicode::Captures<'t>` has a public `len` method but no corresponding `is_empty` method -regex-1.3.2/src/re_unicode.rs:928:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/re_unicode.rs:934:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/re_unicode.rs:943:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/re_unicode.rs:972:5: this method could have a `#[must_use]` attribute -regex-1.3.2/src/sparse.rs:10:37: you should put bare URLs between `<`/`>` or make a proper Markdown link -regex-1.3.2/src/sparse.rs:15:1: item name starts with its containing module's name -regex-1.3.2/src/utf8.rs:100:16: digits of hex or binary literal not grouped by four -regex-1.3.2/src/utf8.rs:103:16: digits of hex or binary literal not grouped by four -regex-1.3.2/src/utf8.rs:106:22: casting `u8` to `u32` may become silently lossy if you later change the type -regex-1.3.2/src/utf8.rs:107:19: casting `u8` to `u32` may become silently lossy if you later change the type -regex-1.3.2/src/utf8.rs:108:19: casting `u8` to `u32` may become silently lossy if you later change the type -regex-1.3.2/src/utf8.rs:109:19: casting `u8` to `u32` may become silently lossy if you later change the type -regex-1.3.2/src/utf8.rs:111:27: long literal lacking separators -regex-1.3.2/src/utf8.rs:121:1: item name ends with its containing module's name -regex-1.3.2/src/utf8.rs:143:24: digits of hex or binary literal not grouped by four -regex-1.3.2/src/utf8.rs:143:9: digits of hex or binary literal not grouped by four -regex-1.3.2/src/utf8.rs:23:1: item name ends with its containing module's name -regex-1.3.2/src/utf8.rs:30:20: digits of hex or binary literal not grouped by four -regex-1.3.2/src/utf8.rs:51:1: item name ends with its containing module's name -regex-1.3.2/src/utf8.rs:58:23: digits of hex or binary literal not grouped by four -regex-1.3.2/src/utf8.rs:58:9: digits of hex or binary literal not grouped by four -regex-1.3.2/src/utf8.rs:63:16: digits of hex or binary literal not grouped by four -regex-1.3.2/src/utf8.rs:66:22: casting `u8` to `u32` may become silently lossy if you later change the type -regex-1.3.2/src/utf8.rs:66:54: casting `u8` to `u32` may become silently lossy if you later change the type -regex-1.3.2/src/utf8.rs:77:16: digits of hex or binary literal not grouped by four -regex-1.3.2/src/utf8.rs:80:16: digits of hex or binary literal not grouped by four -regex-1.3.2/src/utf8.rs:83:22: casting `u8` to `u32` may become silently lossy if you later change the type -regex-1.3.2/src/utf8.rs:84:19: casting `u8` to `u32` may become silently lossy if you later change the type -regex-1.3.2/src/utf8.rs:85:19: casting `u8` to `u32` may become silently lossy if you later change the type -regex-1.3.2/src/utf8.rs:92:23: digits of hex or binary literal not grouped by four -regex-1.3.2/src/utf8.rs:92:9: digits of hex or binary literal not grouped by four -regex-1.3.2/src/utf8.rs:97:16: digits of hex or binary literal not grouped by four -ripgrep-12.1.1/build.rs:133:19: called `.as_ref().map(|x| &**x)` on an Option value. This can be done more directly by calling `githash.as_deref()` instead -ripgrep-12.1.1/build.rs:18:18: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -ripgrep-12.1.1/build.rs:225:14: redundant closure found -ripgrep-12.1.1/build.rs:92:19: called `.as_ref().map(|x| &**x)` on an Option value. This can be done more directly by calling `githash.as_deref()` instead -ripgrep-12.1.1/crates/core/app.rs:1408:5: adding items after statements is confusing, since items exist from the start of the scope -ripgrep-12.1.1/crates/core/app.rs:1408:5: adding items after statements is confusing, since items exist from the start of the scope -ripgrep-12.1.1/crates/core/app.rs:1409:5: adding items after statements is confusing, since items exist from the start of the scope -ripgrep-12.1.1/crates/core/app.rs:1409:5: adding items after statements is confusing, since items exist from the start of the scope -ripgrep-12.1.1/crates/core/app.rs:152:32: you should put `clap::Arg` between ticks in the documentation -ripgrep-12.1.1/crates/core/app.rs:152:32: you should put `clap::Arg` between ticks in the documentation -ripgrep-12.1.1/crates/core/app.rs:156:39: you should put `clap::Arg` between ticks in the documentation -ripgrep-12.1.1/crates/core/app.rs:156:39: you should put `clap::Arg` between ticks in the documentation -ripgrep-12.1.1/crates/core/app.rs:156:5: you should put `RGArg` between ticks in the documentation -ripgrep-12.1.1/crates/core/app.rs:156:5: you should put `RGArg` between ticks in the documentation -ripgrep-12.1.1/crates/core/app.rs:1668:5: adding items after statements is confusing, since items exist from the start of the scope -ripgrep-12.1.1/crates/core/app.rs:1668:5: adding items after statements is confusing, since items exist from the start of the scope -ripgrep-12.1.1/crates/core/app.rs:1669:5: adding items after statements is confusing, since items exist from the start of the scope -ripgrep-12.1.1/crates/core/app.rs:1669:5: adding items after statements is confusing, since items exist from the start of the scope -ripgrep-12.1.1/crates/core/app.rs:1821:5: adding items after statements is confusing, since items exist from the start of the scope -ripgrep-12.1.1/crates/core/app.rs:1821:5: adding items after statements is confusing, since items exist from the start of the scope -ripgrep-12.1.1/crates/core/app.rs:1822:5: adding items after statements is confusing, since items exist from the start of the scope -ripgrep-12.1.1/crates/core/app.rs:1822:5: adding items after statements is confusing, since items exist from the start of the scope -ripgrep-12.1.1/crates/core/app.rs:2999:5: adding items after statements is confusing, since items exist from the start of the scope -ripgrep-12.1.1/crates/core/app.rs:2999:5: adding items after statements is confusing, since items exist from the start of the scope -ripgrep-12.1.1/crates/core/app.rs:3000:5: adding items after statements is confusing, since items exist from the start of the scope -ripgrep-12.1.1/crates/core/app.rs:3000:5: adding items after statements is confusing, since items exist from the start of the scope -ripgrep-12.1.1/crates/core/app.rs:367:54: this `match` has identical arm bodies -ripgrep-12.1.1/crates/core/app.rs:367:54: this `match` has identical arm bodies -ripgrep-12.1.1/crates/core/app.rs:414:59: this `match` has identical arm bodies -ripgrep-12.1.1/crates/core/app.rs:414:59: this `match` has identical arm bodies -ripgrep-12.1.1/crates/core/app.rs:417:57: this `match` has identical arm bodies -ripgrep-12.1.1/crates/core/app.rs:417:57: this `match` has identical arm bodies -ripgrep-12.1.1/crates/core/app.rs:417:57: this `match` has identical arm bodies -ripgrep-12.1.1/crates/core/app.rs:417:57: this `match` has identical arm bodies -ripgrep-12.1.1/crates/core/app.rs:444:41: this `match` has identical arm bodies -ripgrep-12.1.1/crates/core/app.rs:444:41: this `match` has identical arm bodies -ripgrep-12.1.1/crates/core/app.rs:470:41: this `match` has identical arm bodies -ripgrep-12.1.1/crates/core/app.rs:470:41: this `match` has identical arm bodies -ripgrep-12.1.1/crates/core/app.rs:75:9: you should put `RIPGREP_BUILD_GIT_HASH` between ticks in the documentation -ripgrep-12.1.1/crates/core/app.rs:75:9: you should put `RIPGREP_BUILD_GIT_HASH` between ticks in the documentation -ripgrep-12.1.1/crates/core/app.rs:87:5: unnecessary boolean `not` operation -ripgrep-12.1.1/crates/core/app.rs:87:5: unnecessary boolean `not` operation -ripgrep-12.1.1/crates/core/args.rs:1143:22: unused `self` argument -ripgrep-12.1.1/crates/core/args.rs:11:1: this import is redundant -ripgrep-12.1.1/crates/core/args.rs:1209:74: this `if` has identical blocks -ripgrep-12.1.1/crates/core/args.rs:1209:74: this `if` has identical blocks -ripgrep-12.1.1/crates/core/args.rs:1282:13: binding's name is too similar to existing binding -ripgrep-12.1.1/crates/core/args.rs:1430:22: unused `self` argument -ripgrep-12.1.1/crates/core/args.rs:1438:21: you should put `OsStr` between ticks in the documentation -ripgrep-12.1.1/crates/core/args.rs:1520:44: redundant closure found -ripgrep-12.1.1/crates/core/args.rs:1524:5: this function's return value is unnecessarily wrapped by `Result` -ripgrep-12.1.1/crates/core/args.rs:1635:14: you should put `values_of_lossy` between ticks in the documentation -ripgrep-12.1.1/crates/core/args.rs:1693:41: redundant closure found -ripgrep-12.1.1/crates/core/args.rs:1770:17: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers -ripgrep-12.1.1/crates/core/args.rs:287:13: binding's name is too similar to existing binding -ripgrep-12.1.1/crates/core/args.rs:33:1: this import is redundant -ripgrep-12.1.1/crates/core/args.rs:34:1: this import is redundant -ripgrep-12.1.1/crates/core/args.rs:35:1: this import is redundant -ripgrep-12.1.1/crates/core/args.rs:410:14: this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -ripgrep-12.1.1/crates/core/args.rs:475:18: this `match` has identical arm bodies -ripgrep-12.1.1/crates/core/args.rs:512:19: you should put `ArgMatches` between ticks in the documentation -ripgrep-12.1.1/crates/core/args.rs:549:16: methods called `to_*` usually take self by reference; consider choosing a less ambiguous name -ripgrep-12.1.1/crates/core/args.rs:76:18: this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -ripgrep-12.1.1/crates/core/args.rs:77:13: usage of wildcard import for enum variants -ripgrep-12.1.1/crates/core/args.rs:923:42: you should put `BinaryDetection::quit` between ticks in the documentation -ripgrep-12.1.1/crates/core/config.rs:13:1: this import is redundant -ripgrep-12.1.1/crates/core/config.rs:58:6: very complex type used. Consider factoring parts into `type` definitions -ripgrep-12.1.1/crates/core/config.rs:79:6: very complex type used. Consider factoring parts into `type` definitions -ripgrep-12.1.1/crates/core/logger.rs:11:30: you should put `max_level` between ticks in the documentation -ripgrep-12.1.1/crates/core/logger.rs:15:16: constants have by default a `'static` lifetime -ripgrep-12.1.1/crates/core/main.rs:55:19: this argument is passed by value, but not consumed in the function body -ripgrep-12.1.1/crates/core/main.rs:56:9: usage of wildcard import for enum variants -ripgrep-12.1.1/crates/core/messages.rs:46:1: item name ends with its containing module's name -ripgrep-12.1.1/crates/core/messages.rs:51:1: item name ends with its containing module's name -ripgrep-12.1.1/crates/core/messages.rs:62:1: item name ends with its containing module's name -ripgrep-12.1.1/crates/core/path_printer.rs:27:1: item name starts with its containing module's name -ripgrep-12.1.1/crates/core/path_printer.rs:89:9: unnecessary boolean `not` operation -ripgrep-12.1.1/crates/core/search.rs:185:1: item name starts with its containing module's name -ripgrep-12.1.1/crates/core/search.rs:292:9: using `write!()` with a format string that ends in a single newline -ripgrep-12.1.1/crates/core/search.rs:311:1: item name starts with its containing module's name -ripgrep-12.1.1/crates/core/search.rs:377:12: this boolean expression can be simplified -ripgrep-12.1.1/crates/core/search.rs:423:13: usage of wildcard import for enum variants -ripgrep-12.1.1/crates/core/search.rs:447:13: usage of wildcard import for enum variants -ripgrep-12.1.1/crates/core/search.rs:472:24: you are using an explicit closure for cloning elements -ripgrep-12.1.1/crates/core/search.rs:472:41: redundant closure found -ripgrep-12.1.1/crates/core/search.rs:480:24: you are using an explicit closure for cloning elements -ripgrep-12.1.1/crates/core/search.rs:480:41: redundant closure found -ripgrep-12.1.1/crates/core/search.rs:49:1: item name starts with its containing module's name -ripgrep-12.1.1/crates/core/search.rs:509:24: you are using an explicit closure for cloning elements -ripgrep-12.1.1/crates/core/search.rs:509:41: redundant closure found -ripgrep-12.1.1/crates/core/search.rs:517:24: you are using an explicit closure for cloning elements -ripgrep-12.1.1/crates/core/search.rs:517:41: redundant closure found -ripgrep-12.1.1/crates/core/search.rs:533:36: casting `u32` to `f64` may become silently lossy if you later change the type -ripgrep-12.1.1/crates/core/search.rs:533:5: casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -ripgrep-12.1.1/crates/core/subject.rs:20:1: item name starts with its containing module's name -ripgrep-12.1.1/crates/core/subject.rs:4:1: this import is redundant -syn-1.0.54/src/lit.rs:1397:40: redundant else block -syn-1.0.54/src/lit.rs:1405:28: redundant else block -syn-1.0.54/src/lit.rs:1485:32: redundant else block -unicode-xid-0.2.1/src/lib.rs:57:64: you should put `XID_Start` between ticks in the documentation -unicode-xid-0.2.1/src/lib.rs:60:10: you should put `XID_Start` between ticks in the documentation -unicode-xid-0.2.1/src/lib.rs:62:27: you should put `ID_Start` between ticks in the documentation -unicode-xid-0.2.1/src/lib.rs:62:67: you should put `NFKx` between ticks in the documentation -unicode-xid-0.2.1/src/lib.rs:63:21: methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name -unicode-xid-0.2.1/src/lib.rs:65:61: you should put `XID_Continue` between ticks in the documentation -unicode-xid-0.2.1/src/lib.rs:68:10: you should put `XID_Continue` between ticks in the documentation -unicode-xid-0.2.1/src/lib.rs:70:28: you should put `ID_Continue` between ticks in the documentation -unicode-xid-0.2.1/src/lib.rs:70:72: you should put `NFKx` between ticks in the documentation -unicode-xid-0.2.1/src/lib.rs:71:24: methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name -xsv-0.13.0/src/cmd/cat.rs:101:34: redundant closure found -xsv-0.13.0/src/cmd/cat.rs:42:1: more than 3 bools in a struct -xsv-0.13.0/src/cmd/cat.rs:53:9: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/cat.rs:7:16: statics have by default a `'static` lifetime -xsv-0.13.0/src/cmd/count.rs:32:9: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/count.rs:38:9: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -xsv-0.13.0/src/cmd/count.rs:42:33: integer type suffix should be separated by an underscore -xsv-0.13.0/src/cmd/count.rs:50:5: passing a unit value to a function -xsv-0.13.0/src/cmd/count.rs:7:16: statics have by default a `'static` lifetime -xsv-0.13.0/src/cmd/fixlengths.rs:45:9: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/fixlengths.rs:50:18: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -xsv-0.13.0/src/cmd/fixlengths.rs:62:30: integer type suffix should be separated by an underscore -xsv-0.13.0/src/cmd/fixlengths.rs:9:16: statics have by default a `'static` lifetime -xsv-0.13.0/src/cmd/flatten.rs:10:16: statics have by default a `'static` lifetime -xsv-0.13.0/src/cmd/flatten.rs:51:9: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/fmt.rs:50:9: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/fmt.rs:55:13: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/fmt.rs:7:16: statics have by default a `'static` lifetime -xsv-0.13.0/src/cmd/frequency.rs:148:43: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers -xsv-0.13.0/src/cmd/frequency.rs:149:43: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers -xsv-0.13.0/src/cmd/frequency.rs:15:16: statics have by default a `'static` lifetime -xsv-0.13.0/src/cmd/frequency.rs:169:13: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/frequency.rs:176:17: unnecessary boolean `not` operation -xsv-0.13.0/src/cmd/frequency.rs:178:24: this `else { if .. }` block can be collapsed -xsv-0.13.0/src/cmd/frequency.rs:77:9: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/frequency.rs:93:31: it is more concise to loop over containers instead of using explicit iteration methods -xsv-0.13.0/src/cmd/headers.rs:43:9: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/headers.rs:49:17: it is more concise to loop over containers instead of using explicit iteration methods -xsv-0.13.0/src/cmd/headers.rs:60:22: trait objects without an explicit `dyn` are deprecated -xsv-0.13.0/src/cmd/headers.rs:9:16: statics have by default a `'static` lifetime -xsv-0.13.0/src/cmd/index.rs:11:16: statics have by default a `'static` lifetime -xsv-0.13.0/src/cmd/index.rs:45:9: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/input.rs:42:9: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/input.rs:47:9: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/input.rs:7:16: statics have by default a `'static` lifetime -xsv-0.13.0/src/cmd/join.rs:17:16: statics have by default a `'static` lifetime -xsv-0.13.0/src/cmd/join.rs:194:29: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/join.rs:224:22: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/join.rs:281:44: trait objects without an explicit `dyn` are deprecated -xsv-0.13.0/src/cmd/join.rs:293:14: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/join.rs:293:20: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/join.rs:297:13: redundant field names in struct initialization -xsv-0.13.0/src/cmd/join.rs:298:13: redundant field names in struct initialization -xsv-0.13.0/src/cmd/join.rs:299:13: redundant field names in struct initialization -xsv-0.13.0/src/cmd/join.rs:300:13: redundant field names in struct initialization -xsv-0.13.0/src/cmd/join.rs:308:9: unused `self` argument -xsv-0.13.0/src/cmd/join.rs:342:38: integer type suffix should be separated by an underscore -xsv-0.13.0/src/cmd/join.rs:342:46: integer type suffix should be separated by an underscore -xsv-0.13.0/src/cmd/join.rs:347:9: unnecessary boolean `not` operation -xsv-0.13.0/src/cmd/join.rs:372:44: redundant closure found -xsv-0.13.0/src/cmd/join.rs:375:33: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/join.rs:392:13: redundant field names in struct initialization -xsv-0.13.0/src/cmd/join.rs:403:29: it is more concise to loop over containers instead of using explicit iteration methods -xsv-0.13.0/src/cmd/join.rs:426:13: unnecessary boolean `not` operation -xsv-0.13.0/src/cmd/join.rs:77:1: more than 3 bools in a struct -xsv-0.13.0/src/cmd/join.rs:94:9: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/partition.rs:105:22: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/partition.rs:126:36: trait objects without an explicit `dyn` are deprecated -xsv-0.13.0/src/cmd/partition.rs:139:13: redundant field names in struct initialization -xsv-0.13.0/src/cmd/partition.rs:15:16: statics have by default a `'static` lifetime -xsv-0.13.0/src/cmd/partition.rs:169:9: unnecessary boolean `not` operation -xsv-0.13.0/src/cmd/partition.rs:56:9: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/partition.rs:77:9: unused `self` argument -xsv-0.13.0/src/cmd/sample.rs:105:44: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers -xsv-0.13.0/src/cmd/sample.rs:115:21: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers -xsv-0.13.0/src/cmd/sample.rs:11:16: statics have by default a `'static` lifetime -xsv-0.13.0/src/cmd/sample.rs:51:9: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/sample.rs:58:19: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -xsv-0.13.0/src/cmd/sample.rs:69:9: wildcard match will miss any future added variants -xsv-0.13.0/src/cmd/sample.rs:75:16: it is more concise to loop over containers instead of using explicit iteration methods -xsv-0.13.0/src/cmd/sample.rs:91:42: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers -xsv-0.13.0/src/cmd/sample.rs:92:43: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers -xsv-0.13.0/src/cmd/search.rs:51:9: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/search.rs:9:16: statics have by default a `'static` lifetime -xsv-0.13.0/src/cmd/select.rs:60:9: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/select.rs:8:16: statics have by default a `'static` lifetime -xsv-0.13.0/src/cmd/slice.rs:57:9: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/slice.rs:9:16: statics have by default a `'static` lifetime -xsv-0.13.0/src/cmd/sort.rs:11:16: statics have by default a `'static` lifetime -xsv-0.13.0/src/cmd/sort.rs:138:47: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -xsv-0.13.0/src/cmd/sort.rs:139:51: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -xsv-0.13.0/src/cmd/sort.rs:48:9: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/sort.rs:91:14: it is more concise to loop over containers instead of using explicit iteration methods -xsv-0.13.0/src/cmd/split.rs:131:36: trait objects without an explicit `dyn` are deprecated -xsv-0.13.0/src/cmd/split.rs:14:16: statics have by default a `'static` lifetime -xsv-0.13.0/src/cmd/split.rs:61:9: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/split.rs:94:5: this function's return value is unnecessarily wrapped by `Result` -xsv-0.13.0/src/cmd/split.rs:96:14: this argument is passed by value, but not consumed in the function body -xsv-0.13.0/src/cmd/split.rs:99:13: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers -xsv-0.13.0/src/cmd/stats.rs:110:36: redundant closure found -xsv-0.13.0/src/cmd/stats.rs:127:14: this argument is passed by value, but not consumed in the function body -xsv-0.13.0/src/cmd/stats.rs:138:43: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers -xsv-0.13.0/src/cmd/stats.rs:139:43: casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers -xsv-0.13.0/src/cmd/stats.rs:162:25: it is more concise to loop over containers instead of using explicit iteration methods -xsv-0.13.0/src/cmd/stats.rs:22:16: statics have by default a `'static` lifetime -xsv-0.13.0/src/cmd/stats.rs:231:1: more than 3 bools in a struct -xsv-0.13.0/src/cmd/stats.rs:262:35: calling `cmd::stats::TypedSum::default()` is more clear than this expression -xsv-0.13.0/src/cmd/stats.rs:263:40: calling `cmd::stats::TypedMinMax::default()` is more clear than this expression -xsv-0.13.0/src/cmd/stats.rs:264:39: calling `stats::OnlineStats::default()` is more clear than this expression -xsv-0.13.0/src/cmd/stats.rs:265:58: calling `stats::Unsorted::default()` is more clear than this expression -xsv-0.13.0/src/cmd/stats.rs:266:41: calling `stats::Unsorted::default()` is more clear than this expression -xsv-0.13.0/src/cmd/stats.rs:268:18: calling `cmd::stats::FieldType::default()` is more clear than this expression -xsv-0.13.0/src/cmd/stats.rs:269:13: redundant field names in struct initialization -xsv-0.13.0/src/cmd/stats.rs:270:13: redundant field names in struct initialization -xsv-0.13.0/src/cmd/stats.rs:271:13: redundant field names in struct initialization -xsv-0.13.0/src/cmd/stats.rs:272:13: redundant field names in struct initialization -xsv-0.13.0/src/cmd/stats.rs:273:13: redundant field names in struct initialization -xsv-0.13.0/src/cmd/stats.rs:274:13: redundant field names in struct initialization -xsv-0.13.0/src/cmd/stats.rs:283:9: called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()` -xsv-0.13.0/src/cmd/stats.rs:284:9: called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()` -xsv-0.13.0/src/cmd/stats.rs:285:9: called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()` -xsv-0.13.0/src/cmd/stats.rs:290:21: called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()` -xsv-0.13.0/src/cmd/stats.rs:293:25: this `match` has identical arm bodies -xsv-0.13.0/src/cmd/stats.rs:297:25: called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()` -xsv-0.13.0/src/cmd/stats.rs:301:21: called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()` -xsv-0.13.0/src/cmd/stats.rs:302:21: called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()` -xsv-0.13.0/src/cmd/stats.rs:308:18: methods called `to_*` usually take self by reference; consider choosing a less ambiguous name -xsv-0.13.0/src/cmd/stats.rs:318:9: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -xsv-0.13.0/src/cmd/stats.rs:322:45: redundant closure found -xsv-0.13.0/src/cmd/stats.rs:322:9: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -xsv-0.13.0/src/cmd/stats.rs:327:9: unnecessary boolean `not` operation -xsv-0.13.0/src/cmd/stats.rs:330:13: you seem to be trying to use match for destructuring a single pattern. Consider using `if let` -xsv-0.13.0/src/cmd/stats.rs:338:45: redundant closure found -xsv-0.13.0/src/cmd/stats.rs:402:16: redundant pattern matching, consider using `is_ok()` -xsv-0.13.0/src/cmd/stats.rs:403:16: redundant pattern matching, consider using `is_ok()` -xsv-0.13.0/src/cmd/stats.rs:407:18: this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -xsv-0.13.0/src/cmd/stats.rs:411:16: this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -xsv-0.13.0/src/cmd/stats.rs:427:56: this `match` has identical arm bodies -xsv-0.13.0/src/cmd/stats.rs:429:56: this `match` has identical arm bodies -xsv-0.13.0/src/cmd/stats.rs:430:60: this `match` has identical arm bodies -xsv-0.13.0/src/cmd/stats.rs:430:60: this `match` has identical arm bodies -xsv-0.13.0/src/cmd/stats.rs:454:5: you should put `TypedSum` between ticks in the documentation -xsv-0.13.0/src/cmd/stats.rs:473:43: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -xsv-0.13.0/src/cmd/stats.rs:504:56: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -xsv-0.13.0/src/cmd/stats.rs:505:51: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -xsv-0.13.0/src/cmd/stats.rs:511:5: you should put `TypedMinMax` between ticks in the documentation -xsv-0.13.0/src/cmd/stats.rs:536:35: casting `f64` to `i64` may truncate the value -xsv-0.13.0/src/cmd/stats.rs:544:33: casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) -xsv-0.13.0/src/cmd/stats.rs:592:22: calling `stats::MinMax::default()` is more clear than this expression -xsv-0.13.0/src/cmd/stats.rs:593:22: calling `stats::MinMax::default()` is more clear than this expression -xsv-0.13.0/src/cmd/stats.rs:594:23: calling `stats::MinMax::default()` is more clear than this expression -xsv-0.13.0/src/cmd/stats.rs:595:21: calling `stats::MinMax::default()` is more clear than this expression -xsv-0.13.0/src/cmd/stats.rs:71:1: more than 3 bools in a struct -xsv-0.13.0/src/cmd/stats.rs:86:9: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/table.rs:10:16: statics have by default a `'static` lifetime -xsv-0.13.0/src/cmd/table.rs:50:9: binding's name is too similar to existing binding -xsv-0.13.0/src/cmd/table.rs:54:9: binding's name is too similar to existing binding -xsv-0.13.0/src/config.rs:113:43: use of `unwrap_or` followed by a function call -xsv-0.13.0/src/config.rs:197:48: trait objects without an explicit `dyn` are deprecated -xsv-0.13.0/src/config.rs:202:48: trait objects without an explicit `dyn` are deprecated -xsv-0.13.0/src/config.rs:263:47: trait objects without an explicit `dyn` are deprecated -xsv-0.13.0/src/config.rs:293:47: trait objects without an explicit `dyn` are deprecated -xsv-0.13.0/src/config.rs:58:1: more than 3 bools in a struct -xsv-0.13.0/src/config.rs:77:28: explicit deref method call -xsv-0.13.0/src/config.rs:90:13: redundant field names in struct initialization -xsv-0.13.0/src/index.rs:31:13: redundant field names in struct initialization -xsv-0.13.0/src/main.rs:164:49: redundant clone -xsv-0.13.0/src/main.rs:75:16: statics have by default a `'static` lifetime -xsv-0.13.0/src/select.rs:13:1: item name starts with its containing module's name -xsv-0.13.0/src/select.rs:154:5: this function's return value is unnecessarily wrapped by `Result` -xsv-0.13.0/src/select.rs:250:33: binding's name is too similar to existing binding -xsv-0.13.0/src/select.rs:250:43: binding's name is too similar to existing binding -xsv-0.13.0/src/select.rs:255:39: an inclusive range would be more readable -xsv-0.13.0/src/select.rs:280:20: length comparison to zero -xsv-0.13.0/src/select.rs:29:13: redundant field names in struct initialization -xsv-0.13.0/src/select.rs:360:62: this argument (8 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte) -xsv-0.13.0/src/select.rs:360:9: this function's return value is unnecessarily wrapped by `Option` -xsv-0.13.0/src/select.rs:375:9: used sort instead of sort_unstable to sort primitive type `usize` -xsv-0.13.0/src/select.rs:379:18: it is more concise to loop over containers instead of using explicit iteration methods -xsv-0.13.0/src/select.rs:416:5: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) -xsv-0.13.0/src/select.rs:419:9: this function's return value is unnecessarily wrapped by `Option` -xsv-0.13.0/src/select.rs:420:27: consider using `Option` instead of `Option>` or a custom enum if you need to distinguish all 3 cases -xsv-0.13.0/src/select.rs:99:17: binding's name is too similar to existing binding -xsv-0.13.0/src/util.rs:150:5: you should put bare URLs between `<`/`>` or make a proper Markdown link -xsv-0.13.0/src/util.rs:190:48: trait objects without an explicit `dyn` are deprecated -xsv-0.13.0/src/util.rs:37:33: you are using an explicit closure for copying elements -xsv-0.13.0/src/util.rs:90:1: explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration) +cargo/0.49.0//home/matthias/.rustup/toolchains/nightly-2020-12-20-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/core/src/macros/mod.rs:393:34 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/build.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.categories` metadata" +cargo/0.49.0/build.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.keywords` metadata" +cargo/0.49.0/src/bin/cargo/cli.rs:104:34 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/bin/cargo/cli.rs:121:5 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo/0.49.0/src/bin/cargo/cli.rs:157:30 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/cli.rs:184:41 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +cargo/0.49.0/src/bin/cargo/cli.rs:196:42 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/cli.rs:200:39 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/cli.rs:231:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo/0.49.0/src/bin/cargo/cli.rs:245:22 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +cargo/0.49.0/src/bin/cargo/cli.rs:247:47 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/cli.rs:257:22 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/cli.rs:26:20 clippy::redundant_else "redundant else block" +cargo/0.49.0/src/bin/cargo/cli.rs:7:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/bench.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/bench.rs:76:59 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/commands/build.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/check.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/clean.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/doc.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/fetch.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/fix.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/generate_lockfile.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/git_checkout.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/help.rs:20:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/bin/cargo/commands/init.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/install.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/install.rs:97:16 clippy::option_if_let_else "use Option::map_or instead of an if let/else" +cargo/0.49.0/src/bin/cargo/commands/locate_project.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/login.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/metadata.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/mod.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/new.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/new.rs:20:24 clippy::option_if_let_else "use Option::map_or instead of an if let/else" +cargo/0.49.0/src/bin/cargo/commands/owner.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/owner.rs:38:43 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/commands/owner.rs:39:43 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/commands/owner.rs:40:43 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/commands/owner.rs:43:30 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/commands/owner.rs:46:30 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/commands/package.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/pkgid.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/publish.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/publish.rs:40:47 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/commands/read_manifest.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/run.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/rustc.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/rustdoc.rs:3:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/search.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/test.rs:127:54 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/commands/test.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/tree.rs:149:49 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/commands/tree.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/uninstall.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/update.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/vendor.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/vendor.rs:96:16 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +cargo/0.49.0/src/bin/cargo/commands/verify_project.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/version.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/yank.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/yank.rs:32:36 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/commands/yank.rs:33:35 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/commands/yank.rs:34:36 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/commands/yank.rs:35:36 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/main.rs:100:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +cargo/0.49.0/src/bin/cargo/main.rs:118:41 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/main.rs:137:43 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/main.rs:148:19 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/bin/cargo/main.rs:174:57 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/main.rs:18:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/main.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.categories` metadata" +cargo/0.49.0/src/bin/cargo/main.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.keywords` metadata" +cargo/0.49.0/src/bin/cargo/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `crossbeam-utils`: 0.6.6, 0.7.2" +cargo/0.49.0/src/bin/cargo/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `hex`: 0.3.2, 0.4.0" +cargo/0.49.0/src/bin/cargo/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `humantime`: 1.3.0, 2.0.0" +cargo/0.49.0/src/bin/cargo/main.rs:72:22 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/main.rs:94:13 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +cargo/0.49.0/src/bin/cargo/main.rs:96:41 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/main.rs:98:60 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/compiler/build_config.rs:155:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +cargo/0.49.0/src/cargo/core/compiler/build_config.rs:170:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/build_config.rs:175:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/build_config.rs:180:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/build_config.rs:186:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/build_config.rs:197:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/build_config.rs:205:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/build_config.rs:51:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/build_config.rs:69:48 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +cargo/0.49.0/src/cargo/core/compiler/build_config.rs:96:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/build_context/mod.rs:44:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/build_context/mod.rs:83:20 clippy::doc_markdown "you should put `x86_64` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:108:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:121:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:149:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:420:69 clippy::doc_markdown "you should put `mode/target_kind` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:423:19 clippy::doc_markdown "you should put `CrateTypes` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:424:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:469:58 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:591:20 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:603:19 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:665:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:82:31 clippy::doc_markdown "you should put `FileType` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:83:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:84:9 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:96:31 clippy::doc_markdown "you should put `FileType` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:98:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/build_plan.rs:4:9 clippy::doc_markdown "you should put `BuildPlan` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/build_plan.rs:5:66 clippy::doc_markdown "you should put `BuildPlan` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/compilation.rs:150:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/compilation.rs:169:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/compilation.rs:185:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/compilation.rs:193:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/compilation.rs:194:49 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/compiler/compilation.rs:198:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/compilation.rs:314:16 clippy::doc_markdown "you should put `rustc_tool` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/compilation.rs:91:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/compile_kind.rs:118:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/compile_kind.rs:147:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/compile_kind.rs:157:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/compile_kind.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/compile_kind.rs:33:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/compile_kind.rs:49:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/context/compilation_files.rs:204:9 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/core/compiler/context/compilation_files.rs:277:22 clippy::doc_markdown "you should put `OUT_DIR` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/context/compilation_files.rs:324:66 clippy::doc_markdown "you should put `FileType` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/context/compilation_files.rs:393:37 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/compiler/context/compilation_files.rs:426:71 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:125:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:125:5 clippy::too_many_lines "this function has too many lines (107/100)" +cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:270:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:286:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:308:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:340:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:349:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:354:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:358:21 clippy::doc_markdown "you should put `RunCustomBuild` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:361:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:365:9 clippy::find_map "called `find(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:374:43 clippy::doc_markdown "you should put `RunCustomBuild` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:378:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:383:41 clippy::doc_markdown "you should put `RunCustomBuild` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:384:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:391:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:397:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:523:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:538:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:542:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:83:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:92:25 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/core/compiler/crate_type.rs:16:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/crate_type.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/crate_type.rs:40:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/crate_type.rs:49:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/crate_type.rs:60:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:150:1 clippy::too_many_lines "this function has too many lines (230/100)" +cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:154:29 clippy::find_map "called `find(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:353:56 clippy::manual_strip "stripping a prefix manually" +cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:448:27 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:464:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:481:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:48:56 clippy::doc_markdown "you should put `RunCustomBuild` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:561:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:567:20 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:576:28 clippy::shadow_unrelated "`mut value` is being shadowed" +cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:606:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:624:13 clippy::find_map "called `find(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:688:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:756:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:762:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:762:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:823:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1021:51 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1252:20 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1278:19 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1656:16 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1664:5 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1787:5 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1795:5 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1882:17 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1894:17 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1906:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1917:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1923:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1956:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1962:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1963:22 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1964:22 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1965:22 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1966:22 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1980:17 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1980:24 clippy::manual_strip "stripping a prefix manually" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1986:17 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:2016:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:61:5 clippy::doc_markdown "you should put `CompileMode` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:63:12 clippy::doc_markdown "you should put `CompileKind` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:67:7 clippy::doc_markdown "you should put `CARGO_DEFAULT_LIB_METADATA[^4` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:68:5 clippy::doc_markdown "you should put `package_id` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:71:19 clippy::doc_markdown "you should put `test/bench/for_host/edition` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:755:52 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:77:5 clippy::doc_markdown "you should put `is_std` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:816:5 clippy::too_many_lines "this function has too many lines (127/100)" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:863:64 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:875:33 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:876:32 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:896:30 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:897:30 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:991:37 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:12:5 clippy::doc_markdown "you should put `src/librustc_jobserver/lib.rs` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:282:30 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:329:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:332:23 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:34:53 clippy::doc_markdown "you should put `NeedsToken` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:35:6 clippy::doc_markdown "you should put `ReleaseToken` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:37:6 clippy::doc_markdown "you should put `NeedsToken` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:40:5 clippy::doc_markdown "you should put `NeedsToken` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:40:56 clippy::doc_markdown "you should put `NeedsToken` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:43:6 clippy::doc_markdown "you should put `ReleaseToken` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:749:13 clippy::if_not_else "unnecessary boolean `not` operation" +cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:786:26 clippy::unused_self "unused `self` argument" +cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:81:61 clippy::doc_markdown "you should put `DrainState` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:865:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:871:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:890:9 clippy::unused_self "unused `self` argument" +cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:93:24 clippy::doc_markdown "you should put `JobQueue` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/links.rs:8:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/core/compiler/mod.rs:1016:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/mod.rs:1094:19 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/compiler/mod.rs:1131:1 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo/0.49.0/src/cargo/core/compiler/mod.rs:1277:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/compiler/mod.rs:179:1 clippy::too_many_lines "this function has too many lines (162/100)" +cargo/0.49.0/src/cargo/core/compiler/mod.rs:198:78 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/compiler/mod.rs:201:25 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/core/compiler/mod.rs:267:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/compiler/mod.rs:324:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/compiler/mod.rs:364:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/compiler/mod.rs:364:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo/0.49.0/src/cargo/core/compiler/mod.rs:392:45 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/compiler/mod.rs:415:23 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/core/compiler/mod.rs:667:15 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/core/compiler/mod.rs:693:1 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo/0.49.0/src/cargo/core/compiler/mod.rs:725:42 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/compiler/mod.rs:736:1 clippy::too_many_lines "this function has too many lines (141/100)" +cargo/0.49.0/src/cargo/core/compiler/mod.rs:73:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/mod.rs:777:12 clippy::if_not_else "unnecessary boolean `not` operation" +cargo/0.49.0/src/cargo/core/compiler/mod.rs:873:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/compiler/output_depinfo.rs:41:13 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +cargo/0.49.0/src/cargo/core/compiler/rustdoc.rs:16:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/core/compiler/rustdoc.rs:57:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/core/compiler/rustdoc.rs:72:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/standard_lib.rs:134:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/standard_lib.rs:16:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/standard_lib.rs:30:28 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/compiler/standard_lib.rs:34:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/timings.rs:16:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo/0.49.0/src/cargo/core/compiler/timings.rs:192:64 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo/0.49.0/src/cargo/core/compiler/timings.rs:212:58 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo/0.49.0/src/cargo/core/compiler/timings.rs:234:13 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" +cargo/0.49.0/src/cargo/core/compiler/timings.rs:355:13 clippy::cast_possible_truncation "casting `f64` to `u32` may truncate the value" +cargo/0.49.0/src/cargo/core/compiler/timings.rs:355:13 clippy::cast_sign_loss "casting `f64` to `u32` may lose the sign of the value" +cargo/0.49.0/src/cargo/core/compiler/timings.rs:397:38 clippy::cast_possible_truncation "casting `f64` to `u32` may truncate the value" +cargo/0.49.0/src/cargo/core/compiler/timings.rs:397:38 clippy::cast_sign_loss "casting `f64` to `u32` may lose the sign of the value" +cargo/0.49.0/src/cargo/core/compiler/timings.rs:484:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/compiler/timings.rs:605:38 clippy::doc_markdown "you should put `rmeta_time` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/timings.rs:605:50 clippy::doc_markdown "you should put `codegen_time` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/timings.rs:641:26 clippy::non_ascii_literal "literal non-ASCII character detected" +cargo/0.49.0/src/cargo/core/compiler/unit.rs:100:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/unit.rs:151:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/core/compiler/unit.rs:161:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/unit.rs:35:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/core/compiler/unit_dependencies.rs:154:29 clippy::doc_markdown "you should put `state.unit_dependencies` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/unit_dependencies.rs:213:1 clippy::too_many_lines "this function has too many lines (110/100)" +cargo/0.49.0/src/cargo/core/compiler/unit_dependencies.rs:329:13 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/core/compiler/unit_dependencies.rs:480:5 clippy::find_map "called `find(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/core/compiler/unit_dependencies.rs:511:5 clippy::find_map "called `find(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/core/compiler/unit_dependencies.rs:52:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/unit_dependencies.rs:52:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/core/compiler/unit_graph.rs:65:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/unit_graph.rs:65:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/core/dependency.rs:157:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/dependency.rs:182:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/dependency.rs:203:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/dependency.rs:224:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/dependency.rs:23:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo/0.49.0/src/cargo/core/dependency.rs:248:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/dependency.rs:270:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/dependency.rs:274:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/dependency.rs:278:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/dependency.rs:287:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/dependency.rs:291:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/dependency.rs:305:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/dependency.rs:311:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/dependency.rs:319:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/dependency.rs:337:75 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/dependency.rs:397:56 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/dependency.rs:403:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/dependency.rs:408:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/dependency.rs:415:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/dependency.rs:419:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/dependency.rs:424:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/dependency.rs:428:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/dependency.rs:433:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/dependency.rs:438:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/dependency.rs:443:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/dependency.rs:449:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/dependency.rs:450:9 clippy::if_not_else "unnecessary `!=` operation" +cargo/0.49.0/src/cargo/core/features.rs:119:17 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/features.rs:229:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/features.rs:274:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/features.rs:278:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/features.rs:306:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/features.rs:338:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo/0.49.0/src/cargo/core/features.rs:362:25 clippy::option_option "consider using `Option` instead of `Option>` or a custom enum if you need to distinguish all 3 cases" +cargo/0.49.0/src/cargo/core/features.rs:380:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/features.rs:401:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/features.rs:409:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/features.rs:412:45 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/features.rs:416:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/features.rs:419:45 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/features.rs:424:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/features.rs:431:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/features.rs:477:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/features.rs:509:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/features.rs:518:5 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +cargo/0.49.0/src/cargo/core/features.rs:542:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/features.rs:543:37 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/features.rs:547:60 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/features.rs:556:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/core/features.rs:563:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/core/manifest.rs:116:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +cargo/0.49.0/src/cargo/core/manifest.rs:118:58 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/manifest.rs:130:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +cargo/0.49.0/src/cargo/core/manifest.rs:143:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:159:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:162:34 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/manifest.rs:169:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:17:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/cargo/core/manifest.rs:189:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo/0.49.0/src/cargo/core/manifest.rs:215:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:222:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:22:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/core/manifest.rs:360:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:407:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:410:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:413:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:416:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:419:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:422:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:425:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:431:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:438:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:444:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:447:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:450:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:453:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:456:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:459:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:462:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:466:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:470:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:477:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:481:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:488:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/manifest.rs:512:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:516:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:520:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:524:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:528:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:538:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:557:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:561:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:565:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:569:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:577:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:581:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:588:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:617:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:632:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:648:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:659:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:66:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/core/manifest.rs:670:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:693:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:708:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:723:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:726:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:729:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:735:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:738:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:741:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:744:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:747:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:751:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:754:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:757:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:760:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:763:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:767:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:776:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:780:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:787:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:798:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:800:56 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/manifest.rs:805:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:809:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:818:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:823:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:828:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:831:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:834:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:839:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:85:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/core/manifest.rs:888:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:936:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package.rs:1075:28 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/package.rs:160:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package.rs:170:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package.rs:174:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package.rs:182:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package.rs:186:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package.rs:190:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package.rs:194:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package.rs:198:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package.rs:202:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package.rs:206:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package.rs:210:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package.rs:217:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package.rs:221:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package.rs:222:35 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/package.rs:226:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package.rs:227:35 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/package.rs:230:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package.rs:239:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/package.rs:249:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package.rs:287:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/core/package.rs:385:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/package.rs:421:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +cargo/0.49.0/src/cargo/core/package.rs:425:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/package.rs:452:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/package.rs:453:60 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/package.rs:459:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/package.rs:473:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/package.rs:587:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/package.rs:682:46 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" +cargo/0.49.0/src/cargo/core/package.rs:682:46 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" +cargo/0.49.0/src/cargo/core/package.rs:682:63 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" +cargo/0.49.0/src/cargo/core/package.rs:682:63 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" +cargo/0.49.0/src/cargo/core/package.rs:731:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/package.rs:790:13 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/core/package.rs:988:9 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/core/package_id.rs:115:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/package_id.rs:124:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package_id.rs:139:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package_id.rs:142:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package_id.rs:145:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package_id.rs:149:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package_id.rs:157:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package_id.rs:161:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package_id.rs:169:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package_id.rs:174:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/core/package_id_spec.rs:101:39 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/package_id_spec.rs:143:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package_id_spec.rs:147:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package_id_spec.rs:151:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package_id_spec.rs:160:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package_id_spec.rs:179:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/package_id_spec.rs:212:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/package_id_spec.rs:231:9 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/core/package_id_spec.rs:51:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/package_id_spec.rs:77:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/package_id_spec.rs:88:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/profiles.rs:1004:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/profiles.rs:1014:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/profiles.rs:1018:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/profiles.rs:1028:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/profiles.rs:106:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/profiles.rs:143:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo/0.49.0/src/cargo/core/profiles.rs:286:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/profiles.rs:294:40 clippy::if_not_else "unnecessary boolean `not` operation" +cargo/0.49.0/src/cargo/core/profiles.rs:30:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/profiles.rs:342:25 clippy::shadow_unrelated "`maker` is being shadowed" +cargo/0.49.0/src/cargo/core/profiles.rs:370:41 clippy::unused_self "unused `self` argument" +cargo/0.49.0/src/cargo/core/profiles.rs:370:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/profiles.rs:372:9 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" +cargo/0.49.0/src/cargo/core/profiles.rs:382:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/profiles.rs:383:28 clippy::if_not_else "unnecessary boolean `not` operation" +cargo/0.49.0/src/cargo/core/profiles.rs:397:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/profiles.rs:405:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/profiles.rs:607:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo/0.49.0/src/cargo/core/profiles.rs:909:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/profiles.rs:923:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/profiles.rs:934:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/profiles.rs:987:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/registry.rs:111:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/registry.rs:127:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/registry.rs:168:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/registry.rs:19:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/registry.rs:240:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/registry.rs:26:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/registry.rs:344:49 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/registry.rs:369:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/registry.rs:424:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/registry.rs:49:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/core/registry.rs:520:17 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/core/registry.rs:763:53 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/registry.rs:765:53 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/registry.rs:807:14 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/registry.rs:814:53 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/resolver/conflict_cache.rs:197:29 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/resolver/conflict_cache.rs:41:38 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +cargo/0.49.0/src/cargo/core/resolver/context.rs:274:53 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/resolver/context.rs:297:9 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/core/resolver/context.rs:42:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/core/resolver/context.rs:74:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/encode.rs:156:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/resolver/encode.rs:156:5 clippy::too_many_lines "this function has too many lines (164/100)" +cargo/0.49.0/src/cargo/core/resolver/encode.rs:339:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +cargo/0.49.0/src/cargo/core/resolver/encode.rs:438:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/resolver/encode.rs:449:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/resolver/encode.rs:529:34 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/resolver/encode.rs:602:59 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/resolver/encode.rs:623:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/core/resolver/encode.rs:652:27 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/core/resolver/encode.rs:674:51 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/resolver/errors.rs:103:22 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/resolver/errors.rs:104:22 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/resolver/errors.rs:206:9 clippy::if_not_else "unnecessary boolean `not` operation" +cargo/0.49.0/src/cargo/core/resolver/errors.rs:257:45 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/resolver/errors.rs:27:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/errors.rs:305:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo/0.49.0/src/cargo/core/resolver/errors.rs:70:1 clippy::too_many_lines "this function has too many lines (207/100)" +cargo/0.49.0/src/cargo/core/resolver/features.rs:104:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/core/resolver/features.rs:111:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/features.rs:162:56 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/resolver/features.rs:179:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/core/resolver/features.rs:186:23 clippy::doc_markdown "you should put `RequestedFeatures` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/resolver/features.rs:187:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/features.rs:199:23 clippy::doc_markdown "you should put `RequestedFeatures` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/resolver/features.rs:200:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/features.rs:209:9 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/core/resolver/features.rs:221:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/features.rs:231:21 clippy::doc_markdown "you should put `pkg_id/is_build` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/resolver/features.rs:233:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/features.rs:247:58 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/resolver/features.rs:278:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/resolver/features.rs:394:27 clippy::doc_markdown "you should put `FeatureValue` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/resolver/features.rs:460:19 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/core/resolver/features.rs:480:24 clippy::doc_markdown "you should put `FeatureValues` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/resolver/features.rs:496:24 clippy::doc_markdown "you should put `FeatureValues` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/resolver/features.rs:561:28 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/core/resolver/features.rs:58:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/core/resolver/features.rs:67:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo/0.49.0/src/cargo/core/resolver/mod.rs:1017:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/resolver/mod.rs:1045:57 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/resolver/mod.rs:122:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/resolver/mod.rs:142:44 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/resolver/mod.rs:180:1 clippy::too_many_lines "this function has too many lines (225/100)" +cargo/0.49.0/src/cargo/core/resolver/mod.rs:311:17 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/core/resolver/mod.rs:421:52 clippy::filter_map_next "called `filter_map(..).next()` on an `Iterator`. This is more succinctly expressed by calling `.find_map(..)` instead." +cargo/0.49.0/src/cargo/core/resolver/mod.rs:437:33 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/core/resolver/mod.rs:457:69 clippy::filter_map_next "called `filter_map(..).next()` on an `Iterator`. This is more succinctly expressed by calling `.find_map(..)` instead." +cargo/0.49.0/src/cargo/core/resolver/mod.rs:470:37 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/core/resolver/mod.rs:480:37 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/core/resolver/mod.rs:607:11 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo/0.49.0/src/cargo/core/resolver/mod.rs:631:21 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/core/resolver/mod.rs:942:15 clippy::if_not_else "unnecessary boolean `not` operation" +cargo/0.49.0/src/cargo/core/resolver/mod.rs:988:20 clippy::redundant_else "redundant else block" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:120:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:132:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:199:24 clippy::redundant_else "redundant else block" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:235:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:239:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:255:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:259:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:263:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:269:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:273:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:274:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:280:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:284:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:288:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:292:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:296:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:300:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:315:13 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:354:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:362:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:60:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:76:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:90:35 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/core/resolver/types.rs:111:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/resolver/types.rs:121:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/types.rs:141:19 clippy::doc_markdown "you should put `ResolveOpts` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/resolver/types.rs:142:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/types.rs:149:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/types.rs:181:9 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +cargo/0.49.0/src/cargo/core/resolver/types.rs:187:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +cargo/0.49.0/src/cargo/core/resolver/types.rs:261:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +cargo/0.49.0/src/cargo/core/shell.rs:113:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/shell.rs:130:9 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/core/shell.rs:148:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/shell.rs:153:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/shell.rs:163:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/shell.rs:18:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/shell.rs:198:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/shell.rs:206:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/shell.rs:214:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/shell.rs:228:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/shell.rs:239:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/shell.rs:250:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/shell.rs:259:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/shell.rs:267:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/shell.rs:26:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/shell.rs:277:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/shell.rs:282:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/shell.rs:314:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/shell.rs:322:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/shell.rs:330:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/shell.rs:98:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/source/mod.rs:103:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/source/mod.rs:247:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/core/source/mod.rs:261:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/source/mod.rs:268:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/source/mod.rs:273:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/source/mod.rs:291:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/source/mod.rs:302:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/source/mod.rs:307:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/source/mod.rs:31:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/source/mod.rs:37:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/source/mod.rs:39:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/source/mod.rs:47:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/source/mod.rs:50:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/source/mod.rs:52:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/source/mod.rs:63:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/source/mod.rs:74:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/source/mod.rs:83:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/source/source_id.rs:107:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/source/source_id.rs:128:50 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/source/source_id.rs:147:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/source/source_id.rs:156:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/source/source_id.rs:162:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/source/source_id.rs:166:19 clippy::doc_markdown "you should put `SourceId` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/source/source_id.rs:167:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/source/source_id.rs:171:19 clippy::doc_markdown "you should put `SourceId` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/source/source_id.rs:172:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/source/source_id.rs:178:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/source/source_id.rs:187:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/source/source_id.rs:18:74 clippy::default_trait_access "calling `std::sync::Mutex::default()` is more clear than this expression" +cargo/0.49.0/src/cargo/core/source/source_id.rs:195:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/source/source_id.rs:207:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/source/source_id.rs:213:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/source/source_id.rs:217:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/source/source_id.rs:225:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/source/source_id.rs:228:16 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" +cargo/0.49.0/src/cargo/core/source/source_id.rs:236:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/source/source_id.rs:241:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/source/source_id.rs:252:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/source/source_id.rs:257:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/source/source_id.rs:262:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/source/source_id.rs:305:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/source/source_id.rs:310:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/source/source_id.rs:318:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/source/source_id.rs:326:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/source/source_id.rs:355:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/source/source_id.rs:393:61 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:394:42 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:395:42 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:397:71 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:397:71 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:398:47 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:398:47 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:399:47 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:399:47 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:401:63 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:401:63 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:401:63 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:402:43 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:402:43 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:402:43 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:403:43 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:403:43 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:403:43 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:406:21 clippy::enum_glob_use "usage of wildcard import for enum variants" +cargo/0.49.0/src/cargo/core/source/source_id.rs:412:41 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:413:36 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:414:36 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:420:47 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:420:47 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:512:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo/0.49.0/src/cargo/core/source/source_id.rs:513:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo/0.49.0/src/cargo/core/source/source_id.rs:517:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo/0.49.0/src/cargo/core/source/source_id.rs:518:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo/0.49.0/src/cargo/core/source/source_id.rs:525:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo/0.49.0/src/cargo/core/source/source_id.rs:526:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo/0.49.0/src/cargo/core/source/source_id.rs:530:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo/0.49.0/src/cargo/core/source/source_id.rs:531:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo/0.49.0/src/cargo/core/source/source_id.rs:535:33 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo/0.49.0/src/cargo/core/source/source_id.rs:536:37 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo/0.49.0/src/cargo/core/source/source_id.rs:537:42 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo/0.49.0/src/cargo/core/source/source_id.rs:538:38 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo/0.49.0/src/cargo/core/source/source_id.rs:548:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/core/source/source_id.rs:597:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/summary.rs:103:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/summary.rs:123:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/summary.rs:150:1 clippy::too_many_lines "this function has too many lines (141/100)" +cargo/0.49.0/src/cargo/core/summary.rs:158:9 clippy::enum_glob_use "usage of wildcard import for enum variants" +cargo/0.49.0/src/cargo/core/summary.rs:181:21 clippy::if_not_else "unnecessary boolean `not` operation" +cargo/0.49.0/src/cargo/core/summary.rs:192:28 clippy::redundant_else "redundant else block" +cargo/0.49.0/src/cargo/core/summary.rs:258:32 clippy::redundant_else "redundant else block" +cargo/0.49.0/src/cargo/core/summary.rs:281:28 clippy::redundant_else "redundant else block" +cargo/0.49.0/src/cargo/core/summary.rs:303:28 clippy::redundant_else "redundant else block" +cargo/0.49.0/src/cargo/core/summary.rs:321:51 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/summary.rs:344:5 clippy::doc_markdown "you should put `FeatureValue` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/summary.rs:350:85 clippy::doc_markdown "you should put `FeatureValue` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/summary.rs:36:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/summary.rs:378:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/summary.rs:386:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/summary.rs:387:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +cargo/0.49.0/src/cargo/core/summary.rs:407:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +cargo/0.49.0/src/cargo/core/summary.rs:69:34 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/summary.rs:75:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/summary.rs:78:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/summary.rs:81:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/summary.rs:84:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/summary.rs:87:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/summary.rs:90:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/summary.rs:93:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/summary.rs:96:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/summary.rs:99:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/workspace.rs:1019:59 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/core/workspace.rs:1056:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo/0.49.0/src/cargo/core/workspace.rs:113:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/core/workspace.rs:1157:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/workspace.rs:128:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/core/workspace.rs:150:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/workspace.rs:159:16 clippy::redundant_else "redundant else block" +cargo/0.49.0/src/cargo/core/workspace.rs:197:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/workspace.rs:225:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/workspace.rs:255:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/workspace.rs:267:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/workspace.rs:329:37 clippy::doc_markdown "you should put `VirtualManifest` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/workspace.rs:410:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/workspace.rs:440:9 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo/0.49.0/src/cargo/core/workspace.rs:511:32 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/core/workspace.rs:561:25 clippy::non_ascii_literal "literal non-ASCII character detected" +cargo/0.49.0/src/cargo/core/workspace.rs:613:13 clippy::filter_map "called `filter_map(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/core/workspace.rs:615:22 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/workspace.rs:688:35 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/core/workspace.rs:762:27 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/core/workspace.rs:784:17 clippy::if_not_else "unnecessary boolean `not` operation" +cargo/0.49.0/src/cargo/core/workspace.rs:849:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/workspace.rs:893:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/workspace.rs:906:24 clippy::redundant_else "redundant else block" +cargo/0.49.0/src/cargo/core/workspace.rs:932:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/lib.rs:177:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/lib.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.categories` metadata" +cargo/0.49.0/src/cargo/lib.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.keywords` metadata" +cargo/0.49.0/src/cargo/lib.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `crossbeam-utils`: 0.6.6, 0.7.2" +cargo/0.49.0/src/cargo/lib.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `hex`: 0.3.2, 0.4.0" +cargo/0.49.0/src/cargo/lib.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `humantime`: 1.3.0, 2.0.0" +cargo/0.49.0/src/cargo/ops/cargo_clean.rs:205:23 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/ops/cargo_clean.rs:27:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_clean.rs:27:1 clippy::too_many_lines "this function has too many lines (120/100)" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:1078:14 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:109:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:119:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:1227:17 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:127:35 clippy::from_iter_instead_of_collect "usage of `FromIterator::from_iter`" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:128:32 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:173:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:205:36 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:242:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:249:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:258:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:275:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:275:1 clippy::too_many_lines "this function has too many lines (219/100)" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:468:9 clippy::default_trait_access "calling `std::collections::HashMap::default()` is more clear than this expression" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:548:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:556:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:574:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:583:21 clippy::doc_markdown "you should put `CompileFilter` between ticks in the documentation" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:584:5 clippy::fn_params_excessive_bools "more than 3 bools in function parameters" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:584:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:592:9 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:593:9 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:607:13 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:612:21 clippy::doc_markdown "you should put `CompileFilter` between ticks in the documentation" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:613:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:618:9 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:641:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:652:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:655:50 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:673:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:692:49 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:703:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:729:1 clippy::too_many_lines "this function has too many lines (205/100)" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:82:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:874:69 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/ops/cargo_doc.rs:20:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_fetch.rs:15:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_fetch.rs:27:46 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/ops/cargo_fetch.rs:36:20 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:160:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:175:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:22:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:37:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:37:1 clippy::too_many_lines "this function has too many lines (171/100)" +cargo/0.49.0/src/cargo/ops/cargo_install.rs:13:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/cargo/ops/cargo_install.rs:148:1 clippy::fn_params_excessive_bools "more than 3 bools in function parameters" +cargo/0.49.0/src/cargo/ops/cargo_install.rs:148:1 clippy::too_many_lines "this function has too many lines (316/100)" +cargo/0.49.0/src/cargo/ops/cargo_install.rs:202:17 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/ops/cargo_install.rs:312:64 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/ops/cargo_install.rs:318:63 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/ops/cargo_install.rs:32:13 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" +cargo/0.49.0/src/cargo/ops/cargo_install.rs:37:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_install.rs:454:22 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/ops/cargo_install.rs:483:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/ops/cargo_install.rs:683:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_new.rs:101:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_new.rs:245:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/ops/cargo_new.rs:251:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/ops/cargo_new.rs:367:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_new.rs:405:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_new.rs:489:5 clippy::doc_markdown "you should put `IgnoreList` between ticks in the documentation" +cargo/0.49.0/src/cargo/ops/cargo_new.rs:525:47 clippy::doc_markdown "you should put `IgnoreList` between ticks in the documentation" +cargo/0.49.0/src/cargo/ops/cargo_new.rs:525:9 clippy::doc_markdown "you should put `format_existing` between ticks in the documentation" +cargo/0.49.0/src/cargo/ops/cargo_new.rs:572:34 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/ops/cargo_new.rs:623:1 clippy::too_many_lines "this function has too many lines (130/100)" +cargo/0.49.0/src/cargo/ops/cargo_new.rs:781:5 clippy::filter_map_next "called `filter_map(..).next()` on an `Iterator`. This is more succinctly expressed by calling `.find_map(..)` instead." +cargo/0.49.0/src/cargo/ops/cargo_new.rs:800:16 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/ops/cargo_output_metadata.rs:163:36 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/ops/cargo_output_metadata.rs:27:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_output_metadata.rs:45:45 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/ops/cargo_package.rs:144:1 clippy::too_many_lines "this function has too many lines (112/100)" +cargo/0.49.0/src/cargo/ops/cargo_package.rs:207:13 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/ops/cargo_package.rs:25:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo/0.49.0/src/cargo/ops/cargo_package.rs:307:54 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/ops/cargo_package.rs:394:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/ops/cargo_package.rs:418:21 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/ops/cargo_package.rs:425:61 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/ops/cargo_package.rs:459:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/ops/cargo_package.rs:66:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_package.rs:769:29 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/ops/cargo_package.rs:93:20 clippy::if_not_else "unnecessary boolean `not` operation" +cargo/0.49.0/src/cargo/ops/cargo_pkgid.rs:5:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_read_manifest.rs:14:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_read_manifest.rs:171:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/ops/cargo_read_manifest.rs:37:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_read_manifest.rs:57:49 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/ops/cargo_read_manifest.rs:69:37 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/ops/cargo_run.rs:25:24 clippy::if_not_else "unnecessary boolean `not` operation" +cargo/0.49.0/src/cargo/ops/cargo_run.rs:35:9 clippy::if_not_else "unnecessary boolean `not` operation" +cargo/0.49.0/src/cargo/ops/cargo_run.rs:37:16 clippy::redundant_else "redundant else block" +cargo/0.49.0/src/cargo/ops/cargo_run.rs:53:9 clippy::if_not_else "unnecessary boolean `not` operation" +cargo/0.49.0/src/cargo/ops/cargo_run.rs:65:16 clippy::redundant_else "redundant else block" +cargo/0.49.0/src/cargo/ops/cargo_run.rs:9:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_test.rs:16:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_test.rs:43:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_test.rs:84:17 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/ops/cargo_uninstall.rs:14:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_uninstall.rs:7:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:147:9 clippy::doc_markdown "you should put `PackageId` between ticks in the documentation" +cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:233:21 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:244:22 clippy::doc_markdown "you should put `PackageId` between ticks in the documentation" +cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:244:63 clippy::doc_markdown "you should put `PackageId` between ticks in the documentation" +cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:253:17 clippy::if_not_else "unnecessary boolean `not` operation" +cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:370:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:392:9 clippy::find_map "called `find(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:505:8 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:525:10 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:542:27 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:542:5 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:561:20 clippy::redundant_else "redundant else block" +cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:613:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:645:41 clippy::doc_markdown "you should put `BTreeSet` between ticks in the documentation" +cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:654:42 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:662:14 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:674:17 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:681:17 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:92:19 clippy::doc_markdown "you should put `InstallTracker` between ticks in the documentation" +cargo/0.49.0/src/cargo/ops/fix.rs:200:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/fix.rs:200:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/ops/fix.rs:424:20 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +cargo/0.49.0/src/cargo/ops/fix.rs:455:13 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/ops/fix.rs:506:17 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/ops/fix.rs:608:9 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" +cargo/0.49.0/src/cargo/ops/fix.rs:612:42 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/ops/fix.rs:619:48 clippy::manual_strip "stripping a prefix manually" +cargo/0.49.0/src/cargo/ops/fix.rs:66:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/ops/fix.rs:66:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo/0.49.0/src/cargo/ops/fix.rs:708:18 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/ops/fix.rs:77:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/lockfile.rs:154:13 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo/0.49.0/src/cargo/ops/lockfile.rs:217:9 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo/0.49.0/src/cargo/ops/lockfile.rs:30:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/lockfile.rs:35:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/lockfile.rs:35:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/ops/lockfile.rs:87:1 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo/0.49.0/src/cargo/ops/lockfile.rs:8:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/lockfile.rs:8:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/ops/registry.rs:150:21 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/ops/registry.rs:188:1 clippy::too_many_lines "this function has too many lines (130/100)" +cargo/0.49.0/src/cargo/ops/registry.rs:196:16 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/ops/registry.rs:212:32 clippy::if_not_else "unnecessary `!=` operation" +cargo/0.49.0/src/cargo/ops/registry.rs:222:53 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/ops/registry.rs:224:44 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/ops/registry.rs:31:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/ops/registry.rs:346:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/registry.rs:346:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/ops/registry.rs:351:26 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/ops/registry.rs:385:12 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo/0.49.0/src/cargo/ops/registry.rs:386:15 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo/0.49.0/src/cargo/ops/registry.rs:38:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo/0.49.0/src/cargo/ops/registry.rs:477:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/registry.rs:483:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/registry.rs:503:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/registry.rs:505:38 clippy::default_trait_access "calling `util::config::CargoHttpConfig::default()` is more clear than this expression" +cargo/0.49.0/src/cargo/ops/registry.rs:510:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/registry.rs:529:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/ops/registry.rs:53:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/registry.rs:573:22 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/ops/registry.rs:608:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/registry.rs:621:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/registry.rs:671:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/registry.rs:671:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/ops/registry.rs:674:10 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo/0.49.0/src/cargo/ops/registry.rs:678:17 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/ops/registry.rs:730:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/registry.rs:731:16 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/ops/registry.rs:785:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/registry.rs:794:16 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/ops/registry.rs:828:14 clippy::doc_markdown "you should put `SourceId` between ticks in the documentation" +cargo/0.49.0/src/cargo/ops/registry.rs:848:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/resolve.rs:199:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/resolve.rs:199:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/ops/resolve.rs:199:1 clippy::too_many_lines "this function has too many lines (137/100)" +cargo/0.49.0/src/cargo/ops/resolve.rs:241:28 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/ops/resolve.rs:28:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/ops/resolve.rs:384:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/resolve.rs:417:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/resolve.rs:589:9 clippy::shadow_unrelated "`keep` is being shadowed" +cargo/0.49.0/src/cargo/ops/resolve.rs:58:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/resolve.rs:58:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/ops/resolve.rs:602:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/ops/resolve.rs:75:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/resolve.rs:75:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/ops/tree/graph.rs:129:26 clippy::doc_markdown "you should put `PackageIds` between ticks in the documentation" +cargo/0.49.0/src/cargo/ops/tree/graph.rs:131:47 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/ops/tree/graph.rs:152:15 clippy::match_on_vec_items "indexing into a vector may panic" +cargo/0.49.0/src/cargo/ops/tree/graph.rs:173:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/ops/tree/graph.rs:234:46 clippy::filter_map "called `filter(..).flat_map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/ops/tree/graph.rs:328:44 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/ops/tree/graph.rs:330:50 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/ops/tree/graph.rs:563:35 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/ops/tree/mod.rs:112:11 clippy::non_ascii_literal "literal non-ASCII character detected" +cargo/0.49.0/src/cargo/ops/tree/mod.rs:113:10 clippy::non_ascii_literal "literal non-ASCII character detected" +cargo/0.49.0/src/cargo/ops/tree/mod.rs:114:10 clippy::non_ascii_literal "literal non-ASCII character detected" +cargo/0.49.0/src/cargo/ops/tree/mod.rs:115:12 clippy::non_ascii_literal "literal non-ASCII character detected" +cargo/0.49.0/src/cargo/ops/tree/mod.rs:126:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/tree/mod.rs:21:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/ops/tree/mod.rs:21:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo/0.49.0/src/cargo/ops/tree/mod.rs:360:30 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/ops/tree/mod.rs:58:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/ops/vendor.rs:14:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/ops/vendor.rs:21:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/vendor.rs:314:34 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/ops/vendor.rs:324:13 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +cargo/0.49.0/src/cargo/ops/vendor.rs:70:1 clippy::too_many_lines "this function has too many lines (175/100)" +cargo/0.49.0/src/cargo/sources/config.rs:102:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/config.rs:135:67 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/sources/config.rs:206:36 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo/0.49.0/src/cargo/sources/config.rs:282:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/sources/config.rs:70:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/config.rs:81:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/config.rs:97:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/sources/directory.rs:14:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/sources/directory.rs:90:56 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/sources/git/source.rs:14:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/sources/git/source.rs:25:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/git/source.rs:49:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/sources/git/source.rs:53:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/git/source.rs:69:20 clippy::comparison_to_empty "comparison to empty slice" +cargo/0.49.0/src/cargo/sources/git/utils.rs:1025:19 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/sources/git/utils.rs:1158:9 clippy::manual_strip "stripping a suffix manually" +cargo/0.49.0/src/cargo/sources/git/utils.rs:176:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/sources/git/utils.rs:180:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/sources/git/utils.rs:184:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/git/utils.rs:188:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/git/utils.rs:242:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/git/utils.rs:253:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/git/utils.rs:262:13 clippy::if_not_else "unnecessary boolean `not` operation" +cargo/0.49.0/src/cargo/sources/git/utils.rs:289:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/git/utils.rs:294:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/sources/git/utils.rs:298:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/git/utils.rs:308:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/git/utils.rs:472:9 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" +cargo/0.49.0/src/cargo/sources/git/utils.rs:489:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/sources/git/utils.rs:503:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/sources/git/utils.rs:528:28 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/sources/git/utils.rs:537:21 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" +cargo/0.49.0/src/cargo/sources/git/utils.rs:588:1 clippy::too_many_lines "this function has too many lines (135/100)" +cargo/0.49.0/src/cargo/sources/git/utils.rs:758:9 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo/0.49.0/src/cargo/sources/git/utils.rs:858:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/path.rs:129:44 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/sources/path.rs:143:44 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/sources/path.rs:15:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/sources/path.rs:282:50 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/sources/path.rs:313:21 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/sources/path.rs:314:21 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/sources/path.rs:319:21 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/sources/path.rs:339:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/sources/path.rs:339:9 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo/0.49.0/src/cargo/sources/path.rs:380:9 clippy::unused_self "unused `self` argument" +cargo/0.49.0/src/cargo/sources/path.rs:419:50 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/sources/path.rs:429:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/path.rs:460:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/sources/path.rs:473:43 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/sources/path.rs:482:43 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/sources/path.rs:63:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/path.rs:77:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/path.rs:98:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/registry/index.rs:117:23 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo/0.49.0/src/cargo/sources/registry/index.rs:121:70 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo/0.49.0/src/cargo/sources/registry/index.rs:167:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/sources/registry/index.rs:215:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/sources/registry/index.rs:324:23 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/sources/registry/index.rs:393:25 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/sources/registry/index.rs:468:40 clippy::doc_markdown "you should put `SourceId` between ticks in the documentation" +cargo/0.49.0/src/cargo/sources/registry/index.rs:590:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/sources/registry/index.rs:648:17 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/sources/registry/index.rs:736:1 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +cargo/0.49.0/src/cargo/sources/registry/index.rs:95:37 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +cargo/0.49.0/src/cargo/sources/registry/local.rs:12:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/sources/registry/mod.rs:192:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/sources/registry/mod.rs:203:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/sources/registry/mod.rs:229:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/sources/registry/mod.rs:372:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/sources/registry/mod.rs:373:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/registry/mod.rs:375:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/registry/mod.rs:381:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/registry/mod.rs:382:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/registry/mod.rs:383:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/registry/mod.rs:384:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/registry/mod.rs:452:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/registry/mod.rs:582:20 clippy::redundant_else "redundant else block" +cargo/0.49.0/src/cargo/sources/registry/mod.rs:621:9 clippy::if_not_else "unnecessary `!=` operation" +cargo/0.49.0/src/cargo/sources/registry/remote.rs:139:17 clippy::unused_self "unused `self` argument" +cargo/0.49.0/src/cargo/sources/registry/remote.rs:32:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/sources/registry/remote.rs:72:13 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/sources/replaced.rs:12:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/sources/replaced.rs:5:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/util/canonical_url.rs:19:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/canonical_url.rs:65:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/command_prelude.rs:218:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/command_prelude.rs:222:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/command_prelude.rs:234:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/command_prelude.rs:249:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/command_prelude.rs:264:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/command_prelude.rs:279:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/command_prelude.rs:298:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/command_prelude.rs:320:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/command_prelude.rs:328:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/command_prelude.rs:352:13 clippy::if_not_else "unnecessary boolean `not` operation" +cargo/0.49.0/src/cargo/util/command_prelude.rs:363:13 clippy::if_not_else "unnecessary boolean `not` operation" +cargo/0.49.0/src/cargo/util/command_prelude.rs:378:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/command_prelude.rs:387:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/command_prelude.rs:387:5 clippy::too_many_lines "this function has too many lines (104/100)" +cargo/0.49.0/src/cargo/util/command_prelude.rs:39:20 clippy::doc_markdown "you should put `arg_package_spec` between ticks in the documentation" +cargo/0.49.0/src/cargo/util/command_prelude.rs:504:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/command_prelude.rs:516:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/command_prelude.rs:530:40 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/util/command_prelude.rs:531:43 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/util/command_prelude.rs:536:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/command_prelude.rs:556:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/command_prelude.rs:575:49 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/util/command_prelude.rs:580:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/command_prelude.rs:631:18 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/util/command_prelude.rs:638:18 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/util/command_prelude.rs:647:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/command_prelude.rs:651:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/command_prelude.rs:662:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/command_prelude.rs:665:51 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/util/config/de.rs:420:16 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo/0.49.0/src/cargo/util/config/de.rs:46:25 clippy::doc_markdown "you should put `CV::List` between ticks in the documentation" +cargo/0.49.0/src/cargo/util/config/de.rs:47:24 clippy::doc_markdown "you should put `ConfigSeqAccess` between ticks in the documentation" +cargo/0.49.0/src/cargo/util/config/de.rs:527:53 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo/0.49.0/src/cargo/util/config/de.rs:530:53 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo/0.49.0/src/cargo/util/config/de.rs:532:68 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo/0.49.0/src/cargo/util/config/key.rs:11:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/util/config/key.rs:69:9 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo/0.49.0/src/cargo/util/config/mod.rs:100:71 clippy::doc_markdown "you should put `OptValue` between ticks in the documentation" +cargo/0.49.0/src/cargo/util/config/mod.rs:100:71 clippy::doc_markdown "you should put `OptValue` between ticks in the documentation" +cargo/0.49.0/src/cargo/util/config/mod.rs:100:71 clippy::doc_markdown "you should put `OptValue` between ticks in the documentation" +cargo/0.49.0/src/cargo/util/config/mod.rs:1049:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:1064:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:1090:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:1166:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:1179:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:1184:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:1189:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:1203:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:1211:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:1216:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:1225:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:1229:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:124:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo/0.49.0/src/cargo/util/config/mod.rs:1254:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:1279:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:1281:9 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/util/config/mod.rs:1323:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/util/config/mod.rs:1339:39 clippy::unused_self "unused `self` argument" +cargo/0.49.0/src/cargo/util/config/mod.rs:1344:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/util/config/mod.rs:1420:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/util/config/mod.rs:1553:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:1560:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:1567:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:1574:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:1581:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:1588:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/config/mod.rs:1598:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/config/mod.rs:1619:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/config/mod.rs:1623:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:1623:64 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo/0.49.0/src/cargo/util/config/mod.rs:1649:9 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" +cargo/0.49.0/src/cargo/util/config/mod.rs:1699:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/util/config/mod.rs:1730:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/util/config/mod.rs:1757:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/util/config/mod.rs:1770:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/util/config/mod.rs:1778:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/util/config/mod.rs:1804:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/util/config/mod.rs:1896:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/config/mod.rs:1901:5 clippy::doc_markdown "you should put `StringList` between ticks in the documentation" +cargo/0.49.0/src/cargo/util/config/mod.rs:214:13 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +cargo/0.49.0/src/cargo/util/config/mod.rs:259:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:298:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:311:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:318:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:353:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:401:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:411:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:419:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:431:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:449:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:454:16 clippy::option_if_let_else "use Option::map_or instead of an if let/else" +cargo/0.49.0/src/cargo/util/config/mod.rs:547:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:556:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:582:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:595:20 clippy::doc_markdown "you should put `StringList` between ticks in the documentation" +cargo/0.49.0/src/cargo/util/config/mod.rs:689:20 clippy::unused_self "unused `self` argument" +cargo/0.49.0/src/cargo/util/config/mod.rs:699:5 clippy::fn_params_excessive_bools "more than 3 bools in function parameters" +cargo/0.49.0/src/cargo/util/config/mod.rs:699:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:719:58 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/util/config/mod.rs:816:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:875:36 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/util/config/mod.rs:876:37 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/util/config/path.rs:10:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/util/config/path.rs:14:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/config/path.rs:48:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/util/config/target.rs:12:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/util/config/target.rs:24:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/util/config/value.rs:29:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/util/config/value.rs:80:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/config/value.rs:81:9 clippy::match_like_matches_macro "match expression looks like `matches!` macro" +cargo/0.49.0/src/cargo/util/cpu.rs:11:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/cpu.rs:22:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/cpu.rs:82:25 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +cargo/0.49.0/src/cargo/util/cpu.rs:82:9 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +cargo/0.49.0/src/cargo/util/dependency_queue.rs:109:27 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/util/dependency_queue.rs:136:20 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/util/dependency_queue.rs:151:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/dependency_queue.rs:156:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/dependency_queue.rs:46:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/dependency_queue.rs:91:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/util/diagnostic_server.rs:218:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/util/diagnostic_server.rs:230:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/diagnostic_server.rs:242:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/diagnostic_server.rs:58:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/diagnostic_server.rs:96:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/diagnostic_server.rs:96:5 clippy::too_many_lines "this function has too many lines (110/100)" +cargo/0.49.0/src/cargo/util/diagnostic_server.rs:99:21 clippy::shadow_unrelated "`msg` is being shadowed" +cargo/0.49.0/src/cargo/util/errors.rs:101:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/errors.rs:143:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/errors.rs:150:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/errors.rs:15:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/errors.rs:237:5 clippy::pub_enum_variant_names "variant name ends with the enum's name" +cargo/0.49.0/src/cargo/util/errors.rs:245:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/errors.rs:321:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/errors.rs:328:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/errors.rs:356:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/errors.rs:391:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/util/errors.rs:392:13 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/cargo/util/errors.rs:465:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/errors.rs:473:5 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +cargo/0.49.0/src/cargo/util/errors.rs:66:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/flock.rs:115:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/flock.rs:11:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/cargo/util/flock.rs:134:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/flock.rs:142:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/flock.rs:150:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/flock.rs:156:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/flock.rs:170:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/flock.rs:192:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/flock.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/flock.rs:321:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/util/flock.rs:335:23 clippy::cast_possible_truncation "casting `i64` to `u32` may truncate the value" +cargo/0.49.0/src/cargo/util/flock.rs:335:23 clippy::cast_sign_loss "casting `i64` to `u32` may lose the sign of the value" +cargo/0.49.0/src/cargo/util/flock.rs:335:44 clippy::cast_possible_truncation "casting `i64` to `u32` may truncate the value" +cargo/0.49.0/src/cargo/util/flock.rs:379:35 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/util/flock.rs:37:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/flock.rs:43:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/flock.rs:52:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/graph.rs:10:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/graph.rs:115:13 clippy::find_map "called `find(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/util/graph.rs:41:51 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/util/graph.rs:45:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/graph.rs:95:13 clippy::find_map "called `find(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/util/hasher.rs:12:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/hasher.rs:9:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/util/hex.rs:10:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" +cargo/0.49.0/src/cargo/util/hex.rs:11:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" +cargo/0.49.0/src/cargo/util/hex.rs:12:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" +cargo/0.49.0/src/cargo/util/hex.rs:13:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" +cargo/0.49.0/src/cargo/util/hex.rs:14:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" +cargo/0.49.0/src/cargo/util/hex.rs:15:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" +cargo/0.49.0/src/cargo/util/hex.rs:25:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/hex.rs:6:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/util/hex.rs:6:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/hex.rs:8:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" +cargo/0.49.0/src/cargo/util/hex.rs:9:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" +cargo/0.49.0/src/cargo/util/important_paths.rs:23:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/important_paths.rs:6:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/interning.rs:66:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/interning.rs:77:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/into_url.rs:10:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/into_url_with_base.rs:9:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/job.rs:20:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/lev_distance.rs:3:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/lockserver.rs:111:32 clippy::redundant_else "redundant else block" +cargo/0.49.0/src/cargo/util/lockserver.rs:158:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/lockserver.rs:46:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/lockserver.rs:58:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/lockserver.rs:62:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/mod.rs:68:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/mod.rs:79:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/network.rs:12:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/network.rs:19:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/network.rs:84:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/paths.rs:109:12 clippy::redundant_else "redundant else block" +cargo/0.49.0/src/cargo/util/paths.rs:114:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/paths.rs:121:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/paths.rs:125:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/paths.rs:130:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/paths.rs:14:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/paths.rs:14:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/util/paths.rs:151:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/paths.rs:167:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/paths.rs:173:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/paths.rs:178:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/paths.rs:185:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/paths.rs:199:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/paths.rs:215:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/paths.rs:228:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/paths.rs:251:9 clippy::option_if_let_else "use Option::map_or instead of an if let/else" +cargo/0.49.0/src/cargo/util/paths.rs:267:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/paths.rs:276:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/paths.rs:29:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/paths.rs:303:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/paths.rs:312:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/paths.rs:346:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/paths.rs:415:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/paths.rs:445:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/paths.rs:459:45 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/util/paths.rs:469:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/paths.rs:54:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/paths.rs:61:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/paths.rs:63:19 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" +cargo/0.49.0/src/cargo/util/paths.rs:88:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/paths.rs:93:31 clippy::comparison_to_empty "comparison to empty slice" +cargo/0.49.0/src/cargo/util/process_builder.rs:106:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/process_builder.rs:111:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/process_builder.rs:122:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/process_builder.rs:132:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/process_builder.rs:152:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/process_builder.rs:185:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/process_builder.rs:190:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/process_builder.rs:218:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/process_builder.rs:307:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/process_builder.rs:343:39 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo/0.49.0/src/cargo/util/progress.rs:122:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/progress.rs:136:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/progress.rs:15:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/util/progress.rs:249:19 clippy::cast_precision_loss "casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +cargo/0.49.0/src/cargo/util/progress.rs:249:34 clippy::cast_precision_loss "casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +cargo/0.49.0/src/cargo/util/progress.rs:250:19 clippy::if_not_else "unnecessary boolean `not` operation" +cargo/0.49.0/src/cargo/util/progress.rs:263:22 clippy::cast_precision_loss "casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +cargo/0.49.0/src/cargo/util/progress.rs:264:22 clippy::cast_possible_truncation "casting `f64` to `usize` may truncate the value" +cargo/0.49.0/src/cargo/util/progress.rs:264:22 clippy::cast_sign_loss "casting `f64` to `usize` may lose the sign of the value" +cargo/0.49.0/src/cargo/util/progress.rs:269:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo/0.49.0/src/cargo/util/progress.rs:272:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo/0.49.0/src/cargo/util/progress.rs:274:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo/0.49.0/src/cargo/util/progress.rs:280:13 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo/0.49.0/src/cargo/util/progress.rs:282:9 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo/0.49.0/src/cargo/util/progress.rs:89:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/progress.rs:97:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/queue.rs:25:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/read2.rs:11:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/read2.rs:31:17 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/util/restricted_names.rs:13:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/restricted_names.rs:26:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/restricted_names.rs:35:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/restricted_names.rs:45:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/restricted_names.rs:87:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/restricted_names.rs:89:21 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/util/restricted_names.rs:8:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/rustc.rs:103:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/rustc.rs:114:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +cargo/0.49.0/src/cargo/util/rustc.rs:115:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +cargo/0.49.0/src/cargo/util/rustc.rs:162:17 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/util/rustc.rs:39:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/rustc.rs:55:13 clippy::find_map "called `find(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/util/sha256.rs:10:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/sha256.rs:20:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/sha256.rs:31:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/sha256.rs:40:24 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo/0.49.0/src/cargo/util/to_semver.rs:5:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/toml/mod.rs:1005:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/toml/mod.rs:1005:5 clippy::too_many_lines "this function has too many lines (282/100)" +cargo/0.49.0/src/cargo/util/toml/mod.rs:1094:36 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/util/toml/mod.rs:1121:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/util/toml/mod.rs:1197:32 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +cargo/0.49.0/src/cargo/util/toml/mod.rs:124:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/toml/mod.rs:1504:9 clippy::unused_self "unused `self` argument" +cargo/0.49.0/src/cargo/util/toml/mod.rs:1526:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/toml/mod.rs:1582:19 clippy::default_trait_access "calling `util::toml::DetailedTomlDependency::default()` is more clear than this expression" +cargo/0.49.0/src/cargo/util/toml/mod.rs:1598:5 clippy::too_many_lines "this function has too many lines (153/100)" +cargo/0.49.0/src/cargo/util/toml/mod.rs:1687:33 clippy::unnecessary_lazy_evaluations "unnecessary closure used to substitute value for `Option::None`" +cargo/0.49.0/src/cargo/util/toml/mod.rs:178:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/util/toml/mod.rs:248:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/util/toml/mod.rs:274:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/util/toml/mod.rs:277:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/toml/mod.rs:281:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/toml/mod.rs:285:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/toml/mod.rs:294:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/util/toml/mod.rs:31:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/toml/mod.rs:381:35 clippy::cast_possible_truncation "casting `i64` to `u32` may truncate the value" +cargo/0.49.0/src/cargo/util/toml/mod.rs:381:35 clippy::cast_sign_loss "casting `i64` to `u32` may lose the sign of the value" +cargo/0.49.0/src/cargo/util/toml/mod.rs:388:35 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +cargo/0.49.0/src/cargo/util/toml/mod.rs:398:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/util/toml/mod.rs:450:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/toml/mod.rs:536:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/toml/mod.rs:783:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/util/toml/mod.rs:824:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/util/toml/mod.rs:834:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/toml/mod.rs:83:42 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/util/toml/mod.rs:852:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/toml/mod.rs:852:5 clippy::too_many_lines "this function has too many lines (138/100)" +cargo/0.49.0/src/cargo/util/toml/mod.rs:962:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/util/toml/mod.rs:971:24 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/util/toml/mod.rs:979:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/util/toml/mod.rs:98:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/util/toml/mod.rs:999:23 clippy::default_trait_access "calling `util::toml::DetailedTomlDependency::default()` is more clear than this expression" +cargo/0.49.0/src/cargo/util/toml/targets.rs:112:27 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/util/toml/targets.rs:325:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/util/toml/targets.rs:586:21 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/util/toml/targets.rs:593:42 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/util/toml/targets.rs:605:19 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/util/toml/targets.rs:612:42 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/util/toml/targets.rs:756:36 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/util/toml/targets.rs:810:24 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/util/vcs.rs:10:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/vcs.rs:33:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/vcs.rs:37:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/vcs.rs:43:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/vcs.rs:47:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/vcs.rs:59:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/vcs.rs:66:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/workspace.rs:52:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/workspace.rs:56:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/workspace.rs:60:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/workspace.rs:64:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron/0.6.1/src/error.rs:24:1 clippy::module_name_repetitions "item name ends with its containing module's name" +iron/0.6.1/src/iron.rs:105:13 clippy::redundant_field_names "redundant field names in struct initialization" +iron/0.6.1/src/iron.rs:119:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron/0.6.1/src/iron.rs:133:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron/0.6.1/src/iron.rs:143:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron/0.6.1/src/iron.rs:149:13 clippy::redundant_field_names "redundant field names in struct initialization" +iron/0.6.1/src/iron.rs:167:49 clippy::similar_names "binding's name is too similar to existing binding" +iron/0.6.1/src/iron.rs:80:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron/0.6.1/src/iron.rs:85:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron/0.6.1/src/iron.rs:90:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron/0.6.1/src/lib.rs:1:null clippy::cargo_common_metadata "package `iron` is missing `package.categories` metadata" +iron/0.6.1/src/lib.rs:1:null clippy::cargo_common_metadata "package `iron` is missing `package.keywords` metadata" +iron/0.6.1/src/lib.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `log`: 0.3.9, 0.4.8" +iron/0.6.1/src/middleware/mod.rs:137:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron/0.6.1/src/middleware/mod.rs:150:1 clippy::module_name_repetitions "item name ends with its containing module's name" +iron/0.6.1/src/middleware/mod.rs:152:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron/0.6.1/src/middleware/mod.rs:159:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron/0.6.1/src/middleware/mod.rs:171:1 clippy::module_name_repetitions "item name ends with its containing module's name" +iron/0.6.1/src/middleware/mod.rs:173:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron/0.6.1/src/middleware/mod.rs:182:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron/0.6.1/src/middleware/mod.rs:192:1 clippy::module_name_repetitions "item name ends with its containing module's name" +iron/0.6.1/src/middleware/mod.rs:217:25 clippy::doc_markdown "you should put `ChainBuilder` between ticks in the documentation" +iron/0.6.1/src/middleware/mod.rs:328:20 clippy::similar_names "binding's name is too similar to existing binding" +iron/0.6.1/src/middleware/mod.rs:360:16 clippy::similar_names "binding's name is too similar to existing binding" +iron/0.6.1/src/middleware/mod.rs:368:33 clippy::similar_names "binding's name is too similar to existing binding" +iron/0.6.1/src/middleware/mod.rs:428:40 clippy::similar_names "binding's name is too similar to existing binding" +iron/0.6.1/src/middleware/mod.rs:434:40 clippy::similar_names "binding's name is too similar to existing binding" +iron/0.6.1/src/middleware/mod.rs:444:40 clippy::similar_names "binding's name is too similar to existing binding" +iron/0.6.1/src/modifiers.rs:132:14 clippy::expect_fun_call "use of `expect` followed by a function call" +iron/0.6.1/src/request/mod.rs:113:24 clippy::similar_names "binding's name is too similar to existing binding" +iron/0.6.1/src/request/mod.rs:121:13 clippy::redundant_field_names "redundant field names in struct initialization" +iron/0.6.1/src/request/mod.rs:123:13 clippy::redundant_field_names "redundant field names in struct initialization" +iron/0.6.1/src/request/mod.rs:124:13 clippy::redundant_field_names "redundant field names in struct initialization" +iron/0.6.1/src/request/mod.rs:126:13 clippy::redundant_field_names "redundant field names in struct initialization" +iron/0.6.1/src/request/mod.rs:128:13 clippy::redundant_field_names "redundant field names in struct initialization" +iron/0.6.1/src/request/mod.rs:153:69 clippy::doc_markdown "you should put `HttpReader` between ticks in the documentation" +iron/0.6.1/src/request/mod.rs:154:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron/0.6.1/src/request/mod.rs:32:1 clippy::manual_non_exhaustive "this seems like a manual implementation of the non-exhaustive pattern" +iron/0.6.1/src/request/mod.rs:75:34 clippy::doc_markdown "you should put `HttpRequest` between ticks in the documentation" +iron/0.6.1/src/request/mod.rs:77:39 clippy::doc_markdown "you should put `HttpRequest` between ticks in the documentation" +iron/0.6.1/src/request/mod.rs:78:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron/0.6.1/src/request/mod.rs:82:13 clippy::similar_names "binding's name is too similar to existing binding" +iron/0.6.1/src/request/mod.rs:83:29 clippy::similar_names "binding's name is too similar to existing binding" +iron/0.6.1/src/request/mod.rs:85:24 clippy::similar_names "binding's name is too similar to existing binding" +iron/0.6.1/src/request/url.rs:109:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron/0.6.1/src/request/url.rs:117:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron/0.6.1/src/request/url.rs:129:1 clippy::from_over_into "an implementation of `From` is preferred since it gives you `Into<_>` for free where the reverse isn't true" +iron/0.6.1/src/request/url.rs:21:14 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +iron/0.6.1/src/request/url.rs:22:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron/0.6.1/src/request/url.rs:31:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron/0.6.1/src/request/url.rs:47:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron/0.6.1/src/request/url.rs:52:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron/0.6.1/src/request/url.rs:57:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron/0.6.1/src/request/url.rs:63:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron/0.6.1/src/request/url.rs:73:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron/0.6.1/src/request/url.rs:83:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron/0.6.1/src/request/url.rs:96:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron/0.6.1/src/response.rs:121:19 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +iron/0.6.1/src/response.rs:125:43 clippy::redundant_closure_for_method_calls "redundant closure found" +iron/0.6.1/src/response.rs:139:41 clippy::redundant_closure_for_method_calls "redundant closure found" +iron/0.6.1/src/response.rs:24:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron/0.6.1/src/response.rs:95:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron/0.6.1/src/response.rs:95:5 clippy::new_without_default "you should consider adding a `Default` implementation for `response::Response`" +libc/0.2.81/build.rs:114:19 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +libc/0.2.81/build.rs:124:5 clippy::question_mark "this block may be rewritten with the `?` operator" +libc/0.2.81/build.rs:133:5 clippy::question_mark "this block may be rewritten with the `?` operator" +libc/0.2.81/src/macros.rs:243:17 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +libc/0.2.81/src/macros.rs:243:17 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +libc/0.2.81/src/macros.rs:243:17 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:428:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:429:30 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:431:30 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:432:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:433:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:434:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:595:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:596:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:597:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:622:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:673:34 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:696:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:697:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:698:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:699:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:712:34 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:721:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:722:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:723:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:751:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:752:30 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:753:30 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:754:30 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:755:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:756:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:757:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:758:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:759:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:760:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:768:30 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:769:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:771:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:772:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:773:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:774:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:775:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:776:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:777:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:778:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:779:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:780:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:781:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:782:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:783:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:784:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:785:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:786:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:787:30 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:788:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:789:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:790:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:791:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:792:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:794:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:795:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:796:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:797:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:798:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:799:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:800:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:801:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:803:27 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:804:28 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:805:28 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:806:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:807:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:808:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:809:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:810:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:811:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:812:30 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:813:30 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:814:30 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:815:30 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:816:30 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:817:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:818:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:821:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:822:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:823:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:824:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:825:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:826:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:827:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:828:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:829:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:830:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:831:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:832:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:833:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:834:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:835:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:836:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:841:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:842:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:843:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:844:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:1120:38 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:178:34 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:291:5 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:291:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:302:5 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:302:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:355:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:355:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:359:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:359:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:363:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:363:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:367:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:367:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:371:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:371:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:534:36 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:645:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:727:40 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:728:40 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:729:39 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:731:44 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:732:36 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:733:41 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:734:43 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:735:42 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:736:40 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:737:36 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:738:37 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:741:39 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:742:40 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:743:40 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:744:40 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:745:40 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:746:43 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:747:42 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:748:40 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:749:39 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:750:41 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:751:41 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:752:43 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:753:42 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:755:42 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:756:41 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:757:41 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:758:39 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:759:39 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:761:41 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:762:44 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:763:45 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:764:40 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:765:40 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:766:40 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:767:44 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:768:44 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:769:39 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:770:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:771:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:772:37 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:773:39 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:774:45 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:775:41 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:776:39 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:803:34 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:841:30 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:842:37 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:982:40 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:984:46 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1209:36 clippy::cast_possible_truncation "casting `i32` to `i16` may truncate the value" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1210:36 clippy::cast_possible_truncation "casting `i32` to `i16` may truncate the value" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1235:39 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1236:41 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1274:42 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1324:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1333:37 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1334:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1346:34 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1346:34 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1346:34 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1347:37 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1347:37 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1347:37 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1348:36 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1348:36 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1348:36 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1349:37 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1349:37 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1349:37 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1350:35 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1350:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1350:35 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1351:36 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1351:36 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1351:36 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1352:31 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1352:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1352:31 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1419:36 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1420:36 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1421:36 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1422:36 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1423:36 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1490:37 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1561:46 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1562:45 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1567:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1568:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1586:26 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1587:34 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1588:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1589:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1897:38 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1898:51 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1900:39 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1969:34 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1970:34 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1971:36 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1972:36 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1973:36 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1974:37 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1975:37 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1976:36 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1977:36 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1978:39 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1979:39 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1980:39 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1981:39 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1982:39 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1983:39 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1984:38 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1985:38 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1986:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1987:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1988:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1989:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1990:38 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1991:37 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1992:37 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1993:38 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1994:37 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1995:37 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1996:37 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1997:37 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1998:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1999:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2000:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2001:34 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2002:34 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2003:34 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2004:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2005:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2032:30 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2033:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2034:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2035:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2036:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2037:28 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2038:27 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2039:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2041:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2042:28 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2043:27 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2044:34 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2045:27 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2046:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2048:28 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2049:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2050:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2051:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2052:26 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2053:36 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2318:42 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2321:38 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2331:39 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2487:42 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2488:42 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2489:43 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2490:43 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2491:43 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2493:47 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2494:44 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2495:46 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2496:47 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2497:49 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2498:48 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2499:50 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2500:45 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2572:9 clippy::needless_return "unneeded `return` statement" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2578:20 clippy::zero_ptr "`0 as *mut _` detected" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2588:13 clippy::zero_ptr "`0 as *mut _` detected" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2596:52 clippy::used_underscore_binding "used binding `_dummy` which is prefixed with an underscore. A leading underscore signals that a binding will not be used." +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2597:11 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2601:21 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2611:9 clippy::unused_unit "unneeded unit expression" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2619:9 clippy::unused_unit "unneeded unit expression" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2634:9 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2647:25 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2648:25 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2649:9 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2654:18 clippy::identity_op "the operation is ineffective. Consider reducing it to `(dev & 0x00000000000000ff)`" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2654:25 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2655:25 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2656:9 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2660:21 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2661:21 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2663:25 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2664:25 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2665:16 clippy::identity_op "the operation is ineffective. Consider reducing it to `(minor & 0x000000ff)`" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2665:25 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2666:25 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:40:1 clippy::empty_enum "enum with no variants" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:954:34 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1000:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1001:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1002:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1016:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1017:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1018:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1019:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1020:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1029:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1030:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1031:30 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1032:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1033:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1034:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1035:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1041:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1042:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1043:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1044:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1045:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1046:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1047:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1048:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1049:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1050:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1051:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1053:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1054:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1055:30 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1056:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1057:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1058:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1059:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1060:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1073:42 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1074:43 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1075:37 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1076:37 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1077:41 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1078:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1079:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1080:36 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1081:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1082:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1083:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1084:38 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1086:30 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1087:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1089:30 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1090:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1091:30 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1094:40 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1095:37 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1096:41 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1097:40 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1098:39 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1099:34 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1100:36 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1101:38 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1102:37 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1105:44 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1106:41 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1107:42 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1108:42 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1109:41 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1110:46 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1111:41 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1112:44 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1113:40 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1114:47 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1115:36 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1126:34 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1127:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1128:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1179:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1180:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1218:27 clippy::identity_op "the operation is ineffective. Consider reducing it to `IPOPT_CONTROL`" +libc/0.2.81/src/unix/linux_like/mod.rs:1314:9 clippy::precedence "operator precedence can trip the unwary" +libc/0.2.81/src/unix/linux_like/mod.rs:1323:13 clippy::zero_ptr "`0 as *mut _` detected" +libc/0.2.81/src/unix/linux_like/mod.rs:1332:9 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +libc/0.2.81/src/unix/linux_like/mod.rs:1337:9 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +libc/0.2.81/src/unix/linux_like/mod.rs:1341:18 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" +libc/0.2.81/src/unix/linux_like/mod.rs:1344:9 clippy::needless_return "unneeded `return` statement" +libc/0.2.81/src/unix/linux_like/mod.rs:1348:18 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" +libc/0.2.81/src/unix/linux_like/mod.rs:1350:9 clippy::needless_return "unneeded `return` statement" +libc/0.2.81/src/unix/linux_like/mod.rs:1354:18 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" +libc/0.2.81/src/unix/linux_like/mod.rs:1357:9 clippy::needless_return "unneeded `return` statement" +libc/0.2.81/src/unix/linux_like/mod.rs:1361:21 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" +libc/0.2.81/src/unix/linux_like/mod.rs:1381:9 clippy::cast_possible_truncation "casting `i32` to `i8` may truncate the value" +libc/0.2.81/src/unix/linux_like/mod.rs:1389:9 clippy::verbose_bit_mask "bit mask could be simplified with a call to `trailing_zeros`" +libc/0.2.81/src/unix/linux_like/mod.rs:446:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:591:36 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:592:38 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:593:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:594:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:595:34 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:596:36 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:597:37 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:598:37 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:599:39 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:600:34 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:601:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:602:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:607:37 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:608:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:764:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:765:39 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:991:30 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:9:1 clippy::empty_enum "enum with no variants" +libc/0.2.81/src/unix/mod.rs:198:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/mod.rs:199:28 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/mod.rs:201:35 clippy::unnecessary_cast "casting integer literal to `usize` is unnecessary" +libc/0.2.81/src/unix/mod.rs:202:35 clippy::unnecessary_cast "casting integer literal to `usize` is unnecessary" +libc/0.2.81/src/unix/mod.rs:282:40 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/mod.rs:284:41 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/mod.rs:285:36 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/mod.rs:34:1 clippy::empty_enum "enum with no variants" +libc/0.2.81/src/unix/mod.rs:386:1 clippy::empty_enum "enum with no variants" +libc/0.2.81/src/unix/mod.rs:394:1 clippy::empty_enum "enum with no variants" +log/0.4.11/src/lib.rs:1047:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:1053:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:1059:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:1093:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:1093:5 clippy::new_without_default "you should consider adding a `Default` implementation for `MetadataBuilder<'a>`" +log/0.4.11/src/lib.rs:1118:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:1177:1 clippy::inline_always "you have declared `#[inline(always)]` on `max_level`. This is usually a bad idea" +log/0.4.11/src/lib.rs:1178:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:1306:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +log/0.4.11/src/lib.rs:1358:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:1359:5 clippy::if_not_else "unnecessary `!=` operation" +log/0.4.11/src/lib.rs:1407:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:329:27 clippy::derive_hash_xor_eq "you are deriving `Hash` but have implemented `PartialEq` explicitly" +log/0.4.11/src/lib.rs:356:1 clippy::expl_impl_clone_on_copy "you are implementing `Clone` explicitly on a `Copy` type" +log/0.4.11/src/lib.rs:448:12 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +log/0.4.11/src/lib.rs:468:13 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +log/0.4.11/src/lib.rs:500:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:506:28 clippy::trivially_copy_pass_by_ref "this argument (8 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +log/0.4.11/src/lib.rs:506:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:520:27 clippy::derive_hash_xor_eq "you are deriving `Hash` but have implemented `PartialEq` explicitly" +log/0.4.11/src/lib.rs:538:1 clippy::expl_impl_clone_on_copy "you are implementing `Clone` explicitly on a `Copy` type" +log/0.4.11/src/lib.rs:653:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:661:21 clippy::trivially_copy_pass_by_ref "this argument (8 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +log/0.4.11/src/lib.rs:661:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:677:44 clippy::match_same_arms "this `match` has identical arm bodies" +log/0.4.11/src/lib.rs:758:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:764:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:770:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:776:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:782:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:788:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:794:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:803:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:809:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:818:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:908:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:908:5 clippy::new_without_default "you should consider adding a `Default` implementation for `RecordBuilder<'a>`" +log/0.4.11/src/lib.rs:995:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/detection.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +proc-macro2/1.0.24/src/fallback.rs:108:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +proc-macro2/1.0.24/src/fallback.rs:269:20 clippy::unused_self "unused `self` argument" +proc-macro2/1.0.24/src/fallback.rs:430:24 clippy::trivially_copy_pass_by_ref "this argument (0 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +proc-macro2/1.0.24/src/fallback.rs:437:23 clippy::trivially_copy_pass_by_ref "this argument (0 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +proc-macro2/1.0.24/src/fallback.rs:437:23 clippy::unused_self "unused `self` argument" +proc-macro2/1.0.24/src/fallback.rs:471:17 clippy::trivially_copy_pass_by_ref "this argument (0 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +proc-macro2/1.0.24/src/fallback.rs:471:17 clippy::unused_self "unused `self` argument" +proc-macro2/1.0.24/src/fallback.rs:654:5 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +proc-macro2/1.0.24/src/fallback.rs:655:12 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +proc-macro2/1.0.24/src/fallback.rs:661:5 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +proc-macro2/1.0.24/src/fallback.rs:662:12 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +proc-macro2/1.0.24/src/fallback.rs:664:12 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +proc-macro2/1.0.24/src/fallback.rs:674:37 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +proc-macro2/1.0.24/src/fallback.rs:678:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +proc-macro2/1.0.24/src/fallback.rs:85:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +proc-macro2/1.0.24/src/fallback.rs:882:43 clippy::unused_self "unused `self` argument" +proc-macro2/1.0.24/src/lib.rs:1017:9 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:1081:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:1099:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:1117:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:1135:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:1141:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:1146:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:1151:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:1156:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:152:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:157:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:373:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:383:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:397:24 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +proc-macro2/1.0.24/src/lib.rs:397:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:403:23 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +proc-macro2/1.0.24/src/lib.rs:403:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:418:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:425:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:464:17 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +proc-macro2/1.0.24/src/lib.rs:500:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:626:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:633:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:641:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:652:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:662:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:672:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:734:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:743:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:752:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:757:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:788:19 clippy::doc_markdown "you should put `XID_Start` between ticks in the documentation" +proc-macro2/1.0.24/src/lib.rs:788:69 clippy::doc_markdown "you should put `XID_Continue` between ticks in the documentation" +proc-macro2/1.0.24/src/lib.rs:891:36 clippy::doc_markdown "you should put `syn::parse_str` between ticks in the documentation" +proc-macro2/1.0.24/src/lib.rs:894:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:911:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:996:9 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/parse.rs:552:5 clippy::while_let_on_iterator "this loop could be written as a `for` loop" +proc-macro2/1.0.24/src/parse.rs:584:21 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +proc-macro2/1.0.24/src/parse.rs:602:20 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +proc-macro2/1.0.24/src/parse.rs:696:29 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" +proc-macro2/1.0.24/src/parse.rs:702:34 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" +proc-macro2/1.0.24/src/parse.rs:708:34 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" +proc-macro2/1.0.24/src/parse.rs:803:15 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" +proc-macro2/1.0.24/src/parse.rs:808:15 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" +proc-macro2/1.0.24/src/wrapper.rs:415:24 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +proc-macro2/1.0.24/src/wrapper.rs:429:23 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +proc-macro2/1.0.24/src/wrapper.rs:492:17 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +quote/1.0.7/src/ext.rs:10:1 clippy::module_name_repetitions "item name ends with its containing module's name" +quote/1.0.7/src/ext.rs:7:5 clippy::doc_markdown "you should put `TokenStream` between ticks in the documentation" +quote/1.0.7/src/ident_fragment.rs:13:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +quote/1.0.7/src/ident_fragment.rs:51:31 clippy::manual_strip "stripping a prefix manually" +quote/1.0.7/src/runtime.rs:52:5 clippy::module_name_repetitions "item name ends with its containing module's name" +quote/1.0.7/src/runtime.rs:63:5 clippy::module_name_repetitions "item name ends with its containing module's name" +quote/1.0.7/src/runtime.rs:66:33 clippy::doc_markdown "you should put `DoesNotHaveIter` between ticks in the documentation" +quote/1.0.7/src/runtime.rs:80:5 clippy::module_name_repetitions "item name ends with its containing module's name" +rand/0.7.3/src/distributions/bernoulli.rs:103:20 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" +rand/0.7.3/src/distributions/bernoulli.rs:103:20 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" +rand/0.7.3/src/distributions/bernoulli.rs:116:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +rand/0.7.3/src/distributions/bernoulli.rs:123:21 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" +rand/0.7.3/src/distributions/bernoulli.rs:123:21 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" +rand/0.7.3/src/distributions/bernoulli.rs:63:26 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand/0.7.3/src/distributions/bernoulli.rs:63:27 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +rand/0.7.3/src/distributions/bernoulli.rs:67:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand/0.7.3/src/distributions/bernoulli.rs:95:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +rand/0.7.3/src/distributions/bernoulli.rs:96:13 clippy::manual_range_contains "manual `Range::contains` implementation" +rand/0.7.3/src/distributions/binomial.rs:107:23 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand/0.7.3/src/distributions/binomial.rs:112:44 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand/0.7.3/src/distributions/binomial.rs:116:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rand/0.7.3/src/distributions/binomial.rs:150:28 clippy::redundant_else "redundant else block" +rand/0.7.3/src/distributions/binomial.rs:153:24 clippy::if_not_else "unnecessary boolean `not` operation" +rand/0.7.3/src/distributions/binomial.rs:158:28 clippy::redundant_else "redundant else block" +rand/0.7.3/src/distributions/binomial.rs:164:33 clippy::cast_sign_loss "casting `i64` to `u64` may lose the sign of the value" +rand/0.7.3/src/distributions/binomial.rs:166:28 clippy::redundant_else "redundant else block" +rand/0.7.3/src/distributions/binomial.rs:175:47 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand/0.7.3/src/distributions/binomial.rs:185:38 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand/0.7.3/src/distributions/binomial.rs:194:38 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand/0.7.3/src/distributions/binomial.rs:202:28 clippy::redundant_else "redundant else block" +rand/0.7.3/src/distributions/binomial.rs:209:25 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand/0.7.3/src/distributions/binomial.rs:221:26 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand/0.7.3/src/distributions/binomial.rs:222:26 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand/0.7.3/src/distributions/binomial.rs:223:25 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand/0.7.3/src/distributions/binomial.rs:224:25 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand/0.7.3/src/distributions/binomial.rs:226:17 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rand/0.7.3/src/distributions/binomial.rs:233:32 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand/0.7.3/src/distributions/binomial.rs:234:27 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand/0.7.3/src/distributions/binomial.rs:251:22 clippy::cast_sign_loss "casting `i64` to `u64` may lose the sign of the value" +rand/0.7.3/src/distributions/binomial.rs:255:9 clippy::if_not_else "unnecessary `!=` operation" +rand/0.7.3/src/distributions/binomial.rs:35:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/distributions/binomial.rs:45:17 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand/0.7.3/src/distributions/binomial.rs:46:5 clippy::cast_possible_truncation "casting `f64` to `i64` may truncate the value" +rand/0.7.3/src/distributions/binomial.rs:50:5 clippy::too_many_lines "this function has too many lines (143/100)" +rand/0.7.3/src/distributions/binomial.rs:76:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rand/0.7.3/src/distributions/binomial.rs:78:12 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand/0.7.3/src/distributions/binomial.rs:81:21 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand/0.7.3/src/distributions/binomial.rs:82:32 clippy::cast_possible_truncation "casting `u64` to `i32` may truncate the value" +rand/0.7.3/src/distributions/binomial.rs:88:26 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand/0.7.3/src/distributions/binomial.rs:99:21 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand/0.7.3/src/distributions/cauchy.rs:33:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/distributions/dirichlet.rs:52:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/distributions/dirichlet.rs:64:32 clippy::unseparated_literal_suffix "float type suffix should be separated by an underscore" +rand/0.7.3/src/distributions/dirichlet.rs:65:23 clippy::unseparated_literal_suffix "float type suffix should be separated by an underscore" +rand/0.7.3/src/distributions/exponential.rs:76:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/distributions/float.rs:73:1 clippy::module_name_repetitions "item name ends with its containing module's name" +rand/0.7.3/src/distributions/gamma.rs:13:5 clippy::enum_glob_use "usage of wildcard import for enum variants" +rand/0.7.3/src/distributions/gamma.rs:14:5 clippy::enum_glob_use "usage of wildcard import for enum variants" +rand/0.7.3/src/distributions/gamma.rs:189:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/distributions/gamma.rs:230:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/distributions/gamma.rs:259:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/distributions/gamma.rs:287:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/distributions/gamma.rs:90:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/distributions/integer.rs:23:9 clippy::cast_possible_truncation "casting `u32` to `u8` may truncate the value" +rand/0.7.3/src/distributions/integer.rs:30:9 clippy::cast_possible_truncation "casting `u32` to `u16` may truncate the value" +rand/0.7.3/src/distributions/integer.rs:69:9 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +rand/0.7.3/src/distributions/mod.rs:263:5 clippy::inline_always "you have declared `#[inline(always)]` on `next`. This is usually a bad idea" +rand/0.7.3/src/distributions/normal.rs:100:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/distributions/normal.rs:119:1 clippy::module_name_repetitions "item name ends with its containing module's name" +rand/0.7.3/src/distributions/normal.rs:131:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/distributions/normal.rs:31:1 clippy::module_name_repetitions "item name ends with its containing module's name" +rand/0.7.3/src/distributions/normal.rs:47:25 clippy::unseparated_literal_suffix "float type suffix should be separated by an underscore" +rand/0.7.3/src/distributions/normal.rs:48:25 clippy::unseparated_literal_suffix "float type suffix should be separated by an underscore" +rand/0.7.3/src/distributions/other.rs:89:9 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +rand/0.7.3/src/distributions/pareto.rs:32:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/distributions/poisson.rs:35:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/distributions/poisson.rs:87:30 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" +rand/0.7.3/src/distributions/poisson.rs:87:30 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" +rand/0.7.3/src/distributions/triangular.rs:32:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/distributions/uniform.rs:146:4 clippy::needless_doctest_main "needless `fn main` in doctest" +rand/0.7.3/src/distributions/uniform.rs:199:1 clippy::module_name_repetitions "item name ends with its containing module's name" +rand/0.7.3/src/distributions/uniform.rs:214:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand/0.7.3/src/distributions/uniform.rs:283:14 clippy::doc_markdown "you should put `SampleUniform` between ticks in the documentation" +rand/0.7.3/src/distributions/uniform.rs:283:46 clippy::doc_markdown "you should put `SampleUniform` between ticks in the documentation" +rand/0.7.3/src/distributions/uniform.rs:296:5 clippy::inline_always "you have declared `#[inline(always)]` on `borrow`. This is usually a bad idea" +rand/0.7.3/src/distributions/uniform.rs:304:5 clippy::inline_always "you have declared `#[inline(always)]` on `borrow`. This is usually a bad idea" +rand/0.7.3/src/distributions/uniform.rs:350:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand/0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" +rand/0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" +rand/0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" +rand/0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" +rand/0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" +rand/0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" +rand/0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" +rand/0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" +rand/0.7.3/src/distributions/uniform.rs:56:10 clippy::doc_markdown "you should put `SampleBorrow` between ticks in the documentation" +rand/0.7.3/src/distributions/uniform.rs:647:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand/0.7.3/src/distributions/uniform.rs:840:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand/0.7.3/src/distributions/uniform.rs:913:13 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" +rand/0.7.3/src/distributions/uniform.rs:943:54 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +rand/0.7.3/src/distributions/unit_circle.rs:30:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/distributions/unit_sphere.rs:24:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand/0.7.3/src/distributions/unit_sphere.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/distributions/utils.rs:247:15 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" +rand/0.7.3/src/distributions/utils.rs:248:20 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" +rand/0.7.3/src/distributions/utils.rs:249:18 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" +rand/0.7.3/src/distributions/utils.rs:254:5 clippy::inline_always "you have declared `#[inline(always)]` on `lanes`. This is usually a bad idea" +rand/0.7.3/src/distributions/utils.rs:258:5 clippy::inline_always "you have declared `#[inline(always)]` on `splat`. This is usually a bad idea" +rand/0.7.3/src/distributions/utils.rs:262:5 clippy::inline_always "you have declared `#[inline(always)]` on `extract`. This is usually a bad idea" +rand/0.7.3/src/distributions/utils.rs:267:5 clippy::inline_always "you have declared `#[inline(always)]` on `replace`. This is usually a bad idea" +rand/0.7.3/src/distributions/utils.rs:281:5 clippy::inline_always "you have declared `#[inline(always)]` on `any`. This is usually a bad idea" +rand/0.7.3/src/distributions/utils.rs:286:5 clippy::inline_always "you have declared `#[inline(always)]` on `all`. This is usually a bad idea" +rand/0.7.3/src/distributions/utils.rs:291:5 clippy::inline_always "you have declared `#[inline(always)]` on `none`. This is usually a bad idea" +rand/0.7.3/src/distributions/utils.rs:488:17 clippy::doc_markdown "you should put `x_i` between ticks in the documentation" +rand/0.7.3/src/distributions/utils.rs:489:50 clippy::doc_markdown "you should put `x_i` between ticks in the documentation" +rand/0.7.3/src/distributions/utils.rs:489:63 clippy::doc_markdown "you should put `f(x_i` between ticks in the documentation" +rand/0.7.3/src/distributions/utils.rs:490:40 clippy::doc_markdown "you should put `f(x_i` between ticks in the documentation" +rand/0.7.3/src/distributions/utils.rs:490:49 clippy::doc_markdown "you should put `f(x_{i+1` between ticks in the documentation" +rand/0.7.3/src/distributions/utils.rs:518:17 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +rand/0.7.3/src/distributions/weibull.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/distributions/weighted/alias_method.rs:113:21 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" +rand/0.7.3/src/distributions/weighted/alias_method.rs:125:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rand/0.7.3/src/distributions/weighted/alias_method.rs:131:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rand/0.7.3/src/distributions/weighted/alias_method.rs:180:36 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +rand/0.7.3/src/distributions/weighted/alias_method.rs:182:34 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +rand/0.7.3/src/distributions/weighted/alias_method.rs:259:28 clippy::clone_on_copy "using `clone` on type `distributions::uniform::Uniform` which implements the `Copy` trait" +rand/0.7.3/src/distributions/weighted/alias_method.rs:296:9 clippy::map_clone "you are using an explicit closure for copying elements" +rand/0.7.3/src/distributions/weighted/alias_method.rs:321:9 clippy::map_clone "you are using an explicit closure for copying elements" +rand/0.7.3/src/distributions/weighted/alias_method.rs:78:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +rand/0.7.3/src/distributions/weighted/alias_method.rs:78:5 clippy::too_many_lines "this function has too many lines (106/100)" +rand/0.7.3/src/distributions/weighted/alias_method.rs:85:17 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +rand/0.7.3/src/distributions/weighted/alias_method.rs:87:31 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +rand/0.7.3/src/distributions/weighted/mod.rs:100:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +rand/0.7.3/src/distributions/weighted/mod.rs:144:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +rand/0.7.3/src/distributions/weighted/mod.rs:169:16 clippy::int_plus_one "unnecessary `>= y + 1` or `x - 1 >=`" +rand/0.7.3/src/distributions/weighted/mod.rs:386:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand/0.7.3/src/distributions/weighted/mod.rs:85:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand/0.7.3/src/lib.rs:333:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +rand/0.7.3/src/lib.rs:404:14 clippy::wrong_self_convention "methods called `to_*` usually take self by reference; consider choosing a less ambiguous name" +rand/0.7.3/src/lib.rs:552:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +rand/0.7.3/src/rngs/adapter/read.rs:47:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand/0.7.3/src/rngs/adapter/read.rs:89:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand/0.7.3/src/rngs/adapter/reseeding.rs:100:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +rand/0.7.3/src/rngs/adapter/reseeding.rs:112:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea" +rand/0.7.3/src/rngs/adapter/reseeding.rs:117:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea" +rand/0.7.3/src/rngs/adapter/reseeding.rs:198:13 clippy::cast_possible_wrap "casting `u64` to `i64` may wrap around the value" +rand/0.7.3/src/rngs/adapter/reseeding.rs:231:9 clippy::cast_possible_wrap "casting `usize` to `isize` may wrap around the value" +rand/0.7.3/src/rngs/adapter/reseeding.rs:27:28 clippy::doc_markdown "you should put `ChaCha` between ticks in the documentation" +rand/0.7.3/src/rngs/adapter/reseeding.rs:79:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand/0.7.3/src/rngs/entropy.rs:24:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand/0.7.3/src/rngs/entropy.rs:34:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/rngs/mock.rs:36:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/rngs/mock.rs:47:9 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +rand/0.7.3/src/rngs/mod.rs:61:74 clippy::doc_markdown "you should put `ChaCha20` between ticks in the documentation" +rand/0.7.3/src/rngs/std.rs:25:39 clippy::doc_markdown "you should put `ChaCha` between ticks in the documentation" +rand/0.7.3/src/rngs/std.rs:32:10 clippy::doc_markdown "you should put `rand_chacha` between ticks in the documentation" +rand/0.7.3/src/rngs/std.rs:36:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand/0.7.3/src/rngs/std.rs:39:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea" +rand/0.7.3/src/rngs/std.rs:44:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea" +rand/0.7.3/src/rngs/std.rs:49:5 clippy::inline_always "you have declared `#[inline(always)]` on `fill_bytes`. This is usually a bad idea" +rand/0.7.3/src/rngs/std.rs:54:5 clippy::inline_always "you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea" +rand/0.7.3/src/rngs/std.rs:63:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_seed`. This is usually a bad idea" +rand/0.7.3/src/rngs/std.rs:68:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_rng`. This is usually a bad idea" +rand/0.7.3/src/rngs/thread.rs:57:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand/0.7.3/src/rngs/thread.rs:80:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand/0.7.3/src/rngs/thread.rs:80:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +rand/0.7.3/src/rngs/thread.rs:81:35 clippy::redundant_closure_for_method_calls "redundant closure found" +rand/0.7.3/src/rngs/thread.rs:93:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea" +rand/0.7.3/src/rngs/thread.rs:98:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea" +rand/0.7.3/src/seq/index.rs:127:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand/0.7.3/src/seq/index.rs:139:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +rand/0.7.3/src/seq/index.rs:159:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand/0.7.3/src/seq/index.rs:171:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +rand/0.7.3/src/seq/index.rs:180:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +rand/0.7.3/src/seq/index.rs:223:18 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +rand/0.7.3/src/seq/index.rs:224:18 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +rand/0.7.3/src/seq/index.rs:233:25 clippy::cast_precision_loss "casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide)" +rand/0.7.3/src/seq/index.rs:236:27 clippy::cast_precision_loss "casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide)" +rand/0.7.3/src/seq/index.rs:244:12 clippy::cast_precision_loss "casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide)" +rand/0.7.3/src/seq/index.rs:244:37 clippy::cast_precision_loss "casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide)" +rand/0.7.3/src/seq/index.rs:29:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand/0.7.3/src/seq/index.rs:39:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/seq/index.rs:48:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/seq/index.rs:60:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/seq/index.rs:69:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/seq/index.rs:78:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/seq/index.rs:87:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/seq/index.rs:87:5 clippy::should_implement_trait "method `into_iter` can be confused for the standard trait method `std::iter::IntoIterator::into_iter`" +rand/0.7.3/src/seq/index.rs:97:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +rand/0.7.3/src/seq/mod.rs:141:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +rand/0.7.3/src/seq/mod.rs:168:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +rand/0.7.3/src/seq/mod.rs:229:4 clippy::needless_doctest_main "needless `fn main` in doctest" +rand/0.7.3/src/seq/mod.rs:292:29 clippy::cast_precision_loss "casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand/0.7.3/src/seq/mod.rs:410:23 clippy::default_trait_access "calling `std::marker::PhantomData::default()` is more clear than this expression" +rand/0.7.3/src/seq/mod.rs:45:4 clippy::needless_doctest_main "needless `fn main` in doctest" +rand/0.7.3/src/seq/mod.rs:527:26 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +rand_core/0.6.0/src/block.rs:117:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand_core/0.6.0/src/block.rs:153:5 clippy::inline_always "you have declared `#[inline(always)]` on `index`. This is usually a bad idea" +rand_core/0.6.0/src/block.rs:230:5 clippy::inline_always "you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea" +rand_core/0.6.0/src/block.rs:240:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_seed`. This is usually a bad idea" +rand_core/0.6.0/src/block.rs:245:5 clippy::inline_always "you have declared `#[inline(always)]` on `seed_from_u64`. This is usually a bad idea" +rand_core/0.6.0/src/block.rs:250:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_rng`. This is usually a bad idea" +rand_core/0.6.0/src/block.rs:280:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand_core/0.6.0/src/block.rs:319:5 clippy::inline_always "you have declared `#[inline(always)]` on `index`. This is usually a bad idea" +rand_core/0.6.0/src/block.rs:405:5 clippy::inline_always "you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea" +rand_core/0.6.0/src/block.rs:415:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_seed`. This is usually a bad idea" +rand_core/0.6.0/src/block.rs:420:5 clippy::inline_always "you have declared `#[inline(always)]` on `seed_from_u64`. This is usually a bad idea" +rand_core/0.6.0/src/block.rs:425:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_rng`. This is usually a bad idea" +rand_core/0.6.0/src/block.rs:67:14 clippy::doc_markdown "you should put `module][crate::block` between ticks in the documentation" +rand_core/0.6.0/src/block.rs:68:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand_core/0.6.0/src/error.rs:106:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand_core/0.6.0/src/error.rs:87:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand_core/0.6.0/src/error.rs:95:74 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +rand_core/0.6.0/src/lib.rs:179:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +rand_core/0.6.0/src/lib.rs:301:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand_core/0.6.0/src/lib.rs:303:26 clippy::unreadable_literal "long literal lacking separators" +rand_core/0.6.0/src/lib.rs:304:26 clippy::unreadable_literal "long literal lacking separators" +rand_core/0.6.0/src/lib.rs:313:30 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +rand_core/0.6.0/src/lib.rs:314:23 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +rand_core/0.6.0/src/lib.rs:346:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +rand_core/0.6.0/src/lib.rs:381:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea" +rand_core/0.6.0/src/lib.rs:386:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea" +rand_core/0.6.0/src/lib.rs:391:5 clippy::inline_always "you have declared `#[inline(always)]` on `fill_bytes`. This is usually a bad idea" +rand_core/0.6.0/src/lib.rs:396:5 clippy::inline_always "you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea" +rayon/1.5.0/src/collections/binary_heap.rs:7:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/collections/binary_heap.rs:8:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/collections/btree_map.rs:7:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/collections/btree_map.rs:8:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/collections/btree_set.rs:7:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/collections/btree_set.rs:8:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/collections/hash_map.rs:10:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/collections/hash_map.rs:9:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/collections/hash_set.rs:10:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/collections/hash_set.rs:9:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/collections/linked_list.rs:7:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/collections/linked_list.rs:8:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/collections/mod.rs:59:32 clippy::mem_replace_with_default "replacing a value of type `T` with `T::default()` is better expressed using `std::mem::take`" +rayon/1.5.0/src/collections/vec_deque.rs:8:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/collections/vec_deque.rs:9:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/compile_fail/cannot_collect_filtermap_data.rs:2:1 clippy::needless_doctest_main "needless `fn main` in doctest" +rayon/1.5.0/src/compile_fail/cannot_zip_filtered_data.rs:2:1 clippy::needless_doctest_main "needless `fn main` in doctest" +rayon/1.5.0/src/compile_fail/cell_par_iter.rs:2:1 clippy::needless_doctest_main "needless `fn main` in doctest" +rayon/1.5.0/src/compile_fail/no_send_par_iter.rs:25:1 clippy::needless_doctest_main "needless `fn main` in doctest" +rayon/1.5.0/src/compile_fail/no_send_par_iter.rs:46:1 clippy::needless_doctest_main "needless `fn main` in doctest" +rayon/1.5.0/src/compile_fail/no_send_par_iter.rs:4:1 clippy::needless_doctest_main "needless `fn main` in doctest" +rayon/1.5.0/src/compile_fail/rc_par_iter.rs:2:1 clippy::needless_doctest_main "needless `fn main` in doctest" +rayon/1.5.0/src/iter/chain.rs:103:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/chain.rs:122:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/chain.rs:128:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/chain.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/chain.rs:221:36 clippy::doc_markdown "you should put `ExactSizeIterator` between ticks in the documentation" +rayon/1.5.0/src/iter/chain.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/chain.rs:51:38 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" +rayon/1.5.0/src/iter/chain.rs:58:14 clippy::shadow_unrelated "`a` is being shadowed" +rayon/1.5.0/src/iter/chain.rs:58:17 clippy::shadow_unrelated "`b` is being shadowed" +rayon/1.5.0/src/iter/chain.rs:78:14 clippy::shadow_unrelated "`a` is being shadowed" +rayon/1.5.0/src/iter/chain.rs:78:17 clippy::shadow_unrelated "`b` is being shadowed" +rayon/1.5.0/src/iter/chain.rs:97:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/chunks.rs:3:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/chunks.rs:4:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/chunks.rs:77:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/chunks.rs:83:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/cloned.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/cloned.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/cloned.rs:71:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/cloned.rs:75:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/collect/consumer.rs:141:5 clippy::doc_markdown "you should put `CollectReducer` between ticks in the documentation" +rayon/1.5.0/src/iter/collect/consumer.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/collect/consumer.rs:28:5 clippy::doc_markdown "you should put `CollectResult` between ticks in the documentation" +rayon/1.5.0/src/iter/collect/consumer.rs:36:37 clippy::mut_mut "generally you want to avoid `&mut &mut _` if possible" +rayon/1.5.0/src/iter/collect/consumer.rs:36:37 clippy::mut_mut "generally you want to avoid `&mut &mut _` if possible" +rayon/1.5.0/src/iter/collect/mod.rs:154:9 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +rayon/1.5.0/src/iter/copied.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/copied.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/copied.rs:71:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/copied.rs:75:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/empty.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/empty.rs:24:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +rayon/1.5.0/src/iter/empty.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/enumerate.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/enumerate.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/enumerate.rs:64:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/enumerate.rs:68:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/extend.rs:143:63 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon/1.5.0/src/iter/extend.rs:182:57 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon/1.5.0/src/iter/extend.rs:218:32 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon/1.5.0/src/iter/extend.rs:218:59 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon/1.5.0/src/iter/extend.rs:25:42 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon/1.5.0/src/iter/extend.rs:287:62 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon/1.5.0/src/iter/extend.rs:322:56 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon/1.5.0/src/iter/extend.rs:41:27 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon/1.5.0/src/iter/extend.rs:47:30 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon/1.5.0/src/iter/extend.rs:47:56 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon/1.5.0/src/iter/extend.rs:47:74 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon/1.5.0/src/iter/extend.rs:53:29 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon/1.5.0/src/iter/extend.rs:57:36 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon/1.5.0/src/iter/extend.rs:59:61 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon/1.5.0/src/iter/filter.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/filter.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/filter_map.rs:123:9 clippy::option_if_let_else "use Option::map_or instead of an if let/else" +rayon/1.5.0/src/iter/filter_map.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/filter_map.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/find.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/find.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/find_first_last/mod.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/find_first_last/mod.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/find_first_last/mod.rs:32:67 clippy::doc_markdown "you should put `MatchPosition` between ticks in the documentation" +rayon/1.5.0/src/iter/flat_map.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/flat_map.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/flat_map_iter.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/flat_map_iter.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/flatten.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/flatten.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/flatten_iter.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/flatten_iter.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/fold.rs:158:13 clippy::similar_names "binding's name is too similar to existing binding" +rayon/1.5.0/src/iter/fold.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/fold.rs:204:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rayon/1.5.0/src/iter/fold.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/for_each.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/for_each.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/inspect.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/inspect.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/inspect.rs:83:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/inspect.rs:88:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/interleave.rs:111:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/interleave.rs:119:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/interleave.rs:195:30 clippy::doc_markdown "you should put `self.i_len` between ticks in the documentation" +rayon/1.5.0/src/iter/interleave.rs:195:43 clippy::doc_markdown "you should put `self.j_len` between ticks in the documentation" +rayon/1.5.0/src/iter/interleave.rs:199:23 clippy::doc_markdown "you should put `self.i_len` between ticks in the documentation" +rayon/1.5.0/src/iter/interleave.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/interleave.rs:200:23 clippy::doc_markdown "you should put `self.j_len` between ticks in the documentation" +rayon/1.5.0/src/iter/interleave.rs:249:41 clippy::doc_markdown "you should put `DoubleEndedIterator` between ticks in the documentation" +rayon/1.5.0/src/iter/interleave.rs:250:5 clippy::doc_markdown "you should put `ExactSizeIterator` between ticks in the documentation" +rayon/1.5.0/src/iter/interleave.rs:263:33 clippy::doc_markdown "you should put `InterleaveSeq` between ticks in the documentation" +rayon/1.5.0/src/iter/interleave.rs:280:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +rayon/1.5.0/src/iter/interleave.rs:285:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +rayon/1.5.0/src/iter/interleave.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/interleave.rs:313:9 clippy::comparison_chain "`if` chain can be rewritten with `match`" +rayon/1.5.0/src/iter/interleave.rs:82:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/interleave.rs:90:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/interleave_shortest.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/intersperse.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/intersperse.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/intersperse.rs:90:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/intersperse.rs:96:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/len.rs:12:1 clippy::module_name_repetitions "item name ends with its containing module's name" +rayon/1.5.0/src/iter/len.rs:146:1 clippy::module_name_repetitions "item name ends with its containing module's name" +rayon/1.5.0/src/iter/len.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/len.rs:200:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/len.rs:205:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/len.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/len.rs:66:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/len.rs:71:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/map.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/map.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/map.rs:84:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/map.rs:89:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/map_with.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/map_with.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/map_with.rs:419:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/map_with.rs:425:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/map_with.rs:90:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/map_with.rs:96:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/mod.rs:1874:24 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +rayon/1.5.0/src/iter/mod.rs:2171:1 clippy::len_without_is_empty "trait `IndexedParallelIterator` has a `len` method but no (possibly inherited) `is_empty` method" +rayon/1.5.0/src/iter/mod.rs:2371:26 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +rayon/1.5.0/src/iter/mod.rs:2411:26 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +rayon/1.5.0/src/iter/mod.rs:82:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/multizip.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/multizip.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/noop.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/once.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/once.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/panic_fuse.rs:102:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/panic_fuse.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/panic_fuse.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/panic_fuse.rs:98:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/par_bridge.rs:136:28 clippy::redundant_else "redundant else block" +rayon/1.5.0/src/iter/par_bridge.rs:163:28 clippy::redundant_else "redundant else block" +rayon/1.5.0/src/iter/plumbing/mod.rs:216:58 clippy::doc_markdown "you should put `find_first` between ticks in the documentation" +rayon/1.5.0/src/iter/plumbing/mod.rs:359:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/plumbing/mod.rs:364:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/plumbing/mod.rs:399:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/plumbing/mod.rs:53:19 clippy::doc_markdown "you should put `DoubleEndedIterator` between ticks in the documentation" +rayon/1.5.0/src/iter/plumbing/mod.rs:53:43 clippy::doc_markdown "you should put `ExactSizeIterator` between ticks in the documentation" +rayon/1.5.0/src/iter/plumbing/mod.rs:54:31 clippy::doc_markdown "you should put `IntoIterator` between ticks in the documentation" +rayon/1.5.0/src/iter/plumbing/mod.rs:55:5 clippy::doc_markdown "you should put `IntoIterator` between ticks in the documentation" +rayon/1.5.0/src/iter/positions.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/positions.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/product.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/reduce.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/repeat.rs:103:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rayon/1.5.0/src/iter/repeat.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/repeat.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/rev.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/rev.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/rev.rs:63:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/rev.rs:68:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/skip.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/skip.rs:3:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/skip.rs:68:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/skip.rs:73:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/splitter.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/splitter.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/step_by.rs:4:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/step_by.rs:5:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/step_by.rs:73:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/step_by.rs:79:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/sum.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/take.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/take.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/take.rs:67:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/take.rs:72:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/try_fold.rs:190:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rayon/1.5.0/src/iter/try_fold.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/try_fold.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/try_reduce.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/try_reduce_with.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/unzip.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/unzip.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/update.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/update.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/update.rs:82:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/update.rs:87:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/while_some.rs:130:22 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +rayon/1.5.0/src/iter/while_some.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/while_some.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/zip.rs:102:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/zip.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/zip.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/zip.rs:74:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/zip.rs:79:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/zip.rs:97:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/zip_eq.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/zip_eq.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/option.rs:8:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/option.rs:9:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/par_either.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/par_either.rs:3:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/private.rs:9:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rayon/1.5.0/src/range.rs:19:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/range.rs:20:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/range_inclusive.rs:194:9 clippy::range_plus_one "an inclusive range would be more readable" +rayon/1.5.0/src/range_inclusive.rs:194:9 clippy::range_plus_one "an inclusive range would be more readable" +rayon/1.5.0/src/range_inclusive.rs:19:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/range_inclusive.rs:209:9 clippy::range_plus_one "an inclusive range would be more readable" +rayon/1.5.0/src/range_inclusive.rs:209:9 clippy::range_plus_one "an inclusive range would be more readable" +rayon/1.5.0/src/range_inclusive.rs:20:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/range_inclusive.rs:231:9 clippy::range_plus_one "an inclusive range would be more readable" +rayon/1.5.0/src/range_inclusive.rs:231:9 clippy::range_plus_one "an inclusive range would be more readable" +rayon/1.5.0/src/result.rs:8:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/result.rs:9:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/slice/mergesort.rs:102:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/slice/mergesort.rs:109:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/slice/mergesort.rs:114:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/slice/mergesort.rs:211:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/slice/mergesort.rs:217:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/slice/mergesort.rs:251:5 clippy::doc_markdown "you should put `TimSort` between ticks in the documentation" +rayon/1.5.0/src/slice/mergesort.rs:252:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +rayon/1.5.0/src/slice/mergesort.rs:286:59 clippy::doc_markdown "you should put `TimSort` between ticks in the documentation" +rayon/1.5.0/src/slice/mergesort.rs:333:24 clippy::redundant_else "redundant else block" +rayon/1.5.0/src/slice/mergesort.rs:513:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/slice/mergesort.rs:521:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/slice/mergesort.rs:7:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/slice/mergesort.rs:98:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/slice/mod.rs:15:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/slice/mod.rs:16:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/slice/mod.rs:17:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/slice/mod.rs:25:1 clippy::module_name_repetitions "item name ends with its containing module's name" +rayon/1.5.0/src/slice/mod.rs:657:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rayon/1.5.0/src/slice/mod.rs:971:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rayon/1.5.0/src/slice/quicksort.rs:230:36 clippy::doc_markdown "you should put `BlockQuicksort` between ticks in the documentation" +rayon/1.5.0/src/slice/quicksort.rs:233:1 clippy::too_many_lines "this function has too many lines (117/100)" +rayon/1.5.0/src/slice/quicksort.rs:258:26 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +rayon/1.5.0/src/slice/quicksort.rs:265:26 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +rayon/1.5.0/src/slice/quicksort.rs:268:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/slice/quicksort.rs:308:30 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" +rayon/1.5.0/src/slice/quicksort.rs:325:30 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" +rayon/1.5.0/src/slice/quicksort.rs:393:36 clippy::cast_possible_wrap "casting `u8` to `isize` may wrap around the value on targets with 32-bit wide pointers" +rayon/1.5.0/src/slice/quicksort.rs:405:40 clippy::cast_possible_wrap "casting `u8` to `isize` may wrap around the value on targets with 32-bit wide pointers" +rayon/1.5.0/src/slice/quicksort.rs:430:14 clippy::shadow_unrelated "`pivot` is being shadowed" +rayon/1.5.0/src/slice/quicksort.rs:439:13 clippy::shadow_unrelated "`pivot` is being shadowed" +rayon/1.5.0/src/slice/quicksort.rs:482:10 clippy::shadow_unrelated "`pivot` is being shadowed" +rayon/1.5.0/src/slice/quicksort.rs:491:9 clippy::shadow_unrelated "`pivot` is being shadowed" +rayon/1.5.0/src/slice/quicksort.rs:534:26 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +rayon/1.5.0/src/slice/quicksort.rs:545:17 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +rayon/1.5.0/src/slice/quicksort.rs:588:17 clippy::identity_op "the operation is ineffective. Consider reducing it to `len / 4`" +rayon/1.5.0/src/slice/quicksort.rs:716:14 clippy::shadow_unrelated "`pivot` is being shadowed" +rayon/1.5.0/src/split_producer.rs:56:16 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" +rayon/1.5.0/src/split_producer.rs:92:9 clippy::option_if_let_else "use Option::map_or instead of an if let/else" +rayon/1.5.0/src/str.rs:16:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/str.rs:17:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/str.rs:18:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/str.rs:25:5 clippy::cast_possible_wrap "casting `u8` to `i8` may wrap around the value" +rayon/1.5.0/src/str.rs:715:9 clippy::manual_strip "stripping a suffix manually" +rayon/1.5.0/src/string.rs:5:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/vec.rs:137:12 clippy::len_zero "length comparison to zero" +rayon/1.5.0/src/vec.rs:8:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/vec.rs:9:5 clippy::wildcard_imports "usage of wildcard import" +regex/1.3.2/src/backtrack.rs:100:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/backtrack.rs:133:17 clippy::same_item_push "it looks like the same item is being pushed into this Vec" +regex/1.3.2/src/backtrack.rs:145:20 clippy::if_not_else "unnecessary boolean `not` operation" +regex/1.3.2/src/backtrack.rs:199:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/backtrack.rs:223:29 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/backtrack.rs:230:66 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/backtrack.rs:284:21 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" +regex/1.3.2/src/backtrack.rs:287:5 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex/1.3.2/src/backtrack.rs:97:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/backtrack.rs:98:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/backtrack.rs:99:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:1005:32 clippy::unreadable_literal "long literal lacking separators" +regex/1.3.2/src/compile.rs:1006:21 clippy::unreadable_literal "long literal lacking separators" +regex/1.3.2/src/compile.rs:1008:18 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" +regex/1.3.2/src/compile.rs:1009:18 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" +regex/1.3.2/src/compile.rs:1010:9 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +regex/1.3.2/src/compile.rs:102:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/compile.rs:1037:37 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" +regex/1.3.2/src/compile.rs:1037:55 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" +regex/1.3.2/src/compile.rs:1040:28 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" +regex/1.3.2/src/compile.rs:1040:38 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" +regex/1.3.2/src/compile.rs:1051:25 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +regex/1.3.2/src/compile.rs:1071:8 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" +regex/1.3.2/src/compile.rs:112:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +regex/1.3.2/src/compile.rs:154:30 clippy::redundant_closure_for_method_calls "redundant closure found" +regex/1.3.2/src/compile.rs:156:30 clippy::redundant_closure_for_method_calls "redundant closure found" +regex/1.3.2/src/compile.rs:185:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +regex/1.3.2/src/compile.rs:187:40 clippy::redundant_closure_for_method_calls "redundant closure found" +regex/1.3.2/src/compile.rs:201:53 clippy::doc_markdown "you should put `MaybeInsts` between ticks in the documentation" +regex/1.3.2/src/compile.rs:241:63 clippy::doc_markdown "you should put `c_concat` between ticks in the documentation" +regex/1.3.2/src/compile.rs:245:5 clippy::too_many_lines "this function has too many lines (111/100)" +regex/1.3.2/src/compile.rs:247:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/compile.rs:373:24 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:373:36 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:378:12 clippy::if_not_else "unnecessary boolean `not` operation" +regex/1.3.2/src/compile.rs:400:37 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:407:51 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:409:24 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:417:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +regex/1.3.2/src/compile.rs:42:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/compile.rs:42:5 clippy::new_without_default "you should consider adding a `Default` implementation for `compile::Compiler`" +regex/1.3.2/src/compile.rs:444:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +regex/1.3.2/src/compile.rs:445:57 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:446:20 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:466:20 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:466:32 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:519:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/compile.rs:55:57 clippy::doc_markdown "you should put `size_limit` between ticks in the documentation" +regex/1.3.2/src/compile.rs:58:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/compile.rs:748:41 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:74:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/compile.rs:751:54 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:765:41 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:765:55 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:825:39 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:825:51 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:828:49 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:828:61 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:830:59 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:830:71 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:832:43 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:835:41 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:835:53 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:835:67 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:83:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/compile.rs:896:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +regex/1.3.2/src/compile.rs:905:17 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:953:17 clippy::doc_markdown "you should put `HashMap` between ticks in the documentation" +regex/1.3.2/src/compile.rs:95:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/compile.rs:980:26 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +regex/1.3.2/src/compile.rs:994:44 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:994:54 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/dfa.rs:1007:17 clippy::similar_names "binding's name is too similar to existing binding" +regex/1.3.2/src/dfa.rs:1010:22 clippy::similar_names "binding's name is too similar to existing binding" +regex/1.3.2/src/dfa.rs:1059:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/dfa.rs:1060:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/dfa.rs:1084:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex/1.3.2/src/dfa.rs:1087:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex/1.3.2/src/dfa.rs:1090:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex/1.3.2/src/dfa.rs:1093:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex/1.3.2/src/dfa.rs:1096:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex/1.3.2/src/dfa.rs:1101:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex/1.3.2/src/dfa.rs:1104:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex/1.3.2/src/dfa.rs:1107:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex/1.3.2/src/dfa.rs:1117:30 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex/1.3.2/src/dfa.rs:1120:47 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex/1.3.2/src/dfa.rs:1121:30 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex/1.3.2/src/dfa.rs:1129:13 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" +regex/1.3.2/src/dfa.rs:1134:13 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" +regex/1.3.2/src/dfa.rs:1185:68 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" +regex/1.3.2/src/dfa.rs:1193:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/dfa.rs:1244:50 clippy::doc_markdown "you should put `current_state` between ticks in the documentation" +regex/1.3.2/src/dfa.rs:1338:58 clippy::doc_markdown "you should put `STATE_DEAD` between ticks in the documentation" +regex/1.3.2/src/dfa.rs:1339:9 clippy::doc_markdown "you should put `STATE_UNKNOWN` between ticks in the documentation" +regex/1.3.2/src/dfa.rs:1366:25 clippy::doc_markdown "you should put `STATE_DEAD` between ticks in the documentation" +regex/1.3.2/src/dfa.rs:1366:46 clippy::doc_markdown "you should put `STATE_UNKNOWN` between ticks in the documentation" +regex/1.3.2/src/dfa.rs:1367:41 clippy::inline_always "you have declared `#[inline(always)]` on `start_state`. This is usually a bad idea" +regex/1.3.2/src/dfa.rs:1380:14 clippy::identity_op "the operation is ineffective. Consider reducing it to `(empty_flags.start as u8)`" +regex/1.3.2/src/dfa.rs:1388:15 clippy::match_on_vec_items "indexing into a vector may panic" +regex/1.3.2/src/dfa.rs:1412:20 clippy::unused_self "unused `self` argument" +regex/1.3.2/src/dfa.rs:1438:9 clippy::unused_self "unused `self` argument" +regex/1.3.2/src/dfa.rs:1472:9 clippy::doc_markdown "you should put `StatePtr` between ticks in the documentation" +regex/1.3.2/src/dfa.rs:1490:54 clippy::cast_possible_truncation "casting `i32` to `u8` may truncate the value" +regex/1.3.2/src/dfa.rs:1490:54 clippy::cast_sign_loss "casting `i32` to `u8` may lose the sign of the value" +regex/1.3.2/src/dfa.rs:1521:20 clippy::doc_markdown "you should put `num_byte_classes` between ticks in the documentation" +regex/1.3.2/src/dfa.rs:1529:41 clippy::inline_always "you have declared `#[inline(always)]` on `byte_class`. This is usually a bad idea" +regex/1.3.2/src/dfa.rs:1537:14 clippy::doc_markdown "you should put `byte_class` between ticks in the documentation" +regex/1.3.2/src/dfa.rs:1538:41 clippy::inline_always "you have declared `#[inline(always)]` on `u8_class`. This is usually a bad idea" +regex/1.3.2/src/dfa.rs:1562:18 clippy::doc_markdown "you should put `STATE_START` between ticks in the documentation" +regex/1.3.2/src/dfa.rs:1614:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/dfa.rs:1651:38 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/dfa.rs:1700:17 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +regex/1.3.2/src/dfa.rs:1701:18 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex/1.3.2/src/dfa.rs:1705:19 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex/1.3.2/src/dfa.rs:1708:16 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +regex/1.3.2/src/dfa.rs:1709:18 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex/1.3.2/src/dfa.rs:1713:19 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex/1.3.2/src/dfa.rs:1716:18 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +regex/1.3.2/src/dfa.rs:1717:18 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex/1.3.2/src/dfa.rs:1721:19 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex/1.3.2/src/dfa.rs:1727:14 clippy::cast_lossless "casting `u8` to `u16` may become silently lossy if you later change the type" +regex/1.3.2/src/dfa.rs:1732:15 clippy::trivially_copy_pass_by_ref "this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +regex/1.3.2/src/dfa.rs:1736:22 clippy::trivially_copy_pass_by_ref "this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +regex/1.3.2/src/dfa.rs:1741:9 clippy::match_like_matches_macro "match expression looks like `matches!` macro" +regex/1.3.2/src/dfa.rs:1747:16 clippy::trivially_copy_pass_by_ref "this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +regex/1.3.2/src/dfa.rs:1751:18 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" +regex/1.3.2/src/dfa.rs:1815:38 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" +regex/1.3.2/src/dfa.rs:1821:21 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" +regex/1.3.2/src/dfa.rs:1824:5 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex/1.3.2/src/dfa.rs:1848:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +regex/1.3.2/src/dfa.rs:1850:18 clippy::cast_sign_loss "casting `i32` to `u32` may lose the sign of the value" +regex/1.3.2/src/dfa.rs:1857:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +regex/1.3.2/src/dfa.rs:1860:17 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +regex/1.3.2/src/dfa.rs:1867:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +regex/1.3.2/src/dfa.rs:1870:19 clippy::cast_possible_truncation "casting `u32` to `u8` may truncate the value" +regex/1.3.2/src/dfa.rs:1873:15 clippy::cast_possible_truncation "casting `u32` to `u8` may truncate the value" +regex/1.3.2/src/dfa.rs:1876:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +regex/1.3.2/src/dfa.rs:1882:26 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +regex/1.3.2/src/dfa.rs:1884:15 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +regex/1.3.2/src/dfa.rs:277:17 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +regex/1.3.2/src/dfa.rs:277:31 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +regex/1.3.2/src/dfa.rs:295:20 clippy::cast_possible_truncation "casting `usize` to `i32` may truncate the value on targets with 64-bit wide pointers" +regex/1.3.2/src/dfa.rs:295:20 clippy::cast_possible_wrap "casting `usize` to `i32` may wrap around the value on targets with 32-bit wide pointers" +regex/1.3.2/src/dfa.rs:299:21 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" +regex/1.3.2/src/dfa.rs:34:46 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +regex/1.3.2/src/dfa.rs:398:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +regex/1.3.2/src/dfa.rs:446:41 clippy::inline_always "you have declared `#[inline(always)]` on `forward`. This is usually a bad idea" +regex/1.3.2/src/dfa.rs:457:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/dfa.rs:459:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/dfa.rs:460:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/dfa.rs:476:41 clippy::inline_always "you have declared `#[inline(always)]` on `reverse`. This is usually a bad idea" +regex/1.3.2/src/dfa.rs:487:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/dfa.rs:489:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/dfa.rs:490:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/dfa.rs:506:41 clippy::inline_always "you have declared `#[inline(always)]` on `forward_many`. This is usually a bad idea" +regex/1.3.2/src/dfa.rs:518:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/dfa.rs:520:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/dfa.rs:554:41 clippy::inline_always "you have declared `#[inline(always)]` on `exec_at`. This is usually a bad idea" +regex/1.3.2/src/dfa.rs:555:5 clippy::too_many_lines "this function has too many lines (101/100)" +regex/1.3.2/src/dfa.rs:58:9 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/dfa.rs:667:21 clippy::similar_names "binding's name is too similar to existing binding" +regex/1.3.2/src/dfa.rs:747:41 clippy::inline_always "you have declared `#[inline(always)]` on `exec_at_reverse`. This is usually a bad idea" +regex/1.3.2/src/dfa.rs:795:21 clippy::similar_names "binding's name is too similar to existing binding" +regex/1.3.2/src/dfa.rs:848:9 clippy::doc_markdown "you should put `next_si` between ticks in the documentation" +regex/1.3.2/src/dfa.rs:852:41 clippy::inline_always "you have declared `#[inline(always)]` on `next_si`. This is usually a bad idea" +regex/1.3.2/src/dfa.rs:885:12 clippy::doc_markdown "you should put `STATE_DEAD` between ticks in the documentation" +regex/1.3.2/src/dfa.rs:889:9 clippy::doc_markdown "you should put `STATE_UNKNOWN` between ticks in the documentation" +regex/1.3.2/src/dfa.rs:897:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/dfa.rs:979:29 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex/1.3.2/src/error.rs:6:1 clippy::manual_non_exhaustive "this seems like a manual implementation of the non-exhaustive pattern" +regex/1.3.2/src/exec.rs:1000:14 clippy::doc_markdown "you should put `captures_nfa` between ticks in the documentation" +regex/1.3.2/src/exec.rs:100:1 clippy::module_name_repetitions "item name starts with its containing module's name" +regex/1.3.2/src/exec.rs:1028:5 clippy::too_many_arguments "this function has too many arguments (9/7)" +regex/1.3.2/src/exec.rs:1039:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/exec.rs:1144:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/exec.rs:1179:26 clippy::match_same_arms "this `match` has identical arm bodies" +regex/1.3.2/src/exec.rs:122:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/exec.rs:1250:41 clippy::inline_always "you have declared `#[inline(always)]` on `searcher`. This is usually a bad idea" +regex/1.3.2/src/exec.rs:1260:41 clippy::inline_always "you have declared `#[inline(always)]` on `searcher_str`. This is usually a bad idea" +regex/1.3.2/src/exec.rs:1270:17 clippy::doc_markdown "you should put `RegexSet` between ticks in the documentation" +regex/1.3.2/src/exec.rs:1280:17 clippy::doc_markdown "you should put `RegexSet` between ticks in the documentation" +regex/1.3.2/src/exec.rs:137:9 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" +regex/1.3.2/src/exec.rs:142:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/exec.rs:158:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/exec.rs:168:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/exec.rs:181:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/exec.rs:195:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/exec.rs:204:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/exec.rs:210:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/exec.rs:245:62 clippy::if_same_then_else "this `if` has identical blocks" +regex/1.3.2/src/exec.rs:251:21 clippy::if_not_else "unnecessary boolean `not` operation" +regex/1.3.2/src/exec.rs:262:60 clippy::if_same_then_else "this `if` has identical blocks" +regex/1.3.2/src/exec.rs:268:21 clippy::if_not_else "unnecessary boolean `not` operation" +regex/1.3.2/src/exec.rs:278:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/exec.rs:281:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/exec.rs:286:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +regex/1.3.2/src/exec.rs:300:30 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/exec.rs:308:17 clippy::similar_names "binding's name is too similar to existing binding" +regex/1.3.2/src/exec.rs:329:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/exec.rs:330:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/exec.rs:331:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/exec.rs:334:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/exec.rs:340:19 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/exec.rs:344:27 clippy::unused_self "unused `self` argument" +regex/1.3.2/src/exec.rs:383:41 clippy::inline_always "you have declared `#[inline(always)]` on `shortest_match_at`. This is usually a bad idea" +regex/1.3.2/src/exec.rs:388:41 clippy::inline_always "you have declared `#[inline(always)]` on `is_match_at`. This is usually a bad idea" +regex/1.3.2/src/exec.rs:393:41 clippy::inline_always "you have declared `#[inline(always)]` on `find_at`. This is usually a bad idea" +regex/1.3.2/src/exec.rs:398:41 clippy::inline_always "you have declared `#[inline(always)]` on `captures_read_at`. This is usually a bad idea" +regex/1.3.2/src/exec.rs:425:41 clippy::inline_always "you have declared `#[inline(always)]` on `shortest_match_at`. This is usually a bad idea" +regex/1.3.2/src/exec.rs:44:1 clippy::module_name_repetitions "item name starts with its containing module's name" +regex/1.3.2/src/exec.rs:473:9 clippy::doc_markdown "you should put `shortest_match(...).is_some` between ticks in the documentation" +regex/1.3.2/src/exec.rs:474:41 clippy::inline_always "you have declared `#[inline(always)]` on `is_match_at`. This is usually a bad idea" +regex/1.3.2/src/exec.rs:524:41 clippy::inline_always "you have declared `#[inline(always)]` on `find_at`. This is usually a bad idea" +regex/1.3.2/src/exec.rs:52:1 clippy::module_name_repetitions "item name starts with its containing module's name" +regex/1.3.2/src/exec.rs:686:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/exec.rs:727:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/exec.rs:767:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/exec.rs:783:41 clippy::inline_always "you have declared `#[inline(always)]` on `shortest_dfa`. This is usually a bad idea" +regex/1.3.2/src/exec.rs:791:41 clippy::inline_always "you have declared `#[inline(always)]` on `shortest_dfa_reverse_suffix`. This is usually a bad idea" +regex/1.3.2/src/exec.rs:823:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/exec.rs:868:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/exec.rs:897:31 clippy::doc_markdown "you should put `shortest_nfa(...).is_some` between ticks in the documentation" +regex/1.3.2/src/exec.rs:899:9 clippy::doc_markdown "you should put `shortest_nfa` between ticks in the documentation" +regex/1.3.2/src/exec.rs:905:14 clippy::doc_markdown "you should put `match_nfa` between ticks in the documentation" +regex/1.3.2/src/exec.rs:930:14 clippy::doc_markdown "you should put `shortest_nfa` between ticks in the documentation" +regex/1.3.2/src/exec.rs:981:14 clippy::doc_markdown "you should put `find_nfa` between ticks in the documentation" +regex/1.3.2/src/expand.rs:170:27 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +regex/1.3.2/src/expand.rs:171:5 clippy::match_like_matches_macro "match expression looks like `matches!` macro" +regex/1.3.2/src/expand.rs:22:13 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +regex/1.3.2/src/expand.rs:27:23 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +regex/1.3.2/src/expand.rs:30:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +regex/1.3.2/src/expand.rs:38:30 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +regex/1.3.2/src/expand.rs:42:21 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +regex/1.3.2/src/expand.rs:50:1 clippy::module_name_repetitions "item name starts with its containing module's name" +regex/1.3.2/src/expand.rs:69:23 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +regex/1.3.2/src/expand.rs:80:28 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +regex/1.3.2/src/expand.rs:84:21 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +regex/1.3.2/src/expand.rs:8:1 clippy::module_name_repetitions "item name starts with its containing module's name" +regex/1.3.2/src/input.rs:142:1 clippy::module_name_repetitions "item name ends with its containing module's name" +regex/1.3.2/src/input.rs:146:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/input.rs:15:1 clippy::module_name_repetitions "item name starts with its containing module's name" +regex/1.3.2/src/input.rs:165:31 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/input.rs:178:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/input.rs:228:1 clippy::module_name_repetitions "item name ends with its containing module's name" +regex/1.3.2/src/input.rs:236:21 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/input.rs:236:33 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/input.rs:24:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/input.rs:271:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/input.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/input.rs:362:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/input.rs:370:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/input.rs:371:42 clippy::redundant_closure_for_method_calls "redundant closure found" +regex/1.3.2/src/input.rs:37:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/input.rs:388:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/input.rs:42:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/input.rs:47:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/input.rs:53:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/input.rs:58:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/input.rs:63:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/lib.rs:1:null clippy::cargo_common_metadata "package `regex` is missing `package.keywords` metadata" +regex/1.3.2/src/literal/imp.rs:101:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/literal/imp.rs:114:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/literal/imp.rs:127:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/literal/imp.rs:139:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/literal/imp.rs:144:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/literal/imp.rs:149:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/literal/imp.rs:154:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/literal/imp.rs:155:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/literal/imp.rs:160:30 clippy::match_same_arms "this `match` has identical arm bodies" +regex/1.3.2/src/literal/imp.rs:167:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/literal/imp.rs:168:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/literal/imp.rs:211:20 clippy::redundant_else "redundant else block" +regex/1.3.2/src/literal/imp.rs:276:50 clippy::match_same_arms "this `match` has identical arm bodies" +regex/1.3.2/src/literal/imp.rs:342:41 clippy::inline_always "you have declared `#[inline(always)]` on `find`. This is usually a bad idea" +regex/1.3.2/src/literal/imp.rs:435:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/literal/imp.rs:436:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/literal/imp.rs:437:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/literal/imp.rs:438:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/literal/imp.rs:439:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/literal/imp.rs:440:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/literal/imp.rs:455:41 clippy::inline_always "you have declared `#[inline(always)]` on `find`. This is usually a bad idea" +regex/1.3.2/src/literal/imp.rs:46:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/literal/imp.rs:481:41 clippy::inline_always "you have declared `#[inline(always)]` on `is_suffix`. This is usually a bad idea" +regex/1.3.2/src/literal/imp.rs:51:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/literal/imp.rs:579:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/literal/imp.rs:57:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/literal/imp.rs:580:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/literal/imp.rs:583:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/literal/imp.rs:602:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +regex/1.3.2/src/literal/imp.rs:622:24 clippy::redundant_else "redundant else block" +regex/1.3.2/src/literal/imp.rs:62:18 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +regex/1.3.2/src/literal/imp.rs:637:24 clippy::redundant_else "redundant else block" +regex/1.3.2/src/literal/imp.rs:648:9 clippy::needless_return "unneeded `return` statement" +regex/1.3.2/src/literal/imp.rs:651:44 clippy::doc_markdown "you should put `BoyerMooreSearch` between ticks in the documentation" +regex/1.3.2/src/literal/imp.rs:65:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/literal/imp.rs:68:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/literal/imp.rs:783:32 clippy::redundant_else "redundant else block" +regex/1.3.2/src/literal/imp.rs:786:42 clippy::manual_saturating_arithmetic "manual saturating arithmetic" +regex/1.3.2/src/literal/imp.rs:78:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/literal/imp.rs:84:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/literal/imp.rs:850:20 clippy::unreadable_literal "long literal lacking separators" +regex/1.3.2/src/literal/imp.rs:85:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/pikevm.rs:103:15 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/pikevm.rs:103:52 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/pikevm.rs:114:5 clippy::too_many_arguments "this function has too many arguments (8/7)" +regex/1.3.2/src/pikevm.rs:117:13 clippy::similar_names "binding's name is too similar to existing binding" +regex/1.3.2/src/pikevm.rs:124:17 clippy::similar_names "binding's name is too similar to existing binding" +regex/1.3.2/src/pikevm.rs:220:9 clippy::doc_markdown "you should put `thread_caps` between ticks in the documentation" +regex/1.3.2/src/pikevm.rs:222:16 clippy::doc_markdown "you should put `at_next` between ticks in the documentation" +regex/1.3.2/src/pikevm.rs:223:9 clippy::doc_markdown "you should put `at_next` between ticks in the documentation" +regex/1.3.2/src/pikevm.rs:224:5 clippy::too_many_arguments "this function has too many arguments (8/7)" +regex/1.3.2/src/pikevm.rs:234:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/pikevm.rs:303:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/pikevm.rs:331:29 clippy::mut_mut "this expression mutably borrows a mutable reference. Consider reborrowing" +regex/1.3.2/src/pikevm.rs:88:5 clippy::too_many_arguments "this function has too many arguments (8/7)" +regex/1.3.2/src/prog.rs:102:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/prog.rs:113:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/prog.rs:120:9 clippy::match_like_matches_macro "match expression looks like `matches!` macro" +regex/1.3.2/src/prog.rs:128:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/prog.rs:134:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/prog.rs:141:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/prog.rs:147:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/prog.rs:164:41 clippy::inline_always "you have declared `#[inline(always)]` on `deref`. This is usually a bad idea" +regex/1.3.2/src/prog.rs:172:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/prog.rs:18:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +regex/1.3.2/src/prog.rs:236:13 clippy::write_with_newline "using `write!()` with a format string that ends in a single newline" +regex/1.3.2/src/prog.rs:300:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/prog.rs:301:9 clippy::match_like_matches_macro "match expression looks like `matches!` macro" +regex/1.3.2/src/prog.rs:382:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/prog.rs:409:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/prog.rs:80:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/prog.rs:80:5 clippy::new_without_default "you should consider adding a `Default` implementation for `prog::Program`" +regex/1.3.2/src/re_builder.rs:267:17 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +regex/1.3.2/src/re_builder.rs:267:17 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +regex/1.3.2/src/re_builder.rs:4:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +regex/1.3.2/src/re_builder.rs:57:17 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_builder.rs:57:17 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_builder.rs:68:17 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +regex/1.3.2/src/re_builder.rs:68:17 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +regex/1.3.2/src/re_bytes.rs:1017:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +regex/1.3.2/src/re_bytes.rs:1039:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +regex/1.3.2/src/re_bytes.rs:1093:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +regex/1.3.2/src/re_bytes.rs:1118:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +regex/1.3.2/src/re_bytes.rs:1133:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +regex/1.3.2/src/re_bytes.rs:118:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +regex/1.3.2/src/re_bytes.rs:256:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/re_bytes.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_bytes.rs:35:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_bytes.rs:42:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_bytes.rs:48:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_bytes.rs:558:29 clippy::doc_markdown "you should put `shortest_match` between ticks in the documentation" +regex/1.3.2/src/re_bytes.rs:55:33 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/re_bytes.rs:55:47 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/re_bytes.rs:572:29 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" +regex/1.3.2/src/re_bytes.rs:720:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/re_bytes.rs:817:5 clippy::doc_markdown "you should put `CaptureLocations` between ticks in the documentation" +regex/1.3.2/src/re_bytes.rs:843:1 clippy::len_without_is_empty "item `re_bytes::CaptureLocations` has a public `len` method but no corresponding `is_empty` method" +regex/1.3.2/src/re_bytes.rs:849:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_bytes.rs:858:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_bytes.rs:869:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_bytes.rs:891:1 clippy::len_without_is_empty "item `re_bytes::Captures<'t>` has a public `len` method but no corresponding `is_empty` method" +regex/1.3.2/src/re_bytes.rs:911:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_bytes.rs:917:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_bytes.rs:926:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_bytes.rs:955:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_set.rs:179:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/re_set.rs:179:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/re_set.rs:251:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_set.rs:251:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_set.rs:263:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_set.rs:263:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_set.rs:268:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_set.rs:268:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_set.rs:277:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_set.rs:277:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_set.rs:94:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +regex/1.3.2/src/re_set.rs:94:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +regex/1.3.2/src/re_trait.rs:136:29 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/re_unicode.rs:1019:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +regex/1.3.2/src/re_unicode.rs:1041:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +regex/1.3.2/src/re_unicode.rs:1088:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/re_unicode.rs:1135:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +regex/1.3.2/src/re_unicode.rs:1160:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +regex/1.3.2/src/re_unicode.rs:174:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +regex/1.3.2/src/re_unicode.rs:21:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +regex/1.3.2/src/re_unicode.rs:313:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/re_unicode.rs:38:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_unicode.rs:44:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_unicode.rs:51:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_unicode.rs:57:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_unicode.rs:617:29 clippy::doc_markdown "you should put `shortest_match` between ticks in the documentation" +regex/1.3.2/src/re_unicode.rs:631:29 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" +regex/1.3.2/src/re_unicode.rs:64:33 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/re_unicode.rs:64:47 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/re_unicode.rs:834:5 clippy::doc_markdown "you should put `CaptureLocations` between ticks in the documentation" +regex/1.3.2/src/re_unicode.rs:860:1 clippy::len_without_is_empty "item `re_unicode::CaptureLocations` has a public `len` method but no corresponding `is_empty` method" +regex/1.3.2/src/re_unicode.rs:866:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_unicode.rs:875:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_unicode.rs:886:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_unicode.rs:908:1 clippy::len_without_is_empty "item `re_unicode::Captures<'t>` has a public `len` method but no corresponding `is_empty` method" +regex/1.3.2/src/re_unicode.rs:928:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_unicode.rs:934:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_unicode.rs:943:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_unicode.rs:972:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/sparse.rs:10:37 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +regex/1.3.2/src/sparse.rs:15:1 clippy::module_name_repetitions "item name starts with its containing module's name" +regex/1.3.2/src/utf8.rs:100:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex/1.3.2/src/utf8.rs:103:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex/1.3.2/src/utf8.rs:106:22 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +regex/1.3.2/src/utf8.rs:107:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +regex/1.3.2/src/utf8.rs:108:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +regex/1.3.2/src/utf8.rs:109:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +regex/1.3.2/src/utf8.rs:111:27 clippy::unreadable_literal "long literal lacking separators" +regex/1.3.2/src/utf8.rs:121:1 clippy::module_name_repetitions "item name ends with its containing module's name" +regex/1.3.2/src/utf8.rs:143:24 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex/1.3.2/src/utf8.rs:143:9 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex/1.3.2/src/utf8.rs:23:1 clippy::module_name_repetitions "item name ends with its containing module's name" +regex/1.3.2/src/utf8.rs:30:20 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex/1.3.2/src/utf8.rs:51:1 clippy::module_name_repetitions "item name ends with its containing module's name" +regex/1.3.2/src/utf8.rs:58:23 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex/1.3.2/src/utf8.rs:58:9 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex/1.3.2/src/utf8.rs:63:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex/1.3.2/src/utf8.rs:66:22 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +regex/1.3.2/src/utf8.rs:66:54 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +regex/1.3.2/src/utf8.rs:77:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex/1.3.2/src/utf8.rs:80:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex/1.3.2/src/utf8.rs:83:22 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +regex/1.3.2/src/utf8.rs:84:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +regex/1.3.2/src/utf8.rs:85:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +regex/1.3.2/src/utf8.rs:92:23 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex/1.3.2/src/utf8.rs:92:9 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex/1.3.2/src/utf8.rs:97:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +ripgrep/12.1.1//home/matthias/.rustup/toolchains/nightly-2020-12-20-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std/src/macros.rs:14:27 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep/12.1.1//home/matthias/.rustup/toolchains/nightly-2020-12-20-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std/src/macros.rs:14:27 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep/12.1.1//home/matthias/.rustup/toolchains/nightly-2020-12-20-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std/src/macros.rs:14:27 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep/12.1.1//home/matthias/.rustup/toolchains/nightly-2020-12-20-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std/src/macros.rs:14:27 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep/12.1.1/build.rs:133:19 clippy::option_as_ref_deref "called `.as_ref().map(|x| &**x)` on an Option value. This can be done more directly by calling `githash.as_deref()` instead" +ripgrep/12.1.1/build.rs:18:18 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +ripgrep/12.1.1/build.rs:225:14 clippy::redundant_closure_for_method_calls "redundant closure found" +ripgrep/12.1.1/build.rs:92:19 clippy::option_as_ref_deref "called `.as_ref().map(|x| &**x)` on an Option value. This can be done more directly by calling `githash.as_deref()` instead" +ripgrep/12.1.1/crates/core/app.rs:1408:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep/12.1.1/crates/core/app.rs:1408:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep/12.1.1/crates/core/app.rs:1409:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep/12.1.1/crates/core/app.rs:1409:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep/12.1.1/crates/core/app.rs:152:32 clippy::doc_markdown "you should put `clap::Arg` between ticks in the documentation" +ripgrep/12.1.1/crates/core/app.rs:152:32 clippy::doc_markdown "you should put `clap::Arg` between ticks in the documentation" +ripgrep/12.1.1/crates/core/app.rs:156:39 clippy::doc_markdown "you should put `clap::Arg` between ticks in the documentation" +ripgrep/12.1.1/crates/core/app.rs:156:39 clippy::doc_markdown "you should put `clap::Arg` between ticks in the documentation" +ripgrep/12.1.1/crates/core/app.rs:156:5 clippy::doc_markdown "you should put `RGArg` between ticks in the documentation" +ripgrep/12.1.1/crates/core/app.rs:156:5 clippy::doc_markdown "you should put `RGArg` between ticks in the documentation" +ripgrep/12.1.1/crates/core/app.rs:1668:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep/12.1.1/crates/core/app.rs:1668:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep/12.1.1/crates/core/app.rs:1669:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep/12.1.1/crates/core/app.rs:1669:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep/12.1.1/crates/core/app.rs:1821:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep/12.1.1/crates/core/app.rs:1821:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep/12.1.1/crates/core/app.rs:1822:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep/12.1.1/crates/core/app.rs:1822:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep/12.1.1/crates/core/app.rs:2999:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep/12.1.1/crates/core/app.rs:2999:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep/12.1.1/crates/core/app.rs:3000:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep/12.1.1/crates/core/app.rs:3000:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep/12.1.1/crates/core/app.rs:367:54 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep/12.1.1/crates/core/app.rs:367:54 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep/12.1.1/crates/core/app.rs:414:59 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep/12.1.1/crates/core/app.rs:414:59 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep/12.1.1/crates/core/app.rs:417:57 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep/12.1.1/crates/core/app.rs:417:57 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep/12.1.1/crates/core/app.rs:417:57 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep/12.1.1/crates/core/app.rs:417:57 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep/12.1.1/crates/core/app.rs:75:9 clippy::doc_markdown "you should put `RIPGREP_BUILD_GIT_HASH` between ticks in the documentation" +ripgrep/12.1.1/crates/core/app.rs:75:9 clippy::doc_markdown "you should put `RIPGREP_BUILD_GIT_HASH` between ticks in the documentation" +ripgrep/12.1.1/crates/core/app.rs:87:5 clippy::if_not_else "unnecessary boolean `not` operation" +ripgrep/12.1.1/crates/core/app.rs:87:5 clippy::if_not_else "unnecessary boolean `not` operation" +ripgrep/12.1.1/crates/core/args.rs:1143:22 clippy::unused_self "unused `self` argument" +ripgrep/12.1.1/crates/core/args.rs:11:1 clippy::single_component_path_imports "this import is redundant" +ripgrep/12.1.1/crates/core/args.rs:1209:74 clippy::if_same_then_else "this `if` has identical blocks" +ripgrep/12.1.1/crates/core/args.rs:1209:74 clippy::if_same_then_else "this `if` has identical blocks" +ripgrep/12.1.1/crates/core/args.rs:1282:13 clippy::similar_names "binding's name is too similar to existing binding" +ripgrep/12.1.1/crates/core/args.rs:1430:22 clippy::unused_self "unused `self` argument" +ripgrep/12.1.1/crates/core/args.rs:1438:21 clippy::doc_markdown "you should put `OsStr` between ticks in the documentation" +ripgrep/12.1.1/crates/core/args.rs:1520:44 clippy::redundant_closure_for_method_calls "redundant closure found" +ripgrep/12.1.1/crates/core/args.rs:1524:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +ripgrep/12.1.1/crates/core/args.rs:1635:14 clippy::doc_markdown "you should put `values_of_lossy` between ticks in the documentation" +ripgrep/12.1.1/crates/core/args.rs:1693:41 clippy::redundant_closure_for_method_calls "redundant closure found" +ripgrep/12.1.1/crates/core/args.rs:1770:17 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +ripgrep/12.1.1/crates/core/args.rs:287:13 clippy::similar_names "binding's name is too similar to existing binding" +ripgrep/12.1.1/crates/core/args.rs:33:1 clippy::single_component_path_imports "this import is redundant" +ripgrep/12.1.1/crates/core/args.rs:34:1 clippy::single_component_path_imports "this import is redundant" +ripgrep/12.1.1/crates/core/args.rs:35:1 clippy::single_component_path_imports "this import is redundant" +ripgrep/12.1.1/crates/core/args.rs:410:14 clippy::trivially_copy_pass_by_ref "this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +ripgrep/12.1.1/crates/core/args.rs:475:18 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep/12.1.1/crates/core/args.rs:512:19 clippy::doc_markdown "you should put `ArgMatches` between ticks in the documentation" +ripgrep/12.1.1/crates/core/args.rs:549:16 clippy::wrong_self_convention "methods called `to_*` usually take self by reference; consider choosing a less ambiguous name" +ripgrep/12.1.1/crates/core/args.rs:76:18 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +ripgrep/12.1.1/crates/core/args.rs:77:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +ripgrep/12.1.1/crates/core/args.rs:923:42 clippy::doc_markdown "you should put `BinaryDetection::quit` between ticks in the documentation" +ripgrep/12.1.1/crates/core/config.rs:13:1 clippy::single_component_path_imports "this import is redundant" +ripgrep/12.1.1/crates/core/config.rs:58:6 clippy::type_complexity "very complex type used. Consider factoring parts into `type` definitions" +ripgrep/12.1.1/crates/core/config.rs:79:6 clippy::type_complexity "very complex type used. Consider factoring parts into `type` definitions" +ripgrep/12.1.1/crates/core/logger.rs:11:30 clippy::doc_markdown "you should put `max_level` between ticks in the documentation" +ripgrep/12.1.1/crates/core/logger.rs:15:16 clippy::redundant_static_lifetimes "constants have by default a `'static` lifetime" +ripgrep/12.1.1/crates/core/main.rs:55:19 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +ripgrep/12.1.1/crates/core/main.rs:56:9 clippy::enum_glob_use "usage of wildcard import for enum variants" +ripgrep/12.1.1/crates/core/messages.rs:46:1 clippy::module_name_repetitions "item name ends with its containing module's name" +ripgrep/12.1.1/crates/core/messages.rs:51:1 clippy::module_name_repetitions "item name ends with its containing module's name" +ripgrep/12.1.1/crates/core/messages.rs:62:1 clippy::module_name_repetitions "item name ends with its containing module's name" +ripgrep/12.1.1/crates/core/path_printer.rs:27:1 clippy::module_name_repetitions "item name starts with its containing module's name" +ripgrep/12.1.1/crates/core/path_printer.rs:89:9 clippy::if_not_else "unnecessary boolean `not` operation" +ripgrep/12.1.1/crates/core/search.rs:185:1 clippy::module_name_repetitions "item name starts with its containing module's name" +ripgrep/12.1.1/crates/core/search.rs:292:9 clippy::write_with_newline "using `write!()` with a format string that ends in a single newline" +ripgrep/12.1.1/crates/core/search.rs:311:1 clippy::module_name_repetitions "item name starts with its containing module's name" +ripgrep/12.1.1/crates/core/search.rs:377:12 clippy::nonminimal_bool "this boolean expression can be simplified" +ripgrep/12.1.1/crates/core/search.rs:423:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +ripgrep/12.1.1/crates/core/search.rs:447:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +ripgrep/12.1.1/crates/core/search.rs:472:24 clippy::map_clone "you are using an explicit closure for cloning elements" +ripgrep/12.1.1/crates/core/search.rs:472:41 clippy::redundant_closure_for_method_calls "redundant closure found" +ripgrep/12.1.1/crates/core/search.rs:480:24 clippy::map_clone "you are using an explicit closure for cloning elements" +ripgrep/12.1.1/crates/core/search.rs:480:41 clippy::redundant_closure_for_method_calls "redundant closure found" +ripgrep/12.1.1/crates/core/search.rs:49:1 clippy::module_name_repetitions "item name starts with its containing module's name" +ripgrep/12.1.1/crates/core/search.rs:509:24 clippy::map_clone "you are using an explicit closure for cloning elements" +ripgrep/12.1.1/crates/core/search.rs:509:41 clippy::redundant_closure_for_method_calls "redundant closure found" +ripgrep/12.1.1/crates/core/search.rs:517:24 clippy::map_clone "you are using an explicit closure for cloning elements" +ripgrep/12.1.1/crates/core/search.rs:517:41 clippy::redundant_closure_for_method_calls "redundant closure found" +ripgrep/12.1.1/crates/core/search.rs:533:36 clippy::cast_lossless "casting `u32` to `f64` may become silently lossy if you later change the type" +ripgrep/12.1.1/crates/core/search.rs:533:5 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +ripgrep/12.1.1/crates/core/subject.rs:20:1 clippy::module_name_repetitions "item name starts with its containing module's name" +ripgrep/12.1.1/crates/core/subject.rs:4:1 clippy::single_component_path_imports "this import is redundant" +syn/1.0.54/build.rs:1:null clippy::cargo_common_metadata "package `syn` is missing `package.keywords` metadata" +syn/1.0.54/build.rs:1:null clippy::multiple_crate_versions "could not read cargo metadata: failed to run `cargo metadata`: Downloading crates ...\n Downloaded syn-test-suite v0.0.0\nerror: failed to verify the checksum of `syn-test-suite v0.0.0`" +syn/1.0.54/src/lib.rs:1:null clippy::cargo_common_metadata "package `syn` is missing `package.keywords` metadata" +syn/1.0.54/src/lib.rs:1:null clippy::multiple_crate_versions "could not read cargo metadata: failed to run `cargo metadata`: Downloading crates ...\n Downloaded syn-test-suite v0.0.0\nerror: failed to verify the checksum of `syn-test-suite v0.0.0`" +syn/1.0.54/src/lit.rs:1397:40 clippy::redundant_else "redundant else block" +syn/1.0.54/src/lit.rs:1405:28 clippy::redundant_else "redundant else block" +syn/1.0.54/src/lit.rs:1485:32 clippy::redundant_else "redundant else block" +unicode-xid/0.2.1/src/lib.rs:1:null clippy::cargo_common_metadata "package `unicode-xid` is missing `package.categories` metadata" +unicode-xid/0.2.1/src/lib.rs:57:64 clippy::doc_markdown "you should put `XID_Start` between ticks in the documentation" +unicode-xid/0.2.1/src/lib.rs:60:10 clippy::doc_markdown "you should put `XID_Start` between ticks in the documentation" +unicode-xid/0.2.1/src/lib.rs:62:27 clippy::doc_markdown "you should put `ID_Start` between ticks in the documentation" +unicode-xid/0.2.1/src/lib.rs:62:67 clippy::doc_markdown "you should put `NFKx` between ticks in the documentation" +unicode-xid/0.2.1/src/lib.rs:63:21 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" +unicode-xid/0.2.1/src/lib.rs:65:61 clippy::doc_markdown "you should put `XID_Continue` between ticks in the documentation" +unicode-xid/0.2.1/src/lib.rs:68:10 clippy::doc_markdown "you should put `XID_Continue` between ticks in the documentation" +unicode-xid/0.2.1/src/lib.rs:70:28 clippy::doc_markdown "you should put `ID_Continue` between ticks in the documentation" +unicode-xid/0.2.1/src/lib.rs:70:72 clippy::doc_markdown "you should put `NFKx` between ticks in the documentation" +unicode-xid/0.2.1/src/lib.rs:71:24 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" +xsv/0.13.0/src/cmd/cat.rs:101:34 clippy::redundant_closure_for_method_calls "redundant closure found" +xsv/0.13.0/src/cmd/cat.rs:42:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +xsv/0.13.0/src/cmd/cat.rs:53:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/cat.rs:7:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv/0.13.0/src/cmd/count.rs:32:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/count.rs:38:9 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +xsv/0.13.0/src/cmd/count.rs:42:33 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +xsv/0.13.0/src/cmd/count.rs:50:5 clippy::unit_arg "passing a unit value to a function" +xsv/0.13.0/src/cmd/count.rs:7:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv/0.13.0/src/cmd/fixlengths.rs:45:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/fixlengths.rs:50:18 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +xsv/0.13.0/src/cmd/fixlengths.rs:62:30 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +xsv/0.13.0/src/cmd/fixlengths.rs:9:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv/0.13.0/src/cmd/flatten.rs:10:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv/0.13.0/src/cmd/flatten.rs:51:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/fmt.rs:50:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/fmt.rs:55:13 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/fmt.rs:7:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv/0.13.0/src/cmd/frequency.rs:148:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +xsv/0.13.0/src/cmd/frequency.rs:149:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +xsv/0.13.0/src/cmd/frequency.rs:15:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv/0.13.0/src/cmd/frequency.rs:169:13 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/frequency.rs:176:17 clippy::if_not_else "unnecessary boolean `not` operation" +xsv/0.13.0/src/cmd/frequency.rs:178:24 clippy::collapsible_if "this `else { if .. }` block can be collapsed" +xsv/0.13.0/src/cmd/frequency.rs:77:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/frequency.rs:93:31 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" +xsv/0.13.0/src/cmd/headers.rs:43:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/headers.rs:49:17 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" +xsv/0.13.0/src/cmd/headers.rs:9:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv/0.13.0/src/cmd/index.rs:11:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv/0.13.0/src/cmd/index.rs:45:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/input.rs:42:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/input.rs:47:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/input.rs:7:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv/0.13.0/src/cmd/join.rs:17:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv/0.13.0/src/cmd/join.rs:194:29 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/join.rs:224:22 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/join.rs:293:14 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/join.rs:293:20 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/join.rs:297:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv/0.13.0/src/cmd/join.rs:298:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv/0.13.0/src/cmd/join.rs:299:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv/0.13.0/src/cmd/join.rs:300:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv/0.13.0/src/cmd/join.rs:308:9 clippy::unused_self "unused `self` argument" +xsv/0.13.0/src/cmd/join.rs:342:38 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +xsv/0.13.0/src/cmd/join.rs:342:46 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +xsv/0.13.0/src/cmd/join.rs:347:9 clippy::if_not_else "unnecessary boolean `not` operation" +xsv/0.13.0/src/cmd/join.rs:372:44 clippy::redundant_closure_for_method_calls "redundant closure found" +xsv/0.13.0/src/cmd/join.rs:375:33 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/join.rs:392:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv/0.13.0/src/cmd/join.rs:403:29 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" +xsv/0.13.0/src/cmd/join.rs:426:13 clippy::if_not_else "unnecessary boolean `not` operation" +xsv/0.13.0/src/cmd/join.rs:77:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +xsv/0.13.0/src/cmd/join.rs:94:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/partition.rs:105:22 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/partition.rs:139:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv/0.13.0/src/cmd/partition.rs:15:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv/0.13.0/src/cmd/partition.rs:169:9 clippy::if_not_else "unnecessary boolean `not` operation" +xsv/0.13.0/src/cmd/partition.rs:56:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/partition.rs:77:9 clippy::unused_self "unused `self` argument" +xsv/0.13.0/src/cmd/sample.rs:105:44 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +xsv/0.13.0/src/cmd/sample.rs:115:21 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +xsv/0.13.0/src/cmd/sample.rs:11:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv/0.13.0/src/cmd/sample.rs:51:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/sample.rs:58:19 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +xsv/0.13.0/src/cmd/sample.rs:69:9 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +xsv/0.13.0/src/cmd/sample.rs:75:16 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" +xsv/0.13.0/src/cmd/sample.rs:91:42 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +xsv/0.13.0/src/cmd/sample.rs:92:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +xsv/0.13.0/src/cmd/search.rs:51:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/search.rs:9:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv/0.13.0/src/cmd/select.rs:60:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/select.rs:8:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv/0.13.0/src/cmd/slice.rs:57:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/slice.rs:9:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv/0.13.0/src/cmd/sort.rs:11:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv/0.13.0/src/cmd/sort.rs:138:47 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +xsv/0.13.0/src/cmd/sort.rs:139:51 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +xsv/0.13.0/src/cmd/sort.rs:48:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/sort.rs:91:14 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" +xsv/0.13.0/src/cmd/split.rs:14:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv/0.13.0/src/cmd/split.rs:61:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/split.rs:94:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +xsv/0.13.0/src/cmd/split.rs:96:14 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +xsv/0.13.0/src/cmd/split.rs:99:13 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +xsv/0.13.0/src/cmd/stats.rs:110:36 clippy::redundant_closure_for_method_calls "redundant closure found" +xsv/0.13.0/src/cmd/stats.rs:127:14 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +xsv/0.13.0/src/cmd/stats.rs:138:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +xsv/0.13.0/src/cmd/stats.rs:139:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +xsv/0.13.0/src/cmd/stats.rs:162:25 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" +xsv/0.13.0/src/cmd/stats.rs:22:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv/0.13.0/src/cmd/stats.rs:231:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +xsv/0.13.0/src/cmd/stats.rs:262:35 clippy::default_trait_access "calling `cmd::stats::TypedSum::default()` is more clear than this expression" +xsv/0.13.0/src/cmd/stats.rs:263:40 clippy::default_trait_access "calling `cmd::stats::TypedMinMax::default()` is more clear than this expression" +xsv/0.13.0/src/cmd/stats.rs:264:39 clippy::default_trait_access "calling `stats::OnlineStats::default()` is more clear than this expression" +xsv/0.13.0/src/cmd/stats.rs:265:58 clippy::default_trait_access "calling `stats::Unsorted::default()` is more clear than this expression" +xsv/0.13.0/src/cmd/stats.rs:266:41 clippy::default_trait_access "calling `stats::Unsorted::default()` is more clear than this expression" +xsv/0.13.0/src/cmd/stats.rs:268:18 clippy::default_trait_access "calling `cmd::stats::FieldType::default()` is more clear than this expression" +xsv/0.13.0/src/cmd/stats.rs:269:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv/0.13.0/src/cmd/stats.rs:270:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv/0.13.0/src/cmd/stats.rs:271:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv/0.13.0/src/cmd/stats.rs:272:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv/0.13.0/src/cmd/stats.rs:273:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv/0.13.0/src/cmd/stats.rs:274:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv/0.13.0/src/cmd/stats.rs:283:9 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" +xsv/0.13.0/src/cmd/stats.rs:284:9 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" +xsv/0.13.0/src/cmd/stats.rs:285:9 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" +xsv/0.13.0/src/cmd/stats.rs:290:21 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" +xsv/0.13.0/src/cmd/stats.rs:293:25 clippy::match_same_arms "this `match` has identical arm bodies" +xsv/0.13.0/src/cmd/stats.rs:297:25 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" +xsv/0.13.0/src/cmd/stats.rs:301:21 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" +xsv/0.13.0/src/cmd/stats.rs:302:21 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" +xsv/0.13.0/src/cmd/stats.rs:308:18 clippy::wrong_self_convention "methods called `to_*` usually take self by reference; consider choosing a less ambiguous name" +xsv/0.13.0/src/cmd/stats.rs:318:9 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +xsv/0.13.0/src/cmd/stats.rs:322:45 clippy::redundant_closure_for_method_calls "redundant closure found" +xsv/0.13.0/src/cmd/stats.rs:322:9 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +xsv/0.13.0/src/cmd/stats.rs:327:9 clippy::if_not_else "unnecessary boolean `not` operation" +xsv/0.13.0/src/cmd/stats.rs:330:13 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +xsv/0.13.0/src/cmd/stats.rs:338:45 clippy::redundant_closure_for_method_calls "redundant closure found" +xsv/0.13.0/src/cmd/stats.rs:402:16 clippy::redundant_pattern_matching "redundant pattern matching, consider using `is_ok()`" +xsv/0.13.0/src/cmd/stats.rs:403:16 clippy::redundant_pattern_matching "redundant pattern matching, consider using `is_ok()`" +xsv/0.13.0/src/cmd/stats.rs:407:18 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +xsv/0.13.0/src/cmd/stats.rs:411:16 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +xsv/0.13.0/src/cmd/stats.rs:427:56 clippy::match_same_arms "this `match` has identical arm bodies" +xsv/0.13.0/src/cmd/stats.rs:429:56 clippy::match_same_arms "this `match` has identical arm bodies" +xsv/0.13.0/src/cmd/stats.rs:430:60 clippy::match_same_arms "this `match` has identical arm bodies" +xsv/0.13.0/src/cmd/stats.rs:430:60 clippy::match_same_arms "this `match` has identical arm bodies" +xsv/0.13.0/src/cmd/stats.rs:454:5 clippy::doc_markdown "you should put `TypedSum` between ticks in the documentation" +xsv/0.13.0/src/cmd/stats.rs:473:43 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +xsv/0.13.0/src/cmd/stats.rs:504:56 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +xsv/0.13.0/src/cmd/stats.rs:505:51 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +xsv/0.13.0/src/cmd/stats.rs:511:5 clippy::doc_markdown "you should put `TypedMinMax` between ticks in the documentation" +xsv/0.13.0/src/cmd/stats.rs:536:35 clippy::cast_possible_truncation "casting `f64` to `i64` may truncate the value" +xsv/0.13.0/src/cmd/stats.rs:544:33 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +xsv/0.13.0/src/cmd/stats.rs:592:22 clippy::default_trait_access "calling `stats::MinMax::default()` is more clear than this expression" +xsv/0.13.0/src/cmd/stats.rs:593:22 clippy::default_trait_access "calling `stats::MinMax::default()` is more clear than this expression" +xsv/0.13.0/src/cmd/stats.rs:594:23 clippy::default_trait_access "calling `stats::MinMax::default()` is more clear than this expression" +xsv/0.13.0/src/cmd/stats.rs:595:21 clippy::default_trait_access "calling `stats::MinMax::default()` is more clear than this expression" +xsv/0.13.0/src/cmd/stats.rs:71:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +xsv/0.13.0/src/cmd/stats.rs:86:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/table.rs:10:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv/0.13.0/src/cmd/table.rs:50:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/table.rs:54:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/config.rs:113:43 clippy::or_fun_call "use of `unwrap_or` followed by a function call" +xsv/0.13.0/src/config.rs:58:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +xsv/0.13.0/src/config.rs:77:28 clippy::explicit_deref_methods "explicit deref method call" +xsv/0.13.0/src/config.rs:90:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv/0.13.0/src/index.rs:31:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv/0.13.0/src/main.rs:164:49 clippy::redundant_clone "redundant clone" +xsv/0.13.0/src/main.rs:1:null clippy::cargo_common_metadata "package `xsv` is missing `package.categories` metadata" +xsv/0.13.0/src/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `rand_core`: 0.3.1, 0.4.2" +xsv/0.13.0/src/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `rand`: 0.3.23, 0.4.6" +xsv/0.13.0/src/main.rs:75:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv/0.13.0/src/select.rs:13:1 clippy::module_name_repetitions "item name starts with its containing module's name" +xsv/0.13.0/src/select.rs:154:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +xsv/0.13.0/src/select.rs:250:33 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/select.rs:250:43 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/select.rs:255:39 clippy::range_plus_one "an inclusive range would be more readable" +xsv/0.13.0/src/select.rs:280:20 clippy::len_zero "length comparison to zero" +xsv/0.13.0/src/select.rs:29:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv/0.13.0/src/select.rs:360:62 clippy::trivially_copy_pass_by_ref "this argument (8 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +xsv/0.13.0/src/select.rs:360:9 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Option`" +xsv/0.13.0/src/select.rs:375:9 clippy::stable_sort_primitive "used sort instead of sort_unstable to sort primitive type `usize`" +xsv/0.13.0/src/select.rs:379:18 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" +xsv/0.13.0/src/select.rs:416:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +xsv/0.13.0/src/select.rs:419:9 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Option`" +xsv/0.13.0/src/select.rs:420:27 clippy::option_option "consider using `Option` instead of `Option>` or a custom enum if you need to distinguish all 3 cases" +xsv/0.13.0/src/select.rs:99:17 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/util.rs:150:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +xsv/0.13.0/src/util.rs:37:33 clippy::map_clone "you are using an explicit closure for copying elements" +xsv/0.13.0/src/util.rs:90:1 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -- cgit 1.4.1-3-g733a5 From 4ec9cb84bb96ff11eba9d0a8961ddfea2fa1ba65 Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Wed, 23 Dec 2020 15:31:18 +0100 Subject: cargo dev crater: refactor to get a list of all ClippyWarnings --- clippy_dev/src/crater.rs | 17 +++++++---------- 1 file changed, 7 insertions(+), 10 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/crater.rs b/clippy_dev/src/crater.rs index db0dd3641f1..96b94c2c652 100644 --- a/clippy_dev/src/crater.rs +++ b/clippy_dev/src/crater.rs @@ -106,7 +106,7 @@ impl CrateSource { } impl Crate { - fn run_clippy_lints(&self, cargo_clippy_path: &PathBuf) -> Vec { + fn run_clippy_lints(&self, cargo_clippy_path: &PathBuf) -> Vec { println!("Linting {} {}...", &self.name, &self.version); let cargo_clippy_path = std::fs::canonicalize(cargo_clippy_path).unwrap(); @@ -136,11 +136,7 @@ impl Crate { .filter(|line| line.contains("clippy::")) .map(|json_msg| parse_json_message(json_msg, &self)) .collect(); - - let mut output: Vec = warnings.iter().map(|warning| warning.to_string()).collect(); - // sort messages alphabetically to avoid noise in the logs - output.sort(); - output + warnings } } @@ -219,17 +215,18 @@ pub fn run() { ); // download and extract the crates, then run clippy on them and collect clippys warnings + // flatten into one big list of warnings - let clippy_lint_results: Vec> = read_crates() + let clippy_warnings: Vec = read_crates() .into_iter() .map(|krate| krate.download_and_extract()) .map(|krate| krate.run_clippy_lints(&cargo_clippy_path)) + .flatten() .collect(); - let mut all_warnings: Vec = clippy_lint_results.into_iter().flatten().collect(); - all_warnings.sort(); + let all_msgs: Vec = clippy_warnings.iter().map(|warning| warning.to_string()).collect(); // save the text into mini-crater/logs.txt - let text = all_warnings.join(""); + let text = all_msgs.join(""); write("mini-crater/logs.txt", text).unwrap(); } -- cgit 1.4.1-3-g733a5 From e56c9a52532d87a36da32fbde8066ecc34e67cd4 Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Wed, 23 Dec 2020 15:59:16 +0100 Subject: cargo dev crater: gather and save lint statistics (how often a lint triggered) --- clippy_dev/src/crater.rs | 25 ++++++++++- mini-crater/logs.txt | 112 +++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 136 insertions(+), 1 deletion(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/crater.rs b/clippy_dev/src/crater.rs index 96b94c2c652..7607e6b449f 100644 --- a/clippy_dev/src/crater.rs +++ b/clippy_dev/src/crater.rs @@ -224,7 +224,30 @@ pub fn run() { .flatten() .collect(); - let all_msgs: Vec = clippy_warnings.iter().map(|warning| warning.to_string()).collect(); + // generate some stats: + + // count lint type occurrences + let mut counter: HashMap<&String, usize> = HashMap::new(); + clippy_warnings + .iter() + .for_each(|wrn| *counter.entry(&wrn.linttype).or_insert(0) += 1); + + // collect into a tupled list for sorting + let mut stats: Vec<(&&String, &usize)> = counter.iter().map(|(lint, count)| (lint, count)).collect(); + // sort by number of lint occurences + stats.sort_by_key(|(_, count)| *count); + // biggest number first + stats.reverse(); + + let stats_formatted: String = stats + .iter() + .map(|(lint, count)| format!("{} {}\n", lint, count)) + .collect::(); + + let mut all_msgs: Vec = clippy_warnings.iter().map(|warning| warning.to_string()).collect(); + all_msgs.sort(); + all_msgs.push("\n\n\n\nStats\n\n".into()); + all_msgs.push(stats_formatted); // save the text into mini-crater/logs.txt let text = all_msgs.join(""); diff --git a/mini-crater/logs.txt b/mini-crater/logs.txt index 52045f05faa..18a0c2120ff 100644 --- a/mini-crater/logs.txt +++ b/mini-crater/logs.txt @@ -3247,3 +3247,115 @@ xsv/0.13.0/src/select.rs:99:17 clippy::similar_names "binding's name is too simi xsv/0.13.0/src/util.rs:150:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" xsv/0.13.0/src/util.rs:37:33 clippy::map_clone "you are using an explicit closure for copying elements" xsv/0.13.0/src/util.rs:90:1 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" + + + + +Stats + +clippy::must_use_candidate 552 +clippy::unreadable_literal 365 +clippy::missing_errors_doc 338 +clippy::doc_markdown 178 +clippy::wildcard_imports 160 +clippy::items_after_statements 139 +clippy::module_name_repetitions 137 +clippy::redundant_closure_for_method_calls 135 +clippy::redundant_field_names 111 +clippy::cast_possible_truncation 91 +clippy::similar_names 79 +clippy::match_same_arms 64 +clippy::inline_always 59 +clippy::single_match_else 45 +clippy::unseparated_literal_suffix 41 +clippy::enum_glob_use 40 +clippy::cast_precision_loss 35 +clippy::if_not_else 35 +clippy::filter_map 31 +clippy::too_many_lines 31 +clippy::redundant_else 29 +clippy::trivially_copy_pass_by_ref 26 +clippy::cast_lossless 23 +clippy::redundant_static_lifetimes 21 +clippy::struct_excessive_bools 20 +clippy::map_unwrap_or 20 +clippy::unusual_byte_groupings 19 +clippy::unused_self 19 +clippy::cast_possible_wrap 19 +clippy::cast_sign_loss 19 +clippy::unnecessary_wraps 19 +clippy::needless_pass_by_value 18 +clippy::default_trait_access 16 +clippy::linkedlist 14 +clippy::single_char_add_str 14 +clippy::shadow_unrelated 13 +clippy::cargo_common_metadata 13 +clippy::option_if_let_else 12 +clippy::needless_lifetimes 12 +clippy::multiple_crate_versions 11 +clippy::needless_doctest_main 10 +clippy::missing_safety_doc 10 +clippy::manual_range_contains 10 +clippy::match_wildcard_for_single_variants 10 +clippy::find_map 9 +clippy::wrong_self_convention 8 +clippy::invalid_upcast_comparisons 8 +clippy::option_map_unit_fn 7 +clippy::map_clone 7 +clippy::explicit_into_iter_loop 7 +clippy::range_plus_one 7 +clippy::manual_strip 6 +clippy::non_ascii_literal 6 +clippy::single_component_path_imports 6 +clippy::field_reassign_with_default 5 +clippy::new_without_default 5 +clippy::len_without_is_empty 5 +clippy::identity_op 5 +clippy::needless_return 5 +clippy::empty_enum 5 +clippy::match_like_matches_macro 5 +clippy::explicit_iter_loop 5 +clippy::too_many_arguments 4 +clippy::let_underscore_drop 4 +clippy::if_same_then_else 4 +clippy::filter_map_next 3 +clippy::zero_ptr 3 +clippy::fn_params_excessive_bools 3 +clippy::mut_mut 3 +clippy::manual_non_exhaustive 2 +clippy::comparison_to_empty 2 +clippy::question_mark 2 +clippy::redundant_pattern_matching 2 +clippy::write_with_newline 2 +clippy::unnecessary_cast 2 +clippy::option_option 2 +clippy::match_on_vec_items 2 +clippy::type_complexity 2 +clippy::len_zero 2 +clippy::expl_impl_clone_on_copy 2 +clippy::option_as_ref_deref 2 +clippy::unused_unit 2 +clippy::derive_hash_xor_eq 2 +clippy::while_let_on_iterator 1 +clippy::clone_on_copy 1 +clippy::same_item_push 1 +clippy::from_iter_instead_of_collect 1 +clippy::or_fun_call 1 +clippy::pub_enum_variant_names 1 +clippy::used_underscore_binding 1 +clippy::precedence 1 +clippy::redundant_clone 1 +clippy::collapsible_if 1 +clippy::stable_sort_primitive 1 +clippy::unit_arg 1 +clippy::nonminimal_bool 1 +clippy::comparison_chain 1 +clippy::mem_replace_with_default 1 +clippy::manual_saturating_arithmetic 1 +clippy::expect_fun_call 1 +clippy::should_implement_trait 1 +clippy::verbose_bit_mask 1 +clippy::int_plus_one 1 +clippy::unnecessary_lazy_evaluations 1 +clippy::from_over_into 1 +clippy::explicit_deref_methods 1 -- cgit 1.4.1-3-g733a5 From d257101109e7ed6ca0a561a9e16d51167d2d92d7 Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Sun, 27 Dec 2020 15:44:45 +0100 Subject: make stats stable --- clippy_dev/src/crater.rs | 7 +- mini-crater/logs.txt | 200 +++++++++++++++++++++++------------------------ 2 files changed, 103 insertions(+), 104 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/crater.rs b/clippy_dev/src/crater.rs index 7607e6b449f..b0e7cb70c89 100644 --- a/clippy_dev/src/crater.rs +++ b/clippy_dev/src/crater.rs @@ -234,10 +234,9 @@ pub fn run() { // collect into a tupled list for sorting let mut stats: Vec<(&&String, &usize)> = counter.iter().map(|(lint, count)| (lint, count)).collect(); - // sort by number of lint occurences - stats.sort_by_key(|(_, count)| *count); - // biggest number first - stats.reverse(); + // sort by "000{count} {clippy::lintname}" + // to not have a lint with 200 and 2 warnings take the same spot + stats.sort_by_key(|(lint, count)| format!("{:0>4}, {}", count, lint)); let stats_formatted: String = stats .iter() diff --git a/mini-crater/logs.txt b/mini-crater/logs.txt index 18a0c2120ff..70b9baf0396 100644 --- a/mini-crater/logs.txt +++ b/mini-crater/logs.txt @@ -3059,9 +3059,9 @@ ripgrep/12.1.1/crates/core/search.rs:533:5 clippy::cast_precision_loss "casting ripgrep/12.1.1/crates/core/subject.rs:20:1 clippy::module_name_repetitions "item name starts with its containing module's name" ripgrep/12.1.1/crates/core/subject.rs:4:1 clippy::single_component_path_imports "this import is redundant" syn/1.0.54/build.rs:1:null clippy::cargo_common_metadata "package `syn` is missing `package.keywords` metadata" -syn/1.0.54/build.rs:1:null clippy::multiple_crate_versions "could not read cargo metadata: failed to run `cargo metadata`: Downloading crates ...\n Downloaded syn-test-suite v0.0.0\nerror: failed to verify the checksum of `syn-test-suite v0.0.0`" +syn/1.0.54/build.rs:1:null clippy::multiple_crate_versions "could not read cargo metadata: failed to run `cargo metadata`: Blocking waiting for file lock on package cache\n Blocking waiting for file lock on package cache\n Blocking waiting for file lock on package cache\n Downloading crates ...\n Downloaded ref-cast v1.0.5\n Downloaded ref-cast-impl v1.0.5\n Downloaded syn-test-suite v0.0.0\nerror: failed to verify the checksum of `syn-test-suite v0.0.0`" syn/1.0.54/src/lib.rs:1:null clippy::cargo_common_metadata "package `syn` is missing `package.keywords` metadata" -syn/1.0.54/src/lib.rs:1:null clippy::multiple_crate_versions "could not read cargo metadata: failed to run `cargo metadata`: Downloading crates ...\n Downloaded syn-test-suite v0.0.0\nerror: failed to verify the checksum of `syn-test-suite v0.0.0`" +syn/1.0.54/src/lib.rs:1:null clippy::multiple_crate_versions "could not read cargo metadata: failed to run `cargo metadata`: Downloading crates ...\n Downloaded openssl-sys v0.9.60\n Downloaded syn-test-suite v0.0.0\nerror: failed to verify the checksum of `syn-test-suite v0.0.0`" syn/1.0.54/src/lit.rs:1397:40 clippy::redundant_else "redundant else block" syn/1.0.54/src/lit.rs:1405:28 clippy::redundant_else "redundant else block" syn/1.0.54/src/lit.rs:1485:32 clippy::redundant_else "redundant else block" @@ -3253,109 +3253,109 @@ xsv/0.13.0/src/util.rs:90:1 clippy::needless_lifetimes "explicit lifetimes given Stats -clippy::must_use_candidate 552 -clippy::unreadable_literal 365 -clippy::missing_errors_doc 338 -clippy::doc_markdown 178 -clippy::wildcard_imports 160 -clippy::items_after_statements 139 -clippy::module_name_repetitions 137 -clippy::redundant_closure_for_method_calls 135 -clippy::redundant_field_names 111 -clippy::cast_possible_truncation 91 -clippy::similar_names 79 -clippy::match_same_arms 64 -clippy::inline_always 59 -clippy::single_match_else 45 -clippy::unseparated_literal_suffix 41 -clippy::enum_glob_use 40 -clippy::cast_precision_loss 35 -clippy::if_not_else 35 -clippy::filter_map 31 -clippy::too_many_lines 31 -clippy::redundant_else 29 -clippy::trivially_copy_pass_by_ref 26 -clippy::cast_lossless 23 -clippy::redundant_static_lifetimes 21 -clippy::struct_excessive_bools 20 -clippy::map_unwrap_or 20 -clippy::unusual_byte_groupings 19 -clippy::unused_self 19 -clippy::cast_possible_wrap 19 -clippy::cast_sign_loss 19 -clippy::unnecessary_wraps 19 -clippy::needless_pass_by_value 18 -clippy::default_trait_access 16 -clippy::linkedlist 14 -clippy::single_char_add_str 14 -clippy::shadow_unrelated 13 -clippy::cargo_common_metadata 13 -clippy::option_if_let_else 12 -clippy::needless_lifetimes 12 -clippy::multiple_crate_versions 11 -clippy::needless_doctest_main 10 -clippy::missing_safety_doc 10 -clippy::manual_range_contains 10 -clippy::match_wildcard_for_single_variants 10 -clippy::find_map 9 -clippy::wrong_self_convention 8 -clippy::invalid_upcast_comparisons 8 -clippy::option_map_unit_fn 7 -clippy::map_clone 7 -clippy::explicit_into_iter_loop 7 -clippy::range_plus_one 7 -clippy::manual_strip 6 -clippy::non_ascii_literal 6 -clippy::single_component_path_imports 6 -clippy::field_reassign_with_default 5 -clippy::new_without_default 5 -clippy::len_without_is_empty 5 -clippy::identity_op 5 -clippy::needless_return 5 -clippy::empty_enum 5 -clippy::match_like_matches_macro 5 -clippy::explicit_iter_loop 5 -clippy::too_many_arguments 4 -clippy::let_underscore_drop 4 -clippy::if_same_then_else 4 -clippy::filter_map_next 3 -clippy::zero_ptr 3 -clippy::fn_params_excessive_bools 3 -clippy::mut_mut 3 -clippy::manual_non_exhaustive 2 -clippy::comparison_to_empty 2 -clippy::question_mark 2 -clippy::redundant_pattern_matching 2 -clippy::write_with_newline 2 -clippy::unnecessary_cast 2 -clippy::option_option 2 -clippy::match_on_vec_items 2 -clippy::type_complexity 2 -clippy::len_zero 2 -clippy::expl_impl_clone_on_copy 2 -clippy::option_as_ref_deref 2 -clippy::unused_unit 2 -clippy::derive_hash_xor_eq 2 -clippy::while_let_on_iterator 1 clippy::clone_on_copy 1 -clippy::same_item_push 1 +clippy::collapsible_if 1 +clippy::comparison_chain 1 +clippy::expect_fun_call 1 +clippy::explicit_deref_methods 1 clippy::from_iter_instead_of_collect 1 +clippy::from_over_into 1 +clippy::int_plus_one 1 +clippy::manual_saturating_arithmetic 1 +clippy::mem_replace_with_default 1 +clippy::nonminimal_bool 1 clippy::or_fun_call 1 -clippy::pub_enum_variant_names 1 -clippy::used_underscore_binding 1 clippy::precedence 1 +clippy::pub_enum_variant_names 1 clippy::redundant_clone 1 -clippy::collapsible_if 1 +clippy::same_item_push 1 +clippy::should_implement_trait 1 clippy::stable_sort_primitive 1 clippy::unit_arg 1 -clippy::nonminimal_bool 1 -clippy::comparison_chain 1 -clippy::mem_replace_with_default 1 -clippy::manual_saturating_arithmetic 1 -clippy::expect_fun_call 1 -clippy::should_implement_trait 1 -clippy::verbose_bit_mask 1 -clippy::int_plus_one 1 clippy::unnecessary_lazy_evaluations 1 -clippy::from_over_into 1 -clippy::explicit_deref_methods 1 +clippy::used_underscore_binding 1 +clippy::verbose_bit_mask 1 +clippy::while_let_on_iterator 1 +clippy::comparison_to_empty 2 +clippy::derive_hash_xor_eq 2 +clippy::expl_impl_clone_on_copy 2 +clippy::len_zero 2 +clippy::manual_non_exhaustive 2 +clippy::match_on_vec_items 2 +clippy::option_as_ref_deref 2 +clippy::option_option 2 +clippy::question_mark 2 +clippy::redundant_pattern_matching 2 +clippy::type_complexity 2 +clippy::unnecessary_cast 2 +clippy::unused_unit 2 +clippy::write_with_newline 2 +clippy::filter_map_next 3 +clippy::fn_params_excessive_bools 3 +clippy::mut_mut 3 +clippy::zero_ptr 3 +clippy::if_same_then_else 4 +clippy::let_underscore_drop 4 +clippy::too_many_arguments 4 +clippy::empty_enum 5 +clippy::explicit_iter_loop 5 +clippy::field_reassign_with_default 5 +clippy::identity_op 5 +clippy::len_without_is_empty 5 +clippy::match_like_matches_macro 5 +clippy::needless_return 5 +clippy::new_without_default 5 +clippy::manual_strip 6 +clippy::non_ascii_literal 6 +clippy::single_component_path_imports 6 +clippy::explicit_into_iter_loop 7 +clippy::map_clone 7 +clippy::option_map_unit_fn 7 +clippy::range_plus_one 7 +clippy::invalid_upcast_comparisons 8 +clippy::wrong_self_convention 8 +clippy::find_map 9 +clippy::manual_range_contains 10 +clippy::match_wildcard_for_single_variants 10 +clippy::missing_safety_doc 10 +clippy::needless_doctest_main 10 +clippy::multiple_crate_versions 11 +clippy::needless_lifetimes 12 +clippy::option_if_let_else 12 +clippy::cargo_common_metadata 13 +clippy::shadow_unrelated 13 +clippy::linkedlist 14 +clippy::single_char_add_str 14 +clippy::default_trait_access 16 +clippy::needless_pass_by_value 18 +clippy::cast_possible_wrap 19 +clippy::cast_sign_loss 19 +clippy::unnecessary_wraps 19 +clippy::unused_self 19 +clippy::unusual_byte_groupings 19 +clippy::map_unwrap_or 20 +clippy::struct_excessive_bools 20 +clippy::redundant_static_lifetimes 21 +clippy::cast_lossless 23 +clippy::trivially_copy_pass_by_ref 26 +clippy::redundant_else 29 +clippy::filter_map 31 +clippy::too_many_lines 31 +clippy::cast_precision_loss 35 +clippy::if_not_else 35 +clippy::enum_glob_use 40 +clippy::unseparated_literal_suffix 41 +clippy::single_match_else 45 +clippy::inline_always 59 +clippy::match_same_arms 64 +clippy::similar_names 79 +clippy::cast_possible_truncation 91 +clippy::redundant_field_names 111 +clippy::redundant_closure_for_method_calls 135 +clippy::module_name_repetitions 137 +clippy::items_after_statements 139 +clippy::wildcard_imports 160 +clippy::doc_markdown 178 +clippy::missing_errors_doc 338 +clippy::unreadable_literal 365 +clippy::must_use_candidate 552 -- cgit 1.4.1-3-g733a5 From b6ef1e282ef4c444ce7e5694547aaff4d55c5059 Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Sun, 27 Dec 2020 16:13:42 +0100 Subject: clippy dev crater: add option to only check a single one of the listed crates with --only crate --- clippy_dev/src/crater.rs | 26 +++++++++++++++++++------- clippy_dev/src/main.rs | 16 +++++++++++++--- 2 files changed, 32 insertions(+), 10 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/crater.rs b/clippy_dev/src/crater.rs index b0e7cb70c89..ee4ed451ed5 100644 --- a/clippy_dev/src/crater.rs +++ b/clippy_dev/src/crater.rs @@ -12,6 +12,7 @@ use std::collections::HashMap; use std::process::Command; use std::{fmt, fs::write, path::PathBuf}; +use clap::ArgMatches; use serde::{Deserialize, Serialize}; use serde_json::Value; @@ -200,7 +201,7 @@ fn parse_json_message(json_message: &str, krate: &Crate) -> ClippyWarning { } // the main fn -pub fn run() { +pub fn run(clap_config: &ArgMatches) { let cargo_clippy_path: PathBuf = PathBuf::from("target/debug/cargo-clippy"); println!("Compiling clippy..."); @@ -217,12 +218,23 @@ pub fn run() { // download and extract the crates, then run clippy on them and collect clippys warnings // flatten into one big list of warnings - let clippy_warnings: Vec = read_crates() - .into_iter() - .map(|krate| krate.download_and_extract()) - .map(|krate| krate.run_clippy_lints(&cargo_clippy_path)) - .flatten() - .collect(); + let clippy_warnings: Vec = if let Some(only_one_crate) = clap_config.value_of("only") { + // only check a single + read_crates() + .into_iter() + .map(|krate| krate.download_and_extract()) + .filter(|krate| krate.name == only_one_crate) + .map(|krate| krate.run_clippy_lints(&cargo_clippy_path)) + .flatten() + .collect() + } else { + read_crates() + .into_iter() + .map(|krate| krate.download_and_extract()) + .map(|krate| krate.run_clippy_lints(&cargo_clippy_path)) + .flatten() + .collect() + }; // generate some stats: diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index 6fb8b6f2899..c4688ba3000 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -10,8 +10,8 @@ fn main() { ("bless", Some(matches)) => { bless::bless(matches.is_present("ignore-timestamp")); }, - ("crater", Some(_)) => { - crater::run(); + ("crater", Some(matches)) => { + crater::run(&matches); }, ("fmt", Some(matches)) => { fmt::run(matches.is_present("check"), matches.is_present("verbose")); @@ -59,7 +59,17 @@ fn get_clap_config<'a>() -> ArgMatches<'a> { .help("Include files updated before clippy was built"), ), ) - .subcommand(SubCommand::with_name("crater").about("run clippy on a set of crates and check output")) + .subcommand( + SubCommand::with_name("crater") + .about("run clippy on a set of crates and check output") + .arg( + Arg::with_name("only") + .takes_value(true) + .value_name("CRATE") + .long("only") + .help("only process a single crate of the list"), + ), + ) .subcommand( SubCommand::with_name("fmt") .about("Run rustfmt on all projects and tests") -- cgit 1.4.1-3-g733a5 From ec1902ce4303632bbb155ade52877c072ff52348 Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Sun, 27 Dec 2020 16:20:32 +0100 Subject: cargo dev crater: throw an error if we can't find our specified crate in the .toml list --- clippy_dev/Cargo.toml | 14 ++++++++------ clippy_dev/src/crater.rs | 19 ++++++++++++++++--- clippy_dev/src/main.rs | 40 ++++++++++++++++++++++++---------------- 3 files changed, 48 insertions(+), 25 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/Cargo.toml b/clippy_dev/Cargo.toml index d6663145142..0333a260db1 100644 --- a/clippy_dev/Cargo.toml +++ b/clippy_dev/Cargo.toml @@ -4,20 +4,22 @@ version = "0.0.1" authors = ["Philipp Hansch "] edition = "2018" + [dependencies] bytecount = "0.6" clap = "2.33" -flate2 = "1.0.19" +flate2 = { version = "1.0.19" , optional = true} itertools = "0.9" opener = "0.4" regex = "1" -serde = {version = "1.0", features = ["derive"]} -serde_json = "1.0" +serde = { version = "1.0", features = ["derive"]} +serde_json = { version = "1.0" , optional = true} shell-escape = "0.1" -tar = "0.4.30" -toml = "0.5" -ureq = "2.0.0-rc3" +tar = { version = "0.4.30" , optional = true} +toml = { version = "0.5" , optional = true} +ureq = { version = "2.0.0-rc3" , optional = true} walkdir = "2" [features] +crater = ["flate2", "serde_json", "tar", "toml", "ureq"] deny-warnings = [] diff --git a/clippy_dev/src/crater.rs b/clippy_dev/src/crater.rs index ee4ed451ed5..61ada2c2f23 100644 --- a/clippy_dev/src/crater.rs +++ b/clippy_dev/src/crater.rs @@ -4,6 +4,7 @@ // When a new lint is introduced, we can search the results for new warnings and check for false // positives. +#![cfg(feature = "crater")] #![allow(clippy::filter_map)] use crate::clippy_project_root; @@ -218,9 +219,20 @@ pub fn run(clap_config: &ArgMatches) { // download and extract the crates, then run clippy on them and collect clippys warnings // flatten into one big list of warnings + let crates = read_crates(); + let clippy_warnings: Vec = if let Some(only_one_crate) = clap_config.value_of("only") { - // only check a single - read_crates() + // if we don't have the specified crated in the .toml, throw an error + if !crates.iter().any(|krate| krate.name == only_one_crate) { + eprintln!( + "ERROR: could not find crate '{}' in clippy_dev/crater_crates.toml", + only_one_crate + ); + std::process::exit(1); + } + + // only check a single crate that was passed via cmdline + crates .into_iter() .map(|krate| krate.download_and_extract()) .filter(|krate| krate.name == only_one_crate) @@ -228,7 +240,8 @@ pub fn run(clap_config: &ArgMatches) { .flatten() .collect() } else { - read_crates() + // check all crates (default) + crates .into_iter() .map(|krate| krate.download_and_extract()) .map(|krate| krate.run_clippy_lints(&cargo_clippy_path)) diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index c4688ba3000..e10c3dbe0bd 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -1,7 +1,10 @@ #![cfg_attr(feature = "deny-warnings", deny(warnings))] use clap::{App, Arg, ArgMatches, SubCommand}; -use clippy_dev::{bless, crater, fmt, new_lint, ra_setup, serve, stderr_length_check, update_lints}; +use clippy_dev::{bless, fmt, new_lint, ra_setup, serve, stderr_length_check, update_lints}; + +#[cfg(feature = "crater")] +use clippy_dev::crater; fn main() { let matches = get_clap_config(); @@ -10,6 +13,7 @@ fn main() { ("bless", Some(matches)) => { bless::bless(matches.is_present("ignore-timestamp")); }, + #[cfg(feature = "crater")] ("crater", Some(matches)) => { crater::run(&matches); }, @@ -49,8 +53,19 @@ fn main() { } fn get_clap_config<'a>() -> ArgMatches<'a> { - App::new("Clippy developer tooling") - .subcommand( + #[cfg(feature = "crater")] + let crater_sbcmd = SubCommand::with_name("crater") + .about("run clippy on a set of crates and check output") + .arg( + Arg::with_name("only") + .takes_value(true) + .value_name("CRATE") + .long("only") + .help("only process a single crate of the list"), + ); + + let app = App::new("Clippy developer tooling") + .subcommand( SubCommand::with_name("bless") .about("bless the test output changes") .arg( @@ -59,17 +74,6 @@ fn get_clap_config<'a>() -> ArgMatches<'a> { .help("Include files updated before clippy was built"), ), ) - .subcommand( - SubCommand::with_name("crater") - .about("run clippy on a set of crates and check output") - .arg( - Arg::with_name("only") - .takes_value(true) - .value_name("CRATE") - .long("only") - .help("only process a single crate of the list"), - ), - ) .subcommand( SubCommand::with_name("fmt") .about("Run rustfmt on all projects and tests") @@ -177,6 +181,10 @@ fn get_clap_config<'a>() -> ArgMatches<'a> { .validator_os(serve::validate_port), ) .arg(Arg::with_name("lint").help("Which lint's page to load initially (optional)")), - ) - .get_matches() + ); + + #[cfg(feature = "crater")] + let app = app.subcommand(crater_sbcmd); + + app.get_matches() } -- cgit 1.4.1-3-g733a5 From 48fc948ca3548d5bdcc479b5f9c317767d941e3b Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Tue, 29 Dec 2020 16:18:31 +0100 Subject: clippy dev crater: address more review commetns make serde a feature-dep save clippy version in the crater log --- clippy_dev/Cargo.toml | 14 +++++++------- clippy_dev/src/crater.rs | 9 ++++++++- clippy_dev/src/main.rs | 2 +- mini-crater/logs.txt | 10 ++++++++-- 4 files changed, 24 insertions(+), 11 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/Cargo.toml b/clippy_dev/Cargo.toml index 0333a260db1..4268ef80282 100644 --- a/clippy_dev/Cargo.toml +++ b/clippy_dev/Cargo.toml @@ -8,18 +8,18 @@ edition = "2018" [dependencies] bytecount = "0.6" clap = "2.33" -flate2 = { version = "1.0.19" , optional = true} +flate2 = { version = "1.0.19", optional = true } itertools = "0.9" opener = "0.4" regex = "1" -serde = { version = "1.0", features = ["derive"]} -serde_json = { version = "1.0" , optional = true} +serde = { version = "1.0", features = ["derive"], optional = true } +serde_json = { version = "1.0", optional = true } shell-escape = "0.1" -tar = { version = "0.4.30" , optional = true} -toml = { version = "0.5" , optional = true} -ureq = { version = "2.0.0-rc3" , optional = true} +tar = { version = "0.4.30", optional = true } +toml = { version = "0.5", optional = true } +ureq = { version = "2.0.0-rc3", optional = true } walkdir = "2" [features] -crater = ["flate2", "serde_json", "tar", "toml", "ureq"] +crater = ["flate2", "serde_json", "tar", "toml", "ureq", "serde"] deny-warnings = [] diff --git a/clippy_dev/src/crater.rs b/clippy_dev/src/crater.rs index 61ada2c2f23..98a4af3591e 100644 --- a/clippy_dev/src/crater.rs +++ b/clippy_dev/src/crater.rs @@ -216,6 +216,12 @@ pub fn run(clap_config: &ArgMatches) { cargo_clippy_path.display() ); + let clippy_ver = std::process::Command::new("target/debug/cargo-clippy") + .arg("--version") + .output() + .map(|o| String::from_utf8_lossy(&o.stdout).into_owned()) + .expect("could not get clippy version!"); + // download and extract the crates, then run clippy on them and collect clippys warnings // flatten into one big list of warnings @@ -274,6 +280,7 @@ pub fn run(clap_config: &ArgMatches) { all_msgs.push(stats_formatted); // save the text into mini-crater/logs.txt - let text = all_msgs.join(""); + let mut text = clippy_ver; // clippy version number on top + text.push_str(&format!("\n{}", all_msgs.join(""))); write("mini-crater/logs.txt", text).unwrap(); } diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index e10c3dbe0bd..c47aabc2e0a 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -65,7 +65,7 @@ fn get_clap_config<'a>() -> ArgMatches<'a> { ); let app = App::new("Clippy developer tooling") - .subcommand( + .subcommand( SubCommand::with_name("bless") .about("bless the test output changes") .arg( diff --git a/mini-crater/logs.txt b/mini-crater/logs.txt index 70b9baf0396..f9084dc8321 100644 --- a/mini-crater/logs.txt +++ b/mini-crater/logs.txt @@ -1,3 +1,5 @@ +clippy 0.0.212 (0d8a27a6f 2020-12-28) + cargo/0.49.0//home/matthias/.rustup/toolchains/nightly-2020-12-20-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/core/src/macros/mod.rs:393:34 clippy::match_same_arms "this `match` has identical arm bodies" cargo/0.49.0/build.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.categories` metadata" cargo/0.49.0/build.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.keywords` metadata" @@ -107,6 +109,7 @@ cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:96:31 clippy:: cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:98:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" cargo/0.49.0/src/cargo/core/compiler/build_plan.rs:4:9 clippy::doc_markdown "you should put `BuildPlan` between ticks in the documentation" cargo/0.49.0/src/cargo/core/compiler/build_plan.rs:5:66 clippy::doc_markdown "you should put `BuildPlan` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/build_plan.rs:66:40 clippy::ptr_arg "writing `&PathBuf` instead of `&Path` involves a new object where a slice will do." cargo/0.49.0/src/cargo/core/compiler/compilation.rs:150:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" cargo/0.49.0/src/cargo/core/compiler/compilation.rs:169:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" cargo/0.49.0/src/cargo/core/compiler/compilation.rs:185:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" @@ -237,6 +240,8 @@ cargo/0.49.0/src/cargo/core/compiler/mod.rs:364:5 clippy::items_after_statements cargo/0.49.0/src/cargo/core/compiler/mod.rs:364:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" cargo/0.49.0/src/cargo/core/compiler/mod.rs:392:45 clippy::redundant_closure_for_method_calls "redundant closure found" cargo/0.49.0/src/cargo/core/compiler/mod.rs:415:23 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/core/compiler/mod.rs:464:18 clippy::ptr_arg "writing `&PathBuf` instead of `&Path` involves a new object where a slice will do." +cargo/0.49.0/src/cargo/core/compiler/mod.rs:488:61 clippy::ptr_arg "writing `&PathBuf` instead of `&Path` involves a new object where a slice will do." cargo/0.49.0/src/cargo/core/compiler/mod.rs:667:15 clippy::similar_names "binding's name is too similar to existing binding" cargo/0.49.0/src/cargo/core/compiler/mod.rs:693:1 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" cargo/0.49.0/src/cargo/core/compiler/mod.rs:725:42 clippy::match_same_arms "this `match` has identical arm bodies" @@ -3059,9 +3064,9 @@ ripgrep/12.1.1/crates/core/search.rs:533:5 clippy::cast_precision_loss "casting ripgrep/12.1.1/crates/core/subject.rs:20:1 clippy::module_name_repetitions "item name starts with its containing module's name" ripgrep/12.1.1/crates/core/subject.rs:4:1 clippy::single_component_path_imports "this import is redundant" syn/1.0.54/build.rs:1:null clippy::cargo_common_metadata "package `syn` is missing `package.keywords` metadata" -syn/1.0.54/build.rs:1:null clippy::multiple_crate_versions "could not read cargo metadata: failed to run `cargo metadata`: Blocking waiting for file lock on package cache\n Blocking waiting for file lock on package cache\n Blocking waiting for file lock on package cache\n Downloading crates ...\n Downloaded ref-cast v1.0.5\n Downloaded ref-cast-impl v1.0.5\n Downloaded syn-test-suite v0.0.0\nerror: failed to verify the checksum of `syn-test-suite v0.0.0`" +syn/1.0.54/build.rs:1:null clippy::multiple_crate_versions "could not read cargo metadata: failed to run `cargo metadata`: Downloading crates ...\n Downloaded dtoa v0.4.7\n Downloaded anyhow v1.0.37\n Downloaded syn-test-suite v0.0.0\nerror: failed to verify the checksum of `syn-test-suite v0.0.0`" syn/1.0.54/src/lib.rs:1:null clippy::cargo_common_metadata "package `syn` is missing `package.keywords` metadata" -syn/1.0.54/src/lib.rs:1:null clippy::multiple_crate_versions "could not read cargo metadata: failed to run `cargo metadata`: Downloading crates ...\n Downloaded openssl-sys v0.9.60\n Downloaded syn-test-suite v0.0.0\nerror: failed to verify the checksum of `syn-test-suite v0.0.0`" +syn/1.0.54/src/lib.rs:1:null clippy::multiple_crate_versions "could not read cargo metadata: failed to run `cargo metadata`: Downloading crates ...\n Downloaded syn-test-suite v0.0.0\nerror: failed to verify the checksum of `syn-test-suite v0.0.0`" syn/1.0.54/src/lit.rs:1397:40 clippy::redundant_else "redundant else block" syn/1.0.54/src/lit.rs:1405:28 clippy::redundant_else "redundant else block" syn/1.0.54/src/lit.rs:1485:32 clippy::redundant_else "redundant else block" @@ -3293,6 +3298,7 @@ clippy::write_with_newline 2 clippy::filter_map_next 3 clippy::fn_params_excessive_bools 3 clippy::mut_mut 3 +clippy::ptr_arg 3 clippy::zero_ptr 3 clippy::if_same_then_else 4 clippy::let_underscore_drop 4 -- cgit 1.4.1-3-g733a5 From 83fcf95f52c6e4c9dbb840ce9e562f2d5c859cca Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Sat, 23 Jan 2021 00:25:29 +0100 Subject: rename cargo dev crater to cargo dev lintcheck --- .cargo/config | 2 +- clippy_dev/Cargo.toml | 2 +- clippy_dev/crater_crates.toml | 20 - clippy_dev/lintcheck_crates.toml | 20 + clippy_dev/src/crater.rs | 286 ---- clippy_dev/src/lib.rs | 2 +- clippy_dev/src/lintcheck.rs | 286 ++++ clippy_dev/src/main.rs | 18 +- lintcheck-logs/logs.txt | 3367 ++++++++++++++++++++++++++++++++++++++ mini-crater/logs.txt | 3367 -------------------------------------- 10 files changed, 3685 insertions(+), 3685 deletions(-) delete mode 100644 clippy_dev/crater_crates.toml create mode 100644 clippy_dev/lintcheck_crates.toml delete mode 100644 clippy_dev/src/crater.rs create mode 100644 clippy_dev/src/lintcheck.rs create mode 100644 lintcheck-logs/logs.txt delete mode 100644 mini-crater/logs.txt (limited to 'clippy_dev/src') diff --git a/.cargo/config b/.cargo/config index 220e74f5df4..1142cc470fe 100644 --- a/.cargo/config +++ b/.cargo/config @@ -1,7 +1,7 @@ [alias] uitest = "test --test compile-test" dev = "run --target-dir clippy_dev/target --package clippy_dev --bin clippy_dev --manifest-path clippy_dev/Cargo.toml --" -dev-crater = "run --target-dir clippy_dev/target --package clippy_dev --bin clippy_dev --manifest-path clippy_dev/Cargo.toml --features crater -- crater" +dev-lintcheck = "run --target-dir clippy_dev/target --package clippy_dev --bin clippy_dev --manifest-path clippy_dev/Cargo.toml --features lintcheck -- lintcheck" [build] rustflags = ["-Zunstable-options"] diff --git a/clippy_dev/Cargo.toml b/clippy_dev/Cargo.toml index 4268ef80282..f48c1ee5ea2 100644 --- a/clippy_dev/Cargo.toml +++ b/clippy_dev/Cargo.toml @@ -21,5 +21,5 @@ ureq = { version = "2.0.0-rc3", optional = true } walkdir = "2" [features] -crater = ["flate2", "serde_json", "tar", "toml", "ureq", "serde"] +lintcheck = ["flate2", "serde_json", "tar", "toml", "ureq", "serde"] deny-warnings = [] diff --git a/clippy_dev/crater_crates.toml b/clippy_dev/crater_crates.toml deleted file mode 100644 index 1fbf7930d3e..00000000000 --- a/clippy_dev/crater_crates.toml +++ /dev/null @@ -1,20 +0,0 @@ -[crates] -# some of these are from cargotest -cargo = ['0.49.0'] -iron = ['0.6.1'] -ripgrep = ['12.1.1'] -xsv = ['0.13.0'] -#tokei = ['12.0.4'] -rayon = ['1.5.0'] -serde = ['1.0.118'] -# top 10 crates.io dls -bitflags = ['1.2.1'] -libc = ['0.2.81'] -log = ['0.4.11'] -proc-macro2 = ['1.0.24'] -quote = ['1.0.7'] -rand = ['0.7.3'] -rand_core = ['0.6.0'] -regex = ['1.3.2'] -syn = ['1.0.54'] -unicode-xid = ['0.2.1'] diff --git a/clippy_dev/lintcheck_crates.toml b/clippy_dev/lintcheck_crates.toml new file mode 100644 index 00000000000..1fbf7930d3e --- /dev/null +++ b/clippy_dev/lintcheck_crates.toml @@ -0,0 +1,20 @@ +[crates] +# some of these are from cargotest +cargo = ['0.49.0'] +iron = ['0.6.1'] +ripgrep = ['12.1.1'] +xsv = ['0.13.0'] +#tokei = ['12.0.4'] +rayon = ['1.5.0'] +serde = ['1.0.118'] +# top 10 crates.io dls +bitflags = ['1.2.1'] +libc = ['0.2.81'] +log = ['0.4.11'] +proc-macro2 = ['1.0.24'] +quote = ['1.0.7'] +rand = ['0.7.3'] +rand_core = ['0.6.0'] +regex = ['1.3.2'] +syn = ['1.0.54'] +unicode-xid = ['0.2.1'] diff --git a/clippy_dev/src/crater.rs b/clippy_dev/src/crater.rs deleted file mode 100644 index 98a4af3591e..00000000000 --- a/clippy_dev/src/crater.rs +++ /dev/null @@ -1,286 +0,0 @@ -// Run clippy on a fixed set of crates and collect the warnings. -// This helps observing the impact clippy changs have on a set of real-world code. -// -// When a new lint is introduced, we can search the results for new warnings and check for false -// positives. - -#![cfg(feature = "crater")] -#![allow(clippy::filter_map)] - -use crate::clippy_project_root; - -use std::collections::HashMap; -use std::process::Command; -use std::{fmt, fs::write, path::PathBuf}; - -use clap::ArgMatches; -use serde::{Deserialize, Serialize}; -use serde_json::Value; - -// use this to store the crates when interacting with the crates.toml file -#[derive(Debug, Serialize, Deserialize)] -struct CrateList { - crates: HashMap>, -} - -// crate data we stored in the toml, can have multiple versions per crate -// A single TomlCrate is laster mapped to several CrateSources in that case -struct TomlCrate { - name: String, - versions: Vec, -} - -// represents an archive we download from crates.io -#[derive(Debug, Serialize, Deserialize, Eq, Hash, PartialEq)] -struct CrateSource { - name: String, - version: String, -} - -// represents the extracted sourcecode of a crate -#[derive(Debug)] -struct Crate { - version: String, - name: String, - // path to the extracted sources that clippy can check - path: PathBuf, -} - -#[derive(Debug)] -struct ClippyWarning { - crate_name: String, - crate_version: String, - file: String, - line: String, - column: String, - linttype: String, - message: String, -} - -impl std::fmt::Display for ClippyWarning { - fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { - writeln!( - f, - r#"{}/{}/{}:{}:{} {} "{}""#, - &self.crate_name, &self.crate_version, &self.file, &self.line, &self.column, &self.linttype, &self.message - ) - } -} - -impl CrateSource { - fn download_and_extract(&self) -> Crate { - let extract_dir = PathBuf::from("target/crater/crates"); - let krate_download_dir = PathBuf::from("target/crater/downloads"); - - // url to download the crate from crates.io - let url = format!( - "https://crates.io/api/v1/crates/{}/{}/download", - self.name, self.version - ); - println!("Downloading and extracting {} {} from {}", self.name, self.version, url); - let _ = std::fs::create_dir("target/crater/"); - let _ = std::fs::create_dir(&krate_download_dir); - let _ = std::fs::create_dir(&extract_dir); - - let krate_file_path = krate_download_dir.join(format!("{}-{}.crate.tar.gz", &self.name, &self.version)); - // don't download/extract if we already have done so - if !krate_file_path.is_file() { - // create a file path to download and write the crate data into - let mut krate_dest = std::fs::File::create(&krate_file_path).unwrap(); - let mut krate_req = ureq::get(&url).call().unwrap().into_reader(); - // copy the crate into the file - std::io::copy(&mut krate_req, &mut krate_dest).unwrap(); - - // unzip the tarball - let ungz_tar = flate2::read::GzDecoder::new(std::fs::File::open(&krate_file_path).unwrap()); - // extract the tar archive - let mut archive = tar::Archive::new(ungz_tar); - archive.unpack(&extract_dir).expect("Failed to extract!"); - } - // crate is extracted, return a new Krate object which contains the path to the extracted - // sources that clippy can check - Crate { - version: self.version.clone(), - name: self.name.clone(), - path: extract_dir.join(format!("{}-{}/", self.name, self.version)), - } - } -} - -impl Crate { - fn run_clippy_lints(&self, cargo_clippy_path: &PathBuf) -> Vec { - println!("Linting {} {}...", &self.name, &self.version); - let cargo_clippy_path = std::fs::canonicalize(cargo_clippy_path).unwrap(); - - let shared_target_dir = clippy_project_root().join("target/crater/shared_target_dir/"); - - let all_output = std::process::Command::new(cargo_clippy_path) - .env("CARGO_TARGET_DIR", shared_target_dir) - // lint warnings will look like this: - // src/cargo/ops/cargo_compile.rs:127:35: warning: usage of `FromIterator::from_iter` - .args(&[ - "--", - "--message-format=json", - "--", - "--cap-lints=warn", - "-Wclippy::pedantic", - "-Wclippy::cargo", - ]) - .current_dir(&self.path) - .output() - .unwrap(); - let stdout = String::from_utf8_lossy(&all_output.stdout); - let output_lines = stdout.lines(); - //dbg!(&output_lines); - let warnings: Vec = output_lines - .into_iter() - // get all clippy warnings - .filter(|line| line.contains("clippy::")) - .map(|json_msg| parse_json_message(json_msg, &self)) - .collect(); - warnings - } -} - -fn build_clippy() { - Command::new("cargo") - .arg("build") - .output() - .expect("Failed to build clippy!"); -} - -// get a list of CrateSources we want to check from a "crater_crates.toml" file. -fn read_crates() -> Vec { - let toml_path = PathBuf::from("clippy_dev/crater_crates.toml"); - let toml_content: String = - std::fs::read_to_string(&toml_path).unwrap_or_else(|_| panic!("Failed to read {}", toml_path.display())); - let crate_list: CrateList = - toml::from_str(&toml_content).unwrap_or_else(|e| panic!("Failed to parse {}: \n{}", toml_path.display(), e)); - // parse the hashmap of the toml file into a list of crates - let tomlcrates: Vec = crate_list - .crates - .into_iter() - .map(|(name, versions)| TomlCrate { name, versions }) - .collect(); - - // flatten TomlCrates into CrateSources (one TomlCrates may represent several versions of a crate => - // multiple Cratesources) - let mut crate_sources = Vec::new(); - tomlcrates.into_iter().for_each(|tk| { - tk.versions.iter().for_each(|ver| { - crate_sources.push(CrateSource { - name: tk.name.clone(), - version: ver.to_string(), - }); - }) - }); - crate_sources -} - -// extract interesting data from a json lint message -fn parse_json_message(json_message: &str, krate: &Crate) -> ClippyWarning { - let jmsg: Value = serde_json::from_str(&json_message).unwrap_or_else(|e| panic!("Failed to parse json:\n{:?}", e)); - - ClippyWarning { - crate_name: krate.name.to_string(), - crate_version: krate.version.to_string(), - file: jmsg["message"]["spans"][0]["file_name"] - .to_string() - .trim_matches('"') - .into(), - line: jmsg["message"]["spans"][0]["line_start"] - .to_string() - .trim_matches('"') - .into(), - column: jmsg["message"]["spans"][0]["text"][0]["highlight_start"] - .to_string() - .trim_matches('"') - .into(), - linttype: jmsg["message"]["code"]["code"].to_string().trim_matches('"').into(), - message: jmsg["message"]["message"].to_string().trim_matches('"').into(), - } -} - -// the main fn -pub fn run(clap_config: &ArgMatches) { - let cargo_clippy_path: PathBuf = PathBuf::from("target/debug/cargo-clippy"); - - println!("Compiling clippy..."); - build_clippy(); - println!("Done compiling"); - - // assert that clippy is found - assert!( - cargo_clippy_path.is_file(), - "target/debug/cargo-clippy binary not found! {}", - cargo_clippy_path.display() - ); - - let clippy_ver = std::process::Command::new("target/debug/cargo-clippy") - .arg("--version") - .output() - .map(|o| String::from_utf8_lossy(&o.stdout).into_owned()) - .expect("could not get clippy version!"); - - // download and extract the crates, then run clippy on them and collect clippys warnings - // flatten into one big list of warnings - - let crates = read_crates(); - - let clippy_warnings: Vec = if let Some(only_one_crate) = clap_config.value_of("only") { - // if we don't have the specified crated in the .toml, throw an error - if !crates.iter().any(|krate| krate.name == only_one_crate) { - eprintln!( - "ERROR: could not find crate '{}' in clippy_dev/crater_crates.toml", - only_one_crate - ); - std::process::exit(1); - } - - // only check a single crate that was passed via cmdline - crates - .into_iter() - .map(|krate| krate.download_and_extract()) - .filter(|krate| krate.name == only_one_crate) - .map(|krate| krate.run_clippy_lints(&cargo_clippy_path)) - .flatten() - .collect() - } else { - // check all crates (default) - crates - .into_iter() - .map(|krate| krate.download_and_extract()) - .map(|krate| krate.run_clippy_lints(&cargo_clippy_path)) - .flatten() - .collect() - }; - - // generate some stats: - - // count lint type occurrences - let mut counter: HashMap<&String, usize> = HashMap::new(); - clippy_warnings - .iter() - .for_each(|wrn| *counter.entry(&wrn.linttype).or_insert(0) += 1); - - // collect into a tupled list for sorting - let mut stats: Vec<(&&String, &usize)> = counter.iter().map(|(lint, count)| (lint, count)).collect(); - // sort by "000{count} {clippy::lintname}" - // to not have a lint with 200 and 2 warnings take the same spot - stats.sort_by_key(|(lint, count)| format!("{:0>4}, {}", count, lint)); - - let stats_formatted: String = stats - .iter() - .map(|(lint, count)| format!("{} {}\n", lint, count)) - .collect::(); - - let mut all_msgs: Vec = clippy_warnings.iter().map(|warning| warning.to_string()).collect(); - all_msgs.sort(); - all_msgs.push("\n\n\n\nStats\n\n".into()); - all_msgs.push(stats_formatted); - - // save the text into mini-crater/logs.txt - let mut text = clippy_ver; // clippy version number on top - text.push_str(&format!("\n{}", all_msgs.join(""))); - write("mini-crater/logs.txt", text).unwrap(); -} diff --git a/clippy_dev/src/lib.rs b/clippy_dev/src/lib.rs index 4873769b367..24d70d433f3 100644 --- a/clippy_dev/src/lib.rs +++ b/clippy_dev/src/lib.rs @@ -11,8 +11,8 @@ use std::path::{Path, PathBuf}; use walkdir::WalkDir; pub mod bless; -pub mod crater; pub mod fmt; +pub mod lintcheck; pub mod new_lint; pub mod ra_setup; pub mod serve; diff --git a/clippy_dev/src/lintcheck.rs b/clippy_dev/src/lintcheck.rs new file mode 100644 index 00000000000..e2099ff98c8 --- /dev/null +++ b/clippy_dev/src/lintcheck.rs @@ -0,0 +1,286 @@ +// Run clippy on a fixed set of crates and collect the warnings. +// This helps observing the impact clippy changs have on a set of real-world code. +// +// When a new lint is introduced, we can search the results for new warnings and check for false +// positives. + +#![cfg(feature = "lintcheck")] +#![allow(clippy::filter_map)] + +use crate::clippy_project_root; + +use std::collections::HashMap; +use std::process::Command; +use std::{fmt, fs::write, path::PathBuf}; + +use clap::ArgMatches; +use serde::{Deserialize, Serialize}; +use serde_json::Value; + +// use this to store the crates when interacting with the crates.toml file +#[derive(Debug, Serialize, Deserialize)] +struct CrateList { + crates: HashMap>, +} + +// crate data we stored in the toml, can have multiple versions per crate +// A single TomlCrate is laster mapped to several CrateSources in that case +struct TomlCrate { + name: String, + versions: Vec, +} + +// represents an archive we download from crates.io +#[derive(Debug, Serialize, Deserialize, Eq, Hash, PartialEq)] +struct CrateSource { + name: String, + version: String, +} + +// represents the extracted sourcecode of a crate +#[derive(Debug)] +struct Crate { + version: String, + name: String, + // path to the extracted sources that clippy can check + path: PathBuf, +} + +#[derive(Debug)] +struct ClippyWarning { + crate_name: String, + crate_version: String, + file: String, + line: String, + column: String, + linttype: String, + message: String, +} + +impl std::fmt::Display for ClippyWarning { + fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { + writeln!( + f, + r#"{}/{}/{}:{}:{} {} "{}""#, + &self.crate_name, &self.crate_version, &self.file, &self.line, &self.column, &self.linttype, &self.message + ) + } +} + +impl CrateSource { + fn download_and_extract(&self) -> Crate { + let extract_dir = PathBuf::from("target/lintcheck/crates"); + let krate_download_dir = PathBuf::from("target/lintcheck/downloads"); + + // url to download the crate from crates.io + let url = format!( + "https://crates.io/api/v1/crates/{}/{}/download", + self.name, self.version + ); + println!("Downloading and extracting {} {} from {}", self.name, self.version, url); + let _ = std::fs::create_dir("target/lintcheck/"); + let _ = std::fs::create_dir(&krate_download_dir); + let _ = std::fs::create_dir(&extract_dir); + + let krate_file_path = krate_download_dir.join(format!("{}-{}.crate.tar.gz", &self.name, &self.version)); + // don't download/extract if we already have done so + if !krate_file_path.is_file() { + // create a file path to download and write the crate data into + let mut krate_dest = std::fs::File::create(&krate_file_path).unwrap(); + let mut krate_req = ureq::get(&url).call().unwrap().into_reader(); + // copy the crate into the file + std::io::copy(&mut krate_req, &mut krate_dest).unwrap(); + + // unzip the tarball + let ungz_tar = flate2::read::GzDecoder::new(std::fs::File::open(&krate_file_path).unwrap()); + // extract the tar archive + let mut archive = tar::Archive::new(ungz_tar); + archive.unpack(&extract_dir).expect("Failed to extract!"); + } + // crate is extracted, return a new Krate object which contains the path to the extracted + // sources that clippy can check + Crate { + version: self.version.clone(), + name: self.name.clone(), + path: extract_dir.join(format!("{}-{}/", self.name, self.version)), + } + } +} + +impl Crate { + fn run_clippy_lints(&self, cargo_clippy_path: &PathBuf) -> Vec { + println!("Linting {} {}...", &self.name, &self.version); + let cargo_clippy_path = std::fs::canonicalize(cargo_clippy_path).unwrap(); + + let shared_target_dir = clippy_project_root().join("target/lintcheck/shared_target_dir/"); + + let all_output = std::process::Command::new(cargo_clippy_path) + .env("CARGO_TARGET_DIR", shared_target_dir) + // lint warnings will look like this: + // src/cargo/ops/cargo_compile.rs:127:35: warning: usage of `FromIterator::from_iter` + .args(&[ + "--", + "--message-format=json", + "--", + "--cap-lints=warn", + "-Wclippy::pedantic", + "-Wclippy::cargo", + ]) + .current_dir(&self.path) + .output() + .unwrap(); + let stdout = String::from_utf8_lossy(&all_output.stdout); + let output_lines = stdout.lines(); + //dbg!(&output_lines); + let warnings: Vec = output_lines + .into_iter() + // get all clippy warnings + .filter(|line| line.contains("clippy::")) + .map(|json_msg| parse_json_message(json_msg, &self)) + .collect(); + warnings + } +} + +fn build_clippy() { + Command::new("cargo") + .arg("build") + .output() + .expect("Failed to build clippy!"); +} + +// get a list of CrateSources we want to check from a "lintcheck_crates.toml" file. +fn read_crates() -> Vec { + let toml_path = PathBuf::from("clippy_dev/lintcheck_crates.toml"); + let toml_content: String = + std::fs::read_to_string(&toml_path).unwrap_or_else(|_| panic!("Failed to read {}", toml_path.display())); + let crate_list: CrateList = + toml::from_str(&toml_content).unwrap_or_else(|e| panic!("Failed to parse {}: \n{}", toml_path.display(), e)); + // parse the hashmap of the toml file into a list of crates + let tomlcrates: Vec = crate_list + .crates + .into_iter() + .map(|(name, versions)| TomlCrate { name, versions }) + .collect(); + + // flatten TomlCrates into CrateSources (one TomlCrates may represent several versions of a crate => + // multiple Cratesources) + let mut crate_sources = Vec::new(); + tomlcrates.into_iter().for_each(|tk| { + tk.versions.iter().for_each(|ver| { + crate_sources.push(CrateSource { + name: tk.name.clone(), + version: ver.to_string(), + }); + }) + }); + crate_sources +} + +// extract interesting data from a json lint message +fn parse_json_message(json_message: &str, krate: &Crate) -> ClippyWarning { + let jmsg: Value = serde_json::from_str(&json_message).unwrap_or_else(|e| panic!("Failed to parse json:\n{:?}", e)); + + ClippyWarning { + crate_name: krate.name.to_string(), + crate_version: krate.version.to_string(), + file: jmsg["message"]["spans"][0]["file_name"] + .to_string() + .trim_matches('"') + .into(), + line: jmsg["message"]["spans"][0]["line_start"] + .to_string() + .trim_matches('"') + .into(), + column: jmsg["message"]["spans"][0]["text"][0]["highlight_start"] + .to_string() + .trim_matches('"') + .into(), + linttype: jmsg["message"]["code"]["code"].to_string().trim_matches('"').into(), + message: jmsg["message"]["message"].to_string().trim_matches('"').into(), + } +} + +// the main fn +pub fn run(clap_config: &ArgMatches) { + let cargo_clippy_path: PathBuf = PathBuf::from("target/debug/cargo-clippy"); + + println!("Compiling clippy..."); + build_clippy(); + println!("Done compiling"); + + // assert that clippy is found + assert!( + cargo_clippy_path.is_file(), + "target/debug/cargo-clippy binary not found! {}", + cargo_clippy_path.display() + ); + + let clippy_ver = std::process::Command::new("target/debug/cargo-clippy") + .arg("--version") + .output() + .map(|o| String::from_utf8_lossy(&o.stdout).into_owned()) + .expect("could not get clippy version!"); + + // download and extract the crates, then run clippy on them and collect clippys warnings + // flatten into one big list of warnings + + let crates = read_crates(); + + let clippy_warnings: Vec = if let Some(only_one_crate) = clap_config.value_of("only") { + // if we don't have the specified crated in the .toml, throw an error + if !crates.iter().any(|krate| krate.name == only_one_crate) { + eprintln!( + "ERROR: could not find crate '{}' in clippy_dev/lintcheck_crates.toml", + only_one_crate + ); + std::process::exit(1); + } + + // only check a single crate that was passed via cmdline + crates + .into_iter() + .map(|krate| krate.download_and_extract()) + .filter(|krate| krate.name == only_one_crate) + .map(|krate| krate.run_clippy_lints(&cargo_clippy_path)) + .flatten() + .collect() + } else { + // check all crates (default) + crates + .into_iter() + .map(|krate| krate.download_and_extract()) + .map(|krate| krate.run_clippy_lints(&cargo_clippy_path)) + .flatten() + .collect() + }; + + // generate some stats: + + // count lint type occurrences + let mut counter: HashMap<&String, usize> = HashMap::new(); + clippy_warnings + .iter() + .for_each(|wrn| *counter.entry(&wrn.linttype).or_insert(0) += 1); + + // collect into a tupled list for sorting + let mut stats: Vec<(&&String, &usize)> = counter.iter().map(|(lint, count)| (lint, count)).collect(); + // sort by "000{count} {clippy::lintname}" + // to not have a lint with 200 and 2 warnings take the same spot + stats.sort_by_key(|(lint, count)| format!("{:0>4}, {}", count, lint)); + + let stats_formatted: String = stats + .iter() + .map(|(lint, count)| format!("{} {}\n", lint, count)) + .collect::(); + + let mut all_msgs: Vec = clippy_warnings.iter().map(|warning| warning.to_string()).collect(); + all_msgs.sort(); + all_msgs.push("\n\n\n\nStats\n\n".into()); + all_msgs.push(stats_formatted); + + // save the text into lintcheck-logs/logs.txt + let mut text = clippy_ver; // clippy version number on top + text.push_str(&format!("\n{}", all_msgs.join(""))); + write("lintcheck-logs/logs.txt", text).unwrap(); +} diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index c47aabc2e0a..e7a298a37e1 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -3,8 +3,8 @@ use clap::{App, Arg, ArgMatches, SubCommand}; use clippy_dev::{bless, fmt, new_lint, ra_setup, serve, stderr_length_check, update_lints}; -#[cfg(feature = "crater")] -use clippy_dev::crater; +#[cfg(feature = "lintcheck")] +use clippy_dev::lintcheck; fn main() { let matches = get_clap_config(); @@ -13,9 +13,9 @@ fn main() { ("bless", Some(matches)) => { bless::bless(matches.is_present("ignore-timestamp")); }, - #[cfg(feature = "crater")] - ("crater", Some(matches)) => { - crater::run(&matches); + #[cfg(feature = "lintcheck")] + ("lintcheck", Some(matches)) => { + lintcheck::run(&matches); }, ("fmt", Some(matches)) => { fmt::run(matches.is_present("check"), matches.is_present("verbose")); @@ -53,8 +53,8 @@ fn main() { } fn get_clap_config<'a>() -> ArgMatches<'a> { - #[cfg(feature = "crater")] - let crater_sbcmd = SubCommand::with_name("crater") + #[cfg(feature = "lintcheck")] + let lintcheck_sbcmd = SubCommand::with_name("lintcheck") .about("run clippy on a set of crates and check output") .arg( Arg::with_name("only") @@ -183,8 +183,8 @@ fn get_clap_config<'a>() -> ArgMatches<'a> { .arg(Arg::with_name("lint").help("Which lint's page to load initially (optional)")), ); - #[cfg(feature = "crater")] - let app = app.subcommand(crater_sbcmd); + #[cfg(feature = "lintcheck")] + let app = app.subcommand(lintcheck_sbcmd); app.get_matches() } diff --git a/lintcheck-logs/logs.txt b/lintcheck-logs/logs.txt new file mode 100644 index 00000000000..f9084dc8321 --- /dev/null +++ b/lintcheck-logs/logs.txt @@ -0,0 +1,3367 @@ +clippy 0.0.212 (0d8a27a6f 2020-12-28) + +cargo/0.49.0//home/matthias/.rustup/toolchains/nightly-2020-12-20-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/core/src/macros/mod.rs:393:34 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/build.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.categories` metadata" +cargo/0.49.0/build.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.keywords` metadata" +cargo/0.49.0/src/bin/cargo/cli.rs:104:34 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/bin/cargo/cli.rs:121:5 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo/0.49.0/src/bin/cargo/cli.rs:157:30 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/cli.rs:184:41 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +cargo/0.49.0/src/bin/cargo/cli.rs:196:42 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/cli.rs:200:39 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/cli.rs:231:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo/0.49.0/src/bin/cargo/cli.rs:245:22 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +cargo/0.49.0/src/bin/cargo/cli.rs:247:47 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/cli.rs:257:22 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/cli.rs:26:20 clippy::redundant_else "redundant else block" +cargo/0.49.0/src/bin/cargo/cli.rs:7:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/bench.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/bench.rs:76:59 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/commands/build.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/check.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/clean.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/doc.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/fetch.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/fix.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/generate_lockfile.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/git_checkout.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/help.rs:20:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/bin/cargo/commands/init.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/install.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/install.rs:97:16 clippy::option_if_let_else "use Option::map_or instead of an if let/else" +cargo/0.49.0/src/bin/cargo/commands/locate_project.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/login.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/metadata.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/mod.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/new.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/new.rs:20:24 clippy::option_if_let_else "use Option::map_or instead of an if let/else" +cargo/0.49.0/src/bin/cargo/commands/owner.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/owner.rs:38:43 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/commands/owner.rs:39:43 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/commands/owner.rs:40:43 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/commands/owner.rs:43:30 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/commands/owner.rs:46:30 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/commands/package.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/pkgid.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/publish.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/publish.rs:40:47 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/commands/read_manifest.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/run.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/rustc.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/rustdoc.rs:3:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/search.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/test.rs:127:54 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/commands/test.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/tree.rs:149:49 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/commands/tree.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/uninstall.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/update.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/vendor.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/vendor.rs:96:16 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +cargo/0.49.0/src/bin/cargo/commands/verify_project.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/version.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/yank.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/commands/yank.rs:32:36 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/commands/yank.rs:33:35 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/commands/yank.rs:34:36 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/commands/yank.rs:35:36 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/main.rs:100:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +cargo/0.49.0/src/bin/cargo/main.rs:118:41 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/main.rs:137:43 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/main.rs:148:19 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/bin/cargo/main.rs:174:57 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/main.rs:18:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/bin/cargo/main.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.categories` metadata" +cargo/0.49.0/src/bin/cargo/main.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.keywords` metadata" +cargo/0.49.0/src/bin/cargo/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `crossbeam-utils`: 0.6.6, 0.7.2" +cargo/0.49.0/src/bin/cargo/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `hex`: 0.3.2, 0.4.0" +cargo/0.49.0/src/bin/cargo/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `humantime`: 1.3.0, 2.0.0" +cargo/0.49.0/src/bin/cargo/main.rs:72:22 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/main.rs:94:13 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +cargo/0.49.0/src/bin/cargo/main.rs:96:41 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/bin/cargo/main.rs:98:60 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/compiler/build_config.rs:155:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +cargo/0.49.0/src/cargo/core/compiler/build_config.rs:170:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/build_config.rs:175:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/build_config.rs:180:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/build_config.rs:186:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/build_config.rs:197:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/build_config.rs:205:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/build_config.rs:51:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/build_config.rs:69:48 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +cargo/0.49.0/src/cargo/core/compiler/build_config.rs:96:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/build_context/mod.rs:44:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/build_context/mod.rs:83:20 clippy::doc_markdown "you should put `x86_64` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:108:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:121:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:149:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:420:69 clippy::doc_markdown "you should put `mode/target_kind` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:423:19 clippy::doc_markdown "you should put `CrateTypes` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:424:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:469:58 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:591:20 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:603:19 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:665:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:82:31 clippy::doc_markdown "you should put `FileType` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:83:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:84:9 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:96:31 clippy::doc_markdown "you should put `FileType` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:98:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/build_plan.rs:4:9 clippy::doc_markdown "you should put `BuildPlan` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/build_plan.rs:5:66 clippy::doc_markdown "you should put `BuildPlan` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/build_plan.rs:66:40 clippy::ptr_arg "writing `&PathBuf` instead of `&Path` involves a new object where a slice will do." +cargo/0.49.0/src/cargo/core/compiler/compilation.rs:150:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/compilation.rs:169:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/compilation.rs:185:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/compilation.rs:193:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/compilation.rs:194:49 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/compiler/compilation.rs:198:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/compilation.rs:314:16 clippy::doc_markdown "you should put `rustc_tool` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/compilation.rs:91:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/compile_kind.rs:118:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/compile_kind.rs:147:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/compile_kind.rs:157:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/compile_kind.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/compile_kind.rs:33:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/compile_kind.rs:49:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/context/compilation_files.rs:204:9 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/core/compiler/context/compilation_files.rs:277:22 clippy::doc_markdown "you should put `OUT_DIR` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/context/compilation_files.rs:324:66 clippy::doc_markdown "you should put `FileType` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/context/compilation_files.rs:393:37 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/compiler/context/compilation_files.rs:426:71 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:125:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:125:5 clippy::too_many_lines "this function has too many lines (107/100)" +cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:270:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:286:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:308:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:340:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:349:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:354:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:358:21 clippy::doc_markdown "you should put `RunCustomBuild` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:361:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:365:9 clippy::find_map "called `find(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:374:43 clippy::doc_markdown "you should put `RunCustomBuild` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:378:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:383:41 clippy::doc_markdown "you should put `RunCustomBuild` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:384:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:391:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:397:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:523:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:538:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:542:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:83:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:92:25 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/core/compiler/crate_type.rs:16:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/crate_type.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/crate_type.rs:40:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/crate_type.rs:49:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/crate_type.rs:60:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:150:1 clippy::too_many_lines "this function has too many lines (230/100)" +cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:154:29 clippy::find_map "called `find(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:353:56 clippy::manual_strip "stripping a prefix manually" +cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:448:27 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:464:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:481:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:48:56 clippy::doc_markdown "you should put `RunCustomBuild` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:561:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:567:20 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:576:28 clippy::shadow_unrelated "`mut value` is being shadowed" +cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:606:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:624:13 clippy::find_map "called `find(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:688:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:756:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:762:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:762:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:823:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1021:51 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1252:20 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1278:19 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1656:16 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1664:5 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1787:5 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1795:5 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1882:17 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1894:17 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1906:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1917:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1923:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1956:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1962:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1963:22 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1964:22 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1965:22 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1966:22 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1980:17 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1980:24 clippy::manual_strip "stripping a prefix manually" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1986:17 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:2016:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:61:5 clippy::doc_markdown "you should put `CompileMode` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:63:12 clippy::doc_markdown "you should put `CompileKind` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:67:7 clippy::doc_markdown "you should put `CARGO_DEFAULT_LIB_METADATA[^4` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:68:5 clippy::doc_markdown "you should put `package_id` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:71:19 clippy::doc_markdown "you should put `test/bench/for_host/edition` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:755:52 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:77:5 clippy::doc_markdown "you should put `is_std` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:816:5 clippy::too_many_lines "this function has too many lines (127/100)" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:863:64 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:875:33 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:876:32 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:896:30 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:897:30 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:991:37 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:12:5 clippy::doc_markdown "you should put `src/librustc_jobserver/lib.rs` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:282:30 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:329:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:332:23 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:34:53 clippy::doc_markdown "you should put `NeedsToken` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:35:6 clippy::doc_markdown "you should put `ReleaseToken` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:37:6 clippy::doc_markdown "you should put `NeedsToken` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:40:5 clippy::doc_markdown "you should put `NeedsToken` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:40:56 clippy::doc_markdown "you should put `NeedsToken` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:43:6 clippy::doc_markdown "you should put `ReleaseToken` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:749:13 clippy::if_not_else "unnecessary boolean `not` operation" +cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:786:26 clippy::unused_self "unused `self` argument" +cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:81:61 clippy::doc_markdown "you should put `DrainState` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:865:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:871:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:890:9 clippy::unused_self "unused `self` argument" +cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:93:24 clippy::doc_markdown "you should put `JobQueue` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/links.rs:8:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/core/compiler/mod.rs:1016:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/mod.rs:1094:19 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/compiler/mod.rs:1131:1 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo/0.49.0/src/cargo/core/compiler/mod.rs:1277:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/compiler/mod.rs:179:1 clippy::too_many_lines "this function has too many lines (162/100)" +cargo/0.49.0/src/cargo/core/compiler/mod.rs:198:78 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/compiler/mod.rs:201:25 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/core/compiler/mod.rs:267:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/compiler/mod.rs:324:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/compiler/mod.rs:364:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/compiler/mod.rs:364:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo/0.49.0/src/cargo/core/compiler/mod.rs:392:45 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/compiler/mod.rs:415:23 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/core/compiler/mod.rs:464:18 clippy::ptr_arg "writing `&PathBuf` instead of `&Path` involves a new object where a slice will do." +cargo/0.49.0/src/cargo/core/compiler/mod.rs:488:61 clippy::ptr_arg "writing `&PathBuf` instead of `&Path` involves a new object where a slice will do." +cargo/0.49.0/src/cargo/core/compiler/mod.rs:667:15 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/core/compiler/mod.rs:693:1 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo/0.49.0/src/cargo/core/compiler/mod.rs:725:42 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/compiler/mod.rs:736:1 clippy::too_many_lines "this function has too many lines (141/100)" +cargo/0.49.0/src/cargo/core/compiler/mod.rs:73:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/mod.rs:777:12 clippy::if_not_else "unnecessary boolean `not` operation" +cargo/0.49.0/src/cargo/core/compiler/mod.rs:873:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/compiler/output_depinfo.rs:41:13 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +cargo/0.49.0/src/cargo/core/compiler/rustdoc.rs:16:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/core/compiler/rustdoc.rs:57:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/core/compiler/rustdoc.rs:72:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/standard_lib.rs:134:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/standard_lib.rs:16:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/standard_lib.rs:30:28 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/compiler/standard_lib.rs:34:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/timings.rs:16:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo/0.49.0/src/cargo/core/compiler/timings.rs:192:64 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo/0.49.0/src/cargo/core/compiler/timings.rs:212:58 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo/0.49.0/src/cargo/core/compiler/timings.rs:234:13 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" +cargo/0.49.0/src/cargo/core/compiler/timings.rs:355:13 clippy::cast_possible_truncation "casting `f64` to `u32` may truncate the value" +cargo/0.49.0/src/cargo/core/compiler/timings.rs:355:13 clippy::cast_sign_loss "casting `f64` to `u32` may lose the sign of the value" +cargo/0.49.0/src/cargo/core/compiler/timings.rs:397:38 clippy::cast_possible_truncation "casting `f64` to `u32` may truncate the value" +cargo/0.49.0/src/cargo/core/compiler/timings.rs:397:38 clippy::cast_sign_loss "casting `f64` to `u32` may lose the sign of the value" +cargo/0.49.0/src/cargo/core/compiler/timings.rs:484:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/compiler/timings.rs:605:38 clippy::doc_markdown "you should put `rmeta_time` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/timings.rs:605:50 clippy::doc_markdown "you should put `codegen_time` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/timings.rs:641:26 clippy::non_ascii_literal "literal non-ASCII character detected" +cargo/0.49.0/src/cargo/core/compiler/unit.rs:100:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/unit.rs:151:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/core/compiler/unit.rs:161:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/compiler/unit.rs:35:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/core/compiler/unit_dependencies.rs:154:29 clippy::doc_markdown "you should put `state.unit_dependencies` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/compiler/unit_dependencies.rs:213:1 clippy::too_many_lines "this function has too many lines (110/100)" +cargo/0.49.0/src/cargo/core/compiler/unit_dependencies.rs:329:13 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/core/compiler/unit_dependencies.rs:480:5 clippy::find_map "called `find(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/core/compiler/unit_dependencies.rs:511:5 clippy::find_map "called `find(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/core/compiler/unit_dependencies.rs:52:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/unit_dependencies.rs:52:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/core/compiler/unit_graph.rs:65:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/compiler/unit_graph.rs:65:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/core/dependency.rs:157:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/dependency.rs:182:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/dependency.rs:203:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/dependency.rs:224:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/dependency.rs:23:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo/0.49.0/src/cargo/core/dependency.rs:248:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/dependency.rs:270:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/dependency.rs:274:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/dependency.rs:278:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/dependency.rs:287:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/dependency.rs:291:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/dependency.rs:305:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/dependency.rs:311:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/dependency.rs:319:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/dependency.rs:337:75 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/dependency.rs:397:56 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/dependency.rs:403:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/dependency.rs:408:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/dependency.rs:415:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/dependency.rs:419:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/dependency.rs:424:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/dependency.rs:428:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/dependency.rs:433:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/dependency.rs:438:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/dependency.rs:443:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/dependency.rs:449:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/dependency.rs:450:9 clippy::if_not_else "unnecessary `!=` operation" +cargo/0.49.0/src/cargo/core/features.rs:119:17 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/features.rs:229:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/features.rs:274:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/features.rs:278:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/features.rs:306:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/features.rs:338:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo/0.49.0/src/cargo/core/features.rs:362:25 clippy::option_option "consider using `Option` instead of `Option>` or a custom enum if you need to distinguish all 3 cases" +cargo/0.49.0/src/cargo/core/features.rs:380:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/features.rs:401:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/features.rs:409:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/features.rs:412:45 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/features.rs:416:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/features.rs:419:45 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/features.rs:424:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/features.rs:431:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/features.rs:477:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/features.rs:509:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/features.rs:518:5 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +cargo/0.49.0/src/cargo/core/features.rs:542:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/features.rs:543:37 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/features.rs:547:60 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/features.rs:556:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/core/features.rs:563:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/core/manifest.rs:116:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +cargo/0.49.0/src/cargo/core/manifest.rs:118:58 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/manifest.rs:130:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +cargo/0.49.0/src/cargo/core/manifest.rs:143:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:159:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:162:34 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/manifest.rs:169:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:17:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/cargo/core/manifest.rs:189:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo/0.49.0/src/cargo/core/manifest.rs:215:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:222:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:22:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/core/manifest.rs:360:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:407:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:410:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:413:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:416:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:419:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:422:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:425:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:431:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:438:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:444:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:447:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:450:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:453:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:456:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:459:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:462:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:466:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:470:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:477:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:481:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:488:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/manifest.rs:512:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:516:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:520:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:524:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:528:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:538:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:557:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:561:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:565:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:569:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:577:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:581:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:588:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:617:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:632:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:648:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:659:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:66:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/core/manifest.rs:670:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:693:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:708:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:723:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:726:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:729:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:735:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:738:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:741:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:744:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:747:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:751:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:754:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:757:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:760:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:763:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:767:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:776:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:780:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:787:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:798:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:800:56 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/manifest.rs:805:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:809:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:818:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:823:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:828:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:831:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:834:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:839:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:85:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/core/manifest.rs:888:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/manifest.rs:936:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package.rs:1075:28 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/package.rs:160:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package.rs:170:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package.rs:174:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package.rs:182:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package.rs:186:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package.rs:190:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package.rs:194:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package.rs:198:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package.rs:202:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package.rs:206:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package.rs:210:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package.rs:217:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package.rs:221:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package.rs:222:35 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/package.rs:226:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package.rs:227:35 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/package.rs:230:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package.rs:239:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/package.rs:249:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package.rs:287:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/core/package.rs:385:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/package.rs:421:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +cargo/0.49.0/src/cargo/core/package.rs:425:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/package.rs:452:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/package.rs:453:60 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/package.rs:459:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/package.rs:473:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/package.rs:587:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/package.rs:682:46 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" +cargo/0.49.0/src/cargo/core/package.rs:682:46 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" +cargo/0.49.0/src/cargo/core/package.rs:682:63 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" +cargo/0.49.0/src/cargo/core/package.rs:682:63 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" +cargo/0.49.0/src/cargo/core/package.rs:731:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/package.rs:790:13 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/core/package.rs:988:9 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/core/package_id.rs:115:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/package_id.rs:124:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package_id.rs:139:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package_id.rs:142:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package_id.rs:145:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package_id.rs:149:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package_id.rs:157:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package_id.rs:161:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package_id.rs:169:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package_id.rs:174:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/core/package_id_spec.rs:101:39 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/package_id_spec.rs:143:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package_id_spec.rs:147:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package_id_spec.rs:151:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package_id_spec.rs:160:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/package_id_spec.rs:179:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/package_id_spec.rs:212:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/package_id_spec.rs:231:9 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/core/package_id_spec.rs:51:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/package_id_spec.rs:77:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/package_id_spec.rs:88:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/profiles.rs:1004:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/profiles.rs:1014:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/profiles.rs:1018:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/profiles.rs:1028:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/profiles.rs:106:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/profiles.rs:143:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo/0.49.0/src/cargo/core/profiles.rs:286:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/profiles.rs:294:40 clippy::if_not_else "unnecessary boolean `not` operation" +cargo/0.49.0/src/cargo/core/profiles.rs:30:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/profiles.rs:342:25 clippy::shadow_unrelated "`maker` is being shadowed" +cargo/0.49.0/src/cargo/core/profiles.rs:370:41 clippy::unused_self "unused `self` argument" +cargo/0.49.0/src/cargo/core/profiles.rs:370:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/profiles.rs:372:9 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" +cargo/0.49.0/src/cargo/core/profiles.rs:382:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/profiles.rs:383:28 clippy::if_not_else "unnecessary boolean `not` operation" +cargo/0.49.0/src/cargo/core/profiles.rs:397:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/profiles.rs:405:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/profiles.rs:607:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo/0.49.0/src/cargo/core/profiles.rs:909:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/profiles.rs:923:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/profiles.rs:934:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/profiles.rs:987:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/registry.rs:111:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/registry.rs:127:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/registry.rs:168:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/registry.rs:19:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/registry.rs:240:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/registry.rs:26:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/registry.rs:344:49 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/registry.rs:369:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/registry.rs:424:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/registry.rs:49:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/core/registry.rs:520:17 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/core/registry.rs:763:53 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/registry.rs:765:53 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/registry.rs:807:14 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/registry.rs:814:53 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/resolver/conflict_cache.rs:197:29 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/resolver/conflict_cache.rs:41:38 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +cargo/0.49.0/src/cargo/core/resolver/context.rs:274:53 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/resolver/context.rs:297:9 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/core/resolver/context.rs:42:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/core/resolver/context.rs:74:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/encode.rs:156:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/resolver/encode.rs:156:5 clippy::too_many_lines "this function has too many lines (164/100)" +cargo/0.49.0/src/cargo/core/resolver/encode.rs:339:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +cargo/0.49.0/src/cargo/core/resolver/encode.rs:438:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/resolver/encode.rs:449:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/resolver/encode.rs:529:34 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/resolver/encode.rs:602:59 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/resolver/encode.rs:623:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/core/resolver/encode.rs:652:27 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/core/resolver/encode.rs:674:51 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/resolver/errors.rs:103:22 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/resolver/errors.rs:104:22 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/resolver/errors.rs:206:9 clippy::if_not_else "unnecessary boolean `not` operation" +cargo/0.49.0/src/cargo/core/resolver/errors.rs:257:45 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/resolver/errors.rs:27:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/errors.rs:305:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo/0.49.0/src/cargo/core/resolver/errors.rs:70:1 clippy::too_many_lines "this function has too many lines (207/100)" +cargo/0.49.0/src/cargo/core/resolver/features.rs:104:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/core/resolver/features.rs:111:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/features.rs:162:56 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/resolver/features.rs:179:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/core/resolver/features.rs:186:23 clippy::doc_markdown "you should put `RequestedFeatures` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/resolver/features.rs:187:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/features.rs:199:23 clippy::doc_markdown "you should put `RequestedFeatures` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/resolver/features.rs:200:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/features.rs:209:9 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/core/resolver/features.rs:221:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/features.rs:231:21 clippy::doc_markdown "you should put `pkg_id/is_build` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/resolver/features.rs:233:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/features.rs:247:58 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/resolver/features.rs:278:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/resolver/features.rs:394:27 clippy::doc_markdown "you should put `FeatureValue` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/resolver/features.rs:460:19 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/core/resolver/features.rs:480:24 clippy::doc_markdown "you should put `FeatureValues` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/resolver/features.rs:496:24 clippy::doc_markdown "you should put `FeatureValues` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/resolver/features.rs:561:28 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/core/resolver/features.rs:58:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/core/resolver/features.rs:67:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo/0.49.0/src/cargo/core/resolver/mod.rs:1017:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/core/resolver/mod.rs:1045:57 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/resolver/mod.rs:122:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/resolver/mod.rs:142:44 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/resolver/mod.rs:180:1 clippy::too_many_lines "this function has too many lines (225/100)" +cargo/0.49.0/src/cargo/core/resolver/mod.rs:311:17 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/core/resolver/mod.rs:421:52 clippy::filter_map_next "called `filter_map(..).next()` on an `Iterator`. This is more succinctly expressed by calling `.find_map(..)` instead." +cargo/0.49.0/src/cargo/core/resolver/mod.rs:437:33 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/core/resolver/mod.rs:457:69 clippy::filter_map_next "called `filter_map(..).next()` on an `Iterator`. This is more succinctly expressed by calling `.find_map(..)` instead." +cargo/0.49.0/src/cargo/core/resolver/mod.rs:470:37 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/core/resolver/mod.rs:480:37 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/core/resolver/mod.rs:607:11 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo/0.49.0/src/cargo/core/resolver/mod.rs:631:21 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/core/resolver/mod.rs:942:15 clippy::if_not_else "unnecessary boolean `not` operation" +cargo/0.49.0/src/cargo/core/resolver/mod.rs:988:20 clippy::redundant_else "redundant else block" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:120:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:132:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:199:24 clippy::redundant_else "redundant else block" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:235:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:239:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:255:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:259:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:263:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:269:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:273:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:274:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:280:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:284:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:288:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:292:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:296:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:300:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:315:13 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:354:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:362:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:60:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:76:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/resolve.rs:90:35 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/core/resolver/types.rs:111:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/resolver/types.rs:121:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/types.rs:141:19 clippy::doc_markdown "you should put `ResolveOpts` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/resolver/types.rs:142:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/types.rs:149:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/resolver/types.rs:181:9 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +cargo/0.49.0/src/cargo/core/resolver/types.rs:187:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +cargo/0.49.0/src/cargo/core/resolver/types.rs:261:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +cargo/0.49.0/src/cargo/core/shell.rs:113:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/shell.rs:130:9 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/core/shell.rs:148:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/shell.rs:153:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/shell.rs:163:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/shell.rs:18:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/shell.rs:198:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/shell.rs:206:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/shell.rs:214:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/shell.rs:228:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/shell.rs:239:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/shell.rs:250:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/shell.rs:259:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/shell.rs:267:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/shell.rs:26:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/shell.rs:277:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/shell.rs:282:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/shell.rs:314:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/shell.rs:322:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/shell.rs:330:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/shell.rs:98:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/source/mod.rs:103:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/source/mod.rs:247:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/core/source/mod.rs:261:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/source/mod.rs:268:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/source/mod.rs:273:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/source/mod.rs:291:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/source/mod.rs:302:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/source/mod.rs:307:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/source/mod.rs:31:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/source/mod.rs:37:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/source/mod.rs:39:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/source/mod.rs:47:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/source/mod.rs:50:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/source/mod.rs:52:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/source/mod.rs:63:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/source/mod.rs:74:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/source/mod.rs:83:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/source/source_id.rs:107:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/source/source_id.rs:128:50 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/source/source_id.rs:147:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/source/source_id.rs:156:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/source/source_id.rs:162:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/source/source_id.rs:166:19 clippy::doc_markdown "you should put `SourceId` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/source/source_id.rs:167:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/source/source_id.rs:171:19 clippy::doc_markdown "you should put `SourceId` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/source/source_id.rs:172:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/source/source_id.rs:178:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/source/source_id.rs:187:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/source/source_id.rs:18:74 clippy::default_trait_access "calling `std::sync::Mutex::default()` is more clear than this expression" +cargo/0.49.0/src/cargo/core/source/source_id.rs:195:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/source/source_id.rs:207:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/source/source_id.rs:213:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/source/source_id.rs:217:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/source/source_id.rs:225:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/source/source_id.rs:228:16 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" +cargo/0.49.0/src/cargo/core/source/source_id.rs:236:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/source/source_id.rs:241:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/source/source_id.rs:252:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/source/source_id.rs:257:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/source/source_id.rs:262:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/source/source_id.rs:305:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/source/source_id.rs:310:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/source/source_id.rs:318:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/source/source_id.rs:326:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/source/source_id.rs:355:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/source/source_id.rs:393:61 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:394:42 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:395:42 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:397:71 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:397:71 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:398:47 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:398:47 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:399:47 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:399:47 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:401:63 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:401:63 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:401:63 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:402:43 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:402:43 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:402:43 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:403:43 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:403:43 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:403:43 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:406:21 clippy::enum_glob_use "usage of wildcard import for enum variants" +cargo/0.49.0/src/cargo/core/source/source_id.rs:412:41 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:413:36 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:414:36 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:420:47 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:420:47 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/source/source_id.rs:512:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo/0.49.0/src/cargo/core/source/source_id.rs:513:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo/0.49.0/src/cargo/core/source/source_id.rs:517:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo/0.49.0/src/cargo/core/source/source_id.rs:518:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo/0.49.0/src/cargo/core/source/source_id.rs:525:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo/0.49.0/src/cargo/core/source/source_id.rs:526:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo/0.49.0/src/cargo/core/source/source_id.rs:530:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo/0.49.0/src/cargo/core/source/source_id.rs:531:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo/0.49.0/src/cargo/core/source/source_id.rs:535:33 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo/0.49.0/src/cargo/core/source/source_id.rs:536:37 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo/0.49.0/src/cargo/core/source/source_id.rs:537:42 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo/0.49.0/src/cargo/core/source/source_id.rs:538:38 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo/0.49.0/src/cargo/core/source/source_id.rs:548:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/core/source/source_id.rs:597:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/summary.rs:103:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/summary.rs:123:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/summary.rs:150:1 clippy::too_many_lines "this function has too many lines (141/100)" +cargo/0.49.0/src/cargo/core/summary.rs:158:9 clippy::enum_glob_use "usage of wildcard import for enum variants" +cargo/0.49.0/src/cargo/core/summary.rs:181:21 clippy::if_not_else "unnecessary boolean `not` operation" +cargo/0.49.0/src/cargo/core/summary.rs:192:28 clippy::redundant_else "redundant else block" +cargo/0.49.0/src/cargo/core/summary.rs:258:32 clippy::redundant_else "redundant else block" +cargo/0.49.0/src/cargo/core/summary.rs:281:28 clippy::redundant_else "redundant else block" +cargo/0.49.0/src/cargo/core/summary.rs:303:28 clippy::redundant_else "redundant else block" +cargo/0.49.0/src/cargo/core/summary.rs:321:51 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/core/summary.rs:344:5 clippy::doc_markdown "you should put `FeatureValue` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/summary.rs:350:85 clippy::doc_markdown "you should put `FeatureValue` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/summary.rs:36:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/summary.rs:378:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/summary.rs:386:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/summary.rs:387:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +cargo/0.49.0/src/cargo/core/summary.rs:407:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +cargo/0.49.0/src/cargo/core/summary.rs:69:34 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/summary.rs:75:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/summary.rs:78:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/summary.rs:81:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/summary.rs:84:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/summary.rs:87:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/summary.rs:90:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/summary.rs:93:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/summary.rs:96:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/summary.rs:99:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/workspace.rs:1019:59 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/core/workspace.rs:1056:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo/0.49.0/src/cargo/core/workspace.rs:113:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/core/workspace.rs:1157:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/core/workspace.rs:128:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/core/workspace.rs:150:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/workspace.rs:159:16 clippy::redundant_else "redundant else block" +cargo/0.49.0/src/cargo/core/workspace.rs:197:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/workspace.rs:225:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/workspace.rs:255:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/workspace.rs:267:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/workspace.rs:329:37 clippy::doc_markdown "you should put `VirtualManifest` between ticks in the documentation" +cargo/0.49.0/src/cargo/core/workspace.rs:410:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/workspace.rs:440:9 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo/0.49.0/src/cargo/core/workspace.rs:511:32 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/core/workspace.rs:561:25 clippy::non_ascii_literal "literal non-ASCII character detected" +cargo/0.49.0/src/cargo/core/workspace.rs:613:13 clippy::filter_map "called `filter_map(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/core/workspace.rs:615:22 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/core/workspace.rs:688:35 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/core/workspace.rs:762:27 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/core/workspace.rs:784:17 clippy::if_not_else "unnecessary boolean `not` operation" +cargo/0.49.0/src/cargo/core/workspace.rs:849:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/workspace.rs:893:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/core/workspace.rs:906:24 clippy::redundant_else "redundant else block" +cargo/0.49.0/src/cargo/core/workspace.rs:932:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/lib.rs:177:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/lib.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.categories` metadata" +cargo/0.49.0/src/cargo/lib.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.keywords` metadata" +cargo/0.49.0/src/cargo/lib.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `crossbeam-utils`: 0.6.6, 0.7.2" +cargo/0.49.0/src/cargo/lib.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `hex`: 0.3.2, 0.4.0" +cargo/0.49.0/src/cargo/lib.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `humantime`: 1.3.0, 2.0.0" +cargo/0.49.0/src/cargo/ops/cargo_clean.rs:205:23 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/ops/cargo_clean.rs:27:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_clean.rs:27:1 clippy::too_many_lines "this function has too many lines (120/100)" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:1078:14 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:109:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:119:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:1227:17 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:127:35 clippy::from_iter_instead_of_collect "usage of `FromIterator::from_iter`" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:128:32 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:173:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:205:36 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:242:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:249:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:258:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:275:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:275:1 clippy::too_many_lines "this function has too many lines (219/100)" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:468:9 clippy::default_trait_access "calling `std::collections::HashMap::default()` is more clear than this expression" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:548:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:556:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:574:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:583:21 clippy::doc_markdown "you should put `CompileFilter` between ticks in the documentation" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:584:5 clippy::fn_params_excessive_bools "more than 3 bools in function parameters" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:584:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:592:9 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:593:9 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:607:13 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:612:21 clippy::doc_markdown "you should put `CompileFilter` between ticks in the documentation" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:613:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:618:9 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:641:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:652:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:655:50 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:673:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:692:49 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:703:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:729:1 clippy::too_many_lines "this function has too many lines (205/100)" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:82:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_compile.rs:874:69 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/ops/cargo_doc.rs:20:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_fetch.rs:15:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_fetch.rs:27:46 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/ops/cargo_fetch.rs:36:20 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:160:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:175:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:22:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:37:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:37:1 clippy::too_many_lines "this function has too many lines (171/100)" +cargo/0.49.0/src/cargo/ops/cargo_install.rs:13:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/cargo/ops/cargo_install.rs:148:1 clippy::fn_params_excessive_bools "more than 3 bools in function parameters" +cargo/0.49.0/src/cargo/ops/cargo_install.rs:148:1 clippy::too_many_lines "this function has too many lines (316/100)" +cargo/0.49.0/src/cargo/ops/cargo_install.rs:202:17 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/ops/cargo_install.rs:312:64 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/ops/cargo_install.rs:318:63 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/ops/cargo_install.rs:32:13 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" +cargo/0.49.0/src/cargo/ops/cargo_install.rs:37:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_install.rs:454:22 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/ops/cargo_install.rs:483:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/ops/cargo_install.rs:683:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_new.rs:101:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_new.rs:245:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/ops/cargo_new.rs:251:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/ops/cargo_new.rs:367:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_new.rs:405:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_new.rs:489:5 clippy::doc_markdown "you should put `IgnoreList` between ticks in the documentation" +cargo/0.49.0/src/cargo/ops/cargo_new.rs:525:47 clippy::doc_markdown "you should put `IgnoreList` between ticks in the documentation" +cargo/0.49.0/src/cargo/ops/cargo_new.rs:525:9 clippy::doc_markdown "you should put `format_existing` between ticks in the documentation" +cargo/0.49.0/src/cargo/ops/cargo_new.rs:572:34 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/ops/cargo_new.rs:623:1 clippy::too_many_lines "this function has too many lines (130/100)" +cargo/0.49.0/src/cargo/ops/cargo_new.rs:781:5 clippy::filter_map_next "called `filter_map(..).next()` on an `Iterator`. This is more succinctly expressed by calling `.find_map(..)` instead." +cargo/0.49.0/src/cargo/ops/cargo_new.rs:800:16 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/ops/cargo_output_metadata.rs:163:36 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/ops/cargo_output_metadata.rs:27:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_output_metadata.rs:45:45 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/ops/cargo_package.rs:144:1 clippy::too_many_lines "this function has too many lines (112/100)" +cargo/0.49.0/src/cargo/ops/cargo_package.rs:207:13 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/ops/cargo_package.rs:25:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo/0.49.0/src/cargo/ops/cargo_package.rs:307:54 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/ops/cargo_package.rs:394:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/ops/cargo_package.rs:418:21 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/ops/cargo_package.rs:425:61 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/ops/cargo_package.rs:459:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/ops/cargo_package.rs:66:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_package.rs:769:29 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/ops/cargo_package.rs:93:20 clippy::if_not_else "unnecessary boolean `not` operation" +cargo/0.49.0/src/cargo/ops/cargo_pkgid.rs:5:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_read_manifest.rs:14:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_read_manifest.rs:171:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/ops/cargo_read_manifest.rs:37:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_read_manifest.rs:57:49 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/ops/cargo_read_manifest.rs:69:37 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/ops/cargo_run.rs:25:24 clippy::if_not_else "unnecessary boolean `not` operation" +cargo/0.49.0/src/cargo/ops/cargo_run.rs:35:9 clippy::if_not_else "unnecessary boolean `not` operation" +cargo/0.49.0/src/cargo/ops/cargo_run.rs:37:16 clippy::redundant_else "redundant else block" +cargo/0.49.0/src/cargo/ops/cargo_run.rs:53:9 clippy::if_not_else "unnecessary boolean `not` operation" +cargo/0.49.0/src/cargo/ops/cargo_run.rs:65:16 clippy::redundant_else "redundant else block" +cargo/0.49.0/src/cargo/ops/cargo_run.rs:9:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_test.rs:16:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_test.rs:43:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_test.rs:84:17 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/ops/cargo_uninstall.rs:14:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/cargo_uninstall.rs:7:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:147:9 clippy::doc_markdown "you should put `PackageId` between ticks in the documentation" +cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:233:21 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:244:22 clippy::doc_markdown "you should put `PackageId` between ticks in the documentation" +cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:244:63 clippy::doc_markdown "you should put `PackageId` between ticks in the documentation" +cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:253:17 clippy::if_not_else "unnecessary boolean `not` operation" +cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:370:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:392:9 clippy::find_map "called `find(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:505:8 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:525:10 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:542:27 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:542:5 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:561:20 clippy::redundant_else "redundant else block" +cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:613:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:645:41 clippy::doc_markdown "you should put `BTreeSet` between ticks in the documentation" +cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:654:42 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:662:14 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:674:17 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:681:17 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:92:19 clippy::doc_markdown "you should put `InstallTracker` between ticks in the documentation" +cargo/0.49.0/src/cargo/ops/fix.rs:200:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/fix.rs:200:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/ops/fix.rs:424:20 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +cargo/0.49.0/src/cargo/ops/fix.rs:455:13 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/ops/fix.rs:506:17 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/ops/fix.rs:608:9 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" +cargo/0.49.0/src/cargo/ops/fix.rs:612:42 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/ops/fix.rs:619:48 clippy::manual_strip "stripping a prefix manually" +cargo/0.49.0/src/cargo/ops/fix.rs:66:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/ops/fix.rs:66:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo/0.49.0/src/cargo/ops/fix.rs:708:18 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/ops/fix.rs:77:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/lockfile.rs:154:13 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo/0.49.0/src/cargo/ops/lockfile.rs:217:9 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo/0.49.0/src/cargo/ops/lockfile.rs:30:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/lockfile.rs:35:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/lockfile.rs:35:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/ops/lockfile.rs:87:1 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo/0.49.0/src/cargo/ops/lockfile.rs:8:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/lockfile.rs:8:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/ops/registry.rs:150:21 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/ops/registry.rs:188:1 clippy::too_many_lines "this function has too many lines (130/100)" +cargo/0.49.0/src/cargo/ops/registry.rs:196:16 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/ops/registry.rs:212:32 clippy::if_not_else "unnecessary `!=` operation" +cargo/0.49.0/src/cargo/ops/registry.rs:222:53 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/ops/registry.rs:224:44 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/ops/registry.rs:31:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/ops/registry.rs:346:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/registry.rs:346:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/ops/registry.rs:351:26 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/ops/registry.rs:385:12 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo/0.49.0/src/cargo/ops/registry.rs:386:15 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo/0.49.0/src/cargo/ops/registry.rs:38:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo/0.49.0/src/cargo/ops/registry.rs:477:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/registry.rs:483:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/registry.rs:503:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/registry.rs:505:38 clippy::default_trait_access "calling `util::config::CargoHttpConfig::default()` is more clear than this expression" +cargo/0.49.0/src/cargo/ops/registry.rs:510:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/registry.rs:529:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/ops/registry.rs:53:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/registry.rs:573:22 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/ops/registry.rs:608:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/registry.rs:621:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/registry.rs:671:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/registry.rs:671:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/ops/registry.rs:674:10 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo/0.49.0/src/cargo/ops/registry.rs:678:17 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/ops/registry.rs:730:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/registry.rs:731:16 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/ops/registry.rs:785:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/registry.rs:794:16 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/ops/registry.rs:828:14 clippy::doc_markdown "you should put `SourceId` between ticks in the documentation" +cargo/0.49.0/src/cargo/ops/registry.rs:848:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/resolve.rs:199:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/resolve.rs:199:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/ops/resolve.rs:199:1 clippy::too_many_lines "this function has too many lines (137/100)" +cargo/0.49.0/src/cargo/ops/resolve.rs:241:28 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/ops/resolve.rs:28:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/ops/resolve.rs:384:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/resolve.rs:417:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/resolve.rs:589:9 clippy::shadow_unrelated "`keep` is being shadowed" +cargo/0.49.0/src/cargo/ops/resolve.rs:58:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/resolve.rs:58:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/ops/resolve.rs:602:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/ops/resolve.rs:75:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/resolve.rs:75:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/ops/tree/graph.rs:129:26 clippy::doc_markdown "you should put `PackageIds` between ticks in the documentation" +cargo/0.49.0/src/cargo/ops/tree/graph.rs:131:47 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/ops/tree/graph.rs:152:15 clippy::match_on_vec_items "indexing into a vector may panic" +cargo/0.49.0/src/cargo/ops/tree/graph.rs:173:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/ops/tree/graph.rs:234:46 clippy::filter_map "called `filter(..).flat_map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/ops/tree/graph.rs:328:44 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/ops/tree/graph.rs:330:50 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/ops/tree/graph.rs:563:35 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/ops/tree/mod.rs:112:11 clippy::non_ascii_literal "literal non-ASCII character detected" +cargo/0.49.0/src/cargo/ops/tree/mod.rs:113:10 clippy::non_ascii_literal "literal non-ASCII character detected" +cargo/0.49.0/src/cargo/ops/tree/mod.rs:114:10 clippy::non_ascii_literal "literal non-ASCII character detected" +cargo/0.49.0/src/cargo/ops/tree/mod.rs:115:12 clippy::non_ascii_literal "literal non-ASCII character detected" +cargo/0.49.0/src/cargo/ops/tree/mod.rs:126:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/tree/mod.rs:21:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/ops/tree/mod.rs:21:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo/0.49.0/src/cargo/ops/tree/mod.rs:360:30 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/ops/tree/mod.rs:58:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/ops/vendor.rs:14:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/ops/vendor.rs:21:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/ops/vendor.rs:314:34 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/ops/vendor.rs:324:13 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +cargo/0.49.0/src/cargo/ops/vendor.rs:70:1 clippy::too_many_lines "this function has too many lines (175/100)" +cargo/0.49.0/src/cargo/sources/config.rs:102:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/config.rs:135:67 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/sources/config.rs:206:36 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo/0.49.0/src/cargo/sources/config.rs:282:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/sources/config.rs:70:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/config.rs:81:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/config.rs:97:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/sources/directory.rs:14:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/sources/directory.rs:90:56 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/sources/git/source.rs:14:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/sources/git/source.rs:25:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/git/source.rs:49:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/sources/git/source.rs:53:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/git/source.rs:69:20 clippy::comparison_to_empty "comparison to empty slice" +cargo/0.49.0/src/cargo/sources/git/utils.rs:1025:19 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/sources/git/utils.rs:1158:9 clippy::manual_strip "stripping a suffix manually" +cargo/0.49.0/src/cargo/sources/git/utils.rs:176:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/sources/git/utils.rs:180:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/sources/git/utils.rs:184:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/git/utils.rs:188:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/git/utils.rs:242:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/git/utils.rs:253:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/git/utils.rs:262:13 clippy::if_not_else "unnecessary boolean `not` operation" +cargo/0.49.0/src/cargo/sources/git/utils.rs:289:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/git/utils.rs:294:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/sources/git/utils.rs:298:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/git/utils.rs:308:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/git/utils.rs:472:9 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" +cargo/0.49.0/src/cargo/sources/git/utils.rs:489:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/sources/git/utils.rs:503:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/sources/git/utils.rs:528:28 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/sources/git/utils.rs:537:21 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" +cargo/0.49.0/src/cargo/sources/git/utils.rs:588:1 clippy::too_many_lines "this function has too many lines (135/100)" +cargo/0.49.0/src/cargo/sources/git/utils.rs:758:9 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo/0.49.0/src/cargo/sources/git/utils.rs:858:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/path.rs:129:44 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/sources/path.rs:143:44 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/sources/path.rs:15:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/sources/path.rs:282:50 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/sources/path.rs:313:21 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/sources/path.rs:314:21 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/sources/path.rs:319:21 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/sources/path.rs:339:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/sources/path.rs:339:9 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo/0.49.0/src/cargo/sources/path.rs:380:9 clippy::unused_self "unused `self` argument" +cargo/0.49.0/src/cargo/sources/path.rs:419:50 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/sources/path.rs:429:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/path.rs:460:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/sources/path.rs:473:43 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/sources/path.rs:482:43 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/sources/path.rs:63:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/path.rs:77:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/path.rs:98:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/registry/index.rs:117:23 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo/0.49.0/src/cargo/sources/registry/index.rs:121:70 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo/0.49.0/src/cargo/sources/registry/index.rs:167:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/sources/registry/index.rs:215:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/sources/registry/index.rs:324:23 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/sources/registry/index.rs:393:25 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/sources/registry/index.rs:468:40 clippy::doc_markdown "you should put `SourceId` between ticks in the documentation" +cargo/0.49.0/src/cargo/sources/registry/index.rs:590:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/sources/registry/index.rs:648:17 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/sources/registry/index.rs:736:1 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +cargo/0.49.0/src/cargo/sources/registry/index.rs:95:37 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +cargo/0.49.0/src/cargo/sources/registry/local.rs:12:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/sources/registry/mod.rs:192:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/sources/registry/mod.rs:203:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/sources/registry/mod.rs:229:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/sources/registry/mod.rs:372:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/sources/registry/mod.rs:373:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/registry/mod.rs:375:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/registry/mod.rs:381:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/registry/mod.rs:382:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/registry/mod.rs:383:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/registry/mod.rs:384:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/registry/mod.rs:452:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/sources/registry/mod.rs:582:20 clippy::redundant_else "redundant else block" +cargo/0.49.0/src/cargo/sources/registry/mod.rs:621:9 clippy::if_not_else "unnecessary `!=` operation" +cargo/0.49.0/src/cargo/sources/registry/remote.rs:139:17 clippy::unused_self "unused `self` argument" +cargo/0.49.0/src/cargo/sources/registry/remote.rs:32:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/sources/registry/remote.rs:72:13 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/sources/replaced.rs:12:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/sources/replaced.rs:5:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/util/canonical_url.rs:19:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/canonical_url.rs:65:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/command_prelude.rs:218:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/command_prelude.rs:222:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/command_prelude.rs:234:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/command_prelude.rs:249:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/command_prelude.rs:264:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/command_prelude.rs:279:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/command_prelude.rs:298:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/command_prelude.rs:320:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/command_prelude.rs:328:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/command_prelude.rs:352:13 clippy::if_not_else "unnecessary boolean `not` operation" +cargo/0.49.0/src/cargo/util/command_prelude.rs:363:13 clippy::if_not_else "unnecessary boolean `not` operation" +cargo/0.49.0/src/cargo/util/command_prelude.rs:378:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/command_prelude.rs:387:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/command_prelude.rs:387:5 clippy::too_many_lines "this function has too many lines (104/100)" +cargo/0.49.0/src/cargo/util/command_prelude.rs:39:20 clippy::doc_markdown "you should put `arg_package_spec` between ticks in the documentation" +cargo/0.49.0/src/cargo/util/command_prelude.rs:504:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/command_prelude.rs:516:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/command_prelude.rs:530:40 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/util/command_prelude.rs:531:43 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/util/command_prelude.rs:536:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/command_prelude.rs:556:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/command_prelude.rs:575:49 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/util/command_prelude.rs:580:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/command_prelude.rs:631:18 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/util/command_prelude.rs:638:18 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/util/command_prelude.rs:647:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/command_prelude.rs:651:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/command_prelude.rs:662:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/command_prelude.rs:665:51 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/util/config/de.rs:420:16 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo/0.49.0/src/cargo/util/config/de.rs:46:25 clippy::doc_markdown "you should put `CV::List` between ticks in the documentation" +cargo/0.49.0/src/cargo/util/config/de.rs:47:24 clippy::doc_markdown "you should put `ConfigSeqAccess` between ticks in the documentation" +cargo/0.49.0/src/cargo/util/config/de.rs:527:53 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo/0.49.0/src/cargo/util/config/de.rs:530:53 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo/0.49.0/src/cargo/util/config/de.rs:532:68 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo/0.49.0/src/cargo/util/config/key.rs:11:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/util/config/key.rs:69:9 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo/0.49.0/src/cargo/util/config/mod.rs:100:71 clippy::doc_markdown "you should put `OptValue` between ticks in the documentation" +cargo/0.49.0/src/cargo/util/config/mod.rs:100:71 clippy::doc_markdown "you should put `OptValue` between ticks in the documentation" +cargo/0.49.0/src/cargo/util/config/mod.rs:100:71 clippy::doc_markdown "you should put `OptValue` between ticks in the documentation" +cargo/0.49.0/src/cargo/util/config/mod.rs:1049:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:1064:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:1090:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:1166:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:1179:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:1184:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:1189:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:1203:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:1211:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:1216:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:1225:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:1229:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:124:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo/0.49.0/src/cargo/util/config/mod.rs:1254:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:1279:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:1281:9 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +cargo/0.49.0/src/cargo/util/config/mod.rs:1323:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/util/config/mod.rs:1339:39 clippy::unused_self "unused `self` argument" +cargo/0.49.0/src/cargo/util/config/mod.rs:1344:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/util/config/mod.rs:1420:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/util/config/mod.rs:1553:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:1560:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:1567:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:1574:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:1581:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:1588:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/config/mod.rs:1598:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/config/mod.rs:1619:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/config/mod.rs:1623:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:1623:64 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo/0.49.0/src/cargo/util/config/mod.rs:1649:9 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" +cargo/0.49.0/src/cargo/util/config/mod.rs:1699:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/util/config/mod.rs:1730:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/util/config/mod.rs:1757:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/util/config/mod.rs:1770:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/util/config/mod.rs:1778:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/util/config/mod.rs:1804:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/util/config/mod.rs:1896:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/config/mod.rs:1901:5 clippy::doc_markdown "you should put `StringList` between ticks in the documentation" +cargo/0.49.0/src/cargo/util/config/mod.rs:214:13 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +cargo/0.49.0/src/cargo/util/config/mod.rs:259:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:298:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:311:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:318:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:353:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:401:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:411:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:419:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:431:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:449:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:454:16 clippy::option_if_let_else "use Option::map_or instead of an if let/else" +cargo/0.49.0/src/cargo/util/config/mod.rs:547:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:556:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:582:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:595:20 clippy::doc_markdown "you should put `StringList` between ticks in the documentation" +cargo/0.49.0/src/cargo/util/config/mod.rs:689:20 clippy::unused_self "unused `self` argument" +cargo/0.49.0/src/cargo/util/config/mod.rs:699:5 clippy::fn_params_excessive_bools "more than 3 bools in function parameters" +cargo/0.49.0/src/cargo/util/config/mod.rs:699:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:719:58 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/util/config/mod.rs:816:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/config/mod.rs:875:36 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/util/config/mod.rs:876:37 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/util/config/path.rs:10:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/util/config/path.rs:14:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/config/path.rs:48:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/util/config/target.rs:12:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/util/config/target.rs:24:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/util/config/value.rs:29:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/util/config/value.rs:80:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/config/value.rs:81:9 clippy::match_like_matches_macro "match expression looks like `matches!` macro" +cargo/0.49.0/src/cargo/util/cpu.rs:11:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/cpu.rs:22:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/cpu.rs:82:25 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +cargo/0.49.0/src/cargo/util/cpu.rs:82:9 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +cargo/0.49.0/src/cargo/util/dependency_queue.rs:109:27 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/util/dependency_queue.rs:136:20 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/util/dependency_queue.rs:151:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/dependency_queue.rs:156:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/dependency_queue.rs:46:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/dependency_queue.rs:91:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/util/diagnostic_server.rs:218:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/util/diagnostic_server.rs:230:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/diagnostic_server.rs:242:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/diagnostic_server.rs:58:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/diagnostic_server.rs:96:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/diagnostic_server.rs:96:5 clippy::too_many_lines "this function has too many lines (110/100)" +cargo/0.49.0/src/cargo/util/diagnostic_server.rs:99:21 clippy::shadow_unrelated "`msg` is being shadowed" +cargo/0.49.0/src/cargo/util/errors.rs:101:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/errors.rs:143:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/errors.rs:150:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/errors.rs:15:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/errors.rs:237:5 clippy::pub_enum_variant_names "variant name ends with the enum's name" +cargo/0.49.0/src/cargo/util/errors.rs:245:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/errors.rs:321:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/errors.rs:328:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/errors.rs:356:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/errors.rs:391:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/util/errors.rs:392:13 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/cargo/util/errors.rs:465:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/errors.rs:473:5 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +cargo/0.49.0/src/cargo/util/errors.rs:66:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/flock.rs:115:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/flock.rs:11:5 clippy::wildcard_imports "usage of wildcard import" +cargo/0.49.0/src/cargo/util/flock.rs:134:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/flock.rs:142:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/flock.rs:150:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/flock.rs:156:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/flock.rs:170:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/flock.rs:192:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/flock.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/flock.rs:321:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/util/flock.rs:335:23 clippy::cast_possible_truncation "casting `i64` to `u32` may truncate the value" +cargo/0.49.0/src/cargo/util/flock.rs:335:23 clippy::cast_sign_loss "casting `i64` to `u32` may lose the sign of the value" +cargo/0.49.0/src/cargo/util/flock.rs:335:44 clippy::cast_possible_truncation "casting `i64` to `u32` may truncate the value" +cargo/0.49.0/src/cargo/util/flock.rs:379:35 clippy::match_same_arms "this `match` has identical arm bodies" +cargo/0.49.0/src/cargo/util/flock.rs:37:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/flock.rs:43:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/flock.rs:52:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/graph.rs:10:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/graph.rs:115:13 clippy::find_map "called `find(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/util/graph.rs:41:51 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/util/graph.rs:45:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/graph.rs:95:13 clippy::find_map "called `find(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/util/hasher.rs:12:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/hasher.rs:9:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/util/hex.rs:10:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" +cargo/0.49.0/src/cargo/util/hex.rs:11:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" +cargo/0.49.0/src/cargo/util/hex.rs:12:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" +cargo/0.49.0/src/cargo/util/hex.rs:13:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" +cargo/0.49.0/src/cargo/util/hex.rs:14:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" +cargo/0.49.0/src/cargo/util/hex.rs:15:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" +cargo/0.49.0/src/cargo/util/hex.rs:25:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/hex.rs:6:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/util/hex.rs:6:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/hex.rs:8:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" +cargo/0.49.0/src/cargo/util/hex.rs:9:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" +cargo/0.49.0/src/cargo/util/important_paths.rs:23:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/important_paths.rs:6:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/interning.rs:66:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/interning.rs:77:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/into_url.rs:10:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/into_url_with_base.rs:9:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/job.rs:20:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/lev_distance.rs:3:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/lockserver.rs:111:32 clippy::redundant_else "redundant else block" +cargo/0.49.0/src/cargo/util/lockserver.rs:158:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/lockserver.rs:46:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/lockserver.rs:58:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/lockserver.rs:62:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/mod.rs:68:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/mod.rs:79:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/network.rs:12:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/network.rs:19:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/network.rs:84:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/paths.rs:109:12 clippy::redundant_else "redundant else block" +cargo/0.49.0/src/cargo/util/paths.rs:114:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/paths.rs:121:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/paths.rs:125:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/paths.rs:130:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/paths.rs:14:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/paths.rs:14:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo/0.49.0/src/cargo/util/paths.rs:151:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/paths.rs:167:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/paths.rs:173:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/paths.rs:178:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/paths.rs:185:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/paths.rs:199:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/paths.rs:215:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/paths.rs:228:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/paths.rs:251:9 clippy::option_if_let_else "use Option::map_or instead of an if let/else" +cargo/0.49.0/src/cargo/util/paths.rs:267:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/paths.rs:276:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/paths.rs:29:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/paths.rs:303:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/paths.rs:312:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/paths.rs:346:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/paths.rs:415:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/paths.rs:445:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/paths.rs:459:45 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/util/paths.rs:469:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/paths.rs:54:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/paths.rs:61:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/paths.rs:63:19 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" +cargo/0.49.0/src/cargo/util/paths.rs:88:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/paths.rs:93:31 clippy::comparison_to_empty "comparison to empty slice" +cargo/0.49.0/src/cargo/util/process_builder.rs:106:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/process_builder.rs:111:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/process_builder.rs:122:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/process_builder.rs:132:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/process_builder.rs:152:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/process_builder.rs:185:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/process_builder.rs:190:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/process_builder.rs:218:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/process_builder.rs:307:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/process_builder.rs:343:39 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo/0.49.0/src/cargo/util/progress.rs:122:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/progress.rs:136:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/progress.rs:15:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/util/progress.rs:249:19 clippy::cast_precision_loss "casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +cargo/0.49.0/src/cargo/util/progress.rs:249:34 clippy::cast_precision_loss "casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +cargo/0.49.0/src/cargo/util/progress.rs:250:19 clippy::if_not_else "unnecessary boolean `not` operation" +cargo/0.49.0/src/cargo/util/progress.rs:263:22 clippy::cast_precision_loss "casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +cargo/0.49.0/src/cargo/util/progress.rs:264:22 clippy::cast_possible_truncation "casting `f64` to `usize` may truncate the value" +cargo/0.49.0/src/cargo/util/progress.rs:264:22 clippy::cast_sign_loss "casting `f64` to `usize` may lose the sign of the value" +cargo/0.49.0/src/cargo/util/progress.rs:269:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo/0.49.0/src/cargo/util/progress.rs:272:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo/0.49.0/src/cargo/util/progress.rs:274:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo/0.49.0/src/cargo/util/progress.rs:280:13 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo/0.49.0/src/cargo/util/progress.rs:282:9 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo/0.49.0/src/cargo/util/progress.rs:89:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/progress.rs:97:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/queue.rs:25:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/read2.rs:11:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/read2.rs:31:17 clippy::similar_names "binding's name is too similar to existing binding" +cargo/0.49.0/src/cargo/util/restricted_names.rs:13:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/restricted_names.rs:26:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/restricted_names.rs:35:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/restricted_names.rs:45:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/restricted_names.rs:87:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/restricted_names.rs:89:21 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/util/restricted_names.rs:8:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/rustc.rs:103:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/rustc.rs:114:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +cargo/0.49.0/src/cargo/util/rustc.rs:115:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +cargo/0.49.0/src/cargo/util/rustc.rs:162:17 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/util/rustc.rs:39:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/rustc.rs:55:13 clippy::find_map "called `find(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/util/sha256.rs:10:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/sha256.rs:20:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/sha256.rs:31:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/sha256.rs:40:24 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo/0.49.0/src/cargo/util/to_semver.rs:5:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/toml/mod.rs:1005:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/toml/mod.rs:1005:5 clippy::too_many_lines "this function has too many lines (282/100)" +cargo/0.49.0/src/cargo/util/toml/mod.rs:1094:36 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/util/toml/mod.rs:1121:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/util/toml/mod.rs:1197:32 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +cargo/0.49.0/src/cargo/util/toml/mod.rs:124:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/toml/mod.rs:1504:9 clippy::unused_self "unused `self` argument" +cargo/0.49.0/src/cargo/util/toml/mod.rs:1526:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/toml/mod.rs:1582:19 clippy::default_trait_access "calling `util::toml::DetailedTomlDependency::default()` is more clear than this expression" +cargo/0.49.0/src/cargo/util/toml/mod.rs:1598:5 clippy::too_many_lines "this function has too many lines (153/100)" +cargo/0.49.0/src/cargo/util/toml/mod.rs:1687:33 clippy::unnecessary_lazy_evaluations "unnecessary closure used to substitute value for `Option::None`" +cargo/0.49.0/src/cargo/util/toml/mod.rs:178:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/util/toml/mod.rs:248:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/util/toml/mod.rs:274:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/util/toml/mod.rs:277:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/toml/mod.rs:281:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/toml/mod.rs:285:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/toml/mod.rs:294:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/util/toml/mod.rs:31:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/toml/mod.rs:381:35 clippy::cast_possible_truncation "casting `i64` to `u32` may truncate the value" +cargo/0.49.0/src/cargo/util/toml/mod.rs:381:35 clippy::cast_sign_loss "casting `i64` to `u32` may lose the sign of the value" +cargo/0.49.0/src/cargo/util/toml/mod.rs:388:35 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +cargo/0.49.0/src/cargo/util/toml/mod.rs:398:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/util/toml/mod.rs:450:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/toml/mod.rs:536:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/toml/mod.rs:783:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/util/toml/mod.rs:824:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo/0.49.0/src/cargo/util/toml/mod.rs:834:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/toml/mod.rs:83:42 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/util/toml/mod.rs:852:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/toml/mod.rs:852:5 clippy::too_many_lines "this function has too many lines (138/100)" +cargo/0.49.0/src/cargo/util/toml/mod.rs:962:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/util/toml/mod.rs:971:24 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/util/toml/mod.rs:979:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/util/toml/mod.rs:98:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/util/toml/mod.rs:999:23 clippy::default_trait_access "calling `util::toml::DetailedTomlDependency::default()` is more clear than this expression" +cargo/0.49.0/src/cargo/util/toml/targets.rs:112:27 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/util/toml/targets.rs:325:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo/0.49.0/src/cargo/util/toml/targets.rs:586:21 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/util/toml/targets.rs:593:42 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/util/toml/targets.rs:605:19 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/util/toml/targets.rs:612:42 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/util/toml/targets.rs:756:36 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo/0.49.0/src/cargo/util/toml/targets.rs:810:24 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +cargo/0.49.0/src/cargo/util/vcs.rs:10:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo/0.49.0/src/cargo/util/vcs.rs:33:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/vcs.rs:37:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/vcs.rs:43:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/vcs.rs:47:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/vcs.rs:59:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/vcs.rs:66:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/workspace.rs:52:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/workspace.rs:56:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/workspace.rs:60:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo/0.49.0/src/cargo/util/workspace.rs:64:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron/0.6.1/src/error.rs:24:1 clippy::module_name_repetitions "item name ends with its containing module's name" +iron/0.6.1/src/iron.rs:105:13 clippy::redundant_field_names "redundant field names in struct initialization" +iron/0.6.1/src/iron.rs:119:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron/0.6.1/src/iron.rs:133:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron/0.6.1/src/iron.rs:143:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron/0.6.1/src/iron.rs:149:13 clippy::redundant_field_names "redundant field names in struct initialization" +iron/0.6.1/src/iron.rs:167:49 clippy::similar_names "binding's name is too similar to existing binding" +iron/0.6.1/src/iron.rs:80:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron/0.6.1/src/iron.rs:85:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron/0.6.1/src/iron.rs:90:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron/0.6.1/src/lib.rs:1:null clippy::cargo_common_metadata "package `iron` is missing `package.categories` metadata" +iron/0.6.1/src/lib.rs:1:null clippy::cargo_common_metadata "package `iron` is missing `package.keywords` metadata" +iron/0.6.1/src/lib.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `log`: 0.3.9, 0.4.8" +iron/0.6.1/src/middleware/mod.rs:137:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron/0.6.1/src/middleware/mod.rs:150:1 clippy::module_name_repetitions "item name ends with its containing module's name" +iron/0.6.1/src/middleware/mod.rs:152:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron/0.6.1/src/middleware/mod.rs:159:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron/0.6.1/src/middleware/mod.rs:171:1 clippy::module_name_repetitions "item name ends with its containing module's name" +iron/0.6.1/src/middleware/mod.rs:173:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron/0.6.1/src/middleware/mod.rs:182:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron/0.6.1/src/middleware/mod.rs:192:1 clippy::module_name_repetitions "item name ends with its containing module's name" +iron/0.6.1/src/middleware/mod.rs:217:25 clippy::doc_markdown "you should put `ChainBuilder` between ticks in the documentation" +iron/0.6.1/src/middleware/mod.rs:328:20 clippy::similar_names "binding's name is too similar to existing binding" +iron/0.6.1/src/middleware/mod.rs:360:16 clippy::similar_names "binding's name is too similar to existing binding" +iron/0.6.1/src/middleware/mod.rs:368:33 clippy::similar_names "binding's name is too similar to existing binding" +iron/0.6.1/src/middleware/mod.rs:428:40 clippy::similar_names "binding's name is too similar to existing binding" +iron/0.6.1/src/middleware/mod.rs:434:40 clippy::similar_names "binding's name is too similar to existing binding" +iron/0.6.1/src/middleware/mod.rs:444:40 clippy::similar_names "binding's name is too similar to existing binding" +iron/0.6.1/src/modifiers.rs:132:14 clippy::expect_fun_call "use of `expect` followed by a function call" +iron/0.6.1/src/request/mod.rs:113:24 clippy::similar_names "binding's name is too similar to existing binding" +iron/0.6.1/src/request/mod.rs:121:13 clippy::redundant_field_names "redundant field names in struct initialization" +iron/0.6.1/src/request/mod.rs:123:13 clippy::redundant_field_names "redundant field names in struct initialization" +iron/0.6.1/src/request/mod.rs:124:13 clippy::redundant_field_names "redundant field names in struct initialization" +iron/0.6.1/src/request/mod.rs:126:13 clippy::redundant_field_names "redundant field names in struct initialization" +iron/0.6.1/src/request/mod.rs:128:13 clippy::redundant_field_names "redundant field names in struct initialization" +iron/0.6.1/src/request/mod.rs:153:69 clippy::doc_markdown "you should put `HttpReader` between ticks in the documentation" +iron/0.6.1/src/request/mod.rs:154:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron/0.6.1/src/request/mod.rs:32:1 clippy::manual_non_exhaustive "this seems like a manual implementation of the non-exhaustive pattern" +iron/0.6.1/src/request/mod.rs:75:34 clippy::doc_markdown "you should put `HttpRequest` between ticks in the documentation" +iron/0.6.1/src/request/mod.rs:77:39 clippy::doc_markdown "you should put `HttpRequest` between ticks in the documentation" +iron/0.6.1/src/request/mod.rs:78:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron/0.6.1/src/request/mod.rs:82:13 clippy::similar_names "binding's name is too similar to existing binding" +iron/0.6.1/src/request/mod.rs:83:29 clippy::similar_names "binding's name is too similar to existing binding" +iron/0.6.1/src/request/mod.rs:85:24 clippy::similar_names "binding's name is too similar to existing binding" +iron/0.6.1/src/request/url.rs:109:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron/0.6.1/src/request/url.rs:117:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron/0.6.1/src/request/url.rs:129:1 clippy::from_over_into "an implementation of `From` is preferred since it gives you `Into<_>` for free where the reverse isn't true" +iron/0.6.1/src/request/url.rs:21:14 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +iron/0.6.1/src/request/url.rs:22:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron/0.6.1/src/request/url.rs:31:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron/0.6.1/src/request/url.rs:47:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron/0.6.1/src/request/url.rs:52:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron/0.6.1/src/request/url.rs:57:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron/0.6.1/src/request/url.rs:63:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron/0.6.1/src/request/url.rs:73:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron/0.6.1/src/request/url.rs:83:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron/0.6.1/src/request/url.rs:96:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron/0.6.1/src/response.rs:121:19 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +iron/0.6.1/src/response.rs:125:43 clippy::redundant_closure_for_method_calls "redundant closure found" +iron/0.6.1/src/response.rs:139:41 clippy::redundant_closure_for_method_calls "redundant closure found" +iron/0.6.1/src/response.rs:24:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron/0.6.1/src/response.rs:95:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron/0.6.1/src/response.rs:95:5 clippy::new_without_default "you should consider adding a `Default` implementation for `response::Response`" +libc/0.2.81/build.rs:114:19 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +libc/0.2.81/build.rs:124:5 clippy::question_mark "this block may be rewritten with the `?` operator" +libc/0.2.81/build.rs:133:5 clippy::question_mark "this block may be rewritten with the `?` operator" +libc/0.2.81/src/macros.rs:243:17 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +libc/0.2.81/src/macros.rs:243:17 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +libc/0.2.81/src/macros.rs:243:17 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:428:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:429:30 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:431:30 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:432:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:433:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:434:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:595:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:596:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:597:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:622:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:673:34 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:696:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:697:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:698:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:699:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:712:34 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:721:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:722:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:723:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:751:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:752:30 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:753:30 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:754:30 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:755:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:756:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:757:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:758:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:759:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:760:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:768:30 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:769:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:771:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:772:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:773:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:774:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:775:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:776:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:777:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:778:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:779:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:780:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:781:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:782:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:783:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:784:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:785:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:786:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:787:30 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:788:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:789:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:790:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:791:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:792:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:794:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:795:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:796:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:797:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:798:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:799:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:800:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:801:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:803:27 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:804:28 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:805:28 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:806:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:807:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:808:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:809:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:810:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:811:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:812:30 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:813:30 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:814:30 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:815:30 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:816:30 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:817:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:818:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:821:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:822:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:823:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:824:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:825:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:826:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:827:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:828:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:829:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:830:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:831:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:832:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:833:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:834:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:835:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:836:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:841:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:842:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:843:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:844:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:1120:38 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:178:34 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:291:5 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:291:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:302:5 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:302:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:355:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:355:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:359:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:359:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:363:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:363:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:367:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:367:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:371:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:371:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:534:36 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:645:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:727:40 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:728:40 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:729:39 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:731:44 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:732:36 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:733:41 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:734:43 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:735:42 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:736:40 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:737:36 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:738:37 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:741:39 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:742:40 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:743:40 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:744:40 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:745:40 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:746:43 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:747:42 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:748:40 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:749:39 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:750:41 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:751:41 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:752:43 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:753:42 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:755:42 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:756:41 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:757:41 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:758:39 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:759:39 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:761:41 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:762:44 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:763:45 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:764:40 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:765:40 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:766:40 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:767:44 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:768:44 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:769:39 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:770:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:771:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:772:37 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:773:39 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:774:45 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:775:41 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:776:39 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:803:34 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:841:30 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:842:37 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:982:40 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:984:46 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1209:36 clippy::cast_possible_truncation "casting `i32` to `i16` may truncate the value" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1210:36 clippy::cast_possible_truncation "casting `i32` to `i16` may truncate the value" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1235:39 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1236:41 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1274:42 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1324:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1333:37 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1334:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1346:34 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1346:34 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1346:34 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1347:37 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1347:37 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1347:37 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1348:36 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1348:36 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1348:36 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1349:37 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1349:37 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1349:37 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1350:35 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1350:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1350:35 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1351:36 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1351:36 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1351:36 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1352:31 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1352:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1352:31 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1419:36 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1420:36 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1421:36 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1422:36 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1423:36 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1490:37 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1561:46 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1562:45 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1567:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1568:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1586:26 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1587:34 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1588:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1589:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1897:38 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1898:51 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1900:39 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1969:34 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1970:34 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1971:36 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1972:36 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1973:36 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1974:37 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1975:37 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1976:36 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1977:36 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1978:39 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1979:39 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1980:39 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1981:39 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1982:39 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1983:39 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1984:38 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1985:38 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1986:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1987:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1988:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1989:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1990:38 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1991:37 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1992:37 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1993:38 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1994:37 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1995:37 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1996:37 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1997:37 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1998:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:1999:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2000:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2001:34 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2002:34 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2003:34 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2004:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2005:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2032:30 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2033:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2034:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2035:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2036:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2037:28 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2038:27 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2039:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2041:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2042:28 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2043:27 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2044:34 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2045:27 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2046:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2048:28 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2049:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2050:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2051:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2052:26 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2053:36 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2318:42 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2321:38 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2331:39 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2487:42 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2488:42 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2489:43 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2490:43 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2491:43 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2493:47 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2494:44 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2495:46 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2496:47 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2497:49 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2498:48 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2499:50 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2500:45 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2572:9 clippy::needless_return "unneeded `return` statement" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2578:20 clippy::zero_ptr "`0 as *mut _` detected" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2588:13 clippy::zero_ptr "`0 as *mut _` detected" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2596:52 clippy::used_underscore_binding "used binding `_dummy` which is prefixed with an underscore. A leading underscore signals that a binding will not be used." +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2597:11 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2601:21 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2611:9 clippy::unused_unit "unneeded unit expression" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2619:9 clippy::unused_unit "unneeded unit expression" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2634:9 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2647:25 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2648:25 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2649:9 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2654:18 clippy::identity_op "the operation is ineffective. Consider reducing it to `(dev & 0x00000000000000ff)`" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2654:25 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2655:25 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2656:9 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2660:21 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2661:21 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2663:25 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2664:25 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2665:16 clippy::identity_op "the operation is ineffective. Consider reducing it to `(minor & 0x000000ff)`" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2665:25 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:2666:25 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:40:1 clippy::empty_enum "enum with no variants" +libc/0.2.81/src/unix/linux_like/linux/mod.rs:954:34 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1000:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1001:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1002:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1016:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1017:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1018:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1019:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1020:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1029:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1030:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1031:30 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1032:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1033:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1034:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1035:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1041:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1042:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1043:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1044:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1045:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1046:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1047:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1048:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1049:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1050:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1051:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1053:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1054:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1055:30 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1056:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1057:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1058:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1059:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1060:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1073:42 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1074:43 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1075:37 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1076:37 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1077:41 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1078:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1079:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1080:36 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1081:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1082:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1083:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1084:38 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1086:30 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1087:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1089:30 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1090:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1091:30 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1094:40 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1095:37 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1096:41 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1097:40 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1098:39 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1099:34 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1100:36 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1101:38 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1102:37 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1105:44 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1106:41 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1107:42 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1108:42 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1109:41 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1110:46 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1111:41 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1112:44 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1113:40 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1114:47 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1115:36 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1126:34 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1127:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1128:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1179:32 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1180:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:1218:27 clippy::identity_op "the operation is ineffective. Consider reducing it to `IPOPT_CONTROL`" +libc/0.2.81/src/unix/linux_like/mod.rs:1314:9 clippy::precedence "operator precedence can trip the unwary" +libc/0.2.81/src/unix/linux_like/mod.rs:1323:13 clippy::zero_ptr "`0 as *mut _` detected" +libc/0.2.81/src/unix/linux_like/mod.rs:1332:9 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +libc/0.2.81/src/unix/linux_like/mod.rs:1337:9 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +libc/0.2.81/src/unix/linux_like/mod.rs:1341:18 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" +libc/0.2.81/src/unix/linux_like/mod.rs:1344:9 clippy::needless_return "unneeded `return` statement" +libc/0.2.81/src/unix/linux_like/mod.rs:1348:18 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" +libc/0.2.81/src/unix/linux_like/mod.rs:1350:9 clippy::needless_return "unneeded `return` statement" +libc/0.2.81/src/unix/linux_like/mod.rs:1354:18 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" +libc/0.2.81/src/unix/linux_like/mod.rs:1357:9 clippy::needless_return "unneeded `return` statement" +libc/0.2.81/src/unix/linux_like/mod.rs:1361:21 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" +libc/0.2.81/src/unix/linux_like/mod.rs:1381:9 clippy::cast_possible_truncation "casting `i32` to `i8` may truncate the value" +libc/0.2.81/src/unix/linux_like/mod.rs:1389:9 clippy::verbose_bit_mask "bit mask could be simplified with a call to `trailing_zeros`" +libc/0.2.81/src/unix/linux_like/mod.rs:446:31 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:591:36 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:592:38 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:593:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:594:33 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:595:34 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:596:36 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:597:37 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:598:37 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:599:39 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:600:34 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:601:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:602:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:607:37 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:608:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:764:35 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:765:39 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:991:30 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/linux_like/mod.rs:9:1 clippy::empty_enum "enum with no variants" +libc/0.2.81/src/unix/mod.rs:198:29 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/mod.rs:199:28 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/mod.rs:201:35 clippy::unnecessary_cast "casting integer literal to `usize` is unnecessary" +libc/0.2.81/src/unix/mod.rs:202:35 clippy::unnecessary_cast "casting integer literal to `usize` is unnecessary" +libc/0.2.81/src/unix/mod.rs:282:40 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/mod.rs:284:41 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/mod.rs:285:36 clippy::unreadable_literal "long literal lacking separators" +libc/0.2.81/src/unix/mod.rs:34:1 clippy::empty_enum "enum with no variants" +libc/0.2.81/src/unix/mod.rs:386:1 clippy::empty_enum "enum with no variants" +libc/0.2.81/src/unix/mod.rs:394:1 clippy::empty_enum "enum with no variants" +log/0.4.11/src/lib.rs:1047:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:1053:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:1059:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:1093:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:1093:5 clippy::new_without_default "you should consider adding a `Default` implementation for `MetadataBuilder<'a>`" +log/0.4.11/src/lib.rs:1118:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:1177:1 clippy::inline_always "you have declared `#[inline(always)]` on `max_level`. This is usually a bad idea" +log/0.4.11/src/lib.rs:1178:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:1306:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +log/0.4.11/src/lib.rs:1358:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:1359:5 clippy::if_not_else "unnecessary `!=` operation" +log/0.4.11/src/lib.rs:1407:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:329:27 clippy::derive_hash_xor_eq "you are deriving `Hash` but have implemented `PartialEq` explicitly" +log/0.4.11/src/lib.rs:356:1 clippy::expl_impl_clone_on_copy "you are implementing `Clone` explicitly on a `Copy` type" +log/0.4.11/src/lib.rs:448:12 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +log/0.4.11/src/lib.rs:468:13 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" +log/0.4.11/src/lib.rs:500:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:506:28 clippy::trivially_copy_pass_by_ref "this argument (8 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +log/0.4.11/src/lib.rs:506:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:520:27 clippy::derive_hash_xor_eq "you are deriving `Hash` but have implemented `PartialEq` explicitly" +log/0.4.11/src/lib.rs:538:1 clippy::expl_impl_clone_on_copy "you are implementing `Clone` explicitly on a `Copy` type" +log/0.4.11/src/lib.rs:653:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:661:21 clippy::trivially_copy_pass_by_ref "this argument (8 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +log/0.4.11/src/lib.rs:661:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:677:44 clippy::match_same_arms "this `match` has identical arm bodies" +log/0.4.11/src/lib.rs:758:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:764:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:770:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:776:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:782:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:788:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:794:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:803:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:809:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:818:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:908:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log/0.4.11/src/lib.rs:908:5 clippy::new_without_default "you should consider adding a `Default` implementation for `RecordBuilder<'a>`" +log/0.4.11/src/lib.rs:995:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/detection.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +proc-macro2/1.0.24/src/fallback.rs:108:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +proc-macro2/1.0.24/src/fallback.rs:269:20 clippy::unused_self "unused `self` argument" +proc-macro2/1.0.24/src/fallback.rs:430:24 clippy::trivially_copy_pass_by_ref "this argument (0 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +proc-macro2/1.0.24/src/fallback.rs:437:23 clippy::trivially_copy_pass_by_ref "this argument (0 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +proc-macro2/1.0.24/src/fallback.rs:437:23 clippy::unused_self "unused `self` argument" +proc-macro2/1.0.24/src/fallback.rs:471:17 clippy::trivially_copy_pass_by_ref "this argument (0 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +proc-macro2/1.0.24/src/fallback.rs:471:17 clippy::unused_self "unused `self` argument" +proc-macro2/1.0.24/src/fallback.rs:654:5 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +proc-macro2/1.0.24/src/fallback.rs:655:12 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +proc-macro2/1.0.24/src/fallback.rs:661:5 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +proc-macro2/1.0.24/src/fallback.rs:662:12 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +proc-macro2/1.0.24/src/fallback.rs:664:12 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +proc-macro2/1.0.24/src/fallback.rs:674:37 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +proc-macro2/1.0.24/src/fallback.rs:678:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +proc-macro2/1.0.24/src/fallback.rs:85:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +proc-macro2/1.0.24/src/fallback.rs:882:43 clippy::unused_self "unused `self` argument" +proc-macro2/1.0.24/src/lib.rs:1017:9 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:1081:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:1099:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:1117:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:1135:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:1141:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:1146:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:1151:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:1156:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:152:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:157:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:373:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:383:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:397:24 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +proc-macro2/1.0.24/src/lib.rs:397:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:403:23 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +proc-macro2/1.0.24/src/lib.rs:403:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:418:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:425:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:464:17 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +proc-macro2/1.0.24/src/lib.rs:500:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:626:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:633:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:641:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:652:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:662:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:672:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:734:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:743:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:752:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:757:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:788:19 clippy::doc_markdown "you should put `XID_Start` between ticks in the documentation" +proc-macro2/1.0.24/src/lib.rs:788:69 clippy::doc_markdown "you should put `XID_Continue` between ticks in the documentation" +proc-macro2/1.0.24/src/lib.rs:891:36 clippy::doc_markdown "you should put `syn::parse_str` between ticks in the documentation" +proc-macro2/1.0.24/src/lib.rs:894:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:911:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/lib.rs:996:9 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2/1.0.24/src/parse.rs:552:5 clippy::while_let_on_iterator "this loop could be written as a `for` loop" +proc-macro2/1.0.24/src/parse.rs:584:21 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +proc-macro2/1.0.24/src/parse.rs:602:20 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +proc-macro2/1.0.24/src/parse.rs:696:29 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" +proc-macro2/1.0.24/src/parse.rs:702:34 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" +proc-macro2/1.0.24/src/parse.rs:708:34 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" +proc-macro2/1.0.24/src/parse.rs:803:15 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" +proc-macro2/1.0.24/src/parse.rs:808:15 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" +proc-macro2/1.0.24/src/wrapper.rs:415:24 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +proc-macro2/1.0.24/src/wrapper.rs:429:23 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +proc-macro2/1.0.24/src/wrapper.rs:492:17 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +quote/1.0.7/src/ext.rs:10:1 clippy::module_name_repetitions "item name ends with its containing module's name" +quote/1.0.7/src/ext.rs:7:5 clippy::doc_markdown "you should put `TokenStream` between ticks in the documentation" +quote/1.0.7/src/ident_fragment.rs:13:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +quote/1.0.7/src/ident_fragment.rs:51:31 clippy::manual_strip "stripping a prefix manually" +quote/1.0.7/src/runtime.rs:52:5 clippy::module_name_repetitions "item name ends with its containing module's name" +quote/1.0.7/src/runtime.rs:63:5 clippy::module_name_repetitions "item name ends with its containing module's name" +quote/1.0.7/src/runtime.rs:66:33 clippy::doc_markdown "you should put `DoesNotHaveIter` between ticks in the documentation" +quote/1.0.7/src/runtime.rs:80:5 clippy::module_name_repetitions "item name ends with its containing module's name" +rand/0.7.3/src/distributions/bernoulli.rs:103:20 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" +rand/0.7.3/src/distributions/bernoulli.rs:103:20 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" +rand/0.7.3/src/distributions/bernoulli.rs:116:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +rand/0.7.3/src/distributions/bernoulli.rs:123:21 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" +rand/0.7.3/src/distributions/bernoulli.rs:123:21 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" +rand/0.7.3/src/distributions/bernoulli.rs:63:26 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand/0.7.3/src/distributions/bernoulli.rs:63:27 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +rand/0.7.3/src/distributions/bernoulli.rs:67:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand/0.7.3/src/distributions/bernoulli.rs:95:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +rand/0.7.3/src/distributions/bernoulli.rs:96:13 clippy::manual_range_contains "manual `Range::contains` implementation" +rand/0.7.3/src/distributions/binomial.rs:107:23 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand/0.7.3/src/distributions/binomial.rs:112:44 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand/0.7.3/src/distributions/binomial.rs:116:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rand/0.7.3/src/distributions/binomial.rs:150:28 clippy::redundant_else "redundant else block" +rand/0.7.3/src/distributions/binomial.rs:153:24 clippy::if_not_else "unnecessary boolean `not` operation" +rand/0.7.3/src/distributions/binomial.rs:158:28 clippy::redundant_else "redundant else block" +rand/0.7.3/src/distributions/binomial.rs:164:33 clippy::cast_sign_loss "casting `i64` to `u64` may lose the sign of the value" +rand/0.7.3/src/distributions/binomial.rs:166:28 clippy::redundant_else "redundant else block" +rand/0.7.3/src/distributions/binomial.rs:175:47 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand/0.7.3/src/distributions/binomial.rs:185:38 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand/0.7.3/src/distributions/binomial.rs:194:38 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand/0.7.3/src/distributions/binomial.rs:202:28 clippy::redundant_else "redundant else block" +rand/0.7.3/src/distributions/binomial.rs:209:25 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand/0.7.3/src/distributions/binomial.rs:221:26 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand/0.7.3/src/distributions/binomial.rs:222:26 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand/0.7.3/src/distributions/binomial.rs:223:25 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand/0.7.3/src/distributions/binomial.rs:224:25 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand/0.7.3/src/distributions/binomial.rs:226:17 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rand/0.7.3/src/distributions/binomial.rs:233:32 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand/0.7.3/src/distributions/binomial.rs:234:27 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand/0.7.3/src/distributions/binomial.rs:251:22 clippy::cast_sign_loss "casting `i64` to `u64` may lose the sign of the value" +rand/0.7.3/src/distributions/binomial.rs:255:9 clippy::if_not_else "unnecessary `!=` operation" +rand/0.7.3/src/distributions/binomial.rs:35:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/distributions/binomial.rs:45:17 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand/0.7.3/src/distributions/binomial.rs:46:5 clippy::cast_possible_truncation "casting `f64` to `i64` may truncate the value" +rand/0.7.3/src/distributions/binomial.rs:50:5 clippy::too_many_lines "this function has too many lines (143/100)" +rand/0.7.3/src/distributions/binomial.rs:76:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rand/0.7.3/src/distributions/binomial.rs:78:12 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand/0.7.3/src/distributions/binomial.rs:81:21 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand/0.7.3/src/distributions/binomial.rs:82:32 clippy::cast_possible_truncation "casting `u64` to `i32` may truncate the value" +rand/0.7.3/src/distributions/binomial.rs:88:26 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand/0.7.3/src/distributions/binomial.rs:99:21 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand/0.7.3/src/distributions/cauchy.rs:33:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/distributions/dirichlet.rs:52:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/distributions/dirichlet.rs:64:32 clippy::unseparated_literal_suffix "float type suffix should be separated by an underscore" +rand/0.7.3/src/distributions/dirichlet.rs:65:23 clippy::unseparated_literal_suffix "float type suffix should be separated by an underscore" +rand/0.7.3/src/distributions/exponential.rs:76:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/distributions/float.rs:73:1 clippy::module_name_repetitions "item name ends with its containing module's name" +rand/0.7.3/src/distributions/gamma.rs:13:5 clippy::enum_glob_use "usage of wildcard import for enum variants" +rand/0.7.3/src/distributions/gamma.rs:14:5 clippy::enum_glob_use "usage of wildcard import for enum variants" +rand/0.7.3/src/distributions/gamma.rs:189:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/distributions/gamma.rs:230:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/distributions/gamma.rs:259:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/distributions/gamma.rs:287:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/distributions/gamma.rs:90:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/distributions/integer.rs:23:9 clippy::cast_possible_truncation "casting `u32` to `u8` may truncate the value" +rand/0.7.3/src/distributions/integer.rs:30:9 clippy::cast_possible_truncation "casting `u32` to `u16` may truncate the value" +rand/0.7.3/src/distributions/integer.rs:69:9 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +rand/0.7.3/src/distributions/mod.rs:263:5 clippy::inline_always "you have declared `#[inline(always)]` on `next`. This is usually a bad idea" +rand/0.7.3/src/distributions/normal.rs:100:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/distributions/normal.rs:119:1 clippy::module_name_repetitions "item name ends with its containing module's name" +rand/0.7.3/src/distributions/normal.rs:131:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/distributions/normal.rs:31:1 clippy::module_name_repetitions "item name ends with its containing module's name" +rand/0.7.3/src/distributions/normal.rs:47:25 clippy::unseparated_literal_suffix "float type suffix should be separated by an underscore" +rand/0.7.3/src/distributions/normal.rs:48:25 clippy::unseparated_literal_suffix "float type suffix should be separated by an underscore" +rand/0.7.3/src/distributions/other.rs:89:9 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +rand/0.7.3/src/distributions/pareto.rs:32:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/distributions/poisson.rs:35:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/distributions/poisson.rs:87:30 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" +rand/0.7.3/src/distributions/poisson.rs:87:30 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" +rand/0.7.3/src/distributions/triangular.rs:32:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/distributions/uniform.rs:146:4 clippy::needless_doctest_main "needless `fn main` in doctest" +rand/0.7.3/src/distributions/uniform.rs:199:1 clippy::module_name_repetitions "item name ends with its containing module's name" +rand/0.7.3/src/distributions/uniform.rs:214:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand/0.7.3/src/distributions/uniform.rs:283:14 clippy::doc_markdown "you should put `SampleUniform` between ticks in the documentation" +rand/0.7.3/src/distributions/uniform.rs:283:46 clippy::doc_markdown "you should put `SampleUniform` between ticks in the documentation" +rand/0.7.3/src/distributions/uniform.rs:296:5 clippy::inline_always "you have declared `#[inline(always)]` on `borrow`. This is usually a bad idea" +rand/0.7.3/src/distributions/uniform.rs:304:5 clippy::inline_always "you have declared `#[inline(always)]` on `borrow`. This is usually a bad idea" +rand/0.7.3/src/distributions/uniform.rs:350:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand/0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" +rand/0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" +rand/0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" +rand/0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" +rand/0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" +rand/0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" +rand/0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" +rand/0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" +rand/0.7.3/src/distributions/uniform.rs:56:10 clippy::doc_markdown "you should put `SampleBorrow` between ticks in the documentation" +rand/0.7.3/src/distributions/uniform.rs:647:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand/0.7.3/src/distributions/uniform.rs:840:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand/0.7.3/src/distributions/uniform.rs:913:13 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" +rand/0.7.3/src/distributions/uniform.rs:943:54 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +rand/0.7.3/src/distributions/unit_circle.rs:30:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/distributions/unit_sphere.rs:24:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand/0.7.3/src/distributions/unit_sphere.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/distributions/utils.rs:247:15 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" +rand/0.7.3/src/distributions/utils.rs:248:20 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" +rand/0.7.3/src/distributions/utils.rs:249:18 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" +rand/0.7.3/src/distributions/utils.rs:254:5 clippy::inline_always "you have declared `#[inline(always)]` on `lanes`. This is usually a bad idea" +rand/0.7.3/src/distributions/utils.rs:258:5 clippy::inline_always "you have declared `#[inline(always)]` on `splat`. This is usually a bad idea" +rand/0.7.3/src/distributions/utils.rs:262:5 clippy::inline_always "you have declared `#[inline(always)]` on `extract`. This is usually a bad idea" +rand/0.7.3/src/distributions/utils.rs:267:5 clippy::inline_always "you have declared `#[inline(always)]` on `replace`. This is usually a bad idea" +rand/0.7.3/src/distributions/utils.rs:281:5 clippy::inline_always "you have declared `#[inline(always)]` on `any`. This is usually a bad idea" +rand/0.7.3/src/distributions/utils.rs:286:5 clippy::inline_always "you have declared `#[inline(always)]` on `all`. This is usually a bad idea" +rand/0.7.3/src/distributions/utils.rs:291:5 clippy::inline_always "you have declared `#[inline(always)]` on `none`. This is usually a bad idea" +rand/0.7.3/src/distributions/utils.rs:488:17 clippy::doc_markdown "you should put `x_i` between ticks in the documentation" +rand/0.7.3/src/distributions/utils.rs:489:50 clippy::doc_markdown "you should put `x_i` between ticks in the documentation" +rand/0.7.3/src/distributions/utils.rs:489:63 clippy::doc_markdown "you should put `f(x_i` between ticks in the documentation" +rand/0.7.3/src/distributions/utils.rs:490:40 clippy::doc_markdown "you should put `f(x_i` between ticks in the documentation" +rand/0.7.3/src/distributions/utils.rs:490:49 clippy::doc_markdown "you should put `f(x_{i+1` between ticks in the documentation" +rand/0.7.3/src/distributions/utils.rs:518:17 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +rand/0.7.3/src/distributions/weibull.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/distributions/weighted/alias_method.rs:113:21 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" +rand/0.7.3/src/distributions/weighted/alias_method.rs:125:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rand/0.7.3/src/distributions/weighted/alias_method.rs:131:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rand/0.7.3/src/distributions/weighted/alias_method.rs:180:36 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +rand/0.7.3/src/distributions/weighted/alias_method.rs:182:34 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +rand/0.7.3/src/distributions/weighted/alias_method.rs:259:28 clippy::clone_on_copy "using `clone` on type `distributions::uniform::Uniform` which implements the `Copy` trait" +rand/0.7.3/src/distributions/weighted/alias_method.rs:296:9 clippy::map_clone "you are using an explicit closure for copying elements" +rand/0.7.3/src/distributions/weighted/alias_method.rs:321:9 clippy::map_clone "you are using an explicit closure for copying elements" +rand/0.7.3/src/distributions/weighted/alias_method.rs:78:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +rand/0.7.3/src/distributions/weighted/alias_method.rs:78:5 clippy::too_many_lines "this function has too many lines (106/100)" +rand/0.7.3/src/distributions/weighted/alias_method.rs:85:17 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +rand/0.7.3/src/distributions/weighted/alias_method.rs:87:31 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +rand/0.7.3/src/distributions/weighted/mod.rs:100:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +rand/0.7.3/src/distributions/weighted/mod.rs:144:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +rand/0.7.3/src/distributions/weighted/mod.rs:169:16 clippy::int_plus_one "unnecessary `>= y + 1` or `x - 1 >=`" +rand/0.7.3/src/distributions/weighted/mod.rs:386:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand/0.7.3/src/distributions/weighted/mod.rs:85:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand/0.7.3/src/lib.rs:333:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +rand/0.7.3/src/lib.rs:404:14 clippy::wrong_self_convention "methods called `to_*` usually take self by reference; consider choosing a less ambiguous name" +rand/0.7.3/src/lib.rs:552:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +rand/0.7.3/src/rngs/adapter/read.rs:47:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand/0.7.3/src/rngs/adapter/read.rs:89:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand/0.7.3/src/rngs/adapter/reseeding.rs:100:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +rand/0.7.3/src/rngs/adapter/reseeding.rs:112:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea" +rand/0.7.3/src/rngs/adapter/reseeding.rs:117:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea" +rand/0.7.3/src/rngs/adapter/reseeding.rs:198:13 clippy::cast_possible_wrap "casting `u64` to `i64` may wrap around the value" +rand/0.7.3/src/rngs/adapter/reseeding.rs:231:9 clippy::cast_possible_wrap "casting `usize` to `isize` may wrap around the value" +rand/0.7.3/src/rngs/adapter/reseeding.rs:27:28 clippy::doc_markdown "you should put `ChaCha` between ticks in the documentation" +rand/0.7.3/src/rngs/adapter/reseeding.rs:79:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand/0.7.3/src/rngs/entropy.rs:24:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand/0.7.3/src/rngs/entropy.rs:34:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/rngs/mock.rs:36:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/rngs/mock.rs:47:9 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +rand/0.7.3/src/rngs/mod.rs:61:74 clippy::doc_markdown "you should put `ChaCha20` between ticks in the documentation" +rand/0.7.3/src/rngs/std.rs:25:39 clippy::doc_markdown "you should put `ChaCha` between ticks in the documentation" +rand/0.7.3/src/rngs/std.rs:32:10 clippy::doc_markdown "you should put `rand_chacha` between ticks in the documentation" +rand/0.7.3/src/rngs/std.rs:36:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand/0.7.3/src/rngs/std.rs:39:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea" +rand/0.7.3/src/rngs/std.rs:44:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea" +rand/0.7.3/src/rngs/std.rs:49:5 clippy::inline_always "you have declared `#[inline(always)]` on `fill_bytes`. This is usually a bad idea" +rand/0.7.3/src/rngs/std.rs:54:5 clippy::inline_always "you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea" +rand/0.7.3/src/rngs/std.rs:63:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_seed`. This is usually a bad idea" +rand/0.7.3/src/rngs/std.rs:68:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_rng`. This is usually a bad idea" +rand/0.7.3/src/rngs/thread.rs:57:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand/0.7.3/src/rngs/thread.rs:80:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand/0.7.3/src/rngs/thread.rs:80:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +rand/0.7.3/src/rngs/thread.rs:81:35 clippy::redundant_closure_for_method_calls "redundant closure found" +rand/0.7.3/src/rngs/thread.rs:93:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea" +rand/0.7.3/src/rngs/thread.rs:98:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea" +rand/0.7.3/src/seq/index.rs:127:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand/0.7.3/src/seq/index.rs:139:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +rand/0.7.3/src/seq/index.rs:159:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand/0.7.3/src/seq/index.rs:171:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +rand/0.7.3/src/seq/index.rs:180:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +rand/0.7.3/src/seq/index.rs:223:18 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +rand/0.7.3/src/seq/index.rs:224:18 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +rand/0.7.3/src/seq/index.rs:233:25 clippy::cast_precision_loss "casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide)" +rand/0.7.3/src/seq/index.rs:236:27 clippy::cast_precision_loss "casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide)" +rand/0.7.3/src/seq/index.rs:244:12 clippy::cast_precision_loss "casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide)" +rand/0.7.3/src/seq/index.rs:244:37 clippy::cast_precision_loss "casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide)" +rand/0.7.3/src/seq/index.rs:29:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand/0.7.3/src/seq/index.rs:39:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/seq/index.rs:48:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/seq/index.rs:60:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/seq/index.rs:69:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/seq/index.rs:78:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/seq/index.rs:87:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand/0.7.3/src/seq/index.rs:87:5 clippy::should_implement_trait "method `into_iter` can be confused for the standard trait method `std::iter::IntoIterator::into_iter`" +rand/0.7.3/src/seq/index.rs:97:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +rand/0.7.3/src/seq/mod.rs:141:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +rand/0.7.3/src/seq/mod.rs:168:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +rand/0.7.3/src/seq/mod.rs:229:4 clippy::needless_doctest_main "needless `fn main` in doctest" +rand/0.7.3/src/seq/mod.rs:292:29 clippy::cast_precision_loss "casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand/0.7.3/src/seq/mod.rs:410:23 clippy::default_trait_access "calling `std::marker::PhantomData::default()` is more clear than this expression" +rand/0.7.3/src/seq/mod.rs:45:4 clippy::needless_doctest_main "needless `fn main` in doctest" +rand/0.7.3/src/seq/mod.rs:527:26 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +rand_core/0.6.0/src/block.rs:117:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand_core/0.6.0/src/block.rs:153:5 clippy::inline_always "you have declared `#[inline(always)]` on `index`. This is usually a bad idea" +rand_core/0.6.0/src/block.rs:230:5 clippy::inline_always "you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea" +rand_core/0.6.0/src/block.rs:240:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_seed`. This is usually a bad idea" +rand_core/0.6.0/src/block.rs:245:5 clippy::inline_always "you have declared `#[inline(always)]` on `seed_from_u64`. This is usually a bad idea" +rand_core/0.6.0/src/block.rs:250:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_rng`. This is usually a bad idea" +rand_core/0.6.0/src/block.rs:280:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand_core/0.6.0/src/block.rs:319:5 clippy::inline_always "you have declared `#[inline(always)]` on `index`. This is usually a bad idea" +rand_core/0.6.0/src/block.rs:405:5 clippy::inline_always "you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea" +rand_core/0.6.0/src/block.rs:415:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_seed`. This is usually a bad idea" +rand_core/0.6.0/src/block.rs:420:5 clippy::inline_always "you have declared `#[inline(always)]` on `seed_from_u64`. This is usually a bad idea" +rand_core/0.6.0/src/block.rs:425:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_rng`. This is usually a bad idea" +rand_core/0.6.0/src/block.rs:67:14 clippy::doc_markdown "you should put `module][crate::block` between ticks in the documentation" +rand_core/0.6.0/src/block.rs:68:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand_core/0.6.0/src/error.rs:106:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand_core/0.6.0/src/error.rs:87:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand_core/0.6.0/src/error.rs:95:74 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +rand_core/0.6.0/src/lib.rs:179:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +rand_core/0.6.0/src/lib.rs:301:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand_core/0.6.0/src/lib.rs:303:26 clippy::unreadable_literal "long literal lacking separators" +rand_core/0.6.0/src/lib.rs:304:26 clippy::unreadable_literal "long literal lacking separators" +rand_core/0.6.0/src/lib.rs:313:30 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +rand_core/0.6.0/src/lib.rs:314:23 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +rand_core/0.6.0/src/lib.rs:346:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +rand_core/0.6.0/src/lib.rs:381:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea" +rand_core/0.6.0/src/lib.rs:386:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea" +rand_core/0.6.0/src/lib.rs:391:5 clippy::inline_always "you have declared `#[inline(always)]` on `fill_bytes`. This is usually a bad idea" +rand_core/0.6.0/src/lib.rs:396:5 clippy::inline_always "you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea" +rayon/1.5.0/src/collections/binary_heap.rs:7:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/collections/binary_heap.rs:8:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/collections/btree_map.rs:7:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/collections/btree_map.rs:8:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/collections/btree_set.rs:7:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/collections/btree_set.rs:8:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/collections/hash_map.rs:10:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/collections/hash_map.rs:9:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/collections/hash_set.rs:10:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/collections/hash_set.rs:9:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/collections/linked_list.rs:7:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/collections/linked_list.rs:8:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/collections/mod.rs:59:32 clippy::mem_replace_with_default "replacing a value of type `T` with `T::default()` is better expressed using `std::mem::take`" +rayon/1.5.0/src/collections/vec_deque.rs:8:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/collections/vec_deque.rs:9:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/compile_fail/cannot_collect_filtermap_data.rs:2:1 clippy::needless_doctest_main "needless `fn main` in doctest" +rayon/1.5.0/src/compile_fail/cannot_zip_filtered_data.rs:2:1 clippy::needless_doctest_main "needless `fn main` in doctest" +rayon/1.5.0/src/compile_fail/cell_par_iter.rs:2:1 clippy::needless_doctest_main "needless `fn main` in doctest" +rayon/1.5.0/src/compile_fail/no_send_par_iter.rs:25:1 clippy::needless_doctest_main "needless `fn main` in doctest" +rayon/1.5.0/src/compile_fail/no_send_par_iter.rs:46:1 clippy::needless_doctest_main "needless `fn main` in doctest" +rayon/1.5.0/src/compile_fail/no_send_par_iter.rs:4:1 clippy::needless_doctest_main "needless `fn main` in doctest" +rayon/1.5.0/src/compile_fail/rc_par_iter.rs:2:1 clippy::needless_doctest_main "needless `fn main` in doctest" +rayon/1.5.0/src/iter/chain.rs:103:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/chain.rs:122:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/chain.rs:128:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/chain.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/chain.rs:221:36 clippy::doc_markdown "you should put `ExactSizeIterator` between ticks in the documentation" +rayon/1.5.0/src/iter/chain.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/chain.rs:51:38 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" +rayon/1.5.0/src/iter/chain.rs:58:14 clippy::shadow_unrelated "`a` is being shadowed" +rayon/1.5.0/src/iter/chain.rs:58:17 clippy::shadow_unrelated "`b` is being shadowed" +rayon/1.5.0/src/iter/chain.rs:78:14 clippy::shadow_unrelated "`a` is being shadowed" +rayon/1.5.0/src/iter/chain.rs:78:17 clippy::shadow_unrelated "`b` is being shadowed" +rayon/1.5.0/src/iter/chain.rs:97:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/chunks.rs:3:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/chunks.rs:4:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/chunks.rs:77:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/chunks.rs:83:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/cloned.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/cloned.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/cloned.rs:71:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/cloned.rs:75:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/collect/consumer.rs:141:5 clippy::doc_markdown "you should put `CollectReducer` between ticks in the documentation" +rayon/1.5.0/src/iter/collect/consumer.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/collect/consumer.rs:28:5 clippy::doc_markdown "you should put `CollectResult` between ticks in the documentation" +rayon/1.5.0/src/iter/collect/consumer.rs:36:37 clippy::mut_mut "generally you want to avoid `&mut &mut _` if possible" +rayon/1.5.0/src/iter/collect/consumer.rs:36:37 clippy::mut_mut "generally you want to avoid `&mut &mut _` if possible" +rayon/1.5.0/src/iter/collect/mod.rs:154:9 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +rayon/1.5.0/src/iter/copied.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/copied.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/copied.rs:71:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/copied.rs:75:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/empty.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/empty.rs:24:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +rayon/1.5.0/src/iter/empty.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/enumerate.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/enumerate.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/enumerate.rs:64:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/enumerate.rs:68:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/extend.rs:143:63 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon/1.5.0/src/iter/extend.rs:182:57 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon/1.5.0/src/iter/extend.rs:218:32 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon/1.5.0/src/iter/extend.rs:218:59 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon/1.5.0/src/iter/extend.rs:25:42 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon/1.5.0/src/iter/extend.rs:287:62 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon/1.5.0/src/iter/extend.rs:322:56 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon/1.5.0/src/iter/extend.rs:41:27 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon/1.5.0/src/iter/extend.rs:47:30 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon/1.5.0/src/iter/extend.rs:47:56 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon/1.5.0/src/iter/extend.rs:47:74 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon/1.5.0/src/iter/extend.rs:53:29 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon/1.5.0/src/iter/extend.rs:57:36 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon/1.5.0/src/iter/extend.rs:59:61 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon/1.5.0/src/iter/filter.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/filter.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/filter_map.rs:123:9 clippy::option_if_let_else "use Option::map_or instead of an if let/else" +rayon/1.5.0/src/iter/filter_map.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/filter_map.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/find.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/find.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/find_first_last/mod.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/find_first_last/mod.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/find_first_last/mod.rs:32:67 clippy::doc_markdown "you should put `MatchPosition` between ticks in the documentation" +rayon/1.5.0/src/iter/flat_map.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/flat_map.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/flat_map_iter.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/flat_map_iter.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/flatten.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/flatten.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/flatten_iter.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/flatten_iter.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/fold.rs:158:13 clippy::similar_names "binding's name is too similar to existing binding" +rayon/1.5.0/src/iter/fold.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/fold.rs:204:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rayon/1.5.0/src/iter/fold.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/for_each.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/for_each.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/inspect.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/inspect.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/inspect.rs:83:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/inspect.rs:88:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/interleave.rs:111:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/interleave.rs:119:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/interleave.rs:195:30 clippy::doc_markdown "you should put `self.i_len` between ticks in the documentation" +rayon/1.5.0/src/iter/interleave.rs:195:43 clippy::doc_markdown "you should put `self.j_len` between ticks in the documentation" +rayon/1.5.0/src/iter/interleave.rs:199:23 clippy::doc_markdown "you should put `self.i_len` between ticks in the documentation" +rayon/1.5.0/src/iter/interleave.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/interleave.rs:200:23 clippy::doc_markdown "you should put `self.j_len` between ticks in the documentation" +rayon/1.5.0/src/iter/interleave.rs:249:41 clippy::doc_markdown "you should put `DoubleEndedIterator` between ticks in the documentation" +rayon/1.5.0/src/iter/interleave.rs:250:5 clippy::doc_markdown "you should put `ExactSizeIterator` between ticks in the documentation" +rayon/1.5.0/src/iter/interleave.rs:263:33 clippy::doc_markdown "you should put `InterleaveSeq` between ticks in the documentation" +rayon/1.5.0/src/iter/interleave.rs:280:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +rayon/1.5.0/src/iter/interleave.rs:285:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +rayon/1.5.0/src/iter/interleave.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/interleave.rs:313:9 clippy::comparison_chain "`if` chain can be rewritten with `match`" +rayon/1.5.0/src/iter/interleave.rs:82:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/interleave.rs:90:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/interleave_shortest.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/intersperse.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/intersperse.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/intersperse.rs:90:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/intersperse.rs:96:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/len.rs:12:1 clippy::module_name_repetitions "item name ends with its containing module's name" +rayon/1.5.0/src/iter/len.rs:146:1 clippy::module_name_repetitions "item name ends with its containing module's name" +rayon/1.5.0/src/iter/len.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/len.rs:200:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/len.rs:205:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/len.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/len.rs:66:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/len.rs:71:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/map.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/map.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/map.rs:84:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/map.rs:89:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/map_with.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/map_with.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/map_with.rs:419:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/map_with.rs:425:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/map_with.rs:90:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/map_with.rs:96:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/mod.rs:1874:24 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +rayon/1.5.0/src/iter/mod.rs:2171:1 clippy::len_without_is_empty "trait `IndexedParallelIterator` has a `len` method but no (possibly inherited) `is_empty` method" +rayon/1.5.0/src/iter/mod.rs:2371:26 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +rayon/1.5.0/src/iter/mod.rs:2411:26 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +rayon/1.5.0/src/iter/mod.rs:82:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/multizip.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/multizip.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/noop.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/once.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/once.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/panic_fuse.rs:102:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/panic_fuse.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/panic_fuse.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/panic_fuse.rs:98:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/par_bridge.rs:136:28 clippy::redundant_else "redundant else block" +rayon/1.5.0/src/iter/par_bridge.rs:163:28 clippy::redundant_else "redundant else block" +rayon/1.5.0/src/iter/plumbing/mod.rs:216:58 clippy::doc_markdown "you should put `find_first` between ticks in the documentation" +rayon/1.5.0/src/iter/plumbing/mod.rs:359:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/plumbing/mod.rs:364:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/plumbing/mod.rs:399:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/plumbing/mod.rs:53:19 clippy::doc_markdown "you should put `DoubleEndedIterator` between ticks in the documentation" +rayon/1.5.0/src/iter/plumbing/mod.rs:53:43 clippy::doc_markdown "you should put `ExactSizeIterator` between ticks in the documentation" +rayon/1.5.0/src/iter/plumbing/mod.rs:54:31 clippy::doc_markdown "you should put `IntoIterator` between ticks in the documentation" +rayon/1.5.0/src/iter/plumbing/mod.rs:55:5 clippy::doc_markdown "you should put `IntoIterator` between ticks in the documentation" +rayon/1.5.0/src/iter/positions.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/positions.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/product.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/reduce.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/repeat.rs:103:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rayon/1.5.0/src/iter/repeat.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/repeat.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/rev.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/rev.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/rev.rs:63:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/rev.rs:68:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/skip.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/skip.rs:3:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/skip.rs:68:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/skip.rs:73:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/splitter.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/splitter.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/step_by.rs:4:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/step_by.rs:5:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/step_by.rs:73:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/step_by.rs:79:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/sum.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/take.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/take.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/take.rs:67:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/take.rs:72:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/try_fold.rs:190:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rayon/1.5.0/src/iter/try_fold.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/try_fold.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/try_reduce.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/try_reduce_with.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/unzip.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/unzip.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/update.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/update.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/update.rs:82:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/update.rs:87:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/while_some.rs:130:22 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +rayon/1.5.0/src/iter/while_some.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/while_some.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/zip.rs:102:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/zip.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/zip.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/zip.rs:74:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/zip.rs:79:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/zip.rs:97:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/iter/zip_eq.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/iter/zip_eq.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/option.rs:8:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/option.rs:9:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/par_either.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/par_either.rs:3:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/private.rs:9:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rayon/1.5.0/src/range.rs:19:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/range.rs:20:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/range_inclusive.rs:194:9 clippy::range_plus_one "an inclusive range would be more readable" +rayon/1.5.0/src/range_inclusive.rs:194:9 clippy::range_plus_one "an inclusive range would be more readable" +rayon/1.5.0/src/range_inclusive.rs:19:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/range_inclusive.rs:209:9 clippy::range_plus_one "an inclusive range would be more readable" +rayon/1.5.0/src/range_inclusive.rs:209:9 clippy::range_plus_one "an inclusive range would be more readable" +rayon/1.5.0/src/range_inclusive.rs:20:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/range_inclusive.rs:231:9 clippy::range_plus_one "an inclusive range would be more readable" +rayon/1.5.0/src/range_inclusive.rs:231:9 clippy::range_plus_one "an inclusive range would be more readable" +rayon/1.5.0/src/result.rs:8:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/result.rs:9:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/slice/mergesort.rs:102:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/slice/mergesort.rs:109:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/slice/mergesort.rs:114:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/slice/mergesort.rs:211:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/slice/mergesort.rs:217:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/slice/mergesort.rs:251:5 clippy::doc_markdown "you should put `TimSort` between ticks in the documentation" +rayon/1.5.0/src/slice/mergesort.rs:252:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +rayon/1.5.0/src/slice/mergesort.rs:286:59 clippy::doc_markdown "you should put `TimSort` between ticks in the documentation" +rayon/1.5.0/src/slice/mergesort.rs:333:24 clippy::redundant_else "redundant else block" +rayon/1.5.0/src/slice/mergesort.rs:513:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/slice/mergesort.rs:521:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/slice/mergesort.rs:7:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/slice/mergesort.rs:98:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/slice/mod.rs:15:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/slice/mod.rs:16:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/slice/mod.rs:17:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/slice/mod.rs:25:1 clippy::module_name_repetitions "item name ends with its containing module's name" +rayon/1.5.0/src/slice/mod.rs:657:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rayon/1.5.0/src/slice/mod.rs:971:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rayon/1.5.0/src/slice/quicksort.rs:230:36 clippy::doc_markdown "you should put `BlockQuicksort` between ticks in the documentation" +rayon/1.5.0/src/slice/quicksort.rs:233:1 clippy::too_many_lines "this function has too many lines (117/100)" +rayon/1.5.0/src/slice/quicksort.rs:258:26 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +rayon/1.5.0/src/slice/quicksort.rs:265:26 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +rayon/1.5.0/src/slice/quicksort.rs:268:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon/1.5.0/src/slice/quicksort.rs:308:30 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" +rayon/1.5.0/src/slice/quicksort.rs:325:30 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" +rayon/1.5.0/src/slice/quicksort.rs:393:36 clippy::cast_possible_wrap "casting `u8` to `isize` may wrap around the value on targets with 32-bit wide pointers" +rayon/1.5.0/src/slice/quicksort.rs:405:40 clippy::cast_possible_wrap "casting `u8` to `isize` may wrap around the value on targets with 32-bit wide pointers" +rayon/1.5.0/src/slice/quicksort.rs:430:14 clippy::shadow_unrelated "`pivot` is being shadowed" +rayon/1.5.0/src/slice/quicksort.rs:439:13 clippy::shadow_unrelated "`pivot` is being shadowed" +rayon/1.5.0/src/slice/quicksort.rs:482:10 clippy::shadow_unrelated "`pivot` is being shadowed" +rayon/1.5.0/src/slice/quicksort.rs:491:9 clippy::shadow_unrelated "`pivot` is being shadowed" +rayon/1.5.0/src/slice/quicksort.rs:534:26 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +rayon/1.5.0/src/slice/quicksort.rs:545:17 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +rayon/1.5.0/src/slice/quicksort.rs:588:17 clippy::identity_op "the operation is ineffective. Consider reducing it to `len / 4`" +rayon/1.5.0/src/slice/quicksort.rs:716:14 clippy::shadow_unrelated "`pivot` is being shadowed" +rayon/1.5.0/src/split_producer.rs:56:16 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" +rayon/1.5.0/src/split_producer.rs:92:9 clippy::option_if_let_else "use Option::map_or instead of an if let/else" +rayon/1.5.0/src/str.rs:16:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/str.rs:17:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/str.rs:18:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/str.rs:25:5 clippy::cast_possible_wrap "casting `u8` to `i8` may wrap around the value" +rayon/1.5.0/src/str.rs:715:9 clippy::manual_strip "stripping a suffix manually" +rayon/1.5.0/src/string.rs:5:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/vec.rs:137:12 clippy::len_zero "length comparison to zero" +rayon/1.5.0/src/vec.rs:8:5 clippy::wildcard_imports "usage of wildcard import" +rayon/1.5.0/src/vec.rs:9:5 clippy::wildcard_imports "usage of wildcard import" +regex/1.3.2/src/backtrack.rs:100:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/backtrack.rs:133:17 clippy::same_item_push "it looks like the same item is being pushed into this Vec" +regex/1.3.2/src/backtrack.rs:145:20 clippy::if_not_else "unnecessary boolean `not` operation" +regex/1.3.2/src/backtrack.rs:199:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/backtrack.rs:223:29 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/backtrack.rs:230:66 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/backtrack.rs:284:21 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" +regex/1.3.2/src/backtrack.rs:287:5 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex/1.3.2/src/backtrack.rs:97:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/backtrack.rs:98:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/backtrack.rs:99:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:1005:32 clippy::unreadable_literal "long literal lacking separators" +regex/1.3.2/src/compile.rs:1006:21 clippy::unreadable_literal "long literal lacking separators" +regex/1.3.2/src/compile.rs:1008:18 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" +regex/1.3.2/src/compile.rs:1009:18 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" +regex/1.3.2/src/compile.rs:1010:9 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +regex/1.3.2/src/compile.rs:102:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/compile.rs:1037:37 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" +regex/1.3.2/src/compile.rs:1037:55 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" +regex/1.3.2/src/compile.rs:1040:28 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" +regex/1.3.2/src/compile.rs:1040:38 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" +regex/1.3.2/src/compile.rs:1051:25 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +regex/1.3.2/src/compile.rs:1071:8 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" +regex/1.3.2/src/compile.rs:112:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +regex/1.3.2/src/compile.rs:154:30 clippy::redundant_closure_for_method_calls "redundant closure found" +regex/1.3.2/src/compile.rs:156:30 clippy::redundant_closure_for_method_calls "redundant closure found" +regex/1.3.2/src/compile.rs:185:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +regex/1.3.2/src/compile.rs:187:40 clippy::redundant_closure_for_method_calls "redundant closure found" +regex/1.3.2/src/compile.rs:201:53 clippy::doc_markdown "you should put `MaybeInsts` between ticks in the documentation" +regex/1.3.2/src/compile.rs:241:63 clippy::doc_markdown "you should put `c_concat` between ticks in the documentation" +regex/1.3.2/src/compile.rs:245:5 clippy::too_many_lines "this function has too many lines (111/100)" +regex/1.3.2/src/compile.rs:247:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/compile.rs:373:24 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:373:36 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:378:12 clippy::if_not_else "unnecessary boolean `not` operation" +regex/1.3.2/src/compile.rs:400:37 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:407:51 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:409:24 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:417:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +regex/1.3.2/src/compile.rs:42:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/compile.rs:42:5 clippy::new_without_default "you should consider adding a `Default` implementation for `compile::Compiler`" +regex/1.3.2/src/compile.rs:444:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +regex/1.3.2/src/compile.rs:445:57 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:446:20 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:466:20 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:466:32 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:519:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/compile.rs:55:57 clippy::doc_markdown "you should put `size_limit` between ticks in the documentation" +regex/1.3.2/src/compile.rs:58:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/compile.rs:748:41 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:74:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/compile.rs:751:54 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:765:41 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:765:55 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:825:39 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:825:51 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:828:49 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:828:61 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:830:59 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:830:71 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:832:43 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:835:41 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:835:53 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:835:67 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:83:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/compile.rs:896:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +regex/1.3.2/src/compile.rs:905:17 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:953:17 clippy::doc_markdown "you should put `HashMap` between ticks in the documentation" +regex/1.3.2/src/compile.rs:95:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/compile.rs:980:26 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +regex/1.3.2/src/compile.rs:994:44 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/compile.rs:994:54 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/dfa.rs:1007:17 clippy::similar_names "binding's name is too similar to existing binding" +regex/1.3.2/src/dfa.rs:1010:22 clippy::similar_names "binding's name is too similar to existing binding" +regex/1.3.2/src/dfa.rs:1059:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/dfa.rs:1060:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/dfa.rs:1084:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex/1.3.2/src/dfa.rs:1087:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex/1.3.2/src/dfa.rs:1090:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex/1.3.2/src/dfa.rs:1093:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex/1.3.2/src/dfa.rs:1096:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex/1.3.2/src/dfa.rs:1101:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex/1.3.2/src/dfa.rs:1104:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex/1.3.2/src/dfa.rs:1107:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex/1.3.2/src/dfa.rs:1117:30 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex/1.3.2/src/dfa.rs:1120:47 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex/1.3.2/src/dfa.rs:1121:30 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex/1.3.2/src/dfa.rs:1129:13 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" +regex/1.3.2/src/dfa.rs:1134:13 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" +regex/1.3.2/src/dfa.rs:1185:68 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" +regex/1.3.2/src/dfa.rs:1193:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/dfa.rs:1244:50 clippy::doc_markdown "you should put `current_state` between ticks in the documentation" +regex/1.3.2/src/dfa.rs:1338:58 clippy::doc_markdown "you should put `STATE_DEAD` between ticks in the documentation" +regex/1.3.2/src/dfa.rs:1339:9 clippy::doc_markdown "you should put `STATE_UNKNOWN` between ticks in the documentation" +regex/1.3.2/src/dfa.rs:1366:25 clippy::doc_markdown "you should put `STATE_DEAD` between ticks in the documentation" +regex/1.3.2/src/dfa.rs:1366:46 clippy::doc_markdown "you should put `STATE_UNKNOWN` between ticks in the documentation" +regex/1.3.2/src/dfa.rs:1367:41 clippy::inline_always "you have declared `#[inline(always)]` on `start_state`. This is usually a bad idea" +regex/1.3.2/src/dfa.rs:1380:14 clippy::identity_op "the operation is ineffective. Consider reducing it to `(empty_flags.start as u8)`" +regex/1.3.2/src/dfa.rs:1388:15 clippy::match_on_vec_items "indexing into a vector may panic" +regex/1.3.2/src/dfa.rs:1412:20 clippy::unused_self "unused `self` argument" +regex/1.3.2/src/dfa.rs:1438:9 clippy::unused_self "unused `self` argument" +regex/1.3.2/src/dfa.rs:1472:9 clippy::doc_markdown "you should put `StatePtr` between ticks in the documentation" +regex/1.3.2/src/dfa.rs:1490:54 clippy::cast_possible_truncation "casting `i32` to `u8` may truncate the value" +regex/1.3.2/src/dfa.rs:1490:54 clippy::cast_sign_loss "casting `i32` to `u8` may lose the sign of the value" +regex/1.3.2/src/dfa.rs:1521:20 clippy::doc_markdown "you should put `num_byte_classes` between ticks in the documentation" +regex/1.3.2/src/dfa.rs:1529:41 clippy::inline_always "you have declared `#[inline(always)]` on `byte_class`. This is usually a bad idea" +regex/1.3.2/src/dfa.rs:1537:14 clippy::doc_markdown "you should put `byte_class` between ticks in the documentation" +regex/1.3.2/src/dfa.rs:1538:41 clippy::inline_always "you have declared `#[inline(always)]` on `u8_class`. This is usually a bad idea" +regex/1.3.2/src/dfa.rs:1562:18 clippy::doc_markdown "you should put `STATE_START` between ticks in the documentation" +regex/1.3.2/src/dfa.rs:1614:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/dfa.rs:1651:38 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/dfa.rs:1700:17 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +regex/1.3.2/src/dfa.rs:1701:18 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex/1.3.2/src/dfa.rs:1705:19 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex/1.3.2/src/dfa.rs:1708:16 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +regex/1.3.2/src/dfa.rs:1709:18 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex/1.3.2/src/dfa.rs:1713:19 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex/1.3.2/src/dfa.rs:1716:18 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +regex/1.3.2/src/dfa.rs:1717:18 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex/1.3.2/src/dfa.rs:1721:19 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex/1.3.2/src/dfa.rs:1727:14 clippy::cast_lossless "casting `u8` to `u16` may become silently lossy if you later change the type" +regex/1.3.2/src/dfa.rs:1732:15 clippy::trivially_copy_pass_by_ref "this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +regex/1.3.2/src/dfa.rs:1736:22 clippy::trivially_copy_pass_by_ref "this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +regex/1.3.2/src/dfa.rs:1741:9 clippy::match_like_matches_macro "match expression looks like `matches!` macro" +regex/1.3.2/src/dfa.rs:1747:16 clippy::trivially_copy_pass_by_ref "this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +regex/1.3.2/src/dfa.rs:1751:18 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" +regex/1.3.2/src/dfa.rs:1815:38 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" +regex/1.3.2/src/dfa.rs:1821:21 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" +regex/1.3.2/src/dfa.rs:1824:5 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex/1.3.2/src/dfa.rs:1848:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +regex/1.3.2/src/dfa.rs:1850:18 clippy::cast_sign_loss "casting `i32` to `u32` may lose the sign of the value" +regex/1.3.2/src/dfa.rs:1857:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +regex/1.3.2/src/dfa.rs:1860:17 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +regex/1.3.2/src/dfa.rs:1867:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +regex/1.3.2/src/dfa.rs:1870:19 clippy::cast_possible_truncation "casting `u32` to `u8` may truncate the value" +regex/1.3.2/src/dfa.rs:1873:15 clippy::cast_possible_truncation "casting `u32` to `u8` may truncate the value" +regex/1.3.2/src/dfa.rs:1876:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +regex/1.3.2/src/dfa.rs:1882:26 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +regex/1.3.2/src/dfa.rs:1884:15 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +regex/1.3.2/src/dfa.rs:277:17 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +regex/1.3.2/src/dfa.rs:277:31 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +regex/1.3.2/src/dfa.rs:295:20 clippy::cast_possible_truncation "casting `usize` to `i32` may truncate the value on targets with 64-bit wide pointers" +regex/1.3.2/src/dfa.rs:295:20 clippy::cast_possible_wrap "casting `usize` to `i32` may wrap around the value on targets with 32-bit wide pointers" +regex/1.3.2/src/dfa.rs:299:21 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" +regex/1.3.2/src/dfa.rs:34:46 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +regex/1.3.2/src/dfa.rs:398:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +regex/1.3.2/src/dfa.rs:446:41 clippy::inline_always "you have declared `#[inline(always)]` on `forward`. This is usually a bad idea" +regex/1.3.2/src/dfa.rs:457:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/dfa.rs:459:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/dfa.rs:460:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/dfa.rs:476:41 clippy::inline_always "you have declared `#[inline(always)]` on `reverse`. This is usually a bad idea" +regex/1.3.2/src/dfa.rs:487:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/dfa.rs:489:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/dfa.rs:490:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/dfa.rs:506:41 clippy::inline_always "you have declared `#[inline(always)]` on `forward_many`. This is usually a bad idea" +regex/1.3.2/src/dfa.rs:518:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/dfa.rs:520:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/dfa.rs:554:41 clippy::inline_always "you have declared `#[inline(always)]` on `exec_at`. This is usually a bad idea" +regex/1.3.2/src/dfa.rs:555:5 clippy::too_many_lines "this function has too many lines (101/100)" +regex/1.3.2/src/dfa.rs:58:9 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/dfa.rs:667:21 clippy::similar_names "binding's name is too similar to existing binding" +regex/1.3.2/src/dfa.rs:747:41 clippy::inline_always "you have declared `#[inline(always)]` on `exec_at_reverse`. This is usually a bad idea" +regex/1.3.2/src/dfa.rs:795:21 clippy::similar_names "binding's name is too similar to existing binding" +regex/1.3.2/src/dfa.rs:848:9 clippy::doc_markdown "you should put `next_si` between ticks in the documentation" +regex/1.3.2/src/dfa.rs:852:41 clippy::inline_always "you have declared `#[inline(always)]` on `next_si`. This is usually a bad idea" +regex/1.3.2/src/dfa.rs:885:12 clippy::doc_markdown "you should put `STATE_DEAD` between ticks in the documentation" +regex/1.3.2/src/dfa.rs:889:9 clippy::doc_markdown "you should put `STATE_UNKNOWN` between ticks in the documentation" +regex/1.3.2/src/dfa.rs:897:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/dfa.rs:979:29 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex/1.3.2/src/error.rs:6:1 clippy::manual_non_exhaustive "this seems like a manual implementation of the non-exhaustive pattern" +regex/1.3.2/src/exec.rs:1000:14 clippy::doc_markdown "you should put `captures_nfa` between ticks in the documentation" +regex/1.3.2/src/exec.rs:100:1 clippy::module_name_repetitions "item name starts with its containing module's name" +regex/1.3.2/src/exec.rs:1028:5 clippy::too_many_arguments "this function has too many arguments (9/7)" +regex/1.3.2/src/exec.rs:1039:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/exec.rs:1144:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/exec.rs:1179:26 clippy::match_same_arms "this `match` has identical arm bodies" +regex/1.3.2/src/exec.rs:122:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/exec.rs:1250:41 clippy::inline_always "you have declared `#[inline(always)]` on `searcher`. This is usually a bad idea" +regex/1.3.2/src/exec.rs:1260:41 clippy::inline_always "you have declared `#[inline(always)]` on `searcher_str`. This is usually a bad idea" +regex/1.3.2/src/exec.rs:1270:17 clippy::doc_markdown "you should put `RegexSet` between ticks in the documentation" +regex/1.3.2/src/exec.rs:1280:17 clippy::doc_markdown "you should put `RegexSet` between ticks in the documentation" +regex/1.3.2/src/exec.rs:137:9 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" +regex/1.3.2/src/exec.rs:142:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/exec.rs:158:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/exec.rs:168:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/exec.rs:181:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/exec.rs:195:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/exec.rs:204:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/exec.rs:210:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/exec.rs:245:62 clippy::if_same_then_else "this `if` has identical blocks" +regex/1.3.2/src/exec.rs:251:21 clippy::if_not_else "unnecessary boolean `not` operation" +regex/1.3.2/src/exec.rs:262:60 clippy::if_same_then_else "this `if` has identical blocks" +regex/1.3.2/src/exec.rs:268:21 clippy::if_not_else "unnecessary boolean `not` operation" +regex/1.3.2/src/exec.rs:278:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/exec.rs:281:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/exec.rs:286:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +regex/1.3.2/src/exec.rs:300:30 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/exec.rs:308:17 clippy::similar_names "binding's name is too similar to existing binding" +regex/1.3.2/src/exec.rs:329:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/exec.rs:330:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/exec.rs:331:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/exec.rs:334:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/exec.rs:340:19 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/exec.rs:344:27 clippy::unused_self "unused `self` argument" +regex/1.3.2/src/exec.rs:383:41 clippy::inline_always "you have declared `#[inline(always)]` on `shortest_match_at`. This is usually a bad idea" +regex/1.3.2/src/exec.rs:388:41 clippy::inline_always "you have declared `#[inline(always)]` on `is_match_at`. This is usually a bad idea" +regex/1.3.2/src/exec.rs:393:41 clippy::inline_always "you have declared `#[inline(always)]` on `find_at`. This is usually a bad idea" +regex/1.3.2/src/exec.rs:398:41 clippy::inline_always "you have declared `#[inline(always)]` on `captures_read_at`. This is usually a bad idea" +regex/1.3.2/src/exec.rs:425:41 clippy::inline_always "you have declared `#[inline(always)]` on `shortest_match_at`. This is usually a bad idea" +regex/1.3.2/src/exec.rs:44:1 clippy::module_name_repetitions "item name starts with its containing module's name" +regex/1.3.2/src/exec.rs:473:9 clippy::doc_markdown "you should put `shortest_match(...).is_some` between ticks in the documentation" +regex/1.3.2/src/exec.rs:474:41 clippy::inline_always "you have declared `#[inline(always)]` on `is_match_at`. This is usually a bad idea" +regex/1.3.2/src/exec.rs:524:41 clippy::inline_always "you have declared `#[inline(always)]` on `find_at`. This is usually a bad idea" +regex/1.3.2/src/exec.rs:52:1 clippy::module_name_repetitions "item name starts with its containing module's name" +regex/1.3.2/src/exec.rs:686:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/exec.rs:727:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/exec.rs:767:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/exec.rs:783:41 clippy::inline_always "you have declared `#[inline(always)]` on `shortest_dfa`. This is usually a bad idea" +regex/1.3.2/src/exec.rs:791:41 clippy::inline_always "you have declared `#[inline(always)]` on `shortest_dfa_reverse_suffix`. This is usually a bad idea" +regex/1.3.2/src/exec.rs:823:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/exec.rs:868:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/exec.rs:897:31 clippy::doc_markdown "you should put `shortest_nfa(...).is_some` between ticks in the documentation" +regex/1.3.2/src/exec.rs:899:9 clippy::doc_markdown "you should put `shortest_nfa` between ticks in the documentation" +regex/1.3.2/src/exec.rs:905:14 clippy::doc_markdown "you should put `match_nfa` between ticks in the documentation" +regex/1.3.2/src/exec.rs:930:14 clippy::doc_markdown "you should put `shortest_nfa` between ticks in the documentation" +regex/1.3.2/src/exec.rs:981:14 clippy::doc_markdown "you should put `find_nfa` between ticks in the documentation" +regex/1.3.2/src/expand.rs:170:27 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +regex/1.3.2/src/expand.rs:171:5 clippy::match_like_matches_macro "match expression looks like `matches!` macro" +regex/1.3.2/src/expand.rs:22:13 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +regex/1.3.2/src/expand.rs:27:23 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +regex/1.3.2/src/expand.rs:30:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +regex/1.3.2/src/expand.rs:38:30 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +regex/1.3.2/src/expand.rs:42:21 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +regex/1.3.2/src/expand.rs:50:1 clippy::module_name_repetitions "item name starts with its containing module's name" +regex/1.3.2/src/expand.rs:69:23 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +regex/1.3.2/src/expand.rs:80:28 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +regex/1.3.2/src/expand.rs:84:21 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +regex/1.3.2/src/expand.rs:8:1 clippy::module_name_repetitions "item name starts with its containing module's name" +regex/1.3.2/src/input.rs:142:1 clippy::module_name_repetitions "item name ends with its containing module's name" +regex/1.3.2/src/input.rs:146:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/input.rs:15:1 clippy::module_name_repetitions "item name starts with its containing module's name" +regex/1.3.2/src/input.rs:165:31 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/input.rs:178:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/input.rs:228:1 clippy::module_name_repetitions "item name ends with its containing module's name" +regex/1.3.2/src/input.rs:236:21 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/input.rs:236:33 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/input.rs:24:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/input.rs:271:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/input.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/input.rs:362:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/input.rs:370:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/input.rs:371:42 clippy::redundant_closure_for_method_calls "redundant closure found" +regex/1.3.2/src/input.rs:37:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/input.rs:388:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/input.rs:42:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/input.rs:47:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/input.rs:53:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/input.rs:58:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/input.rs:63:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/lib.rs:1:null clippy::cargo_common_metadata "package `regex` is missing `package.keywords` metadata" +regex/1.3.2/src/literal/imp.rs:101:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/literal/imp.rs:114:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/literal/imp.rs:127:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/literal/imp.rs:139:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/literal/imp.rs:144:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/literal/imp.rs:149:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/literal/imp.rs:154:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/literal/imp.rs:155:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/literal/imp.rs:160:30 clippy::match_same_arms "this `match` has identical arm bodies" +regex/1.3.2/src/literal/imp.rs:167:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/literal/imp.rs:168:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/literal/imp.rs:211:20 clippy::redundant_else "redundant else block" +regex/1.3.2/src/literal/imp.rs:276:50 clippy::match_same_arms "this `match` has identical arm bodies" +regex/1.3.2/src/literal/imp.rs:342:41 clippy::inline_always "you have declared `#[inline(always)]` on `find`. This is usually a bad idea" +regex/1.3.2/src/literal/imp.rs:435:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/literal/imp.rs:436:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/literal/imp.rs:437:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/literal/imp.rs:438:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/literal/imp.rs:439:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/literal/imp.rs:440:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/literal/imp.rs:455:41 clippy::inline_always "you have declared `#[inline(always)]` on `find`. This is usually a bad idea" +regex/1.3.2/src/literal/imp.rs:46:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/literal/imp.rs:481:41 clippy::inline_always "you have declared `#[inline(always)]` on `is_suffix`. This is usually a bad idea" +regex/1.3.2/src/literal/imp.rs:51:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/literal/imp.rs:579:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/literal/imp.rs:57:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/literal/imp.rs:580:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/literal/imp.rs:583:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/literal/imp.rs:602:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +regex/1.3.2/src/literal/imp.rs:622:24 clippy::redundant_else "redundant else block" +regex/1.3.2/src/literal/imp.rs:62:18 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +regex/1.3.2/src/literal/imp.rs:637:24 clippy::redundant_else "redundant else block" +regex/1.3.2/src/literal/imp.rs:648:9 clippy::needless_return "unneeded `return` statement" +regex/1.3.2/src/literal/imp.rs:651:44 clippy::doc_markdown "you should put `BoyerMooreSearch` between ticks in the documentation" +regex/1.3.2/src/literal/imp.rs:65:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/literal/imp.rs:68:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/literal/imp.rs:783:32 clippy::redundant_else "redundant else block" +regex/1.3.2/src/literal/imp.rs:786:42 clippy::manual_saturating_arithmetic "manual saturating arithmetic" +regex/1.3.2/src/literal/imp.rs:78:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/literal/imp.rs:84:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/literal/imp.rs:850:20 clippy::unreadable_literal "long literal lacking separators" +regex/1.3.2/src/literal/imp.rs:85:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/pikevm.rs:103:15 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/pikevm.rs:103:52 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/pikevm.rs:114:5 clippy::too_many_arguments "this function has too many arguments (8/7)" +regex/1.3.2/src/pikevm.rs:117:13 clippy::similar_names "binding's name is too similar to existing binding" +regex/1.3.2/src/pikevm.rs:124:17 clippy::similar_names "binding's name is too similar to existing binding" +regex/1.3.2/src/pikevm.rs:220:9 clippy::doc_markdown "you should put `thread_caps` between ticks in the documentation" +regex/1.3.2/src/pikevm.rs:222:16 clippy::doc_markdown "you should put `at_next` between ticks in the documentation" +regex/1.3.2/src/pikevm.rs:223:9 clippy::doc_markdown "you should put `at_next` between ticks in the documentation" +regex/1.3.2/src/pikevm.rs:224:5 clippy::too_many_arguments "this function has too many arguments (8/7)" +regex/1.3.2/src/pikevm.rs:234:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/pikevm.rs:303:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/pikevm.rs:331:29 clippy::mut_mut "this expression mutably borrows a mutable reference. Consider reborrowing" +regex/1.3.2/src/pikevm.rs:88:5 clippy::too_many_arguments "this function has too many arguments (8/7)" +regex/1.3.2/src/prog.rs:102:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/prog.rs:113:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/prog.rs:120:9 clippy::match_like_matches_macro "match expression looks like `matches!` macro" +regex/1.3.2/src/prog.rs:128:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/prog.rs:134:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/prog.rs:141:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/prog.rs:147:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/prog.rs:164:41 clippy::inline_always "you have declared `#[inline(always)]` on `deref`. This is usually a bad idea" +regex/1.3.2/src/prog.rs:172:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex/1.3.2/src/prog.rs:18:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +regex/1.3.2/src/prog.rs:236:13 clippy::write_with_newline "using `write!()` with a format string that ends in a single newline" +regex/1.3.2/src/prog.rs:300:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/prog.rs:301:9 clippy::match_like_matches_macro "match expression looks like `matches!` macro" +regex/1.3.2/src/prog.rs:382:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/prog.rs:409:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/prog.rs:80:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/prog.rs:80:5 clippy::new_without_default "you should consider adding a `Default` implementation for `prog::Program`" +regex/1.3.2/src/re_builder.rs:267:17 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +regex/1.3.2/src/re_builder.rs:267:17 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +regex/1.3.2/src/re_builder.rs:4:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +regex/1.3.2/src/re_builder.rs:57:17 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_builder.rs:57:17 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_builder.rs:68:17 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +regex/1.3.2/src/re_builder.rs:68:17 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +regex/1.3.2/src/re_bytes.rs:1017:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +regex/1.3.2/src/re_bytes.rs:1039:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +regex/1.3.2/src/re_bytes.rs:1093:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +regex/1.3.2/src/re_bytes.rs:1118:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +regex/1.3.2/src/re_bytes.rs:1133:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +regex/1.3.2/src/re_bytes.rs:118:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +regex/1.3.2/src/re_bytes.rs:256:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/re_bytes.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_bytes.rs:35:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_bytes.rs:42:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_bytes.rs:48:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_bytes.rs:558:29 clippy::doc_markdown "you should put `shortest_match` between ticks in the documentation" +regex/1.3.2/src/re_bytes.rs:55:33 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/re_bytes.rs:55:47 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/re_bytes.rs:572:29 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" +regex/1.3.2/src/re_bytes.rs:720:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/re_bytes.rs:817:5 clippy::doc_markdown "you should put `CaptureLocations` between ticks in the documentation" +regex/1.3.2/src/re_bytes.rs:843:1 clippy::len_without_is_empty "item `re_bytes::CaptureLocations` has a public `len` method but no corresponding `is_empty` method" +regex/1.3.2/src/re_bytes.rs:849:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_bytes.rs:858:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_bytes.rs:869:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_bytes.rs:891:1 clippy::len_without_is_empty "item `re_bytes::Captures<'t>` has a public `len` method but no corresponding `is_empty` method" +regex/1.3.2/src/re_bytes.rs:911:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_bytes.rs:917:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_bytes.rs:926:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_bytes.rs:955:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_set.rs:179:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/re_set.rs:179:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/re_set.rs:251:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_set.rs:251:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_set.rs:263:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_set.rs:263:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_set.rs:268:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_set.rs:268:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_set.rs:277:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_set.rs:277:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_set.rs:94:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +regex/1.3.2/src/re_set.rs:94:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +regex/1.3.2/src/re_trait.rs:136:29 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/re_unicode.rs:1019:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +regex/1.3.2/src/re_unicode.rs:1041:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +regex/1.3.2/src/re_unicode.rs:1088:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/re_unicode.rs:1135:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +regex/1.3.2/src/re_unicode.rs:1160:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +regex/1.3.2/src/re_unicode.rs:174:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +regex/1.3.2/src/re_unicode.rs:21:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +regex/1.3.2/src/re_unicode.rs:313:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/re_unicode.rs:38:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_unicode.rs:44:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_unicode.rs:51:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_unicode.rs:57:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_unicode.rs:617:29 clippy::doc_markdown "you should put `shortest_match` between ticks in the documentation" +regex/1.3.2/src/re_unicode.rs:631:29 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" +regex/1.3.2/src/re_unicode.rs:64:33 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/re_unicode.rs:64:47 clippy::redundant_field_names "redundant field names in struct initialization" +regex/1.3.2/src/re_unicode.rs:834:5 clippy::doc_markdown "you should put `CaptureLocations` between ticks in the documentation" +regex/1.3.2/src/re_unicode.rs:860:1 clippy::len_without_is_empty "item `re_unicode::CaptureLocations` has a public `len` method but no corresponding `is_empty` method" +regex/1.3.2/src/re_unicode.rs:866:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_unicode.rs:875:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_unicode.rs:886:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_unicode.rs:908:1 clippy::len_without_is_empty "item `re_unicode::Captures<'t>` has a public `len` method but no corresponding `is_empty` method" +regex/1.3.2/src/re_unicode.rs:928:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_unicode.rs:934:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_unicode.rs:943:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/re_unicode.rs:972:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex/1.3.2/src/sparse.rs:10:37 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +regex/1.3.2/src/sparse.rs:15:1 clippy::module_name_repetitions "item name starts with its containing module's name" +regex/1.3.2/src/utf8.rs:100:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex/1.3.2/src/utf8.rs:103:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex/1.3.2/src/utf8.rs:106:22 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +regex/1.3.2/src/utf8.rs:107:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +regex/1.3.2/src/utf8.rs:108:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +regex/1.3.2/src/utf8.rs:109:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +regex/1.3.2/src/utf8.rs:111:27 clippy::unreadable_literal "long literal lacking separators" +regex/1.3.2/src/utf8.rs:121:1 clippy::module_name_repetitions "item name ends with its containing module's name" +regex/1.3.2/src/utf8.rs:143:24 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex/1.3.2/src/utf8.rs:143:9 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex/1.3.2/src/utf8.rs:23:1 clippy::module_name_repetitions "item name ends with its containing module's name" +regex/1.3.2/src/utf8.rs:30:20 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex/1.3.2/src/utf8.rs:51:1 clippy::module_name_repetitions "item name ends with its containing module's name" +regex/1.3.2/src/utf8.rs:58:23 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex/1.3.2/src/utf8.rs:58:9 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex/1.3.2/src/utf8.rs:63:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex/1.3.2/src/utf8.rs:66:22 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +regex/1.3.2/src/utf8.rs:66:54 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +regex/1.3.2/src/utf8.rs:77:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex/1.3.2/src/utf8.rs:80:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex/1.3.2/src/utf8.rs:83:22 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +regex/1.3.2/src/utf8.rs:84:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +regex/1.3.2/src/utf8.rs:85:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +regex/1.3.2/src/utf8.rs:92:23 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex/1.3.2/src/utf8.rs:92:9 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex/1.3.2/src/utf8.rs:97:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +ripgrep/12.1.1//home/matthias/.rustup/toolchains/nightly-2020-12-20-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std/src/macros.rs:14:27 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep/12.1.1//home/matthias/.rustup/toolchains/nightly-2020-12-20-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std/src/macros.rs:14:27 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep/12.1.1//home/matthias/.rustup/toolchains/nightly-2020-12-20-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std/src/macros.rs:14:27 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep/12.1.1//home/matthias/.rustup/toolchains/nightly-2020-12-20-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std/src/macros.rs:14:27 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep/12.1.1/build.rs:133:19 clippy::option_as_ref_deref "called `.as_ref().map(|x| &**x)` on an Option value. This can be done more directly by calling `githash.as_deref()` instead" +ripgrep/12.1.1/build.rs:18:18 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +ripgrep/12.1.1/build.rs:225:14 clippy::redundant_closure_for_method_calls "redundant closure found" +ripgrep/12.1.1/build.rs:92:19 clippy::option_as_ref_deref "called `.as_ref().map(|x| &**x)` on an Option value. This can be done more directly by calling `githash.as_deref()` instead" +ripgrep/12.1.1/crates/core/app.rs:1408:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep/12.1.1/crates/core/app.rs:1408:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep/12.1.1/crates/core/app.rs:1409:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep/12.1.1/crates/core/app.rs:1409:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep/12.1.1/crates/core/app.rs:152:32 clippy::doc_markdown "you should put `clap::Arg` between ticks in the documentation" +ripgrep/12.1.1/crates/core/app.rs:152:32 clippy::doc_markdown "you should put `clap::Arg` between ticks in the documentation" +ripgrep/12.1.1/crates/core/app.rs:156:39 clippy::doc_markdown "you should put `clap::Arg` between ticks in the documentation" +ripgrep/12.1.1/crates/core/app.rs:156:39 clippy::doc_markdown "you should put `clap::Arg` between ticks in the documentation" +ripgrep/12.1.1/crates/core/app.rs:156:5 clippy::doc_markdown "you should put `RGArg` between ticks in the documentation" +ripgrep/12.1.1/crates/core/app.rs:156:5 clippy::doc_markdown "you should put `RGArg` between ticks in the documentation" +ripgrep/12.1.1/crates/core/app.rs:1668:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep/12.1.1/crates/core/app.rs:1668:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep/12.1.1/crates/core/app.rs:1669:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep/12.1.1/crates/core/app.rs:1669:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep/12.1.1/crates/core/app.rs:1821:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep/12.1.1/crates/core/app.rs:1821:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep/12.1.1/crates/core/app.rs:1822:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep/12.1.1/crates/core/app.rs:1822:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep/12.1.1/crates/core/app.rs:2999:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep/12.1.1/crates/core/app.rs:2999:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep/12.1.1/crates/core/app.rs:3000:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep/12.1.1/crates/core/app.rs:3000:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep/12.1.1/crates/core/app.rs:367:54 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep/12.1.1/crates/core/app.rs:367:54 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep/12.1.1/crates/core/app.rs:414:59 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep/12.1.1/crates/core/app.rs:414:59 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep/12.1.1/crates/core/app.rs:417:57 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep/12.1.1/crates/core/app.rs:417:57 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep/12.1.1/crates/core/app.rs:417:57 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep/12.1.1/crates/core/app.rs:417:57 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep/12.1.1/crates/core/app.rs:75:9 clippy::doc_markdown "you should put `RIPGREP_BUILD_GIT_HASH` between ticks in the documentation" +ripgrep/12.1.1/crates/core/app.rs:75:9 clippy::doc_markdown "you should put `RIPGREP_BUILD_GIT_HASH` between ticks in the documentation" +ripgrep/12.1.1/crates/core/app.rs:87:5 clippy::if_not_else "unnecessary boolean `not` operation" +ripgrep/12.1.1/crates/core/app.rs:87:5 clippy::if_not_else "unnecessary boolean `not` operation" +ripgrep/12.1.1/crates/core/args.rs:1143:22 clippy::unused_self "unused `self` argument" +ripgrep/12.1.1/crates/core/args.rs:11:1 clippy::single_component_path_imports "this import is redundant" +ripgrep/12.1.1/crates/core/args.rs:1209:74 clippy::if_same_then_else "this `if` has identical blocks" +ripgrep/12.1.1/crates/core/args.rs:1209:74 clippy::if_same_then_else "this `if` has identical blocks" +ripgrep/12.1.1/crates/core/args.rs:1282:13 clippy::similar_names "binding's name is too similar to existing binding" +ripgrep/12.1.1/crates/core/args.rs:1430:22 clippy::unused_self "unused `self` argument" +ripgrep/12.1.1/crates/core/args.rs:1438:21 clippy::doc_markdown "you should put `OsStr` between ticks in the documentation" +ripgrep/12.1.1/crates/core/args.rs:1520:44 clippy::redundant_closure_for_method_calls "redundant closure found" +ripgrep/12.1.1/crates/core/args.rs:1524:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +ripgrep/12.1.1/crates/core/args.rs:1635:14 clippy::doc_markdown "you should put `values_of_lossy` between ticks in the documentation" +ripgrep/12.1.1/crates/core/args.rs:1693:41 clippy::redundant_closure_for_method_calls "redundant closure found" +ripgrep/12.1.1/crates/core/args.rs:1770:17 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +ripgrep/12.1.1/crates/core/args.rs:287:13 clippy::similar_names "binding's name is too similar to existing binding" +ripgrep/12.1.1/crates/core/args.rs:33:1 clippy::single_component_path_imports "this import is redundant" +ripgrep/12.1.1/crates/core/args.rs:34:1 clippy::single_component_path_imports "this import is redundant" +ripgrep/12.1.1/crates/core/args.rs:35:1 clippy::single_component_path_imports "this import is redundant" +ripgrep/12.1.1/crates/core/args.rs:410:14 clippy::trivially_copy_pass_by_ref "this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +ripgrep/12.1.1/crates/core/args.rs:475:18 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep/12.1.1/crates/core/args.rs:512:19 clippy::doc_markdown "you should put `ArgMatches` between ticks in the documentation" +ripgrep/12.1.1/crates/core/args.rs:549:16 clippy::wrong_self_convention "methods called `to_*` usually take self by reference; consider choosing a less ambiguous name" +ripgrep/12.1.1/crates/core/args.rs:76:18 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +ripgrep/12.1.1/crates/core/args.rs:77:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +ripgrep/12.1.1/crates/core/args.rs:923:42 clippy::doc_markdown "you should put `BinaryDetection::quit` between ticks in the documentation" +ripgrep/12.1.1/crates/core/config.rs:13:1 clippy::single_component_path_imports "this import is redundant" +ripgrep/12.1.1/crates/core/config.rs:58:6 clippy::type_complexity "very complex type used. Consider factoring parts into `type` definitions" +ripgrep/12.1.1/crates/core/config.rs:79:6 clippy::type_complexity "very complex type used. Consider factoring parts into `type` definitions" +ripgrep/12.1.1/crates/core/logger.rs:11:30 clippy::doc_markdown "you should put `max_level` between ticks in the documentation" +ripgrep/12.1.1/crates/core/logger.rs:15:16 clippy::redundant_static_lifetimes "constants have by default a `'static` lifetime" +ripgrep/12.1.1/crates/core/main.rs:55:19 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +ripgrep/12.1.1/crates/core/main.rs:56:9 clippy::enum_glob_use "usage of wildcard import for enum variants" +ripgrep/12.1.1/crates/core/messages.rs:46:1 clippy::module_name_repetitions "item name ends with its containing module's name" +ripgrep/12.1.1/crates/core/messages.rs:51:1 clippy::module_name_repetitions "item name ends with its containing module's name" +ripgrep/12.1.1/crates/core/messages.rs:62:1 clippy::module_name_repetitions "item name ends with its containing module's name" +ripgrep/12.1.1/crates/core/path_printer.rs:27:1 clippy::module_name_repetitions "item name starts with its containing module's name" +ripgrep/12.1.1/crates/core/path_printer.rs:89:9 clippy::if_not_else "unnecessary boolean `not` operation" +ripgrep/12.1.1/crates/core/search.rs:185:1 clippy::module_name_repetitions "item name starts with its containing module's name" +ripgrep/12.1.1/crates/core/search.rs:292:9 clippy::write_with_newline "using `write!()` with a format string that ends in a single newline" +ripgrep/12.1.1/crates/core/search.rs:311:1 clippy::module_name_repetitions "item name starts with its containing module's name" +ripgrep/12.1.1/crates/core/search.rs:377:12 clippy::nonminimal_bool "this boolean expression can be simplified" +ripgrep/12.1.1/crates/core/search.rs:423:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +ripgrep/12.1.1/crates/core/search.rs:447:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +ripgrep/12.1.1/crates/core/search.rs:472:24 clippy::map_clone "you are using an explicit closure for cloning elements" +ripgrep/12.1.1/crates/core/search.rs:472:41 clippy::redundant_closure_for_method_calls "redundant closure found" +ripgrep/12.1.1/crates/core/search.rs:480:24 clippy::map_clone "you are using an explicit closure for cloning elements" +ripgrep/12.1.1/crates/core/search.rs:480:41 clippy::redundant_closure_for_method_calls "redundant closure found" +ripgrep/12.1.1/crates/core/search.rs:49:1 clippy::module_name_repetitions "item name starts with its containing module's name" +ripgrep/12.1.1/crates/core/search.rs:509:24 clippy::map_clone "you are using an explicit closure for cloning elements" +ripgrep/12.1.1/crates/core/search.rs:509:41 clippy::redundant_closure_for_method_calls "redundant closure found" +ripgrep/12.1.1/crates/core/search.rs:517:24 clippy::map_clone "you are using an explicit closure for cloning elements" +ripgrep/12.1.1/crates/core/search.rs:517:41 clippy::redundant_closure_for_method_calls "redundant closure found" +ripgrep/12.1.1/crates/core/search.rs:533:36 clippy::cast_lossless "casting `u32` to `f64` may become silently lossy if you later change the type" +ripgrep/12.1.1/crates/core/search.rs:533:5 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +ripgrep/12.1.1/crates/core/subject.rs:20:1 clippy::module_name_repetitions "item name starts with its containing module's name" +ripgrep/12.1.1/crates/core/subject.rs:4:1 clippy::single_component_path_imports "this import is redundant" +syn/1.0.54/build.rs:1:null clippy::cargo_common_metadata "package `syn` is missing `package.keywords` metadata" +syn/1.0.54/build.rs:1:null clippy::multiple_crate_versions "could not read cargo metadata: failed to run `cargo metadata`: Downloading crates ...\n Downloaded dtoa v0.4.7\n Downloaded anyhow v1.0.37\n Downloaded syn-test-suite v0.0.0\nerror: failed to verify the checksum of `syn-test-suite v0.0.0`" +syn/1.0.54/src/lib.rs:1:null clippy::cargo_common_metadata "package `syn` is missing `package.keywords` metadata" +syn/1.0.54/src/lib.rs:1:null clippy::multiple_crate_versions "could not read cargo metadata: failed to run `cargo metadata`: Downloading crates ...\n Downloaded syn-test-suite v0.0.0\nerror: failed to verify the checksum of `syn-test-suite v0.0.0`" +syn/1.0.54/src/lit.rs:1397:40 clippy::redundant_else "redundant else block" +syn/1.0.54/src/lit.rs:1405:28 clippy::redundant_else "redundant else block" +syn/1.0.54/src/lit.rs:1485:32 clippy::redundant_else "redundant else block" +unicode-xid/0.2.1/src/lib.rs:1:null clippy::cargo_common_metadata "package `unicode-xid` is missing `package.categories` metadata" +unicode-xid/0.2.1/src/lib.rs:57:64 clippy::doc_markdown "you should put `XID_Start` between ticks in the documentation" +unicode-xid/0.2.1/src/lib.rs:60:10 clippy::doc_markdown "you should put `XID_Start` between ticks in the documentation" +unicode-xid/0.2.1/src/lib.rs:62:27 clippy::doc_markdown "you should put `ID_Start` between ticks in the documentation" +unicode-xid/0.2.1/src/lib.rs:62:67 clippy::doc_markdown "you should put `NFKx` between ticks in the documentation" +unicode-xid/0.2.1/src/lib.rs:63:21 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" +unicode-xid/0.2.1/src/lib.rs:65:61 clippy::doc_markdown "you should put `XID_Continue` between ticks in the documentation" +unicode-xid/0.2.1/src/lib.rs:68:10 clippy::doc_markdown "you should put `XID_Continue` between ticks in the documentation" +unicode-xid/0.2.1/src/lib.rs:70:28 clippy::doc_markdown "you should put `ID_Continue` between ticks in the documentation" +unicode-xid/0.2.1/src/lib.rs:70:72 clippy::doc_markdown "you should put `NFKx` between ticks in the documentation" +unicode-xid/0.2.1/src/lib.rs:71:24 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" +xsv/0.13.0/src/cmd/cat.rs:101:34 clippy::redundant_closure_for_method_calls "redundant closure found" +xsv/0.13.0/src/cmd/cat.rs:42:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +xsv/0.13.0/src/cmd/cat.rs:53:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/cat.rs:7:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv/0.13.0/src/cmd/count.rs:32:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/count.rs:38:9 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +xsv/0.13.0/src/cmd/count.rs:42:33 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +xsv/0.13.0/src/cmd/count.rs:50:5 clippy::unit_arg "passing a unit value to a function" +xsv/0.13.0/src/cmd/count.rs:7:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv/0.13.0/src/cmd/fixlengths.rs:45:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/fixlengths.rs:50:18 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +xsv/0.13.0/src/cmd/fixlengths.rs:62:30 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +xsv/0.13.0/src/cmd/fixlengths.rs:9:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv/0.13.0/src/cmd/flatten.rs:10:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv/0.13.0/src/cmd/flatten.rs:51:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/fmt.rs:50:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/fmt.rs:55:13 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/fmt.rs:7:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv/0.13.0/src/cmd/frequency.rs:148:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +xsv/0.13.0/src/cmd/frequency.rs:149:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +xsv/0.13.0/src/cmd/frequency.rs:15:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv/0.13.0/src/cmd/frequency.rs:169:13 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/frequency.rs:176:17 clippy::if_not_else "unnecessary boolean `not` operation" +xsv/0.13.0/src/cmd/frequency.rs:178:24 clippy::collapsible_if "this `else { if .. }` block can be collapsed" +xsv/0.13.0/src/cmd/frequency.rs:77:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/frequency.rs:93:31 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" +xsv/0.13.0/src/cmd/headers.rs:43:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/headers.rs:49:17 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" +xsv/0.13.0/src/cmd/headers.rs:9:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv/0.13.0/src/cmd/index.rs:11:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv/0.13.0/src/cmd/index.rs:45:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/input.rs:42:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/input.rs:47:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/input.rs:7:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv/0.13.0/src/cmd/join.rs:17:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv/0.13.0/src/cmd/join.rs:194:29 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/join.rs:224:22 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/join.rs:293:14 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/join.rs:293:20 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/join.rs:297:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv/0.13.0/src/cmd/join.rs:298:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv/0.13.0/src/cmd/join.rs:299:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv/0.13.0/src/cmd/join.rs:300:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv/0.13.0/src/cmd/join.rs:308:9 clippy::unused_self "unused `self` argument" +xsv/0.13.0/src/cmd/join.rs:342:38 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +xsv/0.13.0/src/cmd/join.rs:342:46 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +xsv/0.13.0/src/cmd/join.rs:347:9 clippy::if_not_else "unnecessary boolean `not` operation" +xsv/0.13.0/src/cmd/join.rs:372:44 clippy::redundant_closure_for_method_calls "redundant closure found" +xsv/0.13.0/src/cmd/join.rs:375:33 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/join.rs:392:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv/0.13.0/src/cmd/join.rs:403:29 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" +xsv/0.13.0/src/cmd/join.rs:426:13 clippy::if_not_else "unnecessary boolean `not` operation" +xsv/0.13.0/src/cmd/join.rs:77:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +xsv/0.13.0/src/cmd/join.rs:94:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/partition.rs:105:22 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/partition.rs:139:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv/0.13.0/src/cmd/partition.rs:15:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv/0.13.0/src/cmd/partition.rs:169:9 clippy::if_not_else "unnecessary boolean `not` operation" +xsv/0.13.0/src/cmd/partition.rs:56:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/partition.rs:77:9 clippy::unused_self "unused `self` argument" +xsv/0.13.0/src/cmd/sample.rs:105:44 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +xsv/0.13.0/src/cmd/sample.rs:115:21 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +xsv/0.13.0/src/cmd/sample.rs:11:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv/0.13.0/src/cmd/sample.rs:51:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/sample.rs:58:19 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +xsv/0.13.0/src/cmd/sample.rs:69:9 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +xsv/0.13.0/src/cmd/sample.rs:75:16 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" +xsv/0.13.0/src/cmd/sample.rs:91:42 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +xsv/0.13.0/src/cmd/sample.rs:92:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +xsv/0.13.0/src/cmd/search.rs:51:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/search.rs:9:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv/0.13.0/src/cmd/select.rs:60:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/select.rs:8:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv/0.13.0/src/cmd/slice.rs:57:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/slice.rs:9:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv/0.13.0/src/cmd/sort.rs:11:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv/0.13.0/src/cmd/sort.rs:138:47 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +xsv/0.13.0/src/cmd/sort.rs:139:51 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +xsv/0.13.0/src/cmd/sort.rs:48:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/sort.rs:91:14 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" +xsv/0.13.0/src/cmd/split.rs:14:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv/0.13.0/src/cmd/split.rs:61:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/split.rs:94:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +xsv/0.13.0/src/cmd/split.rs:96:14 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +xsv/0.13.0/src/cmd/split.rs:99:13 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +xsv/0.13.0/src/cmd/stats.rs:110:36 clippy::redundant_closure_for_method_calls "redundant closure found" +xsv/0.13.0/src/cmd/stats.rs:127:14 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +xsv/0.13.0/src/cmd/stats.rs:138:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +xsv/0.13.0/src/cmd/stats.rs:139:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +xsv/0.13.0/src/cmd/stats.rs:162:25 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" +xsv/0.13.0/src/cmd/stats.rs:22:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv/0.13.0/src/cmd/stats.rs:231:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +xsv/0.13.0/src/cmd/stats.rs:262:35 clippy::default_trait_access "calling `cmd::stats::TypedSum::default()` is more clear than this expression" +xsv/0.13.0/src/cmd/stats.rs:263:40 clippy::default_trait_access "calling `cmd::stats::TypedMinMax::default()` is more clear than this expression" +xsv/0.13.0/src/cmd/stats.rs:264:39 clippy::default_trait_access "calling `stats::OnlineStats::default()` is more clear than this expression" +xsv/0.13.0/src/cmd/stats.rs:265:58 clippy::default_trait_access "calling `stats::Unsorted::default()` is more clear than this expression" +xsv/0.13.0/src/cmd/stats.rs:266:41 clippy::default_trait_access "calling `stats::Unsorted::default()` is more clear than this expression" +xsv/0.13.0/src/cmd/stats.rs:268:18 clippy::default_trait_access "calling `cmd::stats::FieldType::default()` is more clear than this expression" +xsv/0.13.0/src/cmd/stats.rs:269:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv/0.13.0/src/cmd/stats.rs:270:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv/0.13.0/src/cmd/stats.rs:271:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv/0.13.0/src/cmd/stats.rs:272:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv/0.13.0/src/cmd/stats.rs:273:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv/0.13.0/src/cmd/stats.rs:274:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv/0.13.0/src/cmd/stats.rs:283:9 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" +xsv/0.13.0/src/cmd/stats.rs:284:9 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" +xsv/0.13.0/src/cmd/stats.rs:285:9 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" +xsv/0.13.0/src/cmd/stats.rs:290:21 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" +xsv/0.13.0/src/cmd/stats.rs:293:25 clippy::match_same_arms "this `match` has identical arm bodies" +xsv/0.13.0/src/cmd/stats.rs:297:25 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" +xsv/0.13.0/src/cmd/stats.rs:301:21 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" +xsv/0.13.0/src/cmd/stats.rs:302:21 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" +xsv/0.13.0/src/cmd/stats.rs:308:18 clippy::wrong_self_convention "methods called `to_*` usually take self by reference; consider choosing a less ambiguous name" +xsv/0.13.0/src/cmd/stats.rs:318:9 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +xsv/0.13.0/src/cmd/stats.rs:322:45 clippy::redundant_closure_for_method_calls "redundant closure found" +xsv/0.13.0/src/cmd/stats.rs:322:9 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +xsv/0.13.0/src/cmd/stats.rs:327:9 clippy::if_not_else "unnecessary boolean `not` operation" +xsv/0.13.0/src/cmd/stats.rs:330:13 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" +xsv/0.13.0/src/cmd/stats.rs:338:45 clippy::redundant_closure_for_method_calls "redundant closure found" +xsv/0.13.0/src/cmd/stats.rs:402:16 clippy::redundant_pattern_matching "redundant pattern matching, consider using `is_ok()`" +xsv/0.13.0/src/cmd/stats.rs:403:16 clippy::redundant_pattern_matching "redundant pattern matching, consider using `is_ok()`" +xsv/0.13.0/src/cmd/stats.rs:407:18 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +xsv/0.13.0/src/cmd/stats.rs:411:16 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +xsv/0.13.0/src/cmd/stats.rs:427:56 clippy::match_same_arms "this `match` has identical arm bodies" +xsv/0.13.0/src/cmd/stats.rs:429:56 clippy::match_same_arms "this `match` has identical arm bodies" +xsv/0.13.0/src/cmd/stats.rs:430:60 clippy::match_same_arms "this `match` has identical arm bodies" +xsv/0.13.0/src/cmd/stats.rs:430:60 clippy::match_same_arms "this `match` has identical arm bodies" +xsv/0.13.0/src/cmd/stats.rs:454:5 clippy::doc_markdown "you should put `TypedSum` between ticks in the documentation" +xsv/0.13.0/src/cmd/stats.rs:473:43 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +xsv/0.13.0/src/cmd/stats.rs:504:56 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +xsv/0.13.0/src/cmd/stats.rs:505:51 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +xsv/0.13.0/src/cmd/stats.rs:511:5 clippy::doc_markdown "you should put `TypedMinMax` between ticks in the documentation" +xsv/0.13.0/src/cmd/stats.rs:536:35 clippy::cast_possible_truncation "casting `f64` to `i64` may truncate the value" +xsv/0.13.0/src/cmd/stats.rs:544:33 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +xsv/0.13.0/src/cmd/stats.rs:592:22 clippy::default_trait_access "calling `stats::MinMax::default()` is more clear than this expression" +xsv/0.13.0/src/cmd/stats.rs:593:22 clippy::default_trait_access "calling `stats::MinMax::default()` is more clear than this expression" +xsv/0.13.0/src/cmd/stats.rs:594:23 clippy::default_trait_access "calling `stats::MinMax::default()` is more clear than this expression" +xsv/0.13.0/src/cmd/stats.rs:595:21 clippy::default_trait_access "calling `stats::MinMax::default()` is more clear than this expression" +xsv/0.13.0/src/cmd/stats.rs:71:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +xsv/0.13.0/src/cmd/stats.rs:86:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/table.rs:10:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv/0.13.0/src/cmd/table.rs:50:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/cmd/table.rs:54:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/config.rs:113:43 clippy::or_fun_call "use of `unwrap_or` followed by a function call" +xsv/0.13.0/src/config.rs:58:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +xsv/0.13.0/src/config.rs:77:28 clippy::explicit_deref_methods "explicit deref method call" +xsv/0.13.0/src/config.rs:90:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv/0.13.0/src/index.rs:31:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv/0.13.0/src/main.rs:164:49 clippy::redundant_clone "redundant clone" +xsv/0.13.0/src/main.rs:1:null clippy::cargo_common_metadata "package `xsv` is missing `package.categories` metadata" +xsv/0.13.0/src/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `rand_core`: 0.3.1, 0.4.2" +xsv/0.13.0/src/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `rand`: 0.3.23, 0.4.6" +xsv/0.13.0/src/main.rs:75:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv/0.13.0/src/select.rs:13:1 clippy::module_name_repetitions "item name starts with its containing module's name" +xsv/0.13.0/src/select.rs:154:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +xsv/0.13.0/src/select.rs:250:33 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/select.rs:250:43 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/select.rs:255:39 clippy::range_plus_one "an inclusive range would be more readable" +xsv/0.13.0/src/select.rs:280:20 clippy::len_zero "length comparison to zero" +xsv/0.13.0/src/select.rs:29:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv/0.13.0/src/select.rs:360:62 clippy::trivially_copy_pass_by_ref "this argument (8 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +xsv/0.13.0/src/select.rs:360:9 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Option`" +xsv/0.13.0/src/select.rs:375:9 clippy::stable_sort_primitive "used sort instead of sort_unstable to sort primitive type `usize`" +xsv/0.13.0/src/select.rs:379:18 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" +xsv/0.13.0/src/select.rs:416:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +xsv/0.13.0/src/select.rs:419:9 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Option`" +xsv/0.13.0/src/select.rs:420:27 clippy::option_option "consider using `Option` instead of `Option>` or a custom enum if you need to distinguish all 3 cases" +xsv/0.13.0/src/select.rs:99:17 clippy::similar_names "binding's name is too similar to existing binding" +xsv/0.13.0/src/util.rs:150:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +xsv/0.13.0/src/util.rs:37:33 clippy::map_clone "you are using an explicit closure for copying elements" +xsv/0.13.0/src/util.rs:90:1 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" + + + + +Stats + +clippy::clone_on_copy 1 +clippy::collapsible_if 1 +clippy::comparison_chain 1 +clippy::expect_fun_call 1 +clippy::explicit_deref_methods 1 +clippy::from_iter_instead_of_collect 1 +clippy::from_over_into 1 +clippy::int_plus_one 1 +clippy::manual_saturating_arithmetic 1 +clippy::mem_replace_with_default 1 +clippy::nonminimal_bool 1 +clippy::or_fun_call 1 +clippy::precedence 1 +clippy::pub_enum_variant_names 1 +clippy::redundant_clone 1 +clippy::same_item_push 1 +clippy::should_implement_trait 1 +clippy::stable_sort_primitive 1 +clippy::unit_arg 1 +clippy::unnecessary_lazy_evaluations 1 +clippy::used_underscore_binding 1 +clippy::verbose_bit_mask 1 +clippy::while_let_on_iterator 1 +clippy::comparison_to_empty 2 +clippy::derive_hash_xor_eq 2 +clippy::expl_impl_clone_on_copy 2 +clippy::len_zero 2 +clippy::manual_non_exhaustive 2 +clippy::match_on_vec_items 2 +clippy::option_as_ref_deref 2 +clippy::option_option 2 +clippy::question_mark 2 +clippy::redundant_pattern_matching 2 +clippy::type_complexity 2 +clippy::unnecessary_cast 2 +clippy::unused_unit 2 +clippy::write_with_newline 2 +clippy::filter_map_next 3 +clippy::fn_params_excessive_bools 3 +clippy::mut_mut 3 +clippy::ptr_arg 3 +clippy::zero_ptr 3 +clippy::if_same_then_else 4 +clippy::let_underscore_drop 4 +clippy::too_many_arguments 4 +clippy::empty_enum 5 +clippy::explicit_iter_loop 5 +clippy::field_reassign_with_default 5 +clippy::identity_op 5 +clippy::len_without_is_empty 5 +clippy::match_like_matches_macro 5 +clippy::needless_return 5 +clippy::new_without_default 5 +clippy::manual_strip 6 +clippy::non_ascii_literal 6 +clippy::single_component_path_imports 6 +clippy::explicit_into_iter_loop 7 +clippy::map_clone 7 +clippy::option_map_unit_fn 7 +clippy::range_plus_one 7 +clippy::invalid_upcast_comparisons 8 +clippy::wrong_self_convention 8 +clippy::find_map 9 +clippy::manual_range_contains 10 +clippy::match_wildcard_for_single_variants 10 +clippy::missing_safety_doc 10 +clippy::needless_doctest_main 10 +clippy::multiple_crate_versions 11 +clippy::needless_lifetimes 12 +clippy::option_if_let_else 12 +clippy::cargo_common_metadata 13 +clippy::shadow_unrelated 13 +clippy::linkedlist 14 +clippy::single_char_add_str 14 +clippy::default_trait_access 16 +clippy::needless_pass_by_value 18 +clippy::cast_possible_wrap 19 +clippy::cast_sign_loss 19 +clippy::unnecessary_wraps 19 +clippy::unused_self 19 +clippy::unusual_byte_groupings 19 +clippy::map_unwrap_or 20 +clippy::struct_excessive_bools 20 +clippy::redundant_static_lifetimes 21 +clippy::cast_lossless 23 +clippy::trivially_copy_pass_by_ref 26 +clippy::redundant_else 29 +clippy::filter_map 31 +clippy::too_many_lines 31 +clippy::cast_precision_loss 35 +clippy::if_not_else 35 +clippy::enum_glob_use 40 +clippy::unseparated_literal_suffix 41 +clippy::single_match_else 45 +clippy::inline_always 59 +clippy::match_same_arms 64 +clippy::similar_names 79 +clippy::cast_possible_truncation 91 +clippy::redundant_field_names 111 +clippy::redundant_closure_for_method_calls 135 +clippy::module_name_repetitions 137 +clippy::items_after_statements 139 +clippy::wildcard_imports 160 +clippy::doc_markdown 178 +clippy::missing_errors_doc 338 +clippy::unreadable_literal 365 +clippy::must_use_candidate 552 diff --git a/mini-crater/logs.txt b/mini-crater/logs.txt deleted file mode 100644 index f9084dc8321..00000000000 --- a/mini-crater/logs.txt +++ /dev/null @@ -1,3367 +0,0 @@ -clippy 0.0.212 (0d8a27a6f 2020-12-28) - -cargo/0.49.0//home/matthias/.rustup/toolchains/nightly-2020-12-20-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/core/src/macros/mod.rs:393:34 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/build.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.categories` metadata" -cargo/0.49.0/build.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.keywords` metadata" -cargo/0.49.0/src/bin/cargo/cli.rs:104:34 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/bin/cargo/cli.rs:121:5 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo/0.49.0/src/bin/cargo/cli.rs:157:30 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/cli.rs:184:41 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" -cargo/0.49.0/src/bin/cargo/cli.rs:196:42 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/cli.rs:200:39 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/cli.rs:231:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo/0.49.0/src/bin/cargo/cli.rs:245:22 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" -cargo/0.49.0/src/bin/cargo/cli.rs:247:47 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/cli.rs:257:22 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/cli.rs:26:20 clippy::redundant_else "redundant else block" -cargo/0.49.0/src/bin/cargo/cli.rs:7:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/bench.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/bench.rs:76:59 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/commands/build.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/check.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/clean.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/doc.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/fetch.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/fix.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/generate_lockfile.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/git_checkout.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/help.rs:20:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/bin/cargo/commands/init.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/install.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/install.rs:97:16 clippy::option_if_let_else "use Option::map_or instead of an if let/else" -cargo/0.49.0/src/bin/cargo/commands/locate_project.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/login.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/metadata.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/mod.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/new.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/new.rs:20:24 clippy::option_if_let_else "use Option::map_or instead of an if let/else" -cargo/0.49.0/src/bin/cargo/commands/owner.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/owner.rs:38:43 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/commands/owner.rs:39:43 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/commands/owner.rs:40:43 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/commands/owner.rs:43:30 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/commands/owner.rs:46:30 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/commands/package.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/pkgid.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/publish.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/publish.rs:40:47 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/commands/read_manifest.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/run.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/rustc.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/rustdoc.rs:3:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/search.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/test.rs:127:54 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/commands/test.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/tree.rs:149:49 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/commands/tree.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/uninstall.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/update.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/vendor.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/vendor.rs:96:16 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" -cargo/0.49.0/src/bin/cargo/commands/verify_project.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/version.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/yank.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/yank.rs:32:36 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/commands/yank.rs:33:35 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/commands/yank.rs:34:36 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/commands/yank.rs:35:36 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/main.rs:100:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" -cargo/0.49.0/src/bin/cargo/main.rs:118:41 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/main.rs:137:43 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/main.rs:148:19 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/bin/cargo/main.rs:174:57 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/main.rs:18:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/main.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.categories` metadata" -cargo/0.49.0/src/bin/cargo/main.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.keywords` metadata" -cargo/0.49.0/src/bin/cargo/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `crossbeam-utils`: 0.6.6, 0.7.2" -cargo/0.49.0/src/bin/cargo/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `hex`: 0.3.2, 0.4.0" -cargo/0.49.0/src/bin/cargo/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `humantime`: 1.3.0, 2.0.0" -cargo/0.49.0/src/bin/cargo/main.rs:72:22 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/main.rs:94:13 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" -cargo/0.49.0/src/bin/cargo/main.rs:96:41 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/main.rs:98:60 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/compiler/build_config.rs:155:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -cargo/0.49.0/src/cargo/core/compiler/build_config.rs:170:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/build_config.rs:175:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/build_config.rs:180:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/build_config.rs:186:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/build_config.rs:197:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/build_config.rs:205:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/build_config.rs:51:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/build_config.rs:69:48 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -cargo/0.49.0/src/cargo/core/compiler/build_config.rs:96:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/build_context/mod.rs:44:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/build_context/mod.rs:83:20 clippy::doc_markdown "you should put `x86_64` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:108:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:121:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:149:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:420:69 clippy::doc_markdown "you should put `mode/target_kind` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:423:19 clippy::doc_markdown "you should put `CrateTypes` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:424:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:469:58 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:591:20 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" -cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:603:19 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:665:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:82:31 clippy::doc_markdown "you should put `FileType` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:83:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:84:9 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:96:31 clippy::doc_markdown "you should put `FileType` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:98:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/build_plan.rs:4:9 clippy::doc_markdown "you should put `BuildPlan` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/build_plan.rs:5:66 clippy::doc_markdown "you should put `BuildPlan` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/build_plan.rs:66:40 clippy::ptr_arg "writing `&PathBuf` instead of `&Path` involves a new object where a slice will do." -cargo/0.49.0/src/cargo/core/compiler/compilation.rs:150:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/compilation.rs:169:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/compilation.rs:185:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/compilation.rs:193:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/compilation.rs:194:49 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/compiler/compilation.rs:198:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/compilation.rs:314:16 clippy::doc_markdown "you should put `rustc_tool` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/compilation.rs:91:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/compile_kind.rs:118:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/compile_kind.rs:147:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/compile_kind.rs:157:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/compile_kind.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/compile_kind.rs:33:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/compile_kind.rs:49:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/context/compilation_files.rs:204:9 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/core/compiler/context/compilation_files.rs:277:22 clippy::doc_markdown "you should put `OUT_DIR` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/context/compilation_files.rs:324:66 clippy::doc_markdown "you should put `FileType` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/context/compilation_files.rs:393:37 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/compiler/context/compilation_files.rs:426:71 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:125:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:125:5 clippy::too_many_lines "this function has too many lines (107/100)" -cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:270:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:286:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:308:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:340:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:349:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:354:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:358:21 clippy::doc_markdown "you should put `RunCustomBuild` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:361:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:365:9 clippy::find_map "called `find(..).map(..)` on an `Iterator`" -cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:374:43 clippy::doc_markdown "you should put `RunCustomBuild` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:378:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:383:41 clippy::doc_markdown "you should put `RunCustomBuild` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:384:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:391:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:397:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:523:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:538:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:542:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:83:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:92:25 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/core/compiler/crate_type.rs:16:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/crate_type.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/crate_type.rs:40:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/crate_type.rs:49:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/crate_type.rs:60:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:150:1 clippy::too_many_lines "this function has too many lines (230/100)" -cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:154:29 clippy::find_map "called `find(..).map(..)` on an `Iterator`" -cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:353:56 clippy::manual_strip "stripping a prefix manually" -cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:448:27 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:464:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:481:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:48:56 clippy::doc_markdown "you should put `RunCustomBuild` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:561:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:567:20 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:576:28 clippy::shadow_unrelated "`mut value` is being shadowed" -cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:606:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:624:13 clippy::find_map "called `find(..).map(..)` on an `Iterator`" -cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:688:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:756:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:762:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:762:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:823:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1021:51 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1252:20 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1278:19 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1656:16 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1664:5 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1787:5 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1795:5 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1882:17 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1894:17 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1906:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1917:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1923:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1956:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1962:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1963:22 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1964:22 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1965:22 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1966:22 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1980:17 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1980:24 clippy::manual_strip "stripping a prefix manually" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1986:17 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:2016:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:61:5 clippy::doc_markdown "you should put `CompileMode` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:63:12 clippy::doc_markdown "you should put `CompileKind` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:67:7 clippy::doc_markdown "you should put `CARGO_DEFAULT_LIB_METADATA[^4` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:68:5 clippy::doc_markdown "you should put `package_id` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:71:19 clippy::doc_markdown "you should put `test/bench/for_host/edition` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:755:52 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:77:5 clippy::doc_markdown "you should put `is_std` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:816:5 clippy::too_many_lines "this function has too many lines (127/100)" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:863:64 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:875:33 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:876:32 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:896:30 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:897:30 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:991:37 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:12:5 clippy::doc_markdown "you should put `src/librustc_jobserver/lib.rs` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:282:30 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" -cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:329:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:332:23 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:34:53 clippy::doc_markdown "you should put `NeedsToken` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:35:6 clippy::doc_markdown "you should put `ReleaseToken` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:37:6 clippy::doc_markdown "you should put `NeedsToken` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:40:5 clippy::doc_markdown "you should put `NeedsToken` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:40:56 clippy::doc_markdown "you should put `NeedsToken` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:43:6 clippy::doc_markdown "you should put `ReleaseToken` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:749:13 clippy::if_not_else "unnecessary boolean `not` operation" -cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:786:26 clippy::unused_self "unused `self` argument" -cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:81:61 clippy::doc_markdown "you should put `DrainState` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:865:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:871:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:890:9 clippy::unused_self "unused `self` argument" -cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:93:24 clippy::doc_markdown "you should put `JobQueue` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/links.rs:8:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/core/compiler/mod.rs:1016:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/mod.rs:1094:19 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/compiler/mod.rs:1131:1 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -cargo/0.49.0/src/cargo/core/compiler/mod.rs:1277:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/compiler/mod.rs:179:1 clippy::too_many_lines "this function has too many lines (162/100)" -cargo/0.49.0/src/cargo/core/compiler/mod.rs:198:78 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/compiler/mod.rs:201:25 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/core/compiler/mod.rs:267:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/compiler/mod.rs:324:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/compiler/mod.rs:364:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/compiler/mod.rs:364:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -cargo/0.49.0/src/cargo/core/compiler/mod.rs:392:45 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/compiler/mod.rs:415:23 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/core/compiler/mod.rs:464:18 clippy::ptr_arg "writing `&PathBuf` instead of `&Path` involves a new object where a slice will do." -cargo/0.49.0/src/cargo/core/compiler/mod.rs:488:61 clippy::ptr_arg "writing `&PathBuf` instead of `&Path` involves a new object where a slice will do." -cargo/0.49.0/src/cargo/core/compiler/mod.rs:667:15 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/core/compiler/mod.rs:693:1 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -cargo/0.49.0/src/cargo/core/compiler/mod.rs:725:42 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/compiler/mod.rs:736:1 clippy::too_many_lines "this function has too many lines (141/100)" -cargo/0.49.0/src/cargo/core/compiler/mod.rs:73:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/mod.rs:777:12 clippy::if_not_else "unnecessary boolean `not` operation" -cargo/0.49.0/src/cargo/core/compiler/mod.rs:873:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/compiler/output_depinfo.rs:41:13 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" -cargo/0.49.0/src/cargo/core/compiler/rustdoc.rs:16:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/core/compiler/rustdoc.rs:57:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/core/compiler/rustdoc.rs:72:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/standard_lib.rs:134:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/standard_lib.rs:16:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/standard_lib.rs:30:28 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/compiler/standard_lib.rs:34:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/timings.rs:16:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo/0.49.0/src/cargo/core/compiler/timings.rs:192:64 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo/0.49.0/src/cargo/core/compiler/timings.rs:212:58 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo/0.49.0/src/cargo/core/compiler/timings.rs:234:13 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" -cargo/0.49.0/src/cargo/core/compiler/timings.rs:355:13 clippy::cast_possible_truncation "casting `f64` to `u32` may truncate the value" -cargo/0.49.0/src/cargo/core/compiler/timings.rs:355:13 clippy::cast_sign_loss "casting `f64` to `u32` may lose the sign of the value" -cargo/0.49.0/src/cargo/core/compiler/timings.rs:397:38 clippy::cast_possible_truncation "casting `f64` to `u32` may truncate the value" -cargo/0.49.0/src/cargo/core/compiler/timings.rs:397:38 clippy::cast_sign_loss "casting `f64` to `u32` may lose the sign of the value" -cargo/0.49.0/src/cargo/core/compiler/timings.rs:484:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/compiler/timings.rs:605:38 clippy::doc_markdown "you should put `rmeta_time` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/timings.rs:605:50 clippy::doc_markdown "you should put `codegen_time` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/timings.rs:641:26 clippy::non_ascii_literal "literal non-ASCII character detected" -cargo/0.49.0/src/cargo/core/compiler/unit.rs:100:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/unit.rs:151:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/core/compiler/unit.rs:161:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/unit.rs:35:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/core/compiler/unit_dependencies.rs:154:29 clippy::doc_markdown "you should put `state.unit_dependencies` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/unit_dependencies.rs:213:1 clippy::too_many_lines "this function has too many lines (110/100)" -cargo/0.49.0/src/cargo/core/compiler/unit_dependencies.rs:329:13 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" -cargo/0.49.0/src/cargo/core/compiler/unit_dependencies.rs:480:5 clippy::find_map "called `find(..).map(..)` on an `Iterator`" -cargo/0.49.0/src/cargo/core/compiler/unit_dependencies.rs:511:5 clippy::find_map "called `find(..).map(..)` on an `Iterator`" -cargo/0.49.0/src/cargo/core/compiler/unit_dependencies.rs:52:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/unit_dependencies.rs:52:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/core/compiler/unit_graph.rs:65:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/unit_graph.rs:65:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/core/dependency.rs:157:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/dependency.rs:182:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/dependency.rs:203:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/dependency.rs:224:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/dependency.rs:23:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo/0.49.0/src/cargo/core/dependency.rs:248:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/dependency.rs:270:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/dependency.rs:274:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/dependency.rs:278:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/dependency.rs:287:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/dependency.rs:291:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/dependency.rs:305:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/dependency.rs:311:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/dependency.rs:319:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/dependency.rs:337:75 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/dependency.rs:397:56 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/dependency.rs:403:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/dependency.rs:408:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/dependency.rs:415:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/dependency.rs:419:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/dependency.rs:424:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/dependency.rs:428:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/dependency.rs:433:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/dependency.rs:438:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/dependency.rs:443:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/dependency.rs:449:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/dependency.rs:450:9 clippy::if_not_else "unnecessary `!=` operation" -cargo/0.49.0/src/cargo/core/features.rs:119:17 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/features.rs:229:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/features.rs:274:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/features.rs:278:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/features.rs:306:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/features.rs:338:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo/0.49.0/src/cargo/core/features.rs:362:25 clippy::option_option "consider using `Option` instead of `Option>` or a custom enum if you need to distinguish all 3 cases" -cargo/0.49.0/src/cargo/core/features.rs:380:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/features.rs:401:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/features.rs:409:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/features.rs:412:45 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/features.rs:416:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/features.rs:419:45 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/features.rs:424:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/features.rs:431:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/features.rs:477:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/features.rs:509:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/features.rs:518:5 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" -cargo/0.49.0/src/cargo/core/features.rs:542:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/features.rs:543:37 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/features.rs:547:60 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/features.rs:556:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/core/features.rs:563:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/core/manifest.rs:116:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -cargo/0.49.0/src/cargo/core/manifest.rs:118:58 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/manifest.rs:130:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -cargo/0.49.0/src/cargo/core/manifest.rs:143:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:159:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:162:34 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/manifest.rs:169:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:17:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/cargo/core/manifest.rs:189:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo/0.49.0/src/cargo/core/manifest.rs:215:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:222:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:22:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/core/manifest.rs:360:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:407:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:410:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:413:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:416:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:419:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:422:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:425:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:431:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:438:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:444:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:447:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:450:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:453:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:456:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:459:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:462:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:466:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:470:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:477:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:481:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:488:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/manifest.rs:512:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:516:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:520:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:524:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:528:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:538:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:557:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:561:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:565:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:569:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:577:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:581:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:588:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:617:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:632:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:648:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:659:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:66:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/core/manifest.rs:670:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:693:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:708:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:723:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:726:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:729:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:735:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:738:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:741:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:744:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:747:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:751:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:754:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:757:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:760:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:763:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:767:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:776:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:780:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:787:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:798:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:800:56 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/manifest.rs:805:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:809:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:818:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:823:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:828:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:831:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:834:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:839:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:85:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/core/manifest.rs:888:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:936:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package.rs:1075:28 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/package.rs:160:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package.rs:170:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package.rs:174:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package.rs:182:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package.rs:186:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package.rs:190:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package.rs:194:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package.rs:198:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package.rs:202:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package.rs:206:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package.rs:210:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package.rs:217:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package.rs:221:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package.rs:222:35 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/package.rs:226:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package.rs:227:35 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/package.rs:230:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package.rs:239:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/package.rs:249:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package.rs:287:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/core/package.rs:385:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/package.rs:421:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -cargo/0.49.0/src/cargo/core/package.rs:425:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/package.rs:452:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/package.rs:453:60 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/package.rs:459:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/package.rs:473:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/package.rs:587:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/package.rs:682:46 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" -cargo/0.49.0/src/cargo/core/package.rs:682:46 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" -cargo/0.49.0/src/cargo/core/package.rs:682:63 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" -cargo/0.49.0/src/cargo/core/package.rs:682:63 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" -cargo/0.49.0/src/cargo/core/package.rs:731:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/package.rs:790:13 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/core/package.rs:988:9 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/core/package_id.rs:115:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/package_id.rs:124:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package_id.rs:139:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package_id.rs:142:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package_id.rs:145:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package_id.rs:149:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package_id.rs:157:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package_id.rs:161:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package_id.rs:169:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package_id.rs:174:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/core/package_id_spec.rs:101:39 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/package_id_spec.rs:143:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package_id_spec.rs:147:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package_id_spec.rs:151:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package_id_spec.rs:160:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package_id_spec.rs:179:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/package_id_spec.rs:212:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/package_id_spec.rs:231:9 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/core/package_id_spec.rs:51:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/package_id_spec.rs:77:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/package_id_spec.rs:88:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/profiles.rs:1004:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/profiles.rs:1014:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/profiles.rs:1018:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/profiles.rs:1028:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/profiles.rs:106:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/profiles.rs:143:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -cargo/0.49.0/src/cargo/core/profiles.rs:286:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/profiles.rs:294:40 clippy::if_not_else "unnecessary boolean `not` operation" -cargo/0.49.0/src/cargo/core/profiles.rs:30:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/profiles.rs:342:25 clippy::shadow_unrelated "`maker` is being shadowed" -cargo/0.49.0/src/cargo/core/profiles.rs:370:41 clippy::unused_self "unused `self` argument" -cargo/0.49.0/src/cargo/core/profiles.rs:370:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/profiles.rs:372:9 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" -cargo/0.49.0/src/cargo/core/profiles.rs:382:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/profiles.rs:383:28 clippy::if_not_else "unnecessary boolean `not` operation" -cargo/0.49.0/src/cargo/core/profiles.rs:397:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/profiles.rs:405:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/profiles.rs:607:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo/0.49.0/src/cargo/core/profiles.rs:909:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/profiles.rs:923:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/profiles.rs:934:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/profiles.rs:987:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/registry.rs:111:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/registry.rs:127:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/registry.rs:168:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/registry.rs:19:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/registry.rs:240:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/registry.rs:26:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/registry.rs:344:49 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/registry.rs:369:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/registry.rs:424:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/registry.rs:49:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/core/registry.rs:520:17 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/core/registry.rs:763:53 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/registry.rs:765:53 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/registry.rs:807:14 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/registry.rs:814:53 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/resolver/conflict_cache.rs:197:29 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/resolver/conflict_cache.rs:41:38 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" -cargo/0.49.0/src/cargo/core/resolver/context.rs:274:53 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/resolver/context.rs:297:9 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" -cargo/0.49.0/src/cargo/core/resolver/context.rs:42:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/core/resolver/context.rs:74:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/encode.rs:156:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/resolver/encode.rs:156:5 clippy::too_many_lines "this function has too many lines (164/100)" -cargo/0.49.0/src/cargo/core/resolver/encode.rs:339:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" -cargo/0.49.0/src/cargo/core/resolver/encode.rs:438:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/resolver/encode.rs:449:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/resolver/encode.rs:529:34 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/resolver/encode.rs:602:59 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/resolver/encode.rs:623:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/core/resolver/encode.rs:652:27 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/core/resolver/encode.rs:674:51 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/resolver/errors.rs:103:22 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/resolver/errors.rs:104:22 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/resolver/errors.rs:206:9 clippy::if_not_else "unnecessary boolean `not` operation" -cargo/0.49.0/src/cargo/core/resolver/errors.rs:257:45 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/resolver/errors.rs:27:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/errors.rs:305:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo/0.49.0/src/cargo/core/resolver/errors.rs:70:1 clippy::too_many_lines "this function has too many lines (207/100)" -cargo/0.49.0/src/cargo/core/resolver/features.rs:104:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/core/resolver/features.rs:111:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/features.rs:162:56 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/resolver/features.rs:179:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/core/resolver/features.rs:186:23 clippy::doc_markdown "you should put `RequestedFeatures` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/resolver/features.rs:187:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/features.rs:199:23 clippy::doc_markdown "you should put `RequestedFeatures` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/resolver/features.rs:200:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/features.rs:209:9 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" -cargo/0.49.0/src/cargo/core/resolver/features.rs:221:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/features.rs:231:21 clippy::doc_markdown "you should put `pkg_id/is_build` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/resolver/features.rs:233:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/features.rs:247:58 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/resolver/features.rs:278:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/resolver/features.rs:394:27 clippy::doc_markdown "you should put `FeatureValue` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/resolver/features.rs:460:19 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/core/resolver/features.rs:480:24 clippy::doc_markdown "you should put `FeatureValues` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/resolver/features.rs:496:24 clippy::doc_markdown "you should put `FeatureValues` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/resolver/features.rs:561:28 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" -cargo/0.49.0/src/cargo/core/resolver/features.rs:58:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/core/resolver/features.rs:67:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo/0.49.0/src/cargo/core/resolver/mod.rs:1017:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/resolver/mod.rs:1045:57 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/resolver/mod.rs:122:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/resolver/mod.rs:142:44 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/resolver/mod.rs:180:1 clippy::too_many_lines "this function has too many lines (225/100)" -cargo/0.49.0/src/cargo/core/resolver/mod.rs:311:17 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/core/resolver/mod.rs:421:52 clippy::filter_map_next "called `filter_map(..).next()` on an `Iterator`. This is more succinctly expressed by calling `.find_map(..)` instead." -cargo/0.49.0/src/cargo/core/resolver/mod.rs:437:33 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" -cargo/0.49.0/src/cargo/core/resolver/mod.rs:457:69 clippy::filter_map_next "called `filter_map(..).next()` on an `Iterator`. This is more succinctly expressed by calling `.find_map(..)` instead." -cargo/0.49.0/src/cargo/core/resolver/mod.rs:470:37 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/core/resolver/mod.rs:480:37 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" -cargo/0.49.0/src/cargo/core/resolver/mod.rs:607:11 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo/0.49.0/src/cargo/core/resolver/mod.rs:631:21 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/core/resolver/mod.rs:942:15 clippy::if_not_else "unnecessary boolean `not` operation" -cargo/0.49.0/src/cargo/core/resolver/mod.rs:988:20 clippy::redundant_else "redundant else block" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:120:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:132:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:199:24 clippy::redundant_else "redundant else block" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:235:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:239:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:255:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:259:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:263:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:269:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:273:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:274:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:280:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:284:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:288:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:292:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:296:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:300:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:315:13 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:354:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:362:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:60:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:76:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:90:35 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" -cargo/0.49.0/src/cargo/core/resolver/types.rs:111:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/resolver/types.rs:121:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/types.rs:141:19 clippy::doc_markdown "you should put `ResolveOpts` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/resolver/types.rs:142:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/types.rs:149:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/types.rs:181:9 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" -cargo/0.49.0/src/cargo/core/resolver/types.rs:187:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -cargo/0.49.0/src/cargo/core/resolver/types.rs:261:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -cargo/0.49.0/src/cargo/core/shell.rs:113:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/shell.rs:130:9 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/core/shell.rs:148:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/shell.rs:153:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/shell.rs:163:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/shell.rs:18:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/shell.rs:198:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/shell.rs:206:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/shell.rs:214:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/shell.rs:228:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/shell.rs:239:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/shell.rs:250:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/shell.rs:259:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/shell.rs:267:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/shell.rs:26:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/shell.rs:277:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/shell.rs:282:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/shell.rs:314:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/shell.rs:322:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/shell.rs:330:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/shell.rs:98:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/source/mod.rs:103:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/source/mod.rs:247:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/core/source/mod.rs:261:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/source/mod.rs:268:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/source/mod.rs:273:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/source/mod.rs:291:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/source/mod.rs:302:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/source/mod.rs:307:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/source/mod.rs:31:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/source/mod.rs:37:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/source/mod.rs:39:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/source/mod.rs:47:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/source/mod.rs:50:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/source/mod.rs:52:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/source/mod.rs:63:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/source/mod.rs:74:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/source/mod.rs:83:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/source/source_id.rs:107:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/source/source_id.rs:128:50 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/source/source_id.rs:147:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/source/source_id.rs:156:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/source/source_id.rs:162:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/source/source_id.rs:166:19 clippy::doc_markdown "you should put `SourceId` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/source/source_id.rs:167:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/source/source_id.rs:171:19 clippy::doc_markdown "you should put `SourceId` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/source/source_id.rs:172:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/source/source_id.rs:178:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/source/source_id.rs:187:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/source/source_id.rs:18:74 clippy::default_trait_access "calling `std::sync::Mutex::default()` is more clear than this expression" -cargo/0.49.0/src/cargo/core/source/source_id.rs:195:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/source/source_id.rs:207:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/source/source_id.rs:213:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/source/source_id.rs:217:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/source/source_id.rs:225:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/source/source_id.rs:228:16 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" -cargo/0.49.0/src/cargo/core/source/source_id.rs:236:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/source/source_id.rs:241:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/source/source_id.rs:252:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/source/source_id.rs:257:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/source/source_id.rs:262:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/source/source_id.rs:305:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/source/source_id.rs:310:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/source/source_id.rs:318:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/source/source_id.rs:326:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/source/source_id.rs:355:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/source/source_id.rs:393:61 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:394:42 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:395:42 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:397:71 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:397:71 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:398:47 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:398:47 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:399:47 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:399:47 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:401:63 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:401:63 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:401:63 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:402:43 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:402:43 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:402:43 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:403:43 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:403:43 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:403:43 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:406:21 clippy::enum_glob_use "usage of wildcard import for enum variants" -cargo/0.49.0/src/cargo/core/source/source_id.rs:412:41 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:413:36 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:414:36 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:420:47 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:420:47 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:512:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo/0.49.0/src/cargo/core/source/source_id.rs:513:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo/0.49.0/src/cargo/core/source/source_id.rs:517:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo/0.49.0/src/cargo/core/source/source_id.rs:518:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo/0.49.0/src/cargo/core/source/source_id.rs:525:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo/0.49.0/src/cargo/core/source/source_id.rs:526:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo/0.49.0/src/cargo/core/source/source_id.rs:530:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo/0.49.0/src/cargo/core/source/source_id.rs:531:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo/0.49.0/src/cargo/core/source/source_id.rs:535:33 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo/0.49.0/src/cargo/core/source/source_id.rs:536:37 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo/0.49.0/src/cargo/core/source/source_id.rs:537:42 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo/0.49.0/src/cargo/core/source/source_id.rs:538:38 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo/0.49.0/src/cargo/core/source/source_id.rs:548:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/core/source/source_id.rs:597:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/summary.rs:103:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/summary.rs:123:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/summary.rs:150:1 clippy::too_many_lines "this function has too many lines (141/100)" -cargo/0.49.0/src/cargo/core/summary.rs:158:9 clippy::enum_glob_use "usage of wildcard import for enum variants" -cargo/0.49.0/src/cargo/core/summary.rs:181:21 clippy::if_not_else "unnecessary boolean `not` operation" -cargo/0.49.0/src/cargo/core/summary.rs:192:28 clippy::redundant_else "redundant else block" -cargo/0.49.0/src/cargo/core/summary.rs:258:32 clippy::redundant_else "redundant else block" -cargo/0.49.0/src/cargo/core/summary.rs:281:28 clippy::redundant_else "redundant else block" -cargo/0.49.0/src/cargo/core/summary.rs:303:28 clippy::redundant_else "redundant else block" -cargo/0.49.0/src/cargo/core/summary.rs:321:51 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/summary.rs:344:5 clippy::doc_markdown "you should put `FeatureValue` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/summary.rs:350:85 clippy::doc_markdown "you should put `FeatureValue` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/summary.rs:36:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/summary.rs:378:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/summary.rs:386:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/summary.rs:387:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -cargo/0.49.0/src/cargo/core/summary.rs:407:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -cargo/0.49.0/src/cargo/core/summary.rs:69:34 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/summary.rs:75:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/summary.rs:78:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/summary.rs:81:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/summary.rs:84:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/summary.rs:87:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/summary.rs:90:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/summary.rs:93:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/summary.rs:96:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/summary.rs:99:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/workspace.rs:1019:59 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" -cargo/0.49.0/src/cargo/core/workspace.rs:1056:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -cargo/0.49.0/src/cargo/core/workspace.rs:113:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/core/workspace.rs:1157:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/workspace.rs:128:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/core/workspace.rs:150:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/workspace.rs:159:16 clippy::redundant_else "redundant else block" -cargo/0.49.0/src/cargo/core/workspace.rs:197:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/workspace.rs:225:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/workspace.rs:255:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/workspace.rs:267:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/workspace.rs:329:37 clippy::doc_markdown "you should put `VirtualManifest` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/workspace.rs:410:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/workspace.rs:440:9 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -cargo/0.49.0/src/cargo/core/workspace.rs:511:32 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/core/workspace.rs:561:25 clippy::non_ascii_literal "literal non-ASCII character detected" -cargo/0.49.0/src/cargo/core/workspace.rs:613:13 clippy::filter_map "called `filter_map(..).map(..)` on an `Iterator`" -cargo/0.49.0/src/cargo/core/workspace.rs:615:22 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/workspace.rs:688:35 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" -cargo/0.49.0/src/cargo/core/workspace.rs:762:27 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/core/workspace.rs:784:17 clippy::if_not_else "unnecessary boolean `not` operation" -cargo/0.49.0/src/cargo/core/workspace.rs:849:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/workspace.rs:893:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/workspace.rs:906:24 clippy::redundant_else "redundant else block" -cargo/0.49.0/src/cargo/core/workspace.rs:932:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/lib.rs:177:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/lib.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.categories` metadata" -cargo/0.49.0/src/cargo/lib.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.keywords` metadata" -cargo/0.49.0/src/cargo/lib.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `crossbeam-utils`: 0.6.6, 0.7.2" -cargo/0.49.0/src/cargo/lib.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `hex`: 0.3.2, 0.4.0" -cargo/0.49.0/src/cargo/lib.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `humantime`: 1.3.0, 2.0.0" -cargo/0.49.0/src/cargo/ops/cargo_clean.rs:205:23 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/ops/cargo_clean.rs:27:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_clean.rs:27:1 clippy::too_many_lines "this function has too many lines (120/100)" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:1078:14 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:109:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:119:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:1227:17 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:127:35 clippy::from_iter_instead_of_collect "usage of `FromIterator::from_iter`" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:128:32 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:173:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:205:36 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:242:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:249:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:258:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:275:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:275:1 clippy::too_many_lines "this function has too many lines (219/100)" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:468:9 clippy::default_trait_access "calling `std::collections::HashMap::default()` is more clear than this expression" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:548:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:556:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:574:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:583:21 clippy::doc_markdown "you should put `CompileFilter` between ticks in the documentation" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:584:5 clippy::fn_params_excessive_bools "more than 3 bools in function parameters" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:584:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:592:9 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:593:9 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:607:13 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:612:21 clippy::doc_markdown "you should put `CompileFilter` between ticks in the documentation" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:613:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:618:9 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:641:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:652:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:655:50 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:673:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:692:49 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:703:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:729:1 clippy::too_many_lines "this function has too many lines (205/100)" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:82:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:874:69 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/ops/cargo_doc.rs:20:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_fetch.rs:15:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_fetch.rs:27:46 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/ops/cargo_fetch.rs:36:20 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" -cargo/0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:160:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:175:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:22:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:37:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:37:1 clippy::too_many_lines "this function has too many lines (171/100)" -cargo/0.49.0/src/cargo/ops/cargo_install.rs:13:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/cargo/ops/cargo_install.rs:148:1 clippy::fn_params_excessive_bools "more than 3 bools in function parameters" -cargo/0.49.0/src/cargo/ops/cargo_install.rs:148:1 clippy::too_many_lines "this function has too many lines (316/100)" -cargo/0.49.0/src/cargo/ops/cargo_install.rs:202:17 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/ops/cargo_install.rs:312:64 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/ops/cargo_install.rs:318:63 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" -cargo/0.49.0/src/cargo/ops/cargo_install.rs:32:13 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" -cargo/0.49.0/src/cargo/ops/cargo_install.rs:37:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_install.rs:454:22 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/ops/cargo_install.rs:483:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/ops/cargo_install.rs:683:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_new.rs:101:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_new.rs:245:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/ops/cargo_new.rs:251:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/ops/cargo_new.rs:367:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_new.rs:405:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_new.rs:489:5 clippy::doc_markdown "you should put `IgnoreList` between ticks in the documentation" -cargo/0.49.0/src/cargo/ops/cargo_new.rs:525:47 clippy::doc_markdown "you should put `IgnoreList` between ticks in the documentation" -cargo/0.49.0/src/cargo/ops/cargo_new.rs:525:9 clippy::doc_markdown "you should put `format_existing` between ticks in the documentation" -cargo/0.49.0/src/cargo/ops/cargo_new.rs:572:34 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/ops/cargo_new.rs:623:1 clippy::too_many_lines "this function has too many lines (130/100)" -cargo/0.49.0/src/cargo/ops/cargo_new.rs:781:5 clippy::filter_map_next "called `filter_map(..).next()` on an `Iterator`. This is more succinctly expressed by calling `.find_map(..)` instead." -cargo/0.49.0/src/cargo/ops/cargo_new.rs:800:16 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/ops/cargo_output_metadata.rs:163:36 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/ops/cargo_output_metadata.rs:27:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_output_metadata.rs:45:45 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/ops/cargo_package.rs:144:1 clippy::too_many_lines "this function has too many lines (112/100)" -cargo/0.49.0/src/cargo/ops/cargo_package.rs:207:13 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/ops/cargo_package.rs:25:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo/0.49.0/src/cargo/ops/cargo_package.rs:307:54 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/ops/cargo_package.rs:394:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/ops/cargo_package.rs:418:21 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" -cargo/0.49.0/src/cargo/ops/cargo_package.rs:425:61 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/ops/cargo_package.rs:459:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/ops/cargo_package.rs:66:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_package.rs:769:29 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" -cargo/0.49.0/src/cargo/ops/cargo_package.rs:93:20 clippy::if_not_else "unnecessary boolean `not` operation" -cargo/0.49.0/src/cargo/ops/cargo_pkgid.rs:5:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_read_manifest.rs:14:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_read_manifest.rs:171:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/ops/cargo_read_manifest.rs:37:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_read_manifest.rs:57:49 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/ops/cargo_read_manifest.rs:69:37 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/ops/cargo_run.rs:25:24 clippy::if_not_else "unnecessary boolean `not` operation" -cargo/0.49.0/src/cargo/ops/cargo_run.rs:35:9 clippy::if_not_else "unnecessary boolean `not` operation" -cargo/0.49.0/src/cargo/ops/cargo_run.rs:37:16 clippy::redundant_else "redundant else block" -cargo/0.49.0/src/cargo/ops/cargo_run.rs:53:9 clippy::if_not_else "unnecessary boolean `not` operation" -cargo/0.49.0/src/cargo/ops/cargo_run.rs:65:16 clippy::redundant_else "redundant else block" -cargo/0.49.0/src/cargo/ops/cargo_run.rs:9:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_test.rs:16:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_test.rs:43:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_test.rs:84:17 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/ops/cargo_uninstall.rs:14:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_uninstall.rs:7:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:147:9 clippy::doc_markdown "you should put `PackageId` between ticks in the documentation" -cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:233:21 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:244:22 clippy::doc_markdown "you should put `PackageId` between ticks in the documentation" -cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:244:63 clippy::doc_markdown "you should put `PackageId` between ticks in the documentation" -cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:253:17 clippy::if_not_else "unnecessary boolean `not` operation" -cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:370:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:392:9 clippy::find_map "called `find(..).map(..)` on an `Iterator`" -cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:505:8 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" -cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:525:10 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:542:27 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:542:5 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:561:20 clippy::redundant_else "redundant else block" -cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:613:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:645:41 clippy::doc_markdown "you should put `BTreeSet` between ticks in the documentation" -cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:654:42 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" -cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:662:14 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" -cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:674:17 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" -cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:681:17 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" -cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:92:19 clippy::doc_markdown "you should put `InstallTracker` between ticks in the documentation" -cargo/0.49.0/src/cargo/ops/fix.rs:200:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/fix.rs:200:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/ops/fix.rs:424:20 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" -cargo/0.49.0/src/cargo/ops/fix.rs:455:13 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/ops/fix.rs:506:17 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/ops/fix.rs:608:9 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" -cargo/0.49.0/src/cargo/ops/fix.rs:612:42 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/ops/fix.rs:619:48 clippy::manual_strip "stripping a prefix manually" -cargo/0.49.0/src/cargo/ops/fix.rs:66:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/ops/fix.rs:66:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo/0.49.0/src/cargo/ops/fix.rs:708:18 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/ops/fix.rs:77:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/lockfile.rs:154:13 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo/0.49.0/src/cargo/ops/lockfile.rs:217:9 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo/0.49.0/src/cargo/ops/lockfile.rs:30:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/lockfile.rs:35:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/lockfile.rs:35:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/ops/lockfile.rs:87:1 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -cargo/0.49.0/src/cargo/ops/lockfile.rs:8:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/lockfile.rs:8:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/ops/registry.rs:150:21 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/ops/registry.rs:188:1 clippy::too_many_lines "this function has too many lines (130/100)" -cargo/0.49.0/src/cargo/ops/registry.rs:196:16 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" -cargo/0.49.0/src/cargo/ops/registry.rs:212:32 clippy::if_not_else "unnecessary `!=` operation" -cargo/0.49.0/src/cargo/ops/registry.rs:222:53 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/ops/registry.rs:224:44 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/ops/registry.rs:31:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/ops/registry.rs:346:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/registry.rs:346:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/ops/registry.rs:351:26 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/ops/registry.rs:385:12 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo/0.49.0/src/cargo/ops/registry.rs:386:15 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo/0.49.0/src/cargo/ops/registry.rs:38:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo/0.49.0/src/cargo/ops/registry.rs:477:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/registry.rs:483:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/registry.rs:503:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/registry.rs:505:38 clippy::default_trait_access "calling `util::config::CargoHttpConfig::default()` is more clear than this expression" -cargo/0.49.0/src/cargo/ops/registry.rs:510:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/registry.rs:529:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/ops/registry.rs:53:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/registry.rs:573:22 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/ops/registry.rs:608:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/registry.rs:621:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/registry.rs:671:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/registry.rs:671:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/ops/registry.rs:674:10 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo/0.49.0/src/cargo/ops/registry.rs:678:17 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/ops/registry.rs:730:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/registry.rs:731:16 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/ops/registry.rs:785:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/registry.rs:794:16 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/ops/registry.rs:828:14 clippy::doc_markdown "you should put `SourceId` between ticks in the documentation" -cargo/0.49.0/src/cargo/ops/registry.rs:848:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/resolve.rs:199:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/resolve.rs:199:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/ops/resolve.rs:199:1 clippy::too_many_lines "this function has too many lines (137/100)" -cargo/0.49.0/src/cargo/ops/resolve.rs:241:28 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/ops/resolve.rs:28:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/ops/resolve.rs:384:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/resolve.rs:417:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/resolve.rs:589:9 clippy::shadow_unrelated "`keep` is being shadowed" -cargo/0.49.0/src/cargo/ops/resolve.rs:58:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/resolve.rs:58:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/ops/resolve.rs:602:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/ops/resolve.rs:75:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/resolve.rs:75:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/ops/tree/graph.rs:129:26 clippy::doc_markdown "you should put `PackageIds` between ticks in the documentation" -cargo/0.49.0/src/cargo/ops/tree/graph.rs:131:47 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" -cargo/0.49.0/src/cargo/ops/tree/graph.rs:152:15 clippy::match_on_vec_items "indexing into a vector may panic" -cargo/0.49.0/src/cargo/ops/tree/graph.rs:173:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/ops/tree/graph.rs:234:46 clippy::filter_map "called `filter(..).flat_map(..)` on an `Iterator`" -cargo/0.49.0/src/cargo/ops/tree/graph.rs:328:44 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/ops/tree/graph.rs:330:50 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/ops/tree/graph.rs:563:35 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/ops/tree/mod.rs:112:11 clippy::non_ascii_literal "literal non-ASCII character detected" -cargo/0.49.0/src/cargo/ops/tree/mod.rs:113:10 clippy::non_ascii_literal "literal non-ASCII character detected" -cargo/0.49.0/src/cargo/ops/tree/mod.rs:114:10 clippy::non_ascii_literal "literal non-ASCII character detected" -cargo/0.49.0/src/cargo/ops/tree/mod.rs:115:12 clippy::non_ascii_literal "literal non-ASCII character detected" -cargo/0.49.0/src/cargo/ops/tree/mod.rs:126:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/tree/mod.rs:21:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/ops/tree/mod.rs:21:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo/0.49.0/src/cargo/ops/tree/mod.rs:360:30 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/ops/tree/mod.rs:58:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/ops/vendor.rs:14:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/ops/vendor.rs:21:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/vendor.rs:314:34 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/ops/vendor.rs:324:13 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" -cargo/0.49.0/src/cargo/ops/vendor.rs:70:1 clippy::too_many_lines "this function has too many lines (175/100)" -cargo/0.49.0/src/cargo/sources/config.rs:102:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/config.rs:135:67 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/sources/config.rs:206:36 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo/0.49.0/src/cargo/sources/config.rs:282:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/sources/config.rs:70:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/config.rs:81:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/config.rs:97:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/sources/directory.rs:14:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/sources/directory.rs:90:56 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/sources/git/source.rs:14:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/sources/git/source.rs:25:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/git/source.rs:49:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/sources/git/source.rs:53:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/git/source.rs:69:20 clippy::comparison_to_empty "comparison to empty slice" -cargo/0.49.0/src/cargo/sources/git/utils.rs:1025:19 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/sources/git/utils.rs:1158:9 clippy::manual_strip "stripping a suffix manually" -cargo/0.49.0/src/cargo/sources/git/utils.rs:176:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/sources/git/utils.rs:180:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/sources/git/utils.rs:184:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/git/utils.rs:188:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/git/utils.rs:242:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/git/utils.rs:253:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/git/utils.rs:262:13 clippy::if_not_else "unnecessary boolean `not` operation" -cargo/0.49.0/src/cargo/sources/git/utils.rs:289:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/git/utils.rs:294:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/sources/git/utils.rs:298:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/git/utils.rs:308:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/git/utils.rs:472:9 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" -cargo/0.49.0/src/cargo/sources/git/utils.rs:489:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/sources/git/utils.rs:503:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/sources/git/utils.rs:528:28 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/sources/git/utils.rs:537:21 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" -cargo/0.49.0/src/cargo/sources/git/utils.rs:588:1 clippy::too_many_lines "this function has too many lines (135/100)" -cargo/0.49.0/src/cargo/sources/git/utils.rs:758:9 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo/0.49.0/src/cargo/sources/git/utils.rs:858:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/path.rs:129:44 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/sources/path.rs:143:44 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/sources/path.rs:15:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/sources/path.rs:282:50 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/sources/path.rs:313:21 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/sources/path.rs:314:21 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/sources/path.rs:319:21 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/sources/path.rs:339:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/sources/path.rs:339:9 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -cargo/0.49.0/src/cargo/sources/path.rs:380:9 clippy::unused_self "unused `self` argument" -cargo/0.49.0/src/cargo/sources/path.rs:419:50 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/sources/path.rs:429:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/path.rs:460:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/sources/path.rs:473:43 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/sources/path.rs:482:43 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/sources/path.rs:63:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/path.rs:77:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/path.rs:98:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/registry/index.rs:117:23 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo/0.49.0/src/cargo/sources/registry/index.rs:121:70 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo/0.49.0/src/cargo/sources/registry/index.rs:167:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/sources/registry/index.rs:215:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/sources/registry/index.rs:324:23 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/sources/registry/index.rs:393:25 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" -cargo/0.49.0/src/cargo/sources/registry/index.rs:468:40 clippy::doc_markdown "you should put `SourceId` between ticks in the documentation" -cargo/0.49.0/src/cargo/sources/registry/index.rs:590:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/sources/registry/index.rs:648:17 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/sources/registry/index.rs:736:1 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -cargo/0.49.0/src/cargo/sources/registry/index.rs:95:37 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -cargo/0.49.0/src/cargo/sources/registry/local.rs:12:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/sources/registry/mod.rs:192:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/sources/registry/mod.rs:203:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/sources/registry/mod.rs:229:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/sources/registry/mod.rs:372:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/sources/registry/mod.rs:373:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/registry/mod.rs:375:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/registry/mod.rs:381:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/registry/mod.rs:382:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/registry/mod.rs:383:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/registry/mod.rs:384:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/registry/mod.rs:452:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/registry/mod.rs:582:20 clippy::redundant_else "redundant else block" -cargo/0.49.0/src/cargo/sources/registry/mod.rs:621:9 clippy::if_not_else "unnecessary `!=` operation" -cargo/0.49.0/src/cargo/sources/registry/remote.rs:139:17 clippy::unused_self "unused `self` argument" -cargo/0.49.0/src/cargo/sources/registry/remote.rs:32:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/sources/registry/remote.rs:72:13 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/sources/replaced.rs:12:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/sources/replaced.rs:5:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/util/canonical_url.rs:19:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/canonical_url.rs:65:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/command_prelude.rs:218:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/command_prelude.rs:222:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/command_prelude.rs:234:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/command_prelude.rs:249:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/command_prelude.rs:264:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/command_prelude.rs:279:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/command_prelude.rs:298:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/command_prelude.rs:320:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/command_prelude.rs:328:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/command_prelude.rs:352:13 clippy::if_not_else "unnecessary boolean `not` operation" -cargo/0.49.0/src/cargo/util/command_prelude.rs:363:13 clippy::if_not_else "unnecessary boolean `not` operation" -cargo/0.49.0/src/cargo/util/command_prelude.rs:378:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/command_prelude.rs:387:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/command_prelude.rs:387:5 clippy::too_many_lines "this function has too many lines (104/100)" -cargo/0.49.0/src/cargo/util/command_prelude.rs:39:20 clippy::doc_markdown "you should put `arg_package_spec` between ticks in the documentation" -cargo/0.49.0/src/cargo/util/command_prelude.rs:504:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/command_prelude.rs:516:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/command_prelude.rs:530:40 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/util/command_prelude.rs:531:43 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/util/command_prelude.rs:536:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/command_prelude.rs:556:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/command_prelude.rs:575:49 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/util/command_prelude.rs:580:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/command_prelude.rs:631:18 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/util/command_prelude.rs:638:18 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/util/command_prelude.rs:647:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/command_prelude.rs:651:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/command_prelude.rs:662:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/command_prelude.rs:665:51 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/util/config/de.rs:420:16 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo/0.49.0/src/cargo/util/config/de.rs:46:25 clippy::doc_markdown "you should put `CV::List` between ticks in the documentation" -cargo/0.49.0/src/cargo/util/config/de.rs:47:24 clippy::doc_markdown "you should put `ConfigSeqAccess` between ticks in the documentation" -cargo/0.49.0/src/cargo/util/config/de.rs:527:53 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo/0.49.0/src/cargo/util/config/de.rs:530:53 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo/0.49.0/src/cargo/util/config/de.rs:532:68 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo/0.49.0/src/cargo/util/config/key.rs:11:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/util/config/key.rs:69:9 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo/0.49.0/src/cargo/util/config/mod.rs:100:71 clippy::doc_markdown "you should put `OptValue` between ticks in the documentation" -cargo/0.49.0/src/cargo/util/config/mod.rs:100:71 clippy::doc_markdown "you should put `OptValue` between ticks in the documentation" -cargo/0.49.0/src/cargo/util/config/mod.rs:100:71 clippy::doc_markdown "you should put `OptValue` between ticks in the documentation" -cargo/0.49.0/src/cargo/util/config/mod.rs:1049:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:1064:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:1090:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:1166:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:1179:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:1184:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:1189:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:1203:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:1211:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:1216:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:1225:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:1229:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:124:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo/0.49.0/src/cargo/util/config/mod.rs:1254:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:1279:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:1281:9 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/util/config/mod.rs:1323:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/util/config/mod.rs:1339:39 clippy::unused_self "unused `self` argument" -cargo/0.49.0/src/cargo/util/config/mod.rs:1344:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/util/config/mod.rs:1420:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/util/config/mod.rs:1553:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:1560:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:1567:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:1574:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:1581:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:1588:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/config/mod.rs:1598:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/config/mod.rs:1619:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/config/mod.rs:1623:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:1623:64 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo/0.49.0/src/cargo/util/config/mod.rs:1649:9 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" -cargo/0.49.0/src/cargo/util/config/mod.rs:1699:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/util/config/mod.rs:1730:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/util/config/mod.rs:1757:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/util/config/mod.rs:1770:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/util/config/mod.rs:1778:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/util/config/mod.rs:1804:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/util/config/mod.rs:1896:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/config/mod.rs:1901:5 clippy::doc_markdown "you should put `StringList` between ticks in the documentation" -cargo/0.49.0/src/cargo/util/config/mod.rs:214:13 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" -cargo/0.49.0/src/cargo/util/config/mod.rs:259:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:298:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:311:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:318:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:353:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:401:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:411:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:419:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:431:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:449:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:454:16 clippy::option_if_let_else "use Option::map_or instead of an if let/else" -cargo/0.49.0/src/cargo/util/config/mod.rs:547:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:556:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:582:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:595:20 clippy::doc_markdown "you should put `StringList` between ticks in the documentation" -cargo/0.49.0/src/cargo/util/config/mod.rs:689:20 clippy::unused_self "unused `self` argument" -cargo/0.49.0/src/cargo/util/config/mod.rs:699:5 clippy::fn_params_excessive_bools "more than 3 bools in function parameters" -cargo/0.49.0/src/cargo/util/config/mod.rs:699:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:719:58 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/util/config/mod.rs:816:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:875:36 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/util/config/mod.rs:876:37 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/util/config/path.rs:10:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/util/config/path.rs:14:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/config/path.rs:48:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/util/config/target.rs:12:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/util/config/target.rs:24:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/util/config/value.rs:29:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/util/config/value.rs:80:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/config/value.rs:81:9 clippy::match_like_matches_macro "match expression looks like `matches!` macro" -cargo/0.49.0/src/cargo/util/cpu.rs:11:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/cpu.rs:22:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/cpu.rs:82:25 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -cargo/0.49.0/src/cargo/util/cpu.rs:82:9 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -cargo/0.49.0/src/cargo/util/dependency_queue.rs:109:27 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/util/dependency_queue.rs:136:20 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" -cargo/0.49.0/src/cargo/util/dependency_queue.rs:151:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/dependency_queue.rs:156:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/dependency_queue.rs:46:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/dependency_queue.rs:91:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/util/diagnostic_server.rs:218:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/util/diagnostic_server.rs:230:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/diagnostic_server.rs:242:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/diagnostic_server.rs:58:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/diagnostic_server.rs:96:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/diagnostic_server.rs:96:5 clippy::too_many_lines "this function has too many lines (110/100)" -cargo/0.49.0/src/cargo/util/diagnostic_server.rs:99:21 clippy::shadow_unrelated "`msg` is being shadowed" -cargo/0.49.0/src/cargo/util/errors.rs:101:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/errors.rs:143:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/errors.rs:150:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/errors.rs:15:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/errors.rs:237:5 clippy::pub_enum_variant_names "variant name ends with the enum's name" -cargo/0.49.0/src/cargo/util/errors.rs:245:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/errors.rs:321:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/errors.rs:328:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/errors.rs:356:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/errors.rs:391:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/util/errors.rs:392:13 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/cargo/util/errors.rs:465:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/errors.rs:473:5 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" -cargo/0.49.0/src/cargo/util/errors.rs:66:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/flock.rs:115:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/flock.rs:11:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/cargo/util/flock.rs:134:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/flock.rs:142:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/flock.rs:150:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/flock.rs:156:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/flock.rs:170:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/flock.rs:192:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/flock.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/flock.rs:321:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/util/flock.rs:335:23 clippy::cast_possible_truncation "casting `i64` to `u32` may truncate the value" -cargo/0.49.0/src/cargo/util/flock.rs:335:23 clippy::cast_sign_loss "casting `i64` to `u32` may lose the sign of the value" -cargo/0.49.0/src/cargo/util/flock.rs:335:44 clippy::cast_possible_truncation "casting `i64` to `u32` may truncate the value" -cargo/0.49.0/src/cargo/util/flock.rs:379:35 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/util/flock.rs:37:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/flock.rs:43:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/flock.rs:52:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/graph.rs:10:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/graph.rs:115:13 clippy::find_map "called `find(..).map(..)` on an `Iterator`" -cargo/0.49.0/src/cargo/util/graph.rs:41:51 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/util/graph.rs:45:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/graph.rs:95:13 clippy::find_map "called `find(..).map(..)` on an `Iterator`" -cargo/0.49.0/src/cargo/util/hasher.rs:12:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/hasher.rs:9:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/util/hex.rs:10:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" -cargo/0.49.0/src/cargo/util/hex.rs:11:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" -cargo/0.49.0/src/cargo/util/hex.rs:12:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" -cargo/0.49.0/src/cargo/util/hex.rs:13:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" -cargo/0.49.0/src/cargo/util/hex.rs:14:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" -cargo/0.49.0/src/cargo/util/hex.rs:15:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" -cargo/0.49.0/src/cargo/util/hex.rs:25:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/hex.rs:6:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/util/hex.rs:6:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/hex.rs:8:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" -cargo/0.49.0/src/cargo/util/hex.rs:9:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" -cargo/0.49.0/src/cargo/util/important_paths.rs:23:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/important_paths.rs:6:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/interning.rs:66:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/interning.rs:77:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/into_url.rs:10:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/into_url_with_base.rs:9:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/job.rs:20:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/lev_distance.rs:3:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/lockserver.rs:111:32 clippy::redundant_else "redundant else block" -cargo/0.49.0/src/cargo/util/lockserver.rs:158:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/lockserver.rs:46:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/lockserver.rs:58:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/lockserver.rs:62:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/mod.rs:68:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/mod.rs:79:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/network.rs:12:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/network.rs:19:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/network.rs:84:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/paths.rs:109:12 clippy::redundant_else "redundant else block" -cargo/0.49.0/src/cargo/util/paths.rs:114:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/paths.rs:121:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/paths.rs:125:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/paths.rs:130:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/paths.rs:14:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/paths.rs:14:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/util/paths.rs:151:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/paths.rs:167:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/paths.rs:173:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/paths.rs:178:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/paths.rs:185:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/paths.rs:199:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/paths.rs:215:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/paths.rs:228:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/paths.rs:251:9 clippy::option_if_let_else "use Option::map_or instead of an if let/else" -cargo/0.49.0/src/cargo/util/paths.rs:267:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/paths.rs:276:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/paths.rs:29:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/paths.rs:303:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/paths.rs:312:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/paths.rs:346:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/paths.rs:415:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/paths.rs:445:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/paths.rs:459:45 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/util/paths.rs:469:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/paths.rs:54:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/paths.rs:61:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/paths.rs:63:19 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" -cargo/0.49.0/src/cargo/util/paths.rs:88:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/paths.rs:93:31 clippy::comparison_to_empty "comparison to empty slice" -cargo/0.49.0/src/cargo/util/process_builder.rs:106:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/process_builder.rs:111:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/process_builder.rs:122:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/process_builder.rs:132:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/process_builder.rs:152:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/process_builder.rs:185:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/process_builder.rs:190:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/process_builder.rs:218:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/process_builder.rs:307:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/process_builder.rs:343:39 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo/0.49.0/src/cargo/util/progress.rs:122:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/progress.rs:136:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/progress.rs:15:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/util/progress.rs:249:19 clippy::cast_precision_loss "casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -cargo/0.49.0/src/cargo/util/progress.rs:249:34 clippy::cast_precision_loss "casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -cargo/0.49.0/src/cargo/util/progress.rs:250:19 clippy::if_not_else "unnecessary boolean `not` operation" -cargo/0.49.0/src/cargo/util/progress.rs:263:22 clippy::cast_precision_loss "casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -cargo/0.49.0/src/cargo/util/progress.rs:264:22 clippy::cast_possible_truncation "casting `f64` to `usize` may truncate the value" -cargo/0.49.0/src/cargo/util/progress.rs:264:22 clippy::cast_sign_loss "casting `f64` to `usize` may lose the sign of the value" -cargo/0.49.0/src/cargo/util/progress.rs:269:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo/0.49.0/src/cargo/util/progress.rs:272:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo/0.49.0/src/cargo/util/progress.rs:274:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo/0.49.0/src/cargo/util/progress.rs:280:13 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo/0.49.0/src/cargo/util/progress.rs:282:9 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo/0.49.0/src/cargo/util/progress.rs:89:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/progress.rs:97:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/queue.rs:25:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/read2.rs:11:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/read2.rs:31:17 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/util/restricted_names.rs:13:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/restricted_names.rs:26:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/restricted_names.rs:35:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/restricted_names.rs:45:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/restricted_names.rs:87:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/restricted_names.rs:89:21 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/util/restricted_names.rs:8:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/rustc.rs:103:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/rustc.rs:114:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" -cargo/0.49.0/src/cargo/util/rustc.rs:115:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" -cargo/0.49.0/src/cargo/util/rustc.rs:162:17 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/util/rustc.rs:39:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/rustc.rs:55:13 clippy::find_map "called `find(..).map(..)` on an `Iterator`" -cargo/0.49.0/src/cargo/util/sha256.rs:10:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/sha256.rs:20:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/sha256.rs:31:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/sha256.rs:40:24 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo/0.49.0/src/cargo/util/to_semver.rs:5:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/toml/mod.rs:1005:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/toml/mod.rs:1005:5 clippy::too_many_lines "this function has too many lines (282/100)" -cargo/0.49.0/src/cargo/util/toml/mod.rs:1094:36 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/util/toml/mod.rs:1121:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/util/toml/mod.rs:1197:32 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" -cargo/0.49.0/src/cargo/util/toml/mod.rs:124:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/toml/mod.rs:1504:9 clippy::unused_self "unused `self` argument" -cargo/0.49.0/src/cargo/util/toml/mod.rs:1526:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/toml/mod.rs:1582:19 clippy::default_trait_access "calling `util::toml::DetailedTomlDependency::default()` is more clear than this expression" -cargo/0.49.0/src/cargo/util/toml/mod.rs:1598:5 clippy::too_many_lines "this function has too many lines (153/100)" -cargo/0.49.0/src/cargo/util/toml/mod.rs:1687:33 clippy::unnecessary_lazy_evaluations "unnecessary closure used to substitute value for `Option::None`" -cargo/0.49.0/src/cargo/util/toml/mod.rs:178:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/util/toml/mod.rs:248:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/util/toml/mod.rs:274:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/util/toml/mod.rs:277:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/toml/mod.rs:281:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/toml/mod.rs:285:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/toml/mod.rs:294:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/util/toml/mod.rs:31:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/toml/mod.rs:381:35 clippy::cast_possible_truncation "casting `i64` to `u32` may truncate the value" -cargo/0.49.0/src/cargo/util/toml/mod.rs:381:35 clippy::cast_sign_loss "casting `i64` to `u32` may lose the sign of the value" -cargo/0.49.0/src/cargo/util/toml/mod.rs:388:35 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" -cargo/0.49.0/src/cargo/util/toml/mod.rs:398:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/util/toml/mod.rs:450:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/toml/mod.rs:536:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/toml/mod.rs:783:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/util/toml/mod.rs:824:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/util/toml/mod.rs:834:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/toml/mod.rs:83:42 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/util/toml/mod.rs:852:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/toml/mod.rs:852:5 clippy::too_many_lines "this function has too many lines (138/100)" -cargo/0.49.0/src/cargo/util/toml/mod.rs:962:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/util/toml/mod.rs:971:24 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" -cargo/0.49.0/src/cargo/util/toml/mod.rs:979:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/util/toml/mod.rs:98:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/util/toml/mod.rs:999:23 clippy::default_trait_access "calling `util::toml::DetailedTomlDependency::default()` is more clear than this expression" -cargo/0.49.0/src/cargo/util/toml/targets.rs:112:27 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/util/toml/targets.rs:325:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/util/toml/targets.rs:586:21 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/util/toml/targets.rs:593:42 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/util/toml/targets.rs:605:19 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/util/toml/targets.rs:612:42 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/util/toml/targets.rs:756:36 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/util/toml/targets.rs:810:24 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" -cargo/0.49.0/src/cargo/util/vcs.rs:10:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/vcs.rs:33:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/vcs.rs:37:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/vcs.rs:43:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/vcs.rs:47:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/vcs.rs:59:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/vcs.rs:66:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/workspace.rs:52:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/workspace.rs:56:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/workspace.rs:60:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/workspace.rs:64:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron/0.6.1/src/error.rs:24:1 clippy::module_name_repetitions "item name ends with its containing module's name" -iron/0.6.1/src/iron.rs:105:13 clippy::redundant_field_names "redundant field names in struct initialization" -iron/0.6.1/src/iron.rs:119:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron/0.6.1/src/iron.rs:133:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron/0.6.1/src/iron.rs:143:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron/0.6.1/src/iron.rs:149:13 clippy::redundant_field_names "redundant field names in struct initialization" -iron/0.6.1/src/iron.rs:167:49 clippy::similar_names "binding's name is too similar to existing binding" -iron/0.6.1/src/iron.rs:80:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron/0.6.1/src/iron.rs:85:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron/0.6.1/src/iron.rs:90:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron/0.6.1/src/lib.rs:1:null clippy::cargo_common_metadata "package `iron` is missing `package.categories` metadata" -iron/0.6.1/src/lib.rs:1:null clippy::cargo_common_metadata "package `iron` is missing `package.keywords` metadata" -iron/0.6.1/src/lib.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `log`: 0.3.9, 0.4.8" -iron/0.6.1/src/middleware/mod.rs:137:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron/0.6.1/src/middleware/mod.rs:150:1 clippy::module_name_repetitions "item name ends with its containing module's name" -iron/0.6.1/src/middleware/mod.rs:152:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron/0.6.1/src/middleware/mod.rs:159:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron/0.6.1/src/middleware/mod.rs:171:1 clippy::module_name_repetitions "item name ends with its containing module's name" -iron/0.6.1/src/middleware/mod.rs:173:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron/0.6.1/src/middleware/mod.rs:182:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron/0.6.1/src/middleware/mod.rs:192:1 clippy::module_name_repetitions "item name ends with its containing module's name" -iron/0.6.1/src/middleware/mod.rs:217:25 clippy::doc_markdown "you should put `ChainBuilder` between ticks in the documentation" -iron/0.6.1/src/middleware/mod.rs:328:20 clippy::similar_names "binding's name is too similar to existing binding" -iron/0.6.1/src/middleware/mod.rs:360:16 clippy::similar_names "binding's name is too similar to existing binding" -iron/0.6.1/src/middleware/mod.rs:368:33 clippy::similar_names "binding's name is too similar to existing binding" -iron/0.6.1/src/middleware/mod.rs:428:40 clippy::similar_names "binding's name is too similar to existing binding" -iron/0.6.1/src/middleware/mod.rs:434:40 clippy::similar_names "binding's name is too similar to existing binding" -iron/0.6.1/src/middleware/mod.rs:444:40 clippy::similar_names "binding's name is too similar to existing binding" -iron/0.6.1/src/modifiers.rs:132:14 clippy::expect_fun_call "use of `expect` followed by a function call" -iron/0.6.1/src/request/mod.rs:113:24 clippy::similar_names "binding's name is too similar to existing binding" -iron/0.6.1/src/request/mod.rs:121:13 clippy::redundant_field_names "redundant field names in struct initialization" -iron/0.6.1/src/request/mod.rs:123:13 clippy::redundant_field_names "redundant field names in struct initialization" -iron/0.6.1/src/request/mod.rs:124:13 clippy::redundant_field_names "redundant field names in struct initialization" -iron/0.6.1/src/request/mod.rs:126:13 clippy::redundant_field_names "redundant field names in struct initialization" -iron/0.6.1/src/request/mod.rs:128:13 clippy::redundant_field_names "redundant field names in struct initialization" -iron/0.6.1/src/request/mod.rs:153:69 clippy::doc_markdown "you should put `HttpReader` between ticks in the documentation" -iron/0.6.1/src/request/mod.rs:154:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron/0.6.1/src/request/mod.rs:32:1 clippy::manual_non_exhaustive "this seems like a manual implementation of the non-exhaustive pattern" -iron/0.6.1/src/request/mod.rs:75:34 clippy::doc_markdown "you should put `HttpRequest` between ticks in the documentation" -iron/0.6.1/src/request/mod.rs:77:39 clippy::doc_markdown "you should put `HttpRequest` between ticks in the documentation" -iron/0.6.1/src/request/mod.rs:78:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron/0.6.1/src/request/mod.rs:82:13 clippy::similar_names "binding's name is too similar to existing binding" -iron/0.6.1/src/request/mod.rs:83:29 clippy::similar_names "binding's name is too similar to existing binding" -iron/0.6.1/src/request/mod.rs:85:24 clippy::similar_names "binding's name is too similar to existing binding" -iron/0.6.1/src/request/url.rs:109:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron/0.6.1/src/request/url.rs:117:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron/0.6.1/src/request/url.rs:129:1 clippy::from_over_into "an implementation of `From` is preferred since it gives you `Into<_>` for free where the reverse isn't true" -iron/0.6.1/src/request/url.rs:21:14 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" -iron/0.6.1/src/request/url.rs:22:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron/0.6.1/src/request/url.rs:31:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron/0.6.1/src/request/url.rs:47:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron/0.6.1/src/request/url.rs:52:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron/0.6.1/src/request/url.rs:57:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron/0.6.1/src/request/url.rs:63:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron/0.6.1/src/request/url.rs:73:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron/0.6.1/src/request/url.rs:83:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron/0.6.1/src/request/url.rs:96:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron/0.6.1/src/response.rs:121:19 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -iron/0.6.1/src/response.rs:125:43 clippy::redundant_closure_for_method_calls "redundant closure found" -iron/0.6.1/src/response.rs:139:41 clippy::redundant_closure_for_method_calls "redundant closure found" -iron/0.6.1/src/response.rs:24:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron/0.6.1/src/response.rs:95:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron/0.6.1/src/response.rs:95:5 clippy::new_without_default "you should consider adding a `Default` implementation for `response::Response`" -libc/0.2.81/build.rs:114:19 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" -libc/0.2.81/build.rs:124:5 clippy::question_mark "this block may be rewritten with the `?` operator" -libc/0.2.81/build.rs:133:5 clippy::question_mark "this block may be rewritten with the `?` operator" -libc/0.2.81/src/macros.rs:243:17 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" -libc/0.2.81/src/macros.rs:243:17 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" -libc/0.2.81/src/macros.rs:243:17 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" -libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:428:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:429:30 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:431:30 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:432:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:433:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:434:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:595:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:596:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:597:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:622:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:673:34 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:696:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:697:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:698:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:699:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:712:34 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:721:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:722:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:723:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:751:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:752:30 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:753:30 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:754:30 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:755:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:756:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:757:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:758:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:759:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:760:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:768:30 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:769:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:771:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:772:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:773:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:774:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:775:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:776:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:777:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:778:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:779:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:780:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:781:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:782:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:783:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:784:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:785:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:786:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:787:30 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:788:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:789:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:790:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:791:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:792:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:794:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:795:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:796:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:797:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:798:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:799:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:800:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:801:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:803:27 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:804:28 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:805:28 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:806:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:807:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:808:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:809:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:810:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:811:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:812:30 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:813:30 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:814:30 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:815:30 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:816:30 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:817:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:818:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:821:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:822:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:823:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:824:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:825:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:826:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:827:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:828:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:829:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:830:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:831:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:832:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:833:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:834:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:835:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:836:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:841:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:842:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:843:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:844:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:1120:38 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:178:34 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:291:5 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:291:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:302:5 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:302:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:355:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:355:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:359:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:359:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:363:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:363:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:367:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:367:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:371:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:371:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:534:36 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:645:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:727:40 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:728:40 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:729:39 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:731:44 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:732:36 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:733:41 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:734:43 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:735:42 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:736:40 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:737:36 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:738:37 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:741:39 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:742:40 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:743:40 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:744:40 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:745:40 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:746:43 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:747:42 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:748:40 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:749:39 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:750:41 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:751:41 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:752:43 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:753:42 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:755:42 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:756:41 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:757:41 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:758:39 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:759:39 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:761:41 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:762:44 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:763:45 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:764:40 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:765:40 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:766:40 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:767:44 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:768:44 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:769:39 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:770:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:771:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:772:37 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:773:39 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:774:45 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:775:41 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:776:39 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:803:34 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:841:30 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:842:37 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:982:40 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:984:46 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1209:36 clippy::cast_possible_truncation "casting `i32` to `i16` may truncate the value" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1210:36 clippy::cast_possible_truncation "casting `i32` to `i16` may truncate the value" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1235:39 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1236:41 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1274:42 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1324:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1333:37 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1334:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1346:34 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1346:34 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1346:34 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1347:37 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1347:37 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1347:37 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1348:36 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1348:36 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1348:36 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1349:37 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1349:37 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1349:37 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1350:35 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1350:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1350:35 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1351:36 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1351:36 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1351:36 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1352:31 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1352:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1352:31 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1419:36 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1420:36 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1421:36 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1422:36 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1423:36 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1490:37 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1561:46 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1562:45 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1567:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1568:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1586:26 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1587:34 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1588:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1589:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1897:38 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1898:51 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1900:39 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1969:34 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1970:34 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1971:36 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1972:36 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1973:36 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1974:37 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1975:37 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1976:36 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1977:36 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1978:39 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1979:39 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1980:39 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1981:39 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1982:39 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1983:39 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1984:38 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1985:38 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1986:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1987:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1988:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1989:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1990:38 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1991:37 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1992:37 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1993:38 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1994:37 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1995:37 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1996:37 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1997:37 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1998:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1999:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2000:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2001:34 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2002:34 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2003:34 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2004:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2005:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2032:30 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2033:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2034:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2035:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2036:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2037:28 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2038:27 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2039:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2041:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2042:28 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2043:27 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2044:34 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2045:27 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2046:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2048:28 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2049:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2050:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2051:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2052:26 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2053:36 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2318:42 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2321:38 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2331:39 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2487:42 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2488:42 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2489:43 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2490:43 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2491:43 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2493:47 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2494:44 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2495:46 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2496:47 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2497:49 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2498:48 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2499:50 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2500:45 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2572:9 clippy::needless_return "unneeded `return` statement" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2578:20 clippy::zero_ptr "`0 as *mut _` detected" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2588:13 clippy::zero_ptr "`0 as *mut _` detected" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2596:52 clippy::used_underscore_binding "used binding `_dummy` which is prefixed with an underscore. A leading underscore signals that a binding will not be used." -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2597:11 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2601:21 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2611:9 clippy::unused_unit "unneeded unit expression" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2619:9 clippy::unused_unit "unneeded unit expression" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2634:9 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2647:25 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2648:25 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2649:9 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2654:18 clippy::identity_op "the operation is ineffective. Consider reducing it to `(dev & 0x00000000000000ff)`" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2654:25 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2655:25 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2656:9 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2660:21 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2661:21 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2663:25 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2664:25 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2665:16 clippy::identity_op "the operation is ineffective. Consider reducing it to `(minor & 0x000000ff)`" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2665:25 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2666:25 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:40:1 clippy::empty_enum "enum with no variants" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:954:34 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1000:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1001:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1002:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1016:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1017:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1018:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1019:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1020:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1029:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1030:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1031:30 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1032:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1033:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1034:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1035:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1041:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1042:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1043:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1044:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1045:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1046:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1047:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1048:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1049:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1050:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1051:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1053:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1054:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1055:30 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1056:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1057:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1058:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1059:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1060:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1073:42 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1074:43 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1075:37 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1076:37 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1077:41 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1078:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1079:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1080:36 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1081:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1082:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1083:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1084:38 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1086:30 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1087:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1089:30 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1090:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1091:30 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1094:40 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1095:37 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1096:41 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1097:40 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1098:39 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1099:34 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1100:36 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1101:38 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1102:37 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1105:44 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1106:41 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1107:42 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1108:42 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1109:41 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1110:46 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1111:41 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1112:44 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1113:40 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1114:47 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1115:36 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1126:34 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1127:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1128:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1179:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1180:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1218:27 clippy::identity_op "the operation is ineffective. Consider reducing it to `IPOPT_CONTROL`" -libc/0.2.81/src/unix/linux_like/mod.rs:1314:9 clippy::precedence "operator precedence can trip the unwary" -libc/0.2.81/src/unix/linux_like/mod.rs:1323:13 clippy::zero_ptr "`0 as *mut _` detected" -libc/0.2.81/src/unix/linux_like/mod.rs:1332:9 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -libc/0.2.81/src/unix/linux_like/mod.rs:1337:9 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -libc/0.2.81/src/unix/linux_like/mod.rs:1341:18 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" -libc/0.2.81/src/unix/linux_like/mod.rs:1344:9 clippy::needless_return "unneeded `return` statement" -libc/0.2.81/src/unix/linux_like/mod.rs:1348:18 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" -libc/0.2.81/src/unix/linux_like/mod.rs:1350:9 clippy::needless_return "unneeded `return` statement" -libc/0.2.81/src/unix/linux_like/mod.rs:1354:18 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" -libc/0.2.81/src/unix/linux_like/mod.rs:1357:9 clippy::needless_return "unneeded `return` statement" -libc/0.2.81/src/unix/linux_like/mod.rs:1361:21 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" -libc/0.2.81/src/unix/linux_like/mod.rs:1381:9 clippy::cast_possible_truncation "casting `i32` to `i8` may truncate the value" -libc/0.2.81/src/unix/linux_like/mod.rs:1389:9 clippy::verbose_bit_mask "bit mask could be simplified with a call to `trailing_zeros`" -libc/0.2.81/src/unix/linux_like/mod.rs:446:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:591:36 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:592:38 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:593:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:594:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:595:34 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:596:36 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:597:37 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:598:37 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:599:39 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:600:34 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:601:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:602:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:607:37 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:608:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:764:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:765:39 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:991:30 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:9:1 clippy::empty_enum "enum with no variants" -libc/0.2.81/src/unix/mod.rs:198:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/mod.rs:199:28 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/mod.rs:201:35 clippy::unnecessary_cast "casting integer literal to `usize` is unnecessary" -libc/0.2.81/src/unix/mod.rs:202:35 clippy::unnecessary_cast "casting integer literal to `usize` is unnecessary" -libc/0.2.81/src/unix/mod.rs:282:40 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/mod.rs:284:41 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/mod.rs:285:36 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/mod.rs:34:1 clippy::empty_enum "enum with no variants" -libc/0.2.81/src/unix/mod.rs:386:1 clippy::empty_enum "enum with no variants" -libc/0.2.81/src/unix/mod.rs:394:1 clippy::empty_enum "enum with no variants" -log/0.4.11/src/lib.rs:1047:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:1053:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:1059:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:1093:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:1093:5 clippy::new_without_default "you should consider adding a `Default` implementation for `MetadataBuilder<'a>`" -log/0.4.11/src/lib.rs:1118:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:1177:1 clippy::inline_always "you have declared `#[inline(always)]` on `max_level`. This is usually a bad idea" -log/0.4.11/src/lib.rs:1178:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:1306:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -log/0.4.11/src/lib.rs:1358:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:1359:5 clippy::if_not_else "unnecessary `!=` operation" -log/0.4.11/src/lib.rs:1407:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:329:27 clippy::derive_hash_xor_eq "you are deriving `Hash` but have implemented `PartialEq` explicitly" -log/0.4.11/src/lib.rs:356:1 clippy::expl_impl_clone_on_copy "you are implementing `Clone` explicitly on a `Copy` type" -log/0.4.11/src/lib.rs:448:12 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" -log/0.4.11/src/lib.rs:468:13 clippy::filter_map "called `filter(..).map(..)` on an `Iterator`" -log/0.4.11/src/lib.rs:500:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:506:28 clippy::trivially_copy_pass_by_ref "this argument (8 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -log/0.4.11/src/lib.rs:506:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:520:27 clippy::derive_hash_xor_eq "you are deriving `Hash` but have implemented `PartialEq` explicitly" -log/0.4.11/src/lib.rs:538:1 clippy::expl_impl_clone_on_copy "you are implementing `Clone` explicitly on a `Copy` type" -log/0.4.11/src/lib.rs:653:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:661:21 clippy::trivially_copy_pass_by_ref "this argument (8 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -log/0.4.11/src/lib.rs:661:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:677:44 clippy::match_same_arms "this `match` has identical arm bodies" -log/0.4.11/src/lib.rs:758:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:764:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:770:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:776:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:782:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:788:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:794:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:803:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:809:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:818:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:908:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:908:5 clippy::new_without_default "you should consider adding a `Default` implementation for `RecordBuilder<'a>`" -log/0.4.11/src/lib.rs:995:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/detection.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -proc-macro2/1.0.24/src/fallback.rs:108:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" -proc-macro2/1.0.24/src/fallback.rs:269:20 clippy::unused_self "unused `self` argument" -proc-macro2/1.0.24/src/fallback.rs:430:24 clippy::trivially_copy_pass_by_ref "this argument (0 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -proc-macro2/1.0.24/src/fallback.rs:437:23 clippy::trivially_copy_pass_by_ref "this argument (0 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -proc-macro2/1.0.24/src/fallback.rs:437:23 clippy::unused_self "unused `self` argument" -proc-macro2/1.0.24/src/fallback.rs:471:17 clippy::trivially_copy_pass_by_ref "this argument (0 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -proc-macro2/1.0.24/src/fallback.rs:471:17 clippy::unused_self "unused `self` argument" -proc-macro2/1.0.24/src/fallback.rs:654:5 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" -proc-macro2/1.0.24/src/fallback.rs:655:12 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" -proc-macro2/1.0.24/src/fallback.rs:661:5 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" -proc-macro2/1.0.24/src/fallback.rs:662:12 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" -proc-macro2/1.0.24/src/fallback.rs:664:12 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" -proc-macro2/1.0.24/src/fallback.rs:674:37 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" -proc-macro2/1.0.24/src/fallback.rs:678:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -proc-macro2/1.0.24/src/fallback.rs:85:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -proc-macro2/1.0.24/src/fallback.rs:882:43 clippy::unused_self "unused `self` argument" -proc-macro2/1.0.24/src/lib.rs:1017:9 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:1081:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:1099:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:1117:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:1135:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:1141:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:1146:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:1151:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:1156:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:152:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:157:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:373:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:383:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:397:24 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -proc-macro2/1.0.24/src/lib.rs:397:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:403:23 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -proc-macro2/1.0.24/src/lib.rs:403:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:418:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:425:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:464:17 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -proc-macro2/1.0.24/src/lib.rs:500:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:626:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:633:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:641:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:652:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:662:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:672:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:734:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:743:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:752:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:757:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:788:19 clippy::doc_markdown "you should put `XID_Start` between ticks in the documentation" -proc-macro2/1.0.24/src/lib.rs:788:69 clippy::doc_markdown "you should put `XID_Continue` between ticks in the documentation" -proc-macro2/1.0.24/src/lib.rs:891:36 clippy::doc_markdown "you should put `syn::parse_str` between ticks in the documentation" -proc-macro2/1.0.24/src/lib.rs:894:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:911:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:996:9 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/parse.rs:552:5 clippy::while_let_on_iterator "this loop could be written as a `for` loop" -proc-macro2/1.0.24/src/parse.rs:584:21 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" -proc-macro2/1.0.24/src/parse.rs:602:20 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" -proc-macro2/1.0.24/src/parse.rs:696:29 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" -proc-macro2/1.0.24/src/parse.rs:702:34 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" -proc-macro2/1.0.24/src/parse.rs:708:34 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" -proc-macro2/1.0.24/src/parse.rs:803:15 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" -proc-macro2/1.0.24/src/parse.rs:808:15 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" -proc-macro2/1.0.24/src/wrapper.rs:415:24 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -proc-macro2/1.0.24/src/wrapper.rs:429:23 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -proc-macro2/1.0.24/src/wrapper.rs:492:17 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -quote/1.0.7/src/ext.rs:10:1 clippy::module_name_repetitions "item name ends with its containing module's name" -quote/1.0.7/src/ext.rs:7:5 clippy::doc_markdown "you should put `TokenStream` between ticks in the documentation" -quote/1.0.7/src/ident_fragment.rs:13:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -quote/1.0.7/src/ident_fragment.rs:51:31 clippy::manual_strip "stripping a prefix manually" -quote/1.0.7/src/runtime.rs:52:5 clippy::module_name_repetitions "item name ends with its containing module's name" -quote/1.0.7/src/runtime.rs:63:5 clippy::module_name_repetitions "item name ends with its containing module's name" -quote/1.0.7/src/runtime.rs:66:33 clippy::doc_markdown "you should put `DoesNotHaveIter` between ticks in the documentation" -quote/1.0.7/src/runtime.rs:80:5 clippy::module_name_repetitions "item name ends with its containing module's name" -rand/0.7.3/src/distributions/bernoulli.rs:103:20 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" -rand/0.7.3/src/distributions/bernoulli.rs:103:20 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" -rand/0.7.3/src/distributions/bernoulli.rs:116:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -rand/0.7.3/src/distributions/bernoulli.rs:123:21 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" -rand/0.7.3/src/distributions/bernoulli.rs:123:21 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" -rand/0.7.3/src/distributions/bernoulli.rs:63:26 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand/0.7.3/src/distributions/bernoulli.rs:63:27 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -rand/0.7.3/src/distributions/bernoulli.rs:67:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand/0.7.3/src/distributions/bernoulli.rs:95:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -rand/0.7.3/src/distributions/bernoulli.rs:96:13 clippy::manual_range_contains "manual `Range::contains` implementation" -rand/0.7.3/src/distributions/binomial.rs:107:23 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand/0.7.3/src/distributions/binomial.rs:112:44 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand/0.7.3/src/distributions/binomial.rs:116:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rand/0.7.3/src/distributions/binomial.rs:150:28 clippy::redundant_else "redundant else block" -rand/0.7.3/src/distributions/binomial.rs:153:24 clippy::if_not_else "unnecessary boolean `not` operation" -rand/0.7.3/src/distributions/binomial.rs:158:28 clippy::redundant_else "redundant else block" -rand/0.7.3/src/distributions/binomial.rs:164:33 clippy::cast_sign_loss "casting `i64` to `u64` may lose the sign of the value" -rand/0.7.3/src/distributions/binomial.rs:166:28 clippy::redundant_else "redundant else block" -rand/0.7.3/src/distributions/binomial.rs:175:47 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand/0.7.3/src/distributions/binomial.rs:185:38 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand/0.7.3/src/distributions/binomial.rs:194:38 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand/0.7.3/src/distributions/binomial.rs:202:28 clippy::redundant_else "redundant else block" -rand/0.7.3/src/distributions/binomial.rs:209:25 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand/0.7.3/src/distributions/binomial.rs:221:26 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand/0.7.3/src/distributions/binomial.rs:222:26 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand/0.7.3/src/distributions/binomial.rs:223:25 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand/0.7.3/src/distributions/binomial.rs:224:25 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand/0.7.3/src/distributions/binomial.rs:226:17 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rand/0.7.3/src/distributions/binomial.rs:233:32 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand/0.7.3/src/distributions/binomial.rs:234:27 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand/0.7.3/src/distributions/binomial.rs:251:22 clippy::cast_sign_loss "casting `i64` to `u64` may lose the sign of the value" -rand/0.7.3/src/distributions/binomial.rs:255:9 clippy::if_not_else "unnecessary `!=` operation" -rand/0.7.3/src/distributions/binomial.rs:35:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/distributions/binomial.rs:45:17 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand/0.7.3/src/distributions/binomial.rs:46:5 clippy::cast_possible_truncation "casting `f64` to `i64` may truncate the value" -rand/0.7.3/src/distributions/binomial.rs:50:5 clippy::too_many_lines "this function has too many lines (143/100)" -rand/0.7.3/src/distributions/binomial.rs:76:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rand/0.7.3/src/distributions/binomial.rs:78:12 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand/0.7.3/src/distributions/binomial.rs:81:21 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand/0.7.3/src/distributions/binomial.rs:82:32 clippy::cast_possible_truncation "casting `u64` to `i32` may truncate the value" -rand/0.7.3/src/distributions/binomial.rs:88:26 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand/0.7.3/src/distributions/binomial.rs:99:21 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand/0.7.3/src/distributions/cauchy.rs:33:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/distributions/dirichlet.rs:52:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/distributions/dirichlet.rs:64:32 clippy::unseparated_literal_suffix "float type suffix should be separated by an underscore" -rand/0.7.3/src/distributions/dirichlet.rs:65:23 clippy::unseparated_literal_suffix "float type suffix should be separated by an underscore" -rand/0.7.3/src/distributions/exponential.rs:76:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/distributions/float.rs:73:1 clippy::module_name_repetitions "item name ends with its containing module's name" -rand/0.7.3/src/distributions/gamma.rs:13:5 clippy::enum_glob_use "usage of wildcard import for enum variants" -rand/0.7.3/src/distributions/gamma.rs:14:5 clippy::enum_glob_use "usage of wildcard import for enum variants" -rand/0.7.3/src/distributions/gamma.rs:189:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/distributions/gamma.rs:230:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/distributions/gamma.rs:259:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/distributions/gamma.rs:287:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/distributions/gamma.rs:90:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/distributions/integer.rs:23:9 clippy::cast_possible_truncation "casting `u32` to `u8` may truncate the value" -rand/0.7.3/src/distributions/integer.rs:30:9 clippy::cast_possible_truncation "casting `u32` to `u16` may truncate the value" -rand/0.7.3/src/distributions/integer.rs:69:9 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -rand/0.7.3/src/distributions/mod.rs:263:5 clippy::inline_always "you have declared `#[inline(always)]` on `next`. This is usually a bad idea" -rand/0.7.3/src/distributions/normal.rs:100:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/distributions/normal.rs:119:1 clippy::module_name_repetitions "item name ends with its containing module's name" -rand/0.7.3/src/distributions/normal.rs:131:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/distributions/normal.rs:31:1 clippy::module_name_repetitions "item name ends with its containing module's name" -rand/0.7.3/src/distributions/normal.rs:47:25 clippy::unseparated_literal_suffix "float type suffix should be separated by an underscore" -rand/0.7.3/src/distributions/normal.rs:48:25 clippy::unseparated_literal_suffix "float type suffix should be separated by an underscore" -rand/0.7.3/src/distributions/other.rs:89:9 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -rand/0.7.3/src/distributions/pareto.rs:32:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/distributions/poisson.rs:35:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/distributions/poisson.rs:87:30 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" -rand/0.7.3/src/distributions/poisson.rs:87:30 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" -rand/0.7.3/src/distributions/triangular.rs:32:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/distributions/uniform.rs:146:4 clippy::needless_doctest_main "needless `fn main` in doctest" -rand/0.7.3/src/distributions/uniform.rs:199:1 clippy::module_name_repetitions "item name ends with its containing module's name" -rand/0.7.3/src/distributions/uniform.rs:214:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand/0.7.3/src/distributions/uniform.rs:283:14 clippy::doc_markdown "you should put `SampleUniform` between ticks in the documentation" -rand/0.7.3/src/distributions/uniform.rs:283:46 clippy::doc_markdown "you should put `SampleUniform` between ticks in the documentation" -rand/0.7.3/src/distributions/uniform.rs:296:5 clippy::inline_always "you have declared `#[inline(always)]` on `borrow`. This is usually a bad idea" -rand/0.7.3/src/distributions/uniform.rs:304:5 clippy::inline_always "you have declared `#[inline(always)]` on `borrow`. This is usually a bad idea" -rand/0.7.3/src/distributions/uniform.rs:350:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand/0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" -rand/0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" -rand/0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" -rand/0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" -rand/0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" -rand/0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" -rand/0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" -rand/0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" -rand/0.7.3/src/distributions/uniform.rs:56:10 clippy::doc_markdown "you should put `SampleBorrow` between ticks in the documentation" -rand/0.7.3/src/distributions/uniform.rs:647:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand/0.7.3/src/distributions/uniform.rs:840:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand/0.7.3/src/distributions/uniform.rs:913:13 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" -rand/0.7.3/src/distributions/uniform.rs:943:54 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" -rand/0.7.3/src/distributions/unit_circle.rs:30:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/distributions/unit_sphere.rs:24:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand/0.7.3/src/distributions/unit_sphere.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/distributions/utils.rs:247:15 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" -rand/0.7.3/src/distributions/utils.rs:248:20 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" -rand/0.7.3/src/distributions/utils.rs:249:18 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" -rand/0.7.3/src/distributions/utils.rs:254:5 clippy::inline_always "you have declared `#[inline(always)]` on `lanes`. This is usually a bad idea" -rand/0.7.3/src/distributions/utils.rs:258:5 clippy::inline_always "you have declared `#[inline(always)]` on `splat`. This is usually a bad idea" -rand/0.7.3/src/distributions/utils.rs:262:5 clippy::inline_always "you have declared `#[inline(always)]` on `extract`. This is usually a bad idea" -rand/0.7.3/src/distributions/utils.rs:267:5 clippy::inline_always "you have declared `#[inline(always)]` on `replace`. This is usually a bad idea" -rand/0.7.3/src/distributions/utils.rs:281:5 clippy::inline_always "you have declared `#[inline(always)]` on `any`. This is usually a bad idea" -rand/0.7.3/src/distributions/utils.rs:286:5 clippy::inline_always "you have declared `#[inline(always)]` on `all`. This is usually a bad idea" -rand/0.7.3/src/distributions/utils.rs:291:5 clippy::inline_always "you have declared `#[inline(always)]` on `none`. This is usually a bad idea" -rand/0.7.3/src/distributions/utils.rs:488:17 clippy::doc_markdown "you should put `x_i` between ticks in the documentation" -rand/0.7.3/src/distributions/utils.rs:489:50 clippy::doc_markdown "you should put `x_i` between ticks in the documentation" -rand/0.7.3/src/distributions/utils.rs:489:63 clippy::doc_markdown "you should put `f(x_i` between ticks in the documentation" -rand/0.7.3/src/distributions/utils.rs:490:40 clippy::doc_markdown "you should put `f(x_i` between ticks in the documentation" -rand/0.7.3/src/distributions/utils.rs:490:49 clippy::doc_markdown "you should put `f(x_{i+1` between ticks in the documentation" -rand/0.7.3/src/distributions/utils.rs:518:17 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -rand/0.7.3/src/distributions/weibull.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/distributions/weighted/alias_method.rs:113:21 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" -rand/0.7.3/src/distributions/weighted/alias_method.rs:125:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rand/0.7.3/src/distributions/weighted/alias_method.rs:131:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rand/0.7.3/src/distributions/weighted/alias_method.rs:180:36 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -rand/0.7.3/src/distributions/weighted/alias_method.rs:182:34 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -rand/0.7.3/src/distributions/weighted/alias_method.rs:259:28 clippy::clone_on_copy "using `clone` on type `distributions::uniform::Uniform` which implements the `Copy` trait" -rand/0.7.3/src/distributions/weighted/alias_method.rs:296:9 clippy::map_clone "you are using an explicit closure for copying elements" -rand/0.7.3/src/distributions/weighted/alias_method.rs:321:9 clippy::map_clone "you are using an explicit closure for copying elements" -rand/0.7.3/src/distributions/weighted/alias_method.rs:78:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -rand/0.7.3/src/distributions/weighted/alias_method.rs:78:5 clippy::too_many_lines "this function has too many lines (106/100)" -rand/0.7.3/src/distributions/weighted/alias_method.rs:85:17 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -rand/0.7.3/src/distributions/weighted/alias_method.rs:87:31 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" -rand/0.7.3/src/distributions/weighted/mod.rs:100:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -rand/0.7.3/src/distributions/weighted/mod.rs:144:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -rand/0.7.3/src/distributions/weighted/mod.rs:169:16 clippy::int_plus_one "unnecessary `>= y + 1` or `x - 1 >=`" -rand/0.7.3/src/distributions/weighted/mod.rs:386:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand/0.7.3/src/distributions/weighted/mod.rs:85:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand/0.7.3/src/lib.rs:333:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -rand/0.7.3/src/lib.rs:404:14 clippy::wrong_self_convention "methods called `to_*` usually take self by reference; consider choosing a less ambiguous name" -rand/0.7.3/src/lib.rs:552:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -rand/0.7.3/src/rngs/adapter/read.rs:47:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand/0.7.3/src/rngs/adapter/read.rs:89:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand/0.7.3/src/rngs/adapter/reseeding.rs:100:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -rand/0.7.3/src/rngs/adapter/reseeding.rs:112:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea" -rand/0.7.3/src/rngs/adapter/reseeding.rs:117:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea" -rand/0.7.3/src/rngs/adapter/reseeding.rs:198:13 clippy::cast_possible_wrap "casting `u64` to `i64` may wrap around the value" -rand/0.7.3/src/rngs/adapter/reseeding.rs:231:9 clippy::cast_possible_wrap "casting `usize` to `isize` may wrap around the value" -rand/0.7.3/src/rngs/adapter/reseeding.rs:27:28 clippy::doc_markdown "you should put `ChaCha` between ticks in the documentation" -rand/0.7.3/src/rngs/adapter/reseeding.rs:79:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand/0.7.3/src/rngs/entropy.rs:24:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand/0.7.3/src/rngs/entropy.rs:34:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/rngs/mock.rs:36:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/rngs/mock.rs:47:9 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" -rand/0.7.3/src/rngs/mod.rs:61:74 clippy::doc_markdown "you should put `ChaCha20` between ticks in the documentation" -rand/0.7.3/src/rngs/std.rs:25:39 clippy::doc_markdown "you should put `ChaCha` between ticks in the documentation" -rand/0.7.3/src/rngs/std.rs:32:10 clippy::doc_markdown "you should put `rand_chacha` between ticks in the documentation" -rand/0.7.3/src/rngs/std.rs:36:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand/0.7.3/src/rngs/std.rs:39:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea" -rand/0.7.3/src/rngs/std.rs:44:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea" -rand/0.7.3/src/rngs/std.rs:49:5 clippy::inline_always "you have declared `#[inline(always)]` on `fill_bytes`. This is usually a bad idea" -rand/0.7.3/src/rngs/std.rs:54:5 clippy::inline_always "you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea" -rand/0.7.3/src/rngs/std.rs:63:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_seed`. This is usually a bad idea" -rand/0.7.3/src/rngs/std.rs:68:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_rng`. This is usually a bad idea" -rand/0.7.3/src/rngs/thread.rs:57:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand/0.7.3/src/rngs/thread.rs:80:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand/0.7.3/src/rngs/thread.rs:80:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -rand/0.7.3/src/rngs/thread.rs:81:35 clippy::redundant_closure_for_method_calls "redundant closure found" -rand/0.7.3/src/rngs/thread.rs:93:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea" -rand/0.7.3/src/rngs/thread.rs:98:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea" -rand/0.7.3/src/seq/index.rs:127:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand/0.7.3/src/seq/index.rs:139:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -rand/0.7.3/src/seq/index.rs:159:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand/0.7.3/src/seq/index.rs:171:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -rand/0.7.3/src/seq/index.rs:180:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -rand/0.7.3/src/seq/index.rs:223:18 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -rand/0.7.3/src/seq/index.rs:224:18 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -rand/0.7.3/src/seq/index.rs:233:25 clippy::cast_precision_loss "casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide)" -rand/0.7.3/src/seq/index.rs:236:27 clippy::cast_precision_loss "casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide)" -rand/0.7.3/src/seq/index.rs:244:12 clippy::cast_precision_loss "casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide)" -rand/0.7.3/src/seq/index.rs:244:37 clippy::cast_precision_loss "casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide)" -rand/0.7.3/src/seq/index.rs:29:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand/0.7.3/src/seq/index.rs:39:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/seq/index.rs:48:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/seq/index.rs:60:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/seq/index.rs:69:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/seq/index.rs:78:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/seq/index.rs:87:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/seq/index.rs:87:5 clippy::should_implement_trait "method `into_iter` can be confused for the standard trait method `std::iter::IntoIterator::into_iter`" -rand/0.7.3/src/seq/index.rs:97:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -rand/0.7.3/src/seq/mod.rs:141:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -rand/0.7.3/src/seq/mod.rs:168:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -rand/0.7.3/src/seq/mod.rs:229:4 clippy::needless_doctest_main "needless `fn main` in doctest" -rand/0.7.3/src/seq/mod.rs:292:29 clippy::cast_precision_loss "casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand/0.7.3/src/seq/mod.rs:410:23 clippy::default_trait_access "calling `std::marker::PhantomData::default()` is more clear than this expression" -rand/0.7.3/src/seq/mod.rs:45:4 clippy::needless_doctest_main "needless `fn main` in doctest" -rand/0.7.3/src/seq/mod.rs:527:26 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -rand_core/0.6.0/src/block.rs:117:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand_core/0.6.0/src/block.rs:153:5 clippy::inline_always "you have declared `#[inline(always)]` on `index`. This is usually a bad idea" -rand_core/0.6.0/src/block.rs:230:5 clippy::inline_always "you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea" -rand_core/0.6.0/src/block.rs:240:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_seed`. This is usually a bad idea" -rand_core/0.6.0/src/block.rs:245:5 clippy::inline_always "you have declared `#[inline(always)]` on `seed_from_u64`. This is usually a bad idea" -rand_core/0.6.0/src/block.rs:250:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_rng`. This is usually a bad idea" -rand_core/0.6.0/src/block.rs:280:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand_core/0.6.0/src/block.rs:319:5 clippy::inline_always "you have declared `#[inline(always)]` on `index`. This is usually a bad idea" -rand_core/0.6.0/src/block.rs:405:5 clippy::inline_always "you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea" -rand_core/0.6.0/src/block.rs:415:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_seed`. This is usually a bad idea" -rand_core/0.6.0/src/block.rs:420:5 clippy::inline_always "you have declared `#[inline(always)]` on `seed_from_u64`. This is usually a bad idea" -rand_core/0.6.0/src/block.rs:425:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_rng`. This is usually a bad idea" -rand_core/0.6.0/src/block.rs:67:14 clippy::doc_markdown "you should put `module][crate::block` between ticks in the documentation" -rand_core/0.6.0/src/block.rs:68:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand_core/0.6.0/src/error.rs:106:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand_core/0.6.0/src/error.rs:87:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand_core/0.6.0/src/error.rs:95:74 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -rand_core/0.6.0/src/lib.rs:179:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -rand_core/0.6.0/src/lib.rs:301:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand_core/0.6.0/src/lib.rs:303:26 clippy::unreadable_literal "long literal lacking separators" -rand_core/0.6.0/src/lib.rs:304:26 clippy::unreadable_literal "long literal lacking separators" -rand_core/0.6.0/src/lib.rs:313:30 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" -rand_core/0.6.0/src/lib.rs:314:23 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" -rand_core/0.6.0/src/lib.rs:346:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -rand_core/0.6.0/src/lib.rs:381:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea" -rand_core/0.6.0/src/lib.rs:386:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea" -rand_core/0.6.0/src/lib.rs:391:5 clippy::inline_always "you have declared `#[inline(always)]` on `fill_bytes`. This is usually a bad idea" -rand_core/0.6.0/src/lib.rs:396:5 clippy::inline_always "you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea" -rayon/1.5.0/src/collections/binary_heap.rs:7:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/collections/binary_heap.rs:8:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/collections/btree_map.rs:7:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/collections/btree_map.rs:8:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/collections/btree_set.rs:7:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/collections/btree_set.rs:8:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/collections/hash_map.rs:10:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/collections/hash_map.rs:9:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/collections/hash_set.rs:10:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/collections/hash_set.rs:9:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/collections/linked_list.rs:7:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/collections/linked_list.rs:8:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/collections/mod.rs:59:32 clippy::mem_replace_with_default "replacing a value of type `T` with `T::default()` is better expressed using `std::mem::take`" -rayon/1.5.0/src/collections/vec_deque.rs:8:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/collections/vec_deque.rs:9:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/compile_fail/cannot_collect_filtermap_data.rs:2:1 clippy::needless_doctest_main "needless `fn main` in doctest" -rayon/1.5.0/src/compile_fail/cannot_zip_filtered_data.rs:2:1 clippy::needless_doctest_main "needless `fn main` in doctest" -rayon/1.5.0/src/compile_fail/cell_par_iter.rs:2:1 clippy::needless_doctest_main "needless `fn main` in doctest" -rayon/1.5.0/src/compile_fail/no_send_par_iter.rs:25:1 clippy::needless_doctest_main "needless `fn main` in doctest" -rayon/1.5.0/src/compile_fail/no_send_par_iter.rs:46:1 clippy::needless_doctest_main "needless `fn main` in doctest" -rayon/1.5.0/src/compile_fail/no_send_par_iter.rs:4:1 clippy::needless_doctest_main "needless `fn main` in doctest" -rayon/1.5.0/src/compile_fail/rc_par_iter.rs:2:1 clippy::needless_doctest_main "needless `fn main` in doctest" -rayon/1.5.0/src/iter/chain.rs:103:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/chain.rs:122:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/chain.rs:128:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/chain.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/chain.rs:221:36 clippy::doc_markdown "you should put `ExactSizeIterator` between ticks in the documentation" -rayon/1.5.0/src/iter/chain.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/chain.rs:51:38 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" -rayon/1.5.0/src/iter/chain.rs:58:14 clippy::shadow_unrelated "`a` is being shadowed" -rayon/1.5.0/src/iter/chain.rs:58:17 clippy::shadow_unrelated "`b` is being shadowed" -rayon/1.5.0/src/iter/chain.rs:78:14 clippy::shadow_unrelated "`a` is being shadowed" -rayon/1.5.0/src/iter/chain.rs:78:17 clippy::shadow_unrelated "`b` is being shadowed" -rayon/1.5.0/src/iter/chain.rs:97:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/chunks.rs:3:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/chunks.rs:4:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/chunks.rs:77:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/chunks.rs:83:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/cloned.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/cloned.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/cloned.rs:71:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/cloned.rs:75:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/collect/consumer.rs:141:5 clippy::doc_markdown "you should put `CollectReducer` between ticks in the documentation" -rayon/1.5.0/src/iter/collect/consumer.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/collect/consumer.rs:28:5 clippy::doc_markdown "you should put `CollectResult` between ticks in the documentation" -rayon/1.5.0/src/iter/collect/consumer.rs:36:37 clippy::mut_mut "generally you want to avoid `&mut &mut _` if possible" -rayon/1.5.0/src/iter/collect/consumer.rs:36:37 clippy::mut_mut "generally you want to avoid `&mut &mut _` if possible" -rayon/1.5.0/src/iter/collect/mod.rs:154:9 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -rayon/1.5.0/src/iter/copied.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/copied.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/copied.rs:71:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/copied.rs:75:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/empty.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/empty.rs:24:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -rayon/1.5.0/src/iter/empty.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/enumerate.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/enumerate.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/enumerate.rs:64:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/enumerate.rs:68:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/extend.rs:143:63 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" -rayon/1.5.0/src/iter/extend.rs:182:57 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" -rayon/1.5.0/src/iter/extend.rs:218:32 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" -rayon/1.5.0/src/iter/extend.rs:218:59 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" -rayon/1.5.0/src/iter/extend.rs:25:42 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" -rayon/1.5.0/src/iter/extend.rs:287:62 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" -rayon/1.5.0/src/iter/extend.rs:322:56 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" -rayon/1.5.0/src/iter/extend.rs:41:27 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" -rayon/1.5.0/src/iter/extend.rs:47:30 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" -rayon/1.5.0/src/iter/extend.rs:47:56 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" -rayon/1.5.0/src/iter/extend.rs:47:74 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" -rayon/1.5.0/src/iter/extend.rs:53:29 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" -rayon/1.5.0/src/iter/extend.rs:57:36 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" -rayon/1.5.0/src/iter/extend.rs:59:61 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" -rayon/1.5.0/src/iter/filter.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/filter.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/filter_map.rs:123:9 clippy::option_if_let_else "use Option::map_or instead of an if let/else" -rayon/1.5.0/src/iter/filter_map.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/filter_map.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/find.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/find.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/find_first_last/mod.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/find_first_last/mod.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/find_first_last/mod.rs:32:67 clippy::doc_markdown "you should put `MatchPosition` between ticks in the documentation" -rayon/1.5.0/src/iter/flat_map.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/flat_map.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/flat_map_iter.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/flat_map_iter.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/flatten.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/flatten.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/flatten_iter.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/flatten_iter.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/fold.rs:158:13 clippy::similar_names "binding's name is too similar to existing binding" -rayon/1.5.0/src/iter/fold.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/fold.rs:204:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rayon/1.5.0/src/iter/fold.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/for_each.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/for_each.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/inspect.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/inspect.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/inspect.rs:83:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/inspect.rs:88:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/interleave.rs:111:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/interleave.rs:119:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/interleave.rs:195:30 clippy::doc_markdown "you should put `self.i_len` between ticks in the documentation" -rayon/1.5.0/src/iter/interleave.rs:195:43 clippy::doc_markdown "you should put `self.j_len` between ticks in the documentation" -rayon/1.5.0/src/iter/interleave.rs:199:23 clippy::doc_markdown "you should put `self.i_len` between ticks in the documentation" -rayon/1.5.0/src/iter/interleave.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/interleave.rs:200:23 clippy::doc_markdown "you should put `self.j_len` between ticks in the documentation" -rayon/1.5.0/src/iter/interleave.rs:249:41 clippy::doc_markdown "you should put `DoubleEndedIterator` between ticks in the documentation" -rayon/1.5.0/src/iter/interleave.rs:250:5 clippy::doc_markdown "you should put `ExactSizeIterator` between ticks in the documentation" -rayon/1.5.0/src/iter/interleave.rs:263:33 clippy::doc_markdown "you should put `InterleaveSeq` between ticks in the documentation" -rayon/1.5.0/src/iter/interleave.rs:280:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" -rayon/1.5.0/src/iter/interleave.rs:285:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" -rayon/1.5.0/src/iter/interleave.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/interleave.rs:313:9 clippy::comparison_chain "`if` chain can be rewritten with `match`" -rayon/1.5.0/src/iter/interleave.rs:82:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/interleave.rs:90:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/interleave_shortest.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/intersperse.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/intersperse.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/intersperse.rs:90:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/intersperse.rs:96:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/len.rs:12:1 clippy::module_name_repetitions "item name ends with its containing module's name" -rayon/1.5.0/src/iter/len.rs:146:1 clippy::module_name_repetitions "item name ends with its containing module's name" -rayon/1.5.0/src/iter/len.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/len.rs:200:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/len.rs:205:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/len.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/len.rs:66:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/len.rs:71:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/map.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/map.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/map.rs:84:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/map.rs:89:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/map_with.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/map_with.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/map_with.rs:419:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/map_with.rs:425:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/map_with.rs:90:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/map_with.rs:96:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/mod.rs:1874:24 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -rayon/1.5.0/src/iter/mod.rs:2171:1 clippy::len_without_is_empty "trait `IndexedParallelIterator` has a `len` method but no (possibly inherited) `is_empty` method" -rayon/1.5.0/src/iter/mod.rs:2371:26 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -rayon/1.5.0/src/iter/mod.rs:2411:26 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -rayon/1.5.0/src/iter/mod.rs:82:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/multizip.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/multizip.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/noop.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/once.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/once.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/panic_fuse.rs:102:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/panic_fuse.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/panic_fuse.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/panic_fuse.rs:98:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/par_bridge.rs:136:28 clippy::redundant_else "redundant else block" -rayon/1.5.0/src/iter/par_bridge.rs:163:28 clippy::redundant_else "redundant else block" -rayon/1.5.0/src/iter/plumbing/mod.rs:216:58 clippy::doc_markdown "you should put `find_first` between ticks in the documentation" -rayon/1.5.0/src/iter/plumbing/mod.rs:359:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/plumbing/mod.rs:364:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/plumbing/mod.rs:399:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/plumbing/mod.rs:53:19 clippy::doc_markdown "you should put `DoubleEndedIterator` between ticks in the documentation" -rayon/1.5.0/src/iter/plumbing/mod.rs:53:43 clippy::doc_markdown "you should put `ExactSizeIterator` between ticks in the documentation" -rayon/1.5.0/src/iter/plumbing/mod.rs:54:31 clippy::doc_markdown "you should put `IntoIterator` between ticks in the documentation" -rayon/1.5.0/src/iter/plumbing/mod.rs:55:5 clippy::doc_markdown "you should put `IntoIterator` between ticks in the documentation" -rayon/1.5.0/src/iter/positions.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/positions.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/product.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/reduce.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/repeat.rs:103:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rayon/1.5.0/src/iter/repeat.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/repeat.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/rev.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/rev.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/rev.rs:63:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/rev.rs:68:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/skip.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/skip.rs:3:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/skip.rs:68:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/skip.rs:73:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/splitter.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/splitter.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/step_by.rs:4:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/step_by.rs:5:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/step_by.rs:73:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/step_by.rs:79:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/sum.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/take.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/take.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/take.rs:67:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/take.rs:72:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/try_fold.rs:190:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rayon/1.5.0/src/iter/try_fold.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/try_fold.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/try_reduce.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/try_reduce_with.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/unzip.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/unzip.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/update.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/update.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/update.rs:82:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/update.rs:87:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/while_some.rs:130:22 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -rayon/1.5.0/src/iter/while_some.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/while_some.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/zip.rs:102:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/zip.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/zip.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/zip.rs:74:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/zip.rs:79:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/zip.rs:97:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/zip_eq.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/zip_eq.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/option.rs:8:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/option.rs:9:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/par_either.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/par_either.rs:3:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/private.rs:9:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rayon/1.5.0/src/range.rs:19:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/range.rs:20:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/range_inclusive.rs:194:9 clippy::range_plus_one "an inclusive range would be more readable" -rayon/1.5.0/src/range_inclusive.rs:194:9 clippy::range_plus_one "an inclusive range would be more readable" -rayon/1.5.0/src/range_inclusive.rs:19:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/range_inclusive.rs:209:9 clippy::range_plus_one "an inclusive range would be more readable" -rayon/1.5.0/src/range_inclusive.rs:209:9 clippy::range_plus_one "an inclusive range would be more readable" -rayon/1.5.0/src/range_inclusive.rs:20:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/range_inclusive.rs:231:9 clippy::range_plus_one "an inclusive range would be more readable" -rayon/1.5.0/src/range_inclusive.rs:231:9 clippy::range_plus_one "an inclusive range would be more readable" -rayon/1.5.0/src/result.rs:8:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/result.rs:9:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/slice/mergesort.rs:102:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/slice/mergesort.rs:109:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/slice/mergesort.rs:114:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/slice/mergesort.rs:211:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/slice/mergesort.rs:217:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/slice/mergesort.rs:251:5 clippy::doc_markdown "you should put `TimSort` between ticks in the documentation" -rayon/1.5.0/src/slice/mergesort.rs:252:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" -rayon/1.5.0/src/slice/mergesort.rs:286:59 clippy::doc_markdown "you should put `TimSort` between ticks in the documentation" -rayon/1.5.0/src/slice/mergesort.rs:333:24 clippy::redundant_else "redundant else block" -rayon/1.5.0/src/slice/mergesort.rs:513:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/slice/mergesort.rs:521:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/slice/mergesort.rs:7:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/slice/mergesort.rs:98:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/slice/mod.rs:15:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/slice/mod.rs:16:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/slice/mod.rs:17:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/slice/mod.rs:25:1 clippy::module_name_repetitions "item name ends with its containing module's name" -rayon/1.5.0/src/slice/mod.rs:657:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rayon/1.5.0/src/slice/mod.rs:971:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rayon/1.5.0/src/slice/quicksort.rs:230:36 clippy::doc_markdown "you should put `BlockQuicksort` between ticks in the documentation" -rayon/1.5.0/src/slice/quicksort.rs:233:1 clippy::too_many_lines "this function has too many lines (117/100)" -rayon/1.5.0/src/slice/quicksort.rs:258:26 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -rayon/1.5.0/src/slice/quicksort.rs:265:26 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -rayon/1.5.0/src/slice/quicksort.rs:268:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/slice/quicksort.rs:308:30 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" -rayon/1.5.0/src/slice/quicksort.rs:325:30 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" -rayon/1.5.0/src/slice/quicksort.rs:393:36 clippy::cast_possible_wrap "casting `u8` to `isize` may wrap around the value on targets with 32-bit wide pointers" -rayon/1.5.0/src/slice/quicksort.rs:405:40 clippy::cast_possible_wrap "casting `u8` to `isize` may wrap around the value on targets with 32-bit wide pointers" -rayon/1.5.0/src/slice/quicksort.rs:430:14 clippy::shadow_unrelated "`pivot` is being shadowed" -rayon/1.5.0/src/slice/quicksort.rs:439:13 clippy::shadow_unrelated "`pivot` is being shadowed" -rayon/1.5.0/src/slice/quicksort.rs:482:10 clippy::shadow_unrelated "`pivot` is being shadowed" -rayon/1.5.0/src/slice/quicksort.rs:491:9 clippy::shadow_unrelated "`pivot` is being shadowed" -rayon/1.5.0/src/slice/quicksort.rs:534:26 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -rayon/1.5.0/src/slice/quicksort.rs:545:17 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -rayon/1.5.0/src/slice/quicksort.rs:588:17 clippy::identity_op "the operation is ineffective. Consider reducing it to `len / 4`" -rayon/1.5.0/src/slice/quicksort.rs:716:14 clippy::shadow_unrelated "`pivot` is being shadowed" -rayon/1.5.0/src/split_producer.rs:56:16 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" -rayon/1.5.0/src/split_producer.rs:92:9 clippy::option_if_let_else "use Option::map_or instead of an if let/else" -rayon/1.5.0/src/str.rs:16:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/str.rs:17:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/str.rs:18:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/str.rs:25:5 clippy::cast_possible_wrap "casting `u8` to `i8` may wrap around the value" -rayon/1.5.0/src/str.rs:715:9 clippy::manual_strip "stripping a suffix manually" -rayon/1.5.0/src/string.rs:5:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/vec.rs:137:12 clippy::len_zero "length comparison to zero" -rayon/1.5.0/src/vec.rs:8:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/vec.rs:9:5 clippy::wildcard_imports "usage of wildcard import" -regex/1.3.2/src/backtrack.rs:100:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/backtrack.rs:133:17 clippy::same_item_push "it looks like the same item is being pushed into this Vec" -regex/1.3.2/src/backtrack.rs:145:20 clippy::if_not_else "unnecessary boolean `not` operation" -regex/1.3.2/src/backtrack.rs:199:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/backtrack.rs:223:29 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/backtrack.rs:230:66 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/backtrack.rs:284:21 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" -regex/1.3.2/src/backtrack.rs:287:5 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex/1.3.2/src/backtrack.rs:97:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/backtrack.rs:98:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/backtrack.rs:99:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:1005:32 clippy::unreadable_literal "long literal lacking separators" -regex/1.3.2/src/compile.rs:1006:21 clippy::unreadable_literal "long literal lacking separators" -regex/1.3.2/src/compile.rs:1008:18 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" -regex/1.3.2/src/compile.rs:1009:18 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" -regex/1.3.2/src/compile.rs:1010:9 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -regex/1.3.2/src/compile.rs:102:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/compile.rs:1037:37 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" -regex/1.3.2/src/compile.rs:1037:55 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" -regex/1.3.2/src/compile.rs:1040:28 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" -regex/1.3.2/src/compile.rs:1040:38 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" -regex/1.3.2/src/compile.rs:1051:25 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -regex/1.3.2/src/compile.rs:1071:8 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" -regex/1.3.2/src/compile.rs:112:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -regex/1.3.2/src/compile.rs:154:30 clippy::redundant_closure_for_method_calls "redundant closure found" -regex/1.3.2/src/compile.rs:156:30 clippy::redundant_closure_for_method_calls "redundant closure found" -regex/1.3.2/src/compile.rs:185:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -regex/1.3.2/src/compile.rs:187:40 clippy::redundant_closure_for_method_calls "redundant closure found" -regex/1.3.2/src/compile.rs:201:53 clippy::doc_markdown "you should put `MaybeInsts` between ticks in the documentation" -regex/1.3.2/src/compile.rs:241:63 clippy::doc_markdown "you should put `c_concat` between ticks in the documentation" -regex/1.3.2/src/compile.rs:245:5 clippy::too_many_lines "this function has too many lines (111/100)" -regex/1.3.2/src/compile.rs:247:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/compile.rs:373:24 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:373:36 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:378:12 clippy::if_not_else "unnecessary boolean `not` operation" -regex/1.3.2/src/compile.rs:400:37 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:407:51 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:409:24 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:417:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -regex/1.3.2/src/compile.rs:42:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/compile.rs:42:5 clippy::new_without_default "you should consider adding a `Default` implementation for `compile::Compiler`" -regex/1.3.2/src/compile.rs:444:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -regex/1.3.2/src/compile.rs:445:57 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:446:20 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:466:20 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:466:32 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:519:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/compile.rs:55:57 clippy::doc_markdown "you should put `size_limit` between ticks in the documentation" -regex/1.3.2/src/compile.rs:58:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/compile.rs:748:41 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:74:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/compile.rs:751:54 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:765:41 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:765:55 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:825:39 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:825:51 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:828:49 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:828:61 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:830:59 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:830:71 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:832:43 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:835:41 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:835:53 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:835:67 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:83:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/compile.rs:896:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -regex/1.3.2/src/compile.rs:905:17 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:953:17 clippy::doc_markdown "you should put `HashMap` between ticks in the documentation" -regex/1.3.2/src/compile.rs:95:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/compile.rs:980:26 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -regex/1.3.2/src/compile.rs:994:44 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:994:54 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/dfa.rs:1007:17 clippy::similar_names "binding's name is too similar to existing binding" -regex/1.3.2/src/dfa.rs:1010:22 clippy::similar_names "binding's name is too similar to existing binding" -regex/1.3.2/src/dfa.rs:1059:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/dfa.rs:1060:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/dfa.rs:1084:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex/1.3.2/src/dfa.rs:1087:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex/1.3.2/src/dfa.rs:1090:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex/1.3.2/src/dfa.rs:1093:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex/1.3.2/src/dfa.rs:1096:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex/1.3.2/src/dfa.rs:1101:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex/1.3.2/src/dfa.rs:1104:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex/1.3.2/src/dfa.rs:1107:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex/1.3.2/src/dfa.rs:1117:30 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex/1.3.2/src/dfa.rs:1120:47 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex/1.3.2/src/dfa.rs:1121:30 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex/1.3.2/src/dfa.rs:1129:13 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" -regex/1.3.2/src/dfa.rs:1134:13 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" -regex/1.3.2/src/dfa.rs:1185:68 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" -regex/1.3.2/src/dfa.rs:1193:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/dfa.rs:1244:50 clippy::doc_markdown "you should put `current_state` between ticks in the documentation" -regex/1.3.2/src/dfa.rs:1338:58 clippy::doc_markdown "you should put `STATE_DEAD` between ticks in the documentation" -regex/1.3.2/src/dfa.rs:1339:9 clippy::doc_markdown "you should put `STATE_UNKNOWN` between ticks in the documentation" -regex/1.3.2/src/dfa.rs:1366:25 clippy::doc_markdown "you should put `STATE_DEAD` between ticks in the documentation" -regex/1.3.2/src/dfa.rs:1366:46 clippy::doc_markdown "you should put `STATE_UNKNOWN` between ticks in the documentation" -regex/1.3.2/src/dfa.rs:1367:41 clippy::inline_always "you have declared `#[inline(always)]` on `start_state`. This is usually a bad idea" -regex/1.3.2/src/dfa.rs:1380:14 clippy::identity_op "the operation is ineffective. Consider reducing it to `(empty_flags.start as u8)`" -regex/1.3.2/src/dfa.rs:1388:15 clippy::match_on_vec_items "indexing into a vector may panic" -regex/1.3.2/src/dfa.rs:1412:20 clippy::unused_self "unused `self` argument" -regex/1.3.2/src/dfa.rs:1438:9 clippy::unused_self "unused `self` argument" -regex/1.3.2/src/dfa.rs:1472:9 clippy::doc_markdown "you should put `StatePtr` between ticks in the documentation" -regex/1.3.2/src/dfa.rs:1490:54 clippy::cast_possible_truncation "casting `i32` to `u8` may truncate the value" -regex/1.3.2/src/dfa.rs:1490:54 clippy::cast_sign_loss "casting `i32` to `u8` may lose the sign of the value" -regex/1.3.2/src/dfa.rs:1521:20 clippy::doc_markdown "you should put `num_byte_classes` between ticks in the documentation" -regex/1.3.2/src/dfa.rs:1529:41 clippy::inline_always "you have declared `#[inline(always)]` on `byte_class`. This is usually a bad idea" -regex/1.3.2/src/dfa.rs:1537:14 clippy::doc_markdown "you should put `byte_class` between ticks in the documentation" -regex/1.3.2/src/dfa.rs:1538:41 clippy::inline_always "you have declared `#[inline(always)]` on `u8_class`. This is usually a bad idea" -regex/1.3.2/src/dfa.rs:1562:18 clippy::doc_markdown "you should put `STATE_START` between ticks in the documentation" -regex/1.3.2/src/dfa.rs:1614:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/dfa.rs:1651:38 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/dfa.rs:1700:17 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -regex/1.3.2/src/dfa.rs:1701:18 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex/1.3.2/src/dfa.rs:1705:19 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex/1.3.2/src/dfa.rs:1708:16 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -regex/1.3.2/src/dfa.rs:1709:18 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex/1.3.2/src/dfa.rs:1713:19 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex/1.3.2/src/dfa.rs:1716:18 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -regex/1.3.2/src/dfa.rs:1717:18 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex/1.3.2/src/dfa.rs:1721:19 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex/1.3.2/src/dfa.rs:1727:14 clippy::cast_lossless "casting `u8` to `u16` may become silently lossy if you later change the type" -regex/1.3.2/src/dfa.rs:1732:15 clippy::trivially_copy_pass_by_ref "this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -regex/1.3.2/src/dfa.rs:1736:22 clippy::trivially_copy_pass_by_ref "this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -regex/1.3.2/src/dfa.rs:1741:9 clippy::match_like_matches_macro "match expression looks like `matches!` macro" -regex/1.3.2/src/dfa.rs:1747:16 clippy::trivially_copy_pass_by_ref "this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -regex/1.3.2/src/dfa.rs:1751:18 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" -regex/1.3.2/src/dfa.rs:1815:38 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" -regex/1.3.2/src/dfa.rs:1821:21 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" -regex/1.3.2/src/dfa.rs:1824:5 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex/1.3.2/src/dfa.rs:1848:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" -regex/1.3.2/src/dfa.rs:1850:18 clippy::cast_sign_loss "casting `i32` to `u32` may lose the sign of the value" -regex/1.3.2/src/dfa.rs:1857:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" -regex/1.3.2/src/dfa.rs:1860:17 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -regex/1.3.2/src/dfa.rs:1867:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" -regex/1.3.2/src/dfa.rs:1870:19 clippy::cast_possible_truncation "casting `u32` to `u8` may truncate the value" -regex/1.3.2/src/dfa.rs:1873:15 clippy::cast_possible_truncation "casting `u32` to `u8` may truncate the value" -regex/1.3.2/src/dfa.rs:1876:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" -regex/1.3.2/src/dfa.rs:1882:26 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" -regex/1.3.2/src/dfa.rs:1884:15 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" -regex/1.3.2/src/dfa.rs:277:17 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -regex/1.3.2/src/dfa.rs:277:31 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -regex/1.3.2/src/dfa.rs:295:20 clippy::cast_possible_truncation "casting `usize` to `i32` may truncate the value on targets with 64-bit wide pointers" -regex/1.3.2/src/dfa.rs:295:20 clippy::cast_possible_wrap "casting `usize` to `i32` may wrap around the value on targets with 32-bit wide pointers" -regex/1.3.2/src/dfa.rs:299:21 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" -regex/1.3.2/src/dfa.rs:34:46 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" -regex/1.3.2/src/dfa.rs:398:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -regex/1.3.2/src/dfa.rs:446:41 clippy::inline_always "you have declared `#[inline(always)]` on `forward`. This is usually a bad idea" -regex/1.3.2/src/dfa.rs:457:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/dfa.rs:459:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/dfa.rs:460:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/dfa.rs:476:41 clippy::inline_always "you have declared `#[inline(always)]` on `reverse`. This is usually a bad idea" -regex/1.3.2/src/dfa.rs:487:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/dfa.rs:489:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/dfa.rs:490:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/dfa.rs:506:41 clippy::inline_always "you have declared `#[inline(always)]` on `forward_many`. This is usually a bad idea" -regex/1.3.2/src/dfa.rs:518:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/dfa.rs:520:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/dfa.rs:554:41 clippy::inline_always "you have declared `#[inline(always)]` on `exec_at`. This is usually a bad idea" -regex/1.3.2/src/dfa.rs:555:5 clippy::too_many_lines "this function has too many lines (101/100)" -regex/1.3.2/src/dfa.rs:58:9 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/dfa.rs:667:21 clippy::similar_names "binding's name is too similar to existing binding" -regex/1.3.2/src/dfa.rs:747:41 clippy::inline_always "you have declared `#[inline(always)]` on `exec_at_reverse`. This is usually a bad idea" -regex/1.3.2/src/dfa.rs:795:21 clippy::similar_names "binding's name is too similar to existing binding" -regex/1.3.2/src/dfa.rs:848:9 clippy::doc_markdown "you should put `next_si` between ticks in the documentation" -regex/1.3.2/src/dfa.rs:852:41 clippy::inline_always "you have declared `#[inline(always)]` on `next_si`. This is usually a bad idea" -regex/1.3.2/src/dfa.rs:885:12 clippy::doc_markdown "you should put `STATE_DEAD` between ticks in the documentation" -regex/1.3.2/src/dfa.rs:889:9 clippy::doc_markdown "you should put `STATE_UNKNOWN` between ticks in the documentation" -regex/1.3.2/src/dfa.rs:897:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/dfa.rs:979:29 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex/1.3.2/src/error.rs:6:1 clippy::manual_non_exhaustive "this seems like a manual implementation of the non-exhaustive pattern" -regex/1.3.2/src/exec.rs:1000:14 clippy::doc_markdown "you should put `captures_nfa` between ticks in the documentation" -regex/1.3.2/src/exec.rs:100:1 clippy::module_name_repetitions "item name starts with its containing module's name" -regex/1.3.2/src/exec.rs:1028:5 clippy::too_many_arguments "this function has too many arguments (9/7)" -regex/1.3.2/src/exec.rs:1039:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/exec.rs:1144:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/exec.rs:1179:26 clippy::match_same_arms "this `match` has identical arm bodies" -regex/1.3.2/src/exec.rs:122:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/exec.rs:1250:41 clippy::inline_always "you have declared `#[inline(always)]` on `searcher`. This is usually a bad idea" -regex/1.3.2/src/exec.rs:1260:41 clippy::inline_always "you have declared `#[inline(always)]` on `searcher_str`. This is usually a bad idea" -regex/1.3.2/src/exec.rs:1270:17 clippy::doc_markdown "you should put `RegexSet` between ticks in the documentation" -regex/1.3.2/src/exec.rs:1280:17 clippy::doc_markdown "you should put `RegexSet` between ticks in the documentation" -regex/1.3.2/src/exec.rs:137:9 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" -regex/1.3.2/src/exec.rs:142:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/exec.rs:158:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/exec.rs:168:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/exec.rs:181:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/exec.rs:195:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/exec.rs:204:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/exec.rs:210:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/exec.rs:245:62 clippy::if_same_then_else "this `if` has identical blocks" -regex/1.3.2/src/exec.rs:251:21 clippy::if_not_else "unnecessary boolean `not` operation" -regex/1.3.2/src/exec.rs:262:60 clippy::if_same_then_else "this `if` has identical blocks" -regex/1.3.2/src/exec.rs:268:21 clippy::if_not_else "unnecessary boolean `not` operation" -regex/1.3.2/src/exec.rs:278:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/exec.rs:281:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/exec.rs:286:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -regex/1.3.2/src/exec.rs:300:30 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/exec.rs:308:17 clippy::similar_names "binding's name is too similar to existing binding" -regex/1.3.2/src/exec.rs:329:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/exec.rs:330:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/exec.rs:331:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/exec.rs:334:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/exec.rs:340:19 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/exec.rs:344:27 clippy::unused_self "unused `self` argument" -regex/1.3.2/src/exec.rs:383:41 clippy::inline_always "you have declared `#[inline(always)]` on `shortest_match_at`. This is usually a bad idea" -regex/1.3.2/src/exec.rs:388:41 clippy::inline_always "you have declared `#[inline(always)]` on `is_match_at`. This is usually a bad idea" -regex/1.3.2/src/exec.rs:393:41 clippy::inline_always "you have declared `#[inline(always)]` on `find_at`. This is usually a bad idea" -regex/1.3.2/src/exec.rs:398:41 clippy::inline_always "you have declared `#[inline(always)]` on `captures_read_at`. This is usually a bad idea" -regex/1.3.2/src/exec.rs:425:41 clippy::inline_always "you have declared `#[inline(always)]` on `shortest_match_at`. This is usually a bad idea" -regex/1.3.2/src/exec.rs:44:1 clippy::module_name_repetitions "item name starts with its containing module's name" -regex/1.3.2/src/exec.rs:473:9 clippy::doc_markdown "you should put `shortest_match(...).is_some` between ticks in the documentation" -regex/1.3.2/src/exec.rs:474:41 clippy::inline_always "you have declared `#[inline(always)]` on `is_match_at`. This is usually a bad idea" -regex/1.3.2/src/exec.rs:524:41 clippy::inline_always "you have declared `#[inline(always)]` on `find_at`. This is usually a bad idea" -regex/1.3.2/src/exec.rs:52:1 clippy::module_name_repetitions "item name starts with its containing module's name" -regex/1.3.2/src/exec.rs:686:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/exec.rs:727:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/exec.rs:767:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/exec.rs:783:41 clippy::inline_always "you have declared `#[inline(always)]` on `shortest_dfa`. This is usually a bad idea" -regex/1.3.2/src/exec.rs:791:41 clippy::inline_always "you have declared `#[inline(always)]` on `shortest_dfa_reverse_suffix`. This is usually a bad idea" -regex/1.3.2/src/exec.rs:823:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/exec.rs:868:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/exec.rs:897:31 clippy::doc_markdown "you should put `shortest_nfa(...).is_some` between ticks in the documentation" -regex/1.3.2/src/exec.rs:899:9 clippy::doc_markdown "you should put `shortest_nfa` between ticks in the documentation" -regex/1.3.2/src/exec.rs:905:14 clippy::doc_markdown "you should put `match_nfa` between ticks in the documentation" -regex/1.3.2/src/exec.rs:930:14 clippy::doc_markdown "you should put `shortest_nfa` between ticks in the documentation" -regex/1.3.2/src/exec.rs:981:14 clippy::doc_markdown "you should put `find_nfa` between ticks in the documentation" -regex/1.3.2/src/expand.rs:170:27 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -regex/1.3.2/src/expand.rs:171:5 clippy::match_like_matches_macro "match expression looks like `matches!` macro" -regex/1.3.2/src/expand.rs:22:13 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -regex/1.3.2/src/expand.rs:27:23 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -regex/1.3.2/src/expand.rs:30:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -regex/1.3.2/src/expand.rs:38:30 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" -regex/1.3.2/src/expand.rs:42:21 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" -regex/1.3.2/src/expand.rs:50:1 clippy::module_name_repetitions "item name starts with its containing module's name" -regex/1.3.2/src/expand.rs:69:23 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -regex/1.3.2/src/expand.rs:80:28 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" -regex/1.3.2/src/expand.rs:84:21 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" -regex/1.3.2/src/expand.rs:8:1 clippy::module_name_repetitions "item name starts with its containing module's name" -regex/1.3.2/src/input.rs:142:1 clippy::module_name_repetitions "item name ends with its containing module's name" -regex/1.3.2/src/input.rs:146:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/input.rs:15:1 clippy::module_name_repetitions "item name starts with its containing module's name" -regex/1.3.2/src/input.rs:165:31 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/input.rs:178:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/input.rs:228:1 clippy::module_name_repetitions "item name ends with its containing module's name" -regex/1.3.2/src/input.rs:236:21 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/input.rs:236:33 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/input.rs:24:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/input.rs:271:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/input.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/input.rs:362:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/input.rs:370:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/input.rs:371:42 clippy::redundant_closure_for_method_calls "redundant closure found" -regex/1.3.2/src/input.rs:37:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/input.rs:388:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/input.rs:42:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/input.rs:47:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/input.rs:53:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/input.rs:58:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/input.rs:63:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/lib.rs:1:null clippy::cargo_common_metadata "package `regex` is missing `package.keywords` metadata" -regex/1.3.2/src/literal/imp.rs:101:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/literal/imp.rs:114:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/literal/imp.rs:127:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/literal/imp.rs:139:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/literal/imp.rs:144:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/literal/imp.rs:149:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/literal/imp.rs:154:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/literal/imp.rs:155:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/literal/imp.rs:160:30 clippy::match_same_arms "this `match` has identical arm bodies" -regex/1.3.2/src/literal/imp.rs:167:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/literal/imp.rs:168:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/literal/imp.rs:211:20 clippy::redundant_else "redundant else block" -regex/1.3.2/src/literal/imp.rs:276:50 clippy::match_same_arms "this `match` has identical arm bodies" -regex/1.3.2/src/literal/imp.rs:342:41 clippy::inline_always "you have declared `#[inline(always)]` on `find`. This is usually a bad idea" -regex/1.3.2/src/literal/imp.rs:435:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/literal/imp.rs:436:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/literal/imp.rs:437:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/literal/imp.rs:438:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/literal/imp.rs:439:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/literal/imp.rs:440:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/literal/imp.rs:455:41 clippy::inline_always "you have declared `#[inline(always)]` on `find`. This is usually a bad idea" -regex/1.3.2/src/literal/imp.rs:46:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/literal/imp.rs:481:41 clippy::inline_always "you have declared `#[inline(always)]` on `is_suffix`. This is usually a bad idea" -regex/1.3.2/src/literal/imp.rs:51:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/literal/imp.rs:579:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/literal/imp.rs:57:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/literal/imp.rs:580:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/literal/imp.rs:583:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/literal/imp.rs:602:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -regex/1.3.2/src/literal/imp.rs:622:24 clippy::redundant_else "redundant else block" -regex/1.3.2/src/literal/imp.rs:62:18 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -regex/1.3.2/src/literal/imp.rs:637:24 clippy::redundant_else "redundant else block" -regex/1.3.2/src/literal/imp.rs:648:9 clippy::needless_return "unneeded `return` statement" -regex/1.3.2/src/literal/imp.rs:651:44 clippy::doc_markdown "you should put `BoyerMooreSearch` between ticks in the documentation" -regex/1.3.2/src/literal/imp.rs:65:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/literal/imp.rs:68:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/literal/imp.rs:783:32 clippy::redundant_else "redundant else block" -regex/1.3.2/src/literal/imp.rs:786:42 clippy::manual_saturating_arithmetic "manual saturating arithmetic" -regex/1.3.2/src/literal/imp.rs:78:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/literal/imp.rs:84:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/literal/imp.rs:850:20 clippy::unreadable_literal "long literal lacking separators" -regex/1.3.2/src/literal/imp.rs:85:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/pikevm.rs:103:15 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/pikevm.rs:103:52 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/pikevm.rs:114:5 clippy::too_many_arguments "this function has too many arguments (8/7)" -regex/1.3.2/src/pikevm.rs:117:13 clippy::similar_names "binding's name is too similar to existing binding" -regex/1.3.2/src/pikevm.rs:124:17 clippy::similar_names "binding's name is too similar to existing binding" -regex/1.3.2/src/pikevm.rs:220:9 clippy::doc_markdown "you should put `thread_caps` between ticks in the documentation" -regex/1.3.2/src/pikevm.rs:222:16 clippy::doc_markdown "you should put `at_next` between ticks in the documentation" -regex/1.3.2/src/pikevm.rs:223:9 clippy::doc_markdown "you should put `at_next` between ticks in the documentation" -regex/1.3.2/src/pikevm.rs:224:5 clippy::too_many_arguments "this function has too many arguments (8/7)" -regex/1.3.2/src/pikevm.rs:234:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/pikevm.rs:303:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/pikevm.rs:331:29 clippy::mut_mut "this expression mutably borrows a mutable reference. Consider reborrowing" -regex/1.3.2/src/pikevm.rs:88:5 clippy::too_many_arguments "this function has too many arguments (8/7)" -regex/1.3.2/src/prog.rs:102:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/prog.rs:113:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/prog.rs:120:9 clippy::match_like_matches_macro "match expression looks like `matches!` macro" -regex/1.3.2/src/prog.rs:128:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/prog.rs:134:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/prog.rs:141:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/prog.rs:147:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/prog.rs:164:41 clippy::inline_always "you have declared `#[inline(always)]` on `deref`. This is usually a bad idea" -regex/1.3.2/src/prog.rs:172:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/prog.rs:18:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -regex/1.3.2/src/prog.rs:236:13 clippy::write_with_newline "using `write!()` with a format string that ends in a single newline" -regex/1.3.2/src/prog.rs:300:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/prog.rs:301:9 clippy::match_like_matches_macro "match expression looks like `matches!` macro" -regex/1.3.2/src/prog.rs:382:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/prog.rs:409:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/prog.rs:80:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/prog.rs:80:5 clippy::new_without_default "you should consider adding a `Default` implementation for `prog::Program`" -regex/1.3.2/src/re_builder.rs:267:17 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -regex/1.3.2/src/re_builder.rs:267:17 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -regex/1.3.2/src/re_builder.rs:4:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -regex/1.3.2/src/re_builder.rs:57:17 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_builder.rs:57:17 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_builder.rs:68:17 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -regex/1.3.2/src/re_builder.rs:68:17 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -regex/1.3.2/src/re_bytes.rs:1017:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" -regex/1.3.2/src/re_bytes.rs:1039:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" -regex/1.3.2/src/re_bytes.rs:1093:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -regex/1.3.2/src/re_bytes.rs:1118:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -regex/1.3.2/src/re_bytes.rs:1133:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -regex/1.3.2/src/re_bytes.rs:118:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -regex/1.3.2/src/re_bytes.rs:256:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/re_bytes.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_bytes.rs:35:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_bytes.rs:42:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_bytes.rs:48:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_bytes.rs:558:29 clippy::doc_markdown "you should put `shortest_match` between ticks in the documentation" -regex/1.3.2/src/re_bytes.rs:55:33 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/re_bytes.rs:55:47 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/re_bytes.rs:572:29 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" -regex/1.3.2/src/re_bytes.rs:720:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/re_bytes.rs:817:5 clippy::doc_markdown "you should put `CaptureLocations` between ticks in the documentation" -regex/1.3.2/src/re_bytes.rs:843:1 clippy::len_without_is_empty "item `re_bytes::CaptureLocations` has a public `len` method but no corresponding `is_empty` method" -regex/1.3.2/src/re_bytes.rs:849:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_bytes.rs:858:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_bytes.rs:869:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_bytes.rs:891:1 clippy::len_without_is_empty "item `re_bytes::Captures<'t>` has a public `len` method but no corresponding `is_empty` method" -regex/1.3.2/src/re_bytes.rs:911:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_bytes.rs:917:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_bytes.rs:926:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_bytes.rs:955:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_set.rs:179:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/re_set.rs:179:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/re_set.rs:251:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_set.rs:251:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_set.rs:263:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_set.rs:263:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_set.rs:268:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_set.rs:268:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_set.rs:277:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_set.rs:277:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_set.rs:94:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -regex/1.3.2/src/re_set.rs:94:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -regex/1.3.2/src/re_trait.rs:136:29 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/re_unicode.rs:1019:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" -regex/1.3.2/src/re_unicode.rs:1041:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" -regex/1.3.2/src/re_unicode.rs:1088:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/re_unicode.rs:1135:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -regex/1.3.2/src/re_unicode.rs:1160:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -regex/1.3.2/src/re_unicode.rs:174:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -regex/1.3.2/src/re_unicode.rs:21:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -regex/1.3.2/src/re_unicode.rs:313:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/re_unicode.rs:38:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_unicode.rs:44:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_unicode.rs:51:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_unicode.rs:57:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_unicode.rs:617:29 clippy::doc_markdown "you should put `shortest_match` between ticks in the documentation" -regex/1.3.2/src/re_unicode.rs:631:29 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" -regex/1.3.2/src/re_unicode.rs:64:33 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/re_unicode.rs:64:47 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/re_unicode.rs:834:5 clippy::doc_markdown "you should put `CaptureLocations` between ticks in the documentation" -regex/1.3.2/src/re_unicode.rs:860:1 clippy::len_without_is_empty "item `re_unicode::CaptureLocations` has a public `len` method but no corresponding `is_empty` method" -regex/1.3.2/src/re_unicode.rs:866:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_unicode.rs:875:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_unicode.rs:886:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_unicode.rs:908:1 clippy::len_without_is_empty "item `re_unicode::Captures<'t>` has a public `len` method but no corresponding `is_empty` method" -regex/1.3.2/src/re_unicode.rs:928:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_unicode.rs:934:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_unicode.rs:943:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_unicode.rs:972:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/sparse.rs:10:37 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" -regex/1.3.2/src/sparse.rs:15:1 clippy::module_name_repetitions "item name starts with its containing module's name" -regex/1.3.2/src/utf8.rs:100:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex/1.3.2/src/utf8.rs:103:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex/1.3.2/src/utf8.rs:106:22 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" -regex/1.3.2/src/utf8.rs:107:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" -regex/1.3.2/src/utf8.rs:108:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" -regex/1.3.2/src/utf8.rs:109:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" -regex/1.3.2/src/utf8.rs:111:27 clippy::unreadable_literal "long literal lacking separators" -regex/1.3.2/src/utf8.rs:121:1 clippy::module_name_repetitions "item name ends with its containing module's name" -regex/1.3.2/src/utf8.rs:143:24 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex/1.3.2/src/utf8.rs:143:9 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex/1.3.2/src/utf8.rs:23:1 clippy::module_name_repetitions "item name ends with its containing module's name" -regex/1.3.2/src/utf8.rs:30:20 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex/1.3.2/src/utf8.rs:51:1 clippy::module_name_repetitions "item name ends with its containing module's name" -regex/1.3.2/src/utf8.rs:58:23 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex/1.3.2/src/utf8.rs:58:9 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex/1.3.2/src/utf8.rs:63:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex/1.3.2/src/utf8.rs:66:22 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" -regex/1.3.2/src/utf8.rs:66:54 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" -regex/1.3.2/src/utf8.rs:77:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex/1.3.2/src/utf8.rs:80:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex/1.3.2/src/utf8.rs:83:22 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" -regex/1.3.2/src/utf8.rs:84:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" -regex/1.3.2/src/utf8.rs:85:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" -regex/1.3.2/src/utf8.rs:92:23 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex/1.3.2/src/utf8.rs:92:9 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex/1.3.2/src/utf8.rs:97:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -ripgrep/12.1.1//home/matthias/.rustup/toolchains/nightly-2020-12-20-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std/src/macros.rs:14:27 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep/12.1.1//home/matthias/.rustup/toolchains/nightly-2020-12-20-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std/src/macros.rs:14:27 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep/12.1.1//home/matthias/.rustup/toolchains/nightly-2020-12-20-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std/src/macros.rs:14:27 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep/12.1.1//home/matthias/.rustup/toolchains/nightly-2020-12-20-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std/src/macros.rs:14:27 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep/12.1.1/build.rs:133:19 clippy::option_as_ref_deref "called `.as_ref().map(|x| &**x)` on an Option value. This can be done more directly by calling `githash.as_deref()` instead" -ripgrep/12.1.1/build.rs:18:18 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -ripgrep/12.1.1/build.rs:225:14 clippy::redundant_closure_for_method_calls "redundant closure found" -ripgrep/12.1.1/build.rs:92:19 clippy::option_as_ref_deref "called `.as_ref().map(|x| &**x)` on an Option value. This can be done more directly by calling `githash.as_deref()` instead" -ripgrep/12.1.1/crates/core/app.rs:1408:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep/12.1.1/crates/core/app.rs:1408:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep/12.1.1/crates/core/app.rs:1409:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep/12.1.1/crates/core/app.rs:1409:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep/12.1.1/crates/core/app.rs:152:32 clippy::doc_markdown "you should put `clap::Arg` between ticks in the documentation" -ripgrep/12.1.1/crates/core/app.rs:152:32 clippy::doc_markdown "you should put `clap::Arg` between ticks in the documentation" -ripgrep/12.1.1/crates/core/app.rs:156:39 clippy::doc_markdown "you should put `clap::Arg` between ticks in the documentation" -ripgrep/12.1.1/crates/core/app.rs:156:39 clippy::doc_markdown "you should put `clap::Arg` between ticks in the documentation" -ripgrep/12.1.1/crates/core/app.rs:156:5 clippy::doc_markdown "you should put `RGArg` between ticks in the documentation" -ripgrep/12.1.1/crates/core/app.rs:156:5 clippy::doc_markdown "you should put `RGArg` between ticks in the documentation" -ripgrep/12.1.1/crates/core/app.rs:1668:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep/12.1.1/crates/core/app.rs:1668:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep/12.1.1/crates/core/app.rs:1669:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep/12.1.1/crates/core/app.rs:1669:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep/12.1.1/crates/core/app.rs:1821:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep/12.1.1/crates/core/app.rs:1821:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep/12.1.1/crates/core/app.rs:1822:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep/12.1.1/crates/core/app.rs:1822:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep/12.1.1/crates/core/app.rs:2999:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep/12.1.1/crates/core/app.rs:2999:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep/12.1.1/crates/core/app.rs:3000:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep/12.1.1/crates/core/app.rs:3000:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep/12.1.1/crates/core/app.rs:367:54 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep/12.1.1/crates/core/app.rs:367:54 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep/12.1.1/crates/core/app.rs:414:59 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep/12.1.1/crates/core/app.rs:414:59 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep/12.1.1/crates/core/app.rs:417:57 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep/12.1.1/crates/core/app.rs:417:57 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep/12.1.1/crates/core/app.rs:417:57 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep/12.1.1/crates/core/app.rs:417:57 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep/12.1.1/crates/core/app.rs:75:9 clippy::doc_markdown "you should put `RIPGREP_BUILD_GIT_HASH` between ticks in the documentation" -ripgrep/12.1.1/crates/core/app.rs:75:9 clippy::doc_markdown "you should put `RIPGREP_BUILD_GIT_HASH` between ticks in the documentation" -ripgrep/12.1.1/crates/core/app.rs:87:5 clippy::if_not_else "unnecessary boolean `not` operation" -ripgrep/12.1.1/crates/core/app.rs:87:5 clippy::if_not_else "unnecessary boolean `not` operation" -ripgrep/12.1.1/crates/core/args.rs:1143:22 clippy::unused_self "unused `self` argument" -ripgrep/12.1.1/crates/core/args.rs:11:1 clippy::single_component_path_imports "this import is redundant" -ripgrep/12.1.1/crates/core/args.rs:1209:74 clippy::if_same_then_else "this `if` has identical blocks" -ripgrep/12.1.1/crates/core/args.rs:1209:74 clippy::if_same_then_else "this `if` has identical blocks" -ripgrep/12.1.1/crates/core/args.rs:1282:13 clippy::similar_names "binding's name is too similar to existing binding" -ripgrep/12.1.1/crates/core/args.rs:1430:22 clippy::unused_self "unused `self` argument" -ripgrep/12.1.1/crates/core/args.rs:1438:21 clippy::doc_markdown "you should put `OsStr` between ticks in the documentation" -ripgrep/12.1.1/crates/core/args.rs:1520:44 clippy::redundant_closure_for_method_calls "redundant closure found" -ripgrep/12.1.1/crates/core/args.rs:1524:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -ripgrep/12.1.1/crates/core/args.rs:1635:14 clippy::doc_markdown "you should put `values_of_lossy` between ticks in the documentation" -ripgrep/12.1.1/crates/core/args.rs:1693:41 clippy::redundant_closure_for_method_calls "redundant closure found" -ripgrep/12.1.1/crates/core/args.rs:1770:17 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -ripgrep/12.1.1/crates/core/args.rs:287:13 clippy::similar_names "binding's name is too similar to existing binding" -ripgrep/12.1.1/crates/core/args.rs:33:1 clippy::single_component_path_imports "this import is redundant" -ripgrep/12.1.1/crates/core/args.rs:34:1 clippy::single_component_path_imports "this import is redundant" -ripgrep/12.1.1/crates/core/args.rs:35:1 clippy::single_component_path_imports "this import is redundant" -ripgrep/12.1.1/crates/core/args.rs:410:14 clippy::trivially_copy_pass_by_ref "this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -ripgrep/12.1.1/crates/core/args.rs:475:18 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep/12.1.1/crates/core/args.rs:512:19 clippy::doc_markdown "you should put `ArgMatches` between ticks in the documentation" -ripgrep/12.1.1/crates/core/args.rs:549:16 clippy::wrong_self_convention "methods called `to_*` usually take self by reference; consider choosing a less ambiguous name" -ripgrep/12.1.1/crates/core/args.rs:76:18 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -ripgrep/12.1.1/crates/core/args.rs:77:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -ripgrep/12.1.1/crates/core/args.rs:923:42 clippy::doc_markdown "you should put `BinaryDetection::quit` between ticks in the documentation" -ripgrep/12.1.1/crates/core/config.rs:13:1 clippy::single_component_path_imports "this import is redundant" -ripgrep/12.1.1/crates/core/config.rs:58:6 clippy::type_complexity "very complex type used. Consider factoring parts into `type` definitions" -ripgrep/12.1.1/crates/core/config.rs:79:6 clippy::type_complexity "very complex type used. Consider factoring parts into `type` definitions" -ripgrep/12.1.1/crates/core/logger.rs:11:30 clippy::doc_markdown "you should put `max_level` between ticks in the documentation" -ripgrep/12.1.1/crates/core/logger.rs:15:16 clippy::redundant_static_lifetimes "constants have by default a `'static` lifetime" -ripgrep/12.1.1/crates/core/main.rs:55:19 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -ripgrep/12.1.1/crates/core/main.rs:56:9 clippy::enum_glob_use "usage of wildcard import for enum variants" -ripgrep/12.1.1/crates/core/messages.rs:46:1 clippy::module_name_repetitions "item name ends with its containing module's name" -ripgrep/12.1.1/crates/core/messages.rs:51:1 clippy::module_name_repetitions "item name ends with its containing module's name" -ripgrep/12.1.1/crates/core/messages.rs:62:1 clippy::module_name_repetitions "item name ends with its containing module's name" -ripgrep/12.1.1/crates/core/path_printer.rs:27:1 clippy::module_name_repetitions "item name starts with its containing module's name" -ripgrep/12.1.1/crates/core/path_printer.rs:89:9 clippy::if_not_else "unnecessary boolean `not` operation" -ripgrep/12.1.1/crates/core/search.rs:185:1 clippy::module_name_repetitions "item name starts with its containing module's name" -ripgrep/12.1.1/crates/core/search.rs:292:9 clippy::write_with_newline "using `write!()` with a format string that ends in a single newline" -ripgrep/12.1.1/crates/core/search.rs:311:1 clippy::module_name_repetitions "item name starts with its containing module's name" -ripgrep/12.1.1/crates/core/search.rs:377:12 clippy::nonminimal_bool "this boolean expression can be simplified" -ripgrep/12.1.1/crates/core/search.rs:423:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -ripgrep/12.1.1/crates/core/search.rs:447:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -ripgrep/12.1.1/crates/core/search.rs:472:24 clippy::map_clone "you are using an explicit closure for cloning elements" -ripgrep/12.1.1/crates/core/search.rs:472:41 clippy::redundant_closure_for_method_calls "redundant closure found" -ripgrep/12.1.1/crates/core/search.rs:480:24 clippy::map_clone "you are using an explicit closure for cloning elements" -ripgrep/12.1.1/crates/core/search.rs:480:41 clippy::redundant_closure_for_method_calls "redundant closure found" -ripgrep/12.1.1/crates/core/search.rs:49:1 clippy::module_name_repetitions "item name starts with its containing module's name" -ripgrep/12.1.1/crates/core/search.rs:509:24 clippy::map_clone "you are using an explicit closure for cloning elements" -ripgrep/12.1.1/crates/core/search.rs:509:41 clippy::redundant_closure_for_method_calls "redundant closure found" -ripgrep/12.1.1/crates/core/search.rs:517:24 clippy::map_clone "you are using an explicit closure for cloning elements" -ripgrep/12.1.1/crates/core/search.rs:517:41 clippy::redundant_closure_for_method_calls "redundant closure found" -ripgrep/12.1.1/crates/core/search.rs:533:36 clippy::cast_lossless "casting `u32` to `f64` may become silently lossy if you later change the type" -ripgrep/12.1.1/crates/core/search.rs:533:5 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -ripgrep/12.1.1/crates/core/subject.rs:20:1 clippy::module_name_repetitions "item name starts with its containing module's name" -ripgrep/12.1.1/crates/core/subject.rs:4:1 clippy::single_component_path_imports "this import is redundant" -syn/1.0.54/build.rs:1:null clippy::cargo_common_metadata "package `syn` is missing `package.keywords` metadata" -syn/1.0.54/build.rs:1:null clippy::multiple_crate_versions "could not read cargo metadata: failed to run `cargo metadata`: Downloading crates ...\n Downloaded dtoa v0.4.7\n Downloaded anyhow v1.0.37\n Downloaded syn-test-suite v0.0.0\nerror: failed to verify the checksum of `syn-test-suite v0.0.0`" -syn/1.0.54/src/lib.rs:1:null clippy::cargo_common_metadata "package `syn` is missing `package.keywords` metadata" -syn/1.0.54/src/lib.rs:1:null clippy::multiple_crate_versions "could not read cargo metadata: failed to run `cargo metadata`: Downloading crates ...\n Downloaded syn-test-suite v0.0.0\nerror: failed to verify the checksum of `syn-test-suite v0.0.0`" -syn/1.0.54/src/lit.rs:1397:40 clippy::redundant_else "redundant else block" -syn/1.0.54/src/lit.rs:1405:28 clippy::redundant_else "redundant else block" -syn/1.0.54/src/lit.rs:1485:32 clippy::redundant_else "redundant else block" -unicode-xid/0.2.1/src/lib.rs:1:null clippy::cargo_common_metadata "package `unicode-xid` is missing `package.categories` metadata" -unicode-xid/0.2.1/src/lib.rs:57:64 clippy::doc_markdown "you should put `XID_Start` between ticks in the documentation" -unicode-xid/0.2.1/src/lib.rs:60:10 clippy::doc_markdown "you should put `XID_Start` between ticks in the documentation" -unicode-xid/0.2.1/src/lib.rs:62:27 clippy::doc_markdown "you should put `ID_Start` between ticks in the documentation" -unicode-xid/0.2.1/src/lib.rs:62:67 clippy::doc_markdown "you should put `NFKx` between ticks in the documentation" -unicode-xid/0.2.1/src/lib.rs:63:21 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" -unicode-xid/0.2.1/src/lib.rs:65:61 clippy::doc_markdown "you should put `XID_Continue` between ticks in the documentation" -unicode-xid/0.2.1/src/lib.rs:68:10 clippy::doc_markdown "you should put `XID_Continue` between ticks in the documentation" -unicode-xid/0.2.1/src/lib.rs:70:28 clippy::doc_markdown "you should put `ID_Continue` between ticks in the documentation" -unicode-xid/0.2.1/src/lib.rs:70:72 clippy::doc_markdown "you should put `NFKx` between ticks in the documentation" -unicode-xid/0.2.1/src/lib.rs:71:24 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" -xsv/0.13.0/src/cmd/cat.rs:101:34 clippy::redundant_closure_for_method_calls "redundant closure found" -xsv/0.13.0/src/cmd/cat.rs:42:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -xsv/0.13.0/src/cmd/cat.rs:53:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/cat.rs:7:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv/0.13.0/src/cmd/count.rs:32:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/count.rs:38:9 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -xsv/0.13.0/src/cmd/count.rs:42:33 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -xsv/0.13.0/src/cmd/count.rs:50:5 clippy::unit_arg "passing a unit value to a function" -xsv/0.13.0/src/cmd/count.rs:7:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv/0.13.0/src/cmd/fixlengths.rs:45:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/fixlengths.rs:50:18 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -xsv/0.13.0/src/cmd/fixlengths.rs:62:30 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -xsv/0.13.0/src/cmd/fixlengths.rs:9:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv/0.13.0/src/cmd/flatten.rs:10:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv/0.13.0/src/cmd/flatten.rs:51:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/fmt.rs:50:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/fmt.rs:55:13 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/fmt.rs:7:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv/0.13.0/src/cmd/frequency.rs:148:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -xsv/0.13.0/src/cmd/frequency.rs:149:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -xsv/0.13.0/src/cmd/frequency.rs:15:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv/0.13.0/src/cmd/frequency.rs:169:13 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/frequency.rs:176:17 clippy::if_not_else "unnecessary boolean `not` operation" -xsv/0.13.0/src/cmd/frequency.rs:178:24 clippy::collapsible_if "this `else { if .. }` block can be collapsed" -xsv/0.13.0/src/cmd/frequency.rs:77:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/frequency.rs:93:31 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" -xsv/0.13.0/src/cmd/headers.rs:43:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/headers.rs:49:17 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" -xsv/0.13.0/src/cmd/headers.rs:9:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv/0.13.0/src/cmd/index.rs:11:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv/0.13.0/src/cmd/index.rs:45:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/input.rs:42:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/input.rs:47:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/input.rs:7:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv/0.13.0/src/cmd/join.rs:17:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv/0.13.0/src/cmd/join.rs:194:29 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/join.rs:224:22 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/join.rs:293:14 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/join.rs:293:20 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/join.rs:297:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv/0.13.0/src/cmd/join.rs:298:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv/0.13.0/src/cmd/join.rs:299:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv/0.13.0/src/cmd/join.rs:300:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv/0.13.0/src/cmd/join.rs:308:9 clippy::unused_self "unused `self` argument" -xsv/0.13.0/src/cmd/join.rs:342:38 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -xsv/0.13.0/src/cmd/join.rs:342:46 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -xsv/0.13.0/src/cmd/join.rs:347:9 clippy::if_not_else "unnecessary boolean `not` operation" -xsv/0.13.0/src/cmd/join.rs:372:44 clippy::redundant_closure_for_method_calls "redundant closure found" -xsv/0.13.0/src/cmd/join.rs:375:33 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/join.rs:392:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv/0.13.0/src/cmd/join.rs:403:29 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" -xsv/0.13.0/src/cmd/join.rs:426:13 clippy::if_not_else "unnecessary boolean `not` operation" -xsv/0.13.0/src/cmd/join.rs:77:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -xsv/0.13.0/src/cmd/join.rs:94:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/partition.rs:105:22 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/partition.rs:139:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv/0.13.0/src/cmd/partition.rs:15:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv/0.13.0/src/cmd/partition.rs:169:9 clippy::if_not_else "unnecessary boolean `not` operation" -xsv/0.13.0/src/cmd/partition.rs:56:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/partition.rs:77:9 clippy::unused_self "unused `self` argument" -xsv/0.13.0/src/cmd/sample.rs:105:44 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -xsv/0.13.0/src/cmd/sample.rs:115:21 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -xsv/0.13.0/src/cmd/sample.rs:11:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv/0.13.0/src/cmd/sample.rs:51:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/sample.rs:58:19 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -xsv/0.13.0/src/cmd/sample.rs:69:9 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" -xsv/0.13.0/src/cmd/sample.rs:75:16 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" -xsv/0.13.0/src/cmd/sample.rs:91:42 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -xsv/0.13.0/src/cmd/sample.rs:92:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -xsv/0.13.0/src/cmd/search.rs:51:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/search.rs:9:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv/0.13.0/src/cmd/select.rs:60:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/select.rs:8:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv/0.13.0/src/cmd/slice.rs:57:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/slice.rs:9:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv/0.13.0/src/cmd/sort.rs:11:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv/0.13.0/src/cmd/sort.rs:138:47 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -xsv/0.13.0/src/cmd/sort.rs:139:51 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -xsv/0.13.0/src/cmd/sort.rs:48:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/sort.rs:91:14 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" -xsv/0.13.0/src/cmd/split.rs:14:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv/0.13.0/src/cmd/split.rs:61:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/split.rs:94:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -xsv/0.13.0/src/cmd/split.rs:96:14 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -xsv/0.13.0/src/cmd/split.rs:99:13 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -xsv/0.13.0/src/cmd/stats.rs:110:36 clippy::redundant_closure_for_method_calls "redundant closure found" -xsv/0.13.0/src/cmd/stats.rs:127:14 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -xsv/0.13.0/src/cmd/stats.rs:138:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -xsv/0.13.0/src/cmd/stats.rs:139:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -xsv/0.13.0/src/cmd/stats.rs:162:25 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" -xsv/0.13.0/src/cmd/stats.rs:22:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv/0.13.0/src/cmd/stats.rs:231:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -xsv/0.13.0/src/cmd/stats.rs:262:35 clippy::default_trait_access "calling `cmd::stats::TypedSum::default()` is more clear than this expression" -xsv/0.13.0/src/cmd/stats.rs:263:40 clippy::default_trait_access "calling `cmd::stats::TypedMinMax::default()` is more clear than this expression" -xsv/0.13.0/src/cmd/stats.rs:264:39 clippy::default_trait_access "calling `stats::OnlineStats::default()` is more clear than this expression" -xsv/0.13.0/src/cmd/stats.rs:265:58 clippy::default_trait_access "calling `stats::Unsorted::default()` is more clear than this expression" -xsv/0.13.0/src/cmd/stats.rs:266:41 clippy::default_trait_access "calling `stats::Unsorted::default()` is more clear than this expression" -xsv/0.13.0/src/cmd/stats.rs:268:18 clippy::default_trait_access "calling `cmd::stats::FieldType::default()` is more clear than this expression" -xsv/0.13.0/src/cmd/stats.rs:269:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv/0.13.0/src/cmd/stats.rs:270:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv/0.13.0/src/cmd/stats.rs:271:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv/0.13.0/src/cmd/stats.rs:272:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv/0.13.0/src/cmd/stats.rs:273:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv/0.13.0/src/cmd/stats.rs:274:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv/0.13.0/src/cmd/stats.rs:283:9 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" -xsv/0.13.0/src/cmd/stats.rs:284:9 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" -xsv/0.13.0/src/cmd/stats.rs:285:9 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" -xsv/0.13.0/src/cmd/stats.rs:290:21 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" -xsv/0.13.0/src/cmd/stats.rs:293:25 clippy::match_same_arms "this `match` has identical arm bodies" -xsv/0.13.0/src/cmd/stats.rs:297:25 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" -xsv/0.13.0/src/cmd/stats.rs:301:21 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" -xsv/0.13.0/src/cmd/stats.rs:302:21 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" -xsv/0.13.0/src/cmd/stats.rs:308:18 clippy::wrong_self_convention "methods called `to_*` usually take self by reference; consider choosing a less ambiguous name" -xsv/0.13.0/src/cmd/stats.rs:318:9 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -xsv/0.13.0/src/cmd/stats.rs:322:45 clippy::redundant_closure_for_method_calls "redundant closure found" -xsv/0.13.0/src/cmd/stats.rs:322:9 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -xsv/0.13.0/src/cmd/stats.rs:327:9 clippy::if_not_else "unnecessary boolean `not` operation" -xsv/0.13.0/src/cmd/stats.rs:330:13 clippy::single_match_else "you seem to be trying to use match for destructuring a single pattern. Consider using `if let`" -xsv/0.13.0/src/cmd/stats.rs:338:45 clippy::redundant_closure_for_method_calls "redundant closure found" -xsv/0.13.0/src/cmd/stats.rs:402:16 clippy::redundant_pattern_matching "redundant pattern matching, consider using `is_ok()`" -xsv/0.13.0/src/cmd/stats.rs:403:16 clippy::redundant_pattern_matching "redundant pattern matching, consider using `is_ok()`" -xsv/0.13.0/src/cmd/stats.rs:407:18 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -xsv/0.13.0/src/cmd/stats.rs:411:16 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -xsv/0.13.0/src/cmd/stats.rs:427:56 clippy::match_same_arms "this `match` has identical arm bodies" -xsv/0.13.0/src/cmd/stats.rs:429:56 clippy::match_same_arms "this `match` has identical arm bodies" -xsv/0.13.0/src/cmd/stats.rs:430:60 clippy::match_same_arms "this `match` has identical arm bodies" -xsv/0.13.0/src/cmd/stats.rs:430:60 clippy::match_same_arms "this `match` has identical arm bodies" -xsv/0.13.0/src/cmd/stats.rs:454:5 clippy::doc_markdown "you should put `TypedSum` between ticks in the documentation" -xsv/0.13.0/src/cmd/stats.rs:473:43 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -xsv/0.13.0/src/cmd/stats.rs:504:56 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -xsv/0.13.0/src/cmd/stats.rs:505:51 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -xsv/0.13.0/src/cmd/stats.rs:511:5 clippy::doc_markdown "you should put `TypedMinMax` between ticks in the documentation" -xsv/0.13.0/src/cmd/stats.rs:536:35 clippy::cast_possible_truncation "casting `f64` to `i64` may truncate the value" -xsv/0.13.0/src/cmd/stats.rs:544:33 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -xsv/0.13.0/src/cmd/stats.rs:592:22 clippy::default_trait_access "calling `stats::MinMax::default()` is more clear than this expression" -xsv/0.13.0/src/cmd/stats.rs:593:22 clippy::default_trait_access "calling `stats::MinMax::default()` is more clear than this expression" -xsv/0.13.0/src/cmd/stats.rs:594:23 clippy::default_trait_access "calling `stats::MinMax::default()` is more clear than this expression" -xsv/0.13.0/src/cmd/stats.rs:595:21 clippy::default_trait_access "calling `stats::MinMax::default()` is more clear than this expression" -xsv/0.13.0/src/cmd/stats.rs:71:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -xsv/0.13.0/src/cmd/stats.rs:86:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/table.rs:10:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv/0.13.0/src/cmd/table.rs:50:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/table.rs:54:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/config.rs:113:43 clippy::or_fun_call "use of `unwrap_or` followed by a function call" -xsv/0.13.0/src/config.rs:58:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -xsv/0.13.0/src/config.rs:77:28 clippy::explicit_deref_methods "explicit deref method call" -xsv/0.13.0/src/config.rs:90:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv/0.13.0/src/index.rs:31:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv/0.13.0/src/main.rs:164:49 clippy::redundant_clone "redundant clone" -xsv/0.13.0/src/main.rs:1:null clippy::cargo_common_metadata "package `xsv` is missing `package.categories` metadata" -xsv/0.13.0/src/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `rand_core`: 0.3.1, 0.4.2" -xsv/0.13.0/src/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `rand`: 0.3.23, 0.4.6" -xsv/0.13.0/src/main.rs:75:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv/0.13.0/src/select.rs:13:1 clippy::module_name_repetitions "item name starts with its containing module's name" -xsv/0.13.0/src/select.rs:154:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -xsv/0.13.0/src/select.rs:250:33 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/select.rs:250:43 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/select.rs:255:39 clippy::range_plus_one "an inclusive range would be more readable" -xsv/0.13.0/src/select.rs:280:20 clippy::len_zero "length comparison to zero" -xsv/0.13.0/src/select.rs:29:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv/0.13.0/src/select.rs:360:62 clippy::trivially_copy_pass_by_ref "this argument (8 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -xsv/0.13.0/src/select.rs:360:9 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Option`" -xsv/0.13.0/src/select.rs:375:9 clippy::stable_sort_primitive "used sort instead of sort_unstable to sort primitive type `usize`" -xsv/0.13.0/src/select.rs:379:18 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" -xsv/0.13.0/src/select.rs:416:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -xsv/0.13.0/src/select.rs:419:9 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Option`" -xsv/0.13.0/src/select.rs:420:27 clippy::option_option "consider using `Option` instead of `Option>` or a custom enum if you need to distinguish all 3 cases" -xsv/0.13.0/src/select.rs:99:17 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/util.rs:150:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" -xsv/0.13.0/src/util.rs:37:33 clippy::map_clone "you are using an explicit closure for copying elements" -xsv/0.13.0/src/util.rs:90:1 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" - - - - -Stats - -clippy::clone_on_copy 1 -clippy::collapsible_if 1 -clippy::comparison_chain 1 -clippy::expect_fun_call 1 -clippy::explicit_deref_methods 1 -clippy::from_iter_instead_of_collect 1 -clippy::from_over_into 1 -clippy::int_plus_one 1 -clippy::manual_saturating_arithmetic 1 -clippy::mem_replace_with_default 1 -clippy::nonminimal_bool 1 -clippy::or_fun_call 1 -clippy::precedence 1 -clippy::pub_enum_variant_names 1 -clippy::redundant_clone 1 -clippy::same_item_push 1 -clippy::should_implement_trait 1 -clippy::stable_sort_primitive 1 -clippy::unit_arg 1 -clippy::unnecessary_lazy_evaluations 1 -clippy::used_underscore_binding 1 -clippy::verbose_bit_mask 1 -clippy::while_let_on_iterator 1 -clippy::comparison_to_empty 2 -clippy::derive_hash_xor_eq 2 -clippy::expl_impl_clone_on_copy 2 -clippy::len_zero 2 -clippy::manual_non_exhaustive 2 -clippy::match_on_vec_items 2 -clippy::option_as_ref_deref 2 -clippy::option_option 2 -clippy::question_mark 2 -clippy::redundant_pattern_matching 2 -clippy::type_complexity 2 -clippy::unnecessary_cast 2 -clippy::unused_unit 2 -clippy::write_with_newline 2 -clippy::filter_map_next 3 -clippy::fn_params_excessive_bools 3 -clippy::mut_mut 3 -clippy::ptr_arg 3 -clippy::zero_ptr 3 -clippy::if_same_then_else 4 -clippy::let_underscore_drop 4 -clippy::too_many_arguments 4 -clippy::empty_enum 5 -clippy::explicit_iter_loop 5 -clippy::field_reassign_with_default 5 -clippy::identity_op 5 -clippy::len_without_is_empty 5 -clippy::match_like_matches_macro 5 -clippy::needless_return 5 -clippy::new_without_default 5 -clippy::manual_strip 6 -clippy::non_ascii_literal 6 -clippy::single_component_path_imports 6 -clippy::explicit_into_iter_loop 7 -clippy::map_clone 7 -clippy::option_map_unit_fn 7 -clippy::range_plus_one 7 -clippy::invalid_upcast_comparisons 8 -clippy::wrong_self_convention 8 -clippy::find_map 9 -clippy::manual_range_contains 10 -clippy::match_wildcard_for_single_variants 10 -clippy::missing_safety_doc 10 -clippy::needless_doctest_main 10 -clippy::multiple_crate_versions 11 -clippy::needless_lifetimes 12 -clippy::option_if_let_else 12 -clippy::cargo_common_metadata 13 -clippy::shadow_unrelated 13 -clippy::linkedlist 14 -clippy::single_char_add_str 14 -clippy::default_trait_access 16 -clippy::needless_pass_by_value 18 -clippy::cast_possible_wrap 19 -clippy::cast_sign_loss 19 -clippy::unnecessary_wraps 19 -clippy::unused_self 19 -clippy::unusual_byte_groupings 19 -clippy::map_unwrap_or 20 -clippy::struct_excessive_bools 20 -clippy::redundant_static_lifetimes 21 -clippy::cast_lossless 23 -clippy::trivially_copy_pass_by_ref 26 -clippy::redundant_else 29 -clippy::filter_map 31 -clippy::too_many_lines 31 -clippy::cast_precision_loss 35 -clippy::if_not_else 35 -clippy::enum_glob_use 40 -clippy::unseparated_literal_suffix 41 -clippy::single_match_else 45 -clippy::inline_always 59 -clippy::match_same_arms 64 -clippy::similar_names 79 -clippy::cast_possible_truncation 91 -clippy::redundant_field_names 111 -clippy::redundant_closure_for_method_calls 135 -clippy::module_name_repetitions 137 -clippy::items_after_statements 139 -clippy::wildcard_imports 160 -clippy::doc_markdown 178 -clippy::missing_errors_doc 338 -clippy::unreadable_literal 365 -clippy::must_use_candidate 552 -- cgit 1.4.1-3-g733a5 From 5b6a18362be15a693e202a592f4ae6bc4b2844f2 Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Sat, 23 Jan 2021 01:09:51 +0100 Subject: lintcheck: fix paths in the logs --- clippy_dev/src/lintcheck.rs | 2 +- lintcheck-logs/logs.txt | 6506 +++++++++++++++++++++---------------------- 2 files changed, 3254 insertions(+), 3254 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lintcheck.rs b/clippy_dev/src/lintcheck.rs index e2099ff98c8..785c692d3cb 100644 --- a/clippy_dev/src/lintcheck.rs +++ b/clippy_dev/src/lintcheck.rs @@ -61,7 +61,7 @@ impl std::fmt::Display for ClippyWarning { fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { writeln!( f, - r#"{}/{}/{}:{}:{} {} "{}""#, + r#"{}-{}/{}:{}:{} {} "{}""#, &self.crate_name, &self.crate_version, &self.file, &self.line, &self.column, &self.linttype, &self.message ) } diff --git a/lintcheck-logs/logs.txt b/lintcheck-logs/logs.txt index f61e9b38775..e565691e0e3 100644 --- a/lintcheck-logs/logs.txt +++ b/lintcheck-logs/logs.txt @@ -1,3258 +1,3258 @@ clippy 0.1.51 (c6701036b 2021-01-23) -cargo/0.49.0//home/matthias/.rustup/toolchains/nightly-2021-01-15-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/core/src/macros/mod.rs:393:34 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/build.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.categories` metadata" -cargo/0.49.0/build.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.keywords` metadata" -cargo/0.49.0/src/bin/cargo/cli.rs:104:34 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/bin/cargo/cli.rs:121:5 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo/0.49.0/src/bin/cargo/cli.rs:157:30 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/cli.rs:184:41 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" -cargo/0.49.0/src/bin/cargo/cli.rs:196:42 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/cli.rs:200:39 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/cli.rs:231:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo/0.49.0/src/bin/cargo/cli.rs:245:22 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" -cargo/0.49.0/src/bin/cargo/cli.rs:247:47 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/cli.rs:257:22 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/cli.rs:26:20 clippy::redundant_else "redundant else block" -cargo/0.49.0/src/bin/cargo/cli.rs:7:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/bench.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/bench.rs:76:59 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/commands/build.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/check.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/clean.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/doc.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/fetch.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/fix.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/generate_lockfile.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/git_checkout.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/help.rs:20:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/bin/cargo/commands/init.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/install.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/install.rs:97:16 clippy::option_if_let_else "use Option::map_or instead of an if let/else" -cargo/0.49.0/src/bin/cargo/commands/locate_project.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/login.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/metadata.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/mod.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/new.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/new.rs:20:24 clippy::option_if_let_else "use Option::map_or instead of an if let/else" -cargo/0.49.0/src/bin/cargo/commands/owner.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/owner.rs:38:43 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/commands/owner.rs:39:43 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/commands/owner.rs:40:43 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/commands/owner.rs:43:30 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/commands/owner.rs:46:30 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/commands/package.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/pkgid.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/publish.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/publish.rs:40:47 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/commands/read_manifest.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/run.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/rustc.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/rustdoc.rs:3:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/search.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/test.rs:127:54 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/commands/test.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/tree.rs:149:49 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/commands/tree.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/uninstall.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/update.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/vendor.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/vendor.rs:96:16 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" -cargo/0.49.0/src/bin/cargo/commands/verify_project.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/version.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/yank.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/commands/yank.rs:32:36 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/commands/yank.rs:33:35 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/commands/yank.rs:34:36 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/commands/yank.rs:35:36 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/main.rs:100:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" -cargo/0.49.0/src/bin/cargo/main.rs:118:41 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/main.rs:137:43 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/main.rs:148:19 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/bin/cargo/main.rs:174:57 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/main.rs:18:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/bin/cargo/main.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.categories` metadata" -cargo/0.49.0/src/bin/cargo/main.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.keywords` metadata" -cargo/0.49.0/src/bin/cargo/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `crossbeam-utils`: 0.6.6, 0.7.2" -cargo/0.49.0/src/bin/cargo/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `hex`: 0.3.2, 0.4.0" -cargo/0.49.0/src/bin/cargo/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `humantime`: 1.3.0, 2.0.0" -cargo/0.49.0/src/bin/cargo/main.rs:72:22 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/main.rs:94:13 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" -cargo/0.49.0/src/bin/cargo/main.rs:96:41 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/bin/cargo/main.rs:98:60 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/compiler/build_config.rs:155:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -cargo/0.49.0/src/cargo/core/compiler/build_config.rs:170:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/build_config.rs:175:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/build_config.rs:180:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/build_config.rs:186:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/build_config.rs:197:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/build_config.rs:205:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/build_config.rs:51:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/build_config.rs:69:48 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -cargo/0.49.0/src/cargo/core/compiler/build_config.rs:96:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/build_context/mod.rs:44:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/build_context/mod.rs:83:20 clippy::doc_markdown "you should put `x86_64` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:108:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:121:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:149:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:411:9 clippy::needless_question_mark "Question mark operator is useless here" -cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:420:69 clippy::doc_markdown "you should put `mode/target_kind` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:423:19 clippy::doc_markdown "you should put `CrateTypes` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:424:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:469:58 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:603:19 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:665:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:82:31 clippy::doc_markdown "you should put `FileType` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:83:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:84:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:96:31 clippy::doc_markdown "you should put `FileType` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/build_context/target_info.rs:98:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/build_plan.rs:4:9 clippy::doc_markdown "you should put `BuildPlan` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/build_plan.rs:5:66 clippy::doc_markdown "you should put `BuildPlan` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/build_plan.rs:66:40 clippy::ptr_arg "writing `&PathBuf` instead of `&Path` involves a new object where a slice will do." -cargo/0.49.0/src/cargo/core/compiler/compilation.rs:150:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/compilation.rs:169:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/compilation.rs:185:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/compilation.rs:193:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/compilation.rs:194:49 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/compiler/compilation.rs:198:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/compilation.rs:314:16 clippy::doc_markdown "you should put `rustc_tool` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/compilation.rs:91:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/compile_kind.rs:118:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/compile_kind.rs:123:18 clippy::case_sensitive_file_extension_comparisons "case-sensitive file extension comparison" -cargo/0.49.0/src/cargo/core/compiler/compile_kind.rs:147:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/compile_kind.rs:157:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/compile_kind.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/compile_kind.rs:33:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/compile_kind.rs:49:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/compile_kind.rs:69:48 clippy::case_sensitive_file_extension_comparisons "case-sensitive file extension comparison" -cargo/0.49.0/src/cargo/core/compiler/context/compilation_files.rs:204:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/core/compiler/context/compilation_files.rs:277:22 clippy::doc_markdown "you should put `OUT_DIR` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/context/compilation_files.rs:324:66 clippy::doc_markdown "you should put `FileType` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/context/compilation_files.rs:393:37 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/compiler/context/compilation_files.rs:426:71 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:125:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:125:5 clippy::too_many_lines "this function has too many lines (107/100)" -cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:270:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:286:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:308:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:340:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:349:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:354:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:358:21 clippy::doc_markdown "you should put `RunCustomBuild` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:361:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:374:43 clippy::doc_markdown "you should put `RunCustomBuild` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:378:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:383:41 clippy::doc_markdown "you should put `RunCustomBuild` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:384:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:391:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:397:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:523:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:538:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:542:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:83:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/context/mod.rs:92:25 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/core/compiler/crate_type.rs:16:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/crate_type.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/crate_type.rs:40:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/crate_type.rs:49:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/crate_type.rs:60:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:150:1 clippy::too_many_lines "this function has too many lines (230/100)" -cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:353:56 clippy::manual_strip "stripping a prefix manually" -cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:448:27 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:464:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:481:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:48:56 clippy::doc_markdown "you should put `RunCustomBuild` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:561:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:567:20 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:576:28 clippy::shadow_unrelated "`mut value` is being shadowed" -cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:606:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:688:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:756:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:762:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:762:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -cargo/0.49.0/src/cargo/core/compiler/custom_build.rs:823:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1021:51 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1656:16 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1664:5 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1787:5 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1795:5 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1882:17 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1894:17 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1906:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1917:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1923:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1956:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1962:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1963:22 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1964:22 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1965:22 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1966:22 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1980:17 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1980:24 clippy::manual_strip "stripping a prefix manually" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:1986:17 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:2016:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:61:5 clippy::doc_markdown "you should put `CompileMode` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:63:12 clippy::doc_markdown "you should put `CompileKind` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:67:7 clippy::doc_markdown "you should put `CARGO_DEFAULT_LIB_METADATA[^4` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:68:5 clippy::doc_markdown "you should put `package_id` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:71:19 clippy::doc_markdown "you should put `test/bench/for_host/edition` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:755:52 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:77:5 clippy::doc_markdown "you should put `is_std` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:816:5 clippy::too_many_lines "this function has too many lines (127/100)" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:863:64 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:875:33 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:876:32 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:896:30 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:897:30 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/core/compiler/fingerprint.rs:991:37 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:12:5 clippy::doc_markdown "you should put `src/librustc_jobserver/lib.rs` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:329:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:332:23 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:34:53 clippy::doc_markdown "you should put `NeedsToken` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:35:6 clippy::doc_markdown "you should put `ReleaseToken` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:37:6 clippy::doc_markdown "you should put `NeedsToken` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:40:5 clippy::doc_markdown "you should put `NeedsToken` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:40:56 clippy::doc_markdown "you should put `NeedsToken` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:43:6 clippy::doc_markdown "you should put `ReleaseToken` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:748:16 clippy::collapsible_else_if "this `else { if .. }` block can be collapsed" -cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:749:13 clippy::if_not_else "unnecessary boolean `not` operation" -cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:786:26 clippy::unused_self "unused `self` argument" -cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:81:61 clippy::doc_markdown "you should put `DrainState` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:865:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:871:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:890:9 clippy::unused_self "unused `self` argument" -cargo/0.49.0/src/cargo/core/compiler/job_queue.rs:93:24 clippy::doc_markdown "you should put `JobQueue` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/links.rs:8:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/core/compiler/mod.rs:1016:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/mod.rs:1094:19 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/compiler/mod.rs:1131:1 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -cargo/0.49.0/src/cargo/core/compiler/mod.rs:1268:34 clippy::case_sensitive_file_extension_comparisons "case-sensitive file extension comparison" -cargo/0.49.0/src/cargo/core/compiler/mod.rs:1277:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/compiler/mod.rs:179:1 clippy::too_many_lines "this function has too many lines (162/100)" -cargo/0.49.0/src/cargo/core/compiler/mod.rs:198:78 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/compiler/mod.rs:201:25 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/core/compiler/mod.rs:267:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/compiler/mod.rs:324:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/compiler/mod.rs:364:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/compiler/mod.rs:364:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -cargo/0.49.0/src/cargo/core/compiler/mod.rs:392:45 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/compiler/mod.rs:415:23 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/core/compiler/mod.rs:464:18 clippy::ptr_arg "writing `&PathBuf` instead of `&Path` involves a new object where a slice will do." -cargo/0.49.0/src/cargo/core/compiler/mod.rs:488:61 clippy::ptr_arg "writing `&PathBuf` instead of `&Path` involves a new object where a slice will do." -cargo/0.49.0/src/cargo/core/compiler/mod.rs:667:15 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/core/compiler/mod.rs:693:1 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -cargo/0.49.0/src/cargo/core/compiler/mod.rs:725:42 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/compiler/mod.rs:736:1 clippy::too_many_lines "this function has too many lines (141/100)" -cargo/0.49.0/src/cargo/core/compiler/mod.rs:73:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/mod.rs:777:12 clippy::if_not_else "unnecessary boolean `not` operation" -cargo/0.49.0/src/cargo/core/compiler/mod.rs:873:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/compiler/output_depinfo.rs:41:13 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" -cargo/0.49.0/src/cargo/core/compiler/rustdoc.rs:16:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/core/compiler/rustdoc.rs:57:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/core/compiler/rustdoc.rs:72:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/standard_lib.rs:134:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/standard_lib.rs:16:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/standard_lib.rs:30:28 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/compiler/standard_lib.rs:34:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/timings.rs:16:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo/0.49.0/src/cargo/core/compiler/timings.rs:192:64 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo/0.49.0/src/cargo/core/compiler/timings.rs:212:58 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo/0.49.0/src/cargo/core/compiler/timings.rs:234:13 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" -cargo/0.49.0/src/cargo/core/compiler/timings.rs:355:13 clippy::cast_possible_truncation "casting `f64` to `u32` may truncate the value" -cargo/0.49.0/src/cargo/core/compiler/timings.rs:355:13 clippy::cast_sign_loss "casting `f64` to `u32` may lose the sign of the value" -cargo/0.49.0/src/cargo/core/compiler/timings.rs:397:38 clippy::cast_possible_truncation "casting `f64` to `u32` may truncate the value" -cargo/0.49.0/src/cargo/core/compiler/timings.rs:397:38 clippy::cast_sign_loss "casting `f64` to `u32` may lose the sign of the value" -cargo/0.49.0/src/cargo/core/compiler/timings.rs:484:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/compiler/timings.rs:605:38 clippy::doc_markdown "you should put `rmeta_time` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/timings.rs:605:50 clippy::doc_markdown "you should put `codegen_time` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/timings.rs:641:26 clippy::non_ascii_literal "literal non-ASCII character detected" -cargo/0.49.0/src/cargo/core/compiler/unit.rs:100:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/unit.rs:151:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/core/compiler/unit.rs:161:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/compiler/unit.rs:35:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/core/compiler/unit_dependencies.rs:154:29 clippy::doc_markdown "you should put `state.unit_dependencies` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/compiler/unit_dependencies.rs:213:1 clippy::too_many_lines "this function has too many lines (110/100)" -cargo/0.49.0/src/cargo/core/compiler/unit_dependencies.rs:52:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/unit_dependencies.rs:52:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/core/compiler/unit_graph.rs:65:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/compiler/unit_graph.rs:65:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/core/dependency.rs:157:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/dependency.rs:182:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/dependency.rs:203:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/dependency.rs:224:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/dependency.rs:23:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo/0.49.0/src/cargo/core/dependency.rs:248:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/dependency.rs:270:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/dependency.rs:274:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/dependency.rs:278:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/dependency.rs:287:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/dependency.rs:291:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/dependency.rs:305:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/dependency.rs:311:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/dependency.rs:319:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/dependency.rs:337:75 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/dependency.rs:397:56 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/dependency.rs:403:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/dependency.rs:408:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/dependency.rs:415:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/dependency.rs:419:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/dependency.rs:424:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/dependency.rs:428:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/dependency.rs:433:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/dependency.rs:438:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/dependency.rs:443:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/dependency.rs:449:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/dependency.rs:450:9 clippy::if_not_else "unnecessary `!=` operation" -cargo/0.49.0/src/cargo/core/features.rs:119:17 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/features.rs:229:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/features.rs:274:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/features.rs:278:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/features.rs:306:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/features.rs:338:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo/0.49.0/src/cargo/core/features.rs:362:25 clippy::option_option "consider using `Option` instead of `Option>` or a custom enum if you need to distinguish all 3 cases" -cargo/0.49.0/src/cargo/core/features.rs:380:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/features.rs:401:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/features.rs:409:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/features.rs:412:45 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/features.rs:416:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/features.rs:419:45 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/features.rs:424:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/features.rs:431:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/features.rs:477:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/features.rs:509:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/features.rs:518:5 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" -cargo/0.49.0/src/cargo/core/features.rs:542:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/features.rs:543:37 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/features.rs:547:60 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/features.rs:556:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/core/features.rs:563:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/core/manifest.rs:116:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -cargo/0.49.0/src/cargo/core/manifest.rs:118:58 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/manifest.rs:130:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -cargo/0.49.0/src/cargo/core/manifest.rs:143:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:159:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:162:34 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/manifest.rs:169:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:17:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/cargo/core/manifest.rs:189:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo/0.49.0/src/cargo/core/manifest.rs:215:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:222:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:22:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/core/manifest.rs:360:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:407:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:410:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:413:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:416:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:419:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:422:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:425:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:431:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:438:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:444:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:447:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:450:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:453:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:456:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:459:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:462:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:466:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:470:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:477:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:481:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:488:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/manifest.rs:512:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:516:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:520:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:524:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:528:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:538:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:557:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:561:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:565:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:569:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:577:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:581:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:588:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:617:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:632:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:648:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:659:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:66:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/core/manifest.rs:670:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:693:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:708:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:723:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:726:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:729:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:735:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:738:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:741:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:744:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:747:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:751:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:754:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:757:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:760:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:763:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:767:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:776:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:780:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:787:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:798:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:800:56 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/manifest.rs:805:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:809:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:818:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:823:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:828:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:831:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:834:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:839:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:85:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/core/manifest.rs:888:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/manifest.rs:936:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package.rs:1075:28 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/package.rs:160:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package.rs:170:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package.rs:174:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package.rs:182:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package.rs:186:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package.rs:190:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package.rs:194:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package.rs:198:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package.rs:202:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package.rs:206:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package.rs:210:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package.rs:217:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package.rs:221:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package.rs:222:35 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/package.rs:226:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package.rs:227:35 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/package.rs:230:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package.rs:239:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/package.rs:249:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package.rs:287:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/core/package.rs:385:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/package.rs:421:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -cargo/0.49.0/src/cargo/core/package.rs:425:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/package.rs:452:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/package.rs:453:60 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/package.rs:459:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/package.rs:473:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/package.rs:587:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/package.rs:588:9 clippy::needless_question_mark "Question mark operator is useless here" -cargo/0.49.0/src/cargo/core/package.rs:682:46 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" -cargo/0.49.0/src/cargo/core/package.rs:682:46 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" -cargo/0.49.0/src/cargo/core/package.rs:682:63 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" -cargo/0.49.0/src/cargo/core/package.rs:682:63 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" -cargo/0.49.0/src/cargo/core/package.rs:731:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/package.rs:790:13 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/core/package.rs:988:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/core/package_id.rs:115:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/package_id.rs:124:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package_id.rs:139:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package_id.rs:142:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package_id.rs:145:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package_id.rs:149:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package_id.rs:157:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package_id.rs:161:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package_id.rs:169:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package_id.rs:174:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/core/package_id_spec.rs:101:39 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/package_id_spec.rs:143:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package_id_spec.rs:147:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package_id_spec.rs:151:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package_id_spec.rs:160:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/package_id_spec.rs:179:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/package_id_spec.rs:212:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/package_id_spec.rs:231:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/core/package_id_spec.rs:51:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/package_id_spec.rs:77:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/package_id_spec.rs:88:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/profiles.rs:1004:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/profiles.rs:1014:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/profiles.rs:1018:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/profiles.rs:1028:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/profiles.rs:106:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/profiles.rs:143:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -cargo/0.49.0/src/cargo/core/profiles.rs:286:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/profiles.rs:294:40 clippy::if_not_else "unnecessary boolean `not` operation" -cargo/0.49.0/src/cargo/core/profiles.rs:30:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/profiles.rs:342:25 clippy::shadow_unrelated "`maker` is being shadowed" -cargo/0.49.0/src/cargo/core/profiles.rs:370:41 clippy::unused_self "unused `self` argument" -cargo/0.49.0/src/cargo/core/profiles.rs:370:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/profiles.rs:372:9 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" -cargo/0.49.0/src/cargo/core/profiles.rs:382:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/profiles.rs:383:28 clippy::if_not_else "unnecessary boolean `not` operation" -cargo/0.49.0/src/cargo/core/profiles.rs:397:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/profiles.rs:405:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/profiles.rs:607:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo/0.49.0/src/cargo/core/profiles.rs:909:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/profiles.rs:923:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/profiles.rs:934:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/profiles.rs:987:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/registry.rs:111:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/registry.rs:127:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/registry.rs:168:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/registry.rs:19:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/registry.rs:240:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/registry.rs:26:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/registry.rs:344:49 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/registry.rs:369:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/registry.rs:424:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/registry.rs:49:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/core/registry.rs:520:17 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/core/registry.rs:763:53 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/registry.rs:765:53 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/registry.rs:807:14 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/registry.rs:814:53 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/resolver/conflict_cache.rs:197:29 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/resolver/conflict_cache.rs:41:38 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" -cargo/0.49.0/src/cargo/core/resolver/context.rs:274:53 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/resolver/context.rs:42:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/core/resolver/context.rs:74:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/encode.rs:156:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/resolver/encode.rs:156:5 clippy::too_many_lines "this function has too many lines (164/100)" -cargo/0.49.0/src/cargo/core/resolver/encode.rs:339:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" -cargo/0.49.0/src/cargo/core/resolver/encode.rs:438:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/resolver/encode.rs:449:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/resolver/encode.rs:529:34 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/resolver/encode.rs:602:59 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/resolver/encode.rs:623:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/core/resolver/encode.rs:652:27 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/core/resolver/encode.rs:674:51 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/resolver/errors.rs:103:22 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/resolver/errors.rs:104:22 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/resolver/errors.rs:206:9 clippy::if_not_else "unnecessary boolean `not` operation" -cargo/0.49.0/src/cargo/core/resolver/errors.rs:257:45 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/resolver/errors.rs:27:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/errors.rs:305:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo/0.49.0/src/cargo/core/resolver/errors.rs:70:1 clippy::too_many_lines "this function has too many lines (207/100)" -cargo/0.49.0/src/cargo/core/resolver/features.rs:104:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/core/resolver/features.rs:111:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/features.rs:162:56 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/resolver/features.rs:179:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/core/resolver/features.rs:186:23 clippy::doc_markdown "you should put `RequestedFeatures` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/resolver/features.rs:187:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/features.rs:199:23 clippy::doc_markdown "you should put `RequestedFeatures` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/resolver/features.rs:200:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/features.rs:221:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/features.rs:231:21 clippy::doc_markdown "you should put `pkg_id/is_build` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/resolver/features.rs:233:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/features.rs:247:58 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/resolver/features.rs:278:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/resolver/features.rs:394:27 clippy::doc_markdown "you should put `FeatureValue` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/resolver/features.rs:460:19 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/core/resolver/features.rs:480:24 clippy::doc_markdown "you should put `FeatureValues` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/resolver/features.rs:496:24 clippy::doc_markdown "you should put `FeatureValues` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/resolver/features.rs:58:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/core/resolver/features.rs:67:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo/0.49.0/src/cargo/core/resolver/mod.rs:1017:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/core/resolver/mod.rs:1045:57 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/resolver/mod.rs:122:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/resolver/mod.rs:142:44 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/resolver/mod.rs:180:1 clippy::too_many_lines "this function has too many lines (225/100)" -cargo/0.49.0/src/cargo/core/resolver/mod.rs:311:17 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/core/resolver/mod.rs:421:52 clippy::filter_map_next "called `filter_map(..).next()` on an `Iterator`. This is more succinctly expressed by calling `.find_map(..)` instead." -cargo/0.49.0/src/cargo/core/resolver/mod.rs:457:69 clippy::filter_map_next "called `filter_map(..).next()` on an `Iterator`. This is more succinctly expressed by calling `.find_map(..)` instead." -cargo/0.49.0/src/cargo/core/resolver/mod.rs:470:37 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/core/resolver/mod.rs:607:11 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo/0.49.0/src/cargo/core/resolver/mod.rs:631:21 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/core/resolver/mod.rs:942:15 clippy::if_not_else "unnecessary boolean `not` operation" -cargo/0.49.0/src/cargo/core/resolver/mod.rs:988:20 clippy::redundant_else "redundant else block" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:120:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:132:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:199:24 clippy::redundant_else "redundant else block" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:235:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:239:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:255:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:259:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:263:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:269:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:273:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:274:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:280:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:284:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:288:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:292:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:296:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:300:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:315:13 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:354:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:362:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:60:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/core/resolver/resolve.rs:76:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/types.rs:111:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/resolver/types.rs:121:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/types.rs:141:19 clippy::doc_markdown "you should put `ResolveOpts` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/resolver/types.rs:142:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/types.rs:149:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/resolver/types.rs:181:9 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" -cargo/0.49.0/src/cargo/core/resolver/types.rs:187:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -cargo/0.49.0/src/cargo/core/resolver/types.rs:261:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -cargo/0.49.0/src/cargo/core/shell.rs:113:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/shell.rs:130:9 clippy::single_match_else "you seem to be trying to use `match` for an equality check. Consider using `if`" -cargo/0.49.0/src/cargo/core/shell.rs:148:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/shell.rs:153:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/shell.rs:163:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/shell.rs:18:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/shell.rs:198:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/shell.rs:206:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/shell.rs:214:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/shell.rs:228:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/shell.rs:239:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/shell.rs:250:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/shell.rs:259:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/shell.rs:267:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/shell.rs:26:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/shell.rs:277:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/shell.rs:282:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/shell.rs:314:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/shell.rs:322:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/shell.rs:330:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/shell.rs:98:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/source/mod.rs:103:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/source/mod.rs:247:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/core/source/mod.rs:261:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/source/mod.rs:268:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/source/mod.rs:273:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/source/mod.rs:291:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/source/mod.rs:302:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/source/mod.rs:307:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/source/mod.rs:31:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/source/mod.rs:37:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/source/mod.rs:39:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/source/mod.rs:47:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/source/mod.rs:50:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/source/mod.rs:52:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/source/mod.rs:63:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/source/mod.rs:74:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/source/mod.rs:83:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/source/source_id.rs:107:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/source/source_id.rs:128:50 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/source/source_id.rs:147:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/source/source_id.rs:156:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/source/source_id.rs:162:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/source/source_id.rs:166:19 clippy::doc_markdown "you should put `SourceId` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/source/source_id.rs:167:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/source/source_id.rs:171:19 clippy::doc_markdown "you should put `SourceId` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/source/source_id.rs:172:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/source/source_id.rs:178:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/source/source_id.rs:187:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/source/source_id.rs:18:74 clippy::default_trait_access "calling `std::sync::Mutex::default()` is more clear than this expression" -cargo/0.49.0/src/cargo/core/source/source_id.rs:195:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/source/source_id.rs:207:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/source/source_id.rs:213:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/source/source_id.rs:217:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/source/source_id.rs:225:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/source/source_id.rs:228:16 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" -cargo/0.49.0/src/cargo/core/source/source_id.rs:236:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/source/source_id.rs:241:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/source/source_id.rs:252:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/source/source_id.rs:257:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/source/source_id.rs:262:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/source/source_id.rs:305:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/source/source_id.rs:310:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/source/source_id.rs:318:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/source/source_id.rs:326:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/source/source_id.rs:355:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/source/source_id.rs:393:61 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:394:42 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:395:42 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:397:71 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:397:71 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:398:47 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:398:47 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:399:47 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:399:47 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:401:63 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:401:63 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:401:63 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:402:43 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:402:43 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:402:43 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:403:43 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:403:43 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:403:43 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:406:21 clippy::enum_glob_use "usage of wildcard import for enum variants" -cargo/0.49.0/src/cargo/core/source/source_id.rs:412:41 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:413:36 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:414:36 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:420:47 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:420:47 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/source/source_id.rs:512:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo/0.49.0/src/cargo/core/source/source_id.rs:513:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo/0.49.0/src/cargo/core/source/source_id.rs:517:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo/0.49.0/src/cargo/core/source/source_id.rs:518:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo/0.49.0/src/cargo/core/source/source_id.rs:525:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo/0.49.0/src/cargo/core/source/source_id.rs:526:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo/0.49.0/src/cargo/core/source/source_id.rs:530:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo/0.49.0/src/cargo/core/source/source_id.rs:531:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo/0.49.0/src/cargo/core/source/source_id.rs:535:33 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo/0.49.0/src/cargo/core/source/source_id.rs:536:37 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo/0.49.0/src/cargo/core/source/source_id.rs:537:42 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo/0.49.0/src/cargo/core/source/source_id.rs:538:38 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo/0.49.0/src/cargo/core/source/source_id.rs:548:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/core/source/source_id.rs:597:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/summary.rs:103:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/summary.rs:123:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/summary.rs:150:1 clippy::too_many_lines "this function has too many lines (141/100)" -cargo/0.49.0/src/cargo/core/summary.rs:158:9 clippy::enum_glob_use "usage of wildcard import for enum variants" -cargo/0.49.0/src/cargo/core/summary.rs:181:21 clippy::if_not_else "unnecessary boolean `not` operation" -cargo/0.49.0/src/cargo/core/summary.rs:192:28 clippy::redundant_else "redundant else block" -cargo/0.49.0/src/cargo/core/summary.rs:258:32 clippy::redundant_else "redundant else block" -cargo/0.49.0/src/cargo/core/summary.rs:281:28 clippy::redundant_else "redundant else block" -cargo/0.49.0/src/cargo/core/summary.rs:303:28 clippy::redundant_else "redundant else block" -cargo/0.49.0/src/cargo/core/summary.rs:321:51 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/core/summary.rs:344:5 clippy::doc_markdown "you should put `FeatureValue` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/summary.rs:350:85 clippy::doc_markdown "you should put `FeatureValue` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/summary.rs:36:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/summary.rs:378:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/summary.rs:386:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/summary.rs:387:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -cargo/0.49.0/src/cargo/core/summary.rs:407:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -cargo/0.49.0/src/cargo/core/summary.rs:69:34 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/summary.rs:75:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/summary.rs:78:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/summary.rs:81:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/summary.rs:84:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/summary.rs:87:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/summary.rs:90:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/summary.rs:93:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/summary.rs:96:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/summary.rs:99:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/workspace.rs:1056:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -cargo/0.49.0/src/cargo/core/workspace.rs:113:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/core/workspace.rs:1157:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/core/workspace.rs:128:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/core/workspace.rs:150:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/workspace.rs:159:16 clippy::redundant_else "redundant else block" -cargo/0.49.0/src/cargo/core/workspace.rs:197:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/workspace.rs:225:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/workspace.rs:255:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/workspace.rs:267:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/workspace.rs:329:37 clippy::doc_markdown "you should put `VirtualManifest` between ticks in the documentation" -cargo/0.49.0/src/cargo/core/workspace.rs:410:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/workspace.rs:440:9 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -cargo/0.49.0/src/cargo/core/workspace.rs:511:32 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/core/workspace.rs:561:25 clippy::non_ascii_literal "literal non-ASCII character detected" -cargo/0.49.0/src/cargo/core/workspace.rs:613:13 clippy::filter_map "called `filter_map(..).map(..)` on an `Iterator`" -cargo/0.49.0/src/cargo/core/workspace.rs:615:22 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/core/workspace.rs:762:27 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/core/workspace.rs:784:17 clippy::if_not_else "unnecessary boolean `not` operation" -cargo/0.49.0/src/cargo/core/workspace.rs:849:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/workspace.rs:893:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/core/workspace.rs:906:24 clippy::redundant_else "redundant else block" -cargo/0.49.0/src/cargo/core/workspace.rs:932:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/lib.rs:177:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/lib.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.categories` metadata" -cargo/0.49.0/src/cargo/lib.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.keywords` metadata" -cargo/0.49.0/src/cargo/lib.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `crossbeam-utils`: 0.6.6, 0.7.2" -cargo/0.49.0/src/cargo/lib.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `hex`: 0.3.2, 0.4.0" -cargo/0.49.0/src/cargo/lib.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `humantime`: 1.3.0, 2.0.0" -cargo/0.49.0/src/cargo/ops/cargo_clean.rs:205:23 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/ops/cargo_clean.rs:27:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_clean.rs:27:1 clippy::too_many_lines "this function has too many lines (120/100)" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:1078:14 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:109:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:119:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:1227:17 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:127:35 clippy::from_iter_instead_of_collect "usage of `FromIterator::from_iter`" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:173:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:205:36 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:242:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:249:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:258:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:267:16 clippy::needless_question_mark "Question mark operator is useless here" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:275:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:275:1 clippy::too_many_lines "this function has too many lines (219/100)" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:468:9 clippy::default_trait_access "calling `std::collections::HashMap::default()` is more clear than this expression" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:548:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:556:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:574:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:583:21 clippy::doc_markdown "you should put `CompileFilter` between ticks in the documentation" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:584:5 clippy::fn_params_excessive_bools "more than 3 bools in function parameters" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:584:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:592:9 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:593:9 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:607:13 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:612:21 clippy::doc_markdown "you should put `CompileFilter` between ticks in the documentation" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:613:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:618:9 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:641:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:652:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:655:50 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:673:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:692:49 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:703:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:729:1 clippy::too_many_lines "this function has too many lines (205/100)" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:82:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_compile.rs:874:69 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/ops/cargo_doc.rs:20:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_fetch.rs:15:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_fetch.rs:27:46 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:160:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:175:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:22:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:37:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:37:1 clippy::too_many_lines "this function has too many lines (171/100)" -cargo/0.49.0/src/cargo/ops/cargo_install.rs:13:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/cargo/ops/cargo_install.rs:148:1 clippy::fn_params_excessive_bools "more than 3 bools in function parameters" -cargo/0.49.0/src/cargo/ops/cargo_install.rs:148:1 clippy::too_many_lines "this function has too many lines (316/100)" -cargo/0.49.0/src/cargo/ops/cargo_install.rs:178:24 clippy::collapsible_else_if "this `else { if .. }` block can be collapsed" -cargo/0.49.0/src/cargo/ops/cargo_install.rs:202:17 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/ops/cargo_install.rs:236:16 clippy::collapsible_else_if "this `else { if .. }` block can be collapsed" -cargo/0.49.0/src/cargo/ops/cargo_install.rs:312:64 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/ops/cargo_install.rs:32:13 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" -cargo/0.49.0/src/cargo/ops/cargo_install.rs:339:12 clippy::collapsible_else_if "this `else { if .. }` block can be collapsed" -cargo/0.49.0/src/cargo/ops/cargo_install.rs:37:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_install.rs:454:22 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/ops/cargo_install.rs:483:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/ops/cargo_install.rs:683:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_new.rs:101:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_new.rs:245:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/ops/cargo_new.rs:251:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/ops/cargo_new.rs:367:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_new.rs:405:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_new.rs:489:5 clippy::doc_markdown "you should put `IgnoreList` between ticks in the documentation" -cargo/0.49.0/src/cargo/ops/cargo_new.rs:525:47 clippy::doc_markdown "you should put `IgnoreList` between ticks in the documentation" -cargo/0.49.0/src/cargo/ops/cargo_new.rs:525:9 clippy::doc_markdown "you should put `format_existing` between ticks in the documentation" -cargo/0.49.0/src/cargo/ops/cargo_new.rs:572:34 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/ops/cargo_new.rs:623:1 clippy::too_many_lines "this function has too many lines (130/100)" -cargo/0.49.0/src/cargo/ops/cargo_new.rs:781:5 clippy::filter_map_next "called `filter_map(..).next()` on an `Iterator`. This is more succinctly expressed by calling `.find_map(..)` instead." -cargo/0.49.0/src/cargo/ops/cargo_new.rs:800:16 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/ops/cargo_output_metadata.rs:163:36 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/ops/cargo_output_metadata.rs:27:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_output_metadata.rs:45:45 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/ops/cargo_package.rs:144:1 clippy::too_many_lines "this function has too many lines (112/100)" -cargo/0.49.0/src/cargo/ops/cargo_package.rs:207:13 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/ops/cargo_package.rs:25:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo/0.49.0/src/cargo/ops/cargo_package.rs:307:54 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/ops/cargo_package.rs:394:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/ops/cargo_package.rs:425:61 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/ops/cargo_package.rs:459:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/ops/cargo_package.rs:66:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_package.rs:93:20 clippy::if_not_else "unnecessary boolean `not` operation" -cargo/0.49.0/src/cargo/ops/cargo_pkgid.rs:5:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_read_manifest.rs:14:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_read_manifest.rs:171:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/ops/cargo_read_manifest.rs:37:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_read_manifest.rs:57:49 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/ops/cargo_read_manifest.rs:69:37 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/ops/cargo_run.rs:25:24 clippy::if_not_else "unnecessary boolean `not` operation" -cargo/0.49.0/src/cargo/ops/cargo_run.rs:35:9 clippy::if_not_else "unnecessary boolean `not` operation" -cargo/0.49.0/src/cargo/ops/cargo_run.rs:37:16 clippy::redundant_else "redundant else block" -cargo/0.49.0/src/cargo/ops/cargo_run.rs:53:9 clippy::if_not_else "unnecessary boolean `not` operation" -cargo/0.49.0/src/cargo/ops/cargo_run.rs:65:16 clippy::redundant_else "redundant else block" -cargo/0.49.0/src/cargo/ops/cargo_run.rs:9:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_test.rs:16:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_test.rs:43:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_test.rs:84:17 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/ops/cargo_uninstall.rs:14:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/cargo_uninstall.rs:7:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:147:9 clippy::doc_markdown "you should put `PackageId` between ticks in the documentation" -cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:233:21 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:244:22 clippy::doc_markdown "you should put `PackageId` between ticks in the documentation" -cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:244:63 clippy::doc_markdown "you should put `PackageId` between ticks in the documentation" -cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:253:17 clippy::if_not_else "unnecessary boolean `not` operation" -cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:370:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:505:8 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" -cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:525:10 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:542:27 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:542:5 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:561:20 clippy::redundant_else "redundant else block" -cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:613:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:645:41 clippy::doc_markdown "you should put `BTreeSet` between ticks in the documentation" -cargo/0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:92:19 clippy::doc_markdown "you should put `InstallTracker` between ticks in the documentation" -cargo/0.49.0/src/cargo/ops/fix.rs:200:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/fix.rs:200:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/ops/fix.rs:424:20 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" -cargo/0.49.0/src/cargo/ops/fix.rs:455:13 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/ops/fix.rs:506:17 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/ops/fix.rs:608:9 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" -cargo/0.49.0/src/cargo/ops/fix.rs:612:42 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/ops/fix.rs:619:48 clippy::manual_strip "stripping a prefix manually" -cargo/0.49.0/src/cargo/ops/fix.rs:66:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/ops/fix.rs:66:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo/0.49.0/src/cargo/ops/fix.rs:708:18 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/ops/fix.rs:77:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/lockfile.rs:154:13 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo/0.49.0/src/cargo/ops/lockfile.rs:217:9 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo/0.49.0/src/cargo/ops/lockfile.rs:30:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/lockfile.rs:35:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/lockfile.rs:35:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/ops/lockfile.rs:87:1 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -cargo/0.49.0/src/cargo/ops/lockfile.rs:8:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/lockfile.rs:8:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/ops/registry.rs:150:21 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/ops/registry.rs:188:1 clippy::too_many_lines "this function has too many lines (130/100)" -cargo/0.49.0/src/cargo/ops/registry.rs:212:32 clippy::if_not_else "unnecessary `!=` operation" -cargo/0.49.0/src/cargo/ops/registry.rs:222:53 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/ops/registry.rs:224:44 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/ops/registry.rs:31:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/ops/registry.rs:346:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/registry.rs:346:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/ops/registry.rs:351:26 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/ops/registry.rs:385:12 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo/0.49.0/src/cargo/ops/registry.rs:386:15 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo/0.49.0/src/cargo/ops/registry.rs:38:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo/0.49.0/src/cargo/ops/registry.rs:477:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/registry.rs:483:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/registry.rs:503:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/registry.rs:505:38 clippy::default_trait_access "calling `util::config::CargoHttpConfig::default()` is more clear than this expression" -cargo/0.49.0/src/cargo/ops/registry.rs:510:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/registry.rs:529:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/ops/registry.rs:53:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/registry.rs:573:22 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/ops/registry.rs:608:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/registry.rs:621:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/registry.rs:671:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/registry.rs:671:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/ops/registry.rs:674:10 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo/0.49.0/src/cargo/ops/registry.rs:678:17 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/ops/registry.rs:730:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/registry.rs:731:16 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/ops/registry.rs:785:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/registry.rs:794:16 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/ops/registry.rs:828:14 clippy::doc_markdown "you should put `SourceId` between ticks in the documentation" -cargo/0.49.0/src/cargo/ops/registry.rs:848:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/resolve.rs:199:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/resolve.rs:199:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/ops/resolve.rs:199:1 clippy::too_many_lines "this function has too many lines (137/100)" -cargo/0.49.0/src/cargo/ops/resolve.rs:241:28 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/ops/resolve.rs:28:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/ops/resolve.rs:384:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/resolve.rs:417:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/resolve.rs:589:9 clippy::shadow_unrelated "`keep` is being shadowed" -cargo/0.49.0/src/cargo/ops/resolve.rs:58:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/resolve.rs:58:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/ops/resolve.rs:602:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/ops/resolve.rs:75:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/resolve.rs:75:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/ops/tree/graph.rs:129:26 clippy::doc_markdown "you should put `PackageIds` between ticks in the documentation" -cargo/0.49.0/src/cargo/ops/tree/graph.rs:152:15 clippy::match_on_vec_items "indexing into a vector may panic" -cargo/0.49.0/src/cargo/ops/tree/graph.rs:173:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/ops/tree/graph.rs:234:46 clippy::filter_map "called `filter(..).flat_map(..)` on an `Iterator`" -cargo/0.49.0/src/cargo/ops/tree/graph.rs:328:44 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/ops/tree/graph.rs:330:50 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/ops/tree/graph.rs:563:35 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/ops/tree/mod.rs:112:11 clippy::non_ascii_literal "literal non-ASCII character detected" -cargo/0.49.0/src/cargo/ops/tree/mod.rs:113:10 clippy::non_ascii_literal "literal non-ASCII character detected" -cargo/0.49.0/src/cargo/ops/tree/mod.rs:114:10 clippy::non_ascii_literal "literal non-ASCII character detected" -cargo/0.49.0/src/cargo/ops/tree/mod.rs:115:12 clippy::non_ascii_literal "literal non-ASCII character detected" -cargo/0.49.0/src/cargo/ops/tree/mod.rs:126:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/tree/mod.rs:21:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/ops/tree/mod.rs:21:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo/0.49.0/src/cargo/ops/tree/mod.rs:360:30 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/ops/tree/mod.rs:58:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/ops/vendor.rs:14:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/ops/vendor.rs:21:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/ops/vendor.rs:314:34 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/ops/vendor.rs:320:29 clippy::case_sensitive_file_extension_comparisons "case-sensitive file extension comparison" -cargo/0.49.0/src/cargo/ops/vendor.rs:320:60 clippy::case_sensitive_file_extension_comparisons "case-sensitive file extension comparison" -cargo/0.49.0/src/cargo/ops/vendor.rs:324:13 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" -cargo/0.49.0/src/cargo/ops/vendor.rs:70:1 clippy::too_many_lines "this function has too many lines (175/100)" -cargo/0.49.0/src/cargo/sources/config.rs:102:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/config.rs:111:28 clippy::needless_question_mark "Question mark operator is useless here" -cargo/0.49.0/src/cargo/sources/config.rs:133:48 clippy::needless_question_mark "Question mark operator is useless here" -cargo/0.49.0/src/cargo/sources/config.rs:135:67 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/sources/config.rs:206:36 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo/0.49.0/src/cargo/sources/config.rs:282:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/sources/config.rs:70:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/config.rs:81:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/config.rs:97:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/sources/directory.rs:14:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/sources/directory.rs:90:56 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/sources/git/source.rs:14:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/sources/git/source.rs:25:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/git/source.rs:49:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/sources/git/source.rs:53:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/git/source.rs:69:20 clippy::comparison_to_empty "comparison to empty slice" -cargo/0.49.0/src/cargo/sources/git/utils.rs:1025:19 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/sources/git/utils.rs:1157:36 clippy::case_sensitive_file_extension_comparisons "case-sensitive file extension comparison" -cargo/0.49.0/src/cargo/sources/git/utils.rs:1158:9 clippy::manual_strip "stripping a suffix manually" -cargo/0.49.0/src/cargo/sources/git/utils.rs:134:12 clippy::upper_case_acronyms "name `GitShortID` contains a capitalized acronym" -cargo/0.49.0/src/cargo/sources/git/utils.rs:176:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/sources/git/utils.rs:180:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/sources/git/utils.rs:184:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/git/utils.rs:188:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/git/utils.rs:242:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/git/utils.rs:253:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/git/utils.rs:262:13 clippy::if_not_else "unnecessary boolean `not` operation" -cargo/0.49.0/src/cargo/sources/git/utils.rs:289:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/git/utils.rs:294:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/sources/git/utils.rs:298:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/git/utils.rs:308:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/git/utils.rs:472:9 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" -cargo/0.49.0/src/cargo/sources/git/utils.rs:489:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/sources/git/utils.rs:503:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/sources/git/utils.rs:528:28 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/sources/git/utils.rs:537:21 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" -cargo/0.49.0/src/cargo/sources/git/utils.rs:588:1 clippy::too_many_lines "this function has too many lines (135/100)" -cargo/0.49.0/src/cargo/sources/git/utils.rs:692:9 clippy::vec_init_then_push "calls to `push` immediately after creation" -cargo/0.49.0/src/cargo/sources/git/utils.rs:758:9 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo/0.49.0/src/cargo/sources/git/utils.rs:858:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/path.rs:129:44 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/sources/path.rs:143:44 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/sources/path.rs:15:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/sources/path.rs:282:50 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/sources/path.rs:313:21 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/sources/path.rs:314:21 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/sources/path.rs:319:21 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/sources/path.rs:339:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/sources/path.rs:339:9 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -cargo/0.49.0/src/cargo/sources/path.rs:380:9 clippy::unused_self "unused `self` argument" -cargo/0.49.0/src/cargo/sources/path.rs:419:50 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/sources/path.rs:429:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/path.rs:460:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/sources/path.rs:473:43 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/sources/path.rs:482:43 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/sources/path.rs:63:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/path.rs:77:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/path.rs:98:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/registry/index.rs:117:23 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo/0.49.0/src/cargo/sources/registry/index.rs:121:70 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo/0.49.0/src/cargo/sources/registry/index.rs:167:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/sources/registry/index.rs:215:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/sources/registry/index.rs:324:23 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/sources/registry/index.rs:468:40 clippy::doc_markdown "you should put `SourceId` between ticks in the documentation" -cargo/0.49.0/src/cargo/sources/registry/index.rs:590:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/sources/registry/index.rs:648:17 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/sources/registry/index.rs:736:1 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -cargo/0.49.0/src/cargo/sources/registry/index.rs:95:37 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -cargo/0.49.0/src/cargo/sources/registry/local.rs:12:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/sources/registry/mod.rs:192:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/sources/registry/mod.rs:203:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/sources/registry/mod.rs:229:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/sources/registry/mod.rs:372:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/sources/registry/mod.rs:373:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/registry/mod.rs:375:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/registry/mod.rs:381:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/registry/mod.rs:382:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/registry/mod.rs:383:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/registry/mod.rs:384:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/registry/mod.rs:452:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/sources/registry/mod.rs:582:20 clippy::redundant_else "redundant else block" -cargo/0.49.0/src/cargo/sources/registry/mod.rs:621:9 clippy::if_not_else "unnecessary `!=` operation" -cargo/0.49.0/src/cargo/sources/registry/remote.rs:139:17 clippy::unused_self "unused `self` argument" -cargo/0.49.0/src/cargo/sources/registry/remote.rs:32:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/sources/registry/remote.rs:72:13 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/sources/replaced.rs:12:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/sources/replaced.rs:5:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/util/canonical_url.rs:19:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/canonical_url.rs:50:41 clippy::case_sensitive_file_extension_comparisons "case-sensitive file extension comparison" -cargo/0.49.0/src/cargo/util/canonical_url.rs:65:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/command_prelude.rs:218:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/command_prelude.rs:222:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/command_prelude.rs:234:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/command_prelude.rs:249:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/command_prelude.rs:264:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/command_prelude.rs:279:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/command_prelude.rs:298:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/command_prelude.rs:320:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/command_prelude.rs:328:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/command_prelude.rs:352:13 clippy::if_not_else "unnecessary boolean `not` operation" -cargo/0.49.0/src/cargo/util/command_prelude.rs:363:13 clippy::if_not_else "unnecessary boolean `not` operation" -cargo/0.49.0/src/cargo/util/command_prelude.rs:378:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/command_prelude.rs:387:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/command_prelude.rs:387:5 clippy::too_many_lines "this function has too many lines (104/100)" -cargo/0.49.0/src/cargo/util/command_prelude.rs:39:20 clippy::doc_markdown "you should put `arg_package_spec` between ticks in the documentation" -cargo/0.49.0/src/cargo/util/command_prelude.rs:504:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/command_prelude.rs:516:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/command_prelude.rs:530:40 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/util/command_prelude.rs:531:43 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/util/command_prelude.rs:536:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/command_prelude.rs:556:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/command_prelude.rs:575:49 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/util/command_prelude.rs:580:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/command_prelude.rs:631:18 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/util/command_prelude.rs:638:18 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/util/command_prelude.rs:647:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/command_prelude.rs:651:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/command_prelude.rs:662:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/command_prelude.rs:665:51 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/util/config/de.rs:420:16 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo/0.49.0/src/cargo/util/config/de.rs:46:25 clippy::doc_markdown "you should put `CV::List` between ticks in the documentation" -cargo/0.49.0/src/cargo/util/config/de.rs:47:24 clippy::doc_markdown "you should put `ConfigSeqAccess` between ticks in the documentation" -cargo/0.49.0/src/cargo/util/config/de.rs:527:53 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo/0.49.0/src/cargo/util/config/de.rs:530:53 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo/0.49.0/src/cargo/util/config/de.rs:532:68 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo/0.49.0/src/cargo/util/config/key.rs:11:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/util/config/key.rs:69:9 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo/0.49.0/src/cargo/util/config/mod.rs:100:71 clippy::doc_markdown "you should put `OptValue` between ticks in the documentation" -cargo/0.49.0/src/cargo/util/config/mod.rs:100:71 clippy::doc_markdown "you should put `OptValue` between ticks in the documentation" -cargo/0.49.0/src/cargo/util/config/mod.rs:100:71 clippy::doc_markdown "you should put `OptValue` between ticks in the documentation" -cargo/0.49.0/src/cargo/util/config/mod.rs:1049:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:1064:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:1090:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:1166:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:1179:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:1181:33 clippy::needless_question_mark "Question mark operator is useless here" -cargo/0.49.0/src/cargo/util/config/mod.rs:1184:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:1186:33 clippy::needless_question_mark "Question mark operator is useless here" -cargo/0.49.0/src/cargo/util/config/mod.rs:1189:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:1191:33 clippy::needless_question_mark "Question mark operator is useless here" -cargo/0.49.0/src/cargo/util/config/mod.rs:1203:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:1211:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:1216:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:1225:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:1229:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:124:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo/0.49.0/src/cargo/util/config/mod.rs:1254:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:1279:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:1281:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo/0.49.0/src/cargo/util/config/mod.rs:1323:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/util/config/mod.rs:1339:39 clippy::unused_self "unused `self` argument" -cargo/0.49.0/src/cargo/util/config/mod.rs:1344:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/util/config/mod.rs:1420:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/util/config/mod.rs:1553:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:1560:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:1567:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:1574:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:1581:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:1588:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/config/mod.rs:1598:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/config/mod.rs:1619:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/config/mod.rs:1623:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:1623:64 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo/0.49.0/src/cargo/util/config/mod.rs:1649:9 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" -cargo/0.49.0/src/cargo/util/config/mod.rs:1699:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/util/config/mod.rs:1730:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/util/config/mod.rs:1757:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/util/config/mod.rs:1770:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/util/config/mod.rs:1778:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/util/config/mod.rs:1804:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/util/config/mod.rs:1896:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/config/mod.rs:1901:5 clippy::doc_markdown "you should put `StringList` between ticks in the documentation" -cargo/0.49.0/src/cargo/util/config/mod.rs:214:13 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" -cargo/0.49.0/src/cargo/util/config/mod.rs:259:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:298:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:311:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:318:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:353:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:401:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:411:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:419:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:431:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:449:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:454:16 clippy::option_if_let_else "use Option::map_or instead of an if let/else" -cargo/0.49.0/src/cargo/util/config/mod.rs:547:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:556:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:582:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:595:20 clippy::doc_markdown "you should put `StringList` between ticks in the documentation" -cargo/0.49.0/src/cargo/util/config/mod.rs:689:20 clippy::unused_self "unused `self` argument" -cargo/0.49.0/src/cargo/util/config/mod.rs:699:5 clippy::fn_params_excessive_bools "more than 3 bools in function parameters" -cargo/0.49.0/src/cargo/util/config/mod.rs:699:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:719:58 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/util/config/mod.rs:816:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/config/mod.rs:875:36 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/util/config/mod.rs:876:37 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/util/config/path.rs:10:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/util/config/path.rs:14:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/config/path.rs:48:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/util/config/target.rs:12:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/util/config/target.rs:24:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/util/config/value.rs:29:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/util/config/value.rs:80:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/config/value.rs:81:9 clippy::match_like_matches_macro "match expression looks like `matches!` macro" -cargo/0.49.0/src/cargo/util/cpu.rs:11:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/cpu.rs:22:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/cpu.rs:82:25 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -cargo/0.49.0/src/cargo/util/cpu.rs:82:9 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -cargo/0.49.0/src/cargo/util/dependency_queue.rs:109:27 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/util/dependency_queue.rs:151:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/dependency_queue.rs:156:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/dependency_queue.rs:46:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/dependency_queue.rs:91:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/util/diagnostic_server.rs:218:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/util/diagnostic_server.rs:230:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/diagnostic_server.rs:242:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/diagnostic_server.rs:58:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/diagnostic_server.rs:96:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/diagnostic_server.rs:96:5 clippy::too_many_lines "this function has too many lines (110/100)" -cargo/0.49.0/src/cargo/util/diagnostic_server.rs:99:21 clippy::shadow_unrelated "`msg` is being shadowed" -cargo/0.49.0/src/cargo/util/errors.rs:101:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/errors.rs:143:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/errors.rs:150:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/errors.rs:15:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/errors.rs:237:5 clippy::pub_enum_variant_names "variant name ends with the enum's name" -cargo/0.49.0/src/cargo/util/errors.rs:245:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/errors.rs:321:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/errors.rs:328:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/errors.rs:356:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/errors.rs:391:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/util/errors.rs:392:13 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/cargo/util/errors.rs:465:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/errors.rs:473:5 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" -cargo/0.49.0/src/cargo/util/errors.rs:66:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/flock.rs:115:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/flock.rs:11:5 clippy::wildcard_imports "usage of wildcard import" -cargo/0.49.0/src/cargo/util/flock.rs:134:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/flock.rs:142:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/flock.rs:150:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/flock.rs:156:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/flock.rs:170:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/flock.rs:192:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/flock.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/flock.rs:321:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/util/flock.rs:335:23 clippy::cast_possible_truncation "casting `i64` to `u32` may truncate the value" -cargo/0.49.0/src/cargo/util/flock.rs:335:23 clippy::cast_sign_loss "casting `i64` to `u32` may lose the sign of the value" -cargo/0.49.0/src/cargo/util/flock.rs:335:44 clippy::cast_possible_truncation "casting `i64` to `u32` may truncate the value" -cargo/0.49.0/src/cargo/util/flock.rs:379:35 clippy::match_same_arms "this `match` has identical arm bodies" -cargo/0.49.0/src/cargo/util/flock.rs:37:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/flock.rs:43:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/flock.rs:52:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/graph.rs:10:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/graph.rs:41:51 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/util/graph.rs:45:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/hasher.rs:12:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/hasher.rs:9:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/util/hex.rs:10:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" -cargo/0.49.0/src/cargo/util/hex.rs:11:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" -cargo/0.49.0/src/cargo/util/hex.rs:12:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" -cargo/0.49.0/src/cargo/util/hex.rs:13:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" -cargo/0.49.0/src/cargo/util/hex.rs:14:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" -cargo/0.49.0/src/cargo/util/hex.rs:15:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" -cargo/0.49.0/src/cargo/util/hex.rs:25:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/hex.rs:6:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/util/hex.rs:6:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/hex.rs:8:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" -cargo/0.49.0/src/cargo/util/hex.rs:9:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" -cargo/0.49.0/src/cargo/util/important_paths.rs:23:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/important_paths.rs:6:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/interning.rs:66:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/interning.rs:77:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/into_url.rs:10:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/into_url_with_base.rs:9:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/job.rs:20:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/lev_distance.rs:3:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/lockserver.rs:111:32 clippy::redundant_else "redundant else block" -cargo/0.49.0/src/cargo/util/lockserver.rs:158:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/lockserver.rs:46:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/lockserver.rs:58:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/lockserver.rs:62:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/mod.rs:68:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/mod.rs:79:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/network.rs:12:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/network.rs:19:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/network.rs:84:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/paths.rs:109:12 clippy::redundant_else "redundant else block" -cargo/0.49.0/src/cargo/util/paths.rs:114:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/paths.rs:121:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/paths.rs:125:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/paths.rs:130:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/paths.rs:14:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/paths.rs:14:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo/0.49.0/src/cargo/util/paths.rs:151:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/paths.rs:167:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/paths.rs:173:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/paths.rs:178:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/paths.rs:185:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/paths.rs:199:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/paths.rs:215:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/paths.rs:228:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/paths.rs:251:9 clippy::option_if_let_else "use Option::map_or instead of an if let/else" -cargo/0.49.0/src/cargo/util/paths.rs:267:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/paths.rs:276:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/paths.rs:29:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/paths.rs:303:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/paths.rs:312:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/paths.rs:346:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/paths.rs:415:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/paths.rs:445:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/paths.rs:459:45 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/util/paths.rs:469:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/paths.rs:54:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/paths.rs:61:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/paths.rs:63:19 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" -cargo/0.49.0/src/cargo/util/paths.rs:88:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/paths.rs:93:31 clippy::comparison_to_empty "comparison to empty slice" -cargo/0.49.0/src/cargo/util/process_builder.rs:106:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/process_builder.rs:111:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/process_builder.rs:122:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/process_builder.rs:132:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/process_builder.rs:152:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/process_builder.rs:185:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/process_builder.rs:190:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/process_builder.rs:218:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/process_builder.rs:307:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/process_builder.rs:343:39 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo/0.49.0/src/cargo/util/progress.rs:122:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/progress.rs:136:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/progress.rs:15:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/util/progress.rs:249:19 clippy::cast_precision_loss "casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -cargo/0.49.0/src/cargo/util/progress.rs:249:34 clippy::cast_precision_loss "casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -cargo/0.49.0/src/cargo/util/progress.rs:250:19 clippy::if_not_else "unnecessary boolean `not` operation" -cargo/0.49.0/src/cargo/util/progress.rs:263:22 clippy::cast_precision_loss "casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -cargo/0.49.0/src/cargo/util/progress.rs:264:22 clippy::cast_possible_truncation "casting `f64` to `usize` may truncate the value" -cargo/0.49.0/src/cargo/util/progress.rs:264:22 clippy::cast_sign_loss "casting `f64` to `usize` may lose the sign of the value" -cargo/0.49.0/src/cargo/util/progress.rs:269:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo/0.49.0/src/cargo/util/progress.rs:272:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo/0.49.0/src/cargo/util/progress.rs:274:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo/0.49.0/src/cargo/util/progress.rs:280:13 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo/0.49.0/src/cargo/util/progress.rs:282:9 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo/0.49.0/src/cargo/util/progress.rs:89:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/progress.rs:97:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/queue.rs:25:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/read2.rs:11:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/read2.rs:31:17 clippy::similar_names "binding's name is too similar to existing binding" -cargo/0.49.0/src/cargo/util/restricted_names.rs:13:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/restricted_names.rs:26:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/restricted_names.rs:35:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/restricted_names.rs:45:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/restricted_names.rs:87:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/restricted_names.rs:89:21 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/util/restricted_names.rs:8:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/rustc.rs:103:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/rustc.rs:114:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" -cargo/0.49.0/src/cargo/util/rustc.rs:115:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" -cargo/0.49.0/src/cargo/util/rustc.rs:162:17 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/util/rustc.rs:39:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/sha256.rs:10:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/sha256.rs:20:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/sha256.rs:31:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/sha256.rs:40:24 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo/0.49.0/src/cargo/util/to_semver.rs:5:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/toml/mod.rs:1005:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/toml/mod.rs:1005:5 clippy::too_many_lines "this function has too many lines (282/100)" -cargo/0.49.0/src/cargo/util/toml/mod.rs:1094:36 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/util/toml/mod.rs:1121:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/util/toml/mod.rs:1197:32 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" -cargo/0.49.0/src/cargo/util/toml/mod.rs:124:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/toml/mod.rs:1504:9 clippy::unused_self "unused `self` argument" -cargo/0.49.0/src/cargo/util/toml/mod.rs:1526:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/toml/mod.rs:1582:19 clippy::default_trait_access "calling `util::toml::DetailedTomlDependency::default()` is more clear than this expression" -cargo/0.49.0/src/cargo/util/toml/mod.rs:1598:5 clippy::too_many_lines "this function has too many lines (153/100)" -cargo/0.49.0/src/cargo/util/toml/mod.rs:1687:33 clippy::unnecessary_lazy_evaluations "unnecessary closure used to substitute value for `Option::None`" -cargo/0.49.0/src/cargo/util/toml/mod.rs:178:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/util/toml/mod.rs:248:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/util/toml/mod.rs:274:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/util/toml/mod.rs:277:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/toml/mod.rs:281:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/toml/mod.rs:285:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/toml/mod.rs:294:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/util/toml/mod.rs:31:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/toml/mod.rs:381:35 clippy::cast_possible_truncation "casting `i64` to `u32` may truncate the value" -cargo/0.49.0/src/cargo/util/toml/mod.rs:381:35 clippy::cast_sign_loss "casting `i64` to `u32` may lose the sign of the value" -cargo/0.49.0/src/cargo/util/toml/mod.rs:388:35 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" -cargo/0.49.0/src/cargo/util/toml/mod.rs:398:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/util/toml/mod.rs:450:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/toml/mod.rs:536:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/toml/mod.rs:783:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/util/toml/mod.rs:824:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo/0.49.0/src/cargo/util/toml/mod.rs:834:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/toml/mod.rs:83:42 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/util/toml/mod.rs:852:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/toml/mod.rs:852:5 clippy::too_many_lines "this function has too many lines (138/100)" -cargo/0.49.0/src/cargo/util/toml/mod.rs:962:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/util/toml/mod.rs:979:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/util/toml/mod.rs:98:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/util/toml/mod.rs:999:23 clippy::default_trait_access "calling `util::toml::DetailedTomlDependency::default()` is more clear than this expression" -cargo/0.49.0/src/cargo/util/toml/targets.rs:112:27 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/util/toml/targets.rs:325:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo/0.49.0/src/cargo/util/toml/targets.rs:586:21 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/util/toml/targets.rs:593:42 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/util/toml/targets.rs:605:19 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/util/toml/targets.rs:612:42 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/util/toml/targets.rs:756:36 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo/0.49.0/src/cargo/util/vcs.rs:10:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo/0.49.0/src/cargo/util/vcs.rs:33:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/vcs.rs:37:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/vcs.rs:43:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/vcs.rs:47:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/vcs.rs:59:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/vcs.rs:66:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/workspace.rs:52:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/workspace.rs:56:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/workspace.rs:60:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo/0.49.0/src/cargo/util/workspace.rs:64:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron/0.6.1/src/error.rs:24:1 clippy::module_name_repetitions "item name ends with its containing module's name" -iron/0.6.1/src/iron.rs:105:13 clippy::redundant_field_names "redundant field names in struct initialization" -iron/0.6.1/src/iron.rs:119:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron/0.6.1/src/iron.rs:133:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron/0.6.1/src/iron.rs:143:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron/0.6.1/src/iron.rs:149:13 clippy::redundant_field_names "redundant field names in struct initialization" -iron/0.6.1/src/iron.rs:167:49 clippy::similar_names "binding's name is too similar to existing binding" -iron/0.6.1/src/iron.rs:80:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron/0.6.1/src/iron.rs:85:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron/0.6.1/src/iron.rs:90:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron/0.6.1/src/lib.rs:1:null clippy::cargo_common_metadata "package `iron` is missing `package.categories` metadata" -iron/0.6.1/src/lib.rs:1:null clippy::cargo_common_metadata "package `iron` is missing `package.keywords` metadata" -iron/0.6.1/src/lib.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `log`: 0.3.9, 0.4.8" -iron/0.6.1/src/middleware/mod.rs:137:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron/0.6.1/src/middleware/mod.rs:150:1 clippy::module_name_repetitions "item name ends with its containing module's name" -iron/0.6.1/src/middleware/mod.rs:152:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron/0.6.1/src/middleware/mod.rs:159:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron/0.6.1/src/middleware/mod.rs:171:1 clippy::module_name_repetitions "item name ends with its containing module's name" -iron/0.6.1/src/middleware/mod.rs:173:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron/0.6.1/src/middleware/mod.rs:182:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron/0.6.1/src/middleware/mod.rs:192:1 clippy::module_name_repetitions "item name ends with its containing module's name" -iron/0.6.1/src/middleware/mod.rs:217:25 clippy::doc_markdown "you should put `ChainBuilder` between ticks in the documentation" -iron/0.6.1/src/middleware/mod.rs:328:20 clippy::similar_names "binding's name is too similar to existing binding" -iron/0.6.1/src/middleware/mod.rs:360:16 clippy::similar_names "binding's name is too similar to existing binding" -iron/0.6.1/src/middleware/mod.rs:368:33 clippy::similar_names "binding's name is too similar to existing binding" -iron/0.6.1/src/middleware/mod.rs:428:40 clippy::similar_names "binding's name is too similar to existing binding" -iron/0.6.1/src/middleware/mod.rs:434:40 clippy::similar_names "binding's name is too similar to existing binding" -iron/0.6.1/src/middleware/mod.rs:444:40 clippy::similar_names "binding's name is too similar to existing binding" -iron/0.6.1/src/modifiers.rs:132:14 clippy::expect_fun_call "use of `expect` followed by a function call" -iron/0.6.1/src/request/mod.rs:113:24 clippy::similar_names "binding's name is too similar to existing binding" -iron/0.6.1/src/request/mod.rs:121:13 clippy::redundant_field_names "redundant field names in struct initialization" -iron/0.6.1/src/request/mod.rs:123:13 clippy::redundant_field_names "redundant field names in struct initialization" -iron/0.6.1/src/request/mod.rs:124:13 clippy::redundant_field_names "redundant field names in struct initialization" -iron/0.6.1/src/request/mod.rs:126:13 clippy::redundant_field_names "redundant field names in struct initialization" -iron/0.6.1/src/request/mod.rs:128:13 clippy::redundant_field_names "redundant field names in struct initialization" -iron/0.6.1/src/request/mod.rs:153:69 clippy::doc_markdown "you should put `HttpReader` between ticks in the documentation" -iron/0.6.1/src/request/mod.rs:154:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron/0.6.1/src/request/mod.rs:32:1 clippy::manual_non_exhaustive "this seems like a manual implementation of the non-exhaustive pattern" -iron/0.6.1/src/request/mod.rs:75:34 clippy::doc_markdown "you should put `HttpRequest` between ticks in the documentation" -iron/0.6.1/src/request/mod.rs:77:39 clippy::doc_markdown "you should put `HttpRequest` between ticks in the documentation" -iron/0.6.1/src/request/mod.rs:78:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron/0.6.1/src/request/mod.rs:82:13 clippy::similar_names "binding's name is too similar to existing binding" -iron/0.6.1/src/request/mod.rs:83:29 clippy::similar_names "binding's name is too similar to existing binding" -iron/0.6.1/src/request/mod.rs:85:24 clippy::similar_names "binding's name is too similar to existing binding" -iron/0.6.1/src/request/url.rs:109:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron/0.6.1/src/request/url.rs:117:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron/0.6.1/src/request/url.rs:129:1 clippy::from_over_into "an implementation of `From` is preferred since it gives you `Into<_>` for free where the reverse isn't true" -iron/0.6.1/src/request/url.rs:21:14 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" -iron/0.6.1/src/request/url.rs:22:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron/0.6.1/src/request/url.rs:31:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron/0.6.1/src/request/url.rs:47:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron/0.6.1/src/request/url.rs:52:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron/0.6.1/src/request/url.rs:57:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron/0.6.1/src/request/url.rs:63:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron/0.6.1/src/request/url.rs:73:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron/0.6.1/src/request/url.rs:83:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron/0.6.1/src/request/url.rs:96:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron/0.6.1/src/response.rs:121:19 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -iron/0.6.1/src/response.rs:125:43 clippy::redundant_closure_for_method_calls "redundant closure found" -iron/0.6.1/src/response.rs:139:41 clippy::redundant_closure_for_method_calls "redundant closure found" -iron/0.6.1/src/response.rs:24:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron/0.6.1/src/response.rs:95:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron/0.6.1/src/response.rs:95:5 clippy::new_without_default "you should consider adding a `Default` implementation for `response::Response`" -libc/0.2.81/build.rs:114:19 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" -libc/0.2.81/build.rs:124:5 clippy::question_mark "this block may be rewritten with the `?` operator" -libc/0.2.81/build.rs:133:5 clippy::question_mark "this block may be rewritten with the `?` operator" -libc/0.2.81/src/macros.rs:243:17 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" -libc/0.2.81/src/macros.rs:243:17 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" -libc/0.2.81/src/macros.rs:243:17 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" -libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:428:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:429:30 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:431:30 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:432:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:433:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:434:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:595:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:596:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:597:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:622:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:673:34 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:696:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:697:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:698:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:699:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:712:34 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:721:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:722:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:723:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:751:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:752:30 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:753:30 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:754:30 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:755:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:756:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:757:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:758:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:759:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:760:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:768:30 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:769:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:771:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:772:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:773:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:774:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:775:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:776:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:777:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:778:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:779:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:780:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:781:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:782:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:783:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:784:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:785:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:786:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:787:30 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:788:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:789:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:790:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:791:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:792:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:794:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:795:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:796:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:797:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:798:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:799:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:800:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:801:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:803:27 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:804:28 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:805:28 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:806:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:807:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:808:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:809:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:810:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:811:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:812:30 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:813:30 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:814:30 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:815:30 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:816:30 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:817:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:818:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:821:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:822:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:823:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:824:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:825:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:826:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:827:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:828:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:829:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:830:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:831:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:832:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:833:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:834:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:835:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:836:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:841:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:842:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:843:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:844:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:1120:38 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:178:34 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:291:5 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:291:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:299:11 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:302:5 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:302:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:312:11 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:352:20 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:355:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:355:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:359:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:359:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:363:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:363:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:367:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:367:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:371:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:371:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:534:36 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:645:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:727:40 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:728:40 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:729:39 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:731:44 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:732:36 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:733:41 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:734:43 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:735:42 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:736:40 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:737:36 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:738:37 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:741:39 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:742:40 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:743:40 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:744:40 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:745:40 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:746:43 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:747:42 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:748:40 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:749:39 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:750:41 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:751:41 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:752:43 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:753:42 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:755:42 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:756:41 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:757:41 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:758:39 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:759:39 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:761:41 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:762:44 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:763:45 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:764:40 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:765:40 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:766:40 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:767:44 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:768:44 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:769:39 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:770:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:771:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:772:37 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:773:39 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:774:45 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:775:41 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:776:39 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:803:34 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:841:30 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:842:37 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:982:40 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/gnu/mod.rs:984:46 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1209:36 clippy::cast_possible_truncation "casting `i32` to `i16` may truncate the value" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1210:36 clippy::cast_possible_truncation "casting `i32` to `i16` may truncate the value" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1235:39 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1236:41 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1274:42 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1324:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1333:37 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1334:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1346:34 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1346:34 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1346:34 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1347:37 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1347:37 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1347:37 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1348:36 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1348:36 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1348:36 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1349:37 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1349:37 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1349:37 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1350:35 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1350:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1350:35 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1351:36 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1351:36 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1351:36 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1352:31 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1352:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1352:31 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1419:36 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1420:36 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1421:36 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1422:36 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1423:36 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1490:37 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1561:46 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1562:45 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1567:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1568:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1586:26 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1587:34 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1588:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1589:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1897:38 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1898:51 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1900:39 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1969:34 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1970:34 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1971:36 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1972:36 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1973:36 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1974:37 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1975:37 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1976:36 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1977:36 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1978:39 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1979:39 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1980:39 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1981:39 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1982:39 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1983:39 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1984:38 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1985:38 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1986:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1987:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1988:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1989:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1990:38 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1991:37 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1992:37 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1993:38 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1994:37 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1995:37 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1996:37 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1997:37 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1998:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:1999:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2000:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2001:34 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2002:34 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2003:34 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2004:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2005:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2032:30 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2033:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2034:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2035:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2036:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2037:28 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2038:27 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2039:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2041:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2042:28 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2043:27 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2044:34 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2045:27 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2046:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2048:28 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2049:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2050:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2051:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2052:26 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2053:36 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2318:42 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2321:38 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2331:39 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2487:42 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2488:42 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2489:43 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2490:43 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2491:43 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2493:47 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2494:44 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2495:46 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2496:47 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2497:49 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2498:48 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2499:50 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2500:45 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2572:9 clippy::needless_return "unneeded `return` statement" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2578:20 clippy::zero_ptr "`0 as *mut _` detected" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2588:13 clippy::zero_ptr "`0 as *mut _` detected" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2590:13 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2596:52 clippy::used_underscore_binding "used binding `_dummy` which is prefixed with an underscore. A leading underscore signals that a binding will not be used." -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2597:11 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2601:21 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2611:9 clippy::unused_unit "unneeded unit expression" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2619:9 clippy::unused_unit "unneeded unit expression" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2634:9 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2647:25 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2648:25 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2649:9 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2654:18 clippy::identity_op "the operation is ineffective. Consider reducing it to `(dev & 0x00000000000000ff)`" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2654:25 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2655:25 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2656:9 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2660:21 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2661:21 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2663:25 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2664:25 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2665:16 clippy::identity_op "the operation is ineffective. Consider reducing it to `(minor & 0x000000ff)`" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2665:25 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:2666:25 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/linux/mod.rs:954:34 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1000:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1001:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1002:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1016:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1017:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1018:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1019:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1020:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1029:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1030:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1031:30 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1032:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1033:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1034:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1035:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1041:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1042:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1043:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1044:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1045:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1046:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1047:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1048:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1049:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1050:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1051:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1053:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1054:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1055:30 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1056:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1057:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1058:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1059:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1060:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1073:42 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1074:43 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1075:37 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1076:37 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1077:41 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1078:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1079:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1080:36 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1081:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1082:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1083:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1084:38 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1086:30 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1087:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1089:30 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1090:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1091:30 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1094:40 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1095:37 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1096:41 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1097:40 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1098:39 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1099:34 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1100:36 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1101:38 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1102:37 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1105:44 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1106:41 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1107:42 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1108:42 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1109:41 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1110:46 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1111:41 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1112:44 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1113:40 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1114:47 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1115:36 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1126:34 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1127:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1128:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1179:32 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1180:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:1218:27 clippy::identity_op "the operation is ineffective. Consider reducing it to `IPOPT_CONTROL`" -libc/0.2.81/src/unix/linux_like/mod.rs:1314:9 clippy::precedence "operator precedence can trip the unwary" -libc/0.2.81/src/unix/linux_like/mod.rs:1321:13 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" -libc/0.2.81/src/unix/linux_like/mod.rs:1323:13 clippy::zero_ptr "`0 as *mut _` detected" -libc/0.2.81/src/unix/linux_like/mod.rs:1332:9 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -libc/0.2.81/src/unix/linux_like/mod.rs:1337:9 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -libc/0.2.81/src/unix/linux_like/mod.rs:1341:18 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" -libc/0.2.81/src/unix/linux_like/mod.rs:1344:9 clippy::needless_return "unneeded `return` statement" -libc/0.2.81/src/unix/linux_like/mod.rs:1348:18 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" -libc/0.2.81/src/unix/linux_like/mod.rs:1350:9 clippy::needless_return "unneeded `return` statement" -libc/0.2.81/src/unix/linux_like/mod.rs:1354:18 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" -libc/0.2.81/src/unix/linux_like/mod.rs:1357:9 clippy::needless_return "unneeded `return` statement" -libc/0.2.81/src/unix/linux_like/mod.rs:1361:21 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" -libc/0.2.81/src/unix/linux_like/mod.rs:1381:9 clippy::cast_possible_truncation "casting `i32` to `i8` may truncate the value" -libc/0.2.81/src/unix/linux_like/mod.rs:1389:9 clippy::verbose_bit_mask "bit mask could be simplified with a call to `trailing_zeros`" -libc/0.2.81/src/unix/linux_like/mod.rs:446:31 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:591:36 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:592:38 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:593:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:594:33 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:595:34 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:596:36 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:597:37 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:598:37 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:599:39 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:600:34 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:601:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:602:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:607:37 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:608:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:764:35 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:765:39 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/linux_like/mod.rs:991:30 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/mod.rs:198:29 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/mod.rs:199:28 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/mod.rs:201:35 clippy::unnecessary_cast "casting integer literal to `usize` is unnecessary" -libc/0.2.81/src/unix/mod.rs:202:35 clippy::unnecessary_cast "casting integer literal to `usize` is unnecessary" -libc/0.2.81/src/unix/mod.rs:282:40 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/mod.rs:284:41 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/mod.rs:285:36 clippy::unreadable_literal "long literal lacking separators" -libc/0.2.81/src/unix/mod.rs:34:10 clippy::upper_case_acronyms "name `DIR` contains a capitalized acronym" -libc/0.2.81/src/unix/mod.rs:386:10 clippy::upper_case_acronyms "name `FILE` contains a capitalized acronym" -log/0.4.11/src/lib.rs:1047:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:1053:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:1059:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:1093:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:1093:5 clippy::new_without_default "you should consider adding a `Default` implementation for `MetadataBuilder<'a>`" -log/0.4.11/src/lib.rs:1118:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:1177:1 clippy::inline_always "you have declared `#[inline(always)]` on `max_level`. This is usually a bad idea" -log/0.4.11/src/lib.rs:1178:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:1306:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -log/0.4.11/src/lib.rs:1358:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:1359:5 clippy::if_not_else "unnecessary `!=` operation" -log/0.4.11/src/lib.rs:1407:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:329:27 clippy::derive_hash_xor_eq "you are deriving `Hash` but have implemented `PartialEq` explicitly" -log/0.4.11/src/lib.rs:356:1 clippy::expl_impl_clone_on_copy "you are implementing `Clone` explicitly on a `Copy` type" -log/0.4.11/src/lib.rs:448:12 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" -log/0.4.11/src/lib.rs:500:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:506:28 clippy::trivially_copy_pass_by_ref "this argument (8 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -log/0.4.11/src/lib.rs:506:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:520:27 clippy::derive_hash_xor_eq "you are deriving `Hash` but have implemented `PartialEq` explicitly" -log/0.4.11/src/lib.rs:538:1 clippy::expl_impl_clone_on_copy "you are implementing `Clone` explicitly on a `Copy` type" -log/0.4.11/src/lib.rs:653:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:661:21 clippy::trivially_copy_pass_by_ref "this argument (8 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -log/0.4.11/src/lib.rs:661:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:677:44 clippy::match_same_arms "this `match` has identical arm bodies" -log/0.4.11/src/lib.rs:758:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:764:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:770:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:776:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:782:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:788:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:794:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:803:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:809:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:818:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:908:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log/0.4.11/src/lib.rs:908:5 clippy::new_without_default "you should consider adding a `Default` implementation for `RecordBuilder<'a>`" -log/0.4.11/src/lib.rs:995:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/detection.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -proc-macro2/1.0.24/src/fallback.rs:108:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" -proc-macro2/1.0.24/src/fallback.rs:269:20 clippy::unused_self "unused `self` argument" -proc-macro2/1.0.24/src/fallback.rs:430:24 clippy::trivially_copy_pass_by_ref "this argument (0 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -proc-macro2/1.0.24/src/fallback.rs:437:23 clippy::trivially_copy_pass_by_ref "this argument (0 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -proc-macro2/1.0.24/src/fallback.rs:437:23 clippy::unused_self "unused `self` argument" -proc-macro2/1.0.24/src/fallback.rs:471:17 clippy::trivially_copy_pass_by_ref "this argument (0 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -proc-macro2/1.0.24/src/fallback.rs:471:17 clippy::unused_self "unused `self` argument" -proc-macro2/1.0.24/src/fallback.rs:654:5 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" -proc-macro2/1.0.24/src/fallback.rs:655:12 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" -proc-macro2/1.0.24/src/fallback.rs:661:5 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" -proc-macro2/1.0.24/src/fallback.rs:662:12 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" -proc-macro2/1.0.24/src/fallback.rs:664:12 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" -proc-macro2/1.0.24/src/fallback.rs:674:37 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" -proc-macro2/1.0.24/src/fallback.rs:678:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -proc-macro2/1.0.24/src/fallback.rs:85:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -proc-macro2/1.0.24/src/fallback.rs:882:43 clippy::unused_self "unused `self` argument" -proc-macro2/1.0.24/src/lib.rs:1017:9 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:1081:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:1099:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:1117:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:1135:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:1141:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:1146:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:1151:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:1156:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:152:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:157:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:373:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:383:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:397:24 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -proc-macro2/1.0.24/src/lib.rs:397:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:403:23 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -proc-macro2/1.0.24/src/lib.rs:403:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:418:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:425:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:464:17 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -proc-macro2/1.0.24/src/lib.rs:500:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:626:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:633:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:641:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:652:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:662:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:672:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:734:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:743:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:752:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:757:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:788:19 clippy::doc_markdown "you should put `XID_Start` between ticks in the documentation" -proc-macro2/1.0.24/src/lib.rs:788:69 clippy::doc_markdown "you should put `XID_Continue` between ticks in the documentation" -proc-macro2/1.0.24/src/lib.rs:891:36 clippy::doc_markdown "you should put `syn::parse_str` between ticks in the documentation" -proc-macro2/1.0.24/src/lib.rs:894:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:911:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/lib.rs:996:9 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2/1.0.24/src/parse.rs:552:5 clippy::while_let_on_iterator "this loop could be written as a `for` loop" -proc-macro2/1.0.24/src/parse.rs:584:21 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" -proc-macro2/1.0.24/src/parse.rs:602:20 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" -proc-macro2/1.0.24/src/parse.rs:696:29 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" -proc-macro2/1.0.24/src/parse.rs:702:34 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" -proc-macro2/1.0.24/src/parse.rs:708:34 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" -proc-macro2/1.0.24/src/parse.rs:793:5 clippy::vec_init_then_push "calls to `push` immediately after creation" -proc-macro2/1.0.24/src/parse.rs:803:15 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" -proc-macro2/1.0.24/src/parse.rs:808:15 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" -proc-macro2/1.0.24/src/wrapper.rs:415:24 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -proc-macro2/1.0.24/src/wrapper.rs:429:23 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -proc-macro2/1.0.24/src/wrapper.rs:492:17 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -quote/1.0.7/src/ext.rs:10:1 clippy::module_name_repetitions "item name ends with its containing module's name" -quote/1.0.7/src/ext.rs:7:5 clippy::doc_markdown "you should put `TokenStream` between ticks in the documentation" -quote/1.0.7/src/ident_fragment.rs:13:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -quote/1.0.7/src/ident_fragment.rs:51:31 clippy::manual_strip "stripping a prefix manually" -quote/1.0.7/src/runtime.rs:52:5 clippy::module_name_repetitions "item name ends with its containing module's name" -quote/1.0.7/src/runtime.rs:63:5 clippy::module_name_repetitions "item name ends with its containing module's name" -quote/1.0.7/src/runtime.rs:66:33 clippy::doc_markdown "you should put `DoesNotHaveIter` between ticks in the documentation" -quote/1.0.7/src/runtime.rs:80:5 clippy::module_name_repetitions "item name ends with its containing module's name" -rand/0.7.3/src/distributions/bernoulli.rs:103:20 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" -rand/0.7.3/src/distributions/bernoulli.rs:103:20 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" -rand/0.7.3/src/distributions/bernoulli.rs:116:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -rand/0.7.3/src/distributions/bernoulli.rs:123:21 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" -rand/0.7.3/src/distributions/bernoulli.rs:123:21 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" -rand/0.7.3/src/distributions/bernoulli.rs:63:26 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand/0.7.3/src/distributions/bernoulli.rs:63:27 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -rand/0.7.3/src/distributions/bernoulli.rs:67:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand/0.7.3/src/distributions/bernoulli.rs:95:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -rand/0.7.3/src/distributions/bernoulli.rs:96:13 clippy::manual_range_contains "manual `Range::contains` implementation" -rand/0.7.3/src/distributions/binomial.rs:107:23 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand/0.7.3/src/distributions/binomial.rs:112:44 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand/0.7.3/src/distributions/binomial.rs:116:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rand/0.7.3/src/distributions/binomial.rs:150:28 clippy::redundant_else "redundant else block" -rand/0.7.3/src/distributions/binomial.rs:153:24 clippy::if_not_else "unnecessary boolean `not` operation" -rand/0.7.3/src/distributions/binomial.rs:158:28 clippy::redundant_else "redundant else block" -rand/0.7.3/src/distributions/binomial.rs:164:33 clippy::cast_sign_loss "casting `i64` to `u64` may lose the sign of the value" -rand/0.7.3/src/distributions/binomial.rs:166:28 clippy::redundant_else "redundant else block" -rand/0.7.3/src/distributions/binomial.rs:175:47 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand/0.7.3/src/distributions/binomial.rs:185:38 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand/0.7.3/src/distributions/binomial.rs:194:38 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand/0.7.3/src/distributions/binomial.rs:202:28 clippy::redundant_else "redundant else block" -rand/0.7.3/src/distributions/binomial.rs:209:25 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand/0.7.3/src/distributions/binomial.rs:221:26 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand/0.7.3/src/distributions/binomial.rs:222:26 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand/0.7.3/src/distributions/binomial.rs:223:25 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand/0.7.3/src/distributions/binomial.rs:224:25 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand/0.7.3/src/distributions/binomial.rs:226:17 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rand/0.7.3/src/distributions/binomial.rs:233:32 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand/0.7.3/src/distributions/binomial.rs:234:27 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand/0.7.3/src/distributions/binomial.rs:251:22 clippy::cast_sign_loss "casting `i64` to `u64` may lose the sign of the value" -rand/0.7.3/src/distributions/binomial.rs:255:9 clippy::if_not_else "unnecessary `!=` operation" -rand/0.7.3/src/distributions/binomial.rs:35:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/distributions/binomial.rs:45:17 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand/0.7.3/src/distributions/binomial.rs:46:5 clippy::cast_possible_truncation "casting `f64` to `i64` may truncate the value" -rand/0.7.3/src/distributions/binomial.rs:50:5 clippy::too_many_lines "this function has too many lines (143/100)" -rand/0.7.3/src/distributions/binomial.rs:76:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rand/0.7.3/src/distributions/binomial.rs:78:12 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand/0.7.3/src/distributions/binomial.rs:81:21 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand/0.7.3/src/distributions/binomial.rs:82:32 clippy::cast_possible_truncation "casting `u64` to `i32` may truncate the value" -rand/0.7.3/src/distributions/binomial.rs:88:26 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand/0.7.3/src/distributions/binomial.rs:99:21 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand/0.7.3/src/distributions/cauchy.rs:33:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/distributions/dirichlet.rs:52:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/distributions/dirichlet.rs:64:32 clippy::unseparated_literal_suffix "float type suffix should be separated by an underscore" -rand/0.7.3/src/distributions/dirichlet.rs:65:23 clippy::unseparated_literal_suffix "float type suffix should be separated by an underscore" -rand/0.7.3/src/distributions/exponential.rs:76:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/distributions/float.rs:73:1 clippy::module_name_repetitions "item name ends with its containing module's name" -rand/0.7.3/src/distributions/gamma.rs:13:5 clippy::enum_glob_use "usage of wildcard import for enum variants" -rand/0.7.3/src/distributions/gamma.rs:14:5 clippy::enum_glob_use "usage of wildcard import for enum variants" -rand/0.7.3/src/distributions/gamma.rs:189:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/distributions/gamma.rs:230:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/distributions/gamma.rs:259:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/distributions/gamma.rs:287:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/distributions/gamma.rs:90:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/distributions/integer.rs:23:9 clippy::cast_possible_truncation "casting `u32` to `u8` may truncate the value" -rand/0.7.3/src/distributions/integer.rs:30:9 clippy::cast_possible_truncation "casting `u32` to `u16` may truncate the value" -rand/0.7.3/src/distributions/integer.rs:69:9 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -rand/0.7.3/src/distributions/mod.rs:263:5 clippy::inline_always "you have declared `#[inline(always)]` on `next`. This is usually a bad idea" -rand/0.7.3/src/distributions/normal.rs:100:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/distributions/normal.rs:119:1 clippy::module_name_repetitions "item name ends with its containing module's name" -rand/0.7.3/src/distributions/normal.rs:131:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/distributions/normal.rs:31:1 clippy::module_name_repetitions "item name ends with its containing module's name" -rand/0.7.3/src/distributions/normal.rs:47:25 clippy::unseparated_literal_suffix "float type suffix should be separated by an underscore" -rand/0.7.3/src/distributions/normal.rs:48:25 clippy::unseparated_literal_suffix "float type suffix should be separated by an underscore" -rand/0.7.3/src/distributions/other.rs:89:9 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -rand/0.7.3/src/distributions/pareto.rs:32:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/distributions/poisson.rs:35:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/distributions/poisson.rs:87:30 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" -rand/0.7.3/src/distributions/poisson.rs:87:30 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" -rand/0.7.3/src/distributions/triangular.rs:32:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/distributions/uniform.rs:146:4 clippy::needless_doctest_main "needless `fn main` in doctest" -rand/0.7.3/src/distributions/uniform.rs:199:1 clippy::module_name_repetitions "item name ends with its containing module's name" -rand/0.7.3/src/distributions/uniform.rs:214:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand/0.7.3/src/distributions/uniform.rs:283:14 clippy::doc_markdown "you should put `SampleUniform` between ticks in the documentation" -rand/0.7.3/src/distributions/uniform.rs:283:46 clippy::doc_markdown "you should put `SampleUniform` between ticks in the documentation" -rand/0.7.3/src/distributions/uniform.rs:296:5 clippy::inline_always "you have declared `#[inline(always)]` on `borrow`. This is usually a bad idea" -rand/0.7.3/src/distributions/uniform.rs:304:5 clippy::inline_always "you have declared `#[inline(always)]` on `borrow`. This is usually a bad idea" -rand/0.7.3/src/distributions/uniform.rs:350:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand/0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand/0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" -rand/0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" -rand/0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" -rand/0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" -rand/0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" -rand/0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" -rand/0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" -rand/0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" -rand/0.7.3/src/distributions/uniform.rs:56:10 clippy::doc_markdown "you should put `SampleBorrow` between ticks in the documentation" -rand/0.7.3/src/distributions/uniform.rs:647:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand/0.7.3/src/distributions/uniform.rs:840:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand/0.7.3/src/distributions/uniform.rs:913:13 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" -rand/0.7.3/src/distributions/uniform.rs:943:54 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" -rand/0.7.3/src/distributions/unit_circle.rs:30:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/distributions/unit_sphere.rs:24:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand/0.7.3/src/distributions/unit_sphere.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/distributions/utils.rs:218:18 clippy::upper_case_acronyms "name `FloatSIMDUtils` contains a capitalized acronym" -rand/0.7.3/src/distributions/utils.rs:247:15 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" -rand/0.7.3/src/distributions/utils.rs:248:20 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" -rand/0.7.3/src/distributions/utils.rs:249:18 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" -rand/0.7.3/src/distributions/utils.rs:253:18 clippy::upper_case_acronyms "name `FloatAsSIMD` contains a capitalized acronym" -rand/0.7.3/src/distributions/utils.rs:254:5 clippy::inline_always "you have declared `#[inline(always)]` on `lanes`. This is usually a bad idea" -rand/0.7.3/src/distributions/utils.rs:258:5 clippy::inline_always "you have declared `#[inline(always)]` on `splat`. This is usually a bad idea" -rand/0.7.3/src/distributions/utils.rs:262:5 clippy::inline_always "you have declared `#[inline(always)]` on `extract`. This is usually a bad idea" -rand/0.7.3/src/distributions/utils.rs:267:5 clippy::inline_always "you have declared `#[inline(always)]` on `replace`. This is usually a bad idea" -rand/0.7.3/src/distributions/utils.rs:274:18 clippy::upper_case_acronyms "name `BoolAsSIMD` contains a capitalized acronym" -rand/0.7.3/src/distributions/utils.rs:281:5 clippy::inline_always "you have declared `#[inline(always)]` on `any`. This is usually a bad idea" -rand/0.7.3/src/distributions/utils.rs:286:5 clippy::inline_always "you have declared `#[inline(always)]` on `all`. This is usually a bad idea" -rand/0.7.3/src/distributions/utils.rs:291:5 clippy::inline_always "you have declared `#[inline(always)]` on `none`. This is usually a bad idea" -rand/0.7.3/src/distributions/utils.rs:488:17 clippy::doc_markdown "you should put `x_i` between ticks in the documentation" -rand/0.7.3/src/distributions/utils.rs:489:50 clippy::doc_markdown "you should put `x_i` between ticks in the documentation" -rand/0.7.3/src/distributions/utils.rs:489:63 clippy::doc_markdown "you should put `f(x_i` between ticks in the documentation" -rand/0.7.3/src/distributions/utils.rs:490:40 clippy::doc_markdown "you should put `f(x_i` between ticks in the documentation" -rand/0.7.3/src/distributions/utils.rs:490:49 clippy::doc_markdown "you should put `f(x_{i+1` between ticks in the documentation" -rand/0.7.3/src/distributions/utils.rs:518:17 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -rand/0.7.3/src/distributions/weibull.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/distributions/weighted/alias_method.rs:113:21 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" -rand/0.7.3/src/distributions/weighted/alias_method.rs:125:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rand/0.7.3/src/distributions/weighted/alias_method.rs:131:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rand/0.7.3/src/distributions/weighted/alias_method.rs:180:36 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -rand/0.7.3/src/distributions/weighted/alias_method.rs:182:34 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -rand/0.7.3/src/distributions/weighted/alias_method.rs:259:28 clippy::clone_on_copy "using `clone` on type `distributions::uniform::Uniform` which implements the `Copy` trait" -rand/0.7.3/src/distributions/weighted/alias_method.rs:296:9 clippy::map_clone "you are using an explicit closure for copying elements" -rand/0.7.3/src/distributions/weighted/alias_method.rs:321:9 clippy::map_clone "you are using an explicit closure for copying elements" -rand/0.7.3/src/distributions/weighted/alias_method.rs:78:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -rand/0.7.3/src/distributions/weighted/alias_method.rs:78:5 clippy::too_many_lines "this function has too many lines (106/100)" -rand/0.7.3/src/distributions/weighted/alias_method.rs:85:17 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -rand/0.7.3/src/distributions/weighted/alias_method.rs:87:31 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" -rand/0.7.3/src/distributions/weighted/mod.rs:100:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -rand/0.7.3/src/distributions/weighted/mod.rs:144:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -rand/0.7.3/src/distributions/weighted/mod.rs:169:16 clippy::int_plus_one "unnecessary `>= y + 1` or `x - 1 >=`" -rand/0.7.3/src/distributions/weighted/mod.rs:386:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand/0.7.3/src/distributions/weighted/mod.rs:85:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand/0.7.3/src/lib.rs:333:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -rand/0.7.3/src/lib.rs:404:14 clippy::wrong_self_convention "methods called `to_*` usually take self by reference; consider choosing a less ambiguous name" -rand/0.7.3/src/lib.rs:552:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -rand/0.7.3/src/rngs/adapter/read.rs:47:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand/0.7.3/src/rngs/adapter/read.rs:89:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand/0.7.3/src/rngs/adapter/reseeding.rs:100:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -rand/0.7.3/src/rngs/adapter/reseeding.rs:112:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea" -rand/0.7.3/src/rngs/adapter/reseeding.rs:117:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea" -rand/0.7.3/src/rngs/adapter/reseeding.rs:198:13 clippy::cast_possible_wrap "casting `u64` to `i64` may wrap around the value" -rand/0.7.3/src/rngs/adapter/reseeding.rs:231:9 clippy::cast_possible_wrap "casting `usize` to `isize` may wrap around the value" -rand/0.7.3/src/rngs/adapter/reseeding.rs:27:28 clippy::doc_markdown "you should put `ChaCha` between ticks in the documentation" -rand/0.7.3/src/rngs/adapter/reseeding.rs:79:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand/0.7.3/src/rngs/entropy.rs:24:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand/0.7.3/src/rngs/entropy.rs:34:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/rngs/mock.rs:36:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/rngs/mock.rs:47:9 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" -rand/0.7.3/src/rngs/mod.rs:61:74 clippy::doc_markdown "you should put `ChaCha20` between ticks in the documentation" -rand/0.7.3/src/rngs/std.rs:25:39 clippy::doc_markdown "you should put `ChaCha` between ticks in the documentation" -rand/0.7.3/src/rngs/std.rs:32:10 clippy::doc_markdown "you should put `rand_chacha` between ticks in the documentation" -rand/0.7.3/src/rngs/std.rs:36:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand/0.7.3/src/rngs/std.rs:39:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea" -rand/0.7.3/src/rngs/std.rs:44:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea" -rand/0.7.3/src/rngs/std.rs:49:5 clippy::inline_always "you have declared `#[inline(always)]` on `fill_bytes`. This is usually a bad idea" -rand/0.7.3/src/rngs/std.rs:54:5 clippy::inline_always "you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea" -rand/0.7.3/src/rngs/std.rs:63:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_seed`. This is usually a bad idea" -rand/0.7.3/src/rngs/std.rs:68:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_rng`. This is usually a bad idea" -rand/0.7.3/src/rngs/thread.rs:57:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand/0.7.3/src/rngs/thread.rs:80:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand/0.7.3/src/rngs/thread.rs:80:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -rand/0.7.3/src/rngs/thread.rs:81:35 clippy::redundant_closure_for_method_calls "redundant closure found" -rand/0.7.3/src/rngs/thread.rs:93:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea" -rand/0.7.3/src/rngs/thread.rs:98:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea" -rand/0.7.3/src/seq/index.rs:127:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand/0.7.3/src/seq/index.rs:139:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -rand/0.7.3/src/seq/index.rs:159:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand/0.7.3/src/seq/index.rs:171:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -rand/0.7.3/src/seq/index.rs:180:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -rand/0.7.3/src/seq/index.rs:223:18 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -rand/0.7.3/src/seq/index.rs:224:18 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -rand/0.7.3/src/seq/index.rs:233:25 clippy::cast_precision_loss "casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide)" -rand/0.7.3/src/seq/index.rs:236:27 clippy::cast_precision_loss "casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide)" -rand/0.7.3/src/seq/index.rs:244:12 clippy::cast_precision_loss "casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide)" -rand/0.7.3/src/seq/index.rs:244:37 clippy::cast_precision_loss "casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide)" -rand/0.7.3/src/seq/index.rs:29:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand/0.7.3/src/seq/index.rs:39:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/seq/index.rs:48:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/seq/index.rs:60:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/seq/index.rs:69:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/seq/index.rs:78:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/seq/index.rs:87:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand/0.7.3/src/seq/index.rs:87:5 clippy::should_implement_trait "method `into_iter` can be confused for the standard trait method `std::iter::IntoIterator::into_iter`" -rand/0.7.3/src/seq/index.rs:97:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -rand/0.7.3/src/seq/mod.rs:141:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -rand/0.7.3/src/seq/mod.rs:168:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -rand/0.7.3/src/seq/mod.rs:229:4 clippy::needless_doctest_main "needless `fn main` in doctest" -rand/0.7.3/src/seq/mod.rs:292:29 clippy::cast_precision_loss "casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand/0.7.3/src/seq/mod.rs:410:23 clippy::default_trait_access "calling `std::marker::PhantomData::default()` is more clear than this expression" -rand/0.7.3/src/seq/mod.rs:45:4 clippy::needless_doctest_main "needless `fn main` in doctest" -rand/0.7.3/src/seq/mod.rs:527:26 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -rand_core/0.6.0/src/block.rs:117:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand_core/0.6.0/src/block.rs:153:5 clippy::inline_always "you have declared `#[inline(always)]` on `index`. This is usually a bad idea" -rand_core/0.6.0/src/block.rs:230:5 clippy::inline_always "you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea" -rand_core/0.6.0/src/block.rs:240:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_seed`. This is usually a bad idea" -rand_core/0.6.0/src/block.rs:245:5 clippy::inline_always "you have declared `#[inline(always)]` on `seed_from_u64`. This is usually a bad idea" -rand_core/0.6.0/src/block.rs:250:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_rng`. This is usually a bad idea" -rand_core/0.6.0/src/block.rs:280:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand_core/0.6.0/src/block.rs:319:5 clippy::inline_always "you have declared `#[inline(always)]` on `index`. This is usually a bad idea" -rand_core/0.6.0/src/block.rs:405:5 clippy::inline_always "you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea" -rand_core/0.6.0/src/block.rs:415:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_seed`. This is usually a bad idea" -rand_core/0.6.0/src/block.rs:420:5 clippy::inline_always "you have declared `#[inline(always)]` on `seed_from_u64`. This is usually a bad idea" -rand_core/0.6.0/src/block.rs:425:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_rng`. This is usually a bad idea" -rand_core/0.6.0/src/block.rs:67:14 clippy::doc_markdown "you should put `module][crate::block` between ticks in the documentation" -rand_core/0.6.0/src/block.rs:68:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand_core/0.6.0/src/error.rs:106:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand_core/0.6.0/src/error.rs:87:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand_core/0.6.0/src/error.rs:95:74 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -rand_core/0.6.0/src/lib.rs:179:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -rand_core/0.6.0/src/lib.rs:301:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand_core/0.6.0/src/lib.rs:303:26 clippy::unreadable_literal "long literal lacking separators" -rand_core/0.6.0/src/lib.rs:304:26 clippy::unreadable_literal "long literal lacking separators" -rand_core/0.6.0/src/lib.rs:313:30 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" -rand_core/0.6.0/src/lib.rs:314:23 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" -rand_core/0.6.0/src/lib.rs:346:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -rand_core/0.6.0/src/lib.rs:381:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea" -rand_core/0.6.0/src/lib.rs:386:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea" -rand_core/0.6.0/src/lib.rs:391:5 clippy::inline_always "you have declared `#[inline(always)]` on `fill_bytes`. This is usually a bad idea" -rand_core/0.6.0/src/lib.rs:396:5 clippy::inline_always "you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea" -rayon/1.5.0/src/collections/binary_heap.rs:7:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/collections/binary_heap.rs:8:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/collections/btree_map.rs:7:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/collections/btree_map.rs:8:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/collections/btree_set.rs:7:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/collections/btree_set.rs:8:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/collections/hash_map.rs:10:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/collections/hash_map.rs:9:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/collections/hash_set.rs:10:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/collections/hash_set.rs:9:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/collections/linked_list.rs:7:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/collections/linked_list.rs:8:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/collections/mod.rs:59:32 clippy::mem_replace_with_default "replacing a value of type `T` with `T::default()` is better expressed using `std::mem::take`" -rayon/1.5.0/src/collections/vec_deque.rs:8:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/collections/vec_deque.rs:9:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/compile_fail/cannot_collect_filtermap_data.rs:2:1 clippy::needless_doctest_main "needless `fn main` in doctest" -rayon/1.5.0/src/compile_fail/cannot_zip_filtered_data.rs:2:1 clippy::needless_doctest_main "needless `fn main` in doctest" -rayon/1.5.0/src/compile_fail/cell_par_iter.rs:2:1 clippy::needless_doctest_main "needless `fn main` in doctest" -rayon/1.5.0/src/compile_fail/no_send_par_iter.rs:25:1 clippy::needless_doctest_main "needless `fn main` in doctest" -rayon/1.5.0/src/compile_fail/no_send_par_iter.rs:46:1 clippy::needless_doctest_main "needless `fn main` in doctest" -rayon/1.5.0/src/compile_fail/no_send_par_iter.rs:4:1 clippy::needless_doctest_main "needless `fn main` in doctest" -rayon/1.5.0/src/compile_fail/rc_par_iter.rs:2:1 clippy::needless_doctest_main "needless `fn main` in doctest" -rayon/1.5.0/src/iter/chain.rs:103:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/chain.rs:122:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/chain.rs:128:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/chain.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/chain.rs:221:36 clippy::doc_markdown "you should put `ExactSizeIterator` between ticks in the documentation" -rayon/1.5.0/src/iter/chain.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/chain.rs:51:38 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" -rayon/1.5.0/src/iter/chain.rs:58:14 clippy::shadow_unrelated "`a` is being shadowed" -rayon/1.5.0/src/iter/chain.rs:58:17 clippy::shadow_unrelated "`b` is being shadowed" -rayon/1.5.0/src/iter/chain.rs:78:14 clippy::shadow_unrelated "`a` is being shadowed" -rayon/1.5.0/src/iter/chain.rs:78:17 clippy::shadow_unrelated "`b` is being shadowed" -rayon/1.5.0/src/iter/chain.rs:97:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/chunks.rs:3:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/chunks.rs:4:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/chunks.rs:77:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/chunks.rs:83:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/cloned.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/cloned.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/cloned.rs:71:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/cloned.rs:75:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/collect/consumer.rs:141:5 clippy::doc_markdown "you should put `CollectReducer` between ticks in the documentation" -rayon/1.5.0/src/iter/collect/consumer.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/collect/consumer.rs:28:5 clippy::doc_markdown "you should put `CollectResult` between ticks in the documentation" -rayon/1.5.0/src/iter/collect/consumer.rs:36:37 clippy::mut_mut "generally you want to avoid `&mut &mut _` if possible" -rayon/1.5.0/src/iter/collect/consumer.rs:36:37 clippy::mut_mut "generally you want to avoid `&mut &mut _` if possible" -rayon/1.5.0/src/iter/collect/mod.rs:154:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -rayon/1.5.0/src/iter/copied.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/copied.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/copied.rs:71:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/copied.rs:75:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/empty.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/empty.rs:24:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -rayon/1.5.0/src/iter/empty.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/enumerate.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/enumerate.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/enumerate.rs:64:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/enumerate.rs:68:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/extend.rs:143:63 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" -rayon/1.5.0/src/iter/extend.rs:182:57 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" -rayon/1.5.0/src/iter/extend.rs:218:32 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" -rayon/1.5.0/src/iter/extend.rs:218:59 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" -rayon/1.5.0/src/iter/extend.rs:25:42 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" -rayon/1.5.0/src/iter/extend.rs:287:62 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" -rayon/1.5.0/src/iter/extend.rs:322:56 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" -rayon/1.5.0/src/iter/extend.rs:41:27 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" -rayon/1.5.0/src/iter/extend.rs:47:30 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" -rayon/1.5.0/src/iter/extend.rs:47:56 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" -rayon/1.5.0/src/iter/extend.rs:47:74 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" -rayon/1.5.0/src/iter/extend.rs:53:29 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" -rayon/1.5.0/src/iter/extend.rs:57:36 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" -rayon/1.5.0/src/iter/extend.rs:59:61 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" -rayon/1.5.0/src/iter/filter.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/filter.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/filter_map.rs:123:9 clippy::option_if_let_else "use Option::map_or instead of an if let/else" -rayon/1.5.0/src/iter/filter_map.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/filter_map.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/find.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/find.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/find_first_last/mod.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/find_first_last/mod.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/find_first_last/mod.rs:32:67 clippy::doc_markdown "you should put `MatchPosition` between ticks in the documentation" -rayon/1.5.0/src/iter/flat_map.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/flat_map.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/flat_map_iter.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/flat_map_iter.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/flatten.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/flatten.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/flatten_iter.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/flatten_iter.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/fold.rs:158:13 clippy::similar_names "binding's name is too similar to existing binding" -rayon/1.5.0/src/iter/fold.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/fold.rs:204:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rayon/1.5.0/src/iter/fold.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/for_each.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/for_each.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/inspect.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/inspect.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/inspect.rs:83:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/inspect.rs:88:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/interleave.rs:111:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/interleave.rs:119:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/interleave.rs:195:30 clippy::doc_markdown "you should put `self.i_len` between ticks in the documentation" -rayon/1.5.0/src/iter/interleave.rs:195:43 clippy::doc_markdown "you should put `self.j_len` between ticks in the documentation" -rayon/1.5.0/src/iter/interleave.rs:199:23 clippy::doc_markdown "you should put `self.i_len` between ticks in the documentation" -rayon/1.5.0/src/iter/interleave.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/interleave.rs:200:23 clippy::doc_markdown "you should put `self.j_len` between ticks in the documentation" -rayon/1.5.0/src/iter/interleave.rs:249:41 clippy::doc_markdown "you should put `DoubleEndedIterator` between ticks in the documentation" -rayon/1.5.0/src/iter/interleave.rs:250:5 clippy::doc_markdown "you should put `ExactSizeIterator` between ticks in the documentation" -rayon/1.5.0/src/iter/interleave.rs:263:33 clippy::doc_markdown "you should put `InterleaveSeq` between ticks in the documentation" -rayon/1.5.0/src/iter/interleave.rs:280:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" -rayon/1.5.0/src/iter/interleave.rs:285:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" -rayon/1.5.0/src/iter/interleave.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/interleave.rs:313:9 clippy::comparison_chain "`if` chain can be rewritten with `match`" -rayon/1.5.0/src/iter/interleave.rs:82:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/interleave.rs:90:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/interleave_shortest.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/intersperse.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/intersperse.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/intersperse.rs:90:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/intersperse.rs:96:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/len.rs:12:1 clippy::module_name_repetitions "item name ends with its containing module's name" -rayon/1.5.0/src/iter/len.rs:146:1 clippy::module_name_repetitions "item name ends with its containing module's name" -rayon/1.5.0/src/iter/len.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/len.rs:200:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/len.rs:205:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/len.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/len.rs:66:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/len.rs:71:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/map.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/map.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/map.rs:84:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/map.rs:89:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/map_with.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/map_with.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/map_with.rs:419:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/map_with.rs:425:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/map_with.rs:90:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/map_with.rs:96:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/mod.rs:1874:24 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -rayon/1.5.0/src/iter/mod.rs:2171:1 clippy::len_without_is_empty "trait `IndexedParallelIterator` has a `len` method but no (possibly inherited) `is_empty` method" -rayon/1.5.0/src/iter/mod.rs:2371:26 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -rayon/1.5.0/src/iter/mod.rs:2411:26 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -rayon/1.5.0/src/iter/mod.rs:82:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/multizip.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/multizip.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/noop.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/once.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/once.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/panic_fuse.rs:102:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/panic_fuse.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/panic_fuse.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/panic_fuse.rs:98:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/par_bridge.rs:136:28 clippy::redundant_else "redundant else block" -rayon/1.5.0/src/iter/par_bridge.rs:163:28 clippy::redundant_else "redundant else block" -rayon/1.5.0/src/iter/plumbing/mod.rs:216:58 clippy::doc_markdown "you should put `find_first` between ticks in the documentation" -rayon/1.5.0/src/iter/plumbing/mod.rs:359:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/plumbing/mod.rs:364:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/plumbing/mod.rs:399:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/plumbing/mod.rs:53:19 clippy::doc_markdown "you should put `DoubleEndedIterator` between ticks in the documentation" -rayon/1.5.0/src/iter/plumbing/mod.rs:53:43 clippy::doc_markdown "you should put `ExactSizeIterator` between ticks in the documentation" -rayon/1.5.0/src/iter/plumbing/mod.rs:54:31 clippy::doc_markdown "you should put `IntoIterator` between ticks in the documentation" -rayon/1.5.0/src/iter/plumbing/mod.rs:55:5 clippy::doc_markdown "you should put `IntoIterator` between ticks in the documentation" -rayon/1.5.0/src/iter/positions.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/positions.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/product.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/reduce.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/repeat.rs:103:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rayon/1.5.0/src/iter/repeat.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/repeat.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/rev.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/rev.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/rev.rs:63:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/rev.rs:68:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/skip.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/skip.rs:3:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/skip.rs:68:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/skip.rs:73:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/splitter.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/splitter.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/step_by.rs:4:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/step_by.rs:5:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/step_by.rs:73:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/step_by.rs:79:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/sum.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/take.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/take.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/take.rs:67:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/take.rs:72:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/try_fold.rs:190:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rayon/1.5.0/src/iter/try_fold.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/try_fold.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/try_reduce.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/try_reduce_with.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/unzip.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/unzip.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/update.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/update.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/update.rs:82:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/update.rs:87:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/while_some.rs:130:22 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -rayon/1.5.0/src/iter/while_some.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/while_some.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/zip.rs:102:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/zip.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/zip.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/zip.rs:74:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/zip.rs:79:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/zip.rs:97:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/iter/zip_eq.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/iter/zip_eq.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/option.rs:8:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/option.rs:9:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/par_either.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/par_either.rs:3:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/private.rs:9:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rayon/1.5.0/src/range.rs:19:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/range.rs:20:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/range_inclusive.rs:194:9 clippy::range_plus_one "an inclusive range would be more readable" -rayon/1.5.0/src/range_inclusive.rs:194:9 clippy::range_plus_one "an inclusive range would be more readable" -rayon/1.5.0/src/range_inclusive.rs:19:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/range_inclusive.rs:209:9 clippy::range_plus_one "an inclusive range would be more readable" -rayon/1.5.0/src/range_inclusive.rs:209:9 clippy::range_plus_one "an inclusive range would be more readable" -rayon/1.5.0/src/range_inclusive.rs:20:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/range_inclusive.rs:231:9 clippy::range_plus_one "an inclusive range would be more readable" -rayon/1.5.0/src/range_inclusive.rs:231:9 clippy::range_plus_one "an inclusive range would be more readable" -rayon/1.5.0/src/result.rs:8:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/result.rs:9:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/slice/mergesort.rs:102:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/slice/mergesort.rs:109:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/slice/mergesort.rs:114:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/slice/mergesort.rs:211:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/slice/mergesort.rs:217:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/slice/mergesort.rs:251:5 clippy::doc_markdown "you should put `TimSort` between ticks in the documentation" -rayon/1.5.0/src/slice/mergesort.rs:252:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" -rayon/1.5.0/src/slice/mergesort.rs:286:59 clippy::doc_markdown "you should put `TimSort` between ticks in the documentation" -rayon/1.5.0/src/slice/mergesort.rs:333:24 clippy::redundant_else "redundant else block" -rayon/1.5.0/src/slice/mergesort.rs:513:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/slice/mergesort.rs:521:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/slice/mergesort.rs:7:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/slice/mergesort.rs:98:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/slice/mod.rs:15:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/slice/mod.rs:16:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/slice/mod.rs:17:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/slice/mod.rs:25:1 clippy::module_name_repetitions "item name ends with its containing module's name" -rayon/1.5.0/src/slice/mod.rs:657:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rayon/1.5.0/src/slice/mod.rs:971:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rayon/1.5.0/src/slice/quicksort.rs:230:36 clippy::doc_markdown "you should put `BlockQuicksort` between ticks in the documentation" -rayon/1.5.0/src/slice/quicksort.rs:233:1 clippy::too_many_lines "this function has too many lines (117/100)" -rayon/1.5.0/src/slice/quicksort.rs:258:26 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -rayon/1.5.0/src/slice/quicksort.rs:265:26 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -rayon/1.5.0/src/slice/quicksort.rs:268:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon/1.5.0/src/slice/quicksort.rs:308:30 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" -rayon/1.5.0/src/slice/quicksort.rs:325:30 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" -rayon/1.5.0/src/slice/quicksort.rs:393:36 clippy::cast_possible_wrap "casting `u8` to `isize` may wrap around the value on targets with 32-bit wide pointers" -rayon/1.5.0/src/slice/quicksort.rs:405:40 clippy::cast_possible_wrap "casting `u8` to `isize` may wrap around the value on targets with 32-bit wide pointers" -rayon/1.5.0/src/slice/quicksort.rs:430:14 clippy::shadow_unrelated "`pivot` is being shadowed" -rayon/1.5.0/src/slice/quicksort.rs:439:13 clippy::shadow_unrelated "`pivot` is being shadowed" -rayon/1.5.0/src/slice/quicksort.rs:482:10 clippy::shadow_unrelated "`pivot` is being shadowed" -rayon/1.5.0/src/slice/quicksort.rs:491:9 clippy::shadow_unrelated "`pivot` is being shadowed" -rayon/1.5.0/src/slice/quicksort.rs:534:26 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -rayon/1.5.0/src/slice/quicksort.rs:545:17 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -rayon/1.5.0/src/slice/quicksort.rs:588:17 clippy::identity_op "the operation is ineffective. Consider reducing it to `len / 4`" -rayon/1.5.0/src/slice/quicksort.rs:716:14 clippy::shadow_unrelated "`pivot` is being shadowed" -rayon/1.5.0/src/split_producer.rs:56:16 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" -rayon/1.5.0/src/split_producer.rs:92:9 clippy::option_if_let_else "use Option::map_or instead of an if let/else" -rayon/1.5.0/src/str.rs:16:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/str.rs:17:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/str.rs:18:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/str.rs:25:5 clippy::cast_possible_wrap "casting `u8` to `i8` may wrap around the value" -rayon/1.5.0/src/str.rs:715:9 clippy::manual_strip "stripping a suffix manually" -rayon/1.5.0/src/string.rs:5:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/vec.rs:137:12 clippy::len_zero "length comparison to zero" -rayon/1.5.0/src/vec.rs:8:5 clippy::wildcard_imports "usage of wildcard import" -rayon/1.5.0/src/vec.rs:9:5 clippy::wildcard_imports "usage of wildcard import" -regex/1.3.2/src/backtrack.rs:100:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/backtrack.rs:133:17 clippy::same_item_push "it looks like the same item is being pushed into this Vec" -regex/1.3.2/src/backtrack.rs:145:20 clippy::if_not_else "unnecessary boolean `not` operation" -regex/1.3.2/src/backtrack.rs:199:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/backtrack.rs:223:29 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/backtrack.rs:230:66 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/backtrack.rs:284:21 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" -regex/1.3.2/src/backtrack.rs:287:5 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex/1.3.2/src/backtrack.rs:97:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/backtrack.rs:98:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/backtrack.rs:99:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:1005:32 clippy::unreadable_literal "long literal lacking separators" -regex/1.3.2/src/compile.rs:1006:21 clippy::unreadable_literal "long literal lacking separators" -regex/1.3.2/src/compile.rs:1008:18 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" -regex/1.3.2/src/compile.rs:1009:18 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" -regex/1.3.2/src/compile.rs:1010:9 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -regex/1.3.2/src/compile.rs:102:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/compile.rs:1037:37 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" -regex/1.3.2/src/compile.rs:1037:55 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" -regex/1.3.2/src/compile.rs:1040:28 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" -regex/1.3.2/src/compile.rs:1040:38 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" -regex/1.3.2/src/compile.rs:1051:25 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -regex/1.3.2/src/compile.rs:1071:8 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" -regex/1.3.2/src/compile.rs:112:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -regex/1.3.2/src/compile.rs:154:30 clippy::redundant_closure_for_method_calls "redundant closure found" -regex/1.3.2/src/compile.rs:156:30 clippy::redundant_closure_for_method_calls "redundant closure found" -regex/1.3.2/src/compile.rs:185:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -regex/1.3.2/src/compile.rs:187:40 clippy::redundant_closure_for_method_calls "redundant closure found" -regex/1.3.2/src/compile.rs:201:53 clippy::doc_markdown "you should put `MaybeInsts` between ticks in the documentation" -regex/1.3.2/src/compile.rs:241:63 clippy::doc_markdown "you should put `c_concat` between ticks in the documentation" -regex/1.3.2/src/compile.rs:245:5 clippy::too_many_lines "this function has too many lines (111/100)" -regex/1.3.2/src/compile.rs:247:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/compile.rs:373:24 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:373:36 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:378:12 clippy::if_not_else "unnecessary boolean `not` operation" -regex/1.3.2/src/compile.rs:400:37 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:407:51 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:409:24 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:417:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -regex/1.3.2/src/compile.rs:42:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/compile.rs:42:5 clippy::new_without_default "you should consider adding a `Default` implementation for `compile::Compiler`" -regex/1.3.2/src/compile.rs:444:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -regex/1.3.2/src/compile.rs:445:57 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:446:20 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:466:20 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:466:32 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:519:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/compile.rs:55:57 clippy::doc_markdown "you should put `size_limit` between ticks in the documentation" -regex/1.3.2/src/compile.rs:58:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/compile.rs:748:41 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:74:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/compile.rs:751:54 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:765:41 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:765:55 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:825:39 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:825:51 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:828:49 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:828:61 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:830:59 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:830:71 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:832:43 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:835:41 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:835:53 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:835:67 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:83:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/compile.rs:896:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -regex/1.3.2/src/compile.rs:905:17 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:953:17 clippy::doc_markdown "you should put `HashMap` between ticks in the documentation" -regex/1.3.2/src/compile.rs:95:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/compile.rs:980:26 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -regex/1.3.2/src/compile.rs:994:44 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/compile.rs:994:54 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/dfa.rs:1007:17 clippy::similar_names "binding's name is too similar to existing binding" -regex/1.3.2/src/dfa.rs:1010:22 clippy::similar_names "binding's name is too similar to existing binding" -regex/1.3.2/src/dfa.rs:1059:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/dfa.rs:1060:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/dfa.rs:1084:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex/1.3.2/src/dfa.rs:1087:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex/1.3.2/src/dfa.rs:1090:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex/1.3.2/src/dfa.rs:1093:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex/1.3.2/src/dfa.rs:1096:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex/1.3.2/src/dfa.rs:1101:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex/1.3.2/src/dfa.rs:1104:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex/1.3.2/src/dfa.rs:1107:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex/1.3.2/src/dfa.rs:1117:30 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex/1.3.2/src/dfa.rs:1120:47 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex/1.3.2/src/dfa.rs:1121:30 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex/1.3.2/src/dfa.rs:1129:13 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" -regex/1.3.2/src/dfa.rs:1134:13 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" -regex/1.3.2/src/dfa.rs:1185:68 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" -regex/1.3.2/src/dfa.rs:1193:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/dfa.rs:1244:50 clippy::doc_markdown "you should put `current_state` between ticks in the documentation" -regex/1.3.2/src/dfa.rs:1338:58 clippy::doc_markdown "you should put `STATE_DEAD` between ticks in the documentation" -regex/1.3.2/src/dfa.rs:1339:9 clippy::doc_markdown "you should put `STATE_UNKNOWN` between ticks in the documentation" -regex/1.3.2/src/dfa.rs:1366:25 clippy::doc_markdown "you should put `STATE_DEAD` between ticks in the documentation" -regex/1.3.2/src/dfa.rs:1366:46 clippy::doc_markdown "you should put `STATE_UNKNOWN` between ticks in the documentation" -regex/1.3.2/src/dfa.rs:1367:41 clippy::inline_always "you have declared `#[inline(always)]` on `start_state`. This is usually a bad idea" -regex/1.3.2/src/dfa.rs:1380:14 clippy::identity_op "the operation is ineffective. Consider reducing it to `(empty_flags.start as u8)`" -regex/1.3.2/src/dfa.rs:1388:15 clippy::match_on_vec_items "indexing into a vector may panic" -regex/1.3.2/src/dfa.rs:1412:20 clippy::unused_self "unused `self` argument" -regex/1.3.2/src/dfa.rs:1438:9 clippy::unused_self "unused `self` argument" -regex/1.3.2/src/dfa.rs:1472:9 clippy::doc_markdown "you should put `StatePtr` between ticks in the documentation" -regex/1.3.2/src/dfa.rs:1490:54 clippy::cast_possible_truncation "casting `i32` to `u8` may truncate the value" -regex/1.3.2/src/dfa.rs:1490:54 clippy::cast_sign_loss "casting `i32` to `u8` may lose the sign of the value" -regex/1.3.2/src/dfa.rs:1521:20 clippy::doc_markdown "you should put `num_byte_classes` between ticks in the documentation" -regex/1.3.2/src/dfa.rs:1529:41 clippy::inline_always "you have declared `#[inline(always)]` on `byte_class`. This is usually a bad idea" -regex/1.3.2/src/dfa.rs:1537:14 clippy::doc_markdown "you should put `byte_class` between ticks in the documentation" -regex/1.3.2/src/dfa.rs:1538:41 clippy::inline_always "you have declared `#[inline(always)]` on `u8_class`. This is usually a bad idea" -regex/1.3.2/src/dfa.rs:1562:18 clippy::doc_markdown "you should put `STATE_START` between ticks in the documentation" -regex/1.3.2/src/dfa.rs:1614:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/dfa.rs:1651:38 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/dfa.rs:1700:17 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -regex/1.3.2/src/dfa.rs:1701:18 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex/1.3.2/src/dfa.rs:1705:19 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex/1.3.2/src/dfa.rs:1708:16 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -regex/1.3.2/src/dfa.rs:1709:18 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex/1.3.2/src/dfa.rs:1713:19 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex/1.3.2/src/dfa.rs:1716:18 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -regex/1.3.2/src/dfa.rs:1717:18 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex/1.3.2/src/dfa.rs:1721:19 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex/1.3.2/src/dfa.rs:1727:14 clippy::cast_lossless "casting `u8` to `u16` may become silently lossy if you later change the type" -regex/1.3.2/src/dfa.rs:1732:15 clippy::trivially_copy_pass_by_ref "this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -regex/1.3.2/src/dfa.rs:1736:22 clippy::trivially_copy_pass_by_ref "this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -regex/1.3.2/src/dfa.rs:1741:9 clippy::match_like_matches_macro "match expression looks like `matches!` macro" -regex/1.3.2/src/dfa.rs:1747:16 clippy::trivially_copy_pass_by_ref "this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -regex/1.3.2/src/dfa.rs:1751:18 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" -regex/1.3.2/src/dfa.rs:1815:38 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" -regex/1.3.2/src/dfa.rs:1821:21 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" -regex/1.3.2/src/dfa.rs:1824:5 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex/1.3.2/src/dfa.rs:1848:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" -regex/1.3.2/src/dfa.rs:1850:18 clippy::cast_sign_loss "casting `i32` to `u32` may lose the sign of the value" -regex/1.3.2/src/dfa.rs:1857:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" -regex/1.3.2/src/dfa.rs:1860:17 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -regex/1.3.2/src/dfa.rs:1867:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" -regex/1.3.2/src/dfa.rs:1870:19 clippy::cast_possible_truncation "casting `u32` to `u8` may truncate the value" -regex/1.3.2/src/dfa.rs:1873:15 clippy::cast_possible_truncation "casting `u32` to `u8` may truncate the value" -regex/1.3.2/src/dfa.rs:1876:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" -regex/1.3.2/src/dfa.rs:1882:26 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" -regex/1.3.2/src/dfa.rs:1884:15 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" -regex/1.3.2/src/dfa.rs:277:17 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -regex/1.3.2/src/dfa.rs:277:31 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -regex/1.3.2/src/dfa.rs:295:20 clippy::cast_possible_truncation "casting `usize` to `i32` may truncate the value on targets with 64-bit wide pointers" -regex/1.3.2/src/dfa.rs:295:20 clippy::cast_possible_wrap "casting `usize` to `i32` may wrap around the value on targets with 32-bit wide pointers" -regex/1.3.2/src/dfa.rs:299:21 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" -regex/1.3.2/src/dfa.rs:34:46 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" -regex/1.3.2/src/dfa.rs:398:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -regex/1.3.2/src/dfa.rs:446:41 clippy::inline_always "you have declared `#[inline(always)]` on `forward`. This is usually a bad idea" -regex/1.3.2/src/dfa.rs:457:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/dfa.rs:459:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/dfa.rs:460:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/dfa.rs:476:41 clippy::inline_always "you have declared `#[inline(always)]` on `reverse`. This is usually a bad idea" -regex/1.3.2/src/dfa.rs:487:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/dfa.rs:489:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/dfa.rs:490:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/dfa.rs:506:41 clippy::inline_always "you have declared `#[inline(always)]` on `forward_many`. This is usually a bad idea" -regex/1.3.2/src/dfa.rs:518:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/dfa.rs:520:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/dfa.rs:554:41 clippy::inline_always "you have declared `#[inline(always)]` on `exec_at`. This is usually a bad idea" -regex/1.3.2/src/dfa.rs:555:5 clippy::too_many_lines "this function has too many lines (101/100)" -regex/1.3.2/src/dfa.rs:58:9 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/dfa.rs:667:21 clippy::similar_names "binding's name is too similar to existing binding" -regex/1.3.2/src/dfa.rs:747:41 clippy::inline_always "you have declared `#[inline(always)]` on `exec_at_reverse`. This is usually a bad idea" -regex/1.3.2/src/dfa.rs:795:21 clippy::similar_names "binding's name is too similar to existing binding" -regex/1.3.2/src/dfa.rs:848:9 clippy::doc_markdown "you should put `next_si` between ticks in the documentation" -regex/1.3.2/src/dfa.rs:852:41 clippy::inline_always "you have declared `#[inline(always)]` on `next_si`. This is usually a bad idea" -regex/1.3.2/src/dfa.rs:885:12 clippy::doc_markdown "you should put `STATE_DEAD` between ticks in the documentation" -regex/1.3.2/src/dfa.rs:889:9 clippy::doc_markdown "you should put `STATE_UNKNOWN` between ticks in the documentation" -regex/1.3.2/src/dfa.rs:897:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/dfa.rs:979:29 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex/1.3.2/src/error.rs:6:1 clippy::manual_non_exhaustive "this seems like a manual implementation of the non-exhaustive pattern" -regex/1.3.2/src/exec.rs:1000:14 clippy::doc_markdown "you should put `captures_nfa` between ticks in the documentation" -regex/1.3.2/src/exec.rs:100:1 clippy::module_name_repetitions "item name starts with its containing module's name" -regex/1.3.2/src/exec.rs:1028:5 clippy::too_many_arguments "this function has too many arguments (9/7)" -regex/1.3.2/src/exec.rs:1039:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/exec.rs:1144:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/exec.rs:1179:26 clippy::match_same_arms "this `match` has identical arm bodies" -regex/1.3.2/src/exec.rs:122:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/exec.rs:1250:41 clippy::inline_always "you have declared `#[inline(always)]` on `searcher`. This is usually a bad idea" -regex/1.3.2/src/exec.rs:1260:41 clippy::inline_always "you have declared `#[inline(always)]` on `searcher_str`. This is usually a bad idea" -regex/1.3.2/src/exec.rs:1270:17 clippy::doc_markdown "you should put `RegexSet` between ticks in the documentation" -regex/1.3.2/src/exec.rs:1280:17 clippy::doc_markdown "you should put `RegexSet` between ticks in the documentation" -regex/1.3.2/src/exec.rs:137:9 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" -regex/1.3.2/src/exec.rs:142:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/exec.rs:1493:5 clippy::upper_case_acronyms "name `PikeVM` contains a capitalized acronym" -regex/1.3.2/src/exec.rs:158:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/exec.rs:168:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/exec.rs:181:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/exec.rs:195:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/exec.rs:204:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/exec.rs:210:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/exec.rs:245:62 clippy::if_same_then_else "this `if` has identical blocks" -regex/1.3.2/src/exec.rs:251:21 clippy::if_not_else "unnecessary boolean `not` operation" -regex/1.3.2/src/exec.rs:262:60 clippy::if_same_then_else "this `if` has identical blocks" -regex/1.3.2/src/exec.rs:268:21 clippy::if_not_else "unnecessary boolean `not` operation" -regex/1.3.2/src/exec.rs:278:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/exec.rs:281:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/exec.rs:286:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -regex/1.3.2/src/exec.rs:300:30 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/exec.rs:308:17 clippy::similar_names "binding's name is too similar to existing binding" -regex/1.3.2/src/exec.rs:329:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/exec.rs:330:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/exec.rs:331:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/exec.rs:334:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/exec.rs:340:19 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/exec.rs:344:27 clippy::unused_self "unused `self` argument" -regex/1.3.2/src/exec.rs:383:41 clippy::inline_always "you have declared `#[inline(always)]` on `shortest_match_at`. This is usually a bad idea" -regex/1.3.2/src/exec.rs:388:41 clippy::inline_always "you have declared `#[inline(always)]` on `is_match_at`. This is usually a bad idea" -regex/1.3.2/src/exec.rs:393:41 clippy::inline_always "you have declared `#[inline(always)]` on `find_at`. This is usually a bad idea" -regex/1.3.2/src/exec.rs:398:41 clippy::inline_always "you have declared `#[inline(always)]` on `captures_read_at`. This is usually a bad idea" -regex/1.3.2/src/exec.rs:425:41 clippy::inline_always "you have declared `#[inline(always)]` on `shortest_match_at`. This is usually a bad idea" -regex/1.3.2/src/exec.rs:44:1 clippy::module_name_repetitions "item name starts with its containing module's name" -regex/1.3.2/src/exec.rs:473:9 clippy::doc_markdown "you should put `shortest_match(...).is_some` between ticks in the documentation" -regex/1.3.2/src/exec.rs:474:41 clippy::inline_always "you have declared `#[inline(always)]` on `is_match_at`. This is usually a bad idea" -regex/1.3.2/src/exec.rs:524:41 clippy::inline_always "you have declared `#[inline(always)]` on `find_at`. This is usually a bad idea" -regex/1.3.2/src/exec.rs:52:1 clippy::module_name_repetitions "item name starts with its containing module's name" -regex/1.3.2/src/exec.rs:686:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/exec.rs:727:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/exec.rs:767:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/exec.rs:783:41 clippy::inline_always "you have declared `#[inline(always)]` on `shortest_dfa`. This is usually a bad idea" -regex/1.3.2/src/exec.rs:791:41 clippy::inline_always "you have declared `#[inline(always)]` on `shortest_dfa_reverse_suffix`. This is usually a bad idea" -regex/1.3.2/src/exec.rs:823:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/exec.rs:868:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/exec.rs:897:31 clippy::doc_markdown "you should put `shortest_nfa(...).is_some` between ticks in the documentation" -regex/1.3.2/src/exec.rs:899:9 clippy::doc_markdown "you should put `shortest_nfa` between ticks in the documentation" -regex/1.3.2/src/exec.rs:905:14 clippy::doc_markdown "you should put `match_nfa` between ticks in the documentation" -regex/1.3.2/src/exec.rs:930:14 clippy::doc_markdown "you should put `shortest_nfa` between ticks in the documentation" -regex/1.3.2/src/exec.rs:981:14 clippy::doc_markdown "you should put `find_nfa` between ticks in the documentation" -regex/1.3.2/src/expand.rs:170:27 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -regex/1.3.2/src/expand.rs:171:5 clippy::match_like_matches_macro "match expression looks like `matches!` macro" -regex/1.3.2/src/expand.rs:22:13 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -regex/1.3.2/src/expand.rs:27:23 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -regex/1.3.2/src/expand.rs:30:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -regex/1.3.2/src/expand.rs:38:30 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" -regex/1.3.2/src/expand.rs:42:21 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" -regex/1.3.2/src/expand.rs:50:1 clippy::module_name_repetitions "item name starts with its containing module's name" -regex/1.3.2/src/expand.rs:69:23 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -regex/1.3.2/src/expand.rs:80:28 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" -regex/1.3.2/src/expand.rs:84:21 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" -regex/1.3.2/src/expand.rs:8:1 clippy::module_name_repetitions "item name starts with its containing module's name" -regex/1.3.2/src/input.rs:142:1 clippy::module_name_repetitions "item name ends with its containing module's name" -regex/1.3.2/src/input.rs:146:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/input.rs:15:1 clippy::module_name_repetitions "item name starts with its containing module's name" -regex/1.3.2/src/input.rs:165:31 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/input.rs:178:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/input.rs:228:1 clippy::module_name_repetitions "item name ends with its containing module's name" -regex/1.3.2/src/input.rs:236:21 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/input.rs:236:33 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/input.rs:24:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/input.rs:271:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/input.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/input.rs:362:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/input.rs:370:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/input.rs:371:42 clippy::redundant_closure_for_method_calls "redundant closure found" -regex/1.3.2/src/input.rs:37:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/input.rs:388:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/input.rs:42:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/input.rs:47:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/input.rs:53:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/input.rs:58:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/input.rs:63:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/lib.rs:1:null clippy::cargo_common_metadata "package `regex` is missing `package.keywords` metadata" -regex/1.3.2/src/literal/imp.rs:101:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/literal/imp.rs:114:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/literal/imp.rs:127:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/literal/imp.rs:139:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/literal/imp.rs:144:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/literal/imp.rs:149:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/literal/imp.rs:154:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/literal/imp.rs:155:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/literal/imp.rs:160:30 clippy::match_same_arms "this `match` has identical arm bodies" -regex/1.3.2/src/literal/imp.rs:167:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/literal/imp.rs:168:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/literal/imp.rs:211:20 clippy::redundant_else "redundant else block" -regex/1.3.2/src/literal/imp.rs:239:5 clippy::upper_case_acronyms "name `AC` contains a capitalized acronym" -regex/1.3.2/src/literal/imp.rs:276:50 clippy::match_same_arms "this `match` has identical arm bodies" -regex/1.3.2/src/literal/imp.rs:342:41 clippy::inline_always "you have declared `#[inline(always)]` on `find`. This is usually a bad idea" -regex/1.3.2/src/literal/imp.rs:34:5 clippy::upper_case_acronyms "name `AC` contains a capitalized acronym" -regex/1.3.2/src/literal/imp.rs:435:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/literal/imp.rs:436:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/literal/imp.rs:437:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/literal/imp.rs:438:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/literal/imp.rs:439:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/literal/imp.rs:440:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/literal/imp.rs:455:41 clippy::inline_always "you have declared `#[inline(always)]` on `find`. This is usually a bad idea" -regex/1.3.2/src/literal/imp.rs:46:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/literal/imp.rs:481:41 clippy::inline_always "you have declared `#[inline(always)]` on `is_suffix`. This is usually a bad idea" -regex/1.3.2/src/literal/imp.rs:51:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/literal/imp.rs:579:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/literal/imp.rs:57:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/literal/imp.rs:580:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/literal/imp.rs:583:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/literal/imp.rs:602:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -regex/1.3.2/src/literal/imp.rs:622:24 clippy::redundant_else "redundant else block" -regex/1.3.2/src/literal/imp.rs:62:18 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -regex/1.3.2/src/literal/imp.rs:637:24 clippy::redundant_else "redundant else block" -regex/1.3.2/src/literal/imp.rs:648:9 clippy::needless_return "unneeded `return` statement" -regex/1.3.2/src/literal/imp.rs:651:44 clippy::doc_markdown "you should put `BoyerMooreSearch` between ticks in the documentation" -regex/1.3.2/src/literal/imp.rs:65:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/literal/imp.rs:68:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/literal/imp.rs:783:32 clippy::redundant_else "redundant else block" -regex/1.3.2/src/literal/imp.rs:786:42 clippy::manual_saturating_arithmetic "manual saturating arithmetic" -regex/1.3.2/src/literal/imp.rs:78:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/literal/imp.rs:84:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/literal/imp.rs:850:20 clippy::unreadable_literal "long literal lacking separators" -regex/1.3.2/src/literal/imp.rs:85:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/pikevm.rs:103:15 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/pikevm.rs:103:52 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/pikevm.rs:114:5 clippy::too_many_arguments "this function has too many arguments (8/7)" -regex/1.3.2/src/pikevm.rs:117:13 clippy::similar_names "binding's name is too similar to existing binding" -regex/1.3.2/src/pikevm.rs:124:17 clippy::similar_names "binding's name is too similar to existing binding" -regex/1.3.2/src/pikevm.rs:220:9 clippy::doc_markdown "you should put `thread_caps` between ticks in the documentation" -regex/1.3.2/src/pikevm.rs:222:16 clippy::doc_markdown "you should put `at_next` between ticks in the documentation" -regex/1.3.2/src/pikevm.rs:223:9 clippy::doc_markdown "you should put `at_next` between ticks in the documentation" -regex/1.3.2/src/pikevm.rs:224:5 clippy::too_many_arguments "this function has too many arguments (8/7)" -regex/1.3.2/src/pikevm.rs:234:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/pikevm.rs:303:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/pikevm.rs:331:29 clippy::mut_mut "this expression mutably borrows a mutable reference. Consider reborrowing" -regex/1.3.2/src/pikevm.rs:70:5 clippy::upper_case_acronyms "name `IP` contains a capitalized acronym" -regex/1.3.2/src/pikevm.rs:88:5 clippy::too_many_arguments "this function has too many arguments (8/7)" -regex/1.3.2/src/prog.rs:102:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/prog.rs:113:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/prog.rs:120:9 clippy::match_like_matches_macro "match expression looks like `matches!` macro" -regex/1.3.2/src/prog.rs:128:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/prog.rs:134:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/prog.rs:141:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/prog.rs:147:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/prog.rs:164:41 clippy::inline_always "you have declared `#[inline(always)]` on `deref`. This is usually a bad idea" -regex/1.3.2/src/prog.rs:172:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex/1.3.2/src/prog.rs:18:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -regex/1.3.2/src/prog.rs:236:13 clippy::write_with_newline "using `write!()` with a format string that ends in a single newline" -regex/1.3.2/src/prog.rs:300:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/prog.rs:301:9 clippy::match_like_matches_macro "match expression looks like `matches!` macro" -regex/1.3.2/src/prog.rs:382:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/prog.rs:409:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/prog.rs:80:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/prog.rs:80:5 clippy::new_without_default "you should consider adding a `Default` implementation for `prog::Program`" -regex/1.3.2/src/re_builder.rs:267:17 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -regex/1.3.2/src/re_builder.rs:267:17 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -regex/1.3.2/src/re_builder.rs:4:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -regex/1.3.2/src/re_builder.rs:57:17 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_builder.rs:57:17 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_builder.rs:68:17 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -regex/1.3.2/src/re_builder.rs:68:17 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -regex/1.3.2/src/re_bytes.rs:1017:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" -regex/1.3.2/src/re_bytes.rs:1039:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" -regex/1.3.2/src/re_bytes.rs:1093:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -regex/1.3.2/src/re_bytes.rs:1118:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -regex/1.3.2/src/re_bytes.rs:1133:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -regex/1.3.2/src/re_bytes.rs:118:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -regex/1.3.2/src/re_bytes.rs:256:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/re_bytes.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_bytes.rs:35:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_bytes.rs:42:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_bytes.rs:48:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_bytes.rs:558:29 clippy::doc_markdown "you should put `shortest_match` between ticks in the documentation" -regex/1.3.2/src/re_bytes.rs:55:33 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/re_bytes.rs:55:47 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/re_bytes.rs:572:29 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" -regex/1.3.2/src/re_bytes.rs:720:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/re_bytes.rs:817:5 clippy::doc_markdown "you should put `CaptureLocations` between ticks in the documentation" -regex/1.3.2/src/re_bytes.rs:843:1 clippy::len_without_is_empty "item `re_bytes::CaptureLocations` has a public `len` method but no corresponding `is_empty` method" -regex/1.3.2/src/re_bytes.rs:849:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_bytes.rs:858:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_bytes.rs:869:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_bytes.rs:891:1 clippy::len_without_is_empty "item `re_bytes::Captures<'t>` has a public `len` method but no corresponding `is_empty` method" -regex/1.3.2/src/re_bytes.rs:911:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_bytes.rs:917:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_bytes.rs:926:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_bytes.rs:955:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_set.rs:179:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/re_set.rs:179:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/re_set.rs:251:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_set.rs:251:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_set.rs:263:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_set.rs:263:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_set.rs:268:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_set.rs:268:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_set.rs:277:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_set.rs:277:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_set.rs:94:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -regex/1.3.2/src/re_set.rs:94:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -regex/1.3.2/src/re_trait.rs:136:29 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/re_unicode.rs:1019:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" -regex/1.3.2/src/re_unicode.rs:1041:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" -regex/1.3.2/src/re_unicode.rs:1088:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/re_unicode.rs:1135:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -regex/1.3.2/src/re_unicode.rs:1160:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -regex/1.3.2/src/re_unicode.rs:174:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -regex/1.3.2/src/re_unicode.rs:21:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -regex/1.3.2/src/re_unicode.rs:313:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/re_unicode.rs:38:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_unicode.rs:44:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_unicode.rs:51:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_unicode.rs:57:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_unicode.rs:617:29 clippy::doc_markdown "you should put `shortest_match` between ticks in the documentation" -regex/1.3.2/src/re_unicode.rs:631:29 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" -regex/1.3.2/src/re_unicode.rs:64:33 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/re_unicode.rs:64:47 clippy::redundant_field_names "redundant field names in struct initialization" -regex/1.3.2/src/re_unicode.rs:834:5 clippy::doc_markdown "you should put `CaptureLocations` between ticks in the documentation" -regex/1.3.2/src/re_unicode.rs:860:1 clippy::len_without_is_empty "item `re_unicode::CaptureLocations` has a public `len` method but no corresponding `is_empty` method" -regex/1.3.2/src/re_unicode.rs:866:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_unicode.rs:875:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_unicode.rs:886:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_unicode.rs:908:1 clippy::len_without_is_empty "item `re_unicode::Captures<'t>` has a public `len` method but no corresponding `is_empty` method" -regex/1.3.2/src/re_unicode.rs:928:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_unicode.rs:934:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_unicode.rs:943:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/re_unicode.rs:972:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex/1.3.2/src/sparse.rs:10:37 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" -regex/1.3.2/src/sparse.rs:15:1 clippy::module_name_repetitions "item name starts with its containing module's name" -regex/1.3.2/src/utf8.rs:100:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex/1.3.2/src/utf8.rs:103:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex/1.3.2/src/utf8.rs:106:22 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" -regex/1.3.2/src/utf8.rs:107:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" -regex/1.3.2/src/utf8.rs:108:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" -regex/1.3.2/src/utf8.rs:109:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" -regex/1.3.2/src/utf8.rs:111:27 clippy::unreadable_literal "long literal lacking separators" -regex/1.3.2/src/utf8.rs:121:1 clippy::module_name_repetitions "item name ends with its containing module's name" -regex/1.3.2/src/utf8.rs:143:24 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex/1.3.2/src/utf8.rs:143:9 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex/1.3.2/src/utf8.rs:23:1 clippy::module_name_repetitions "item name ends with its containing module's name" -regex/1.3.2/src/utf8.rs:30:20 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex/1.3.2/src/utf8.rs:51:1 clippy::module_name_repetitions "item name ends with its containing module's name" -regex/1.3.2/src/utf8.rs:58:23 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex/1.3.2/src/utf8.rs:58:9 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex/1.3.2/src/utf8.rs:63:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex/1.3.2/src/utf8.rs:66:22 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" -regex/1.3.2/src/utf8.rs:66:54 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" -regex/1.3.2/src/utf8.rs:77:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex/1.3.2/src/utf8.rs:80:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex/1.3.2/src/utf8.rs:83:22 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" -regex/1.3.2/src/utf8.rs:84:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" -regex/1.3.2/src/utf8.rs:85:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" -regex/1.3.2/src/utf8.rs:92:23 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex/1.3.2/src/utf8.rs:92:9 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex/1.3.2/src/utf8.rs:97:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -ripgrep/12.1.1//home/matthias/.rustup/toolchains/nightly-2021-01-15-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std/src/macros.rs:14:27 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep/12.1.1//home/matthias/.rustup/toolchains/nightly-2021-01-15-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std/src/macros.rs:14:27 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep/12.1.1//home/matthias/.rustup/toolchains/nightly-2021-01-15-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std/src/macros.rs:14:27 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep/12.1.1//home/matthias/.rustup/toolchains/nightly-2021-01-15-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std/src/macros.rs:14:27 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep/12.1.1/build.rs:133:19 clippy::option_as_ref_deref "called `.as_ref().map(|x| &**x)` on an Option value. This can be done more directly by calling `githash.as_deref()` instead" -ripgrep/12.1.1/build.rs:18:18 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -ripgrep/12.1.1/build.rs:225:14 clippy::redundant_closure_for_method_calls "redundant closure found" -ripgrep/12.1.1/build.rs:92:19 clippy::option_as_ref_deref "called `.as_ref().map(|x| &**x)` on an Option value. This can be done more directly by calling `githash.as_deref()` instead" -ripgrep/12.1.1/crates/core/app.rs:1408:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep/12.1.1/crates/core/app.rs:1408:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep/12.1.1/crates/core/app.rs:1409:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep/12.1.1/crates/core/app.rs:1409:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep/12.1.1/crates/core/app.rs:152:32 clippy::doc_markdown "you should put `clap::Arg` between ticks in the documentation" -ripgrep/12.1.1/crates/core/app.rs:152:32 clippy::doc_markdown "you should put `clap::Arg` between ticks in the documentation" -ripgrep/12.1.1/crates/core/app.rs:156:39 clippy::doc_markdown "you should put `clap::Arg` between ticks in the documentation" -ripgrep/12.1.1/crates/core/app.rs:156:39 clippy::doc_markdown "you should put `clap::Arg` between ticks in the documentation" -ripgrep/12.1.1/crates/core/app.rs:156:5 clippy::doc_markdown "you should put `RGArg` between ticks in the documentation" -ripgrep/12.1.1/crates/core/app.rs:156:5 clippy::doc_markdown "you should put `RGArg` between ticks in the documentation" -ripgrep/12.1.1/crates/core/app.rs:164:12 clippy::upper_case_acronyms "name `RGArg` contains a capitalized acronym" -ripgrep/12.1.1/crates/core/app.rs:164:12 clippy::upper_case_acronyms "name `RGArg` contains a capitalized acronym" -ripgrep/12.1.1/crates/core/app.rs:1668:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep/12.1.1/crates/core/app.rs:1668:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep/12.1.1/crates/core/app.rs:1669:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep/12.1.1/crates/core/app.rs:1669:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep/12.1.1/crates/core/app.rs:1821:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep/12.1.1/crates/core/app.rs:1821:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep/12.1.1/crates/core/app.rs:1822:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep/12.1.1/crates/core/app.rs:1822:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep/12.1.1/crates/core/app.rs:212:10 clippy::upper_case_acronyms "name `RGArgKind` contains a capitalized acronym" -ripgrep/12.1.1/crates/core/app.rs:212:10 clippy::upper_case_acronyms "name `RGArgKind` contains a capitalized acronym" -ripgrep/12.1.1/crates/core/app.rs:2999:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep/12.1.1/crates/core/app.rs:2999:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep/12.1.1/crates/core/app.rs:3000:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep/12.1.1/crates/core/app.rs:3000:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep/12.1.1/crates/core/app.rs:367:54 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep/12.1.1/crates/core/app.rs:367:54 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep/12.1.1/crates/core/app.rs:414:59 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep/12.1.1/crates/core/app.rs:414:59 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep/12.1.1/crates/core/app.rs:417:57 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep/12.1.1/crates/core/app.rs:417:57 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep/12.1.1/crates/core/app.rs:417:57 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep/12.1.1/crates/core/app.rs:417:57 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep/12.1.1/crates/core/app.rs:75:9 clippy::doc_markdown "you should put `RIPGREP_BUILD_GIT_HASH` between ticks in the documentation" -ripgrep/12.1.1/crates/core/app.rs:75:9 clippy::doc_markdown "you should put `RIPGREP_BUILD_GIT_HASH` between ticks in the documentation" -ripgrep/12.1.1/crates/core/app.rs:87:5 clippy::if_not_else "unnecessary boolean `not` operation" -ripgrep/12.1.1/crates/core/app.rs:87:5 clippy::if_not_else "unnecessary boolean `not` operation" -ripgrep/12.1.1/crates/core/args.rs:1143:22 clippy::unused_self "unused `self` argument" -ripgrep/12.1.1/crates/core/args.rs:11:1 clippy::single_component_path_imports "this import is redundant" -ripgrep/12.1.1/crates/core/args.rs:1209:74 clippy::if_same_then_else "this `if` has identical blocks" -ripgrep/12.1.1/crates/core/args.rs:1282:13 clippy::similar_names "binding's name is too similar to existing binding" -ripgrep/12.1.1/crates/core/args.rs:1430:22 clippy::unused_self "unused `self` argument" -ripgrep/12.1.1/crates/core/args.rs:1438:21 clippy::doc_markdown "you should put `OsStr` between ticks in the documentation" -ripgrep/12.1.1/crates/core/args.rs:1520:44 clippy::redundant_closure_for_method_calls "redundant closure found" -ripgrep/12.1.1/crates/core/args.rs:1524:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -ripgrep/12.1.1/crates/core/args.rs:1635:14 clippy::doc_markdown "you should put `values_of_lossy` between ticks in the documentation" -ripgrep/12.1.1/crates/core/args.rs:1693:41 clippy::redundant_closure_for_method_calls "redundant closure found" -ripgrep/12.1.1/crates/core/args.rs:1770:17 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -ripgrep/12.1.1/crates/core/args.rs:287:13 clippy::similar_names "binding's name is too similar to existing binding" -ripgrep/12.1.1/crates/core/args.rs:33:1 clippy::single_component_path_imports "this import is redundant" -ripgrep/12.1.1/crates/core/args.rs:34:1 clippy::single_component_path_imports "this import is redundant" -ripgrep/12.1.1/crates/core/args.rs:35:1 clippy::single_component_path_imports "this import is redundant" -ripgrep/12.1.1/crates/core/args.rs:369:5 clippy::upper_case_acronyms "name `JSON` contains a capitalized acronym" -ripgrep/12.1.1/crates/core/args.rs:410:14 clippy::trivially_copy_pass_by_ref "this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -ripgrep/12.1.1/crates/core/args.rs:475:18 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep/12.1.1/crates/core/args.rs:512:19 clippy::doc_markdown "you should put `ArgMatches` between ticks in the documentation" -ripgrep/12.1.1/crates/core/args.rs:549:16 clippy::wrong_self_convention "methods called `to_*` usually take self by reference; consider choosing a less ambiguous name" -ripgrep/12.1.1/crates/core/args.rs:71:5 clippy::upper_case_acronyms "name `PCRE2Version` contains a capitalized acronym" -ripgrep/12.1.1/crates/core/args.rs:76:18 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -ripgrep/12.1.1/crates/core/args.rs:77:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -ripgrep/12.1.1/crates/core/args.rs:923:42 clippy::doc_markdown "you should put `BinaryDetection::quit` between ticks in the documentation" -ripgrep/12.1.1/crates/core/config.rs:13:1 clippy::single_component_path_imports "this import is redundant" -ripgrep/12.1.1/crates/core/config.rs:58:6 clippy::type_complexity "very complex type used. Consider factoring parts into `type` definitions" -ripgrep/12.1.1/crates/core/config.rs:79:6 clippy::type_complexity "very complex type used. Consider factoring parts into `type` definitions" -ripgrep/12.1.1/crates/core/logger.rs:11:30 clippy::doc_markdown "you should put `max_level` between ticks in the documentation" -ripgrep/12.1.1/crates/core/logger.rs:15:16 clippy::redundant_static_lifetimes "constants have by default a `'static` lifetime" -ripgrep/12.1.1/crates/core/main.rs:55:19 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -ripgrep/12.1.1/crates/core/main.rs:56:9 clippy::enum_glob_use "usage of wildcard import for enum variants" -ripgrep/12.1.1/crates/core/messages.rs:46:1 clippy::module_name_repetitions "item name ends with its containing module's name" -ripgrep/12.1.1/crates/core/messages.rs:51:1 clippy::module_name_repetitions "item name ends with its containing module's name" -ripgrep/12.1.1/crates/core/messages.rs:62:1 clippy::module_name_repetitions "item name ends with its containing module's name" -ripgrep/12.1.1/crates/core/path_printer.rs:27:1 clippy::module_name_repetitions "item name starts with its containing module's name" -ripgrep/12.1.1/crates/core/path_printer.rs:89:9 clippy::if_not_else "unnecessary boolean `not` operation" -ripgrep/12.1.1/crates/core/search.rs:185:1 clippy::module_name_repetitions "item name starts with its containing module's name" -ripgrep/12.1.1/crates/core/search.rs:224:5 clippy::upper_case_acronyms "name `JSON` contains a capitalized acronym" -ripgrep/12.1.1/crates/core/search.rs:292:9 clippy::write_with_newline "using `write!()` with a format string that ends in a single newline" -ripgrep/12.1.1/crates/core/search.rs:311:1 clippy::module_name_repetitions "item name starts with its containing module's name" -ripgrep/12.1.1/crates/core/search.rs:377:12 clippy::nonminimal_bool "this boolean expression can be simplified" -ripgrep/12.1.1/crates/core/search.rs:423:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -ripgrep/12.1.1/crates/core/search.rs:447:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -ripgrep/12.1.1/crates/core/search.rs:472:24 clippy::map_clone "you are using an explicit closure for cloning elements" -ripgrep/12.1.1/crates/core/search.rs:472:41 clippy::redundant_closure_for_method_calls "redundant closure found" -ripgrep/12.1.1/crates/core/search.rs:480:24 clippy::map_clone "you are using an explicit closure for cloning elements" -ripgrep/12.1.1/crates/core/search.rs:480:41 clippy::redundant_closure_for_method_calls "redundant closure found" -ripgrep/12.1.1/crates/core/search.rs:49:1 clippy::module_name_repetitions "item name starts with its containing module's name" -ripgrep/12.1.1/crates/core/search.rs:509:24 clippy::map_clone "you are using an explicit closure for cloning elements" -ripgrep/12.1.1/crates/core/search.rs:509:41 clippy::redundant_closure_for_method_calls "redundant closure found" -ripgrep/12.1.1/crates/core/search.rs:517:24 clippy::map_clone "you are using an explicit closure for cloning elements" -ripgrep/12.1.1/crates/core/search.rs:517:41 clippy::redundant_closure_for_method_calls "redundant closure found" -ripgrep/12.1.1/crates/core/search.rs:533:36 clippy::cast_lossless "casting `u32` to `f64` may become silently lossy if you later change the type" -ripgrep/12.1.1/crates/core/search.rs:533:5 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -ripgrep/12.1.1/crates/core/subject.rs:20:1 clippy::module_name_repetitions "item name starts with its containing module's name" -ripgrep/12.1.1/crates/core/subject.rs:4:1 clippy::single_component_path_imports "this import is redundant" -syn/1.0.54/build.rs:1:null clippy::cargo_common_metadata "package `syn` is missing `package.keywords` metadata" -syn/1.0.54/build.rs:1:null clippy::multiple_crate_versions "could not read cargo metadata: `cargo metadata` exited with an error: Downloading crates ...\n Downloaded syn-test-suite v0.0.0\nerror: failed to verify the checksum of `syn-test-suite v0.0.0`" -syn/1.0.54/src/lib.rs:1:null clippy::cargo_common_metadata "package `syn` is missing `package.keywords` metadata" -syn/1.0.54/src/lib.rs:1:null clippy::multiple_crate_versions "could not read cargo metadata: `cargo metadata` exited with an error: Downloading crates ...\n Downloaded syn-test-suite v0.0.0\nerror: failed to verify the checksum of `syn-test-suite v0.0.0`" -syn/1.0.54/src/lit.rs:1397:40 clippy::redundant_else "redundant else block" -syn/1.0.54/src/lit.rs:1405:28 clippy::redundant_else "redundant else block" -syn/1.0.54/src/lit.rs:1485:32 clippy::redundant_else "redundant else block" -unicode-xid/0.2.1/src/lib.rs:1:null clippy::cargo_common_metadata "package `unicode-xid` is missing `package.categories` metadata" -unicode-xid/0.2.1/src/lib.rs:56:11 clippy::upper_case_acronyms "name `UnicodeXID` contains a capitalized acronym" -unicode-xid/0.2.1/src/lib.rs:57:64 clippy::doc_markdown "you should put `XID_Start` between ticks in the documentation" -unicode-xid/0.2.1/src/lib.rs:60:10 clippy::doc_markdown "you should put `XID_Start` between ticks in the documentation" -unicode-xid/0.2.1/src/lib.rs:62:27 clippy::doc_markdown "you should put `ID_Start` between ticks in the documentation" -unicode-xid/0.2.1/src/lib.rs:62:67 clippy::doc_markdown "you should put `NFKx` between ticks in the documentation" -unicode-xid/0.2.1/src/lib.rs:63:21 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" -unicode-xid/0.2.1/src/lib.rs:65:61 clippy::doc_markdown "you should put `XID_Continue` between ticks in the documentation" -unicode-xid/0.2.1/src/lib.rs:68:10 clippy::doc_markdown "you should put `XID_Continue` between ticks in the documentation" -unicode-xid/0.2.1/src/lib.rs:70:28 clippy::doc_markdown "you should put `ID_Continue` between ticks in the documentation" -unicode-xid/0.2.1/src/lib.rs:70:72 clippy::doc_markdown "you should put `NFKx` between ticks in the documentation" -unicode-xid/0.2.1/src/lib.rs:71:24 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" -xsv/0.13.0/src/cmd/cat.rs:101:34 clippy::redundant_closure_for_method_calls "redundant closure found" -xsv/0.13.0/src/cmd/cat.rs:42:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -xsv/0.13.0/src/cmd/cat.rs:53:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/cat.rs:7:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv/0.13.0/src/cmd/count.rs:32:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/count.rs:38:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -xsv/0.13.0/src/cmd/count.rs:42:33 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -xsv/0.13.0/src/cmd/count.rs:50:5 clippy::unit_arg "passing a unit value to a function" -xsv/0.13.0/src/cmd/count.rs:7:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv/0.13.0/src/cmd/fixlengths.rs:45:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/fixlengths.rs:50:18 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -xsv/0.13.0/src/cmd/fixlengths.rs:62:30 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -xsv/0.13.0/src/cmd/fixlengths.rs:9:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv/0.13.0/src/cmd/flatten.rs:10:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv/0.13.0/src/cmd/flatten.rs:51:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/fmt.rs:50:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/fmt.rs:55:13 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/fmt.rs:7:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv/0.13.0/src/cmd/frequency.rs:148:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -xsv/0.13.0/src/cmd/frequency.rs:149:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -xsv/0.13.0/src/cmd/frequency.rs:15:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv/0.13.0/src/cmd/frequency.rs:169:13 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/frequency.rs:176:17 clippy::if_not_else "unnecessary boolean `not` operation" -xsv/0.13.0/src/cmd/frequency.rs:178:24 clippy::collapsible_else_if "this `else { if .. }` block can be collapsed" -xsv/0.13.0/src/cmd/frequency.rs:77:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/frequency.rs:93:31 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" -xsv/0.13.0/src/cmd/headers.rs:43:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/headers.rs:49:17 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" -xsv/0.13.0/src/cmd/headers.rs:9:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv/0.13.0/src/cmd/index.rs:11:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv/0.13.0/src/cmd/index.rs:45:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/input.rs:42:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/input.rs:47:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/input.rs:7:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv/0.13.0/src/cmd/join.rs:17:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv/0.13.0/src/cmd/join.rs:194:29 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/join.rs:224:22 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/join.rs:293:14 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/join.rs:293:20 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/join.rs:297:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv/0.13.0/src/cmd/join.rs:298:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv/0.13.0/src/cmd/join.rs:299:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv/0.13.0/src/cmd/join.rs:300:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv/0.13.0/src/cmd/join.rs:308:9 clippy::unused_self "unused `self` argument" -xsv/0.13.0/src/cmd/join.rs:342:38 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -xsv/0.13.0/src/cmd/join.rs:342:46 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -xsv/0.13.0/src/cmd/join.rs:347:9 clippy::if_not_else "unnecessary boolean `not` operation" -xsv/0.13.0/src/cmd/join.rs:372:44 clippy::redundant_closure_for_method_calls "redundant closure found" -xsv/0.13.0/src/cmd/join.rs:375:33 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/join.rs:392:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv/0.13.0/src/cmd/join.rs:403:29 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" -xsv/0.13.0/src/cmd/join.rs:426:13 clippy::if_not_else "unnecessary boolean `not` operation" -xsv/0.13.0/src/cmd/join.rs:77:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -xsv/0.13.0/src/cmd/join.rs:94:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/partition.rs:105:22 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/partition.rs:106:22 clippy::redundant_slicing "redundant slicing of the whole range" -xsv/0.13.0/src/cmd/partition.rs:139:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv/0.13.0/src/cmd/partition.rs:15:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv/0.13.0/src/cmd/partition.rs:169:9 clippy::if_not_else "unnecessary boolean `not` operation" -xsv/0.13.0/src/cmd/partition.rs:56:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/partition.rs:77:9 clippy::unused_self "unused `self` argument" -xsv/0.13.0/src/cmd/sample.rs:105:44 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -xsv/0.13.0/src/cmd/sample.rs:115:21 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -xsv/0.13.0/src/cmd/sample.rs:11:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv/0.13.0/src/cmd/sample.rs:51:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/sample.rs:58:19 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -xsv/0.13.0/src/cmd/sample.rs:69:9 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" -xsv/0.13.0/src/cmd/sample.rs:75:16 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" -xsv/0.13.0/src/cmd/sample.rs:91:42 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -xsv/0.13.0/src/cmd/sample.rs:92:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -xsv/0.13.0/src/cmd/search.rs:51:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/search.rs:9:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv/0.13.0/src/cmd/select.rs:60:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/select.rs:8:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv/0.13.0/src/cmd/slice.rs:57:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/slice.rs:9:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv/0.13.0/src/cmd/sort.rs:11:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv/0.13.0/src/cmd/sort.rs:138:47 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -xsv/0.13.0/src/cmd/sort.rs:139:51 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -xsv/0.13.0/src/cmd/sort.rs:48:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/sort.rs:91:14 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" -xsv/0.13.0/src/cmd/split.rs:14:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv/0.13.0/src/cmd/split.rs:61:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/split.rs:94:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -xsv/0.13.0/src/cmd/split.rs:96:14 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -xsv/0.13.0/src/cmd/split.rs:99:13 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -xsv/0.13.0/src/cmd/stats.rs:110:36 clippy::redundant_closure_for_method_calls "redundant closure found" -xsv/0.13.0/src/cmd/stats.rs:127:14 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -xsv/0.13.0/src/cmd/stats.rs:138:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -xsv/0.13.0/src/cmd/stats.rs:139:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -xsv/0.13.0/src/cmd/stats.rs:162:25 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" -xsv/0.13.0/src/cmd/stats.rs:22:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv/0.13.0/src/cmd/stats.rs:231:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -xsv/0.13.0/src/cmd/stats.rs:262:35 clippy::default_trait_access "calling `cmd::stats::TypedSum::default()` is more clear than this expression" -xsv/0.13.0/src/cmd/stats.rs:263:40 clippy::default_trait_access "calling `cmd::stats::TypedMinMax::default()` is more clear than this expression" -xsv/0.13.0/src/cmd/stats.rs:264:39 clippy::default_trait_access "calling `stats::OnlineStats::default()` is more clear than this expression" -xsv/0.13.0/src/cmd/stats.rs:265:58 clippy::default_trait_access "calling `stats::Unsorted::default()` is more clear than this expression" -xsv/0.13.0/src/cmd/stats.rs:266:41 clippy::default_trait_access "calling `stats::Unsorted::default()` is more clear than this expression" -xsv/0.13.0/src/cmd/stats.rs:268:18 clippy::default_trait_access "calling `cmd::stats::FieldType::default()` is more clear than this expression" -xsv/0.13.0/src/cmd/stats.rs:269:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv/0.13.0/src/cmd/stats.rs:270:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv/0.13.0/src/cmd/stats.rs:271:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv/0.13.0/src/cmd/stats.rs:272:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv/0.13.0/src/cmd/stats.rs:273:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv/0.13.0/src/cmd/stats.rs:274:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv/0.13.0/src/cmd/stats.rs:283:9 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" -xsv/0.13.0/src/cmd/stats.rs:284:9 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" -xsv/0.13.0/src/cmd/stats.rs:285:9 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" -xsv/0.13.0/src/cmd/stats.rs:290:21 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" -xsv/0.13.0/src/cmd/stats.rs:293:25 clippy::match_same_arms "this `match` has identical arm bodies" -xsv/0.13.0/src/cmd/stats.rs:297:25 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" -xsv/0.13.0/src/cmd/stats.rs:301:21 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" -xsv/0.13.0/src/cmd/stats.rs:302:21 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" -xsv/0.13.0/src/cmd/stats.rs:308:18 clippy::wrong_self_convention "methods called `to_*` usually take self by reference; consider choosing a less ambiguous name" -xsv/0.13.0/src/cmd/stats.rs:318:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -xsv/0.13.0/src/cmd/stats.rs:322:45 clippy::redundant_closure_for_method_calls "redundant closure found" -xsv/0.13.0/src/cmd/stats.rs:322:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -xsv/0.13.0/src/cmd/stats.rs:327:9 clippy::if_not_else "unnecessary boolean `not` operation" -xsv/0.13.0/src/cmd/stats.rs:330:13 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -xsv/0.13.0/src/cmd/stats.rs:338:45 clippy::redundant_closure_for_method_calls "redundant closure found" -xsv/0.13.0/src/cmd/stats.rs:402:16 clippy::redundant_pattern_matching "redundant pattern matching, consider using `is_ok()`" -xsv/0.13.0/src/cmd/stats.rs:403:16 clippy::redundant_pattern_matching "redundant pattern matching, consider using `is_ok()`" -xsv/0.13.0/src/cmd/stats.rs:407:18 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -xsv/0.13.0/src/cmd/stats.rs:411:16 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -xsv/0.13.0/src/cmd/stats.rs:427:56 clippy::match_same_arms "this `match` has identical arm bodies" -xsv/0.13.0/src/cmd/stats.rs:429:56 clippy::match_same_arms "this `match` has identical arm bodies" -xsv/0.13.0/src/cmd/stats.rs:430:60 clippy::match_same_arms "this `match` has identical arm bodies" -xsv/0.13.0/src/cmd/stats.rs:430:60 clippy::match_same_arms "this `match` has identical arm bodies" -xsv/0.13.0/src/cmd/stats.rs:454:5 clippy::doc_markdown "you should put `TypedSum` between ticks in the documentation" -xsv/0.13.0/src/cmd/stats.rs:473:43 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -xsv/0.13.0/src/cmd/stats.rs:504:56 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -xsv/0.13.0/src/cmd/stats.rs:505:51 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -xsv/0.13.0/src/cmd/stats.rs:511:5 clippy::doc_markdown "you should put `TypedMinMax` between ticks in the documentation" -xsv/0.13.0/src/cmd/stats.rs:536:35 clippy::cast_possible_truncation "casting `f64` to `i64` may truncate the value" -xsv/0.13.0/src/cmd/stats.rs:544:33 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -xsv/0.13.0/src/cmd/stats.rs:592:22 clippy::default_trait_access "calling `stats::MinMax::default()` is more clear than this expression" -xsv/0.13.0/src/cmd/stats.rs:593:22 clippy::default_trait_access "calling `stats::MinMax::default()` is more clear than this expression" -xsv/0.13.0/src/cmd/stats.rs:594:23 clippy::default_trait_access "calling `stats::MinMax::default()` is more clear than this expression" -xsv/0.13.0/src/cmd/stats.rs:595:21 clippy::default_trait_access "calling `stats::MinMax::default()` is more clear than this expression" -xsv/0.13.0/src/cmd/stats.rs:71:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -xsv/0.13.0/src/cmd/stats.rs:86:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/table.rs:10:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv/0.13.0/src/cmd/table.rs:50:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/cmd/table.rs:54:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/config.rs:113:43 clippy::or_fun_call "use of `unwrap_or` followed by a function call" -xsv/0.13.0/src/config.rs:58:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -xsv/0.13.0/src/config.rs:77:28 clippy::explicit_deref_methods "explicit deref method call" -xsv/0.13.0/src/config.rs:90:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv/0.13.0/src/index.rs:31:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv/0.13.0/src/main.rs:164:49 clippy::redundant_clone "redundant clone" -xsv/0.13.0/src/main.rs:1:null clippy::cargo_common_metadata "package `xsv` is missing `package.categories` metadata" -xsv/0.13.0/src/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `rand_core`: 0.3.1, 0.4.2" -xsv/0.13.0/src/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `rand`: 0.3.23, 0.4.6" -xsv/0.13.0/src/main.rs:75:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv/0.13.0/src/select.rs:13:1 clippy::module_name_repetitions "item name starts with its containing module's name" -xsv/0.13.0/src/select.rs:154:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -xsv/0.13.0/src/select.rs:250:33 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/select.rs:250:43 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/select.rs:255:39 clippy::range_plus_one "an inclusive range would be more readable" -xsv/0.13.0/src/select.rs:280:20 clippy::len_zero "length comparison to zero" -xsv/0.13.0/src/select.rs:29:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv/0.13.0/src/select.rs:360:62 clippy::trivially_copy_pass_by_ref "this argument (8 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -xsv/0.13.0/src/select.rs:360:9 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Option`" -xsv/0.13.0/src/select.rs:375:9 clippy::stable_sort_primitive "used `sort` on primitive type `usize`" -xsv/0.13.0/src/select.rs:379:18 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" -xsv/0.13.0/src/select.rs:416:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -xsv/0.13.0/src/select.rs:419:9 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Option`" -xsv/0.13.0/src/select.rs:420:27 clippy::option_option "consider using `Option` instead of `Option>` or a custom enum if you need to distinguish all 3 cases" -xsv/0.13.0/src/select.rs:99:17 clippy::similar_names "binding's name is too similar to existing binding" -xsv/0.13.0/src/util.rs:150:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" -xsv/0.13.0/src/util.rs:37:33 clippy::map_clone "you are using an explicit closure for copying elements" -xsv/0.13.0/src/util.rs:90:1 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +cargo-0.49.0//home/matthias/.rustup/toolchains/nightly-2021-01-15-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/core/src/macros/mod.rs:393:34 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/build.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.categories` metadata" +cargo-0.49.0/build.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.keywords` metadata" +cargo-0.49.0/src/bin/cargo/cli.rs:104:34 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/bin/cargo/cli.rs:121:5 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo-0.49.0/src/bin/cargo/cli.rs:157:30 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/cli.rs:184:41 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +cargo-0.49.0/src/bin/cargo/cli.rs:196:42 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/cli.rs:200:39 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/cli.rs:231:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo-0.49.0/src/bin/cargo/cli.rs:245:22 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +cargo-0.49.0/src/bin/cargo/cli.rs:247:47 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/cli.rs:257:22 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/cli.rs:26:20 clippy::redundant_else "redundant else block" +cargo-0.49.0/src/bin/cargo/cli.rs:7:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/bench.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/bench.rs:76:59 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/commands/build.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/check.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/clean.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/doc.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/fetch.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/fix.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/generate_lockfile.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/git_checkout.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/help.rs:20:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/bin/cargo/commands/init.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/install.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/install.rs:97:16 clippy::option_if_let_else "use Option::map_or instead of an if let/else" +cargo-0.49.0/src/bin/cargo/commands/locate_project.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/login.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/metadata.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/mod.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/new.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/new.rs:20:24 clippy::option_if_let_else "use Option::map_or instead of an if let/else" +cargo-0.49.0/src/bin/cargo/commands/owner.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/owner.rs:38:43 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/commands/owner.rs:39:43 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/commands/owner.rs:40:43 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/commands/owner.rs:43:30 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/commands/owner.rs:46:30 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/commands/package.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/pkgid.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/publish.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/publish.rs:40:47 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/commands/read_manifest.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/run.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/rustc.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/rustdoc.rs:3:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/search.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/test.rs:127:54 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/commands/test.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/tree.rs:149:49 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/commands/tree.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/uninstall.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/update.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/vendor.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/vendor.rs:96:16 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +cargo-0.49.0/src/bin/cargo/commands/verify_project.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/version.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/yank.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/yank.rs:32:36 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/commands/yank.rs:33:35 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/commands/yank.rs:34:36 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/commands/yank.rs:35:36 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/main.rs:100:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +cargo-0.49.0/src/bin/cargo/main.rs:118:41 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/main.rs:137:43 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/main.rs:148:19 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/bin/cargo/main.rs:174:57 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/main.rs:18:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/main.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.categories` metadata" +cargo-0.49.0/src/bin/cargo/main.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.keywords` metadata" +cargo-0.49.0/src/bin/cargo/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `crossbeam-utils`: 0.6.6, 0.7.2" +cargo-0.49.0/src/bin/cargo/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `hex`: 0.3.2, 0.4.0" +cargo-0.49.0/src/bin/cargo/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `humantime`: 1.3.0, 2.0.0" +cargo-0.49.0/src/bin/cargo/main.rs:72:22 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/main.rs:94:13 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +cargo-0.49.0/src/bin/cargo/main.rs:96:41 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/main.rs:98:60 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/compiler/build_config.rs:155:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +cargo-0.49.0/src/cargo/core/compiler/build_config.rs:170:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/build_config.rs:175:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/build_config.rs:180:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/build_config.rs:186:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/build_config.rs:197:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/build_config.rs:205:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/build_config.rs:51:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/build_config.rs:69:48 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +cargo-0.49.0/src/cargo/core/compiler/build_config.rs:96:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/build_context/mod.rs:44:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/build_context/mod.rs:83:20 clippy::doc_markdown "you should put `x86_64` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:108:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:121:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:149:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:411:9 clippy::needless_question_mark "Question mark operator is useless here" +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:420:69 clippy::doc_markdown "you should put `mode/target_kind` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:423:19 clippy::doc_markdown "you should put `CrateTypes` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:424:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:469:58 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:603:19 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:665:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:82:31 clippy::doc_markdown "you should put `FileType` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:83:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:84:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:96:31 clippy::doc_markdown "you should put `FileType` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:98:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/build_plan.rs:4:9 clippy::doc_markdown "you should put `BuildPlan` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/build_plan.rs:5:66 clippy::doc_markdown "you should put `BuildPlan` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/build_plan.rs:66:40 clippy::ptr_arg "writing `&PathBuf` instead of `&Path` involves a new object where a slice will do." +cargo-0.49.0/src/cargo/core/compiler/compilation.rs:150:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/compilation.rs:169:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/compilation.rs:185:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/compilation.rs:193:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/compilation.rs:194:49 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/compiler/compilation.rs:198:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/compilation.rs:314:16 clippy::doc_markdown "you should put `rustc_tool` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/compilation.rs:91:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:118:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:123:18 clippy::case_sensitive_file_extension_comparisons "case-sensitive file extension comparison" +cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:147:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:157:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:33:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:49:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:69:48 clippy::case_sensitive_file_extension_comparisons "case-sensitive file extension comparison" +cargo-0.49.0/src/cargo/core/compiler/context/compilation_files.rs:204:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/core/compiler/context/compilation_files.rs:277:22 clippy::doc_markdown "you should put `OUT_DIR` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/context/compilation_files.rs:324:66 clippy::doc_markdown "you should put `FileType` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/context/compilation_files.rs:393:37 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/compiler/context/compilation_files.rs:426:71 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:125:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:125:5 clippy::too_many_lines "this function has too many lines (107/100)" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:270:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:286:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:308:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:340:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:349:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:354:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:358:21 clippy::doc_markdown "you should put `RunCustomBuild` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:361:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:374:43 clippy::doc_markdown "you should put `RunCustomBuild` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:378:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:383:41 clippy::doc_markdown "you should put `RunCustomBuild` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:384:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:391:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:397:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:523:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:538:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:542:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:83:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:92:25 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/core/compiler/crate_type.rs:16:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/crate_type.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/crate_type.rs:40:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/crate_type.rs:49:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/crate_type.rs:60:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:150:1 clippy::too_many_lines "this function has too many lines (230/100)" +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:353:56 clippy::manual_strip "stripping a prefix manually" +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:448:27 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:464:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:481:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:48:56 clippy::doc_markdown "you should put `RunCustomBuild` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:561:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:567:20 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:576:28 clippy::shadow_unrelated "`mut value` is being shadowed" +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:606:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:688:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:756:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:762:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:762:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:823:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1021:51 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1656:16 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1664:5 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1787:5 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1795:5 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1882:17 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1894:17 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1906:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1917:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1923:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1956:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1962:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1963:22 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1964:22 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1965:22 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1966:22 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1980:17 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1980:24 clippy::manual_strip "stripping a prefix manually" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1986:17 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:2016:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:61:5 clippy::doc_markdown "you should put `CompileMode` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:63:12 clippy::doc_markdown "you should put `CompileKind` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:67:7 clippy::doc_markdown "you should put `CARGO_DEFAULT_LIB_METADATA[^4` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:68:5 clippy::doc_markdown "you should put `package_id` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:71:19 clippy::doc_markdown "you should put `test/bench/for_host/edition` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:755:52 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:77:5 clippy::doc_markdown "you should put `is_std` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:816:5 clippy::too_many_lines "this function has too many lines (127/100)" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:863:64 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:875:33 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:876:32 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:896:30 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:897:30 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:991:37 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:12:5 clippy::doc_markdown "you should put `src/librustc_jobserver/lib.rs` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:329:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:332:23 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:34:53 clippy::doc_markdown "you should put `NeedsToken` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:35:6 clippy::doc_markdown "you should put `ReleaseToken` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:37:6 clippy::doc_markdown "you should put `NeedsToken` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:40:5 clippy::doc_markdown "you should put `NeedsToken` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:40:56 clippy::doc_markdown "you should put `NeedsToken` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:43:6 clippy::doc_markdown "you should put `ReleaseToken` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:748:16 clippy::collapsible_else_if "this `else { if .. }` block can be collapsed" +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:749:13 clippy::if_not_else "unnecessary boolean `not` operation" +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:786:26 clippy::unused_self "unused `self` argument" +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:81:61 clippy::doc_markdown "you should put `DrainState` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:865:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:871:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:890:9 clippy::unused_self "unused `self` argument" +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:93:24 clippy::doc_markdown "you should put `JobQueue` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/links.rs:8:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:1016:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:1094:19 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:1131:1 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:1268:34 clippy::case_sensitive_file_extension_comparisons "case-sensitive file extension comparison" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:1277:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:179:1 clippy::too_many_lines "this function has too many lines (162/100)" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:198:78 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:201:25 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:267:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:324:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:364:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:364:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:392:45 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:415:23 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:464:18 clippy::ptr_arg "writing `&PathBuf` instead of `&Path` involves a new object where a slice will do." +cargo-0.49.0/src/cargo/core/compiler/mod.rs:488:61 clippy::ptr_arg "writing `&PathBuf` instead of `&Path` involves a new object where a slice will do." +cargo-0.49.0/src/cargo/core/compiler/mod.rs:667:15 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:693:1 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:725:42 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:736:1 clippy::too_many_lines "this function has too many lines (141/100)" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:73:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:777:12 clippy::if_not_else "unnecessary boolean `not` operation" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:873:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/compiler/output_depinfo.rs:41:13 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +cargo-0.49.0/src/cargo/core/compiler/rustdoc.rs:16:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/core/compiler/rustdoc.rs:57:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/core/compiler/rustdoc.rs:72:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/standard_lib.rs:134:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/standard_lib.rs:16:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/standard_lib.rs:30:28 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/compiler/standard_lib.rs:34:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/timings.rs:16:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo-0.49.0/src/cargo/core/compiler/timings.rs:192:64 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo-0.49.0/src/cargo/core/compiler/timings.rs:212:58 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo-0.49.0/src/cargo/core/compiler/timings.rs:234:13 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" +cargo-0.49.0/src/cargo/core/compiler/timings.rs:355:13 clippy::cast_possible_truncation "casting `f64` to `u32` may truncate the value" +cargo-0.49.0/src/cargo/core/compiler/timings.rs:355:13 clippy::cast_sign_loss "casting `f64` to `u32` may lose the sign of the value" +cargo-0.49.0/src/cargo/core/compiler/timings.rs:397:38 clippy::cast_possible_truncation "casting `f64` to `u32` may truncate the value" +cargo-0.49.0/src/cargo/core/compiler/timings.rs:397:38 clippy::cast_sign_loss "casting `f64` to `u32` may lose the sign of the value" +cargo-0.49.0/src/cargo/core/compiler/timings.rs:484:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/compiler/timings.rs:605:38 clippy::doc_markdown "you should put `rmeta_time` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/timings.rs:605:50 clippy::doc_markdown "you should put `codegen_time` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/timings.rs:641:26 clippy::non_ascii_literal "literal non-ASCII character detected" +cargo-0.49.0/src/cargo/core/compiler/unit.rs:100:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/unit.rs:151:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/core/compiler/unit.rs:161:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/unit.rs:35:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/core/compiler/unit_dependencies.rs:154:29 clippy::doc_markdown "you should put `state.unit_dependencies` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/unit_dependencies.rs:213:1 clippy::too_many_lines "this function has too many lines (110/100)" +cargo-0.49.0/src/cargo/core/compiler/unit_dependencies.rs:52:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/unit_dependencies.rs:52:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/core/compiler/unit_graph.rs:65:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/unit_graph.rs:65:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/core/dependency.rs:157:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/dependency.rs:182:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/dependency.rs:203:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/dependency.rs:224:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/dependency.rs:23:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo-0.49.0/src/cargo/core/dependency.rs:248:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/dependency.rs:270:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/dependency.rs:274:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/dependency.rs:278:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/dependency.rs:287:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/dependency.rs:291:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/dependency.rs:305:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/dependency.rs:311:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/dependency.rs:319:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/dependency.rs:337:75 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/dependency.rs:397:56 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/dependency.rs:403:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/dependency.rs:408:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/dependency.rs:415:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/dependency.rs:419:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/dependency.rs:424:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/dependency.rs:428:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/dependency.rs:433:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/dependency.rs:438:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/dependency.rs:443:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/dependency.rs:449:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/dependency.rs:450:9 clippy::if_not_else "unnecessary `!=` operation" +cargo-0.49.0/src/cargo/core/features.rs:119:17 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/features.rs:229:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/features.rs:274:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/features.rs:278:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/features.rs:306:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/features.rs:338:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo-0.49.0/src/cargo/core/features.rs:362:25 clippy::option_option "consider using `Option` instead of `Option>` or a custom enum if you need to distinguish all 3 cases" +cargo-0.49.0/src/cargo/core/features.rs:380:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/features.rs:401:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/features.rs:409:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/features.rs:412:45 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/features.rs:416:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/features.rs:419:45 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/features.rs:424:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/features.rs:431:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/features.rs:477:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/features.rs:509:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/features.rs:518:5 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +cargo-0.49.0/src/cargo/core/features.rs:542:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/features.rs:543:37 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/features.rs:547:60 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/features.rs:556:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/core/features.rs:563:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/core/manifest.rs:116:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +cargo-0.49.0/src/cargo/core/manifest.rs:118:58 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/manifest.rs:130:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +cargo-0.49.0/src/cargo/core/manifest.rs:143:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:159:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:162:34 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/manifest.rs:169:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:17:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/cargo/core/manifest.rs:189:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo-0.49.0/src/cargo/core/manifest.rs:215:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:222:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:22:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/core/manifest.rs:360:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:407:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:410:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:413:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:416:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:419:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:422:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:425:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:431:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:438:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:444:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:447:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:450:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:453:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:456:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:459:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:462:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:466:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:470:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:477:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:481:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:488:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/manifest.rs:512:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:516:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:520:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:524:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:528:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:538:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:557:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:561:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:565:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:569:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:577:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:581:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:588:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:617:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:632:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:648:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:659:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:66:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/core/manifest.rs:670:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:693:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:708:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:723:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:726:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:729:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:735:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:738:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:741:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:744:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:747:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:751:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:754:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:757:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:760:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:763:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:767:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:776:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:780:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:787:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:798:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:800:56 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/manifest.rs:805:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:809:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:818:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:823:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:828:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:831:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:834:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:839:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:85:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/core/manifest.rs:888:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:936:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package.rs:1075:28 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/package.rs:160:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package.rs:170:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package.rs:174:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package.rs:182:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package.rs:186:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package.rs:190:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package.rs:194:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package.rs:198:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package.rs:202:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package.rs:206:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package.rs:210:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package.rs:217:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package.rs:221:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package.rs:222:35 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/package.rs:226:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package.rs:227:35 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/package.rs:230:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package.rs:239:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/package.rs:249:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package.rs:287:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/core/package.rs:385:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/package.rs:421:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +cargo-0.49.0/src/cargo/core/package.rs:425:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/package.rs:452:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/package.rs:453:60 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/package.rs:459:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/package.rs:473:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/package.rs:587:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/package.rs:588:9 clippy::needless_question_mark "Question mark operator is useless here" +cargo-0.49.0/src/cargo/core/package.rs:682:46 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" +cargo-0.49.0/src/cargo/core/package.rs:682:46 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" +cargo-0.49.0/src/cargo/core/package.rs:682:63 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" +cargo-0.49.0/src/cargo/core/package.rs:682:63 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" +cargo-0.49.0/src/cargo/core/package.rs:731:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/package.rs:790:13 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/core/package.rs:988:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/core/package_id.rs:115:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/package_id.rs:124:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package_id.rs:139:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package_id.rs:142:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package_id.rs:145:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package_id.rs:149:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package_id.rs:157:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package_id.rs:161:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package_id.rs:169:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package_id.rs:174:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/core/package_id_spec.rs:101:39 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/package_id_spec.rs:143:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package_id_spec.rs:147:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package_id_spec.rs:151:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package_id_spec.rs:160:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package_id_spec.rs:179:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/package_id_spec.rs:212:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/package_id_spec.rs:231:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/core/package_id_spec.rs:51:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/package_id_spec.rs:77:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/package_id_spec.rs:88:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/profiles.rs:1004:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/profiles.rs:1014:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/profiles.rs:1018:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/profiles.rs:1028:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/profiles.rs:106:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/profiles.rs:143:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo-0.49.0/src/cargo/core/profiles.rs:286:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/profiles.rs:294:40 clippy::if_not_else "unnecessary boolean `not` operation" +cargo-0.49.0/src/cargo/core/profiles.rs:30:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/profiles.rs:342:25 clippy::shadow_unrelated "`maker` is being shadowed" +cargo-0.49.0/src/cargo/core/profiles.rs:370:41 clippy::unused_self "unused `self` argument" +cargo-0.49.0/src/cargo/core/profiles.rs:370:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/profiles.rs:372:9 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" +cargo-0.49.0/src/cargo/core/profiles.rs:382:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/profiles.rs:383:28 clippy::if_not_else "unnecessary boolean `not` operation" +cargo-0.49.0/src/cargo/core/profiles.rs:397:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/profiles.rs:405:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/profiles.rs:607:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo-0.49.0/src/cargo/core/profiles.rs:909:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/profiles.rs:923:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/profiles.rs:934:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/profiles.rs:987:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/registry.rs:111:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/registry.rs:127:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/registry.rs:168:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/registry.rs:19:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/registry.rs:240:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/registry.rs:26:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/registry.rs:344:49 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/registry.rs:369:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/registry.rs:424:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/registry.rs:49:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/core/registry.rs:520:17 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/core/registry.rs:763:53 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/registry.rs:765:53 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/registry.rs:807:14 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/registry.rs:814:53 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/resolver/conflict_cache.rs:197:29 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/resolver/conflict_cache.rs:41:38 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +cargo-0.49.0/src/cargo/core/resolver/context.rs:274:53 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/resolver/context.rs:42:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/core/resolver/context.rs:74:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/encode.rs:156:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/resolver/encode.rs:156:5 clippy::too_many_lines "this function has too many lines (164/100)" +cargo-0.49.0/src/cargo/core/resolver/encode.rs:339:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +cargo-0.49.0/src/cargo/core/resolver/encode.rs:438:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/resolver/encode.rs:449:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/resolver/encode.rs:529:34 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/resolver/encode.rs:602:59 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/resolver/encode.rs:623:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/core/resolver/encode.rs:652:27 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/core/resolver/encode.rs:674:51 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/resolver/errors.rs:103:22 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/resolver/errors.rs:104:22 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/resolver/errors.rs:206:9 clippy::if_not_else "unnecessary boolean `not` operation" +cargo-0.49.0/src/cargo/core/resolver/errors.rs:257:45 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/resolver/errors.rs:27:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/errors.rs:305:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo-0.49.0/src/cargo/core/resolver/errors.rs:70:1 clippy::too_many_lines "this function has too many lines (207/100)" +cargo-0.49.0/src/cargo/core/resolver/features.rs:104:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/core/resolver/features.rs:111:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/features.rs:162:56 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/resolver/features.rs:179:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/core/resolver/features.rs:186:23 clippy::doc_markdown "you should put `RequestedFeatures` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/resolver/features.rs:187:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/features.rs:199:23 clippy::doc_markdown "you should put `RequestedFeatures` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/resolver/features.rs:200:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/features.rs:221:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/features.rs:231:21 clippy::doc_markdown "you should put `pkg_id/is_build` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/resolver/features.rs:233:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/features.rs:247:58 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/resolver/features.rs:278:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/resolver/features.rs:394:27 clippy::doc_markdown "you should put `FeatureValue` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/resolver/features.rs:460:19 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/core/resolver/features.rs:480:24 clippy::doc_markdown "you should put `FeatureValues` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/resolver/features.rs:496:24 clippy::doc_markdown "you should put `FeatureValues` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/resolver/features.rs:58:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/core/resolver/features.rs:67:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo-0.49.0/src/cargo/core/resolver/mod.rs:1017:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/resolver/mod.rs:1045:57 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/resolver/mod.rs:122:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/resolver/mod.rs:142:44 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/resolver/mod.rs:180:1 clippy::too_many_lines "this function has too many lines (225/100)" +cargo-0.49.0/src/cargo/core/resolver/mod.rs:311:17 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/core/resolver/mod.rs:421:52 clippy::filter_map_next "called `filter_map(..).next()` on an `Iterator`. This is more succinctly expressed by calling `.find_map(..)` instead." +cargo-0.49.0/src/cargo/core/resolver/mod.rs:457:69 clippy::filter_map_next "called `filter_map(..).next()` on an `Iterator`. This is more succinctly expressed by calling `.find_map(..)` instead." +cargo-0.49.0/src/cargo/core/resolver/mod.rs:470:37 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/core/resolver/mod.rs:607:11 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo-0.49.0/src/cargo/core/resolver/mod.rs:631:21 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/core/resolver/mod.rs:942:15 clippy::if_not_else "unnecessary boolean `not` operation" +cargo-0.49.0/src/cargo/core/resolver/mod.rs:988:20 clippy::redundant_else "redundant else block" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:120:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:132:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:199:24 clippy::redundant_else "redundant else block" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:235:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:239:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:255:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:259:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:263:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:269:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:273:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:274:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:280:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:284:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:288:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:292:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:296:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:300:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:315:13 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:354:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:362:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:60:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:76:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/types.rs:111:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/resolver/types.rs:121:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/types.rs:141:19 clippy::doc_markdown "you should put `ResolveOpts` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/resolver/types.rs:142:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/types.rs:149:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/types.rs:181:9 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +cargo-0.49.0/src/cargo/core/resolver/types.rs:187:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +cargo-0.49.0/src/cargo/core/resolver/types.rs:261:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +cargo-0.49.0/src/cargo/core/shell.rs:113:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/shell.rs:130:9 clippy::single_match_else "you seem to be trying to use `match` for an equality check. Consider using `if`" +cargo-0.49.0/src/cargo/core/shell.rs:148:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/shell.rs:153:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/shell.rs:163:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/shell.rs:18:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/shell.rs:198:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/shell.rs:206:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/shell.rs:214:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/shell.rs:228:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/shell.rs:239:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/shell.rs:250:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/shell.rs:259:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/shell.rs:267:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/shell.rs:26:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/shell.rs:277:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/shell.rs:282:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/shell.rs:314:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/shell.rs:322:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/shell.rs:330:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/shell.rs:98:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/source/mod.rs:103:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/source/mod.rs:247:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/core/source/mod.rs:261:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/source/mod.rs:268:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/source/mod.rs:273:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/source/mod.rs:291:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/source/mod.rs:302:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/source/mod.rs:307:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/source/mod.rs:31:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/source/mod.rs:37:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/source/mod.rs:39:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/source/mod.rs:47:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/source/mod.rs:50:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/source/mod.rs:52:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/source/mod.rs:63:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/source/mod.rs:74:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/source/mod.rs:83:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/source/source_id.rs:107:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/source/source_id.rs:128:50 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/source/source_id.rs:147:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/source/source_id.rs:156:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/source/source_id.rs:162:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/source/source_id.rs:166:19 clippy::doc_markdown "you should put `SourceId` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/source/source_id.rs:167:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/source/source_id.rs:171:19 clippy::doc_markdown "you should put `SourceId` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/source/source_id.rs:172:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/source/source_id.rs:178:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/source/source_id.rs:187:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/source/source_id.rs:18:74 clippy::default_trait_access "calling `std::sync::Mutex::default()` is more clear than this expression" +cargo-0.49.0/src/cargo/core/source/source_id.rs:195:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/source/source_id.rs:207:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/source/source_id.rs:213:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/source/source_id.rs:217:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/source/source_id.rs:225:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/source/source_id.rs:228:16 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" +cargo-0.49.0/src/cargo/core/source/source_id.rs:236:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/source/source_id.rs:241:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/source/source_id.rs:252:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/source/source_id.rs:257:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/source/source_id.rs:262:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/source/source_id.rs:305:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/source/source_id.rs:310:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/source/source_id.rs:318:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/source/source_id.rs:326:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/source/source_id.rs:355:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/source/source_id.rs:393:61 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:394:42 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:395:42 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:397:71 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:397:71 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:398:47 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:398:47 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:399:47 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:399:47 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:401:63 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:401:63 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:401:63 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:402:43 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:402:43 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:402:43 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:403:43 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:403:43 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:403:43 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:406:21 clippy::enum_glob_use "usage of wildcard import for enum variants" +cargo-0.49.0/src/cargo/core/source/source_id.rs:412:41 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:413:36 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:414:36 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:420:47 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:420:47 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:512:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo-0.49.0/src/cargo/core/source/source_id.rs:513:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo-0.49.0/src/cargo/core/source/source_id.rs:517:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo-0.49.0/src/cargo/core/source/source_id.rs:518:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo-0.49.0/src/cargo/core/source/source_id.rs:525:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo-0.49.0/src/cargo/core/source/source_id.rs:526:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo-0.49.0/src/cargo/core/source/source_id.rs:530:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo-0.49.0/src/cargo/core/source/source_id.rs:531:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo-0.49.0/src/cargo/core/source/source_id.rs:535:33 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo-0.49.0/src/cargo/core/source/source_id.rs:536:37 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo-0.49.0/src/cargo/core/source/source_id.rs:537:42 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo-0.49.0/src/cargo/core/source/source_id.rs:538:38 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo-0.49.0/src/cargo/core/source/source_id.rs:548:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/core/source/source_id.rs:597:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/summary.rs:103:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/summary.rs:123:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/summary.rs:150:1 clippy::too_many_lines "this function has too many lines (141/100)" +cargo-0.49.0/src/cargo/core/summary.rs:158:9 clippy::enum_glob_use "usage of wildcard import for enum variants" +cargo-0.49.0/src/cargo/core/summary.rs:181:21 clippy::if_not_else "unnecessary boolean `not` operation" +cargo-0.49.0/src/cargo/core/summary.rs:192:28 clippy::redundant_else "redundant else block" +cargo-0.49.0/src/cargo/core/summary.rs:258:32 clippy::redundant_else "redundant else block" +cargo-0.49.0/src/cargo/core/summary.rs:281:28 clippy::redundant_else "redundant else block" +cargo-0.49.0/src/cargo/core/summary.rs:303:28 clippy::redundant_else "redundant else block" +cargo-0.49.0/src/cargo/core/summary.rs:321:51 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/summary.rs:344:5 clippy::doc_markdown "you should put `FeatureValue` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/summary.rs:350:85 clippy::doc_markdown "you should put `FeatureValue` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/summary.rs:36:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/summary.rs:378:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/summary.rs:386:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/summary.rs:387:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +cargo-0.49.0/src/cargo/core/summary.rs:407:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +cargo-0.49.0/src/cargo/core/summary.rs:69:34 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/summary.rs:75:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/summary.rs:78:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/summary.rs:81:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/summary.rs:84:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/summary.rs:87:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/summary.rs:90:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/summary.rs:93:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/summary.rs:96:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/summary.rs:99:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/workspace.rs:1056:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo-0.49.0/src/cargo/core/workspace.rs:113:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/core/workspace.rs:1157:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/workspace.rs:128:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/core/workspace.rs:150:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/workspace.rs:159:16 clippy::redundant_else "redundant else block" +cargo-0.49.0/src/cargo/core/workspace.rs:197:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/workspace.rs:225:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/workspace.rs:255:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/workspace.rs:267:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/workspace.rs:329:37 clippy::doc_markdown "you should put `VirtualManifest` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/workspace.rs:410:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/workspace.rs:440:9 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo-0.49.0/src/cargo/core/workspace.rs:511:32 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/core/workspace.rs:561:25 clippy::non_ascii_literal "literal non-ASCII character detected" +cargo-0.49.0/src/cargo/core/workspace.rs:613:13 clippy::filter_map "called `filter_map(..).map(..)` on an `Iterator`" +cargo-0.49.0/src/cargo/core/workspace.rs:615:22 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/workspace.rs:762:27 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/core/workspace.rs:784:17 clippy::if_not_else "unnecessary boolean `not` operation" +cargo-0.49.0/src/cargo/core/workspace.rs:849:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/workspace.rs:893:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/workspace.rs:906:24 clippy::redundant_else "redundant else block" +cargo-0.49.0/src/cargo/core/workspace.rs:932:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/lib.rs:177:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/lib.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.categories` metadata" +cargo-0.49.0/src/cargo/lib.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.keywords` metadata" +cargo-0.49.0/src/cargo/lib.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `crossbeam-utils`: 0.6.6, 0.7.2" +cargo-0.49.0/src/cargo/lib.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `hex`: 0.3.2, 0.4.0" +cargo-0.49.0/src/cargo/lib.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `humantime`: 1.3.0, 2.0.0" +cargo-0.49.0/src/cargo/ops/cargo_clean.rs:205:23 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/ops/cargo_clean.rs:27:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_clean.rs:27:1 clippy::too_many_lines "this function has too many lines (120/100)" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:1078:14 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:109:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:119:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:1227:17 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:127:35 clippy::from_iter_instead_of_collect "usage of `FromIterator::from_iter`" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:173:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:205:36 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:242:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:249:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:258:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:267:16 clippy::needless_question_mark "Question mark operator is useless here" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:275:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:275:1 clippy::too_many_lines "this function has too many lines (219/100)" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:468:9 clippy::default_trait_access "calling `std::collections::HashMap::default()` is more clear than this expression" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:548:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:556:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:574:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:583:21 clippy::doc_markdown "you should put `CompileFilter` between ticks in the documentation" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:584:5 clippy::fn_params_excessive_bools "more than 3 bools in function parameters" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:584:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:592:9 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:593:9 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:607:13 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:612:21 clippy::doc_markdown "you should put `CompileFilter` between ticks in the documentation" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:613:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:618:9 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:641:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:652:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:655:50 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:673:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:692:49 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:703:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:729:1 clippy::too_many_lines "this function has too many lines (205/100)" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:82:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:874:69 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/ops/cargo_doc.rs:20:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_fetch.rs:15:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_fetch.rs:27:46 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:160:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:175:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:22:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:37:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:37:1 clippy::too_many_lines "this function has too many lines (171/100)" +cargo-0.49.0/src/cargo/ops/cargo_install.rs:13:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/cargo/ops/cargo_install.rs:148:1 clippy::fn_params_excessive_bools "more than 3 bools in function parameters" +cargo-0.49.0/src/cargo/ops/cargo_install.rs:148:1 clippy::too_many_lines "this function has too many lines (316/100)" +cargo-0.49.0/src/cargo/ops/cargo_install.rs:178:24 clippy::collapsible_else_if "this `else { if .. }` block can be collapsed" +cargo-0.49.0/src/cargo/ops/cargo_install.rs:202:17 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/ops/cargo_install.rs:236:16 clippy::collapsible_else_if "this `else { if .. }` block can be collapsed" +cargo-0.49.0/src/cargo/ops/cargo_install.rs:312:64 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/ops/cargo_install.rs:32:13 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" +cargo-0.49.0/src/cargo/ops/cargo_install.rs:339:12 clippy::collapsible_else_if "this `else { if .. }` block can be collapsed" +cargo-0.49.0/src/cargo/ops/cargo_install.rs:37:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_install.rs:454:22 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/ops/cargo_install.rs:483:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/ops/cargo_install.rs:683:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_new.rs:101:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_new.rs:245:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/ops/cargo_new.rs:251:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/ops/cargo_new.rs:367:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_new.rs:405:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_new.rs:489:5 clippy::doc_markdown "you should put `IgnoreList` between ticks in the documentation" +cargo-0.49.0/src/cargo/ops/cargo_new.rs:525:47 clippy::doc_markdown "you should put `IgnoreList` between ticks in the documentation" +cargo-0.49.0/src/cargo/ops/cargo_new.rs:525:9 clippy::doc_markdown "you should put `format_existing` between ticks in the documentation" +cargo-0.49.0/src/cargo/ops/cargo_new.rs:572:34 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/ops/cargo_new.rs:623:1 clippy::too_many_lines "this function has too many lines (130/100)" +cargo-0.49.0/src/cargo/ops/cargo_new.rs:781:5 clippy::filter_map_next "called `filter_map(..).next()` on an `Iterator`. This is more succinctly expressed by calling `.find_map(..)` instead." +cargo-0.49.0/src/cargo/ops/cargo_new.rs:800:16 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/ops/cargo_output_metadata.rs:163:36 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/ops/cargo_output_metadata.rs:27:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_output_metadata.rs:45:45 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/ops/cargo_package.rs:144:1 clippy::too_many_lines "this function has too many lines (112/100)" +cargo-0.49.0/src/cargo/ops/cargo_package.rs:207:13 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/ops/cargo_package.rs:25:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo-0.49.0/src/cargo/ops/cargo_package.rs:307:54 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/ops/cargo_package.rs:394:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/ops/cargo_package.rs:425:61 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/ops/cargo_package.rs:459:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/ops/cargo_package.rs:66:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_package.rs:93:20 clippy::if_not_else "unnecessary boolean `not` operation" +cargo-0.49.0/src/cargo/ops/cargo_pkgid.rs:5:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_read_manifest.rs:14:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_read_manifest.rs:171:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/ops/cargo_read_manifest.rs:37:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_read_manifest.rs:57:49 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/ops/cargo_read_manifest.rs:69:37 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/ops/cargo_run.rs:25:24 clippy::if_not_else "unnecessary boolean `not` operation" +cargo-0.49.0/src/cargo/ops/cargo_run.rs:35:9 clippy::if_not_else "unnecessary boolean `not` operation" +cargo-0.49.0/src/cargo/ops/cargo_run.rs:37:16 clippy::redundant_else "redundant else block" +cargo-0.49.0/src/cargo/ops/cargo_run.rs:53:9 clippy::if_not_else "unnecessary boolean `not` operation" +cargo-0.49.0/src/cargo/ops/cargo_run.rs:65:16 clippy::redundant_else "redundant else block" +cargo-0.49.0/src/cargo/ops/cargo_run.rs:9:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_test.rs:16:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_test.rs:43:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_test.rs:84:17 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/ops/cargo_uninstall.rs:14:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_uninstall.rs:7:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:147:9 clippy::doc_markdown "you should put `PackageId` between ticks in the documentation" +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:233:21 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:244:22 clippy::doc_markdown "you should put `PackageId` between ticks in the documentation" +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:244:63 clippy::doc_markdown "you should put `PackageId` between ticks in the documentation" +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:253:17 clippy::if_not_else "unnecessary boolean `not` operation" +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:370:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:505:8 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:525:10 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:542:27 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:542:5 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:561:20 clippy::redundant_else "redundant else block" +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:613:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:645:41 clippy::doc_markdown "you should put `BTreeSet` between ticks in the documentation" +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:92:19 clippy::doc_markdown "you should put `InstallTracker` between ticks in the documentation" +cargo-0.49.0/src/cargo/ops/fix.rs:200:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/fix.rs:200:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/ops/fix.rs:424:20 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +cargo-0.49.0/src/cargo/ops/fix.rs:455:13 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/ops/fix.rs:506:17 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/ops/fix.rs:608:9 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" +cargo-0.49.0/src/cargo/ops/fix.rs:612:42 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/ops/fix.rs:619:48 clippy::manual_strip "stripping a prefix manually" +cargo-0.49.0/src/cargo/ops/fix.rs:66:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/ops/fix.rs:66:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo-0.49.0/src/cargo/ops/fix.rs:708:18 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/ops/fix.rs:77:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/lockfile.rs:154:13 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo-0.49.0/src/cargo/ops/lockfile.rs:217:9 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo-0.49.0/src/cargo/ops/lockfile.rs:30:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/lockfile.rs:35:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/lockfile.rs:35:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/ops/lockfile.rs:87:1 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo-0.49.0/src/cargo/ops/lockfile.rs:8:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/lockfile.rs:8:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/ops/registry.rs:150:21 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/ops/registry.rs:188:1 clippy::too_many_lines "this function has too many lines (130/100)" +cargo-0.49.0/src/cargo/ops/registry.rs:212:32 clippy::if_not_else "unnecessary `!=` operation" +cargo-0.49.0/src/cargo/ops/registry.rs:222:53 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/ops/registry.rs:224:44 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/ops/registry.rs:31:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/ops/registry.rs:346:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/registry.rs:346:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/ops/registry.rs:351:26 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/ops/registry.rs:385:12 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo-0.49.0/src/cargo/ops/registry.rs:386:15 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo-0.49.0/src/cargo/ops/registry.rs:38:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo-0.49.0/src/cargo/ops/registry.rs:477:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/registry.rs:483:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/registry.rs:503:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/registry.rs:505:38 clippy::default_trait_access "calling `util::config::CargoHttpConfig::default()` is more clear than this expression" +cargo-0.49.0/src/cargo/ops/registry.rs:510:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/registry.rs:529:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/ops/registry.rs:53:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/registry.rs:573:22 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/ops/registry.rs:608:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/registry.rs:621:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/registry.rs:671:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/registry.rs:671:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/ops/registry.rs:674:10 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo-0.49.0/src/cargo/ops/registry.rs:678:17 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/ops/registry.rs:730:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/registry.rs:731:16 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/ops/registry.rs:785:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/registry.rs:794:16 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/ops/registry.rs:828:14 clippy::doc_markdown "you should put `SourceId` between ticks in the documentation" +cargo-0.49.0/src/cargo/ops/registry.rs:848:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/resolve.rs:199:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/resolve.rs:199:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/ops/resolve.rs:199:1 clippy::too_many_lines "this function has too many lines (137/100)" +cargo-0.49.0/src/cargo/ops/resolve.rs:241:28 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/ops/resolve.rs:28:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/ops/resolve.rs:384:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/resolve.rs:417:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/resolve.rs:589:9 clippy::shadow_unrelated "`keep` is being shadowed" +cargo-0.49.0/src/cargo/ops/resolve.rs:58:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/resolve.rs:58:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/ops/resolve.rs:602:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/ops/resolve.rs:75:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/resolve.rs:75:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/ops/tree/graph.rs:129:26 clippy::doc_markdown "you should put `PackageIds` between ticks in the documentation" +cargo-0.49.0/src/cargo/ops/tree/graph.rs:152:15 clippy::match_on_vec_items "indexing into a vector may panic" +cargo-0.49.0/src/cargo/ops/tree/graph.rs:173:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/ops/tree/graph.rs:234:46 clippy::filter_map "called `filter(..).flat_map(..)` on an `Iterator`" +cargo-0.49.0/src/cargo/ops/tree/graph.rs:328:44 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/ops/tree/graph.rs:330:50 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/ops/tree/graph.rs:563:35 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/ops/tree/mod.rs:112:11 clippy::non_ascii_literal "literal non-ASCII character detected" +cargo-0.49.0/src/cargo/ops/tree/mod.rs:113:10 clippy::non_ascii_literal "literal non-ASCII character detected" +cargo-0.49.0/src/cargo/ops/tree/mod.rs:114:10 clippy::non_ascii_literal "literal non-ASCII character detected" +cargo-0.49.0/src/cargo/ops/tree/mod.rs:115:12 clippy::non_ascii_literal "literal non-ASCII character detected" +cargo-0.49.0/src/cargo/ops/tree/mod.rs:126:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/tree/mod.rs:21:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/ops/tree/mod.rs:21:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo-0.49.0/src/cargo/ops/tree/mod.rs:360:30 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/ops/tree/mod.rs:58:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/ops/vendor.rs:14:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/ops/vendor.rs:21:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/vendor.rs:314:34 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/ops/vendor.rs:320:29 clippy::case_sensitive_file_extension_comparisons "case-sensitive file extension comparison" +cargo-0.49.0/src/cargo/ops/vendor.rs:320:60 clippy::case_sensitive_file_extension_comparisons "case-sensitive file extension comparison" +cargo-0.49.0/src/cargo/ops/vendor.rs:324:13 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +cargo-0.49.0/src/cargo/ops/vendor.rs:70:1 clippy::too_many_lines "this function has too many lines (175/100)" +cargo-0.49.0/src/cargo/sources/config.rs:102:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/config.rs:111:28 clippy::needless_question_mark "Question mark operator is useless here" +cargo-0.49.0/src/cargo/sources/config.rs:133:48 clippy::needless_question_mark "Question mark operator is useless here" +cargo-0.49.0/src/cargo/sources/config.rs:135:67 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/sources/config.rs:206:36 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo-0.49.0/src/cargo/sources/config.rs:282:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/sources/config.rs:70:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/config.rs:81:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/config.rs:97:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/sources/directory.rs:14:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/sources/directory.rs:90:56 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/sources/git/source.rs:14:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/sources/git/source.rs:25:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/git/source.rs:49:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/sources/git/source.rs:53:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/git/source.rs:69:20 clippy::comparison_to_empty "comparison to empty slice" +cargo-0.49.0/src/cargo/sources/git/utils.rs:1025:19 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/sources/git/utils.rs:1157:36 clippy::case_sensitive_file_extension_comparisons "case-sensitive file extension comparison" +cargo-0.49.0/src/cargo/sources/git/utils.rs:1158:9 clippy::manual_strip "stripping a suffix manually" +cargo-0.49.0/src/cargo/sources/git/utils.rs:134:12 clippy::upper_case_acronyms "name `GitShortID` contains a capitalized acronym" +cargo-0.49.0/src/cargo/sources/git/utils.rs:176:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/sources/git/utils.rs:180:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/sources/git/utils.rs:184:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/git/utils.rs:188:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/git/utils.rs:242:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/git/utils.rs:253:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/git/utils.rs:262:13 clippy::if_not_else "unnecessary boolean `not` operation" +cargo-0.49.0/src/cargo/sources/git/utils.rs:289:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/git/utils.rs:294:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/sources/git/utils.rs:298:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/git/utils.rs:308:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/git/utils.rs:472:9 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" +cargo-0.49.0/src/cargo/sources/git/utils.rs:489:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/sources/git/utils.rs:503:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/sources/git/utils.rs:528:28 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/sources/git/utils.rs:537:21 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" +cargo-0.49.0/src/cargo/sources/git/utils.rs:588:1 clippy::too_many_lines "this function has too many lines (135/100)" +cargo-0.49.0/src/cargo/sources/git/utils.rs:692:9 clippy::vec_init_then_push "calls to `push` immediately after creation" +cargo-0.49.0/src/cargo/sources/git/utils.rs:758:9 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo-0.49.0/src/cargo/sources/git/utils.rs:858:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/path.rs:129:44 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/sources/path.rs:143:44 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/sources/path.rs:15:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/sources/path.rs:282:50 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/sources/path.rs:313:21 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/sources/path.rs:314:21 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/sources/path.rs:319:21 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/sources/path.rs:339:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/sources/path.rs:339:9 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo-0.49.0/src/cargo/sources/path.rs:380:9 clippy::unused_self "unused `self` argument" +cargo-0.49.0/src/cargo/sources/path.rs:419:50 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/sources/path.rs:429:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/path.rs:460:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/sources/path.rs:473:43 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/sources/path.rs:482:43 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/sources/path.rs:63:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/path.rs:77:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/path.rs:98:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/registry/index.rs:117:23 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo-0.49.0/src/cargo/sources/registry/index.rs:121:70 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo-0.49.0/src/cargo/sources/registry/index.rs:167:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/sources/registry/index.rs:215:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/sources/registry/index.rs:324:23 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/sources/registry/index.rs:468:40 clippy::doc_markdown "you should put `SourceId` between ticks in the documentation" +cargo-0.49.0/src/cargo/sources/registry/index.rs:590:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/sources/registry/index.rs:648:17 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/sources/registry/index.rs:736:1 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +cargo-0.49.0/src/cargo/sources/registry/index.rs:95:37 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +cargo-0.49.0/src/cargo/sources/registry/local.rs:12:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/sources/registry/mod.rs:192:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/sources/registry/mod.rs:203:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/sources/registry/mod.rs:229:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/sources/registry/mod.rs:372:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/sources/registry/mod.rs:373:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/registry/mod.rs:375:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/registry/mod.rs:381:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/registry/mod.rs:382:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/registry/mod.rs:383:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/registry/mod.rs:384:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/registry/mod.rs:452:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/registry/mod.rs:582:20 clippy::redundant_else "redundant else block" +cargo-0.49.0/src/cargo/sources/registry/mod.rs:621:9 clippy::if_not_else "unnecessary `!=` operation" +cargo-0.49.0/src/cargo/sources/registry/remote.rs:139:17 clippy::unused_self "unused `self` argument" +cargo-0.49.0/src/cargo/sources/registry/remote.rs:32:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/sources/registry/remote.rs:72:13 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/sources/replaced.rs:12:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/sources/replaced.rs:5:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/util/canonical_url.rs:19:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/canonical_url.rs:50:41 clippy::case_sensitive_file_extension_comparisons "case-sensitive file extension comparison" +cargo-0.49.0/src/cargo/util/canonical_url.rs:65:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/command_prelude.rs:218:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/command_prelude.rs:222:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/command_prelude.rs:234:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/command_prelude.rs:249:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/command_prelude.rs:264:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/command_prelude.rs:279:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/command_prelude.rs:298:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/command_prelude.rs:320:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/command_prelude.rs:328:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/command_prelude.rs:352:13 clippy::if_not_else "unnecessary boolean `not` operation" +cargo-0.49.0/src/cargo/util/command_prelude.rs:363:13 clippy::if_not_else "unnecessary boolean `not` operation" +cargo-0.49.0/src/cargo/util/command_prelude.rs:378:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/command_prelude.rs:387:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/command_prelude.rs:387:5 clippy::too_many_lines "this function has too many lines (104/100)" +cargo-0.49.0/src/cargo/util/command_prelude.rs:39:20 clippy::doc_markdown "you should put `arg_package_spec` between ticks in the documentation" +cargo-0.49.0/src/cargo/util/command_prelude.rs:504:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/command_prelude.rs:516:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/command_prelude.rs:530:40 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/util/command_prelude.rs:531:43 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/util/command_prelude.rs:536:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/command_prelude.rs:556:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/command_prelude.rs:575:49 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/util/command_prelude.rs:580:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/command_prelude.rs:631:18 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/util/command_prelude.rs:638:18 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/util/command_prelude.rs:647:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/command_prelude.rs:651:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/command_prelude.rs:662:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/command_prelude.rs:665:51 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/util/config/de.rs:420:16 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo-0.49.0/src/cargo/util/config/de.rs:46:25 clippy::doc_markdown "you should put `CV::List` between ticks in the documentation" +cargo-0.49.0/src/cargo/util/config/de.rs:47:24 clippy::doc_markdown "you should put `ConfigSeqAccess` between ticks in the documentation" +cargo-0.49.0/src/cargo/util/config/de.rs:527:53 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo-0.49.0/src/cargo/util/config/de.rs:530:53 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo-0.49.0/src/cargo/util/config/de.rs:532:68 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo-0.49.0/src/cargo/util/config/key.rs:11:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/util/config/key.rs:69:9 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo-0.49.0/src/cargo/util/config/mod.rs:100:71 clippy::doc_markdown "you should put `OptValue` between ticks in the documentation" +cargo-0.49.0/src/cargo/util/config/mod.rs:100:71 clippy::doc_markdown "you should put `OptValue` between ticks in the documentation" +cargo-0.49.0/src/cargo/util/config/mod.rs:100:71 clippy::doc_markdown "you should put `OptValue` between ticks in the documentation" +cargo-0.49.0/src/cargo/util/config/mod.rs:1049:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:1064:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:1090:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:1166:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:1179:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:1181:33 clippy::needless_question_mark "Question mark operator is useless here" +cargo-0.49.0/src/cargo/util/config/mod.rs:1184:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:1186:33 clippy::needless_question_mark "Question mark operator is useless here" +cargo-0.49.0/src/cargo/util/config/mod.rs:1189:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:1191:33 clippy::needless_question_mark "Question mark operator is useless here" +cargo-0.49.0/src/cargo/util/config/mod.rs:1203:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:1211:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:1216:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:1225:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:1229:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:124:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo-0.49.0/src/cargo/util/config/mod.rs:1254:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:1279:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:1281:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/util/config/mod.rs:1323:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/util/config/mod.rs:1339:39 clippy::unused_self "unused `self` argument" +cargo-0.49.0/src/cargo/util/config/mod.rs:1344:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/util/config/mod.rs:1420:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/util/config/mod.rs:1553:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:1560:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:1567:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:1574:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:1581:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:1588:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/config/mod.rs:1598:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/config/mod.rs:1619:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/config/mod.rs:1623:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:1623:64 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo-0.49.0/src/cargo/util/config/mod.rs:1649:9 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" +cargo-0.49.0/src/cargo/util/config/mod.rs:1699:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/util/config/mod.rs:1730:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/util/config/mod.rs:1757:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/util/config/mod.rs:1770:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/util/config/mod.rs:1778:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/util/config/mod.rs:1804:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/util/config/mod.rs:1896:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/config/mod.rs:1901:5 clippy::doc_markdown "you should put `StringList` between ticks in the documentation" +cargo-0.49.0/src/cargo/util/config/mod.rs:214:13 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +cargo-0.49.0/src/cargo/util/config/mod.rs:259:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:298:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:311:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:318:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:353:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:401:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:411:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:419:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:431:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:449:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:454:16 clippy::option_if_let_else "use Option::map_or instead of an if let/else" +cargo-0.49.0/src/cargo/util/config/mod.rs:547:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:556:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:582:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:595:20 clippy::doc_markdown "you should put `StringList` between ticks in the documentation" +cargo-0.49.0/src/cargo/util/config/mod.rs:689:20 clippy::unused_self "unused `self` argument" +cargo-0.49.0/src/cargo/util/config/mod.rs:699:5 clippy::fn_params_excessive_bools "more than 3 bools in function parameters" +cargo-0.49.0/src/cargo/util/config/mod.rs:699:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:719:58 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/util/config/mod.rs:816:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:875:36 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/util/config/mod.rs:876:37 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/util/config/path.rs:10:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/util/config/path.rs:14:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/config/path.rs:48:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/util/config/target.rs:12:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/util/config/target.rs:24:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/util/config/value.rs:29:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/util/config/value.rs:80:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/config/value.rs:81:9 clippy::match_like_matches_macro "match expression looks like `matches!` macro" +cargo-0.49.0/src/cargo/util/cpu.rs:11:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/cpu.rs:22:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/cpu.rs:82:25 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +cargo-0.49.0/src/cargo/util/cpu.rs:82:9 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +cargo-0.49.0/src/cargo/util/dependency_queue.rs:109:27 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/util/dependency_queue.rs:151:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/dependency_queue.rs:156:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/dependency_queue.rs:46:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/dependency_queue.rs:91:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/util/diagnostic_server.rs:218:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/util/diagnostic_server.rs:230:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/diagnostic_server.rs:242:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/diagnostic_server.rs:58:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/diagnostic_server.rs:96:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/diagnostic_server.rs:96:5 clippy::too_many_lines "this function has too many lines (110/100)" +cargo-0.49.0/src/cargo/util/diagnostic_server.rs:99:21 clippy::shadow_unrelated "`msg` is being shadowed" +cargo-0.49.0/src/cargo/util/errors.rs:101:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/errors.rs:143:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/errors.rs:150:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/errors.rs:15:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/errors.rs:237:5 clippy::pub_enum_variant_names "variant name ends with the enum's name" +cargo-0.49.0/src/cargo/util/errors.rs:245:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/errors.rs:321:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/errors.rs:328:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/errors.rs:356:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/errors.rs:391:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/util/errors.rs:392:13 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/cargo/util/errors.rs:465:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/errors.rs:473:5 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +cargo-0.49.0/src/cargo/util/errors.rs:66:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/flock.rs:115:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/flock.rs:11:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/cargo/util/flock.rs:134:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/flock.rs:142:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/flock.rs:150:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/flock.rs:156:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/flock.rs:170:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/flock.rs:192:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/flock.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/flock.rs:321:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/util/flock.rs:335:23 clippy::cast_possible_truncation "casting `i64` to `u32` may truncate the value" +cargo-0.49.0/src/cargo/util/flock.rs:335:23 clippy::cast_sign_loss "casting `i64` to `u32` may lose the sign of the value" +cargo-0.49.0/src/cargo/util/flock.rs:335:44 clippy::cast_possible_truncation "casting `i64` to `u32` may truncate the value" +cargo-0.49.0/src/cargo/util/flock.rs:379:35 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/util/flock.rs:37:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/flock.rs:43:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/flock.rs:52:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/graph.rs:10:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/graph.rs:41:51 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/util/graph.rs:45:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/hasher.rs:12:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/hasher.rs:9:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/util/hex.rs:10:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" +cargo-0.49.0/src/cargo/util/hex.rs:11:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" +cargo-0.49.0/src/cargo/util/hex.rs:12:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" +cargo-0.49.0/src/cargo/util/hex.rs:13:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" +cargo-0.49.0/src/cargo/util/hex.rs:14:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" +cargo-0.49.0/src/cargo/util/hex.rs:15:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" +cargo-0.49.0/src/cargo/util/hex.rs:25:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/hex.rs:6:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/util/hex.rs:6:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/hex.rs:8:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" +cargo-0.49.0/src/cargo/util/hex.rs:9:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" +cargo-0.49.0/src/cargo/util/important_paths.rs:23:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/important_paths.rs:6:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/interning.rs:66:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/interning.rs:77:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/into_url.rs:10:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/into_url_with_base.rs:9:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/job.rs:20:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/lev_distance.rs:3:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/lockserver.rs:111:32 clippy::redundant_else "redundant else block" +cargo-0.49.0/src/cargo/util/lockserver.rs:158:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/lockserver.rs:46:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/lockserver.rs:58:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/lockserver.rs:62:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/mod.rs:68:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/mod.rs:79:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/network.rs:12:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/network.rs:19:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/network.rs:84:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/paths.rs:109:12 clippy::redundant_else "redundant else block" +cargo-0.49.0/src/cargo/util/paths.rs:114:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/paths.rs:121:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/paths.rs:125:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/paths.rs:130:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/paths.rs:14:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/paths.rs:14:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/util/paths.rs:151:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/paths.rs:167:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/paths.rs:173:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/paths.rs:178:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/paths.rs:185:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/paths.rs:199:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/paths.rs:215:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/paths.rs:228:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/paths.rs:251:9 clippy::option_if_let_else "use Option::map_or instead of an if let/else" +cargo-0.49.0/src/cargo/util/paths.rs:267:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/paths.rs:276:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/paths.rs:29:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/paths.rs:303:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/paths.rs:312:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/paths.rs:346:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/paths.rs:415:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/paths.rs:445:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/paths.rs:459:45 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/util/paths.rs:469:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/paths.rs:54:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/paths.rs:61:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/paths.rs:63:19 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" +cargo-0.49.0/src/cargo/util/paths.rs:88:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/paths.rs:93:31 clippy::comparison_to_empty "comparison to empty slice" +cargo-0.49.0/src/cargo/util/process_builder.rs:106:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/process_builder.rs:111:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/process_builder.rs:122:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/process_builder.rs:132:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/process_builder.rs:152:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/process_builder.rs:185:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/process_builder.rs:190:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/process_builder.rs:218:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/process_builder.rs:307:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/process_builder.rs:343:39 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo-0.49.0/src/cargo/util/progress.rs:122:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/progress.rs:136:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/progress.rs:15:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/util/progress.rs:249:19 clippy::cast_precision_loss "casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +cargo-0.49.0/src/cargo/util/progress.rs:249:34 clippy::cast_precision_loss "casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +cargo-0.49.0/src/cargo/util/progress.rs:250:19 clippy::if_not_else "unnecessary boolean `not` operation" +cargo-0.49.0/src/cargo/util/progress.rs:263:22 clippy::cast_precision_loss "casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +cargo-0.49.0/src/cargo/util/progress.rs:264:22 clippy::cast_possible_truncation "casting `f64` to `usize` may truncate the value" +cargo-0.49.0/src/cargo/util/progress.rs:264:22 clippy::cast_sign_loss "casting `f64` to `usize` may lose the sign of the value" +cargo-0.49.0/src/cargo/util/progress.rs:269:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo-0.49.0/src/cargo/util/progress.rs:272:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo-0.49.0/src/cargo/util/progress.rs:274:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo-0.49.0/src/cargo/util/progress.rs:280:13 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo-0.49.0/src/cargo/util/progress.rs:282:9 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo-0.49.0/src/cargo/util/progress.rs:89:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/progress.rs:97:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/queue.rs:25:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/read2.rs:11:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/read2.rs:31:17 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/util/restricted_names.rs:13:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/restricted_names.rs:26:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/restricted_names.rs:35:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/restricted_names.rs:45:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/restricted_names.rs:87:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/restricted_names.rs:89:21 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/util/restricted_names.rs:8:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/rustc.rs:103:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/rustc.rs:114:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +cargo-0.49.0/src/cargo/util/rustc.rs:115:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +cargo-0.49.0/src/cargo/util/rustc.rs:162:17 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/util/rustc.rs:39:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/sha256.rs:10:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/sha256.rs:20:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/sha256.rs:31:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/sha256.rs:40:24 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo-0.49.0/src/cargo/util/to_semver.rs:5:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/toml/mod.rs:1005:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/toml/mod.rs:1005:5 clippy::too_many_lines "this function has too many lines (282/100)" +cargo-0.49.0/src/cargo/util/toml/mod.rs:1094:36 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/util/toml/mod.rs:1121:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/util/toml/mod.rs:1197:32 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +cargo-0.49.0/src/cargo/util/toml/mod.rs:124:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/toml/mod.rs:1504:9 clippy::unused_self "unused `self` argument" +cargo-0.49.0/src/cargo/util/toml/mod.rs:1526:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/toml/mod.rs:1582:19 clippy::default_trait_access "calling `util::toml::DetailedTomlDependency::default()` is more clear than this expression" +cargo-0.49.0/src/cargo/util/toml/mod.rs:1598:5 clippy::too_many_lines "this function has too many lines (153/100)" +cargo-0.49.0/src/cargo/util/toml/mod.rs:1687:33 clippy::unnecessary_lazy_evaluations "unnecessary closure used to substitute value for `Option::None`" +cargo-0.49.0/src/cargo/util/toml/mod.rs:178:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/util/toml/mod.rs:248:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/util/toml/mod.rs:274:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/util/toml/mod.rs:277:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/toml/mod.rs:281:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/toml/mod.rs:285:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/toml/mod.rs:294:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/util/toml/mod.rs:31:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/toml/mod.rs:381:35 clippy::cast_possible_truncation "casting `i64` to `u32` may truncate the value" +cargo-0.49.0/src/cargo/util/toml/mod.rs:381:35 clippy::cast_sign_loss "casting `i64` to `u32` may lose the sign of the value" +cargo-0.49.0/src/cargo/util/toml/mod.rs:388:35 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +cargo-0.49.0/src/cargo/util/toml/mod.rs:398:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/util/toml/mod.rs:450:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/toml/mod.rs:536:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/toml/mod.rs:783:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/util/toml/mod.rs:824:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/util/toml/mod.rs:834:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/toml/mod.rs:83:42 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/util/toml/mod.rs:852:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/toml/mod.rs:852:5 clippy::too_many_lines "this function has too many lines (138/100)" +cargo-0.49.0/src/cargo/util/toml/mod.rs:962:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/util/toml/mod.rs:979:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/util/toml/mod.rs:98:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/util/toml/mod.rs:999:23 clippy::default_trait_access "calling `util::toml::DetailedTomlDependency::default()` is more clear than this expression" +cargo-0.49.0/src/cargo/util/toml/targets.rs:112:27 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/util/toml/targets.rs:325:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/util/toml/targets.rs:586:21 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/util/toml/targets.rs:593:42 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/util/toml/targets.rs:605:19 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/util/toml/targets.rs:612:42 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/util/toml/targets.rs:756:36 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/util/vcs.rs:10:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/vcs.rs:33:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/vcs.rs:37:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/vcs.rs:43:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/vcs.rs:47:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/vcs.rs:59:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/vcs.rs:66:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/workspace.rs:52:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/workspace.rs:56:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/workspace.rs:60:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/workspace.rs:64:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron-0.6.1/src/error.rs:24:1 clippy::module_name_repetitions "item name ends with its containing module's name" +iron-0.6.1/src/iron.rs:105:13 clippy::redundant_field_names "redundant field names in struct initialization" +iron-0.6.1/src/iron.rs:119:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron-0.6.1/src/iron.rs:133:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron-0.6.1/src/iron.rs:143:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron-0.6.1/src/iron.rs:149:13 clippy::redundant_field_names "redundant field names in struct initialization" +iron-0.6.1/src/iron.rs:167:49 clippy::similar_names "binding's name is too similar to existing binding" +iron-0.6.1/src/iron.rs:80:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron-0.6.1/src/iron.rs:85:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron-0.6.1/src/iron.rs:90:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron-0.6.1/src/lib.rs:1:null clippy::cargo_common_metadata "package `iron` is missing `package.categories` metadata" +iron-0.6.1/src/lib.rs:1:null clippy::cargo_common_metadata "package `iron` is missing `package.keywords` metadata" +iron-0.6.1/src/lib.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `log`: 0.3.9, 0.4.8" +iron-0.6.1/src/middleware/mod.rs:137:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron-0.6.1/src/middleware/mod.rs:150:1 clippy::module_name_repetitions "item name ends with its containing module's name" +iron-0.6.1/src/middleware/mod.rs:152:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron-0.6.1/src/middleware/mod.rs:159:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron-0.6.1/src/middleware/mod.rs:171:1 clippy::module_name_repetitions "item name ends with its containing module's name" +iron-0.6.1/src/middleware/mod.rs:173:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron-0.6.1/src/middleware/mod.rs:182:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron-0.6.1/src/middleware/mod.rs:192:1 clippy::module_name_repetitions "item name ends with its containing module's name" +iron-0.6.1/src/middleware/mod.rs:217:25 clippy::doc_markdown "you should put `ChainBuilder` between ticks in the documentation" +iron-0.6.1/src/middleware/mod.rs:328:20 clippy::similar_names "binding's name is too similar to existing binding" +iron-0.6.1/src/middleware/mod.rs:360:16 clippy::similar_names "binding's name is too similar to existing binding" +iron-0.6.1/src/middleware/mod.rs:368:33 clippy::similar_names "binding's name is too similar to existing binding" +iron-0.6.1/src/middleware/mod.rs:428:40 clippy::similar_names "binding's name is too similar to existing binding" +iron-0.6.1/src/middleware/mod.rs:434:40 clippy::similar_names "binding's name is too similar to existing binding" +iron-0.6.1/src/middleware/mod.rs:444:40 clippy::similar_names "binding's name is too similar to existing binding" +iron-0.6.1/src/modifiers.rs:132:14 clippy::expect_fun_call "use of `expect` followed by a function call" +iron-0.6.1/src/request/mod.rs:113:24 clippy::similar_names "binding's name is too similar to existing binding" +iron-0.6.1/src/request/mod.rs:121:13 clippy::redundant_field_names "redundant field names in struct initialization" +iron-0.6.1/src/request/mod.rs:123:13 clippy::redundant_field_names "redundant field names in struct initialization" +iron-0.6.1/src/request/mod.rs:124:13 clippy::redundant_field_names "redundant field names in struct initialization" +iron-0.6.1/src/request/mod.rs:126:13 clippy::redundant_field_names "redundant field names in struct initialization" +iron-0.6.1/src/request/mod.rs:128:13 clippy::redundant_field_names "redundant field names in struct initialization" +iron-0.6.1/src/request/mod.rs:153:69 clippy::doc_markdown "you should put `HttpReader` between ticks in the documentation" +iron-0.6.1/src/request/mod.rs:154:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron-0.6.1/src/request/mod.rs:32:1 clippy::manual_non_exhaustive "this seems like a manual implementation of the non-exhaustive pattern" +iron-0.6.1/src/request/mod.rs:75:34 clippy::doc_markdown "you should put `HttpRequest` between ticks in the documentation" +iron-0.6.1/src/request/mod.rs:77:39 clippy::doc_markdown "you should put `HttpRequest` between ticks in the documentation" +iron-0.6.1/src/request/mod.rs:78:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron-0.6.1/src/request/mod.rs:82:13 clippy::similar_names "binding's name is too similar to existing binding" +iron-0.6.1/src/request/mod.rs:83:29 clippy::similar_names "binding's name is too similar to existing binding" +iron-0.6.1/src/request/mod.rs:85:24 clippy::similar_names "binding's name is too similar to existing binding" +iron-0.6.1/src/request/url.rs:109:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron-0.6.1/src/request/url.rs:117:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron-0.6.1/src/request/url.rs:129:1 clippy::from_over_into "an implementation of `From` is preferred since it gives you `Into<_>` for free where the reverse isn't true" +iron-0.6.1/src/request/url.rs:21:14 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +iron-0.6.1/src/request/url.rs:22:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron-0.6.1/src/request/url.rs:31:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron-0.6.1/src/request/url.rs:47:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron-0.6.1/src/request/url.rs:52:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron-0.6.1/src/request/url.rs:57:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron-0.6.1/src/request/url.rs:63:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron-0.6.1/src/request/url.rs:73:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron-0.6.1/src/request/url.rs:83:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron-0.6.1/src/request/url.rs:96:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron-0.6.1/src/response.rs:121:19 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +iron-0.6.1/src/response.rs:125:43 clippy::redundant_closure_for_method_calls "redundant closure found" +iron-0.6.1/src/response.rs:139:41 clippy::redundant_closure_for_method_calls "redundant closure found" +iron-0.6.1/src/response.rs:24:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron-0.6.1/src/response.rs:95:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron-0.6.1/src/response.rs:95:5 clippy::new_without_default "you should consider adding a `Default` implementation for `response::Response`" +libc-0.2.81/build.rs:114:19 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +libc-0.2.81/build.rs:124:5 clippy::question_mark "this block may be rewritten with the `?` operator" +libc-0.2.81/build.rs:133:5 clippy::question_mark "this block may be rewritten with the `?` operator" +libc-0.2.81/src/macros.rs:243:17 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +libc-0.2.81/src/macros.rs:243:17 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +libc-0.2.81/src/macros.rs:243:17 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:428:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:429:30 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:431:30 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:432:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:433:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:434:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:595:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:596:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:597:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:622:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:673:34 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:696:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:697:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:698:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:699:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:712:34 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:721:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:722:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:723:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:751:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:752:30 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:753:30 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:754:30 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:755:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:756:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:757:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:758:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:759:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:760:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:768:30 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:769:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:771:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:772:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:773:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:774:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:775:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:776:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:777:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:778:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:779:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:780:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:781:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:782:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:783:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:784:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:785:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:786:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:787:30 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:788:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:789:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:790:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:791:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:792:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:794:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:795:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:796:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:797:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:798:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:799:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:800:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:801:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:803:27 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:804:28 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:805:28 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:806:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:807:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:808:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:809:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:810:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:811:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:812:30 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:813:30 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:814:30 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:815:30 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:816:30 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:817:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:818:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:821:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:822:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:823:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:824:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:825:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:826:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:827:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:828:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:829:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:830:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:831:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:832:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:833:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:834:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:835:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:836:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:841:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:842:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:843:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:844:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:1120:38 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:178:34 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:291:5 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:291:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:299:11 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:302:5 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:302:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:312:11 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:352:20 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:355:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:355:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:359:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:359:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:363:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:363:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:367:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:367:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:371:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:371:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:534:36 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:645:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:727:40 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:728:40 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:729:39 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:731:44 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:732:36 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:733:41 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:734:43 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:735:42 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:736:40 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:737:36 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:738:37 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:741:39 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:742:40 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:743:40 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:744:40 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:745:40 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:746:43 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:747:42 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:748:40 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:749:39 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:750:41 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:751:41 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:752:43 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:753:42 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:755:42 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:756:41 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:757:41 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:758:39 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:759:39 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:761:41 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:762:44 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:763:45 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:764:40 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:765:40 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:766:40 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:767:44 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:768:44 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:769:39 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:770:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:771:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:772:37 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:773:39 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:774:45 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:775:41 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:776:39 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:803:34 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:841:30 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:842:37 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:982:40 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:984:46 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1209:36 clippy::cast_possible_truncation "casting `i32` to `i16` may truncate the value" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1210:36 clippy::cast_possible_truncation "casting `i32` to `i16` may truncate the value" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1235:39 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1236:41 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1274:42 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1324:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1333:37 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1334:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1346:34 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1346:34 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1346:34 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1347:37 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1347:37 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1347:37 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1348:36 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1348:36 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1348:36 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1349:37 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1349:37 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1349:37 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1350:35 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1350:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1350:35 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1351:36 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1351:36 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1351:36 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1352:31 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1352:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1352:31 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1419:36 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1420:36 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1421:36 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1422:36 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1423:36 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1490:37 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1561:46 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1562:45 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1567:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1568:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1586:26 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1587:34 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1588:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1589:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1897:38 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1898:51 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1900:39 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1969:34 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1970:34 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1971:36 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1972:36 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1973:36 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1974:37 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1975:37 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1976:36 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1977:36 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1978:39 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1979:39 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1980:39 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1981:39 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1982:39 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1983:39 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1984:38 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1985:38 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1986:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1987:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1988:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1989:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1990:38 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1991:37 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1992:37 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1993:38 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1994:37 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1995:37 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1996:37 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1997:37 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1998:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1999:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2000:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2001:34 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2002:34 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2003:34 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2004:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2005:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2032:30 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2033:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2034:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2035:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2036:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2037:28 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2038:27 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2039:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2041:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2042:28 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2043:27 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2044:34 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2045:27 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2046:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2048:28 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2049:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2050:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2051:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2052:26 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2053:36 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2318:42 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2321:38 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2331:39 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2487:42 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2488:42 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2489:43 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2490:43 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2491:43 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2493:47 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2494:44 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2495:46 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2496:47 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2497:49 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2498:48 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2499:50 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2500:45 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2572:9 clippy::needless_return "unneeded `return` statement" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2578:20 clippy::zero_ptr "`0 as *mut _` detected" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2588:13 clippy::zero_ptr "`0 as *mut _` detected" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2590:13 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2596:52 clippy::used_underscore_binding "used binding `_dummy` which is prefixed with an underscore. A leading underscore signals that a binding will not be used." +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2597:11 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2601:21 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2611:9 clippy::unused_unit "unneeded unit expression" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2619:9 clippy::unused_unit "unneeded unit expression" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2634:9 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2647:25 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2648:25 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2649:9 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2654:18 clippy::identity_op "the operation is ineffective. Consider reducing it to `(dev & 0x00000000000000ff)`" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2654:25 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2655:25 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2656:9 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2660:21 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2661:21 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2663:25 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2664:25 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2665:16 clippy::identity_op "the operation is ineffective. Consider reducing it to `(minor & 0x000000ff)`" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2665:25 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2666:25 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:954:34 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1000:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1001:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1002:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1016:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1017:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1018:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1019:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1020:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1029:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1030:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1031:30 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1032:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1033:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1034:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1035:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1041:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1042:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1043:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1044:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1045:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1046:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1047:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1048:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1049:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1050:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1051:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1053:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1054:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1055:30 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1056:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1057:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1058:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1059:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1060:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1073:42 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1074:43 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1075:37 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1076:37 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1077:41 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1078:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1079:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1080:36 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1081:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1082:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1083:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1084:38 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1086:30 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1087:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1089:30 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1090:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1091:30 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1094:40 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1095:37 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1096:41 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1097:40 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1098:39 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1099:34 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1100:36 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1101:38 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1102:37 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1105:44 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1106:41 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1107:42 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1108:42 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1109:41 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1110:46 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1111:41 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1112:44 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1113:40 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1114:47 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1115:36 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1126:34 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1127:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1128:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1179:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1180:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1218:27 clippy::identity_op "the operation is ineffective. Consider reducing it to `IPOPT_CONTROL`" +libc-0.2.81/src/unix/linux_like/mod.rs:1314:9 clippy::precedence "operator precedence can trip the unwary" +libc-0.2.81/src/unix/linux_like/mod.rs:1321:13 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" +libc-0.2.81/src/unix/linux_like/mod.rs:1323:13 clippy::zero_ptr "`0 as *mut _` detected" +libc-0.2.81/src/unix/linux_like/mod.rs:1332:9 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +libc-0.2.81/src/unix/linux_like/mod.rs:1337:9 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +libc-0.2.81/src/unix/linux_like/mod.rs:1341:18 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" +libc-0.2.81/src/unix/linux_like/mod.rs:1344:9 clippy::needless_return "unneeded `return` statement" +libc-0.2.81/src/unix/linux_like/mod.rs:1348:18 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" +libc-0.2.81/src/unix/linux_like/mod.rs:1350:9 clippy::needless_return "unneeded `return` statement" +libc-0.2.81/src/unix/linux_like/mod.rs:1354:18 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" +libc-0.2.81/src/unix/linux_like/mod.rs:1357:9 clippy::needless_return "unneeded `return` statement" +libc-0.2.81/src/unix/linux_like/mod.rs:1361:21 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" +libc-0.2.81/src/unix/linux_like/mod.rs:1381:9 clippy::cast_possible_truncation "casting `i32` to `i8` may truncate the value" +libc-0.2.81/src/unix/linux_like/mod.rs:1389:9 clippy::verbose_bit_mask "bit mask could be simplified with a call to `trailing_zeros`" +libc-0.2.81/src/unix/linux_like/mod.rs:446:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:591:36 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:592:38 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:593:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:594:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:595:34 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:596:36 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:597:37 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:598:37 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:599:39 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:600:34 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:601:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:602:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:607:37 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:608:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:764:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:765:39 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:991:30 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/mod.rs:198:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/mod.rs:199:28 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/mod.rs:201:35 clippy::unnecessary_cast "casting integer literal to `usize` is unnecessary" +libc-0.2.81/src/unix/mod.rs:202:35 clippy::unnecessary_cast "casting integer literal to `usize` is unnecessary" +libc-0.2.81/src/unix/mod.rs:282:40 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/mod.rs:284:41 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/mod.rs:285:36 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/mod.rs:34:10 clippy::upper_case_acronyms "name `DIR` contains a capitalized acronym" +libc-0.2.81/src/unix/mod.rs:386:10 clippy::upper_case_acronyms "name `FILE` contains a capitalized acronym" +log-0.4.11/src/lib.rs:1047:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:1053:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:1059:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:1093:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:1093:5 clippy::new_without_default "you should consider adding a `Default` implementation for `MetadataBuilder<'a>`" +log-0.4.11/src/lib.rs:1118:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:1177:1 clippy::inline_always "you have declared `#[inline(always)]` on `max_level`. This is usually a bad idea" +log-0.4.11/src/lib.rs:1178:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:1306:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +log-0.4.11/src/lib.rs:1358:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:1359:5 clippy::if_not_else "unnecessary `!=` operation" +log-0.4.11/src/lib.rs:1407:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:329:27 clippy::derive_hash_xor_eq "you are deriving `Hash` but have implemented `PartialEq` explicitly" +log-0.4.11/src/lib.rs:356:1 clippy::expl_impl_clone_on_copy "you are implementing `Clone` explicitly on a `Copy` type" +log-0.4.11/src/lib.rs:448:12 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +log-0.4.11/src/lib.rs:500:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:506:28 clippy::trivially_copy_pass_by_ref "this argument (8 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +log-0.4.11/src/lib.rs:506:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:520:27 clippy::derive_hash_xor_eq "you are deriving `Hash` but have implemented `PartialEq` explicitly" +log-0.4.11/src/lib.rs:538:1 clippy::expl_impl_clone_on_copy "you are implementing `Clone` explicitly on a `Copy` type" +log-0.4.11/src/lib.rs:653:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:661:21 clippy::trivially_copy_pass_by_ref "this argument (8 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +log-0.4.11/src/lib.rs:661:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:677:44 clippy::match_same_arms "this `match` has identical arm bodies" +log-0.4.11/src/lib.rs:758:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:764:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:770:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:776:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:782:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:788:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:794:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:803:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:809:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:818:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:908:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:908:5 clippy::new_without_default "you should consider adding a `Default` implementation for `RecordBuilder<'a>`" +log-0.4.11/src/lib.rs:995:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/detection.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +proc-macro2-1.0.24/src/fallback.rs:108:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +proc-macro2-1.0.24/src/fallback.rs:269:20 clippy::unused_self "unused `self` argument" +proc-macro2-1.0.24/src/fallback.rs:430:24 clippy::trivially_copy_pass_by_ref "this argument (0 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +proc-macro2-1.0.24/src/fallback.rs:437:23 clippy::trivially_copy_pass_by_ref "this argument (0 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +proc-macro2-1.0.24/src/fallback.rs:437:23 clippy::unused_self "unused `self` argument" +proc-macro2-1.0.24/src/fallback.rs:471:17 clippy::trivially_copy_pass_by_ref "this argument (0 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +proc-macro2-1.0.24/src/fallback.rs:471:17 clippy::unused_self "unused `self` argument" +proc-macro2-1.0.24/src/fallback.rs:654:5 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +proc-macro2-1.0.24/src/fallback.rs:655:12 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +proc-macro2-1.0.24/src/fallback.rs:661:5 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +proc-macro2-1.0.24/src/fallback.rs:662:12 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +proc-macro2-1.0.24/src/fallback.rs:664:12 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +proc-macro2-1.0.24/src/fallback.rs:674:37 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +proc-macro2-1.0.24/src/fallback.rs:678:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +proc-macro2-1.0.24/src/fallback.rs:85:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +proc-macro2-1.0.24/src/fallback.rs:882:43 clippy::unused_self "unused `self` argument" +proc-macro2-1.0.24/src/lib.rs:1017:9 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:1081:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:1099:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:1117:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:1135:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:1141:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:1146:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:1151:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:1156:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:152:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:157:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:373:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:383:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:397:24 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +proc-macro2-1.0.24/src/lib.rs:397:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:403:23 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +proc-macro2-1.0.24/src/lib.rs:403:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:418:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:425:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:464:17 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +proc-macro2-1.0.24/src/lib.rs:500:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:626:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:633:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:641:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:652:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:662:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:672:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:734:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:743:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:752:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:757:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:788:19 clippy::doc_markdown "you should put `XID_Start` between ticks in the documentation" +proc-macro2-1.0.24/src/lib.rs:788:69 clippy::doc_markdown "you should put `XID_Continue` between ticks in the documentation" +proc-macro2-1.0.24/src/lib.rs:891:36 clippy::doc_markdown "you should put `syn::parse_str` between ticks in the documentation" +proc-macro2-1.0.24/src/lib.rs:894:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:911:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:996:9 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/parse.rs:552:5 clippy::while_let_on_iterator "this loop could be written as a `for` loop" +proc-macro2-1.0.24/src/parse.rs:584:21 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +proc-macro2-1.0.24/src/parse.rs:602:20 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +proc-macro2-1.0.24/src/parse.rs:696:29 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" +proc-macro2-1.0.24/src/parse.rs:702:34 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" +proc-macro2-1.0.24/src/parse.rs:708:34 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" +proc-macro2-1.0.24/src/parse.rs:793:5 clippy::vec_init_then_push "calls to `push` immediately after creation" +proc-macro2-1.0.24/src/parse.rs:803:15 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" +proc-macro2-1.0.24/src/parse.rs:808:15 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" +proc-macro2-1.0.24/src/wrapper.rs:415:24 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +proc-macro2-1.0.24/src/wrapper.rs:429:23 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +proc-macro2-1.0.24/src/wrapper.rs:492:17 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +quote-1.0.7/src/ext.rs:10:1 clippy::module_name_repetitions "item name ends with its containing module's name" +quote-1.0.7/src/ext.rs:7:5 clippy::doc_markdown "you should put `TokenStream` between ticks in the documentation" +quote-1.0.7/src/ident_fragment.rs:13:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +quote-1.0.7/src/ident_fragment.rs:51:31 clippy::manual_strip "stripping a prefix manually" +quote-1.0.7/src/runtime.rs:52:5 clippy::module_name_repetitions "item name ends with its containing module's name" +quote-1.0.7/src/runtime.rs:63:5 clippy::module_name_repetitions "item name ends with its containing module's name" +quote-1.0.7/src/runtime.rs:66:33 clippy::doc_markdown "you should put `DoesNotHaveIter` between ticks in the documentation" +quote-1.0.7/src/runtime.rs:80:5 clippy::module_name_repetitions "item name ends with its containing module's name" +rand-0.7.3/src/distributions/bernoulli.rs:103:20 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" +rand-0.7.3/src/distributions/bernoulli.rs:103:20 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" +rand-0.7.3/src/distributions/bernoulli.rs:116:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +rand-0.7.3/src/distributions/bernoulli.rs:123:21 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" +rand-0.7.3/src/distributions/bernoulli.rs:123:21 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" +rand-0.7.3/src/distributions/bernoulli.rs:63:26 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand-0.7.3/src/distributions/bernoulli.rs:63:27 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +rand-0.7.3/src/distributions/bernoulli.rs:67:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand-0.7.3/src/distributions/bernoulli.rs:95:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +rand-0.7.3/src/distributions/bernoulli.rs:96:13 clippy::manual_range_contains "manual `Range::contains` implementation" +rand-0.7.3/src/distributions/binomial.rs:107:23 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand-0.7.3/src/distributions/binomial.rs:112:44 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand-0.7.3/src/distributions/binomial.rs:116:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rand-0.7.3/src/distributions/binomial.rs:150:28 clippy::redundant_else "redundant else block" +rand-0.7.3/src/distributions/binomial.rs:153:24 clippy::if_not_else "unnecessary boolean `not` operation" +rand-0.7.3/src/distributions/binomial.rs:158:28 clippy::redundant_else "redundant else block" +rand-0.7.3/src/distributions/binomial.rs:164:33 clippy::cast_sign_loss "casting `i64` to `u64` may lose the sign of the value" +rand-0.7.3/src/distributions/binomial.rs:166:28 clippy::redundant_else "redundant else block" +rand-0.7.3/src/distributions/binomial.rs:175:47 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand-0.7.3/src/distributions/binomial.rs:185:38 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand-0.7.3/src/distributions/binomial.rs:194:38 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand-0.7.3/src/distributions/binomial.rs:202:28 clippy::redundant_else "redundant else block" +rand-0.7.3/src/distributions/binomial.rs:209:25 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand-0.7.3/src/distributions/binomial.rs:221:26 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand-0.7.3/src/distributions/binomial.rs:222:26 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand-0.7.3/src/distributions/binomial.rs:223:25 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand-0.7.3/src/distributions/binomial.rs:224:25 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand-0.7.3/src/distributions/binomial.rs:226:17 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rand-0.7.3/src/distributions/binomial.rs:233:32 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand-0.7.3/src/distributions/binomial.rs:234:27 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand-0.7.3/src/distributions/binomial.rs:251:22 clippy::cast_sign_loss "casting `i64` to `u64` may lose the sign of the value" +rand-0.7.3/src/distributions/binomial.rs:255:9 clippy::if_not_else "unnecessary `!=` operation" +rand-0.7.3/src/distributions/binomial.rs:35:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/distributions/binomial.rs:45:17 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand-0.7.3/src/distributions/binomial.rs:46:5 clippy::cast_possible_truncation "casting `f64` to `i64` may truncate the value" +rand-0.7.3/src/distributions/binomial.rs:50:5 clippy::too_many_lines "this function has too many lines (143/100)" +rand-0.7.3/src/distributions/binomial.rs:76:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rand-0.7.3/src/distributions/binomial.rs:78:12 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand-0.7.3/src/distributions/binomial.rs:81:21 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand-0.7.3/src/distributions/binomial.rs:82:32 clippy::cast_possible_truncation "casting `u64` to `i32` may truncate the value" +rand-0.7.3/src/distributions/binomial.rs:88:26 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand-0.7.3/src/distributions/binomial.rs:99:21 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand-0.7.3/src/distributions/cauchy.rs:33:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/distributions/dirichlet.rs:52:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/distributions/dirichlet.rs:64:32 clippy::unseparated_literal_suffix "float type suffix should be separated by an underscore" +rand-0.7.3/src/distributions/dirichlet.rs:65:23 clippy::unseparated_literal_suffix "float type suffix should be separated by an underscore" +rand-0.7.3/src/distributions/exponential.rs:76:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/distributions/float.rs:73:1 clippy::module_name_repetitions "item name ends with its containing module's name" +rand-0.7.3/src/distributions/gamma.rs:13:5 clippy::enum_glob_use "usage of wildcard import for enum variants" +rand-0.7.3/src/distributions/gamma.rs:14:5 clippy::enum_glob_use "usage of wildcard import for enum variants" +rand-0.7.3/src/distributions/gamma.rs:189:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/distributions/gamma.rs:230:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/distributions/gamma.rs:259:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/distributions/gamma.rs:287:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/distributions/gamma.rs:90:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/distributions/integer.rs:23:9 clippy::cast_possible_truncation "casting `u32` to `u8` may truncate the value" +rand-0.7.3/src/distributions/integer.rs:30:9 clippy::cast_possible_truncation "casting `u32` to `u16` may truncate the value" +rand-0.7.3/src/distributions/integer.rs:69:9 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +rand-0.7.3/src/distributions/mod.rs:263:5 clippy::inline_always "you have declared `#[inline(always)]` on `next`. This is usually a bad idea" +rand-0.7.3/src/distributions/normal.rs:100:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/distributions/normal.rs:119:1 clippy::module_name_repetitions "item name ends with its containing module's name" +rand-0.7.3/src/distributions/normal.rs:131:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/distributions/normal.rs:31:1 clippy::module_name_repetitions "item name ends with its containing module's name" +rand-0.7.3/src/distributions/normal.rs:47:25 clippy::unseparated_literal_suffix "float type suffix should be separated by an underscore" +rand-0.7.3/src/distributions/normal.rs:48:25 clippy::unseparated_literal_suffix "float type suffix should be separated by an underscore" +rand-0.7.3/src/distributions/other.rs:89:9 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +rand-0.7.3/src/distributions/pareto.rs:32:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/distributions/poisson.rs:35:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/distributions/poisson.rs:87:30 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" +rand-0.7.3/src/distributions/poisson.rs:87:30 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" +rand-0.7.3/src/distributions/triangular.rs:32:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/distributions/uniform.rs:146:4 clippy::needless_doctest_main "needless `fn main` in doctest" +rand-0.7.3/src/distributions/uniform.rs:199:1 clippy::module_name_repetitions "item name ends with its containing module's name" +rand-0.7.3/src/distributions/uniform.rs:214:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand-0.7.3/src/distributions/uniform.rs:283:14 clippy::doc_markdown "you should put `SampleUniform` between ticks in the documentation" +rand-0.7.3/src/distributions/uniform.rs:283:46 clippy::doc_markdown "you should put `SampleUniform` between ticks in the documentation" +rand-0.7.3/src/distributions/uniform.rs:296:5 clippy::inline_always "you have declared `#[inline(always)]` on `borrow`. This is usually a bad idea" +rand-0.7.3/src/distributions/uniform.rs:304:5 clippy::inline_always "you have declared `#[inline(always)]` on `borrow`. This is usually a bad idea" +rand-0.7.3/src/distributions/uniform.rs:350:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand-0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" +rand-0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" +rand-0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" +rand-0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" +rand-0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" +rand-0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" +rand-0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" +rand-0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" +rand-0.7.3/src/distributions/uniform.rs:56:10 clippy::doc_markdown "you should put `SampleBorrow` between ticks in the documentation" +rand-0.7.3/src/distributions/uniform.rs:647:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand-0.7.3/src/distributions/uniform.rs:840:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand-0.7.3/src/distributions/uniform.rs:913:13 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" +rand-0.7.3/src/distributions/uniform.rs:943:54 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +rand-0.7.3/src/distributions/unit_circle.rs:30:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/distributions/unit_sphere.rs:24:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand-0.7.3/src/distributions/unit_sphere.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/distributions/utils.rs:218:18 clippy::upper_case_acronyms "name `FloatSIMDUtils` contains a capitalized acronym" +rand-0.7.3/src/distributions/utils.rs:247:15 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" +rand-0.7.3/src/distributions/utils.rs:248:20 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" +rand-0.7.3/src/distributions/utils.rs:249:18 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" +rand-0.7.3/src/distributions/utils.rs:253:18 clippy::upper_case_acronyms "name `FloatAsSIMD` contains a capitalized acronym" +rand-0.7.3/src/distributions/utils.rs:254:5 clippy::inline_always "you have declared `#[inline(always)]` on `lanes`. This is usually a bad idea" +rand-0.7.3/src/distributions/utils.rs:258:5 clippy::inline_always "you have declared `#[inline(always)]` on `splat`. This is usually a bad idea" +rand-0.7.3/src/distributions/utils.rs:262:5 clippy::inline_always "you have declared `#[inline(always)]` on `extract`. This is usually a bad idea" +rand-0.7.3/src/distributions/utils.rs:267:5 clippy::inline_always "you have declared `#[inline(always)]` on `replace`. This is usually a bad idea" +rand-0.7.3/src/distributions/utils.rs:274:18 clippy::upper_case_acronyms "name `BoolAsSIMD` contains a capitalized acronym" +rand-0.7.3/src/distributions/utils.rs:281:5 clippy::inline_always "you have declared `#[inline(always)]` on `any`. This is usually a bad idea" +rand-0.7.3/src/distributions/utils.rs:286:5 clippy::inline_always "you have declared `#[inline(always)]` on `all`. This is usually a bad idea" +rand-0.7.3/src/distributions/utils.rs:291:5 clippy::inline_always "you have declared `#[inline(always)]` on `none`. This is usually a bad idea" +rand-0.7.3/src/distributions/utils.rs:488:17 clippy::doc_markdown "you should put `x_i` between ticks in the documentation" +rand-0.7.3/src/distributions/utils.rs:489:50 clippy::doc_markdown "you should put `x_i` between ticks in the documentation" +rand-0.7.3/src/distributions/utils.rs:489:63 clippy::doc_markdown "you should put `f(x_i` between ticks in the documentation" +rand-0.7.3/src/distributions/utils.rs:490:40 clippy::doc_markdown "you should put `f(x_i` between ticks in the documentation" +rand-0.7.3/src/distributions/utils.rs:490:49 clippy::doc_markdown "you should put `f(x_{i+1` between ticks in the documentation" +rand-0.7.3/src/distributions/utils.rs:518:17 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +rand-0.7.3/src/distributions/weibull.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/distributions/weighted/alias_method.rs:113:21 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" +rand-0.7.3/src/distributions/weighted/alias_method.rs:125:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rand-0.7.3/src/distributions/weighted/alias_method.rs:131:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rand-0.7.3/src/distributions/weighted/alias_method.rs:180:36 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +rand-0.7.3/src/distributions/weighted/alias_method.rs:182:34 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +rand-0.7.3/src/distributions/weighted/alias_method.rs:259:28 clippy::clone_on_copy "using `clone` on type `distributions::uniform::Uniform` which implements the `Copy` trait" +rand-0.7.3/src/distributions/weighted/alias_method.rs:296:9 clippy::map_clone "you are using an explicit closure for copying elements" +rand-0.7.3/src/distributions/weighted/alias_method.rs:321:9 clippy::map_clone "you are using an explicit closure for copying elements" +rand-0.7.3/src/distributions/weighted/alias_method.rs:78:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +rand-0.7.3/src/distributions/weighted/alias_method.rs:78:5 clippy::too_many_lines "this function has too many lines (106/100)" +rand-0.7.3/src/distributions/weighted/alias_method.rs:85:17 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +rand-0.7.3/src/distributions/weighted/alias_method.rs:87:31 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +rand-0.7.3/src/distributions/weighted/mod.rs:100:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +rand-0.7.3/src/distributions/weighted/mod.rs:144:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +rand-0.7.3/src/distributions/weighted/mod.rs:169:16 clippy::int_plus_one "unnecessary `>= y + 1` or `x - 1 >=`" +rand-0.7.3/src/distributions/weighted/mod.rs:386:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand-0.7.3/src/distributions/weighted/mod.rs:85:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand-0.7.3/src/lib.rs:333:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +rand-0.7.3/src/lib.rs:404:14 clippy::wrong_self_convention "methods called `to_*` usually take self by reference; consider choosing a less ambiguous name" +rand-0.7.3/src/lib.rs:552:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +rand-0.7.3/src/rngs/adapter/read.rs:47:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand-0.7.3/src/rngs/adapter/read.rs:89:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand-0.7.3/src/rngs/adapter/reseeding.rs:100:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +rand-0.7.3/src/rngs/adapter/reseeding.rs:112:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea" +rand-0.7.3/src/rngs/adapter/reseeding.rs:117:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea" +rand-0.7.3/src/rngs/adapter/reseeding.rs:198:13 clippy::cast_possible_wrap "casting `u64` to `i64` may wrap around the value" +rand-0.7.3/src/rngs/adapter/reseeding.rs:231:9 clippy::cast_possible_wrap "casting `usize` to `isize` may wrap around the value" +rand-0.7.3/src/rngs/adapter/reseeding.rs:27:28 clippy::doc_markdown "you should put `ChaCha` between ticks in the documentation" +rand-0.7.3/src/rngs/adapter/reseeding.rs:79:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand-0.7.3/src/rngs/entropy.rs:24:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand-0.7.3/src/rngs/entropy.rs:34:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/rngs/mock.rs:36:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/rngs/mock.rs:47:9 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +rand-0.7.3/src/rngs/mod.rs:61:74 clippy::doc_markdown "you should put `ChaCha20` between ticks in the documentation" +rand-0.7.3/src/rngs/std.rs:25:39 clippy::doc_markdown "you should put `ChaCha` between ticks in the documentation" +rand-0.7.3/src/rngs/std.rs:32:10 clippy::doc_markdown "you should put `rand_chacha` between ticks in the documentation" +rand-0.7.3/src/rngs/std.rs:36:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand-0.7.3/src/rngs/std.rs:39:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea" +rand-0.7.3/src/rngs/std.rs:44:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea" +rand-0.7.3/src/rngs/std.rs:49:5 clippy::inline_always "you have declared `#[inline(always)]` on `fill_bytes`. This is usually a bad idea" +rand-0.7.3/src/rngs/std.rs:54:5 clippy::inline_always "you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea" +rand-0.7.3/src/rngs/std.rs:63:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_seed`. This is usually a bad idea" +rand-0.7.3/src/rngs/std.rs:68:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_rng`. This is usually a bad idea" +rand-0.7.3/src/rngs/thread.rs:57:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand-0.7.3/src/rngs/thread.rs:80:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand-0.7.3/src/rngs/thread.rs:80:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +rand-0.7.3/src/rngs/thread.rs:81:35 clippy::redundant_closure_for_method_calls "redundant closure found" +rand-0.7.3/src/rngs/thread.rs:93:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea" +rand-0.7.3/src/rngs/thread.rs:98:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea" +rand-0.7.3/src/seq/index.rs:127:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand-0.7.3/src/seq/index.rs:139:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +rand-0.7.3/src/seq/index.rs:159:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand-0.7.3/src/seq/index.rs:171:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +rand-0.7.3/src/seq/index.rs:180:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +rand-0.7.3/src/seq/index.rs:223:18 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +rand-0.7.3/src/seq/index.rs:224:18 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +rand-0.7.3/src/seq/index.rs:233:25 clippy::cast_precision_loss "casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide)" +rand-0.7.3/src/seq/index.rs:236:27 clippy::cast_precision_loss "casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide)" +rand-0.7.3/src/seq/index.rs:244:12 clippy::cast_precision_loss "casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide)" +rand-0.7.3/src/seq/index.rs:244:37 clippy::cast_precision_loss "casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide)" +rand-0.7.3/src/seq/index.rs:29:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand-0.7.3/src/seq/index.rs:39:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/seq/index.rs:48:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/seq/index.rs:60:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/seq/index.rs:69:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/seq/index.rs:78:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/seq/index.rs:87:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/seq/index.rs:87:5 clippy::should_implement_trait "method `into_iter` can be confused for the standard trait method `std::iter::IntoIterator::into_iter`" +rand-0.7.3/src/seq/index.rs:97:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +rand-0.7.3/src/seq/mod.rs:141:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +rand-0.7.3/src/seq/mod.rs:168:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +rand-0.7.3/src/seq/mod.rs:229:4 clippy::needless_doctest_main "needless `fn main` in doctest" +rand-0.7.3/src/seq/mod.rs:292:29 clippy::cast_precision_loss "casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand-0.7.3/src/seq/mod.rs:410:23 clippy::default_trait_access "calling `std::marker::PhantomData::default()` is more clear than this expression" +rand-0.7.3/src/seq/mod.rs:45:4 clippy::needless_doctest_main "needless `fn main` in doctest" +rand-0.7.3/src/seq/mod.rs:527:26 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +rand_core-0.6.0/src/block.rs:117:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand_core-0.6.0/src/block.rs:153:5 clippy::inline_always "you have declared `#[inline(always)]` on `index`. This is usually a bad idea" +rand_core-0.6.0/src/block.rs:230:5 clippy::inline_always "you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea" +rand_core-0.6.0/src/block.rs:240:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_seed`. This is usually a bad idea" +rand_core-0.6.0/src/block.rs:245:5 clippy::inline_always "you have declared `#[inline(always)]` on `seed_from_u64`. This is usually a bad idea" +rand_core-0.6.0/src/block.rs:250:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_rng`. This is usually a bad idea" +rand_core-0.6.0/src/block.rs:280:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand_core-0.6.0/src/block.rs:319:5 clippy::inline_always "you have declared `#[inline(always)]` on `index`. This is usually a bad idea" +rand_core-0.6.0/src/block.rs:405:5 clippy::inline_always "you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea" +rand_core-0.6.0/src/block.rs:415:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_seed`. This is usually a bad idea" +rand_core-0.6.0/src/block.rs:420:5 clippy::inline_always "you have declared `#[inline(always)]` on `seed_from_u64`. This is usually a bad idea" +rand_core-0.6.0/src/block.rs:425:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_rng`. This is usually a bad idea" +rand_core-0.6.0/src/block.rs:67:14 clippy::doc_markdown "you should put `module][crate::block` between ticks in the documentation" +rand_core-0.6.0/src/block.rs:68:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand_core-0.6.0/src/error.rs:106:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand_core-0.6.0/src/error.rs:87:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand_core-0.6.0/src/error.rs:95:74 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +rand_core-0.6.0/src/lib.rs:179:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +rand_core-0.6.0/src/lib.rs:301:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand_core-0.6.0/src/lib.rs:303:26 clippy::unreadable_literal "long literal lacking separators" +rand_core-0.6.0/src/lib.rs:304:26 clippy::unreadable_literal "long literal lacking separators" +rand_core-0.6.0/src/lib.rs:313:30 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +rand_core-0.6.0/src/lib.rs:314:23 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +rand_core-0.6.0/src/lib.rs:346:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +rand_core-0.6.0/src/lib.rs:381:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea" +rand_core-0.6.0/src/lib.rs:386:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea" +rand_core-0.6.0/src/lib.rs:391:5 clippy::inline_always "you have declared `#[inline(always)]` on `fill_bytes`. This is usually a bad idea" +rand_core-0.6.0/src/lib.rs:396:5 clippy::inline_always "you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea" +rayon-1.5.0/src/collections/binary_heap.rs:7:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/collections/binary_heap.rs:8:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/collections/btree_map.rs:7:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/collections/btree_map.rs:8:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/collections/btree_set.rs:7:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/collections/btree_set.rs:8:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/collections/hash_map.rs:10:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/collections/hash_map.rs:9:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/collections/hash_set.rs:10:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/collections/hash_set.rs:9:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/collections/linked_list.rs:7:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/collections/linked_list.rs:8:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/collections/mod.rs:59:32 clippy::mem_replace_with_default "replacing a value of type `T` with `T::default()` is better expressed using `std::mem::take`" +rayon-1.5.0/src/collections/vec_deque.rs:8:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/collections/vec_deque.rs:9:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/compile_fail/cannot_collect_filtermap_data.rs:2:1 clippy::needless_doctest_main "needless `fn main` in doctest" +rayon-1.5.0/src/compile_fail/cannot_zip_filtered_data.rs:2:1 clippy::needless_doctest_main "needless `fn main` in doctest" +rayon-1.5.0/src/compile_fail/cell_par_iter.rs:2:1 clippy::needless_doctest_main "needless `fn main` in doctest" +rayon-1.5.0/src/compile_fail/no_send_par_iter.rs:25:1 clippy::needless_doctest_main "needless `fn main` in doctest" +rayon-1.5.0/src/compile_fail/no_send_par_iter.rs:46:1 clippy::needless_doctest_main "needless `fn main` in doctest" +rayon-1.5.0/src/compile_fail/no_send_par_iter.rs:4:1 clippy::needless_doctest_main "needless `fn main` in doctest" +rayon-1.5.0/src/compile_fail/rc_par_iter.rs:2:1 clippy::needless_doctest_main "needless `fn main` in doctest" +rayon-1.5.0/src/iter/chain.rs:103:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/chain.rs:122:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/chain.rs:128:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/chain.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/chain.rs:221:36 clippy::doc_markdown "you should put `ExactSizeIterator` between ticks in the documentation" +rayon-1.5.0/src/iter/chain.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/chain.rs:51:38 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" +rayon-1.5.0/src/iter/chain.rs:58:14 clippy::shadow_unrelated "`a` is being shadowed" +rayon-1.5.0/src/iter/chain.rs:58:17 clippy::shadow_unrelated "`b` is being shadowed" +rayon-1.5.0/src/iter/chain.rs:78:14 clippy::shadow_unrelated "`a` is being shadowed" +rayon-1.5.0/src/iter/chain.rs:78:17 clippy::shadow_unrelated "`b` is being shadowed" +rayon-1.5.0/src/iter/chain.rs:97:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/chunks.rs:3:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/chunks.rs:4:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/chunks.rs:77:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/chunks.rs:83:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/cloned.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/cloned.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/cloned.rs:71:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/cloned.rs:75:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/collect/consumer.rs:141:5 clippy::doc_markdown "you should put `CollectReducer` between ticks in the documentation" +rayon-1.5.0/src/iter/collect/consumer.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/collect/consumer.rs:28:5 clippy::doc_markdown "you should put `CollectResult` between ticks in the documentation" +rayon-1.5.0/src/iter/collect/consumer.rs:36:37 clippy::mut_mut "generally you want to avoid `&mut &mut _` if possible" +rayon-1.5.0/src/iter/collect/consumer.rs:36:37 clippy::mut_mut "generally you want to avoid `&mut &mut _` if possible" +rayon-1.5.0/src/iter/collect/mod.rs:154:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +rayon-1.5.0/src/iter/copied.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/copied.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/copied.rs:71:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/copied.rs:75:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/empty.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/empty.rs:24:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +rayon-1.5.0/src/iter/empty.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/enumerate.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/enumerate.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/enumerate.rs:64:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/enumerate.rs:68:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/extend.rs:143:63 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon-1.5.0/src/iter/extend.rs:182:57 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon-1.5.0/src/iter/extend.rs:218:32 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon-1.5.0/src/iter/extend.rs:218:59 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon-1.5.0/src/iter/extend.rs:25:42 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon-1.5.0/src/iter/extend.rs:287:62 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon-1.5.0/src/iter/extend.rs:322:56 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon-1.5.0/src/iter/extend.rs:41:27 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon-1.5.0/src/iter/extend.rs:47:30 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon-1.5.0/src/iter/extend.rs:47:56 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon-1.5.0/src/iter/extend.rs:47:74 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon-1.5.0/src/iter/extend.rs:53:29 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon-1.5.0/src/iter/extend.rs:57:36 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon-1.5.0/src/iter/extend.rs:59:61 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon-1.5.0/src/iter/filter.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/filter.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/filter_map.rs:123:9 clippy::option_if_let_else "use Option::map_or instead of an if let/else" +rayon-1.5.0/src/iter/filter_map.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/filter_map.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/find.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/find.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/find_first_last/mod.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/find_first_last/mod.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/find_first_last/mod.rs:32:67 clippy::doc_markdown "you should put `MatchPosition` between ticks in the documentation" +rayon-1.5.0/src/iter/flat_map.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/flat_map.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/flat_map_iter.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/flat_map_iter.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/flatten.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/flatten.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/flatten_iter.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/flatten_iter.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/fold.rs:158:13 clippy::similar_names "binding's name is too similar to existing binding" +rayon-1.5.0/src/iter/fold.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/fold.rs:204:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rayon-1.5.0/src/iter/fold.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/for_each.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/for_each.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/inspect.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/inspect.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/inspect.rs:83:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/inspect.rs:88:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/interleave.rs:111:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/interleave.rs:119:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/interleave.rs:195:30 clippy::doc_markdown "you should put `self.i_len` between ticks in the documentation" +rayon-1.5.0/src/iter/interleave.rs:195:43 clippy::doc_markdown "you should put `self.j_len` between ticks in the documentation" +rayon-1.5.0/src/iter/interleave.rs:199:23 clippy::doc_markdown "you should put `self.i_len` between ticks in the documentation" +rayon-1.5.0/src/iter/interleave.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/interleave.rs:200:23 clippy::doc_markdown "you should put `self.j_len` between ticks in the documentation" +rayon-1.5.0/src/iter/interleave.rs:249:41 clippy::doc_markdown "you should put `DoubleEndedIterator` between ticks in the documentation" +rayon-1.5.0/src/iter/interleave.rs:250:5 clippy::doc_markdown "you should put `ExactSizeIterator` between ticks in the documentation" +rayon-1.5.0/src/iter/interleave.rs:263:33 clippy::doc_markdown "you should put `InterleaveSeq` between ticks in the documentation" +rayon-1.5.0/src/iter/interleave.rs:280:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +rayon-1.5.0/src/iter/interleave.rs:285:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +rayon-1.5.0/src/iter/interleave.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/interleave.rs:313:9 clippy::comparison_chain "`if` chain can be rewritten with `match`" +rayon-1.5.0/src/iter/interleave.rs:82:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/interleave.rs:90:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/interleave_shortest.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/intersperse.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/intersperse.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/intersperse.rs:90:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/intersperse.rs:96:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/len.rs:12:1 clippy::module_name_repetitions "item name ends with its containing module's name" +rayon-1.5.0/src/iter/len.rs:146:1 clippy::module_name_repetitions "item name ends with its containing module's name" +rayon-1.5.0/src/iter/len.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/len.rs:200:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/len.rs:205:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/len.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/len.rs:66:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/len.rs:71:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/map.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/map.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/map.rs:84:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/map.rs:89:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/map_with.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/map_with.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/map_with.rs:419:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/map_with.rs:425:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/map_with.rs:90:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/map_with.rs:96:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/mod.rs:1874:24 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +rayon-1.5.0/src/iter/mod.rs:2171:1 clippy::len_without_is_empty "trait `IndexedParallelIterator` has a `len` method but no (possibly inherited) `is_empty` method" +rayon-1.5.0/src/iter/mod.rs:2371:26 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +rayon-1.5.0/src/iter/mod.rs:2411:26 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +rayon-1.5.0/src/iter/mod.rs:82:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/multizip.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/multizip.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/noop.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/once.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/once.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/panic_fuse.rs:102:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/panic_fuse.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/panic_fuse.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/panic_fuse.rs:98:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/par_bridge.rs:136:28 clippy::redundant_else "redundant else block" +rayon-1.5.0/src/iter/par_bridge.rs:163:28 clippy::redundant_else "redundant else block" +rayon-1.5.0/src/iter/plumbing/mod.rs:216:58 clippy::doc_markdown "you should put `find_first` between ticks in the documentation" +rayon-1.5.0/src/iter/plumbing/mod.rs:359:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/plumbing/mod.rs:364:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/plumbing/mod.rs:399:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/plumbing/mod.rs:53:19 clippy::doc_markdown "you should put `DoubleEndedIterator` between ticks in the documentation" +rayon-1.5.0/src/iter/plumbing/mod.rs:53:43 clippy::doc_markdown "you should put `ExactSizeIterator` between ticks in the documentation" +rayon-1.5.0/src/iter/plumbing/mod.rs:54:31 clippy::doc_markdown "you should put `IntoIterator` between ticks in the documentation" +rayon-1.5.0/src/iter/plumbing/mod.rs:55:5 clippy::doc_markdown "you should put `IntoIterator` between ticks in the documentation" +rayon-1.5.0/src/iter/positions.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/positions.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/product.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/reduce.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/repeat.rs:103:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rayon-1.5.0/src/iter/repeat.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/repeat.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/rev.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/rev.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/rev.rs:63:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/rev.rs:68:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/skip.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/skip.rs:3:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/skip.rs:68:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/skip.rs:73:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/splitter.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/splitter.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/step_by.rs:4:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/step_by.rs:5:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/step_by.rs:73:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/step_by.rs:79:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/sum.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/take.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/take.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/take.rs:67:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/take.rs:72:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/try_fold.rs:190:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rayon-1.5.0/src/iter/try_fold.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/try_fold.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/try_reduce.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/try_reduce_with.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/unzip.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/unzip.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/update.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/update.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/update.rs:82:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/update.rs:87:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/while_some.rs:130:22 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +rayon-1.5.0/src/iter/while_some.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/while_some.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/zip.rs:102:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/zip.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/zip.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/zip.rs:74:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/zip.rs:79:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/zip.rs:97:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/zip_eq.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/zip_eq.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/option.rs:8:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/option.rs:9:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/par_either.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/par_either.rs:3:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/private.rs:9:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rayon-1.5.0/src/range.rs:19:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/range.rs:20:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/range_inclusive.rs:194:9 clippy::range_plus_one "an inclusive range would be more readable" +rayon-1.5.0/src/range_inclusive.rs:194:9 clippy::range_plus_one "an inclusive range would be more readable" +rayon-1.5.0/src/range_inclusive.rs:19:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/range_inclusive.rs:209:9 clippy::range_plus_one "an inclusive range would be more readable" +rayon-1.5.0/src/range_inclusive.rs:209:9 clippy::range_plus_one "an inclusive range would be more readable" +rayon-1.5.0/src/range_inclusive.rs:20:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/range_inclusive.rs:231:9 clippy::range_plus_one "an inclusive range would be more readable" +rayon-1.5.0/src/range_inclusive.rs:231:9 clippy::range_plus_one "an inclusive range would be more readable" +rayon-1.5.0/src/result.rs:8:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/result.rs:9:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/slice/mergesort.rs:102:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/slice/mergesort.rs:109:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/slice/mergesort.rs:114:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/slice/mergesort.rs:211:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/slice/mergesort.rs:217:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/slice/mergesort.rs:251:5 clippy::doc_markdown "you should put `TimSort` between ticks in the documentation" +rayon-1.5.0/src/slice/mergesort.rs:252:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +rayon-1.5.0/src/slice/mergesort.rs:286:59 clippy::doc_markdown "you should put `TimSort` between ticks in the documentation" +rayon-1.5.0/src/slice/mergesort.rs:333:24 clippy::redundant_else "redundant else block" +rayon-1.5.0/src/slice/mergesort.rs:513:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/slice/mergesort.rs:521:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/slice/mergesort.rs:7:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/slice/mergesort.rs:98:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/slice/mod.rs:15:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/slice/mod.rs:16:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/slice/mod.rs:17:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/slice/mod.rs:25:1 clippy::module_name_repetitions "item name ends with its containing module's name" +rayon-1.5.0/src/slice/mod.rs:657:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rayon-1.5.0/src/slice/mod.rs:971:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rayon-1.5.0/src/slice/quicksort.rs:230:36 clippy::doc_markdown "you should put `BlockQuicksort` between ticks in the documentation" +rayon-1.5.0/src/slice/quicksort.rs:233:1 clippy::too_many_lines "this function has too many lines (117/100)" +rayon-1.5.0/src/slice/quicksort.rs:258:26 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +rayon-1.5.0/src/slice/quicksort.rs:265:26 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +rayon-1.5.0/src/slice/quicksort.rs:268:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/slice/quicksort.rs:308:30 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" +rayon-1.5.0/src/slice/quicksort.rs:325:30 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" +rayon-1.5.0/src/slice/quicksort.rs:393:36 clippy::cast_possible_wrap "casting `u8` to `isize` may wrap around the value on targets with 32-bit wide pointers" +rayon-1.5.0/src/slice/quicksort.rs:405:40 clippy::cast_possible_wrap "casting `u8` to `isize` may wrap around the value on targets with 32-bit wide pointers" +rayon-1.5.0/src/slice/quicksort.rs:430:14 clippy::shadow_unrelated "`pivot` is being shadowed" +rayon-1.5.0/src/slice/quicksort.rs:439:13 clippy::shadow_unrelated "`pivot` is being shadowed" +rayon-1.5.0/src/slice/quicksort.rs:482:10 clippy::shadow_unrelated "`pivot` is being shadowed" +rayon-1.5.0/src/slice/quicksort.rs:491:9 clippy::shadow_unrelated "`pivot` is being shadowed" +rayon-1.5.0/src/slice/quicksort.rs:534:26 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +rayon-1.5.0/src/slice/quicksort.rs:545:17 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +rayon-1.5.0/src/slice/quicksort.rs:588:17 clippy::identity_op "the operation is ineffective. Consider reducing it to `len / 4`" +rayon-1.5.0/src/slice/quicksort.rs:716:14 clippy::shadow_unrelated "`pivot` is being shadowed" +rayon-1.5.0/src/split_producer.rs:56:16 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" +rayon-1.5.0/src/split_producer.rs:92:9 clippy::option_if_let_else "use Option::map_or instead of an if let/else" +rayon-1.5.0/src/str.rs:16:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/str.rs:17:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/str.rs:18:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/str.rs:25:5 clippy::cast_possible_wrap "casting `u8` to `i8` may wrap around the value" +rayon-1.5.0/src/str.rs:715:9 clippy::manual_strip "stripping a suffix manually" +rayon-1.5.0/src/string.rs:5:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/vec.rs:137:12 clippy::len_zero "length comparison to zero" +rayon-1.5.0/src/vec.rs:8:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/vec.rs:9:5 clippy::wildcard_imports "usage of wildcard import" +regex-1.3.2/src/backtrack.rs:100:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/backtrack.rs:133:17 clippy::same_item_push "it looks like the same item is being pushed into this Vec" +regex-1.3.2/src/backtrack.rs:145:20 clippy::if_not_else "unnecessary boolean `not` operation" +regex-1.3.2/src/backtrack.rs:199:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/backtrack.rs:223:29 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/backtrack.rs:230:66 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/backtrack.rs:284:21 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" +regex-1.3.2/src/backtrack.rs:287:5 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex-1.3.2/src/backtrack.rs:97:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/backtrack.rs:98:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/backtrack.rs:99:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:1005:32 clippy::unreadable_literal "long literal lacking separators" +regex-1.3.2/src/compile.rs:1006:21 clippy::unreadable_literal "long literal lacking separators" +regex-1.3.2/src/compile.rs:1008:18 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" +regex-1.3.2/src/compile.rs:1009:18 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" +regex-1.3.2/src/compile.rs:1010:9 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +regex-1.3.2/src/compile.rs:102:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/compile.rs:1037:37 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" +regex-1.3.2/src/compile.rs:1037:55 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" +regex-1.3.2/src/compile.rs:1040:28 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" +regex-1.3.2/src/compile.rs:1040:38 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" +regex-1.3.2/src/compile.rs:1051:25 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +regex-1.3.2/src/compile.rs:1071:8 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" +regex-1.3.2/src/compile.rs:112:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +regex-1.3.2/src/compile.rs:154:30 clippy::redundant_closure_for_method_calls "redundant closure found" +regex-1.3.2/src/compile.rs:156:30 clippy::redundant_closure_for_method_calls "redundant closure found" +regex-1.3.2/src/compile.rs:185:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +regex-1.3.2/src/compile.rs:187:40 clippy::redundant_closure_for_method_calls "redundant closure found" +regex-1.3.2/src/compile.rs:201:53 clippy::doc_markdown "you should put `MaybeInsts` between ticks in the documentation" +regex-1.3.2/src/compile.rs:241:63 clippy::doc_markdown "you should put `c_concat` between ticks in the documentation" +regex-1.3.2/src/compile.rs:245:5 clippy::too_many_lines "this function has too many lines (111/100)" +regex-1.3.2/src/compile.rs:247:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/compile.rs:373:24 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:373:36 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:378:12 clippy::if_not_else "unnecessary boolean `not` operation" +regex-1.3.2/src/compile.rs:400:37 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:407:51 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:409:24 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:417:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +regex-1.3.2/src/compile.rs:42:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/compile.rs:42:5 clippy::new_without_default "you should consider adding a `Default` implementation for `compile::Compiler`" +regex-1.3.2/src/compile.rs:444:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +regex-1.3.2/src/compile.rs:445:57 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:446:20 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:466:20 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:466:32 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:519:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/compile.rs:55:57 clippy::doc_markdown "you should put `size_limit` between ticks in the documentation" +regex-1.3.2/src/compile.rs:58:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/compile.rs:748:41 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:74:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/compile.rs:751:54 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:765:41 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:765:55 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:825:39 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:825:51 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:828:49 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:828:61 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:830:59 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:830:71 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:832:43 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:835:41 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:835:53 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:835:67 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:83:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/compile.rs:896:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +regex-1.3.2/src/compile.rs:905:17 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:953:17 clippy::doc_markdown "you should put `HashMap` between ticks in the documentation" +regex-1.3.2/src/compile.rs:95:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/compile.rs:980:26 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +regex-1.3.2/src/compile.rs:994:44 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:994:54 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/dfa.rs:1007:17 clippy::similar_names "binding's name is too similar to existing binding" +regex-1.3.2/src/dfa.rs:1010:22 clippy::similar_names "binding's name is too similar to existing binding" +regex-1.3.2/src/dfa.rs:1059:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/dfa.rs:1060:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/dfa.rs:1084:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex-1.3.2/src/dfa.rs:1087:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex-1.3.2/src/dfa.rs:1090:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex-1.3.2/src/dfa.rs:1093:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex-1.3.2/src/dfa.rs:1096:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex-1.3.2/src/dfa.rs:1101:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex-1.3.2/src/dfa.rs:1104:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex-1.3.2/src/dfa.rs:1107:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex-1.3.2/src/dfa.rs:1117:30 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex-1.3.2/src/dfa.rs:1120:47 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex-1.3.2/src/dfa.rs:1121:30 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex-1.3.2/src/dfa.rs:1129:13 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" +regex-1.3.2/src/dfa.rs:1134:13 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" +regex-1.3.2/src/dfa.rs:1185:68 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" +regex-1.3.2/src/dfa.rs:1193:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/dfa.rs:1244:50 clippy::doc_markdown "you should put `current_state` between ticks in the documentation" +regex-1.3.2/src/dfa.rs:1338:58 clippy::doc_markdown "you should put `STATE_DEAD` between ticks in the documentation" +regex-1.3.2/src/dfa.rs:1339:9 clippy::doc_markdown "you should put `STATE_UNKNOWN` between ticks in the documentation" +regex-1.3.2/src/dfa.rs:1366:25 clippy::doc_markdown "you should put `STATE_DEAD` between ticks in the documentation" +regex-1.3.2/src/dfa.rs:1366:46 clippy::doc_markdown "you should put `STATE_UNKNOWN` between ticks in the documentation" +regex-1.3.2/src/dfa.rs:1367:41 clippy::inline_always "you have declared `#[inline(always)]` on `start_state`. This is usually a bad idea" +regex-1.3.2/src/dfa.rs:1380:14 clippy::identity_op "the operation is ineffective. Consider reducing it to `(empty_flags.start as u8)`" +regex-1.3.2/src/dfa.rs:1388:15 clippy::match_on_vec_items "indexing into a vector may panic" +regex-1.3.2/src/dfa.rs:1412:20 clippy::unused_self "unused `self` argument" +regex-1.3.2/src/dfa.rs:1438:9 clippy::unused_self "unused `self` argument" +regex-1.3.2/src/dfa.rs:1472:9 clippy::doc_markdown "you should put `StatePtr` between ticks in the documentation" +regex-1.3.2/src/dfa.rs:1490:54 clippy::cast_possible_truncation "casting `i32` to `u8` may truncate the value" +regex-1.3.2/src/dfa.rs:1490:54 clippy::cast_sign_loss "casting `i32` to `u8` may lose the sign of the value" +regex-1.3.2/src/dfa.rs:1521:20 clippy::doc_markdown "you should put `num_byte_classes` between ticks in the documentation" +regex-1.3.2/src/dfa.rs:1529:41 clippy::inline_always "you have declared `#[inline(always)]` on `byte_class`. This is usually a bad idea" +regex-1.3.2/src/dfa.rs:1537:14 clippy::doc_markdown "you should put `byte_class` between ticks in the documentation" +regex-1.3.2/src/dfa.rs:1538:41 clippy::inline_always "you have declared `#[inline(always)]` on `u8_class`. This is usually a bad idea" +regex-1.3.2/src/dfa.rs:1562:18 clippy::doc_markdown "you should put `STATE_START` between ticks in the documentation" +regex-1.3.2/src/dfa.rs:1614:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/dfa.rs:1651:38 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/dfa.rs:1700:17 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +regex-1.3.2/src/dfa.rs:1701:18 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex-1.3.2/src/dfa.rs:1705:19 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex-1.3.2/src/dfa.rs:1708:16 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +regex-1.3.2/src/dfa.rs:1709:18 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex-1.3.2/src/dfa.rs:1713:19 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex-1.3.2/src/dfa.rs:1716:18 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +regex-1.3.2/src/dfa.rs:1717:18 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex-1.3.2/src/dfa.rs:1721:19 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex-1.3.2/src/dfa.rs:1727:14 clippy::cast_lossless "casting `u8` to `u16` may become silently lossy if you later change the type" +regex-1.3.2/src/dfa.rs:1732:15 clippy::trivially_copy_pass_by_ref "this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +regex-1.3.2/src/dfa.rs:1736:22 clippy::trivially_copy_pass_by_ref "this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +regex-1.3.2/src/dfa.rs:1741:9 clippy::match_like_matches_macro "match expression looks like `matches!` macro" +regex-1.3.2/src/dfa.rs:1747:16 clippy::trivially_copy_pass_by_ref "this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +regex-1.3.2/src/dfa.rs:1751:18 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" +regex-1.3.2/src/dfa.rs:1815:38 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" +regex-1.3.2/src/dfa.rs:1821:21 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" +regex-1.3.2/src/dfa.rs:1824:5 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex-1.3.2/src/dfa.rs:1848:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +regex-1.3.2/src/dfa.rs:1850:18 clippy::cast_sign_loss "casting `i32` to `u32` may lose the sign of the value" +regex-1.3.2/src/dfa.rs:1857:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +regex-1.3.2/src/dfa.rs:1860:17 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +regex-1.3.2/src/dfa.rs:1867:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +regex-1.3.2/src/dfa.rs:1870:19 clippy::cast_possible_truncation "casting `u32` to `u8` may truncate the value" +regex-1.3.2/src/dfa.rs:1873:15 clippy::cast_possible_truncation "casting `u32` to `u8` may truncate the value" +regex-1.3.2/src/dfa.rs:1876:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +regex-1.3.2/src/dfa.rs:1882:26 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +regex-1.3.2/src/dfa.rs:1884:15 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +regex-1.3.2/src/dfa.rs:277:17 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +regex-1.3.2/src/dfa.rs:277:31 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +regex-1.3.2/src/dfa.rs:295:20 clippy::cast_possible_truncation "casting `usize` to `i32` may truncate the value on targets with 64-bit wide pointers" +regex-1.3.2/src/dfa.rs:295:20 clippy::cast_possible_wrap "casting `usize` to `i32` may wrap around the value on targets with 32-bit wide pointers" +regex-1.3.2/src/dfa.rs:299:21 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" +regex-1.3.2/src/dfa.rs:34:46 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +regex-1.3.2/src/dfa.rs:398:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +regex-1.3.2/src/dfa.rs:446:41 clippy::inline_always "you have declared `#[inline(always)]` on `forward`. This is usually a bad idea" +regex-1.3.2/src/dfa.rs:457:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/dfa.rs:459:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/dfa.rs:460:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/dfa.rs:476:41 clippy::inline_always "you have declared `#[inline(always)]` on `reverse`. This is usually a bad idea" +regex-1.3.2/src/dfa.rs:487:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/dfa.rs:489:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/dfa.rs:490:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/dfa.rs:506:41 clippy::inline_always "you have declared `#[inline(always)]` on `forward_many`. This is usually a bad idea" +regex-1.3.2/src/dfa.rs:518:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/dfa.rs:520:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/dfa.rs:554:41 clippy::inline_always "you have declared `#[inline(always)]` on `exec_at`. This is usually a bad idea" +regex-1.3.2/src/dfa.rs:555:5 clippy::too_many_lines "this function has too many lines (101/100)" +regex-1.3.2/src/dfa.rs:58:9 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/dfa.rs:667:21 clippy::similar_names "binding's name is too similar to existing binding" +regex-1.3.2/src/dfa.rs:747:41 clippy::inline_always "you have declared `#[inline(always)]` on `exec_at_reverse`. This is usually a bad idea" +regex-1.3.2/src/dfa.rs:795:21 clippy::similar_names "binding's name is too similar to existing binding" +regex-1.3.2/src/dfa.rs:848:9 clippy::doc_markdown "you should put `next_si` between ticks in the documentation" +regex-1.3.2/src/dfa.rs:852:41 clippy::inline_always "you have declared `#[inline(always)]` on `next_si`. This is usually a bad idea" +regex-1.3.2/src/dfa.rs:885:12 clippy::doc_markdown "you should put `STATE_DEAD` between ticks in the documentation" +regex-1.3.2/src/dfa.rs:889:9 clippy::doc_markdown "you should put `STATE_UNKNOWN` between ticks in the documentation" +regex-1.3.2/src/dfa.rs:897:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/dfa.rs:979:29 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex-1.3.2/src/error.rs:6:1 clippy::manual_non_exhaustive "this seems like a manual implementation of the non-exhaustive pattern" +regex-1.3.2/src/exec.rs:1000:14 clippy::doc_markdown "you should put `captures_nfa` between ticks in the documentation" +regex-1.3.2/src/exec.rs:100:1 clippy::module_name_repetitions "item name starts with its containing module's name" +regex-1.3.2/src/exec.rs:1028:5 clippy::too_many_arguments "this function has too many arguments (9/7)" +regex-1.3.2/src/exec.rs:1039:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/exec.rs:1144:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/exec.rs:1179:26 clippy::match_same_arms "this `match` has identical arm bodies" +regex-1.3.2/src/exec.rs:122:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/exec.rs:1250:41 clippy::inline_always "you have declared `#[inline(always)]` on `searcher`. This is usually a bad idea" +regex-1.3.2/src/exec.rs:1260:41 clippy::inline_always "you have declared `#[inline(always)]` on `searcher_str`. This is usually a bad idea" +regex-1.3.2/src/exec.rs:1270:17 clippy::doc_markdown "you should put `RegexSet` between ticks in the documentation" +regex-1.3.2/src/exec.rs:1280:17 clippy::doc_markdown "you should put `RegexSet` between ticks in the documentation" +regex-1.3.2/src/exec.rs:137:9 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" +regex-1.3.2/src/exec.rs:142:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/exec.rs:1493:5 clippy::upper_case_acronyms "name `PikeVM` contains a capitalized acronym" +regex-1.3.2/src/exec.rs:158:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/exec.rs:168:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/exec.rs:181:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/exec.rs:195:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/exec.rs:204:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/exec.rs:210:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/exec.rs:245:62 clippy::if_same_then_else "this `if` has identical blocks" +regex-1.3.2/src/exec.rs:251:21 clippy::if_not_else "unnecessary boolean `not` operation" +regex-1.3.2/src/exec.rs:262:60 clippy::if_same_then_else "this `if` has identical blocks" +regex-1.3.2/src/exec.rs:268:21 clippy::if_not_else "unnecessary boolean `not` operation" +regex-1.3.2/src/exec.rs:278:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/exec.rs:281:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/exec.rs:286:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +regex-1.3.2/src/exec.rs:300:30 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/exec.rs:308:17 clippy::similar_names "binding's name is too similar to existing binding" +regex-1.3.2/src/exec.rs:329:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/exec.rs:330:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/exec.rs:331:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/exec.rs:334:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/exec.rs:340:19 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/exec.rs:344:27 clippy::unused_self "unused `self` argument" +regex-1.3.2/src/exec.rs:383:41 clippy::inline_always "you have declared `#[inline(always)]` on `shortest_match_at`. This is usually a bad idea" +regex-1.3.2/src/exec.rs:388:41 clippy::inline_always "you have declared `#[inline(always)]` on `is_match_at`. This is usually a bad idea" +regex-1.3.2/src/exec.rs:393:41 clippy::inline_always "you have declared `#[inline(always)]` on `find_at`. This is usually a bad idea" +regex-1.3.2/src/exec.rs:398:41 clippy::inline_always "you have declared `#[inline(always)]` on `captures_read_at`. This is usually a bad idea" +regex-1.3.2/src/exec.rs:425:41 clippy::inline_always "you have declared `#[inline(always)]` on `shortest_match_at`. This is usually a bad idea" +regex-1.3.2/src/exec.rs:44:1 clippy::module_name_repetitions "item name starts with its containing module's name" +regex-1.3.2/src/exec.rs:473:9 clippy::doc_markdown "you should put `shortest_match(...).is_some` between ticks in the documentation" +regex-1.3.2/src/exec.rs:474:41 clippy::inline_always "you have declared `#[inline(always)]` on `is_match_at`. This is usually a bad idea" +regex-1.3.2/src/exec.rs:524:41 clippy::inline_always "you have declared `#[inline(always)]` on `find_at`. This is usually a bad idea" +regex-1.3.2/src/exec.rs:52:1 clippy::module_name_repetitions "item name starts with its containing module's name" +regex-1.3.2/src/exec.rs:686:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/exec.rs:727:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/exec.rs:767:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/exec.rs:783:41 clippy::inline_always "you have declared `#[inline(always)]` on `shortest_dfa`. This is usually a bad idea" +regex-1.3.2/src/exec.rs:791:41 clippy::inline_always "you have declared `#[inline(always)]` on `shortest_dfa_reverse_suffix`. This is usually a bad idea" +regex-1.3.2/src/exec.rs:823:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/exec.rs:868:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/exec.rs:897:31 clippy::doc_markdown "you should put `shortest_nfa(...).is_some` between ticks in the documentation" +regex-1.3.2/src/exec.rs:899:9 clippy::doc_markdown "you should put `shortest_nfa` between ticks in the documentation" +regex-1.3.2/src/exec.rs:905:14 clippy::doc_markdown "you should put `match_nfa` between ticks in the documentation" +regex-1.3.2/src/exec.rs:930:14 clippy::doc_markdown "you should put `shortest_nfa` between ticks in the documentation" +regex-1.3.2/src/exec.rs:981:14 clippy::doc_markdown "you should put `find_nfa` between ticks in the documentation" +regex-1.3.2/src/expand.rs:170:27 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +regex-1.3.2/src/expand.rs:171:5 clippy::match_like_matches_macro "match expression looks like `matches!` macro" +regex-1.3.2/src/expand.rs:22:13 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +regex-1.3.2/src/expand.rs:27:23 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +regex-1.3.2/src/expand.rs:30:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +regex-1.3.2/src/expand.rs:38:30 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +regex-1.3.2/src/expand.rs:42:21 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +regex-1.3.2/src/expand.rs:50:1 clippy::module_name_repetitions "item name starts with its containing module's name" +regex-1.3.2/src/expand.rs:69:23 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +regex-1.3.2/src/expand.rs:80:28 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +regex-1.3.2/src/expand.rs:84:21 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +regex-1.3.2/src/expand.rs:8:1 clippy::module_name_repetitions "item name starts with its containing module's name" +regex-1.3.2/src/input.rs:142:1 clippy::module_name_repetitions "item name ends with its containing module's name" +regex-1.3.2/src/input.rs:146:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/input.rs:15:1 clippy::module_name_repetitions "item name starts with its containing module's name" +regex-1.3.2/src/input.rs:165:31 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/input.rs:178:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/input.rs:228:1 clippy::module_name_repetitions "item name ends with its containing module's name" +regex-1.3.2/src/input.rs:236:21 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/input.rs:236:33 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/input.rs:24:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/input.rs:271:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/input.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/input.rs:362:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/input.rs:370:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/input.rs:371:42 clippy::redundant_closure_for_method_calls "redundant closure found" +regex-1.3.2/src/input.rs:37:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/input.rs:388:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/input.rs:42:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/input.rs:47:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/input.rs:53:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/input.rs:58:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/input.rs:63:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/lib.rs:1:null clippy::cargo_common_metadata "package `regex` is missing `package.keywords` metadata" +regex-1.3.2/src/literal/imp.rs:101:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/literal/imp.rs:114:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/literal/imp.rs:127:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/literal/imp.rs:139:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/literal/imp.rs:144:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/literal/imp.rs:149:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/literal/imp.rs:154:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/literal/imp.rs:155:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/literal/imp.rs:160:30 clippy::match_same_arms "this `match` has identical arm bodies" +regex-1.3.2/src/literal/imp.rs:167:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/literal/imp.rs:168:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/literal/imp.rs:211:20 clippy::redundant_else "redundant else block" +regex-1.3.2/src/literal/imp.rs:239:5 clippy::upper_case_acronyms "name `AC` contains a capitalized acronym" +regex-1.3.2/src/literal/imp.rs:276:50 clippy::match_same_arms "this `match` has identical arm bodies" +regex-1.3.2/src/literal/imp.rs:342:41 clippy::inline_always "you have declared `#[inline(always)]` on `find`. This is usually a bad idea" +regex-1.3.2/src/literal/imp.rs:34:5 clippy::upper_case_acronyms "name `AC` contains a capitalized acronym" +regex-1.3.2/src/literal/imp.rs:435:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/literal/imp.rs:436:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/literal/imp.rs:437:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/literal/imp.rs:438:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/literal/imp.rs:439:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/literal/imp.rs:440:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/literal/imp.rs:455:41 clippy::inline_always "you have declared `#[inline(always)]` on `find`. This is usually a bad idea" +regex-1.3.2/src/literal/imp.rs:46:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/literal/imp.rs:481:41 clippy::inline_always "you have declared `#[inline(always)]` on `is_suffix`. This is usually a bad idea" +regex-1.3.2/src/literal/imp.rs:51:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/literal/imp.rs:579:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/literal/imp.rs:57:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/literal/imp.rs:580:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/literal/imp.rs:583:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/literal/imp.rs:602:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +regex-1.3.2/src/literal/imp.rs:622:24 clippy::redundant_else "redundant else block" +regex-1.3.2/src/literal/imp.rs:62:18 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +regex-1.3.2/src/literal/imp.rs:637:24 clippy::redundant_else "redundant else block" +regex-1.3.2/src/literal/imp.rs:648:9 clippy::needless_return "unneeded `return` statement" +regex-1.3.2/src/literal/imp.rs:651:44 clippy::doc_markdown "you should put `BoyerMooreSearch` between ticks in the documentation" +regex-1.3.2/src/literal/imp.rs:65:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/literal/imp.rs:68:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/literal/imp.rs:783:32 clippy::redundant_else "redundant else block" +regex-1.3.2/src/literal/imp.rs:786:42 clippy::manual_saturating_arithmetic "manual saturating arithmetic" +regex-1.3.2/src/literal/imp.rs:78:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/literal/imp.rs:84:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/literal/imp.rs:850:20 clippy::unreadable_literal "long literal lacking separators" +regex-1.3.2/src/literal/imp.rs:85:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/pikevm.rs:103:15 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/pikevm.rs:103:52 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/pikevm.rs:114:5 clippy::too_many_arguments "this function has too many arguments (8/7)" +regex-1.3.2/src/pikevm.rs:117:13 clippy::similar_names "binding's name is too similar to existing binding" +regex-1.3.2/src/pikevm.rs:124:17 clippy::similar_names "binding's name is too similar to existing binding" +regex-1.3.2/src/pikevm.rs:220:9 clippy::doc_markdown "you should put `thread_caps` between ticks in the documentation" +regex-1.3.2/src/pikevm.rs:222:16 clippy::doc_markdown "you should put `at_next` between ticks in the documentation" +regex-1.3.2/src/pikevm.rs:223:9 clippy::doc_markdown "you should put `at_next` between ticks in the documentation" +regex-1.3.2/src/pikevm.rs:224:5 clippy::too_many_arguments "this function has too many arguments (8/7)" +regex-1.3.2/src/pikevm.rs:234:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/pikevm.rs:303:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/pikevm.rs:331:29 clippy::mut_mut "this expression mutably borrows a mutable reference. Consider reborrowing" +regex-1.3.2/src/pikevm.rs:70:5 clippy::upper_case_acronyms "name `IP` contains a capitalized acronym" +regex-1.3.2/src/pikevm.rs:88:5 clippy::too_many_arguments "this function has too many arguments (8/7)" +regex-1.3.2/src/prog.rs:102:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/prog.rs:113:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/prog.rs:120:9 clippy::match_like_matches_macro "match expression looks like `matches!` macro" +regex-1.3.2/src/prog.rs:128:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/prog.rs:134:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/prog.rs:141:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/prog.rs:147:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/prog.rs:164:41 clippy::inline_always "you have declared `#[inline(always)]` on `deref`. This is usually a bad idea" +regex-1.3.2/src/prog.rs:172:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/prog.rs:18:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +regex-1.3.2/src/prog.rs:236:13 clippy::write_with_newline "using `write!()` with a format string that ends in a single newline" +regex-1.3.2/src/prog.rs:300:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/prog.rs:301:9 clippy::match_like_matches_macro "match expression looks like `matches!` macro" +regex-1.3.2/src/prog.rs:382:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/prog.rs:409:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/prog.rs:80:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/prog.rs:80:5 clippy::new_without_default "you should consider adding a `Default` implementation for `prog::Program`" +regex-1.3.2/src/re_builder.rs:267:17 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +regex-1.3.2/src/re_builder.rs:267:17 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +regex-1.3.2/src/re_builder.rs:4:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +regex-1.3.2/src/re_builder.rs:57:17 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_builder.rs:57:17 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_builder.rs:68:17 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +regex-1.3.2/src/re_builder.rs:68:17 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +regex-1.3.2/src/re_bytes.rs:1017:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +regex-1.3.2/src/re_bytes.rs:1039:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +regex-1.3.2/src/re_bytes.rs:1093:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +regex-1.3.2/src/re_bytes.rs:1118:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +regex-1.3.2/src/re_bytes.rs:1133:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +regex-1.3.2/src/re_bytes.rs:118:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +regex-1.3.2/src/re_bytes.rs:256:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/re_bytes.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_bytes.rs:35:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_bytes.rs:42:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_bytes.rs:48:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_bytes.rs:558:29 clippy::doc_markdown "you should put `shortest_match` between ticks in the documentation" +regex-1.3.2/src/re_bytes.rs:55:33 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/re_bytes.rs:55:47 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/re_bytes.rs:572:29 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" +regex-1.3.2/src/re_bytes.rs:720:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/re_bytes.rs:817:5 clippy::doc_markdown "you should put `CaptureLocations` between ticks in the documentation" +regex-1.3.2/src/re_bytes.rs:843:1 clippy::len_without_is_empty "item `re_bytes::CaptureLocations` has a public `len` method but no corresponding `is_empty` method" +regex-1.3.2/src/re_bytes.rs:849:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_bytes.rs:858:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_bytes.rs:869:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_bytes.rs:891:1 clippy::len_without_is_empty "item `re_bytes::Captures<'t>` has a public `len` method but no corresponding `is_empty` method" +regex-1.3.2/src/re_bytes.rs:911:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_bytes.rs:917:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_bytes.rs:926:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_bytes.rs:955:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_set.rs:179:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/re_set.rs:179:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/re_set.rs:251:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_set.rs:251:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_set.rs:263:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_set.rs:263:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_set.rs:268:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_set.rs:268:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_set.rs:277:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_set.rs:277:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_set.rs:94:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +regex-1.3.2/src/re_set.rs:94:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +regex-1.3.2/src/re_trait.rs:136:29 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/re_unicode.rs:1019:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +regex-1.3.2/src/re_unicode.rs:1041:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +regex-1.3.2/src/re_unicode.rs:1088:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/re_unicode.rs:1135:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +regex-1.3.2/src/re_unicode.rs:1160:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +regex-1.3.2/src/re_unicode.rs:174:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +regex-1.3.2/src/re_unicode.rs:21:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +regex-1.3.2/src/re_unicode.rs:313:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/re_unicode.rs:38:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_unicode.rs:44:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_unicode.rs:51:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_unicode.rs:57:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_unicode.rs:617:29 clippy::doc_markdown "you should put `shortest_match` between ticks in the documentation" +regex-1.3.2/src/re_unicode.rs:631:29 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" +regex-1.3.2/src/re_unicode.rs:64:33 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/re_unicode.rs:64:47 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/re_unicode.rs:834:5 clippy::doc_markdown "you should put `CaptureLocations` between ticks in the documentation" +regex-1.3.2/src/re_unicode.rs:860:1 clippy::len_without_is_empty "item `re_unicode::CaptureLocations` has a public `len` method but no corresponding `is_empty` method" +regex-1.3.2/src/re_unicode.rs:866:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_unicode.rs:875:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_unicode.rs:886:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_unicode.rs:908:1 clippy::len_without_is_empty "item `re_unicode::Captures<'t>` has a public `len` method but no corresponding `is_empty` method" +regex-1.3.2/src/re_unicode.rs:928:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_unicode.rs:934:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_unicode.rs:943:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_unicode.rs:972:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/sparse.rs:10:37 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +regex-1.3.2/src/sparse.rs:15:1 clippy::module_name_repetitions "item name starts with its containing module's name" +regex-1.3.2/src/utf8.rs:100:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex-1.3.2/src/utf8.rs:103:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex-1.3.2/src/utf8.rs:106:22 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +regex-1.3.2/src/utf8.rs:107:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +regex-1.3.2/src/utf8.rs:108:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +regex-1.3.2/src/utf8.rs:109:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +regex-1.3.2/src/utf8.rs:111:27 clippy::unreadable_literal "long literal lacking separators" +regex-1.3.2/src/utf8.rs:121:1 clippy::module_name_repetitions "item name ends with its containing module's name" +regex-1.3.2/src/utf8.rs:143:24 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex-1.3.2/src/utf8.rs:143:9 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex-1.3.2/src/utf8.rs:23:1 clippy::module_name_repetitions "item name ends with its containing module's name" +regex-1.3.2/src/utf8.rs:30:20 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex-1.3.2/src/utf8.rs:51:1 clippy::module_name_repetitions "item name ends with its containing module's name" +regex-1.3.2/src/utf8.rs:58:23 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex-1.3.2/src/utf8.rs:58:9 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex-1.3.2/src/utf8.rs:63:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex-1.3.2/src/utf8.rs:66:22 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +regex-1.3.2/src/utf8.rs:66:54 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +regex-1.3.2/src/utf8.rs:77:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex-1.3.2/src/utf8.rs:80:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex-1.3.2/src/utf8.rs:83:22 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +regex-1.3.2/src/utf8.rs:84:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +regex-1.3.2/src/utf8.rs:85:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +regex-1.3.2/src/utf8.rs:92:23 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex-1.3.2/src/utf8.rs:92:9 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex-1.3.2/src/utf8.rs:97:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +ripgrep-12.1.1//home/matthias/.rustup/toolchains/nightly-2021-01-15-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std/src/macros.rs:14:27 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep-12.1.1//home/matthias/.rustup/toolchains/nightly-2021-01-15-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std/src/macros.rs:14:27 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep-12.1.1//home/matthias/.rustup/toolchains/nightly-2021-01-15-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std/src/macros.rs:14:27 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep-12.1.1//home/matthias/.rustup/toolchains/nightly-2021-01-15-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std/src/macros.rs:14:27 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep-12.1.1/build.rs:133:19 clippy::option_as_ref_deref "called `.as_ref().map(|x| &**x)` on an Option value. This can be done more directly by calling `githash.as_deref()` instead" +ripgrep-12.1.1/build.rs:18:18 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +ripgrep-12.1.1/build.rs:225:14 clippy::redundant_closure_for_method_calls "redundant closure found" +ripgrep-12.1.1/build.rs:92:19 clippy::option_as_ref_deref "called `.as_ref().map(|x| &**x)` on an Option value. This can be done more directly by calling `githash.as_deref()` instead" +ripgrep-12.1.1/crates/core/app.rs:1408:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep-12.1.1/crates/core/app.rs:1408:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep-12.1.1/crates/core/app.rs:1409:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep-12.1.1/crates/core/app.rs:1409:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep-12.1.1/crates/core/app.rs:152:32 clippy::doc_markdown "you should put `clap::Arg` between ticks in the documentation" +ripgrep-12.1.1/crates/core/app.rs:152:32 clippy::doc_markdown "you should put `clap::Arg` between ticks in the documentation" +ripgrep-12.1.1/crates/core/app.rs:156:39 clippy::doc_markdown "you should put `clap::Arg` between ticks in the documentation" +ripgrep-12.1.1/crates/core/app.rs:156:39 clippy::doc_markdown "you should put `clap::Arg` between ticks in the documentation" +ripgrep-12.1.1/crates/core/app.rs:156:5 clippy::doc_markdown "you should put `RGArg` between ticks in the documentation" +ripgrep-12.1.1/crates/core/app.rs:156:5 clippy::doc_markdown "you should put `RGArg` between ticks in the documentation" +ripgrep-12.1.1/crates/core/app.rs:164:12 clippy::upper_case_acronyms "name `RGArg` contains a capitalized acronym" +ripgrep-12.1.1/crates/core/app.rs:164:12 clippy::upper_case_acronyms "name `RGArg` contains a capitalized acronym" +ripgrep-12.1.1/crates/core/app.rs:1668:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep-12.1.1/crates/core/app.rs:1668:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep-12.1.1/crates/core/app.rs:1669:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep-12.1.1/crates/core/app.rs:1669:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep-12.1.1/crates/core/app.rs:1821:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep-12.1.1/crates/core/app.rs:1821:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep-12.1.1/crates/core/app.rs:1822:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep-12.1.1/crates/core/app.rs:1822:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep-12.1.1/crates/core/app.rs:212:10 clippy::upper_case_acronyms "name `RGArgKind` contains a capitalized acronym" +ripgrep-12.1.1/crates/core/app.rs:212:10 clippy::upper_case_acronyms "name `RGArgKind` contains a capitalized acronym" +ripgrep-12.1.1/crates/core/app.rs:2999:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep-12.1.1/crates/core/app.rs:2999:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep-12.1.1/crates/core/app.rs:3000:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep-12.1.1/crates/core/app.rs:3000:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep-12.1.1/crates/core/app.rs:367:54 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep-12.1.1/crates/core/app.rs:367:54 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep-12.1.1/crates/core/app.rs:414:59 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep-12.1.1/crates/core/app.rs:414:59 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep-12.1.1/crates/core/app.rs:417:57 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep-12.1.1/crates/core/app.rs:417:57 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep-12.1.1/crates/core/app.rs:417:57 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep-12.1.1/crates/core/app.rs:417:57 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep-12.1.1/crates/core/app.rs:75:9 clippy::doc_markdown "you should put `RIPGREP_BUILD_GIT_HASH` between ticks in the documentation" +ripgrep-12.1.1/crates/core/app.rs:75:9 clippy::doc_markdown "you should put `RIPGREP_BUILD_GIT_HASH` between ticks in the documentation" +ripgrep-12.1.1/crates/core/app.rs:87:5 clippy::if_not_else "unnecessary boolean `not` operation" +ripgrep-12.1.1/crates/core/app.rs:87:5 clippy::if_not_else "unnecessary boolean `not` operation" +ripgrep-12.1.1/crates/core/args.rs:1143:22 clippy::unused_self "unused `self` argument" +ripgrep-12.1.1/crates/core/args.rs:11:1 clippy::single_component_path_imports "this import is redundant" +ripgrep-12.1.1/crates/core/args.rs:1209:74 clippy::if_same_then_else "this `if` has identical blocks" +ripgrep-12.1.1/crates/core/args.rs:1282:13 clippy::similar_names "binding's name is too similar to existing binding" +ripgrep-12.1.1/crates/core/args.rs:1430:22 clippy::unused_self "unused `self` argument" +ripgrep-12.1.1/crates/core/args.rs:1438:21 clippy::doc_markdown "you should put `OsStr` between ticks in the documentation" +ripgrep-12.1.1/crates/core/args.rs:1520:44 clippy::redundant_closure_for_method_calls "redundant closure found" +ripgrep-12.1.1/crates/core/args.rs:1524:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +ripgrep-12.1.1/crates/core/args.rs:1635:14 clippy::doc_markdown "you should put `values_of_lossy` between ticks in the documentation" +ripgrep-12.1.1/crates/core/args.rs:1693:41 clippy::redundant_closure_for_method_calls "redundant closure found" +ripgrep-12.1.1/crates/core/args.rs:1770:17 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +ripgrep-12.1.1/crates/core/args.rs:287:13 clippy::similar_names "binding's name is too similar to existing binding" +ripgrep-12.1.1/crates/core/args.rs:33:1 clippy::single_component_path_imports "this import is redundant" +ripgrep-12.1.1/crates/core/args.rs:34:1 clippy::single_component_path_imports "this import is redundant" +ripgrep-12.1.1/crates/core/args.rs:35:1 clippy::single_component_path_imports "this import is redundant" +ripgrep-12.1.1/crates/core/args.rs:369:5 clippy::upper_case_acronyms "name `JSON` contains a capitalized acronym" +ripgrep-12.1.1/crates/core/args.rs:410:14 clippy::trivially_copy_pass_by_ref "this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +ripgrep-12.1.1/crates/core/args.rs:475:18 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep-12.1.1/crates/core/args.rs:512:19 clippy::doc_markdown "you should put `ArgMatches` between ticks in the documentation" +ripgrep-12.1.1/crates/core/args.rs:549:16 clippy::wrong_self_convention "methods called `to_*` usually take self by reference; consider choosing a less ambiguous name" +ripgrep-12.1.1/crates/core/args.rs:71:5 clippy::upper_case_acronyms "name `PCRE2Version` contains a capitalized acronym" +ripgrep-12.1.1/crates/core/args.rs:76:18 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +ripgrep-12.1.1/crates/core/args.rs:77:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +ripgrep-12.1.1/crates/core/args.rs:923:42 clippy::doc_markdown "you should put `BinaryDetection::quit` between ticks in the documentation" +ripgrep-12.1.1/crates/core/config.rs:13:1 clippy::single_component_path_imports "this import is redundant" +ripgrep-12.1.1/crates/core/config.rs:58:6 clippy::type_complexity "very complex type used. Consider factoring parts into `type` definitions" +ripgrep-12.1.1/crates/core/config.rs:79:6 clippy::type_complexity "very complex type used. Consider factoring parts into `type` definitions" +ripgrep-12.1.1/crates/core/logger.rs:11:30 clippy::doc_markdown "you should put `max_level` between ticks in the documentation" +ripgrep-12.1.1/crates/core/logger.rs:15:16 clippy::redundant_static_lifetimes "constants have by default a `'static` lifetime" +ripgrep-12.1.1/crates/core/main.rs:55:19 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +ripgrep-12.1.1/crates/core/main.rs:56:9 clippy::enum_glob_use "usage of wildcard import for enum variants" +ripgrep-12.1.1/crates/core/messages.rs:46:1 clippy::module_name_repetitions "item name ends with its containing module's name" +ripgrep-12.1.1/crates/core/messages.rs:51:1 clippy::module_name_repetitions "item name ends with its containing module's name" +ripgrep-12.1.1/crates/core/messages.rs:62:1 clippy::module_name_repetitions "item name ends with its containing module's name" +ripgrep-12.1.1/crates/core/path_printer.rs:27:1 clippy::module_name_repetitions "item name starts with its containing module's name" +ripgrep-12.1.1/crates/core/path_printer.rs:89:9 clippy::if_not_else "unnecessary boolean `not` operation" +ripgrep-12.1.1/crates/core/search.rs:185:1 clippy::module_name_repetitions "item name starts with its containing module's name" +ripgrep-12.1.1/crates/core/search.rs:224:5 clippy::upper_case_acronyms "name `JSON` contains a capitalized acronym" +ripgrep-12.1.1/crates/core/search.rs:292:9 clippy::write_with_newline "using `write!()` with a format string that ends in a single newline" +ripgrep-12.1.1/crates/core/search.rs:311:1 clippy::module_name_repetitions "item name starts with its containing module's name" +ripgrep-12.1.1/crates/core/search.rs:377:12 clippy::nonminimal_bool "this boolean expression can be simplified" +ripgrep-12.1.1/crates/core/search.rs:423:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +ripgrep-12.1.1/crates/core/search.rs:447:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +ripgrep-12.1.1/crates/core/search.rs:472:24 clippy::map_clone "you are using an explicit closure for cloning elements" +ripgrep-12.1.1/crates/core/search.rs:472:41 clippy::redundant_closure_for_method_calls "redundant closure found" +ripgrep-12.1.1/crates/core/search.rs:480:24 clippy::map_clone "you are using an explicit closure for cloning elements" +ripgrep-12.1.1/crates/core/search.rs:480:41 clippy::redundant_closure_for_method_calls "redundant closure found" +ripgrep-12.1.1/crates/core/search.rs:49:1 clippy::module_name_repetitions "item name starts with its containing module's name" +ripgrep-12.1.1/crates/core/search.rs:509:24 clippy::map_clone "you are using an explicit closure for cloning elements" +ripgrep-12.1.1/crates/core/search.rs:509:41 clippy::redundant_closure_for_method_calls "redundant closure found" +ripgrep-12.1.1/crates/core/search.rs:517:24 clippy::map_clone "you are using an explicit closure for cloning elements" +ripgrep-12.1.1/crates/core/search.rs:517:41 clippy::redundant_closure_for_method_calls "redundant closure found" +ripgrep-12.1.1/crates/core/search.rs:533:36 clippy::cast_lossless "casting `u32` to `f64` may become silently lossy if you later change the type" +ripgrep-12.1.1/crates/core/search.rs:533:5 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +ripgrep-12.1.1/crates/core/subject.rs:20:1 clippy::module_name_repetitions "item name starts with its containing module's name" +ripgrep-12.1.1/crates/core/subject.rs:4:1 clippy::single_component_path_imports "this import is redundant" +syn-1.0.54/build.rs:1:null clippy::cargo_common_metadata "package `syn` is missing `package.keywords` metadata" +syn-1.0.54/build.rs:1:null clippy::multiple_crate_versions "could not read cargo metadata: `cargo metadata` exited with an error: Downloading crates ...\n Downloaded syn-test-suite v0.0.0\nerror: failed to verify the checksum of `syn-test-suite v0.0.0`" +syn-1.0.54/src/lib.rs:1:null clippy::cargo_common_metadata "package `syn` is missing `package.keywords` metadata" +syn-1.0.54/src/lib.rs:1:null clippy::multiple_crate_versions "could not read cargo metadata: `cargo metadata` exited with an error: Downloading crates ...\n Downloaded syn-test-suite v0.0.0\nerror: failed to verify the checksum of `syn-test-suite v0.0.0`" +syn-1.0.54/src/lit.rs:1397:40 clippy::redundant_else "redundant else block" +syn-1.0.54/src/lit.rs:1405:28 clippy::redundant_else "redundant else block" +syn-1.0.54/src/lit.rs:1485:32 clippy::redundant_else "redundant else block" +unicode-xid-0.2.1/src/lib.rs:1:null clippy::cargo_common_metadata "package `unicode-xid` is missing `package.categories` metadata" +unicode-xid-0.2.1/src/lib.rs:56:11 clippy::upper_case_acronyms "name `UnicodeXID` contains a capitalized acronym" +unicode-xid-0.2.1/src/lib.rs:57:64 clippy::doc_markdown "you should put `XID_Start` between ticks in the documentation" +unicode-xid-0.2.1/src/lib.rs:60:10 clippy::doc_markdown "you should put `XID_Start` between ticks in the documentation" +unicode-xid-0.2.1/src/lib.rs:62:27 clippy::doc_markdown "you should put `ID_Start` between ticks in the documentation" +unicode-xid-0.2.1/src/lib.rs:62:67 clippy::doc_markdown "you should put `NFKx` between ticks in the documentation" +unicode-xid-0.2.1/src/lib.rs:63:21 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" +unicode-xid-0.2.1/src/lib.rs:65:61 clippy::doc_markdown "you should put `XID_Continue` between ticks in the documentation" +unicode-xid-0.2.1/src/lib.rs:68:10 clippy::doc_markdown "you should put `XID_Continue` between ticks in the documentation" +unicode-xid-0.2.1/src/lib.rs:70:28 clippy::doc_markdown "you should put `ID_Continue` between ticks in the documentation" +unicode-xid-0.2.1/src/lib.rs:70:72 clippy::doc_markdown "you should put `NFKx` between ticks in the documentation" +unicode-xid-0.2.1/src/lib.rs:71:24 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" +xsv-0.13.0/src/cmd/cat.rs:101:34 clippy::redundant_closure_for_method_calls "redundant closure found" +xsv-0.13.0/src/cmd/cat.rs:42:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +xsv-0.13.0/src/cmd/cat.rs:53:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/cat.rs:7:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv-0.13.0/src/cmd/count.rs:32:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/count.rs:38:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +xsv-0.13.0/src/cmd/count.rs:42:33 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +xsv-0.13.0/src/cmd/count.rs:50:5 clippy::unit_arg "passing a unit value to a function" +xsv-0.13.0/src/cmd/count.rs:7:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv-0.13.0/src/cmd/fixlengths.rs:45:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/fixlengths.rs:50:18 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +xsv-0.13.0/src/cmd/fixlengths.rs:62:30 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +xsv-0.13.0/src/cmd/fixlengths.rs:9:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv-0.13.0/src/cmd/flatten.rs:10:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv-0.13.0/src/cmd/flatten.rs:51:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/fmt.rs:50:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/fmt.rs:55:13 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/fmt.rs:7:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv-0.13.0/src/cmd/frequency.rs:148:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +xsv-0.13.0/src/cmd/frequency.rs:149:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +xsv-0.13.0/src/cmd/frequency.rs:15:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv-0.13.0/src/cmd/frequency.rs:169:13 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/frequency.rs:176:17 clippy::if_not_else "unnecessary boolean `not` operation" +xsv-0.13.0/src/cmd/frequency.rs:178:24 clippy::collapsible_else_if "this `else { if .. }` block can be collapsed" +xsv-0.13.0/src/cmd/frequency.rs:77:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/frequency.rs:93:31 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" +xsv-0.13.0/src/cmd/headers.rs:43:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/headers.rs:49:17 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" +xsv-0.13.0/src/cmd/headers.rs:9:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv-0.13.0/src/cmd/index.rs:11:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv-0.13.0/src/cmd/index.rs:45:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/input.rs:42:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/input.rs:47:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/input.rs:7:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv-0.13.0/src/cmd/join.rs:17:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv-0.13.0/src/cmd/join.rs:194:29 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/join.rs:224:22 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/join.rs:293:14 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/join.rs:293:20 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/join.rs:297:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv-0.13.0/src/cmd/join.rs:298:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv-0.13.0/src/cmd/join.rs:299:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv-0.13.0/src/cmd/join.rs:300:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv-0.13.0/src/cmd/join.rs:308:9 clippy::unused_self "unused `self` argument" +xsv-0.13.0/src/cmd/join.rs:342:38 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +xsv-0.13.0/src/cmd/join.rs:342:46 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +xsv-0.13.0/src/cmd/join.rs:347:9 clippy::if_not_else "unnecessary boolean `not` operation" +xsv-0.13.0/src/cmd/join.rs:372:44 clippy::redundant_closure_for_method_calls "redundant closure found" +xsv-0.13.0/src/cmd/join.rs:375:33 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/join.rs:392:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv-0.13.0/src/cmd/join.rs:403:29 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" +xsv-0.13.0/src/cmd/join.rs:426:13 clippy::if_not_else "unnecessary boolean `not` operation" +xsv-0.13.0/src/cmd/join.rs:77:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +xsv-0.13.0/src/cmd/join.rs:94:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/partition.rs:105:22 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/partition.rs:106:22 clippy::redundant_slicing "redundant slicing of the whole range" +xsv-0.13.0/src/cmd/partition.rs:139:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv-0.13.0/src/cmd/partition.rs:15:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv-0.13.0/src/cmd/partition.rs:169:9 clippy::if_not_else "unnecessary boolean `not` operation" +xsv-0.13.0/src/cmd/partition.rs:56:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/partition.rs:77:9 clippy::unused_self "unused `self` argument" +xsv-0.13.0/src/cmd/sample.rs:105:44 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +xsv-0.13.0/src/cmd/sample.rs:115:21 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +xsv-0.13.0/src/cmd/sample.rs:11:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv-0.13.0/src/cmd/sample.rs:51:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/sample.rs:58:19 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +xsv-0.13.0/src/cmd/sample.rs:69:9 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +xsv-0.13.0/src/cmd/sample.rs:75:16 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" +xsv-0.13.0/src/cmd/sample.rs:91:42 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +xsv-0.13.0/src/cmd/sample.rs:92:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +xsv-0.13.0/src/cmd/search.rs:51:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/search.rs:9:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv-0.13.0/src/cmd/select.rs:60:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/select.rs:8:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv-0.13.0/src/cmd/slice.rs:57:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/slice.rs:9:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv-0.13.0/src/cmd/sort.rs:11:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv-0.13.0/src/cmd/sort.rs:138:47 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +xsv-0.13.0/src/cmd/sort.rs:139:51 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +xsv-0.13.0/src/cmd/sort.rs:48:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/sort.rs:91:14 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" +xsv-0.13.0/src/cmd/split.rs:14:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv-0.13.0/src/cmd/split.rs:61:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/split.rs:94:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +xsv-0.13.0/src/cmd/split.rs:96:14 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +xsv-0.13.0/src/cmd/split.rs:99:13 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +xsv-0.13.0/src/cmd/stats.rs:110:36 clippy::redundant_closure_for_method_calls "redundant closure found" +xsv-0.13.0/src/cmd/stats.rs:127:14 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +xsv-0.13.0/src/cmd/stats.rs:138:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +xsv-0.13.0/src/cmd/stats.rs:139:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +xsv-0.13.0/src/cmd/stats.rs:162:25 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" +xsv-0.13.0/src/cmd/stats.rs:22:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv-0.13.0/src/cmd/stats.rs:231:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +xsv-0.13.0/src/cmd/stats.rs:262:35 clippy::default_trait_access "calling `cmd::stats::TypedSum::default()` is more clear than this expression" +xsv-0.13.0/src/cmd/stats.rs:263:40 clippy::default_trait_access "calling `cmd::stats::TypedMinMax::default()` is more clear than this expression" +xsv-0.13.0/src/cmd/stats.rs:264:39 clippy::default_trait_access "calling `stats::OnlineStats::default()` is more clear than this expression" +xsv-0.13.0/src/cmd/stats.rs:265:58 clippy::default_trait_access "calling `stats::Unsorted::default()` is more clear than this expression" +xsv-0.13.0/src/cmd/stats.rs:266:41 clippy::default_trait_access "calling `stats::Unsorted::default()` is more clear than this expression" +xsv-0.13.0/src/cmd/stats.rs:268:18 clippy::default_trait_access "calling `cmd::stats::FieldType::default()` is more clear than this expression" +xsv-0.13.0/src/cmd/stats.rs:269:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv-0.13.0/src/cmd/stats.rs:270:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv-0.13.0/src/cmd/stats.rs:271:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv-0.13.0/src/cmd/stats.rs:272:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv-0.13.0/src/cmd/stats.rs:273:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv-0.13.0/src/cmd/stats.rs:274:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv-0.13.0/src/cmd/stats.rs:283:9 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" +xsv-0.13.0/src/cmd/stats.rs:284:9 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" +xsv-0.13.0/src/cmd/stats.rs:285:9 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" +xsv-0.13.0/src/cmd/stats.rs:290:21 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" +xsv-0.13.0/src/cmd/stats.rs:293:25 clippy::match_same_arms "this `match` has identical arm bodies" +xsv-0.13.0/src/cmd/stats.rs:297:25 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" +xsv-0.13.0/src/cmd/stats.rs:301:21 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" +xsv-0.13.0/src/cmd/stats.rs:302:21 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" +xsv-0.13.0/src/cmd/stats.rs:308:18 clippy::wrong_self_convention "methods called `to_*` usually take self by reference; consider choosing a less ambiguous name" +xsv-0.13.0/src/cmd/stats.rs:318:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +xsv-0.13.0/src/cmd/stats.rs:322:45 clippy::redundant_closure_for_method_calls "redundant closure found" +xsv-0.13.0/src/cmd/stats.rs:322:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +xsv-0.13.0/src/cmd/stats.rs:327:9 clippy::if_not_else "unnecessary boolean `not` operation" +xsv-0.13.0/src/cmd/stats.rs:330:13 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +xsv-0.13.0/src/cmd/stats.rs:338:45 clippy::redundant_closure_for_method_calls "redundant closure found" +xsv-0.13.0/src/cmd/stats.rs:402:16 clippy::redundant_pattern_matching "redundant pattern matching, consider using `is_ok()`" +xsv-0.13.0/src/cmd/stats.rs:403:16 clippy::redundant_pattern_matching "redundant pattern matching, consider using `is_ok()`" +xsv-0.13.0/src/cmd/stats.rs:407:18 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +xsv-0.13.0/src/cmd/stats.rs:411:16 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +xsv-0.13.0/src/cmd/stats.rs:427:56 clippy::match_same_arms "this `match` has identical arm bodies" +xsv-0.13.0/src/cmd/stats.rs:429:56 clippy::match_same_arms "this `match` has identical arm bodies" +xsv-0.13.0/src/cmd/stats.rs:430:60 clippy::match_same_arms "this `match` has identical arm bodies" +xsv-0.13.0/src/cmd/stats.rs:430:60 clippy::match_same_arms "this `match` has identical arm bodies" +xsv-0.13.0/src/cmd/stats.rs:454:5 clippy::doc_markdown "you should put `TypedSum` between ticks in the documentation" +xsv-0.13.0/src/cmd/stats.rs:473:43 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +xsv-0.13.0/src/cmd/stats.rs:504:56 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +xsv-0.13.0/src/cmd/stats.rs:505:51 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +xsv-0.13.0/src/cmd/stats.rs:511:5 clippy::doc_markdown "you should put `TypedMinMax` between ticks in the documentation" +xsv-0.13.0/src/cmd/stats.rs:536:35 clippy::cast_possible_truncation "casting `f64` to `i64` may truncate the value" +xsv-0.13.0/src/cmd/stats.rs:544:33 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +xsv-0.13.0/src/cmd/stats.rs:592:22 clippy::default_trait_access "calling `stats::MinMax::default()` is more clear than this expression" +xsv-0.13.0/src/cmd/stats.rs:593:22 clippy::default_trait_access "calling `stats::MinMax::default()` is more clear than this expression" +xsv-0.13.0/src/cmd/stats.rs:594:23 clippy::default_trait_access "calling `stats::MinMax::default()` is more clear than this expression" +xsv-0.13.0/src/cmd/stats.rs:595:21 clippy::default_trait_access "calling `stats::MinMax::default()` is more clear than this expression" +xsv-0.13.0/src/cmd/stats.rs:71:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +xsv-0.13.0/src/cmd/stats.rs:86:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/table.rs:10:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv-0.13.0/src/cmd/table.rs:50:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/table.rs:54:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/config.rs:113:43 clippy::or_fun_call "use of `unwrap_or` followed by a function call" +xsv-0.13.0/src/config.rs:58:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +xsv-0.13.0/src/config.rs:77:28 clippy::explicit_deref_methods "explicit deref method call" +xsv-0.13.0/src/config.rs:90:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv-0.13.0/src/index.rs:31:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv-0.13.0/src/main.rs:164:49 clippy::redundant_clone "redundant clone" +xsv-0.13.0/src/main.rs:1:null clippy::cargo_common_metadata "package `xsv` is missing `package.categories` metadata" +xsv-0.13.0/src/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `rand_core`: 0.3.1, 0.4.2" +xsv-0.13.0/src/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `rand`: 0.3.23, 0.4.6" +xsv-0.13.0/src/main.rs:75:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv-0.13.0/src/select.rs:13:1 clippy::module_name_repetitions "item name starts with its containing module's name" +xsv-0.13.0/src/select.rs:154:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +xsv-0.13.0/src/select.rs:250:33 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/select.rs:250:43 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/select.rs:255:39 clippy::range_plus_one "an inclusive range would be more readable" +xsv-0.13.0/src/select.rs:280:20 clippy::len_zero "length comparison to zero" +xsv-0.13.0/src/select.rs:29:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv-0.13.0/src/select.rs:360:62 clippy::trivially_copy_pass_by_ref "this argument (8 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +xsv-0.13.0/src/select.rs:360:9 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Option`" +xsv-0.13.0/src/select.rs:375:9 clippy::stable_sort_primitive "used `sort` on primitive type `usize`" +xsv-0.13.0/src/select.rs:379:18 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" +xsv-0.13.0/src/select.rs:416:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +xsv-0.13.0/src/select.rs:419:9 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Option`" +xsv-0.13.0/src/select.rs:420:27 clippy::option_option "consider using `Option` instead of `Option>` or a custom enum if you need to distinguish all 3 cases" +xsv-0.13.0/src/select.rs:99:17 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/util.rs:150:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +xsv-0.13.0/src/util.rs:37:33 clippy::map_clone "you are using an explicit closure for copying elements" +xsv-0.13.0/src/util.rs:90:1 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -- cgit 1.4.1-3-g733a5 From da26b2149f69e977afb9a758307cef1c759570af Mon Sep 17 00:00:00 2001 From: Philipp Hansch Date: Sun, 31 Jan 2021 11:17:37 +0100 Subject: clippy_dev: Pass stderr to CommandFailed --- clippy_dev/src/fmt.rs | 23 +++++++++++++++-------- 1 file changed, 15 insertions(+), 8 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/fmt.rs b/clippy_dev/src/fmt.rs index 6b528d219df..4d0fdadbd85 100644 --- a/clippy_dev/src/fmt.rs +++ b/clippy_dev/src/fmt.rs @@ -8,7 +8,7 @@ use walkdir::WalkDir; #[derive(Debug)] pub enum CliError { - CommandFailed(String), + CommandFailed(String, String), IoError(io::Error), RustfmtNotInstalled, WalkDirError(walkdir::Error), @@ -75,8 +75,8 @@ pub fn run(check: bool, verbose: bool) { fn output_err(err: CliError) { match err { - CliError::CommandFailed(command) => { - eprintln!("error: A command failed! `{}`", command); + CliError::CommandFailed(command, stderr) => { + eprintln!("error: A command failed! `{}`\nstderr: {}", command, stderr); }, CliError::IoError(err) => { eprintln!("error: {}", err); @@ -136,12 +136,16 @@ fn exec( println!("{}", format_command(&program, &dir, args)); } - let mut child = Command::new(&program).current_dir(&dir).args(args.iter()).spawn()?; - let code = child.wait()?; - let success = code.success(); + let child = Command::new(&program).current_dir(&dir).args(args.iter()).spawn()?; + let output = child.wait_with_output()?; + let success = output.status.success(); if !context.check && !success { - return Err(CliError::CommandFailed(format_command(&program, &dir, args))); + let stderr = std::str::from_utf8(&output.stderr).unwrap_or(""); + return Err(CliError::CommandFailed( + format_command(&program, &dir, args), + String::from(stderr), + )); } Ok(success) @@ -177,7 +181,10 @@ fn rustfmt_test(context: &FmtContext) -> Result<(), CliError> { { Err(CliError::RustfmtNotInstalled) } else { - Err(CliError::CommandFailed(format_command(&program, &dir, args))) + Err(CliError::CommandFailed( + format_command(&program, &dir, args), + std::str::from_utf8(&output.stderr).unwrap_or("").to_string(), + )) } } -- cgit 1.4.1-3-g733a5 From bde667af7e7d512978daff3bc2b540bb913bd6a1 Mon Sep 17 00:00:00 2001 From: Caden Haustein Date: Wed, 30 Dec 2020 16:37:59 -0600 Subject: Add missing_panics_doc lint --- CHANGELOG.md | 1 + clippy_dev/src/bless.rs | 3 + clippy_dev/src/lib.rs | 13 +++ clippy_dev/src/ra_setup.rs | 3 + clippy_dev/src/serve.rs | 3 + clippy_lints/src/doc.rs | 125 +++++++++++++++++++++++- clippy_lints/src/lib.rs | 2 + clippy_lints/src/utils/diagnostics.rs | 2 +- mini-macro/src/lib.rs | 3 + tests/ui/doc_panics.rs | 95 ++++++++++++++++++ tests/ui/doc_panics.stderr | 67 +++++++++++++ tests/ui/should_impl_trait/corner_cases.rs | 3 +- tests/ui/should_impl_trait/method_list_1.rs | 3 +- tests/ui/should_impl_trait/method_list_1.stderr | 28 +++--- tests/ui/should_impl_trait/method_list_2.rs | 3 +- tests/ui/should_impl_trait/method_list_2.stderr | 30 +++--- 16 files changed, 346 insertions(+), 38 deletions(-) create mode 100644 tests/ui/doc_panics.rs create mode 100644 tests/ui/doc_panics.stderr (limited to 'clippy_dev/src') diff --git a/CHANGELOG.md b/CHANGELOG.md index dadb6832d1f..c1032204a22 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -2079,6 +2079,7 @@ Released 2018-09-13 [`missing_docs_in_private_items`]: https://rust-lang.github.io/rust-clippy/master/index.html#missing_docs_in_private_items [`missing_errors_doc`]: https://rust-lang.github.io/rust-clippy/master/index.html#missing_errors_doc [`missing_inline_in_public_items`]: https://rust-lang.github.io/rust-clippy/master/index.html#missing_inline_in_public_items +[`missing_panics_doc`]: https://rust-lang.github.io/rust-clippy/master/index.html#missing_panics_doc [`missing_safety_doc`]: https://rust-lang.github.io/rust-clippy/master/index.html#missing_safety_doc [`mistyped_literal_suffixes`]: https://rust-lang.github.io/rust-clippy/master/index.html#mistyped_literal_suffixes [`mixed_case_hex_literals`]: https://rust-lang.github.io/rust-clippy/master/index.html#mixed_case_hex_literals diff --git a/clippy_dev/src/bless.rs b/clippy_dev/src/bless.rs index b877806946c..2a869e9d449 100644 --- a/clippy_dev/src/bless.rs +++ b/clippy_dev/src/bless.rs @@ -24,6 +24,9 @@ static CLIPPY_BUILD_TIME: SyncLazy> = SyncLazy::ne fs::metadata(path).ok()?.modified().ok() }); +/// # Panics +/// +/// Panics if the path to a test file is broken pub fn bless(ignore_timestamp: bool) { let test_suite_dirs = [ clippy_project_root().join("tests").join("ui"), diff --git a/clippy_dev/src/lib.rs b/clippy_dev/src/lib.rs index 24d70d433f3..01d1fc9211a 100644 --- a/clippy_dev/src/lib.rs +++ b/clippy_dev/src/lib.rs @@ -236,6 +236,10 @@ pub struct FileChange { /// `path` is the relative path to the file on which you want to perform the replacement. /// /// See `replace_region_in_text` for documentation of the other options. +/// +/// # Panics +/// +/// Panics if the path could not read or then written pub fn replace_region_in_file( path: &Path, start: &str, @@ -283,6 +287,10 @@ where /// .new_lines; /// assert_eq!("replace_start\na different\ntext\nreplace_end", result); /// ``` +/// +/// # Panics +/// +/// Panics if start or end is not valid regex pub fn replace_region_in_text(text: &str, start: &str, end: &str, replace_start: bool, replacements: F) -> FileChange where F: FnOnce() -> Vec, @@ -329,6 +337,11 @@ where } /// Returns the path to the Clippy project directory +/// +/// # Panics +/// +/// Panics if the current directory could not be retrieved, there was an error reading any of the +/// Cargo.toml files or ancestor directory is the clippy root directory #[must_use] pub fn clippy_project_root() -> PathBuf { let current_dir = std::env::current_dir().unwrap(); diff --git a/clippy_dev/src/ra_setup.rs b/clippy_dev/src/ra_setup.rs index a8a6a2cb1bd..a3c329b578b 100644 --- a/clippy_dev/src/ra_setup.rs +++ b/clippy_dev/src/ra_setup.rs @@ -8,6 +8,9 @@ use std::path::{Path, PathBuf}; // This allows rust analyzer to analyze rustc internals and show proper information inside clippy // code. See https://github.com/rust-analyzer/rust-analyzer/issues/3517 and https://github.com/rust-lang/rust-clippy/issues/5514 for details +/// # Panics +/// +/// Panics if `rustc_path` does not lead to a rustc repo or the files could not be read pub fn run(rustc_path: Option<&str>) { // we can unwrap here because the arg is required by clap let rustc_path = PathBuf::from(rustc_path.unwrap()); diff --git a/clippy_dev/src/serve.rs b/clippy_dev/src/serve.rs index a46c0e4d3f0..faa94859601 100644 --- a/clippy_dev/src/serve.rs +++ b/clippy_dev/src/serve.rs @@ -4,6 +4,9 @@ use std::process::Command; use std::thread; use std::time::{Duration, SystemTime}; +/// # Panics +/// +/// Panics if the python commands could not be spawned pub fn run(port: u16, lint: Option<&str>) -> ! { let mut url = Some(match lint { None => format!("http://localhost:{}", port), diff --git a/clippy_lints/src/doc.rs b/clippy_lints/src/doc.rs index 3a754f49917..b3e3635c1c1 100644 --- a/clippy_lints/src/doc.rs +++ b/clippy_lints/src/doc.rs @@ -1,4 +1,7 @@ -use crate::utils::{implements_trait, is_entrypoint_fn, is_type_diagnostic_item, return_ty, span_lint}; +use crate::utils::{ + implements_trait, is_entrypoint_fn, is_type_diagnostic_item, match_panic_def_id, method_chain_args, return_ty, + span_lint, span_lint_and_note, +}; use if_chain::if_chain; use itertools::Itertools; use rustc_ast::ast::{Async, AttrKind, Attribute, FnRetTy, ItemKind}; @@ -8,7 +11,10 @@ use rustc_data_structures::sync::Lrc; use rustc_errors::emitter::EmitterWriter; use rustc_errors::Handler; use rustc_hir as hir; +use rustc_hir::intravisit::{self, NestedVisitorMap, Visitor}; +use rustc_hir::{Expr, ExprKind, QPath}; use rustc_lint::{LateContext, LateLintPass}; +use rustc_middle::hir::map::Map; use rustc_middle::lint::in_external_macro; use rustc_middle::ty; use rustc_parse::maybe_new_parser_from_source_str; @@ -122,6 +128,37 @@ declare_clippy_lint! { "`pub fn` returns `Result` without `# Errors` in doc comment" } +declare_clippy_lint! { + /// **What it does:** Checks the doc comments of publicly visible functions that + /// may panic and warns if there is no `# Panics` section. + /// + /// **Why is this bad?** Documenting the scenarios in which panicking occurs + /// can help callers who do not want to panic to avoid those situations. + /// + /// **Known problems:** None. + /// + /// **Examples:** + /// + /// Since the following function may panic it has a `# Panics` section in + /// its doc comment: + /// + /// ```rust + /// /// # Panics + /// /// + /// /// Will panic if y is 0 + /// pub fn divide_by(x: i32, y: i32) -> i32 { + /// if y == 0 { + /// panic!("Cannot divide by 0") + /// } else { + /// x / y + /// } + /// } + /// ``` + pub MISSING_PANICS_DOC, + pedantic, + "`pub fn` may panic without `# Panics` in doc comment" +} + declare_clippy_lint! { /// **What it does:** Checks for `fn main() { .. }` in doctests /// @@ -166,7 +203,9 @@ impl DocMarkdown { } } -impl_lint_pass!(DocMarkdown => [DOC_MARKDOWN, MISSING_SAFETY_DOC, MISSING_ERRORS_DOC, NEEDLESS_DOCTEST_MAIN]); +impl_lint_pass!(DocMarkdown => + [DOC_MARKDOWN, MISSING_SAFETY_DOC, MISSING_ERRORS_DOC, MISSING_PANICS_DOC, NEEDLESS_DOCTEST_MAIN] +); impl<'tcx> LateLintPass<'tcx> for DocMarkdown { fn check_crate(&mut self, cx: &LateContext<'tcx>, krate: &'tcx hir::Crate<'_>) { @@ -180,7 +219,15 @@ impl<'tcx> LateLintPass<'tcx> for DocMarkdown { if !(is_entrypoint_fn(cx, cx.tcx.hir().local_def_id(item.hir_id).to_def_id()) || in_external_macro(cx.tcx.sess, item.span)) { - lint_for_missing_headers(cx, item.hir_id, item.span, sig, headers, Some(body_id)); + let body = cx.tcx.hir().body(body_id); + let impl_item_def_id = cx.tcx.hir().local_def_id(item.hir_id); + let mut fpu = FindPanicUnwrap { + cx, + typeck_results: cx.tcx.typeck(impl_item_def_id), + panic_span: None, + }; + fpu.visit_expr(&body.value); + lint_for_missing_headers(cx, item.hir_id, item.span, sig, headers, Some(body_id), fpu.panic_span); } }, hir::ItemKind::Impl(ref impl_) => { @@ -200,7 +247,7 @@ impl<'tcx> LateLintPass<'tcx> for DocMarkdown { let headers = check_attrs(cx, &self.valid_idents, &item.attrs); if let hir::TraitItemKind::Fn(ref sig, ..) = item.kind { if !in_external_macro(cx.tcx.sess, item.span) { - lint_for_missing_headers(cx, item.hir_id, item.span, sig, headers, None); + lint_for_missing_headers(cx, item.hir_id, item.span, sig, headers, None, None); } } } @@ -211,7 +258,15 @@ impl<'tcx> LateLintPass<'tcx> for DocMarkdown { return; } if let hir::ImplItemKind::Fn(ref sig, body_id) = item.kind { - lint_for_missing_headers(cx, item.hir_id, item.span, sig, headers, Some(body_id)); + let body = cx.tcx.hir().body(body_id); + let impl_item_def_id = cx.tcx.hir().local_def_id(item.hir_id); + let mut fpu = FindPanicUnwrap { + cx, + typeck_results: cx.tcx.typeck(impl_item_def_id), + panic_span: None, + }; + fpu.visit_expr(&body.value); + lint_for_missing_headers(cx, item.hir_id, item.span, sig, headers, Some(body_id), fpu.panic_span); } } } @@ -223,6 +278,7 @@ fn lint_for_missing_headers<'tcx>( sig: &hir::FnSig<'_>, headers: DocHeaders, body_id: Option, + panic_span: Option, ) { if !cx.access_levels.is_exported(hir_id) { return; // Private functions do not require doc comments @@ -235,6 +291,16 @@ fn lint_for_missing_headers<'tcx>( "unsafe function's docs miss `# Safety` section", ); } + if !headers.panics && panic_span.is_some() { + span_lint_and_note( + cx, + MISSING_PANICS_DOC, + span, + "docs for function which may panic missing `# Panics` section", + panic_span, + "first possible panic found here", + ); + } if !headers.errors { if is_type_diagnostic_item(cx, return_ty(cx, hir_id), sym::result_type) { span_lint( @@ -321,6 +387,7 @@ pub fn strip_doc_comment_decoration(doc: &str, comment_kind: CommentKind, span: struct DocHeaders { safety: bool, errors: bool, + panics: bool, } fn check_attrs<'a>(cx: &LateContext<'_>, valid_idents: &FxHashSet, attrs: &'a [Attribute]) -> DocHeaders { @@ -338,6 +405,7 @@ fn check_attrs<'a>(cx: &LateContext<'_>, valid_idents: &FxHashSet, attrs return DocHeaders { safety: true, errors: true, + panics: true, }; } } @@ -353,6 +421,7 @@ fn check_attrs<'a>(cx: &LateContext<'_>, valid_idents: &FxHashSet, attrs return DocHeaders { safety: false, errors: false, + panics: false, }; } @@ -394,6 +463,7 @@ fn check_doc<'a, Events: Iterator, Range, Range o, Err(e) => e - 1, @@ -607,3 +678,47 @@ fn check_word(cx: &LateContext<'_>, word: &str, span: Span) { ); } } + +struct FindPanicUnwrap<'a, 'tcx> { + cx: &'a LateContext<'tcx>, + panic_span: Option, + typeck_results: &'tcx ty::TypeckResults<'tcx>, +} + +impl<'a, 'tcx> Visitor<'tcx> for FindPanicUnwrap<'a, 'tcx> { + type Map = Map<'tcx>; + + fn visit_expr(&mut self, expr: &'tcx Expr<'_>) { + if self.panic_span.is_some() { + return; + } + + // check for `begin_panic` + if_chain! { + if let ExprKind::Call(ref func_expr, _) = expr.kind; + if let ExprKind::Path(QPath::Resolved(_, ref path)) = func_expr.kind; + if let Some(path_def_id) = path.res.opt_def_id(); + if match_panic_def_id(self.cx, path_def_id); + then { + self.panic_span = Some(expr.span); + } + } + + // check for `unwrap` + if let Some(arglists) = method_chain_args(expr, &["unwrap"]) { + let reciever_ty = self.typeck_results.expr_ty(&arglists[0][0]).peel_refs(); + if is_type_diagnostic_item(self.cx, reciever_ty, sym::option_type) + || is_type_diagnostic_item(self.cx, reciever_ty, sym::result_type) + { + self.panic_span = Some(expr.span); + } + } + + // and check sub-expressions + intravisit::walk_expr(self, expr); + } + + fn nested_visit_map(&mut self) -> NestedVisitorMap { + NestedVisitorMap::OnlyBodies(self.cx.tcx.hir()) + } +} diff --git a/clippy_lints/src/lib.rs b/clippy_lints/src/lib.rs index 54007c29c6c..5a40c00bd67 100644 --- a/clippy_lints/src/lib.rs +++ b/clippy_lints/src/lib.rs @@ -592,6 +592,7 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf: &disallowed_method::DISALLOWED_METHOD, &doc::DOC_MARKDOWN, &doc::MISSING_ERRORS_DOC, + &doc::MISSING_PANICS_DOC, &doc::MISSING_SAFETY_DOC, &doc::NEEDLESS_DOCTEST_MAIN, &double_comparison::DOUBLE_COMPARISONS, @@ -1317,6 +1318,7 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf: LintId::of(&derive::UNSAFE_DERIVE_DESERIALIZE), LintId::of(&doc::DOC_MARKDOWN), LintId::of(&doc::MISSING_ERRORS_DOC), + LintId::of(&doc::MISSING_PANICS_DOC), LintId::of(&empty_enum::EMPTY_ENUM), LintId::of(&enum_variants::MODULE_NAME_REPETITIONS), LintId::of(&enum_variants::PUB_ENUM_VARIANT_NAMES), diff --git a/clippy_lints/src/utils/diagnostics.rs b/clippy_lints/src/utils/diagnostics.rs index 6caa04f651f..269be217c2d 100644 --- a/clippy_lints/src/utils/diagnostics.rs +++ b/clippy_lints/src/utils/diagnostics.rs @@ -110,7 +110,7 @@ pub fn span_lint_and_help<'a, T: LintContext>( pub fn span_lint_and_note<'a, T: LintContext>( cx: &'a T, lint: &'static Lint, - span: Span, + span: impl Into, msg: &str, note_span: Option, note: &str, diff --git a/mini-macro/src/lib.rs b/mini-macro/src/lib.rs index ba946563ec5..2b793589049 100644 --- a/mini-macro/src/lib.rs +++ b/mini-macro/src/lib.rs @@ -7,6 +7,9 @@ extern crate proc_macro; use proc_macro::{quote, TokenStream}; #[proc_macro_derive(ClippyMiniMacroTest)] +/// # Panics +/// +/// Panics if the macro derivation fails pub fn mini_macro(_: TokenStream) -> TokenStream { quote!( #[allow(unused)] diff --git a/tests/ui/doc_panics.rs b/tests/ui/doc_panics.rs new file mode 100644 index 00000000000..7ef932f367b --- /dev/null +++ b/tests/ui/doc_panics.rs @@ -0,0 +1,95 @@ +#![warn(clippy::missing_panics_doc)] +#![allow(clippy::option_map_unit_fn)] + +fn main() {} + +/// This needs to be documented +pub fn unwrap() { + let result = Err("Hi"); + result.unwrap() +} + +/// This needs to be documented +pub fn panic() { + panic!("This function panics") +} + +/// This needs to be documented +pub fn todo() { + todo!() +} + +/// This needs to be documented +pub fn inner_body(opt: Option) { + opt.map(|x| { + if x == 10 { + panic!() + } + }); +} + +/// This is documented +/// +/// # Panics +/// +/// Panics if `result` if an error +pub fn unwrap_documented() { + let result = Err("Hi"); + result.unwrap() +} + +/// This is documented +/// +/// # Panics +/// +/// Panics just because +pub fn panic_documented() { + panic!("This function panics") +} + +/// This is documented +/// +/// # Panics +/// +/// Panics if `opt` is Just(10) +pub fn inner_body_documented(opt: Option) { + opt.map(|x| { + if x == 10 { + panic!() + } + }); +} + +/// This is documented +/// +/// # Panics +/// +/// We still need to do this part +pub fn todo_documented() { + todo!() +} + +/// This is okay because it is private +fn unwrap_private() { + let result = Err("Hi"); + result.unwrap() +} + +/// This is okay because it is private +fn panic_private() { + panic!("This function panics") +} + +/// This is okay because it is private +fn todo_private() { + todo!() +} + +/// This is okay because it is private +fn inner_body_private(opt: Option) { + opt.map(|x| { + if x == 10 { + panic!() + } + }); +} diff --git a/tests/ui/doc_panics.stderr b/tests/ui/doc_panics.stderr new file mode 100644 index 00000000000..c0c4e9e4fa7 --- /dev/null +++ b/tests/ui/doc_panics.stderr @@ -0,0 +1,67 @@ +error: docs for function which may panic missing `# Panics` section + --> $DIR/doc_panics.rs:7:1 + | +LL | / pub fn unwrap() { +LL | | let result = Err("Hi"); +LL | | result.unwrap() +LL | | } + | |_^ + | + = note: `-D clippy::missing-panics-doc` implied by `-D warnings` +note: first possible panic found here + --> $DIR/doc_panics.rs:9:5 + | +LL | result.unwrap() + | ^^^^^^^^^^^^^^^ + +error: docs for function which may panic missing `# Panics` section + --> $DIR/doc_panics.rs:13:1 + | +LL | / pub fn panic() { +LL | | panic!("This function panics") +LL | | } + | |_^ + | +note: first possible panic found here + --> $DIR/doc_panics.rs:14:5 + | +LL | panic!("This function panics") + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + = note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info) + +error: docs for function which may panic missing `# Panics` section + --> $DIR/doc_panics.rs:18:1 + | +LL | / pub fn todo() { +LL | | todo!() +LL | | } + | |_^ + | +note: first possible panic found here + --> $DIR/doc_panics.rs:19:5 + | +LL | todo!() + | ^^^^^^^ + = note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info) + +error: docs for function which may panic missing `# Panics` section + --> $DIR/doc_panics.rs:23:1 + | +LL | / pub fn inner_body(opt: Option) { +LL | | opt.map(|x| { +LL | | if x == 10 { +LL | | panic!() +LL | | } +LL | | }); +LL | | } + | |_^ + | +note: first possible panic found here + --> $DIR/doc_panics.rs:26:13 + | +LL | panic!() + | ^^^^^^^^ + = note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info) + +error: aborting due to 4 previous errors + diff --git a/tests/ui/should_impl_trait/corner_cases.rs b/tests/ui/should_impl_trait/corner_cases.rs index 6c5ffe6aba8..a7f8f54f2be 100644 --- a/tests/ui/should_impl_trait/corner_cases.rs +++ b/tests/ui/should_impl_trait/corner_cases.rs @@ -8,7 +8,8 @@ clippy::unused_self, clippy::needless_lifetimes, clippy::missing_safety_doc, - clippy::wrong_self_convention + clippy::wrong_self_convention, + clippy::missing_panics_doc )] use std::ops::Mul; diff --git a/tests/ui/should_impl_trait/method_list_1.rs b/tests/ui/should_impl_trait/method_list_1.rs index f8d248fc98d..69a3390b03b 100644 --- a/tests/ui/should_impl_trait/method_list_1.rs +++ b/tests/ui/should_impl_trait/method_list_1.rs @@ -8,7 +8,8 @@ clippy::unused_self, clippy::needless_lifetimes, clippy::missing_safety_doc, - clippy::wrong_self_convention + clippy::wrong_self_convention, + clippy::missing_panics_doc )] use std::ops::Mul; diff --git a/tests/ui/should_impl_trait/method_list_1.stderr b/tests/ui/should_impl_trait/method_list_1.stderr index 2b7d4628c3f..86c63946516 100644 --- a/tests/ui/should_impl_trait/method_list_1.stderr +++ b/tests/ui/should_impl_trait/method_list_1.stderr @@ -1,5 +1,5 @@ error: method `add` can be confused for the standard trait method `std::ops::Add::add` - --> $DIR/method_list_1.rs:25:5 + --> $DIR/method_list_1.rs:26:5 | LL | / pub fn add(self, other: T) -> T { LL | | unimplemented!() @@ -10,7 +10,7 @@ LL | | } = help: consider implementing the trait `std::ops::Add` or choosing a less ambiguous method name error: method `as_mut` can be confused for the standard trait method `std::convert::AsMut::as_mut` - --> $DIR/method_list_1.rs:29:5 + --> $DIR/method_list_1.rs:30:5 | LL | / pub fn as_mut(&mut self) -> &mut T { LL | | unimplemented!() @@ -20,7 +20,7 @@ LL | | } = help: consider implementing the trait `std::convert::AsMut` or choosing a less ambiguous method name error: method `as_ref` can be confused for the standard trait method `std::convert::AsRef::as_ref` - --> $DIR/method_list_1.rs:33:5 + --> $DIR/method_list_1.rs:34:5 | LL | / pub fn as_ref(&self) -> &T { LL | | unimplemented!() @@ -30,7 +30,7 @@ LL | | } = help: consider implementing the trait `std::convert::AsRef` or choosing a less ambiguous method name error: method `bitand` can be confused for the standard trait method `std::ops::BitAnd::bitand` - --> $DIR/method_list_1.rs:37:5 + --> $DIR/method_list_1.rs:38:5 | LL | / pub fn bitand(self, rhs: T) -> T { LL | | unimplemented!() @@ -40,7 +40,7 @@ LL | | } = help: consider implementing the trait `std::ops::BitAnd` or choosing a less ambiguous method name error: method `bitor` can be confused for the standard trait method `std::ops::BitOr::bitor` - --> $DIR/method_list_1.rs:41:5 + --> $DIR/method_list_1.rs:42:5 | LL | / pub fn bitor(self, rhs: Self) -> Self { LL | | unimplemented!() @@ -50,7 +50,7 @@ LL | | } = help: consider implementing the trait `std::ops::BitOr` or choosing a less ambiguous method name error: method `bitxor` can be confused for the standard trait method `std::ops::BitXor::bitxor` - --> $DIR/method_list_1.rs:45:5 + --> $DIR/method_list_1.rs:46:5 | LL | / pub fn bitxor(self, rhs: Self) -> Self { LL | | unimplemented!() @@ -60,7 +60,7 @@ LL | | } = help: consider implementing the trait `std::ops::BitXor` or choosing a less ambiguous method name error: method `borrow` can be confused for the standard trait method `std::borrow::Borrow::borrow` - --> $DIR/method_list_1.rs:49:5 + --> $DIR/method_list_1.rs:50:5 | LL | / pub fn borrow(&self) -> &str { LL | | unimplemented!() @@ -70,7 +70,7 @@ LL | | } = help: consider implementing the trait `std::borrow::Borrow` or choosing a less ambiguous method name error: method `borrow_mut` can be confused for the standard trait method `std::borrow::BorrowMut::borrow_mut` - --> $DIR/method_list_1.rs:53:5 + --> $DIR/method_list_1.rs:54:5 | LL | / pub fn borrow_mut(&mut self) -> &mut str { LL | | unimplemented!() @@ -80,7 +80,7 @@ LL | | } = help: consider implementing the trait `std::borrow::BorrowMut` or choosing a less ambiguous method name error: method `clone` can be confused for the standard trait method `std::clone::Clone::clone` - --> $DIR/method_list_1.rs:57:5 + --> $DIR/method_list_1.rs:58:5 | LL | / pub fn clone(&self) -> Self { LL | | unimplemented!() @@ -90,7 +90,7 @@ LL | | } = help: consider implementing the trait `std::clone::Clone` or choosing a less ambiguous method name error: method `cmp` can be confused for the standard trait method `std::cmp::Ord::cmp` - --> $DIR/method_list_1.rs:61:5 + --> $DIR/method_list_1.rs:62:5 | LL | / pub fn cmp(&self, other: &Self) -> Self { LL | | unimplemented!() @@ -100,7 +100,7 @@ LL | | } = help: consider implementing the trait `std::cmp::Ord` or choosing a less ambiguous method name error: method `deref` can be confused for the standard trait method `std::ops::Deref::deref` - --> $DIR/method_list_1.rs:69:5 + --> $DIR/method_list_1.rs:70:5 | LL | / pub fn deref(&self) -> &Self { LL | | unimplemented!() @@ -110,7 +110,7 @@ LL | | } = help: consider implementing the trait `std::ops::Deref` or choosing a less ambiguous method name error: method `deref_mut` can be confused for the standard trait method `std::ops::DerefMut::deref_mut` - --> $DIR/method_list_1.rs:73:5 + --> $DIR/method_list_1.rs:74:5 | LL | / pub fn deref_mut(&mut self) -> &mut Self { LL | | unimplemented!() @@ -120,7 +120,7 @@ LL | | } = help: consider implementing the trait `std::ops::DerefMut` or choosing a less ambiguous method name error: method `div` can be confused for the standard trait method `std::ops::Div::div` - --> $DIR/method_list_1.rs:77:5 + --> $DIR/method_list_1.rs:78:5 | LL | / pub fn div(self, rhs: Self) -> Self { LL | | unimplemented!() @@ -130,7 +130,7 @@ LL | | } = help: consider implementing the trait `std::ops::Div` or choosing a less ambiguous method name error: method `drop` can be confused for the standard trait method `std::ops::Drop::drop` - --> $DIR/method_list_1.rs:81:5 + --> $DIR/method_list_1.rs:82:5 | LL | / pub fn drop(&mut self) { LL | | unimplemented!() diff --git a/tests/ui/should_impl_trait/method_list_2.rs b/tests/ui/should_impl_trait/method_list_2.rs index ed5e0d384bf..2cdc1a06fe6 100644 --- a/tests/ui/should_impl_trait/method_list_2.rs +++ b/tests/ui/should_impl_trait/method_list_2.rs @@ -8,7 +8,8 @@ clippy::unused_self, clippy::needless_lifetimes, clippy::missing_safety_doc, - clippy::wrong_self_convention + clippy::wrong_self_convention, + clippy::missing_panics_doc )] use std::ops::Mul; diff --git a/tests/ui/should_impl_trait/method_list_2.stderr b/tests/ui/should_impl_trait/method_list_2.stderr index b6fd4356956..0142e299108 100644 --- a/tests/ui/should_impl_trait/method_list_2.stderr +++ b/tests/ui/should_impl_trait/method_list_2.stderr @@ -1,5 +1,5 @@ error: method `eq` can be confused for the standard trait method `std::cmp::PartialEq::eq` - --> $DIR/method_list_2.rs:26:5 + --> $DIR/method_list_2.rs:27:5 | LL | / pub fn eq(&self, other: &Self) -> bool { LL | | unimplemented!() @@ -10,7 +10,7 @@ LL | | } = help: consider implementing the trait `std::cmp::PartialEq` or choosing a less ambiguous method name error: method `from_iter` can be confused for the standard trait method `std::iter::FromIterator::from_iter` - --> $DIR/method_list_2.rs:30:5 + --> $DIR/method_list_2.rs:31:5 | LL | / pub fn from_iter(iter: T) -> Self { LL | | unimplemented!() @@ -20,7 +20,7 @@ LL | | } = help: consider implementing the trait `std::iter::FromIterator` or choosing a less ambiguous method name error: method `from_str` can be confused for the standard trait method `std::str::FromStr::from_str` - --> $DIR/method_list_2.rs:34:5 + --> $DIR/method_list_2.rs:35:5 | LL | / pub fn from_str(s: &str) -> Result { LL | | unimplemented!() @@ -30,7 +30,7 @@ LL | | } = help: consider implementing the trait `std::str::FromStr` or choosing a less ambiguous method name error: method `hash` can be confused for the standard trait method `std::hash::Hash::hash` - --> $DIR/method_list_2.rs:38:5 + --> $DIR/method_list_2.rs:39:5 | LL | / pub fn hash(&self, state: &mut T) { LL | | unimplemented!() @@ -40,7 +40,7 @@ LL | | } = help: consider implementing the trait `std::hash::Hash` or choosing a less ambiguous method name error: method `index` can be confused for the standard trait method `std::ops::Index::index` - --> $DIR/method_list_2.rs:42:5 + --> $DIR/method_list_2.rs:43:5 | LL | / pub fn index(&self, index: usize) -> &Self { LL | | unimplemented!() @@ -50,7 +50,7 @@ LL | | } = help: consider implementing the trait `std::ops::Index` or choosing a less ambiguous method name error: method `index_mut` can be confused for the standard trait method `std::ops::IndexMut::index_mut` - --> $DIR/method_list_2.rs:46:5 + --> $DIR/method_list_2.rs:47:5 | LL | / pub fn index_mut(&mut self, index: usize) -> &mut Self { LL | | unimplemented!() @@ -60,7 +60,7 @@ LL | | } = help: consider implementing the trait `std::ops::IndexMut` or choosing a less ambiguous method name error: method `into_iter` can be confused for the standard trait method `std::iter::IntoIterator::into_iter` - --> $DIR/method_list_2.rs:50:5 + --> $DIR/method_list_2.rs:51:5 | LL | / pub fn into_iter(self) -> Self { LL | | unimplemented!() @@ -70,7 +70,7 @@ LL | | } = help: consider implementing the trait `std::iter::IntoIterator` or choosing a less ambiguous method name error: method `mul` can be confused for the standard trait method `std::ops::Mul::mul` - --> $DIR/method_list_2.rs:54:5 + --> $DIR/method_list_2.rs:55:5 | LL | / pub fn mul(self, rhs: Self) -> Self { LL | | unimplemented!() @@ -80,7 +80,7 @@ LL | | } = help: consider implementing the trait `std::ops::Mul` or choosing a less ambiguous method name error: method `neg` can be confused for the standard trait method `std::ops::Neg::neg` - --> $DIR/method_list_2.rs:58:5 + --> $DIR/method_list_2.rs:59:5 | LL | / pub fn neg(self) -> Self { LL | | unimplemented!() @@ -90,7 +90,7 @@ LL | | } = help: consider implementing the trait `std::ops::Neg` or choosing a less ambiguous method name error: method `next` can be confused for the standard trait method `std::iter::Iterator::next` - --> $DIR/method_list_2.rs:62:5 + --> $DIR/method_list_2.rs:63:5 | LL | / pub fn next(&mut self) -> Option { LL | | unimplemented!() @@ -100,7 +100,7 @@ LL | | } = help: consider implementing the trait `std::iter::Iterator` or choosing a less ambiguous method name error: method `not` can be confused for the standard trait method `std::ops::Not::not` - --> $DIR/method_list_2.rs:66:5 + --> $DIR/method_list_2.rs:67:5 | LL | / pub fn not(self) -> Self { LL | | unimplemented!() @@ -110,7 +110,7 @@ LL | | } = help: consider implementing the trait `std::ops::Not` or choosing a less ambiguous method name error: method `rem` can be confused for the standard trait method `std::ops::Rem::rem` - --> $DIR/method_list_2.rs:70:5 + --> $DIR/method_list_2.rs:71:5 | LL | / pub fn rem(self, rhs: Self) -> Self { LL | | unimplemented!() @@ -120,7 +120,7 @@ LL | | } = help: consider implementing the trait `std::ops::Rem` or choosing a less ambiguous method name error: method `shl` can be confused for the standard trait method `std::ops::Shl::shl` - --> $DIR/method_list_2.rs:74:5 + --> $DIR/method_list_2.rs:75:5 | LL | / pub fn shl(self, rhs: Self) -> Self { LL | | unimplemented!() @@ -130,7 +130,7 @@ LL | | } = help: consider implementing the trait `std::ops::Shl` or choosing a less ambiguous method name error: method `shr` can be confused for the standard trait method `std::ops::Shr::shr` - --> $DIR/method_list_2.rs:78:5 + --> $DIR/method_list_2.rs:79:5 | LL | / pub fn shr(self, rhs: Self) -> Self { LL | | unimplemented!() @@ -140,7 +140,7 @@ LL | | } = help: consider implementing the trait `std::ops::Shr` or choosing a less ambiguous method name error: method `sub` can be confused for the standard trait method `std::ops::Sub::sub` - --> $DIR/method_list_2.rs:82:5 + --> $DIR/method_list_2.rs:83:5 | LL | / pub fn sub(self, rhs: Self) -> Self { LL | | unimplemented!() -- cgit 1.4.1-3-g733a5 From 79dbf10736defbfee05ba95083ba6e2a012f6cef Mon Sep 17 00:00:00 2001 From: flip1995 Date: Fri, 5 Feb 2021 17:23:04 +0100 Subject: Use absolute path to Rust repo in ra_setup This will convert the path to the Rust repo to an absolute path. This is important for the clippy_lints/Cargo.toml file. Otherwise if a relative path is passed, rst-analyzer won't find the Rust repo, because it starts the relative path search from the clippy_lints dir, not the rust-clippy dir where the ra_setup command was run from. --- clippy_dev/src/ra_setup.rs | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/ra_setup.rs b/clippy_dev/src/ra_setup.rs index a3c329b578b..d0e2193ddc5 100644 --- a/clippy_dev/src/ra_setup.rs +++ b/clippy_dev/src/ra_setup.rs @@ -13,7 +13,9 @@ use std::path::{Path, PathBuf}; /// Panics if `rustc_path` does not lead to a rustc repo or the files could not be read pub fn run(rustc_path: Option<&str>) { // we can unwrap here because the arg is required by clap - let rustc_path = PathBuf::from(rustc_path.unwrap()); + let rustc_path = PathBuf::from(rustc_path.unwrap()) + .canonicalize() + .expect("failed to get the absolute repo path"); assert!(rustc_path.is_dir(), "path is not a directory"); let rustc_source_basedir = rustc_path.join("compiler"); assert!( -- cgit 1.4.1-3-g733a5 From 64982cc435fc4546cbdc9ce3935cdd63ac636e4e Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Fri, 5 Feb 2021 23:13:59 +0100 Subject: lintcheck: make TomlCrate also accept git-data from lintcheck_crates.toml --- clippy_dev/lintcheck_crates.toml | 34 +++++++++++++++++----------------- clippy_dev/src/lintcheck.rs | 32 +++++++++++++++++++++----------- 2 files changed, 38 insertions(+), 28 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/lintcheck_crates.toml b/clippy_dev/lintcheck_crates.toml index 1fbf7930d3e..657efb16233 100644 --- a/clippy_dev/lintcheck_crates.toml +++ b/clippy_dev/lintcheck_crates.toml @@ -1,20 +1,20 @@ [crates] # some of these are from cargotest -cargo = ['0.49.0'] -iron = ['0.6.1'] -ripgrep = ['12.1.1'] -xsv = ['0.13.0'] -#tokei = ['12.0.4'] -rayon = ['1.5.0'] -serde = ['1.0.118'] +cargo = {name = "cargo", versions = ['0.49.0']} +iron = {name = "iron", versions = ['0.6.1']} +ripgrep = {name = "ripgrep", versions = ['12.1.1']} +xsv = {name = "xsv", versions = ['0.13.0']} +#tokei = { name = "tokei", versions = ['12.0.4']} +rayon = {name = "rayon", versions = ['1.5.0']} +serde = {name = "serde", versions = ['1.0.118']} # top 10 crates.io dls -bitflags = ['1.2.1'] -libc = ['0.2.81'] -log = ['0.4.11'] -proc-macro2 = ['1.0.24'] -quote = ['1.0.7'] -rand = ['0.7.3'] -rand_core = ['0.6.0'] -regex = ['1.3.2'] -syn = ['1.0.54'] -unicode-xid = ['0.2.1'] +bitflags = {name = "bitflags", versions = ['1.2.1']} +libc = {name = "libc", versions = ['0.2.81']} +log = {name = "log", versions = ['0.4.11']} +proc-macro2 = {name = "proc-macro2", versions = ['1.0.24']} +quote = {name = "quote", versions = ['1.0.7']} +rand = {name = "rand", versions = ['0.7.3']} +rand_core = {name = "rand_core", versions = ['0.6.0']} +regex = {name = "regex", versions = ['1.3.2']} +syn = {name = "syn", versions = ['1.0.54']} +unicode-xid = {name = "unicode-xid", versions = ['0.2.1']} diff --git a/clippy_dev/src/lintcheck.rs b/clippy_dev/src/lintcheck.rs index 785c692d3cb..e3587c7bdfe 100644 --- a/clippy_dev/src/lintcheck.rs +++ b/clippy_dev/src/lintcheck.rs @@ -20,14 +20,17 @@ use serde_json::Value; // use this to store the crates when interacting with the crates.toml file #[derive(Debug, Serialize, Deserialize)] struct CrateList { - crates: HashMap>, + crates: HashMap, } // crate data we stored in the toml, can have multiple versions per crate // A single TomlCrate is laster mapped to several CrateSources in that case +#[derive(Debug, Serialize, Deserialize)] struct TomlCrate { name: String, - versions: Vec, + versions: Option>, + git_url: Option, + git_hash: Option, } // represents an archive we download from crates.io @@ -114,7 +117,7 @@ impl Crate { let shared_target_dir = clippy_project_root().join("target/lintcheck/shared_target_dir/"); - let all_output = std::process::Command::new(cargo_clippy_path) + let all_output = std::process::Command::new(&cargo_clippy_path) .env("CARGO_TARGET_DIR", shared_target_dir) // lint warnings will look like this: // src/cargo/ops/cargo_compile.rs:127:35: warning: usage of `FromIterator::from_iter` @@ -128,7 +131,12 @@ impl Crate { ]) .current_dir(&self.path) .output() - .unwrap(); + .unwrap_or_else(|error| { + dbg!(error); + dbg!(&cargo_clippy_path); + dbg!(&self.path); + panic!("something was not found?") + }); let stdout = String::from_utf8_lossy(&all_output.stdout); let output_lines = stdout.lines(); //dbg!(&output_lines); @@ -160,19 +168,21 @@ fn read_crates() -> Vec { let tomlcrates: Vec = crate_list .crates .into_iter() - .map(|(name, versions)| TomlCrate { name, versions }) + .map(|(_cratename, tomlcrate)| tomlcrate) .collect(); // flatten TomlCrates into CrateSources (one TomlCrates may represent several versions of a crate => // multiple Cratesources) let mut crate_sources = Vec::new(); tomlcrates.into_iter().for_each(|tk| { - tk.versions.iter().for_each(|ver| { - crate_sources.push(CrateSource { - name: tk.name.clone(), - version: ver.to_string(), - }); - }) + if let Some(ref versions) = tk.versions { + versions.iter().for_each(|ver| { + crate_sources.push(CrateSource { + name: tk.name.clone(), + version: ver.to_string(), + }); + }) + } }); crate_sources } -- cgit 1.4.1-3-g733a5 From 10fbafa562b3196dd0cc1b8496e9866e4afab5cb Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Sat, 6 Feb 2021 12:02:42 +0100 Subject: implement the download_and_extract() step for git sources --- clippy_dev/src/lintcheck.rs | 128 ++++++++++++++++++++++++++++++-------------- 1 file changed, 88 insertions(+), 40 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lintcheck.rs b/clippy_dev/src/lintcheck.rs index e3587c7bdfe..63f78db13f8 100644 --- a/clippy_dev/src/lintcheck.rs +++ b/clippy_dev/src/lintcheck.rs @@ -16,6 +16,7 @@ use std::{fmt, fs::write, path::PathBuf}; use clap::ArgMatches; use serde::{Deserialize, Serialize}; use serde_json::Value; +//use git2::Repository; // use this to store the crates when interacting with the crates.toml file #[derive(Debug, Serialize, Deserialize)] @@ -35,12 +36,13 @@ struct TomlCrate { // represents an archive we download from crates.io #[derive(Debug, Serialize, Deserialize, Eq, Hash, PartialEq)] -struct CrateSource { - name: String, - version: String, +enum CrateSource { + CratesIo { name: String, version: String }, + Git { name: String, url: String, commit: String }, } // represents the extracted sourcecode of a crate +// we actually don't need to special-case git repos here because it does not matter for clippy, yay! (clippy only needs a simple path) #[derive(Debug)] struct Crate { version: String, @@ -72,40 +74,70 @@ impl std::fmt::Display for ClippyWarning { impl CrateSource { fn download_and_extract(&self) -> Crate { - let extract_dir = PathBuf::from("target/lintcheck/crates"); - let krate_download_dir = PathBuf::from("target/lintcheck/downloads"); - - // url to download the crate from crates.io - let url = format!( - "https://crates.io/api/v1/crates/{}/{}/download", - self.name, self.version - ); - println!("Downloading and extracting {} {} from {}", self.name, self.version, url); - let _ = std::fs::create_dir("target/lintcheck/"); - let _ = std::fs::create_dir(&krate_download_dir); - let _ = std::fs::create_dir(&extract_dir); - - let krate_file_path = krate_download_dir.join(format!("{}-{}.crate.tar.gz", &self.name, &self.version)); - // don't download/extract if we already have done so - if !krate_file_path.is_file() { - // create a file path to download and write the crate data into - let mut krate_dest = std::fs::File::create(&krate_file_path).unwrap(); - let mut krate_req = ureq::get(&url).call().unwrap().into_reader(); - // copy the crate into the file - std::io::copy(&mut krate_req, &mut krate_dest).unwrap(); - - // unzip the tarball - let ungz_tar = flate2::read::GzDecoder::new(std::fs::File::open(&krate_file_path).unwrap()); - // extract the tar archive - let mut archive = tar::Archive::new(ungz_tar); - archive.unpack(&extract_dir).expect("Failed to extract!"); - } - // crate is extracted, return a new Krate object which contains the path to the extracted - // sources that clippy can check - Crate { - version: self.version.clone(), - name: self.name.clone(), - path: extract_dir.join(format!("{}-{}/", self.name, self.version)), + match self { + CrateSource::CratesIo { name, version } => { + let extract_dir = PathBuf::from("target/lintcheck/crates"); + let krate_download_dir = PathBuf::from("target/lintcheck/downloads"); + + // url to download the crate from crates.io + let url = format!("https://crates.io/api/v1/crates/{}/{}/download", name, version); + println!("Downloading and extracting {} {} from {}", name, version, url); + let _ = std::fs::create_dir("target/lintcheck/"); + let _ = std::fs::create_dir(&krate_download_dir); + let _ = std::fs::create_dir(&extract_dir); + + let krate_file_path = krate_download_dir.join(format!("{}-{}.crate.tar.gz", name, version)); + // don't download/extract if we already have done so + if !krate_file_path.is_file() { + // create a file path to download and write the crate data into + let mut krate_dest = std::fs::File::create(&krate_file_path).unwrap(); + let mut krate_req = ureq::get(&url).call().unwrap().into_reader(); + // copy the crate into the file + std::io::copy(&mut krate_req, &mut krate_dest).unwrap(); + + // unzip the tarball + let ungz_tar = flate2::read::GzDecoder::new(std::fs::File::open(&krate_file_path).unwrap()); + // extract the tar archive + let mut archive = tar::Archive::new(ungz_tar); + archive.unpack(&extract_dir).expect("Failed to extract!"); + } + // crate is extracted, return a new Krate object which contains the path to the extracted + // sources that clippy can check + Crate { + version: version.clone(), + name: name.clone(), + path: extract_dir.join(format!("{}-{}/", name, version)), + } + }, + CrateSource::Git { name, url, commit } => { + let repo_path = { + let mut repo_path = PathBuf::from("target/lintcheck/downloads"); + // add a -git suffix in case we have the same crate from crates.io and a git repo + repo_path.push(format!("{}-git", name)); + repo_path + }; + // clone the repo if we have not done so + if !repo_path.is_dir() { + Command::new("git") + .arg("clone") + .arg(url) + .arg(&repo_path) + .output() + .expect("Failed to clone git repo!"); + } + // check out the commit/branch/whatever + Command::new("git") + .arg("checkout") + .arg(commit) + .output() + .expect("Failed to check out commit"); + + Crate { + version: commit.clone(), + name: name.clone(), + path: repo_path, + } + }, } } } @@ -175,14 +207,30 @@ fn read_crates() -> Vec { // multiple Cratesources) let mut crate_sources = Vec::new(); tomlcrates.into_iter().for_each(|tk| { + // if we have multiple versions, save each one if let Some(ref versions) = tk.versions { versions.iter().for_each(|ver| { - crate_sources.push(CrateSource { + crate_sources.push(CrateSource::CratesIo { name: tk.name.clone(), version: ver.to_string(), }); }) } + // otherwise, we should have a git source + if tk.git_url.is_some() && tk.git_hash.is_some() { + crate_sources.push(CrateSource::Git { + name: tk.name.clone(), + url: tk.git_url.clone().unwrap(), + commit: tk.git_hash.clone().unwrap(), + }); + } + // if we have a version as well as a git data OR only one git data, something is funky + if tk.versions.is_some() && (tk.git_url.is_some() || tk.git_hash.is_some()) + || tk.git_hash.is_some() != tk.git_url.is_some() + { + dbg!(tk); + unreachable!("Failed to translate TomlCrate into CrateSource!"); + } }); crate_sources } @@ -239,13 +287,13 @@ pub fn run(clap_config: &ArgMatches) { let clippy_warnings: Vec = if let Some(only_one_crate) = clap_config.value_of("only") { // if we don't have the specified crated in the .toml, throw an error - if !crates.iter().any(|krate| krate.name == only_one_crate) { + /* if !crates.iter().any(|krate| krate.name == only_one_crate) { eprintln!( "ERROR: could not find crate '{}' in clippy_dev/lintcheck_crates.toml", only_one_crate ); std::process::exit(1); - } + } */ //@FIXME // only check a single crate that was passed via cmdline crates -- cgit 1.4.1-3-g733a5 From 9ab505a3c779c7ad9b078d7d24ace4e3b05d7f1e Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Sat, 6 Feb 2021 11:36:06 +0100 Subject: lintcheck: add git source as an example and update logs --- clippy_dev/lintcheck_crates.toml | 1 + clippy_dev/src/lintcheck.rs | 1 + lintcheck-logs/logs.txt | 82 +++++++++++++++++++++++++++++++++------- 3 files changed, 71 insertions(+), 13 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/lintcheck_crates.toml b/clippy_dev/lintcheck_crates.toml index 657efb16233..c83b4b2ba42 100644 --- a/clippy_dev/lintcheck_crates.toml +++ b/clippy_dev/lintcheck_crates.toml @@ -12,6 +12,7 @@ bitflags = {name = "bitflags", versions = ['1.2.1']} libc = {name = "libc", versions = ['0.2.81']} log = {name = "log", versions = ['0.4.11']} proc-macro2 = {name = "proc-macro2", versions = ['1.0.24']} +puffin = {name = "puffin", git_url = "https://github.com/EmbarkStudios/puffin", git_hash = "02dd4a3"} quote = {name = "quote", versions = ['1.0.7']} rand = {name = "rand", versions = ['0.7.3']} rand_core = {name = "rand_core", versions = ['0.6.0']} diff --git a/clippy_dev/src/lintcheck.rs b/clippy_dev/src/lintcheck.rs index 63f78db13f8..0473b09b1d7 100644 --- a/clippy_dev/src/lintcheck.rs +++ b/clippy_dev/src/lintcheck.rs @@ -118,6 +118,7 @@ impl CrateSource { }; // clone the repo if we have not done so if !repo_path.is_dir() { + println!("Cloning {} and checking out {}", url, commit); Command::new("git") .arg("clone") .arg(url) diff --git a/lintcheck-logs/logs.txt b/lintcheck-logs/logs.txt index 2ba4bd5a021..cee18278b42 100644 --- a/lintcheck-logs/logs.txt +++ b/lintcheck-logs/logs.txt @@ -2086,6 +2086,61 @@ proc-macro2-1.0.24/src/parse.rs:808:15 clippy::explicit_iter_loop "it is more co proc-macro2-1.0.24/src/wrapper.rs:415:24 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" proc-macro2-1.0.24/src/wrapper.rs:429:23 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" proc-macro2-1.0.24/src/wrapper.rs:492:17 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +puffin-02dd4a3/puffin-imgui/src/ui.rs:158:15 clippy::cast_precision_loss "casting `i64` to `f32` causes a loss of precision (`i64` is 64 bits wide, but `f32`'s mantissa is only 23 bits wide)" +puffin-02dd4a3/puffin-imgui/src/ui.rs:175:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +puffin-02dd4a3/puffin-imgui/src/ui.rs:183:5 clippy::too_many_lines "this function has too many lines (115/100)" +puffin-02dd4a3/puffin-imgui/src/ui.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +puffin-02dd4a3/puffin-imgui/src/ui.rs:207:16 clippy::collapsible_else_if "this `else { if .. }` block can be collapsed" +puffin-02dd4a3/puffin-imgui/src/ui.rs:271:67 clippy::cast_precision_loss "casting `i64` to `f32` causes a loss of precision (`i64` is 64 bits wide, but `f32`'s mantissa is only 23 bits wide)" +puffin-02dd4a3/puffin-imgui/src/ui.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +puffin-02dd4a3/puffin-imgui/src/ui.rs:376:29 clippy::cast_precision_loss "casting `i64` to `f32` causes a loss of precision (`i64` is 64 bits wide, but `f32`'s mantissa is only 23 bits wide)" +puffin-02dd4a3/puffin-imgui/src/ui.rs:381:44 clippy::cast_precision_loss "casting `i64` to `f32` causes a loss of precision (`i64` is 64 bits wide, but `f32`'s mantissa is only 23 bits wide)" +puffin-02dd4a3/puffin-imgui/src/ui.rs:453:9 clippy::similar_names "binding's name is too similar to existing binding" +puffin-02dd4a3/puffin-imgui/src/ui.rs:540:14 clippy::cast_possible_truncation "casting `f64` to `f32` may truncate the value" +puffin-02dd4a3/puffin-imgui/src/ui.rs:551:5 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +puffin-02dd4a3/puffin-imgui/src/ui.rs:584:39 clippy::cast_precision_loss "casting `usize` to `f32` causes a loss of precision (`usize` is 32 or 64 bits wide, but `f32`'s mantissa is only 23 bits wide)" +puffin-02dd4a3/puffin-imgui/src/ui.rs:59:26 clippy::unsafe_derive_deserialize "you are deriving `serde::Deserialize` on a type that has methods using `unsafe`" +puffin-02dd4a3/puffin-imgui/src/ui.rs:61:1 clippy::module_name_repetitions "item name ends with its containing module's name" +puffin-02dd4a3/puffin-imgui/src/ui.rs:627:39 clippy::cast_precision_loss "casting `usize` to `f32` causes a loss of precision (`usize` is 32 or 64 bits wide, but `f32`'s mantissa is only 23 bits wide)" +puffin-02dd4a3/puffin-imgui/src/ui.rs:674:47 clippy::cast_precision_loss "casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +puffin-02dd4a3/puffin-imgui/src/ui.rs:690:9 clippy::cast_precision_loss "casting `usize` to `f32` causes a loss of precision (`usize` is 32 or 64 bits wide, but `f32`'s mantissa is only 23 bits wide)" +puffin-02dd4a3/puffin/src/data.rs:102:25 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" +puffin-02dd4a3/puffin/src/data.rs:112:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +puffin-02dd4a3/puffin/src/data.rs:116:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +puffin-02dd4a3/puffin/src/data.rs:137:24 clippy::match_same_arms "this `match` has identical arm bodies" +puffin-02dd4a3/puffin/src/data.rs:177:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +puffin-02dd4a3/puffin/src/data.rs:211:21 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +puffin-02dd4a3/puffin/src/data.rs:24:5 clippy::wildcard_imports "usage of wildcard import" +puffin-02dd4a3/puffin/src/data.rs:75:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +puffin-02dd4a3/puffin/src/lib.rs:113:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +puffin-02dd4a3/puffin/src/lib.rs:147:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +puffin-02dd4a3/puffin/src/lib.rs:147:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +puffin-02dd4a3/puffin/src/lib.rs:165:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +puffin-02dd4a3/puffin/src/lib.rs:200:21 clippy::default_trait_access "calling `Stream::default()` is more clear than this expression" +puffin-02dd4a3/puffin/src/lib.rs:257:78 clippy::default_trait_access "calling `std::cell::RefCell::default()` is more clear than this expression" +puffin-02dd4a3/puffin/src/lib.rs:297:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +puffin-02dd4a3/puffin/src/lib.rs:302:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +puffin-02dd4a3/puffin/src/lib.rs:308:28 clippy::default_trait_access "calling `FullProfileData::default()` is more clear than this expression" +puffin-02dd4a3/puffin/src/lib.rs:316:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +puffin-02dd4a3/puffin/src/lib.rs:321:5 clippy::cast_possible_truncation "casting `u128` to `i64` may truncate the value" +puffin-02dd4a3/puffin/src/lib.rs:348:28 clippy::default_trait_access "calling `std::marker::PhantomData::default()` is more clear than this expression" +puffin-02dd4a3/puffin/src/lib.rs:359:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +puffin-02dd4a3/puffin/src/lib.rs:375:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +puffin-02dd4a3/puffin/src/lib.rs:376:5 clippy::option_if_let_else "use Option::map_or instead of an if let/else" +puffin-02dd4a3/puffin/src/lib.rs:377:9 clippy::option_if_let_else "use Option::map_or instead of an if let/else" +puffin-02dd4a3/puffin/src/lib.rs:406:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +puffin-02dd4a3/puffin/src/lib.rs:408:5 clippy::option_if_let_else "use Option::map_or instead of an if let/else" +puffin-02dd4a3/puffin/src/lib.rs:69:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +puffin-02dd4a3/puffin/src/lib.rs:73:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +puffin-02dd4a3/puffin/src/lib.rs:77:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +puffin-02dd4a3/puffin/src/merge.rs:21:1 clippy::module_name_repetitions "item name starts with its containing module's name" +puffin-02dd4a3/puffin/src/merge.rs:28:1 clippy::module_name_repetitions "item name starts with its containing module's name" +puffin-02dd4a3/puffin/src/merge.rs:28:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +puffin-02dd4a3/puffin/src/merge.rs:35:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +puffin-02dd4a3/puffin/src/merge.rs:35:1 clippy::module_name_repetitions "item name starts with its containing module's name" +puffin-02dd4a3/puffin/src/merge.rs:64:43 clippy::default_trait_access "calling `std::vec::Vec::default()` is more clear than this expression" +puffin-02dd4a3/puffin/src/merge.rs:65:54 clippy::default_trait_access "calling `std::collections::HashMap::default()` is more clear than this expression" +puffin-02dd4a3/puffin/src/merge.rs:9:1 clippy::module_name_repetitions "item name starts with its containing module's name" quote-1.0.7/src/ext.rs:10:1 clippy::module_name_repetitions "item name ends with its containing module's name" quote-1.0.7/src/ext.rs:7:5 clippy::doc_markdown "you should put `TokenStream` between ticks in the documentation" quote-1.0.7/src/ident_fragment.rs:13:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" @@ -3383,6 +3438,7 @@ clippy::should_implement_trait 1 clippy::stable_sort_primitive 1 clippy::unit_arg 1 clippy::unnecessary_lazy_evaluations 1 +clippy::unsafe_derive_deserialize 1 clippy::used_underscore_binding 1 clippy::verbose_bit_mask 1 clippy::while_let_on_iterator 1 @@ -3410,7 +3466,6 @@ clippy::ptr_arg 3 clippy::zero_ptr 3 clippy::let_underscore_drop 4 clippy::too_many_arguments 4 -clippy::collapsible_else_if 5 clippy::explicit_iter_loop 5 clippy::field_reassign_with_default 5 clippy::identity_op 5 @@ -3419,6 +3474,7 @@ clippy::match_like_matches_macro 5 clippy::needless_return 5 clippy::new_without_default 5 clippy::ptr_as_ptr 5 +clippy::collapsible_else_if 6 clippy::manual_strip 6 clippy::non_ascii_literal 6 clippy::single_component_path_imports 6 @@ -3436,12 +3492,11 @@ clippy::missing_safety_doc 10 clippy::needless_doctest_main 10 clippy::multiple_crate_versions 11 clippy::needless_lifetimes 12 -clippy::option_if_let_else 12 clippy::cargo_common_metadata 13 clippy::shadow_unrelated 13 clippy::linkedlist 14 clippy::single_char_add_str 14 -clippy::default_trait_access 16 +clippy::option_if_let_else 15 clippy::needless_pass_by_value 18 clippy::upper_case_acronyms 18 clippy::cast_possible_wrap 19 @@ -3452,26 +3507,27 @@ clippy::unusual_byte_groupings 19 clippy::map_unwrap_or 20 clippy::struct_excessive_bools 20 clippy::redundant_static_lifetimes 21 +clippy::default_trait_access 22 clippy::cast_lossless 23 clippy::trivially_copy_pass_by_ref 26 clippy::redundant_else 29 -clippy::too_many_lines 31 -clippy::cast_precision_loss 35 +clippy::too_many_lines 32 clippy::if_not_else 35 clippy::enum_glob_use 40 clippy::unseparated_literal_suffix 41 +clippy::cast_precision_loss 44 clippy::single_match_else 45 clippy::inline_always 59 -clippy::match_same_arms 64 -clippy::similar_names 77 -clippy::cast_possible_truncation 91 -clippy::missing_panics_doc 106 +clippy::match_same_arms 65 +clippy::similar_names 78 +clippy::cast_possible_truncation 95 +clippy::missing_panics_doc 108 clippy::redundant_field_names 111 clippy::redundant_closure_for_method_calls 135 -clippy::module_name_repetitions 137 clippy::items_after_statements 139 -clippy::wildcard_imports 160 +clippy::module_name_repetitions 142 +clippy::wildcard_imports 163 clippy::doc_markdown 178 -clippy::missing_errors_doc 338 +clippy::missing_errors_doc 343 clippy::unreadable_literal 365 -clippy::must_use_candidate 552 +clippy::must_use_candidate 565 -- cgit 1.4.1-3-g733a5 From e1c284bff74cef5c1684491bc2eb1b0b814332a9 Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Sat, 6 Feb 2021 12:04:31 +0100 Subject: lintcheck: cleanup, fix --only for git crates, better error msgs --- clippy_dev/src/lintcheck.rs | 21 +++++++++++++++------ lintcheck-logs/logs.txt | 6 ++++-- 2 files changed, 19 insertions(+), 8 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lintcheck.rs b/clippy_dev/src/lintcheck.rs index 0473b09b1d7..35c2659952c 100644 --- a/clippy_dev/src/lintcheck.rs +++ b/clippy_dev/src/lintcheck.rs @@ -16,7 +16,6 @@ use std::{fmt, fs::write, path::PathBuf}; use clap::ArgMatches; use serde::{Deserialize, Serialize}; use serde_json::Value; -//use git2::Repository; // use this to store the crates when interacting with the crates.toml file #[derive(Debug, Serialize, Deserialize)] @@ -42,7 +41,8 @@ enum CrateSource { } // represents the extracted sourcecode of a crate -// we actually don't need to special-case git repos here because it does not matter for clippy, yay! (clippy only needs a simple path) +// we actually don't need to special-case git repos here because it does not matter for clippy, yay! +// (clippy only needs a simple path) #[derive(Debug)] struct Crate { version: String, @@ -229,7 +229,10 @@ fn read_crates() -> Vec { if tk.versions.is_some() && (tk.git_url.is_some() || tk.git_hash.is_some()) || tk.git_hash.is_some() != tk.git_url.is_some() { - dbg!(tk); + dbg!(&tk); + if tk.git_hash.is_some() != tk.git_url.is_some() { + panic!("Encountered TomlCrate with only one of git_hash and git_url!") + } unreachable!("Failed to translate TomlCrate into CrateSource!"); } }); @@ -287,14 +290,20 @@ pub fn run(clap_config: &ArgMatches) { let crates = read_crates(); let clippy_warnings: Vec = if let Some(only_one_crate) = clap_config.value_of("only") { - // if we don't have the specified crated in the .toml, throw an error - /* if !crates.iter().any(|krate| krate.name == only_one_crate) { + // if we don't have the specified crate in the .toml, throw an error + if !crates.iter().any(|krate| { + let name = match krate { + CrateSource::CratesIo { name, .. } => name, + CrateSource::Git { name, .. } => name, + }; + name == only_one_crate + }) { eprintln!( "ERROR: could not find crate '{}' in clippy_dev/lintcheck_crates.toml", only_one_crate ); std::process::exit(1); - } */ //@FIXME + } // only check a single crate that was passed via cmdline crates diff --git a/lintcheck-logs/logs.txt b/lintcheck-logs/logs.txt index cee18278b42..3bc7758033b 100644 --- a/lintcheck-logs/logs.txt +++ b/lintcheck-logs/logs.txt @@ -1,4 +1,4 @@ -clippy 0.1.51 (3e4179766 2021-02-03) +clippy 0.1.51 (7f5bb7fd0 2021-02-06) cargo-0.49.0//home/matthias/.rustup/toolchains/nightly-2021-02-03-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/core/src/macros/mod.rs:409:34 clippy::match_same_arms "this `match` has identical arm bodies" cargo-0.49.0/build.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.categories` metadata" @@ -855,6 +855,7 @@ cargo-0.49.0/src/cargo/ops/cargo_install.rs:37:1 clippy::missing_errors_doc "doc cargo-0.49.0/src/cargo/ops/cargo_install.rs:454:22 clippy::redundant_closure_for_method_calls "redundant closure found" cargo-0.49.0/src/cargo/ops/cargo_install.rs:483:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" cargo-0.49.0/src/cargo/ops/cargo_install.rs:683:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_install.rs:708:5 clippy::manual_flatten "unnecessary `if let` since only the `Some` variant of the iterator element is used" cargo-0.49.0/src/cargo/ops/cargo_new.rs:101:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" cargo-0.49.0/src/cargo/ops/cargo_new.rs:245:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" cargo-0.49.0/src/cargo/ops/cargo_new.rs:251:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" @@ -3216,7 +3217,7 @@ ripgrep-12.1.1/crates/core/search.rs:533:5 clippy::cast_precision_loss "casting ripgrep-12.1.1/crates/core/subject.rs:20:1 clippy::module_name_repetitions "item name starts with its containing module's name" ripgrep-12.1.1/crates/core/subject.rs:4:1 clippy::single_component_path_imports "this import is redundant" syn-1.0.54/build.rs:1:null clippy::cargo_common_metadata "package `syn` is missing `package.keywords` metadata" -syn-1.0.54/build.rs:1:null clippy::multiple_crate_versions "could not read cargo metadata: `cargo metadata` exited with an error: Downloading crates ...\n Downloaded httparse v1.3.5\n Downloaded tokio v0.2.25\n Downloaded syn-test-suite v0.0.0\nerror: failed to verify the checksum of `syn-test-suite v0.0.0`" +syn-1.0.54/build.rs:1:null clippy::multiple_crate_versions "could not read cargo metadata: `cargo metadata` exited with an error: Downloading crates ...\n Downloaded syn-test-suite v0.0.0\nerror: failed to verify the checksum of `syn-test-suite v0.0.0`" syn-1.0.54/src/generics.rs:174:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" syn-1.0.54/src/lib.rs:1:null clippy::cargo_common_metadata "package `syn` is missing `package.keywords` metadata" syn-1.0.54/src/lib.rs:1:null clippy::multiple_crate_versions "could not read cargo metadata: `cargo metadata` exited with an error: Downloading crates ...\n Downloaded syn-test-suite v0.0.0\nerror: failed to verify the checksum of `syn-test-suite v0.0.0`" @@ -3425,6 +3426,7 @@ clippy::explicit_deref_methods 1 clippy::from_iter_instead_of_collect 1 clippy::from_over_into 1 clippy::int_plus_one 1 +clippy::manual_flatten 1 clippy::manual_saturating_arithmetic 1 clippy::mem_replace_with_default 1 clippy::nonminimal_bool 1 -- cgit 1.4.1-3-g733a5 From 2bffbfccc1a8e6deba27e6b8753428d999fb0c71 Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Sat, 6 Feb 2021 19:12:28 +0100 Subject: lintcheck: avoid dbg!() calls --- clippy_dev/src/lintcheck.rs | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lintcheck.rs b/clippy_dev/src/lintcheck.rs index 35c2659952c..d73405c9337 100644 --- a/clippy_dev/src/lintcheck.rs +++ b/clippy_dev/src/lintcheck.rs @@ -165,14 +165,15 @@ impl Crate { .current_dir(&self.path) .output() .unwrap_or_else(|error| { - dbg!(error); - dbg!(&cargo_clippy_path); - dbg!(&self.path); - panic!("something was not found?") + panic!( + "Encountered error:\n{:?}\ncargo_clippy_path: {}\ncrate path:{}\n", + error, + &cargo_clippy_path.display(), + &self.path.display() + ); }); let stdout = String::from_utf8_lossy(&all_output.stdout); let output_lines = stdout.lines(); - //dbg!(&output_lines); let warnings: Vec = output_lines .into_iter() // get all clippy warnings @@ -229,7 +230,7 @@ fn read_crates() -> Vec { if tk.versions.is_some() && (tk.git_url.is_some() || tk.git_hash.is_some()) || tk.git_hash.is_some() != tk.git_url.is_some() { - dbg!(&tk); + eprintln!("tomlkrate: {:?}", tk); if tk.git_hash.is_some() != tk.git_url.is_some() { panic!("Encountered TomlCrate with only one of git_hash and git_url!") } -- cgit 1.4.1-3-g733a5 From 40ce05654be9f4f6fb80e295f3eb05bee211cfc7 Mon Sep 17 00:00:00 2001 From: Cameron Steffen Date: Fri, 5 Feb 2021 14:55:09 -0600 Subject: Eat dogfood --- clippy_dev/src/serve.rs | 2 +- clippy_lints/src/macro_use.rs | 2 +- src/main.rs | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/serve.rs b/clippy_dev/src/serve.rs index faa94859601..d13c27a1957 100644 --- a/clippy_dev/src/serve.rs +++ b/clippy_dev/src/serve.rs @@ -34,7 +34,7 @@ pub fn run(port: u16, lint: Option<&str>) -> ! { // Give some time for python to start thread::sleep(Duration::from_millis(500)); // Launch browser after first export.py has completed and http.server is up - let _ = opener::open(url); + let _result = opener::open(url); }); } thread::sleep(Duration::from_millis(1000)); diff --git a/clippy_lints/src/macro_use.rs b/clippy_lints/src/macro_use.rs index bb52888883a..40f04bd677d 100644 --- a/clippy_lints/src/macro_use.rs +++ b/clippy_lints/src/macro_use.rs @@ -160,7 +160,7 @@ impl<'tcx> LateLintPass<'tcx> for MacroUseImports { let found_idx = self.mac_refs.iter().position(|mac| import.ends_with(&mac.name)); if let Some(idx) = found_idx { - let _ = self.mac_refs.remove(idx); + self.mac_refs.remove(idx); let seg = import.split("::").collect::>(); match seg.as_slice() { diff --git a/src/main.rs b/src/main.rs index ea06743394d..b4423ce9ec7 100644 --- a/src/main.rs +++ b/src/main.rs @@ -195,7 +195,7 @@ mod tests { #[should_panic] fn fix_without_unstable() { let args = "cargo clippy --fix".split_whitespace().map(ToString::to_string); - let _ = ClippyCmd::new(args); + ClippyCmd::new(args); } #[test] -- cgit 1.4.1-3-g733a5 From 6f3eeac83c801434bd36e2435c9fafab8af5576c Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Sun, 7 Feb 2021 16:12:21 +0100 Subject: lintcheck: add a cmdline option --crates-toml to override crate sources file to use. Fixes #6691 --- clippy_dev/src/lintcheck.rs | 6 +++--- clippy_dev/src/main.rs | 7 +++++++ 2 files changed, 10 insertions(+), 3 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lintcheck.rs b/clippy_dev/src/lintcheck.rs index d73405c9337..3fc7dcb7d4b 100644 --- a/clippy_dev/src/lintcheck.rs +++ b/clippy_dev/src/lintcheck.rs @@ -192,8 +192,8 @@ fn build_clippy() { } // get a list of CrateSources we want to check from a "lintcheck_crates.toml" file. -fn read_crates() -> Vec { - let toml_path = PathBuf::from("clippy_dev/lintcheck_crates.toml"); +fn read_crates(toml_path: Option<&str>) -> Vec { + let toml_path = PathBuf::from(toml_path.unwrap_or("clippy_dev/lintcheck_crates.toml")); let toml_content: String = std::fs::read_to_string(&toml_path).unwrap_or_else(|_| panic!("Failed to read {}", toml_path.display())); let crate_list: CrateList = @@ -288,7 +288,7 @@ pub fn run(clap_config: &ArgMatches) { // download and extract the crates, then run clippy on them and collect clippys warnings // flatten into one big list of warnings - let crates = read_crates(); + let crates = read_crates(clap_config.value_of("crates-toml")); let clippy_warnings: Vec = if let Some(only_one_crate) = clap_config.value_of("only") { // if we don't have the specified crate in the .toml, throw an error diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index e7a298a37e1..5dbd46935a5 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -62,6 +62,13 @@ fn get_clap_config<'a>() -> ArgMatches<'a> { .value_name("CRATE") .long("only") .help("only process a single crate of the list"), + ) + .arg( + Arg::with_name("crates-toml") + .takes_value(true) + .value_name("CRATES-SOURCES-TOML-PATH") + .long("crates-toml") + .help("set the path for a crates.toml where lintcheck should read the sources from"), ); let app = App::new("Clippy developer tooling") -- cgit 1.4.1-3-g733a5 From c7241b6e5e0666a03ac10f4b48440db10dc748dc Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Tue, 9 Feb 2021 16:27:56 +0100 Subject: lintcheck: make the log file be ${source-file}-logs.txt this allows us to check multiple source.tomls and not worry about overriding our logfiles accidentally --- clippy_dev/src/lintcheck.rs | 11 +- lintcheck-logs/lintcheck_crates_logs.txt | 3535 ++++++++++++++++++++++++++++++ lintcheck-logs/logs.txt | 3535 ------------------------------ 3 files changed, 3542 insertions(+), 3539 deletions(-) create mode 100644 lintcheck-logs/lintcheck_crates_logs.txt delete mode 100644 lintcheck-logs/logs.txt (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lintcheck.rs b/clippy_dev/src/lintcheck.rs index 3fc7dcb7d4b..faf13543f18 100644 --- a/clippy_dev/src/lintcheck.rs +++ b/clippy_dev/src/lintcheck.rs @@ -192,8 +192,10 @@ fn build_clippy() { } // get a list of CrateSources we want to check from a "lintcheck_crates.toml" file. -fn read_crates(toml_path: Option<&str>) -> Vec { +fn read_crates(toml_path: Option<&str>) -> (String, Vec) { let toml_path = PathBuf::from(toml_path.unwrap_or("clippy_dev/lintcheck_crates.toml")); + // save it so that we can use the name of the sources.toml as name for the logfile later. + let toml_filename = toml_path.file_stem().unwrap().to_str().unwrap().to_string(); let toml_content: String = std::fs::read_to_string(&toml_path).unwrap_or_else(|_| panic!("Failed to read {}", toml_path.display())); let crate_list: CrateList = @@ -237,7 +239,7 @@ fn read_crates(toml_path: Option<&str>) -> Vec { unreachable!("Failed to translate TomlCrate into CrateSource!"); } }); - crate_sources + (toml_filename, crate_sources) } // extract interesting data from a json lint message @@ -288,7 +290,7 @@ pub fn run(clap_config: &ArgMatches) { // download and extract the crates, then run clippy on them and collect clippys warnings // flatten into one big list of warnings - let crates = read_crates(clap_config.value_of("crates-toml")); + let (filename, crates) = read_crates(clap_config.value_of("crates-toml")); let clippy_warnings: Vec = if let Some(only_one_crate) = clap_config.value_of("only") { // if we don't have the specified crate in the .toml, throw an error @@ -351,5 +353,6 @@ pub fn run(clap_config: &ArgMatches) { // save the text into lintcheck-logs/logs.txt let mut text = clippy_ver; // clippy version number on top text.push_str(&format!("\n{}", all_msgs.join(""))); - write("lintcheck-logs/logs.txt", text).unwrap(); + let file = format!("lintcheck-logs/{}_logs.txt", filename); + write(file, text).unwrap(); } diff --git a/lintcheck-logs/lintcheck_crates_logs.txt b/lintcheck-logs/lintcheck_crates_logs.txt new file mode 100644 index 00000000000..3bc7758033b --- /dev/null +++ b/lintcheck-logs/lintcheck_crates_logs.txt @@ -0,0 +1,3535 @@ +clippy 0.1.51 (7f5bb7fd0 2021-02-06) + +cargo-0.49.0//home/matthias/.rustup/toolchains/nightly-2021-02-03-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/core/src/macros/mod.rs:409:34 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/build.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.categories` metadata" +cargo-0.49.0/build.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.keywords` metadata" +cargo-0.49.0/src/bin/cargo/cli.rs:104:34 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/bin/cargo/cli.rs:121:5 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo-0.49.0/src/bin/cargo/cli.rs:157:30 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/cli.rs:184:41 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +cargo-0.49.0/src/bin/cargo/cli.rs:196:42 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/cli.rs:200:39 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/cli.rs:231:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo-0.49.0/src/bin/cargo/cli.rs:245:22 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +cargo-0.49.0/src/bin/cargo/cli.rs:247:47 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/cli.rs:257:22 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/cli.rs:26:20 clippy::redundant_else "redundant else block" +cargo-0.49.0/src/bin/cargo/cli.rs:7:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/bench.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/bench.rs:76:59 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/commands/build.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/check.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/clean.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/doc.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/fetch.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/fix.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/generate_lockfile.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/git_checkout.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/help.rs:20:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/bin/cargo/commands/init.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/install.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/install.rs:97:16 clippy::option_if_let_else "use Option::map_or instead of an if let/else" +cargo-0.49.0/src/bin/cargo/commands/locate_project.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/login.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/metadata.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/mod.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/new.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/new.rs:20:24 clippy::option_if_let_else "use Option::map_or instead of an if let/else" +cargo-0.49.0/src/bin/cargo/commands/owner.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/owner.rs:38:43 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/commands/owner.rs:39:43 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/commands/owner.rs:40:43 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/commands/owner.rs:43:30 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/commands/owner.rs:46:30 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/commands/package.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/pkgid.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/publish.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/publish.rs:40:47 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/commands/read_manifest.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/run.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/rustc.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/rustdoc.rs:3:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/search.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/test.rs:127:54 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/commands/test.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/tree.rs:149:49 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/commands/tree.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/uninstall.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/update.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/vendor.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/vendor.rs:96:16 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +cargo-0.49.0/src/bin/cargo/commands/verify_project.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/version.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/yank.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/commands/yank.rs:32:36 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/commands/yank.rs:33:35 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/commands/yank.rs:34:36 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/commands/yank.rs:35:36 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/main.rs:100:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +cargo-0.49.0/src/bin/cargo/main.rs:118:41 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/main.rs:137:43 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/main.rs:148:19 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/bin/cargo/main.rs:174:57 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/main.rs:18:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/bin/cargo/main.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.categories` metadata" +cargo-0.49.0/src/bin/cargo/main.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.keywords` metadata" +cargo-0.49.0/src/bin/cargo/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `crossbeam-utils`: 0.6.6, 0.7.2" +cargo-0.49.0/src/bin/cargo/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `hex`: 0.3.2, 0.4.0" +cargo-0.49.0/src/bin/cargo/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `humantime`: 1.3.0, 2.0.0" +cargo-0.49.0/src/bin/cargo/main.rs:72:22 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/main.rs:94:13 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +cargo-0.49.0/src/bin/cargo/main.rs:96:41 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/main.rs:98:60 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/compiler/build_config.rs:155:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +cargo-0.49.0/src/cargo/core/compiler/build_config.rs:170:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/build_config.rs:175:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/build_config.rs:180:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/build_config.rs:186:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/build_config.rs:197:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/build_config.rs:205:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/build_config.rs:51:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/build_config.rs:69:48 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +cargo-0.49.0/src/cargo/core/compiler/build_config.rs:96:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/build_context/mod.rs:44:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/build_context/mod.rs:83:20 clippy::doc_markdown "you should put `x86_64` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:108:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:121:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:149:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:411:9 clippy::needless_question_mark "Question mark operator is useless here" +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:420:69 clippy::doc_markdown "you should put `mode/target_kind` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:423:19 clippy::doc_markdown "you should put `CrateTypes` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:424:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:424:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:469:58 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:603:19 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:665:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:82:31 clippy::doc_markdown "you should put `FileType` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:83:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:84:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:96:31 clippy::doc_markdown "you should put `FileType` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:98:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/build_plan.rs:4:9 clippy::doc_markdown "you should put `BuildPlan` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/build_plan.rs:5:66 clippy::doc_markdown "you should put `BuildPlan` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/build_plan.rs:66:40 clippy::ptr_arg "writing `&PathBuf` instead of `&Path` involves a new object where a slice will do." +cargo-0.49.0/src/cargo/core/compiler/compilation.rs:150:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/compilation.rs:150:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/core/compiler/compilation.rs:169:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/compilation.rs:185:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/compilation.rs:193:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/compilation.rs:194:49 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/compiler/compilation.rs:198:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/compilation.rs:314:16 clippy::doc_markdown "you should put `rustc_tool` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/compilation.rs:91:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:118:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:123:18 clippy::case_sensitive_file_extension_comparisons "case-sensitive file extension comparison" +cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:147:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:157:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:157:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:33:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:49:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:69:48 clippy::case_sensitive_file_extension_comparisons "case-sensitive file extension comparison" +cargo-0.49.0/src/cargo/core/compiler/context/compilation_files.rs:204:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/core/compiler/context/compilation_files.rs:277:22 clippy::doc_markdown "you should put `OUT_DIR` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/context/compilation_files.rs:324:66 clippy::doc_markdown "you should put `FileType` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/context/compilation_files.rs:393:37 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/compiler/context/compilation_files.rs:426:71 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:125:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:125:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:125:5 clippy::too_many_lines "this function has too many lines (107/100)" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:270:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:286:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:308:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:308:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:340:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:340:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:349:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:349:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:354:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:358:21 clippy::doc_markdown "you should put `RunCustomBuild` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:361:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:374:43 clippy::doc_markdown "you should put `RunCustomBuild` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:378:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:383:41 clippy::doc_markdown "you should put `RunCustomBuild` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:384:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:384:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:391:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:397:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:523:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:538:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:542:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:83:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:92:25 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/core/compiler/crate_type.rs:16:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/crate_type.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/crate_type.rs:40:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/crate_type.rs:49:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/crate_type.rs:60:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:150:1 clippy::too_many_lines "this function has too many lines (230/100)" +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:353:56 clippy::manual_strip "stripping a prefix manually" +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:448:27 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:464:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:481:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:481:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:48:56 clippy::doc_markdown "you should put `RunCustomBuild` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:561:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:561:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:567:20 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:576:28 clippy::shadow_unrelated "`mut value` is being shadowed" +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:606:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:688:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:756:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:762:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:762:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:823:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1021:51 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1656:16 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1664:5 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1787:5 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1795:5 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1882:17 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1894:17 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1906:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1917:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1923:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1956:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1962:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1963:22 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1964:22 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1965:22 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1966:22 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1980:17 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1980:24 clippy::manual_strip "stripping a prefix manually" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1986:17 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:2016:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:61:5 clippy::doc_markdown "you should put `CompileMode` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:63:12 clippy::doc_markdown "you should put `CompileKind` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:67:7 clippy::doc_markdown "you should put `CARGO_DEFAULT_LIB_METADATA[^4` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:68:5 clippy::doc_markdown "you should put `package_id` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:71:19 clippy::doc_markdown "you should put `test/bench/for_host/edition` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:755:52 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:77:5 clippy::doc_markdown "you should put `is_std` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:816:5 clippy::too_many_lines "this function has too many lines (127/100)" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:863:64 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:875:33 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:876:32 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:896:30 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:897:30 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:991:37 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:12:5 clippy::doc_markdown "you should put `src/librustc_jobserver/lib.rs` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:329:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:332:23 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:34:53 clippy::doc_markdown "you should put `NeedsToken` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:35:6 clippy::doc_markdown "you should put `ReleaseToken` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:37:6 clippy::doc_markdown "you should put `NeedsToken` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:40:5 clippy::doc_markdown "you should put `NeedsToken` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:40:56 clippy::doc_markdown "you should put `NeedsToken` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:43:6 clippy::doc_markdown "you should put `ReleaseToken` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:748:16 clippy::collapsible_else_if "this `else { if .. }` block can be collapsed" +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:749:13 clippy::if_not_else "unnecessary boolean `not` operation" +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:786:26 clippy::unused_self "unused `self` argument" +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:81:61 clippy::doc_markdown "you should put `DrainState` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:865:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:871:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:890:9 clippy::unused_self "unused `self` argument" +cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:93:24 clippy::doc_markdown "you should put `JobQueue` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/links.rs:8:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:1016:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:1094:19 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:1131:1 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:1268:34 clippy::case_sensitive_file_extension_comparisons "case-sensitive file extension comparison" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:1277:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:179:1 clippy::too_many_lines "this function has too many lines (162/100)" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:198:78 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:201:25 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:267:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:324:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:364:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:364:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:392:45 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:415:23 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:464:18 clippy::ptr_arg "writing `&PathBuf` instead of `&Path` involves a new object where a slice will do." +cargo-0.49.0/src/cargo/core/compiler/mod.rs:488:61 clippy::ptr_arg "writing `&PathBuf` instead of `&Path` involves a new object where a slice will do." +cargo-0.49.0/src/cargo/core/compiler/mod.rs:667:15 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:693:1 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:725:42 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:736:1 clippy::too_many_lines "this function has too many lines (141/100)" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:73:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:777:12 clippy::if_not_else "unnecessary boolean `not` operation" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:873:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/compiler/output_depinfo.rs:41:13 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +cargo-0.49.0/src/cargo/core/compiler/rustdoc.rs:16:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/core/compiler/rustdoc.rs:57:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/core/compiler/rustdoc.rs:72:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/standard_lib.rs:134:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/standard_lib.rs:16:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/standard_lib.rs:30:28 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/compiler/standard_lib.rs:34:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/standard_lib.rs:34:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/core/compiler/timings.rs:16:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo-0.49.0/src/cargo/core/compiler/timings.rs:192:64 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo-0.49.0/src/cargo/core/compiler/timings.rs:212:58 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo-0.49.0/src/cargo/core/compiler/timings.rs:234:13 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" +cargo-0.49.0/src/cargo/core/compiler/timings.rs:355:13 clippy::cast_possible_truncation "casting `f64` to `u32` may truncate the value" +cargo-0.49.0/src/cargo/core/compiler/timings.rs:355:13 clippy::cast_sign_loss "casting `f64` to `u32` may lose the sign of the value" +cargo-0.49.0/src/cargo/core/compiler/timings.rs:397:38 clippy::cast_possible_truncation "casting `f64` to `u32` may truncate the value" +cargo-0.49.0/src/cargo/core/compiler/timings.rs:397:38 clippy::cast_sign_loss "casting `f64` to `u32` may lose the sign of the value" +cargo-0.49.0/src/cargo/core/compiler/timings.rs:484:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/compiler/timings.rs:605:38 clippy::doc_markdown "you should put `rmeta_time` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/timings.rs:605:50 clippy::doc_markdown "you should put `codegen_time` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/timings.rs:641:26 clippy::non_ascii_literal "literal non-ASCII character detected" +cargo-0.49.0/src/cargo/core/compiler/unit.rs:100:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/unit.rs:151:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/core/compiler/unit.rs:161:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/compiler/unit.rs:35:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/core/compiler/unit_dependencies.rs:154:29 clippy::doc_markdown "you should put `state.unit_dependencies` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/compiler/unit_dependencies.rs:213:1 clippy::too_many_lines "this function has too many lines (110/100)" +cargo-0.49.0/src/cargo/core/compiler/unit_dependencies.rs:52:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/unit_dependencies.rs:52:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/core/compiler/unit_graph.rs:65:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/unit_graph.rs:65:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/core/dependency.rs:157:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/dependency.rs:182:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/dependency.rs:203:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/core/dependency.rs:203:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/dependency.rs:224:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/dependency.rs:23:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo-0.49.0/src/cargo/core/dependency.rs:248:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/dependency.rs:270:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/dependency.rs:274:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/dependency.rs:278:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/dependency.rs:287:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/dependency.rs:291:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/dependency.rs:296:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/core/dependency.rs:305:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/dependency.rs:311:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/dependency.rs:319:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/dependency.rs:323:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/core/dependency.rs:337:75 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/dependency.rs:379:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/core/dependency.rs:397:56 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/dependency.rs:403:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/dependency.rs:408:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/dependency.rs:415:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/dependency.rs:419:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/dependency.rs:424:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/dependency.rs:428:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/dependency.rs:433:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/dependency.rs:438:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/dependency.rs:443:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/dependency.rs:449:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/dependency.rs:450:9 clippy::if_not_else "unnecessary `!=` operation" +cargo-0.49.0/src/cargo/core/features.rs:119:17 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/features.rs:229:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/features.rs:274:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/features.rs:278:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/features.rs:306:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/features.rs:338:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo-0.49.0/src/cargo/core/features.rs:362:25 clippy::option_option "consider using `Option` instead of `Option>` or a custom enum if you need to distinguish all 3 cases" +cargo-0.49.0/src/cargo/core/features.rs:380:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/features.rs:401:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/features.rs:409:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/features.rs:412:45 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/features.rs:416:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/features.rs:419:45 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/features.rs:424:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/features.rs:431:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/features.rs:477:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/features.rs:509:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/features.rs:518:5 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +cargo-0.49.0/src/cargo/core/features.rs:542:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/features.rs:543:37 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/features.rs:547:60 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/features.rs:556:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/core/features.rs:563:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/core/manifest.rs:116:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +cargo-0.49.0/src/cargo/core/manifest.rs:118:58 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/manifest.rs:130:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +cargo-0.49.0/src/cargo/core/manifest.rs:143:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:159:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:162:34 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/manifest.rs:169:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:17:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/cargo/core/manifest.rs:189:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo-0.49.0/src/cargo/core/manifest.rs:215:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:222:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:22:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/core/manifest.rs:360:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:407:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:410:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:413:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:416:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:419:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:422:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:425:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:431:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:438:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:444:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:447:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:450:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:453:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:456:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:459:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:462:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:466:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:470:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:477:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:481:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:488:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/manifest.rs:512:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:516:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:520:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:524:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:528:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:538:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:557:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:561:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:565:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:569:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:577:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:581:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:588:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:617:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:632:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:648:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:659:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:66:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/core/manifest.rs:670:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:693:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:708:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:723:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:726:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:729:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:735:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:738:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:741:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:744:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:747:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:751:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:754:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:757:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:760:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:763:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:767:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:776:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:780:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:787:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:798:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:800:56 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/manifest.rs:805:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:809:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:818:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:823:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:828:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:831:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:834:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:839:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:85:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/core/manifest.rs:888:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/manifest.rs:936:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package.rs:1075:28 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/package.rs:160:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package.rs:170:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package.rs:174:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package.rs:182:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package.rs:186:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package.rs:190:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package.rs:194:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/core/package.rs:194:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package.rs:198:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package.rs:202:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package.rs:206:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package.rs:210:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package.rs:217:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package.rs:221:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package.rs:222:35 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/package.rs:226:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package.rs:227:35 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/package.rs:230:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package.rs:239:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/package.rs:249:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package.rs:287:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/core/package.rs:385:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/package.rs:421:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +cargo-0.49.0/src/cargo/core/package.rs:425:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/package.rs:425:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/core/package.rs:452:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/package.rs:453:60 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/package.rs:459:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/package.rs:473:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/package.rs:552:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/core/package.rs:587:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/package.rs:588:9 clippy::needless_question_mark "Question mark operator is useless here" +cargo-0.49.0/src/cargo/core/package.rs:682:46 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" +cargo-0.49.0/src/cargo/core/package.rs:682:46 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" +cargo-0.49.0/src/cargo/core/package.rs:682:63 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" +cargo-0.49.0/src/cargo/core/package.rs:682:63 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" +cargo-0.49.0/src/cargo/core/package.rs:731:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/package.rs:790:13 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/core/package.rs:988:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/core/package_id.rs:115:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/package_id.rs:124:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/core/package_id.rs:124:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package_id.rs:139:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package_id.rs:142:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package_id.rs:145:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package_id.rs:149:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package_id.rs:157:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package_id.rs:161:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package_id.rs:169:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package_id.rs:174:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/core/package_id_spec.rs:101:39 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/package_id_spec.rs:143:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package_id_spec.rs:147:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package_id_spec.rs:151:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package_id_spec.rs:160:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/package_id_spec.rs:179:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/package_id_spec.rs:212:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/package_id_spec.rs:231:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/core/package_id_spec.rs:51:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/package_id_spec.rs:51:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/core/package_id_spec.rs:77:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/package_id_spec.rs:88:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/profiles.rs:1004:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/core/profiles.rs:1004:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/profiles.rs:1014:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/profiles.rs:1018:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/profiles.rs:1028:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/profiles.rs:106:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/profiles.rs:143:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo-0.49.0/src/cargo/core/profiles.rs:286:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/core/profiles.rs:286:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/profiles.rs:294:40 clippy::if_not_else "unnecessary boolean `not` operation" +cargo-0.49.0/src/cargo/core/profiles.rs:30:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/profiles.rs:342:25 clippy::shadow_unrelated "`maker` is being shadowed" +cargo-0.49.0/src/cargo/core/profiles.rs:370:41 clippy::unused_self "unused `self` argument" +cargo-0.49.0/src/cargo/core/profiles.rs:370:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/profiles.rs:372:9 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" +cargo-0.49.0/src/cargo/core/profiles.rs:382:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/core/profiles.rs:382:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/profiles.rs:383:28 clippy::if_not_else "unnecessary boolean `not` operation" +cargo-0.49.0/src/cargo/core/profiles.rs:397:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/profiles.rs:405:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/profiles.rs:607:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo-0.49.0/src/cargo/core/profiles.rs:909:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/profiles.rs:923:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/profiles.rs:934:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/profiles.rs:987:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/registry.rs:111:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/registry.rs:127:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/registry.rs:168:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/registry.rs:19:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/registry.rs:240:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/registry.rs:26:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/registry.rs:344:49 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/registry.rs:358:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/core/registry.rs:369:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/registry.rs:424:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/core/registry.rs:424:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/registry.rs:49:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/core/registry.rs:520:17 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/core/registry.rs:763:53 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/registry.rs:765:53 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/registry.rs:807:14 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/registry.rs:814:53 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/resolver/conflict_cache.rs:197:29 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/resolver/conflict_cache.rs:41:38 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +cargo-0.49.0/src/cargo/core/resolver/context.rs:274:53 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/resolver/context.rs:42:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/core/resolver/context.rs:74:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/encode.rs:156:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/resolver/encode.rs:156:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/core/resolver/encode.rs:156:5 clippy::too_many_lines "this function has too many lines (164/100)" +cargo-0.49.0/src/cargo/core/resolver/encode.rs:339:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +cargo-0.49.0/src/cargo/core/resolver/encode.rs:438:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/resolver/encode.rs:449:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/resolver/encode.rs:529:34 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/resolver/encode.rs:602:59 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/resolver/encode.rs:623:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/core/resolver/encode.rs:652:27 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/core/resolver/encode.rs:674:51 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/resolver/errors.rs:103:22 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/resolver/errors.rs:104:22 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/resolver/errors.rs:206:9 clippy::if_not_else "unnecessary boolean `not` operation" +cargo-0.49.0/src/cargo/core/resolver/errors.rs:257:45 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/resolver/errors.rs:27:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/errors.rs:305:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo-0.49.0/src/cargo/core/resolver/errors.rs:70:1 clippy::too_many_lines "this function has too many lines (207/100)" +cargo-0.49.0/src/cargo/core/resolver/features.rs:104:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/core/resolver/features.rs:111:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/features.rs:162:56 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/resolver/features.rs:179:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/core/resolver/features.rs:186:23 clippy::doc_markdown "you should put `RequestedFeatures` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/resolver/features.rs:187:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/features.rs:199:23 clippy::doc_markdown "you should put `RequestedFeatures` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/resolver/features.rs:200:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/features.rs:221:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/features.rs:231:21 clippy::doc_markdown "you should put `pkg_id/is_build` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/resolver/features.rs:233:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/features.rs:247:58 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/resolver/features.rs:278:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/resolver/features.rs:394:27 clippy::doc_markdown "you should put `FeatureValue` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/resolver/features.rs:460:19 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/core/resolver/features.rs:480:24 clippy::doc_markdown "you should put `FeatureValues` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/resolver/features.rs:496:24 clippy::doc_markdown "you should put `FeatureValues` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/resolver/features.rs:58:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/core/resolver/features.rs:67:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo-0.49.0/src/cargo/core/resolver/mod.rs:1017:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/core/resolver/mod.rs:1045:57 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/resolver/mod.rs:122:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/resolver/mod.rs:142:44 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/resolver/mod.rs:180:1 clippy::too_many_lines "this function has too many lines (225/100)" +cargo-0.49.0/src/cargo/core/resolver/mod.rs:311:17 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/core/resolver/mod.rs:421:52 clippy::filter_map_next "called `filter_map(..).next()` on an `Iterator`. This is more succinctly expressed by calling `.find_map(..)` instead." +cargo-0.49.0/src/cargo/core/resolver/mod.rs:457:69 clippy::filter_map_next "called `filter_map(..).next()` on an `Iterator`. This is more succinctly expressed by calling `.find_map(..)` instead." +cargo-0.49.0/src/cargo/core/resolver/mod.rs:470:37 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/core/resolver/mod.rs:607:11 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo-0.49.0/src/cargo/core/resolver/mod.rs:631:21 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/core/resolver/mod.rs:942:15 clippy::if_not_else "unnecessary boolean `not` operation" +cargo-0.49.0/src/cargo/core/resolver/mod.rs:988:20 clippy::redundant_else "redundant else block" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:120:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:132:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:199:24 clippy::redundant_else "redundant else block" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:235:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:239:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:255:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:259:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:263:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:269:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:273:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:273:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:274:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:280:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:284:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:288:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:292:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:296:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:300:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:315:13 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:354:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:362:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:60:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/core/resolver/resolve.rs:76:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/types.rs:111:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/resolver/types.rs:121:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/types.rs:141:19 clippy::doc_markdown "you should put `ResolveOpts` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/resolver/types.rs:142:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/types.rs:149:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/resolver/types.rs:181:9 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +cargo-0.49.0/src/cargo/core/resolver/types.rs:187:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +cargo-0.49.0/src/cargo/core/resolver/types.rs:261:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +cargo-0.49.0/src/cargo/core/shell.rs:113:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/shell.rs:130:9 clippy::single_match_else "you seem to be trying to use `match` for an equality check. Consider using `if`" +cargo-0.49.0/src/cargo/core/shell.rs:148:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/shell.rs:153:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/shell.rs:163:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/shell.rs:18:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/shell.rs:198:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/shell.rs:206:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/shell.rs:214:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/shell.rs:228:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/shell.rs:239:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/shell.rs:250:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/shell.rs:259:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/shell.rs:267:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/shell.rs:26:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/shell.rs:277:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/shell.rs:282:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/shell.rs:314:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/shell.rs:322:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/shell.rs:330:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/shell.rs:345:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/core/shell.rs:98:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/source/mod.rs:103:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/source/mod.rs:247:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/core/source/mod.rs:261:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/source/mod.rs:268:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/source/mod.rs:273:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/source/mod.rs:291:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/source/mod.rs:302:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/source/mod.rs:307:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/source/mod.rs:31:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/source/mod.rs:37:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/source/mod.rs:39:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/source/mod.rs:47:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/source/mod.rs:50:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/source/mod.rs:52:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/source/mod.rs:63:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/source/mod.rs:74:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/source/mod.rs:83:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/source/source_id.rs:107:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/source/source_id.rs:107:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/core/source/source_id.rs:128:50 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/source/source_id.rs:147:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/source/source_id.rs:156:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/source/source_id.rs:162:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/source/source_id.rs:166:19 clippy::doc_markdown "you should put `SourceId` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/source/source_id.rs:167:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/source/source_id.rs:171:19 clippy::doc_markdown "you should put `SourceId` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/source/source_id.rs:172:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/source/source_id.rs:178:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/source/source_id.rs:187:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/source/source_id.rs:187:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/core/source/source_id.rs:18:74 clippy::default_trait_access "calling `std::sync::Mutex::default()` is more clear than this expression" +cargo-0.49.0/src/cargo/core/source/source_id.rs:195:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/source/source_id.rs:207:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/source/source_id.rs:213:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/source/source_id.rs:217:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/source/source_id.rs:225:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/source/source_id.rs:228:16 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" +cargo-0.49.0/src/cargo/core/source/source_id.rs:236:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/source/source_id.rs:241:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/source/source_id.rs:252:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/source/source_id.rs:257:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/source/source_id.rs:262:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/source/source_id.rs:262:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/core/source/source_id.rs:305:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/source/source_id.rs:310:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/source/source_id.rs:318:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/source/source_id.rs:326:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/source/source_id.rs:338:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/core/source/source_id.rs:355:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/source/source_id.rs:393:61 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:394:42 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:395:42 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:397:71 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:397:71 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:398:47 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:398:47 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:399:47 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:399:47 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:401:63 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:401:63 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:401:63 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:402:43 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:402:43 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:402:43 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:403:43 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:403:43 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:403:43 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:406:21 clippy::enum_glob_use "usage of wildcard import for enum variants" +cargo-0.49.0/src/cargo/core/source/source_id.rs:412:41 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:413:36 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:414:36 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:420:47 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:420:47 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/source/source_id.rs:512:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo-0.49.0/src/cargo/core/source/source_id.rs:513:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo-0.49.0/src/cargo/core/source/source_id.rs:517:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo-0.49.0/src/cargo/core/source/source_id.rs:518:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo-0.49.0/src/cargo/core/source/source_id.rs:525:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo-0.49.0/src/cargo/core/source/source_id.rs:526:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo-0.49.0/src/cargo/core/source/source_id.rs:530:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo-0.49.0/src/cargo/core/source/source_id.rs:531:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo-0.49.0/src/cargo/core/source/source_id.rs:535:33 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo-0.49.0/src/cargo/core/source/source_id.rs:536:37 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo-0.49.0/src/cargo/core/source/source_id.rs:537:42 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo-0.49.0/src/cargo/core/source/source_id.rs:538:38 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo-0.49.0/src/cargo/core/source/source_id.rs:548:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/core/source/source_id.rs:597:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/summary.rs:103:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/summary.rs:123:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/summary.rs:150:1 clippy::too_many_lines "this function has too many lines (141/100)" +cargo-0.49.0/src/cargo/core/summary.rs:158:9 clippy::enum_glob_use "usage of wildcard import for enum variants" +cargo-0.49.0/src/cargo/core/summary.rs:181:21 clippy::if_not_else "unnecessary boolean `not` operation" +cargo-0.49.0/src/cargo/core/summary.rs:192:28 clippy::redundant_else "redundant else block" +cargo-0.49.0/src/cargo/core/summary.rs:258:32 clippy::redundant_else "redundant else block" +cargo-0.49.0/src/cargo/core/summary.rs:281:28 clippy::redundant_else "redundant else block" +cargo-0.49.0/src/cargo/core/summary.rs:303:28 clippy::redundant_else "redundant else block" +cargo-0.49.0/src/cargo/core/summary.rs:321:51 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/core/summary.rs:344:5 clippy::doc_markdown "you should put `FeatureValue` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/summary.rs:350:85 clippy::doc_markdown "you should put `FeatureValue` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/summary.rs:36:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/summary.rs:378:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/summary.rs:386:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/summary.rs:387:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +cargo-0.49.0/src/cargo/core/summary.rs:407:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +cargo-0.49.0/src/cargo/core/summary.rs:69:34 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/summary.rs:75:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/summary.rs:78:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/summary.rs:81:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/summary.rs:84:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/summary.rs:87:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/summary.rs:90:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/summary.rs:93:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/summary.rs:96:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/summary.rs:99:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/workspace.rs:1056:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo-0.49.0/src/cargo/core/workspace.rs:113:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/core/workspace.rs:1157:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/core/workspace.rs:128:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/core/workspace.rs:150:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/workspace.rs:159:16 clippy::redundant_else "redundant else block" +cargo-0.49.0/src/cargo/core/workspace.rs:197:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/workspace.rs:225:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/workspace.rs:225:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/core/workspace.rs:255:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/workspace.rs:267:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/workspace.rs:317:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/core/workspace.rs:329:37 clippy::doc_markdown "you should put `VirtualManifest` between ticks in the documentation" +cargo-0.49.0/src/cargo/core/workspace.rs:410:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/workspace.rs:440:9 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo-0.49.0/src/cargo/core/workspace.rs:511:32 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/core/workspace.rs:561:25 clippy::non_ascii_literal "literal non-ASCII character detected" +cargo-0.49.0/src/cargo/core/workspace.rs:613:13 clippy::filter_map "called `filter_map(..).map(..)` on an `Iterator`" +cargo-0.49.0/src/cargo/core/workspace.rs:615:22 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/core/workspace.rs:762:27 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/core/workspace.rs:784:17 clippy::if_not_else "unnecessary boolean `not` operation" +cargo-0.49.0/src/cargo/core/workspace.rs:849:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/workspace.rs:849:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/core/workspace.rs:893:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/workspace.rs:906:24 clippy::redundant_else "redundant else block" +cargo-0.49.0/src/cargo/core/workspace.rs:932:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/workspace.rs:932:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/lib.rs:177:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/lib.rs:177:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/lib.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.categories` metadata" +cargo-0.49.0/src/cargo/lib.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.keywords` metadata" +cargo-0.49.0/src/cargo/lib.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `crossbeam-utils`: 0.6.6, 0.7.2" +cargo-0.49.0/src/cargo/lib.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `hex`: 0.3.2, 0.4.0" +cargo-0.49.0/src/cargo/lib.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `humantime`: 1.3.0, 2.0.0" +cargo-0.49.0/src/cargo/ops/cargo_clean.rs:205:23 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/ops/cargo_clean.rs:27:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_clean.rs:27:1 clippy::too_many_lines "this function has too many lines (120/100)" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:1078:14 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:109:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:119:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:1227:17 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:127:35 clippy::from_iter_instead_of_collect "usage of `FromIterator::from_iter`" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:173:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:205:36 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:242:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:249:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:258:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:267:16 clippy::needless_question_mark "Question mark operator is useless here" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:275:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:275:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:275:1 clippy::too_many_lines "this function has too many lines (219/100)" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:468:9 clippy::default_trait_access "calling `std::collections::HashMap::default()` is more clear than this expression" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:548:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:556:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:574:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:583:21 clippy::doc_markdown "you should put `CompileFilter` between ticks in the documentation" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:584:5 clippy::fn_params_excessive_bools "more than 3 bools in function parameters" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:584:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:592:9 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:593:9 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:607:13 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:612:21 clippy::doc_markdown "you should put `CompileFilter` between ticks in the documentation" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:613:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:618:9 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:641:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:652:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:652:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:655:50 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:673:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:692:49 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:703:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:729:1 clippy::too_many_lines "this function has too many lines (205/100)" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:82:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_compile.rs:874:69 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/ops/cargo_doc.rs:20:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_fetch.rs:15:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_fetch.rs:27:46 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:160:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:175:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:22:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:37:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:37:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:37:1 clippy::too_many_lines "this function has too many lines (171/100)" +cargo-0.49.0/src/cargo/ops/cargo_install.rs:13:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/cargo/ops/cargo_install.rs:148:1 clippy::fn_params_excessive_bools "more than 3 bools in function parameters" +cargo-0.49.0/src/cargo/ops/cargo_install.rs:148:1 clippy::too_many_lines "this function has too many lines (316/100)" +cargo-0.49.0/src/cargo/ops/cargo_install.rs:178:24 clippy::collapsible_else_if "this `else { if .. }` block can be collapsed" +cargo-0.49.0/src/cargo/ops/cargo_install.rs:202:17 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/ops/cargo_install.rs:236:16 clippy::collapsible_else_if "this `else { if .. }` block can be collapsed" +cargo-0.49.0/src/cargo/ops/cargo_install.rs:312:64 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/ops/cargo_install.rs:32:13 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" +cargo-0.49.0/src/cargo/ops/cargo_install.rs:339:12 clippy::collapsible_else_if "this `else { if .. }` block can be collapsed" +cargo-0.49.0/src/cargo/ops/cargo_install.rs:37:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_install.rs:454:22 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/ops/cargo_install.rs:483:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/ops/cargo_install.rs:683:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_install.rs:708:5 clippy::manual_flatten "unnecessary `if let` since only the `Some` variant of the iterator element is used" +cargo-0.49.0/src/cargo/ops/cargo_new.rs:101:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_new.rs:245:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/ops/cargo_new.rs:251:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/ops/cargo_new.rs:367:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_new.rs:405:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_new.rs:489:5 clippy::doc_markdown "you should put `IgnoreList` between ticks in the documentation" +cargo-0.49.0/src/cargo/ops/cargo_new.rs:525:47 clippy::doc_markdown "you should put `IgnoreList` between ticks in the documentation" +cargo-0.49.0/src/cargo/ops/cargo_new.rs:525:9 clippy::doc_markdown "you should put `format_existing` between ticks in the documentation" +cargo-0.49.0/src/cargo/ops/cargo_new.rs:572:34 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/ops/cargo_new.rs:623:1 clippy::too_many_lines "this function has too many lines (130/100)" +cargo-0.49.0/src/cargo/ops/cargo_new.rs:781:5 clippy::filter_map_next "called `filter_map(..).next()` on an `Iterator`. This is more succinctly expressed by calling `.find_map(..)` instead." +cargo-0.49.0/src/cargo/ops/cargo_new.rs:800:16 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/ops/cargo_output_metadata.rs:163:36 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/ops/cargo_output_metadata.rs:27:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_output_metadata.rs:45:45 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/ops/cargo_package.rs:144:1 clippy::too_many_lines "this function has too many lines (112/100)" +cargo-0.49.0/src/cargo/ops/cargo_package.rs:207:13 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/ops/cargo_package.rs:25:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo-0.49.0/src/cargo/ops/cargo_package.rs:307:54 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/ops/cargo_package.rs:394:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/ops/cargo_package.rs:425:61 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/ops/cargo_package.rs:459:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/ops/cargo_package.rs:66:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_package.rs:93:20 clippy::if_not_else "unnecessary boolean `not` operation" +cargo-0.49.0/src/cargo/ops/cargo_pkgid.rs:5:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_read_manifest.rs:14:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_read_manifest.rs:171:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/ops/cargo_read_manifest.rs:37:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_read_manifest.rs:37:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/ops/cargo_read_manifest.rs:57:49 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/ops/cargo_read_manifest.rs:69:37 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/ops/cargo_run.rs:25:24 clippy::if_not_else "unnecessary boolean `not` operation" +cargo-0.49.0/src/cargo/ops/cargo_run.rs:35:9 clippy::if_not_else "unnecessary boolean `not` operation" +cargo-0.49.0/src/cargo/ops/cargo_run.rs:37:16 clippy::redundant_else "redundant else block" +cargo-0.49.0/src/cargo/ops/cargo_run.rs:53:9 clippy::if_not_else "unnecessary boolean `not` operation" +cargo-0.49.0/src/cargo/ops/cargo_run.rs:65:16 clippy::redundant_else "redundant else block" +cargo-0.49.0/src/cargo/ops/cargo_run.rs:9:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_run.rs:9:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/ops/cargo_test.rs:16:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_test.rs:43:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_test.rs:84:17 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/ops/cargo_uninstall.rs:14:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/cargo_uninstall.rs:7:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:147:9 clippy::doc_markdown "you should put `PackageId` between ticks in the documentation" +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:233:21 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:244:22 clippy::doc_markdown "you should put `PackageId` between ticks in the documentation" +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:244:63 clippy::doc_markdown "you should put `PackageId` between ticks in the documentation" +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:253:17 clippy::if_not_else "unnecessary boolean `not` operation" +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:370:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:505:8 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:525:10 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:542:27 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:542:5 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:561:20 clippy::redundant_else "redundant else block" +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:613:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:645:41 clippy::doc_markdown "you should put `BTreeSet` between ticks in the documentation" +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:92:19 clippy::doc_markdown "you should put `InstallTracker` between ticks in the documentation" +cargo-0.49.0/src/cargo/ops/fix.rs:200:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/fix.rs:200:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/ops/fix.rs:424:20 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +cargo-0.49.0/src/cargo/ops/fix.rs:455:13 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/ops/fix.rs:506:17 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/ops/fix.rs:608:9 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" +cargo-0.49.0/src/cargo/ops/fix.rs:612:42 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/ops/fix.rs:619:48 clippy::manual_strip "stripping a prefix manually" +cargo-0.49.0/src/cargo/ops/fix.rs:66:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/ops/fix.rs:66:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo-0.49.0/src/cargo/ops/fix.rs:708:18 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/ops/fix.rs:77:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/lockfile.rs:154:13 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo-0.49.0/src/cargo/ops/lockfile.rs:217:9 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo-0.49.0/src/cargo/ops/lockfile.rs:30:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/lockfile.rs:35:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/lockfile.rs:35:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/ops/lockfile.rs:87:1 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo-0.49.0/src/cargo/ops/lockfile.rs:8:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/lockfile.rs:8:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/ops/registry.rs:150:21 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/ops/registry.rs:188:1 clippy::too_many_lines "this function has too many lines (130/100)" +cargo-0.49.0/src/cargo/ops/registry.rs:212:32 clippy::if_not_else "unnecessary `!=` operation" +cargo-0.49.0/src/cargo/ops/registry.rs:222:53 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/ops/registry.rs:224:44 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/ops/registry.rs:31:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/ops/registry.rs:346:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/registry.rs:346:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/ops/registry.rs:351:26 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/ops/registry.rs:385:12 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo-0.49.0/src/cargo/ops/registry.rs:386:15 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo-0.49.0/src/cargo/ops/registry.rs:38:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo-0.49.0/src/cargo/ops/registry.rs:477:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/registry.rs:483:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/registry.rs:503:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/registry.rs:505:38 clippy::default_trait_access "calling `util::config::CargoHttpConfig::default()` is more clear than this expression" +cargo-0.49.0/src/cargo/ops/registry.rs:510:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/registry.rs:529:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/ops/registry.rs:53:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/registry.rs:53:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/ops/registry.rs:573:22 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/ops/registry.rs:608:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/registry.rs:621:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/registry.rs:671:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/registry.rs:671:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/ops/registry.rs:674:10 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo-0.49.0/src/cargo/ops/registry.rs:678:17 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/ops/registry.rs:730:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/registry.rs:731:16 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/ops/registry.rs:785:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/registry.rs:794:16 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/ops/registry.rs:828:14 clippy::doc_markdown "you should put `SourceId` between ticks in the documentation" +cargo-0.49.0/src/cargo/ops/registry.rs:848:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/resolve.rs:199:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/resolve.rs:199:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/ops/resolve.rs:199:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/ops/resolve.rs:199:1 clippy::too_many_lines "this function has too many lines (137/100)" +cargo-0.49.0/src/cargo/ops/resolve.rs:241:28 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/ops/resolve.rs:28:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/ops/resolve.rs:384:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/resolve.rs:417:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/resolve.rs:589:9 clippy::shadow_unrelated "`keep` is being shadowed" +cargo-0.49.0/src/cargo/ops/resolve.rs:58:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/resolve.rs:58:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/ops/resolve.rs:602:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/ops/resolve.rs:75:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/resolve.rs:75:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/ops/tree/graph.rs:129:26 clippy::doc_markdown "you should put `PackageIds` between ticks in the documentation" +cargo-0.49.0/src/cargo/ops/tree/graph.rs:152:15 clippy::match_on_vec_items "indexing into a vector may panic" +cargo-0.49.0/src/cargo/ops/tree/graph.rs:173:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/ops/tree/graph.rs:234:46 clippy::filter_map "called `filter(..).flat_map(..)` on an `Iterator`" +cargo-0.49.0/src/cargo/ops/tree/graph.rs:328:44 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/ops/tree/graph.rs:330:50 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/ops/tree/graph.rs:563:35 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/ops/tree/mod.rs:112:11 clippy::non_ascii_literal "literal non-ASCII character detected" +cargo-0.49.0/src/cargo/ops/tree/mod.rs:113:10 clippy::non_ascii_literal "literal non-ASCII character detected" +cargo-0.49.0/src/cargo/ops/tree/mod.rs:114:10 clippy::non_ascii_literal "literal non-ASCII character detected" +cargo-0.49.0/src/cargo/ops/tree/mod.rs:115:12 clippy::non_ascii_literal "literal non-ASCII character detected" +cargo-0.49.0/src/cargo/ops/tree/mod.rs:126:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/tree/mod.rs:21:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/ops/tree/mod.rs:21:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo-0.49.0/src/cargo/ops/tree/mod.rs:360:30 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/ops/tree/mod.rs:58:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/ops/vendor.rs:14:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/ops/vendor.rs:21:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/ops/vendor.rs:21:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/ops/vendor.rs:314:34 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/ops/vendor.rs:320:29 clippy::case_sensitive_file_extension_comparisons "case-sensitive file extension comparison" +cargo-0.49.0/src/cargo/ops/vendor.rs:320:60 clippy::case_sensitive_file_extension_comparisons "case-sensitive file extension comparison" +cargo-0.49.0/src/cargo/ops/vendor.rs:324:13 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +cargo-0.49.0/src/cargo/ops/vendor.rs:70:1 clippy::too_many_lines "this function has too many lines (175/100)" +cargo-0.49.0/src/cargo/sources/config.rs:102:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/config.rs:111:28 clippy::needless_question_mark "Question mark operator is useless here" +cargo-0.49.0/src/cargo/sources/config.rs:133:48 clippy::needless_question_mark "Question mark operator is useless here" +cargo-0.49.0/src/cargo/sources/config.rs:135:67 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/sources/config.rs:206:36 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo-0.49.0/src/cargo/sources/config.rs:282:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/sources/config.rs:70:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/config.rs:81:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/config.rs:97:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/sources/directory.rs:14:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/sources/directory.rs:90:56 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/sources/git/source.rs:14:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/sources/git/source.rs:25:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/git/source.rs:25:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/sources/git/source.rs:49:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/sources/git/source.rs:53:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/git/source.rs:53:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/sources/git/source.rs:69:20 clippy::comparison_to_empty "comparison to empty slice" +cargo-0.49.0/src/cargo/sources/git/utils.rs:1025:19 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/sources/git/utils.rs:1157:36 clippy::case_sensitive_file_extension_comparisons "case-sensitive file extension comparison" +cargo-0.49.0/src/cargo/sources/git/utils.rs:1158:9 clippy::manual_strip "stripping a suffix manually" +cargo-0.49.0/src/cargo/sources/git/utils.rs:134:12 clippy::upper_case_acronyms "name `GitShortID` contains a capitalized acronym" +cargo-0.49.0/src/cargo/sources/git/utils.rs:176:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/sources/git/utils.rs:180:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/sources/git/utils.rs:184:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/git/utils.rs:188:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/git/utils.rs:242:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/git/utils.rs:253:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/git/utils.rs:253:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/sources/git/utils.rs:262:13 clippy::if_not_else "unnecessary boolean `not` operation" +cargo-0.49.0/src/cargo/sources/git/utils.rs:289:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/git/utils.rs:294:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/sources/git/utils.rs:298:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/git/utils.rs:308:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/git/utils.rs:472:9 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" +cargo-0.49.0/src/cargo/sources/git/utils.rs:489:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/sources/git/utils.rs:503:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/sources/git/utils.rs:528:28 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/sources/git/utils.rs:537:21 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" +cargo-0.49.0/src/cargo/sources/git/utils.rs:588:1 clippy::too_many_lines "this function has too many lines (135/100)" +cargo-0.49.0/src/cargo/sources/git/utils.rs:692:9 clippy::vec_init_then_push "calls to `push` immediately after creation" +cargo-0.49.0/src/cargo/sources/git/utils.rs:758:9 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo-0.49.0/src/cargo/sources/git/utils.rs:858:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/path.rs:129:44 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/sources/path.rs:143:44 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/sources/path.rs:15:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/sources/path.rs:282:50 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/sources/path.rs:313:21 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/sources/path.rs:314:21 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/sources/path.rs:319:21 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/sources/path.rs:339:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/sources/path.rs:339:9 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo-0.49.0/src/cargo/sources/path.rs:380:9 clippy::unused_self "unused `self` argument" +cargo-0.49.0/src/cargo/sources/path.rs:419:50 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/sources/path.rs:429:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/path.rs:460:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/sources/path.rs:473:43 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/sources/path.rs:482:43 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/sources/path.rs:55:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/sources/path.rs:63:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/path.rs:77:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/path.rs:98:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/registry/index.rs:117:23 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo-0.49.0/src/cargo/sources/registry/index.rs:121:70 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo-0.49.0/src/cargo/sources/registry/index.rs:167:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/sources/registry/index.rs:215:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/sources/registry/index.rs:324:23 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/sources/registry/index.rs:468:40 clippy::doc_markdown "you should put `SourceId` between ticks in the documentation" +cargo-0.49.0/src/cargo/sources/registry/index.rs:590:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/sources/registry/index.rs:648:17 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/sources/registry/index.rs:736:1 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +cargo-0.49.0/src/cargo/sources/registry/index.rs:95:37 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +cargo-0.49.0/src/cargo/sources/registry/local.rs:12:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/sources/registry/mod.rs:192:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/sources/registry/mod.rs:203:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/sources/registry/mod.rs:229:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/sources/registry/mod.rs:372:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/sources/registry/mod.rs:373:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/registry/mod.rs:375:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/registry/mod.rs:381:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/registry/mod.rs:382:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/registry/mod.rs:383:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/registry/mod.rs:384:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/registry/mod.rs:452:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/registry/mod.rs:582:20 clippy::redundant_else "redundant else block" +cargo-0.49.0/src/cargo/sources/registry/mod.rs:621:9 clippy::if_not_else "unnecessary `!=` operation" +cargo-0.49.0/src/cargo/sources/registry/remote.rs:139:17 clippy::unused_self "unused `self` argument" +cargo-0.49.0/src/cargo/sources/registry/remote.rs:32:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/sources/registry/remote.rs:72:13 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/sources/replaced.rs:12:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/sources/replaced.rs:5:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/util/canonical_url.rs:19:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/canonical_url.rs:19:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/util/canonical_url.rs:50:41 clippy::case_sensitive_file_extension_comparisons "case-sensitive file extension comparison" +cargo-0.49.0/src/cargo/util/canonical_url.rs:65:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/command_prelude.rs:218:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/command_prelude.rs:222:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/command_prelude.rs:234:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/command_prelude.rs:249:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/command_prelude.rs:264:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/command_prelude.rs:279:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/command_prelude.rs:298:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/command_prelude.rs:320:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/command_prelude.rs:328:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/command_prelude.rs:352:13 clippy::if_not_else "unnecessary boolean `not` operation" +cargo-0.49.0/src/cargo/util/command_prelude.rs:363:13 clippy::if_not_else "unnecessary boolean `not` operation" +cargo-0.49.0/src/cargo/util/command_prelude.rs:378:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/command_prelude.rs:387:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/command_prelude.rs:387:5 clippy::too_many_lines "this function has too many lines (104/100)" +cargo-0.49.0/src/cargo/util/command_prelude.rs:39:20 clippy::doc_markdown "you should put `arg_package_spec` between ticks in the documentation" +cargo-0.49.0/src/cargo/util/command_prelude.rs:504:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/command_prelude.rs:516:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/command_prelude.rs:530:40 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/util/command_prelude.rs:531:43 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/util/command_prelude.rs:536:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/command_prelude.rs:556:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/command_prelude.rs:575:49 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/util/command_prelude.rs:580:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/command_prelude.rs:631:18 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/util/command_prelude.rs:638:18 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/util/command_prelude.rs:647:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/command_prelude.rs:651:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/command_prelude.rs:662:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/command_prelude.rs:665:51 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/util/config/de.rs:420:16 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo-0.49.0/src/cargo/util/config/de.rs:46:25 clippy::doc_markdown "you should put `CV::List` between ticks in the documentation" +cargo-0.49.0/src/cargo/util/config/de.rs:47:24 clippy::doc_markdown "you should put `ConfigSeqAccess` between ticks in the documentation" +cargo-0.49.0/src/cargo/util/config/de.rs:527:53 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo-0.49.0/src/cargo/util/config/de.rs:530:53 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo-0.49.0/src/cargo/util/config/de.rs:532:68 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo-0.49.0/src/cargo/util/config/key.rs:11:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/util/config/key.rs:69:9 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo-0.49.0/src/cargo/util/config/mod.rs:100:71 clippy::doc_markdown "you should put `OptValue` between ticks in the documentation" +cargo-0.49.0/src/cargo/util/config/mod.rs:100:71 clippy::doc_markdown "you should put `OptValue` between ticks in the documentation" +cargo-0.49.0/src/cargo/util/config/mod.rs:100:71 clippy::doc_markdown "you should put `OptValue` between ticks in the documentation" +cargo-0.49.0/src/cargo/util/config/mod.rs:1049:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:1064:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:1090:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:1090:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:1166:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:1179:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:1181:33 clippy::needless_question_mark "Question mark operator is useless here" +cargo-0.49.0/src/cargo/util/config/mod.rs:1184:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:1186:33 clippy::needless_question_mark "Question mark operator is useless here" +cargo-0.49.0/src/cargo/util/config/mod.rs:1189:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:1191:33 clippy::needless_question_mark "Question mark operator is useless here" +cargo-0.49.0/src/cargo/util/config/mod.rs:1203:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:1211:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:1216:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:1225:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:1229:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:124:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +cargo-0.49.0/src/cargo/util/config/mod.rs:1254:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:1263:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:1279:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:1281:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/util/config/mod.rs:1323:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/util/config/mod.rs:1339:39 clippy::unused_self "unused `self` argument" +cargo-0.49.0/src/cargo/util/config/mod.rs:1344:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/util/config/mod.rs:1420:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/util/config/mod.rs:1553:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:1560:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:1567:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:1574:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:1581:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:1588:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/config/mod.rs:1598:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/config/mod.rs:1619:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/config/mod.rs:1623:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:1623:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:1623:64 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo-0.49.0/src/cargo/util/config/mod.rs:1649:9 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" +cargo-0.49.0/src/cargo/util/config/mod.rs:1699:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/util/config/mod.rs:1730:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/util/config/mod.rs:1757:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/util/config/mod.rs:1770:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/util/config/mod.rs:1778:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/util/config/mod.rs:1804:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/util/config/mod.rs:1896:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/config/mod.rs:1901:5 clippy::doc_markdown "you should put `StringList` between ticks in the documentation" +cargo-0.49.0/src/cargo/util/config/mod.rs:214:13 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +cargo-0.49.0/src/cargo/util/config/mod.rs:259:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:298:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:311:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:318:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:353:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:401:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:411:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:419:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:431:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:449:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:454:16 clippy::option_if_let_else "use Option::map_or instead of an if let/else" +cargo-0.49.0/src/cargo/util/config/mod.rs:547:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:556:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:582:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:595:20 clippy::doc_markdown "you should put `StringList` between ticks in the documentation" +cargo-0.49.0/src/cargo/util/config/mod.rs:689:20 clippy::unused_self "unused `self` argument" +cargo-0.49.0/src/cargo/util/config/mod.rs:699:5 clippy::fn_params_excessive_bools "more than 3 bools in function parameters" +cargo-0.49.0/src/cargo/util/config/mod.rs:699:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:719:58 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/util/config/mod.rs:816:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/path.rs:10:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/util/config/path.rs:14:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/config/path.rs:48:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/util/config/target.rs:12:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/util/config/target.rs:24:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/util/config/value.rs:29:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/util/config/value.rs:70:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/util/config/value.rs:80:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/config/value.rs:81:9 clippy::match_like_matches_macro "match expression looks like `matches!` macro" +cargo-0.49.0/src/cargo/util/cpu.rs:11:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/cpu.rs:22:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/cpu.rs:82:25 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +cargo-0.49.0/src/cargo/util/cpu.rs:82:9 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +cargo-0.49.0/src/cargo/util/dependency_queue.rs:109:27 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/util/dependency_queue.rs:125:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/util/dependency_queue.rs:151:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/dependency_queue.rs:156:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/dependency_queue.rs:168:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/util/dependency_queue.rs:46:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/dependency_queue.rs:66:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/util/dependency_queue.rs:91:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/util/diagnostic_server.rs:218:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/util/diagnostic_server.rs:230:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/diagnostic_server.rs:242:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/diagnostic_server.rs:58:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/diagnostic_server.rs:96:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/diagnostic_server.rs:96:5 clippy::too_many_lines "this function has too many lines (110/100)" +cargo-0.49.0/src/cargo/util/diagnostic_server.rs:99:21 clippy::shadow_unrelated "`msg` is being shadowed" +cargo-0.49.0/src/cargo/util/errors.rs:101:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/errors.rs:143:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/errors.rs:150:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/errors.rs:15:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/errors.rs:237:5 clippy::pub_enum_variant_names "variant name ends with the enum's name" +cargo-0.49.0/src/cargo/util/errors.rs:245:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/util/errors.rs:245:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/errors.rs:321:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/errors.rs:328:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/errors.rs:356:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/errors.rs:391:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/util/errors.rs:392:13 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/cargo/util/errors.rs:465:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/errors.rs:473:5 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +cargo-0.49.0/src/cargo/util/errors.rs:66:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/flock.rs:115:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/flock.rs:11:5 clippy::wildcard_imports "usage of wildcard import" +cargo-0.49.0/src/cargo/util/flock.rs:134:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/flock.rs:142:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/flock.rs:150:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/flock.rs:156:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/flock.rs:170:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/flock.rs:192:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/flock.rs:29:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/util/flock.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/flock.rs:321:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/util/flock.rs:335:23 clippy::cast_possible_truncation "casting `i64` to `u32` may truncate the value" +cargo-0.49.0/src/cargo/util/flock.rs:335:23 clippy::cast_sign_loss "casting `i64` to `u32` may lose the sign of the value" +cargo-0.49.0/src/cargo/util/flock.rs:335:44 clippy::cast_possible_truncation "casting `i64` to `u32` may truncate the value" +cargo-0.49.0/src/cargo/util/flock.rs:379:35 clippy::match_same_arms "this `match` has identical arm bodies" +cargo-0.49.0/src/cargo/util/flock.rs:37:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/util/flock.rs:37:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/flock.rs:43:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/util/flock.rs:43:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/flock.rs:52:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/flock.rs:52:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/util/graph.rs:10:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/graph.rs:41:51 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/util/graph.rs:45:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/hasher.rs:12:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/hasher.rs:9:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/util/hex.rs:10:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" +cargo-0.49.0/src/cargo/util/hex.rs:11:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" +cargo-0.49.0/src/cargo/util/hex.rs:12:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" +cargo-0.49.0/src/cargo/util/hex.rs:13:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" +cargo-0.49.0/src/cargo/util/hex.rs:14:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" +cargo-0.49.0/src/cargo/util/hex.rs:15:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" +cargo-0.49.0/src/cargo/util/hex.rs:25:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/hex.rs:6:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/util/hex.rs:6:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/hex.rs:8:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" +cargo-0.49.0/src/cargo/util/hex.rs:9:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" +cargo-0.49.0/src/cargo/util/important_paths.rs:23:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/important_paths.rs:6:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/interning.rs:66:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/util/interning.rs:66:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/interning.rs:77:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/into_url.rs:10:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/into_url_with_base.rs:9:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/job.rs:20:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/lev_distance.rs:3:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/lockserver.rs:111:32 clippy::redundant_else "redundant else block" +cargo-0.49.0/src/cargo/util/lockserver.rs:158:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/lockserver.rs:46:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/lockserver.rs:58:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/lockserver.rs:62:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/mod.rs:68:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/mod.rs:79:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/network.rs:12:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/network.rs:19:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/network.rs:84:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/paths.rs:109:12 clippy::redundant_else "redundant else block" +cargo-0.49.0/src/cargo/util/paths.rs:114:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/paths.rs:121:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/paths.rs:125:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/paths.rs:130:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/paths.rs:14:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/paths.rs:14:1 clippy::module_name_repetitions "item name ends with its containing module's name" +cargo-0.49.0/src/cargo/util/paths.rs:151:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/paths.rs:167:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/paths.rs:173:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/paths.rs:178:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/paths.rs:185:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/paths.rs:199:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/paths.rs:215:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/paths.rs:228:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/paths.rs:251:9 clippy::option_if_let_else "use Option::map_or instead of an if let/else" +cargo-0.49.0/src/cargo/util/paths.rs:267:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/paths.rs:276:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/paths.rs:29:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/paths.rs:303:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/paths.rs:312:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/paths.rs:346:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/paths.rs:415:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/paths.rs:445:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/paths.rs:459:45 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/util/paths.rs:469:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/paths.rs:469:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/util/paths.rs:54:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/paths.rs:61:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/util/paths.rs:61:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/paths.rs:63:19 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" +cargo-0.49.0/src/cargo/util/paths.rs:88:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/paths.rs:93:31 clippy::comparison_to_empty "comparison to empty slice" +cargo-0.49.0/src/cargo/util/process_builder.rs:106:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/process_builder.rs:111:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/process_builder.rs:122:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/process_builder.rs:132:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/process_builder.rs:152:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/process_builder.rs:185:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/process_builder.rs:190:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/process_builder.rs:218:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/process_builder.rs:218:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/util/process_builder.rs:307:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/process_builder.rs:343:39 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +cargo-0.49.0/src/cargo/util/progress.rs:122:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/progress.rs:136:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/progress.rs:15:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/util/progress.rs:249:19 clippy::cast_precision_loss "casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +cargo-0.49.0/src/cargo/util/progress.rs:249:34 clippy::cast_precision_loss "casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +cargo-0.49.0/src/cargo/util/progress.rs:250:19 clippy::if_not_else "unnecessary boolean `not` operation" +cargo-0.49.0/src/cargo/util/progress.rs:263:22 clippy::cast_precision_loss "casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +cargo-0.49.0/src/cargo/util/progress.rs:264:22 clippy::cast_possible_truncation "casting `f64` to `usize` may truncate the value" +cargo-0.49.0/src/cargo/util/progress.rs:264:22 clippy::cast_sign_loss "casting `f64` to `usize` may lose the sign of the value" +cargo-0.49.0/src/cargo/util/progress.rs:269:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo-0.49.0/src/cargo/util/progress.rs:272:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo-0.49.0/src/cargo/util/progress.rs:274:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo-0.49.0/src/cargo/util/progress.rs:280:13 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo-0.49.0/src/cargo/util/progress.rs:282:9 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +cargo-0.49.0/src/cargo/util/progress.rs:89:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/progress.rs:97:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/queue.rs:25:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/queue.rs:36:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/util/queue.rs:42:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/util/queue.rs:52:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/util/queue.rs:69:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/util/read2.rs:11:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/read2.rs:31:17 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/util/restricted_names.rs:13:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/restricted_names.rs:26:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/restricted_names.rs:35:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/restricted_names.rs:45:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/restricted_names.rs:87:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/util/restricted_names.rs:87:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/restricted_names.rs:89:21 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/util/restricted_names.rs:8:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/rustc.rs:103:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/rustc.rs:103:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/util/rustc.rs:114:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +cargo-0.49.0/src/cargo/util/rustc.rs:115:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +cargo-0.49.0/src/cargo/util/rustc.rs:162:17 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/util/rustc.rs:39:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/sha256.rs:10:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/sha256.rs:20:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/sha256.rs:31:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/sha256.rs:40:24 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +cargo-0.49.0/src/cargo/util/to_semver.rs:5:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/toml/mod.rs:1005:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/toml/mod.rs:1005:5 clippy::too_many_lines "this function has too many lines (282/100)" +cargo-0.49.0/src/cargo/util/toml/mod.rs:1094:36 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/util/toml/mod.rs:1121:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/util/toml/mod.rs:1197:32 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +cargo-0.49.0/src/cargo/util/toml/mod.rs:124:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/toml/mod.rs:1504:9 clippy::unused_self "unused `self` argument" +cargo-0.49.0/src/cargo/util/toml/mod.rs:1526:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/toml/mod.rs:1582:19 clippy::default_trait_access "calling `util::toml::DetailedTomlDependency::default()` is more clear than this expression" +cargo-0.49.0/src/cargo/util/toml/mod.rs:1598:5 clippy::too_many_lines "this function has too many lines (153/100)" +cargo-0.49.0/src/cargo/util/toml/mod.rs:1687:33 clippy::unnecessary_lazy_evaluations "unnecessary closure used to substitute value for `Option::None`" +cargo-0.49.0/src/cargo/util/toml/mod.rs:178:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/util/toml/mod.rs:248:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/util/toml/mod.rs:274:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/util/toml/mod.rs:277:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/toml/mod.rs:281:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/toml/mod.rs:285:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/toml/mod.rs:294:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/util/toml/mod.rs:31:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/toml/mod.rs:381:35 clippy::cast_possible_truncation "casting `i64` to `u32` may truncate the value" +cargo-0.49.0/src/cargo/util/toml/mod.rs:381:35 clippy::cast_sign_loss "casting `i64` to `u32` may lose the sign of the value" +cargo-0.49.0/src/cargo/util/toml/mod.rs:388:35 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +cargo-0.49.0/src/cargo/util/toml/mod.rs:398:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/util/toml/mod.rs:450:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/toml/mod.rs:536:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/toml/mod.rs:783:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/util/toml/mod.rs:824:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/util/toml/mod.rs:834:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/toml/mod.rs:83:42 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/util/toml/mod.rs:852:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/toml/mod.rs:852:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/util/toml/mod.rs:852:5 clippy::too_many_lines "this function has too many lines (138/100)" +cargo-0.49.0/src/cargo/util/toml/mod.rs:962:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/util/toml/mod.rs:979:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/util/toml/mod.rs:98:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/util/toml/mod.rs:999:23 clippy::default_trait_access "calling `util::toml::DetailedTomlDependency::default()` is more clear than this expression" +cargo-0.49.0/src/cargo/util/toml/targets.rs:112:27 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/util/toml/targets.rs:325:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +cargo-0.49.0/src/cargo/util/toml/targets.rs:586:21 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/util/toml/targets.rs:593:42 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/util/toml/targets.rs:605:19 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/util/toml/targets.rs:612:42 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/util/toml/targets.rs:756:36 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/util/vcs.rs:10:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/vcs.rs:33:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/vcs.rs:37:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/vcs.rs:43:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/vcs.rs:47:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/vcs.rs:59:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/vcs.rs:66:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/workspace.rs:52:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/workspace.rs:56:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/workspace.rs:60:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/workspace.rs:64:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron-0.6.1/src/error.rs:24:1 clippy::module_name_repetitions "item name ends with its containing module's name" +iron-0.6.1/src/iron.rs:105:13 clippy::redundant_field_names "redundant field names in struct initialization" +iron-0.6.1/src/iron.rs:119:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron-0.6.1/src/iron.rs:133:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron-0.6.1/src/iron.rs:143:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron-0.6.1/src/iron.rs:149:13 clippy::redundant_field_names "redundant field names in struct initialization" +iron-0.6.1/src/iron.rs:167:49 clippy::similar_names "binding's name is too similar to existing binding" +iron-0.6.1/src/iron.rs:80:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron-0.6.1/src/iron.rs:85:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron-0.6.1/src/iron.rs:90:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron-0.6.1/src/lib.rs:1:null clippy::cargo_common_metadata "package `iron` is missing `package.categories` metadata" +iron-0.6.1/src/lib.rs:1:null clippy::cargo_common_metadata "package `iron` is missing `package.keywords` metadata" +iron-0.6.1/src/lib.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `log`: 0.3.9, 0.4.8" +iron-0.6.1/src/middleware/mod.rs:137:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron-0.6.1/src/middleware/mod.rs:150:1 clippy::module_name_repetitions "item name ends with its containing module's name" +iron-0.6.1/src/middleware/mod.rs:152:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron-0.6.1/src/middleware/mod.rs:159:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron-0.6.1/src/middleware/mod.rs:171:1 clippy::module_name_repetitions "item name ends with its containing module's name" +iron-0.6.1/src/middleware/mod.rs:173:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron-0.6.1/src/middleware/mod.rs:182:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron-0.6.1/src/middleware/mod.rs:192:1 clippy::module_name_repetitions "item name ends with its containing module's name" +iron-0.6.1/src/middleware/mod.rs:217:25 clippy::doc_markdown "you should put `ChainBuilder` between ticks in the documentation" +iron-0.6.1/src/middleware/mod.rs:264:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +iron-0.6.1/src/middleware/mod.rs:328:20 clippy::similar_names "binding's name is too similar to existing binding" +iron-0.6.1/src/middleware/mod.rs:360:16 clippy::similar_names "binding's name is too similar to existing binding" +iron-0.6.1/src/middleware/mod.rs:368:33 clippy::similar_names "binding's name is too similar to existing binding" +iron-0.6.1/src/middleware/mod.rs:428:40 clippy::similar_names "binding's name is too similar to existing binding" +iron-0.6.1/src/middleware/mod.rs:434:40 clippy::similar_names "binding's name is too similar to existing binding" +iron-0.6.1/src/middleware/mod.rs:444:40 clippy::similar_names "binding's name is too similar to existing binding" +iron-0.6.1/src/modifiers.rs:132:14 clippy::expect_fun_call "use of `expect` followed by a function call" +iron-0.6.1/src/request/mod.rs:113:24 clippy::similar_names "binding's name is too similar to existing binding" +iron-0.6.1/src/request/mod.rs:121:13 clippy::redundant_field_names "redundant field names in struct initialization" +iron-0.6.1/src/request/mod.rs:123:13 clippy::redundant_field_names "redundant field names in struct initialization" +iron-0.6.1/src/request/mod.rs:124:13 clippy::redundant_field_names "redundant field names in struct initialization" +iron-0.6.1/src/request/mod.rs:126:13 clippy::redundant_field_names "redundant field names in struct initialization" +iron-0.6.1/src/request/mod.rs:128:13 clippy::redundant_field_names "redundant field names in struct initialization" +iron-0.6.1/src/request/mod.rs:153:69 clippy::doc_markdown "you should put `HttpReader` between ticks in the documentation" +iron-0.6.1/src/request/mod.rs:154:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron-0.6.1/src/request/mod.rs:32:1 clippy::manual_non_exhaustive "this seems like a manual implementation of the non-exhaustive pattern" +iron-0.6.1/src/request/mod.rs:75:34 clippy::doc_markdown "you should put `HttpRequest` between ticks in the documentation" +iron-0.6.1/src/request/mod.rs:77:39 clippy::doc_markdown "you should put `HttpRequest` between ticks in the documentation" +iron-0.6.1/src/request/mod.rs:78:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron-0.6.1/src/request/mod.rs:82:13 clippy::similar_names "binding's name is too similar to existing binding" +iron-0.6.1/src/request/mod.rs:83:29 clippy::similar_names "binding's name is too similar to existing binding" +iron-0.6.1/src/request/mod.rs:85:24 clippy::similar_names "binding's name is too similar to existing binding" +iron-0.6.1/src/request/url.rs:109:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron-0.6.1/src/request/url.rs:117:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron-0.6.1/src/request/url.rs:129:1 clippy::from_over_into "an implementation of `From` is preferred since it gives you `Into<_>` for free where the reverse isn't true" +iron-0.6.1/src/request/url.rs:21:14 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +iron-0.6.1/src/request/url.rs:22:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron-0.6.1/src/request/url.rs:31:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron-0.6.1/src/request/url.rs:47:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron-0.6.1/src/request/url.rs:52:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron-0.6.1/src/request/url.rs:57:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +iron-0.6.1/src/request/url.rs:57:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron-0.6.1/src/request/url.rs:63:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +iron-0.6.1/src/request/url.rs:63:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron-0.6.1/src/request/url.rs:73:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +iron-0.6.1/src/request/url.rs:73:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron-0.6.1/src/request/url.rs:83:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron-0.6.1/src/request/url.rs:96:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron-0.6.1/src/response.rs:121:19 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +iron-0.6.1/src/response.rs:125:43 clippy::redundant_closure_for_method_calls "redundant closure found" +iron-0.6.1/src/response.rs:139:41 clippy::redundant_closure_for_method_calls "redundant closure found" +iron-0.6.1/src/response.rs:24:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +iron-0.6.1/src/response.rs:95:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +iron-0.6.1/src/response.rs:95:5 clippy::new_without_default "you should consider adding a `Default` implementation for `response::Response`" +libc-0.2.81/build.rs:114:19 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +libc-0.2.81/build.rs:124:5 clippy::question_mark "this block may be rewritten with the `?` operator" +libc-0.2.81/build.rs:133:5 clippy::question_mark "this block may be rewritten with the `?` operator" +libc-0.2.81/src/macros.rs:243:17 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +libc-0.2.81/src/macros.rs:243:17 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +libc-0.2.81/src/macros.rs:243:17 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:428:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:429:30 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:431:30 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:432:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:433:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:434:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:595:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:596:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:597:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:622:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:673:34 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:696:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:697:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:698:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:699:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:712:34 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:721:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:722:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:723:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:751:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:752:30 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:753:30 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:754:30 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:755:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:756:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:757:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:758:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:759:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:760:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:768:30 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:769:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:771:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:772:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:773:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:774:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:775:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:776:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:777:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:778:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:779:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:780:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:781:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:782:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:783:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:784:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:785:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:786:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:787:30 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:788:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:789:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:790:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:791:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:792:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:794:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:795:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:796:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:797:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:798:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:799:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:800:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:801:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:803:27 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:804:28 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:805:28 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:806:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:807:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:808:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:809:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:810:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:811:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:812:30 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:813:30 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:814:30 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:815:30 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:816:30 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:817:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:818:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:821:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:822:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:823:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:824:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:825:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:826:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:827:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:828:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:829:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:830:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:831:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:832:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:833:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:834:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:835:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:836:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:841:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:842:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:843:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:844:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:1120:38 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:178:34 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:291:5 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:291:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:299:11 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:302:5 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:302:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:312:11 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:352:20 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:355:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:355:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:359:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:359:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:363:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:363:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:367:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:367:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:371:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:371:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:534:36 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:645:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:727:40 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:728:40 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:729:39 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:731:44 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:732:36 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:733:41 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:734:43 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:735:42 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:736:40 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:737:36 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:738:37 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:741:39 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:742:40 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:743:40 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:744:40 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:745:40 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:746:43 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:747:42 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:748:40 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:749:39 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:750:41 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:751:41 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:752:43 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:753:42 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:755:42 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:756:41 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:757:41 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:758:39 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:759:39 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:761:41 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:762:44 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:763:45 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:764:40 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:765:40 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:766:40 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:767:44 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:768:44 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:769:39 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:770:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:771:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:772:37 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:773:39 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:774:45 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:775:41 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:776:39 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:803:34 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:841:30 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:842:37 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:982:40 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:984:46 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1209:36 clippy::cast_possible_truncation "casting `i32` to `i16` may truncate the value" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1210:36 clippy::cast_possible_truncation "casting `i32` to `i16` may truncate the value" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1235:39 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1236:41 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1274:42 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1324:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1333:37 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1334:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1346:34 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1346:34 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1346:34 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1347:37 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1347:37 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1347:37 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1348:36 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1348:36 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1348:36 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1349:37 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1349:37 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1349:37 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1350:35 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1350:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1350:35 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1351:36 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1351:36 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1351:36 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1352:31 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1352:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1352:31 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1419:36 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1420:36 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1421:36 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1422:36 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1423:36 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1490:37 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1561:46 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1562:45 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1567:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1568:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1586:26 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1587:34 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1588:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1589:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1897:38 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1898:51 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1900:39 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1969:34 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1970:34 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1971:36 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1972:36 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1973:36 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1974:37 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1975:37 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1976:36 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1977:36 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1978:39 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1979:39 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1980:39 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1981:39 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1982:39 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1983:39 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1984:38 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1985:38 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1986:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1987:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1988:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1989:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1990:38 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1991:37 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1992:37 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1993:38 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1994:37 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1995:37 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1996:37 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1997:37 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1998:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:1999:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2000:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2001:34 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2002:34 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2003:34 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2004:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2005:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2032:30 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2033:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2034:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2035:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2036:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2037:28 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2038:27 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2039:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2041:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2042:28 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2043:27 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2044:34 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2045:27 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2046:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2048:28 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2049:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2050:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2051:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2052:26 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2053:36 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2318:42 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2321:38 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2331:39 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2487:42 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2488:42 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2489:43 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2490:43 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2491:43 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2493:47 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2494:44 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2495:46 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2496:47 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2497:49 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2498:48 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2499:50 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2500:45 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2572:9 clippy::needless_return "unneeded `return` statement" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2578:20 clippy::zero_ptr "`0 as *mut _` detected" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2588:13 clippy::zero_ptr "`0 as *mut _` detected" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2590:13 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2596:52 clippy::used_underscore_binding "used binding `_dummy` which is prefixed with an underscore. A leading underscore signals that a binding will not be used." +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2597:11 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2601:21 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2611:9 clippy::unused_unit "unneeded unit expression" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2619:9 clippy::unused_unit "unneeded unit expression" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2634:9 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2647:25 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2648:25 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2649:9 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2654:18 clippy::identity_op "the operation is ineffective. Consider reducing it to `(dev & 0x00000000000000ff)`" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2654:25 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2655:25 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2656:9 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2660:21 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2661:21 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2663:25 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2664:25 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2665:16 clippy::identity_op "the operation is ineffective. Consider reducing it to `(minor & 0x000000ff)`" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2665:25 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:2666:25 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/linux/mod.rs:954:34 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1000:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1001:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1002:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1016:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1017:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1018:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1019:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1020:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1029:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1030:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1031:30 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1032:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1033:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1034:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1035:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1041:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1042:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1043:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1044:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1045:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1046:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1047:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1048:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1049:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1050:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1051:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1053:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1054:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1055:30 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1056:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1057:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1058:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1059:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1060:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1073:42 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1074:43 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1075:37 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1076:37 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1077:41 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1078:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1079:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1080:36 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1081:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1082:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1083:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1084:38 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1086:30 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1087:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1089:30 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1090:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1091:30 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1094:40 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1095:37 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1096:41 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1097:40 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1098:39 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1099:34 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1100:36 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1101:38 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1102:37 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1105:44 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1106:41 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1107:42 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1108:42 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1109:41 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1110:46 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1111:41 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1112:44 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1113:40 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1114:47 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1115:36 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1126:34 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1127:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1128:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1179:32 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1180:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:1218:27 clippy::identity_op "the operation is ineffective. Consider reducing it to `IPOPT_CONTROL`" +libc-0.2.81/src/unix/linux_like/mod.rs:1314:9 clippy::precedence "operator precedence can trip the unwary" +libc-0.2.81/src/unix/linux_like/mod.rs:1321:13 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" +libc-0.2.81/src/unix/linux_like/mod.rs:1323:13 clippy::zero_ptr "`0 as *mut _` detected" +libc-0.2.81/src/unix/linux_like/mod.rs:1332:9 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +libc-0.2.81/src/unix/linux_like/mod.rs:1337:9 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +libc-0.2.81/src/unix/linux_like/mod.rs:1341:18 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" +libc-0.2.81/src/unix/linux_like/mod.rs:1344:9 clippy::needless_return "unneeded `return` statement" +libc-0.2.81/src/unix/linux_like/mod.rs:1348:18 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" +libc-0.2.81/src/unix/linux_like/mod.rs:1350:9 clippy::needless_return "unneeded `return` statement" +libc-0.2.81/src/unix/linux_like/mod.rs:1354:18 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" +libc-0.2.81/src/unix/linux_like/mod.rs:1357:9 clippy::needless_return "unneeded `return` statement" +libc-0.2.81/src/unix/linux_like/mod.rs:1361:21 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" +libc-0.2.81/src/unix/linux_like/mod.rs:1381:9 clippy::cast_possible_truncation "casting `i32` to `i8` may truncate the value" +libc-0.2.81/src/unix/linux_like/mod.rs:1389:9 clippy::verbose_bit_mask "bit mask could be simplified with a call to `trailing_zeros`" +libc-0.2.81/src/unix/linux_like/mod.rs:446:31 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:591:36 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:592:38 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:593:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:594:33 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:595:34 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:596:36 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:597:37 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:598:37 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:599:39 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:600:34 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:601:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:602:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:607:37 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:608:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:764:35 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:765:39 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/linux_like/mod.rs:991:30 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/mod.rs:198:29 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/mod.rs:199:28 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/mod.rs:201:35 clippy::unnecessary_cast "casting integer literal to `usize` is unnecessary" +libc-0.2.81/src/unix/mod.rs:202:35 clippy::unnecessary_cast "casting integer literal to `usize` is unnecessary" +libc-0.2.81/src/unix/mod.rs:282:40 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/mod.rs:284:41 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/mod.rs:285:36 clippy::unreadable_literal "long literal lacking separators" +libc-0.2.81/src/unix/mod.rs:34:10 clippy::upper_case_acronyms "name `DIR` contains a capitalized acronym" +libc-0.2.81/src/unix/mod.rs:386:10 clippy::upper_case_acronyms "name `FILE` contains a capitalized acronym" +log-0.4.11/src/lib.rs:1047:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:1053:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:1059:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:1093:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:1093:5 clippy::new_without_default "you should consider adding a `Default` implementation for `MetadataBuilder<'a>`" +log-0.4.11/src/lib.rs:1118:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:1177:1 clippy::inline_always "you have declared `#[inline(always)]` on `max_level`. This is usually a bad idea" +log-0.4.11/src/lib.rs:1178:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:1306:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +log-0.4.11/src/lib.rs:1306:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +log-0.4.11/src/lib.rs:1358:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:1359:5 clippy::if_not_else "unnecessary `!=` operation" +log-0.4.11/src/lib.rs:1407:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:329:27 clippy::derive_hash_xor_eq "you are deriving `Hash` but have implemented `PartialEq` explicitly" +log-0.4.11/src/lib.rs:356:1 clippy::expl_impl_clone_on_copy "you are implementing `Clone` explicitly on a `Copy` type" +log-0.4.11/src/lib.rs:448:12 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +log-0.4.11/src/lib.rs:500:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:506:28 clippy::trivially_copy_pass_by_ref "this argument (8 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +log-0.4.11/src/lib.rs:506:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +log-0.4.11/src/lib.rs:506:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:520:27 clippy::derive_hash_xor_eq "you are deriving `Hash` but have implemented `PartialEq` explicitly" +log-0.4.11/src/lib.rs:538:1 clippy::expl_impl_clone_on_copy "you are implementing `Clone` explicitly on a `Copy` type" +log-0.4.11/src/lib.rs:653:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:661:21 clippy::trivially_copy_pass_by_ref "this argument (8 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +log-0.4.11/src/lib.rs:661:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:677:44 clippy::match_same_arms "this `match` has identical arm bodies" +log-0.4.11/src/lib.rs:758:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:764:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:770:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:776:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:782:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:788:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:794:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:803:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:809:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:818:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:908:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +log-0.4.11/src/lib.rs:908:5 clippy::new_without_default "you should consider adding a `Default` implementation for `RecordBuilder<'a>`" +log-0.4.11/src/lib.rs:995:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/detection.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +proc-macro2-1.0.24/src/fallback.rs:108:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +proc-macro2-1.0.24/src/fallback.rs:269:20 clippy::unused_self "unused `self` argument" +proc-macro2-1.0.24/src/fallback.rs:430:24 clippy::trivially_copy_pass_by_ref "this argument (0 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +proc-macro2-1.0.24/src/fallback.rs:437:23 clippy::trivially_copy_pass_by_ref "this argument (0 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +proc-macro2-1.0.24/src/fallback.rs:437:23 clippy::unused_self "unused `self` argument" +proc-macro2-1.0.24/src/fallback.rs:471:17 clippy::trivially_copy_pass_by_ref "this argument (0 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +proc-macro2-1.0.24/src/fallback.rs:471:17 clippy::unused_self "unused `self` argument" +proc-macro2-1.0.24/src/fallback.rs:654:5 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +proc-macro2-1.0.24/src/fallback.rs:655:12 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +proc-macro2-1.0.24/src/fallback.rs:661:5 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +proc-macro2-1.0.24/src/fallback.rs:662:12 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +proc-macro2-1.0.24/src/fallback.rs:664:12 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +proc-macro2-1.0.24/src/fallback.rs:674:37 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +proc-macro2-1.0.24/src/fallback.rs:678:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +proc-macro2-1.0.24/src/fallback.rs:85:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +proc-macro2-1.0.24/src/fallback.rs:882:43 clippy::unused_self "unused `self` argument" +proc-macro2-1.0.24/src/lib.rs:1017:9 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:1081:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:1099:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:1117:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:1135:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:1141:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:1146:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:1151:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:1156:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:152:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:157:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:373:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:383:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:397:24 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +proc-macro2-1.0.24/src/lib.rs:397:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:403:23 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +proc-macro2-1.0.24/src/lib.rs:403:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:418:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:425:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:464:17 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +proc-macro2-1.0.24/src/lib.rs:500:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:626:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:633:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:641:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:652:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:662:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:672:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:734:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:743:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:752:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:757:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:788:19 clippy::doc_markdown "you should put `XID_Start` between ticks in the documentation" +proc-macro2-1.0.24/src/lib.rs:788:69 clippy::doc_markdown "you should put `XID_Continue` between ticks in the documentation" +proc-macro2-1.0.24/src/lib.rs:891:36 clippy::doc_markdown "you should put `syn::parse_str` between ticks in the documentation" +proc-macro2-1.0.24/src/lib.rs:894:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:911:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/lib.rs:996:9 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +proc-macro2-1.0.24/src/parse.rs:552:5 clippy::while_let_on_iterator "this loop could be written as a `for` loop" +proc-macro2-1.0.24/src/parse.rs:584:21 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +proc-macro2-1.0.24/src/parse.rs:602:20 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +proc-macro2-1.0.24/src/parse.rs:696:29 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" +proc-macro2-1.0.24/src/parse.rs:702:34 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" +proc-macro2-1.0.24/src/parse.rs:708:34 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" +proc-macro2-1.0.24/src/parse.rs:793:5 clippy::vec_init_then_push "calls to `push` immediately after creation" +proc-macro2-1.0.24/src/parse.rs:803:15 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" +proc-macro2-1.0.24/src/parse.rs:808:15 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" +proc-macro2-1.0.24/src/wrapper.rs:415:24 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +proc-macro2-1.0.24/src/wrapper.rs:429:23 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +proc-macro2-1.0.24/src/wrapper.rs:492:17 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +puffin-02dd4a3/puffin-imgui/src/ui.rs:158:15 clippy::cast_precision_loss "casting `i64` to `f32` causes a loss of precision (`i64` is 64 bits wide, but `f32`'s mantissa is only 23 bits wide)" +puffin-02dd4a3/puffin-imgui/src/ui.rs:175:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +puffin-02dd4a3/puffin-imgui/src/ui.rs:183:5 clippy::too_many_lines "this function has too many lines (115/100)" +puffin-02dd4a3/puffin-imgui/src/ui.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +puffin-02dd4a3/puffin-imgui/src/ui.rs:207:16 clippy::collapsible_else_if "this `else { if .. }` block can be collapsed" +puffin-02dd4a3/puffin-imgui/src/ui.rs:271:67 clippy::cast_precision_loss "casting `i64` to `f32` causes a loss of precision (`i64` is 64 bits wide, but `f32`'s mantissa is only 23 bits wide)" +puffin-02dd4a3/puffin-imgui/src/ui.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +puffin-02dd4a3/puffin-imgui/src/ui.rs:376:29 clippy::cast_precision_loss "casting `i64` to `f32` causes a loss of precision (`i64` is 64 bits wide, but `f32`'s mantissa is only 23 bits wide)" +puffin-02dd4a3/puffin-imgui/src/ui.rs:381:44 clippy::cast_precision_loss "casting `i64` to `f32` causes a loss of precision (`i64` is 64 bits wide, but `f32`'s mantissa is only 23 bits wide)" +puffin-02dd4a3/puffin-imgui/src/ui.rs:453:9 clippy::similar_names "binding's name is too similar to existing binding" +puffin-02dd4a3/puffin-imgui/src/ui.rs:540:14 clippy::cast_possible_truncation "casting `f64` to `f32` may truncate the value" +puffin-02dd4a3/puffin-imgui/src/ui.rs:551:5 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +puffin-02dd4a3/puffin-imgui/src/ui.rs:584:39 clippy::cast_precision_loss "casting `usize` to `f32` causes a loss of precision (`usize` is 32 or 64 bits wide, but `f32`'s mantissa is only 23 bits wide)" +puffin-02dd4a3/puffin-imgui/src/ui.rs:59:26 clippy::unsafe_derive_deserialize "you are deriving `serde::Deserialize` on a type that has methods using `unsafe`" +puffin-02dd4a3/puffin-imgui/src/ui.rs:61:1 clippy::module_name_repetitions "item name ends with its containing module's name" +puffin-02dd4a3/puffin-imgui/src/ui.rs:627:39 clippy::cast_precision_loss "casting `usize` to `f32` causes a loss of precision (`usize` is 32 or 64 bits wide, but `f32`'s mantissa is only 23 bits wide)" +puffin-02dd4a3/puffin-imgui/src/ui.rs:674:47 clippy::cast_precision_loss "casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +puffin-02dd4a3/puffin-imgui/src/ui.rs:690:9 clippy::cast_precision_loss "casting `usize` to `f32` causes a loss of precision (`usize` is 32 or 64 bits wide, but `f32`'s mantissa is only 23 bits wide)" +puffin-02dd4a3/puffin/src/data.rs:102:25 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" +puffin-02dd4a3/puffin/src/data.rs:112:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +puffin-02dd4a3/puffin/src/data.rs:116:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +puffin-02dd4a3/puffin/src/data.rs:137:24 clippy::match_same_arms "this `match` has identical arm bodies" +puffin-02dd4a3/puffin/src/data.rs:177:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +puffin-02dd4a3/puffin/src/data.rs:211:21 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +puffin-02dd4a3/puffin/src/data.rs:24:5 clippy::wildcard_imports "usage of wildcard import" +puffin-02dd4a3/puffin/src/data.rs:75:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +puffin-02dd4a3/puffin/src/lib.rs:113:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +puffin-02dd4a3/puffin/src/lib.rs:147:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +puffin-02dd4a3/puffin/src/lib.rs:147:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +puffin-02dd4a3/puffin/src/lib.rs:165:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +puffin-02dd4a3/puffin/src/lib.rs:200:21 clippy::default_trait_access "calling `Stream::default()` is more clear than this expression" +puffin-02dd4a3/puffin/src/lib.rs:257:78 clippy::default_trait_access "calling `std::cell::RefCell::default()` is more clear than this expression" +puffin-02dd4a3/puffin/src/lib.rs:297:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +puffin-02dd4a3/puffin/src/lib.rs:302:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +puffin-02dd4a3/puffin/src/lib.rs:308:28 clippy::default_trait_access "calling `FullProfileData::default()` is more clear than this expression" +puffin-02dd4a3/puffin/src/lib.rs:316:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +puffin-02dd4a3/puffin/src/lib.rs:321:5 clippy::cast_possible_truncation "casting `u128` to `i64` may truncate the value" +puffin-02dd4a3/puffin/src/lib.rs:348:28 clippy::default_trait_access "calling `std::marker::PhantomData::default()` is more clear than this expression" +puffin-02dd4a3/puffin/src/lib.rs:359:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +puffin-02dd4a3/puffin/src/lib.rs:375:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +puffin-02dd4a3/puffin/src/lib.rs:376:5 clippy::option_if_let_else "use Option::map_or instead of an if let/else" +puffin-02dd4a3/puffin/src/lib.rs:377:9 clippy::option_if_let_else "use Option::map_or instead of an if let/else" +puffin-02dd4a3/puffin/src/lib.rs:406:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +puffin-02dd4a3/puffin/src/lib.rs:408:5 clippy::option_if_let_else "use Option::map_or instead of an if let/else" +puffin-02dd4a3/puffin/src/lib.rs:69:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +puffin-02dd4a3/puffin/src/lib.rs:73:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +puffin-02dd4a3/puffin/src/lib.rs:77:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +puffin-02dd4a3/puffin/src/merge.rs:21:1 clippy::module_name_repetitions "item name starts with its containing module's name" +puffin-02dd4a3/puffin/src/merge.rs:28:1 clippy::module_name_repetitions "item name starts with its containing module's name" +puffin-02dd4a3/puffin/src/merge.rs:28:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +puffin-02dd4a3/puffin/src/merge.rs:35:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +puffin-02dd4a3/puffin/src/merge.rs:35:1 clippy::module_name_repetitions "item name starts with its containing module's name" +puffin-02dd4a3/puffin/src/merge.rs:64:43 clippy::default_trait_access "calling `std::vec::Vec::default()` is more clear than this expression" +puffin-02dd4a3/puffin/src/merge.rs:65:54 clippy::default_trait_access "calling `std::collections::HashMap::default()` is more clear than this expression" +puffin-02dd4a3/puffin/src/merge.rs:9:1 clippy::module_name_repetitions "item name starts with its containing module's name" +quote-1.0.7/src/ext.rs:10:1 clippy::module_name_repetitions "item name ends with its containing module's name" +quote-1.0.7/src/ext.rs:7:5 clippy::doc_markdown "you should put `TokenStream` between ticks in the documentation" +quote-1.0.7/src/ident_fragment.rs:13:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +quote-1.0.7/src/ident_fragment.rs:51:31 clippy::manual_strip "stripping a prefix manually" +quote-1.0.7/src/runtime.rs:332:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +quote-1.0.7/src/runtime.rs:52:5 clippy::module_name_repetitions "item name ends with its containing module's name" +quote-1.0.7/src/runtime.rs:63:5 clippy::module_name_repetitions "item name ends with its containing module's name" +quote-1.0.7/src/runtime.rs:66:33 clippy::doc_markdown "you should put `DoesNotHaveIter` between ticks in the documentation" +quote-1.0.7/src/runtime.rs:80:5 clippy::module_name_repetitions "item name ends with its containing module's name" +rand-0.7.3/src/distributions/bernoulli.rs:103:20 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" +rand-0.7.3/src/distributions/bernoulli.rs:103:20 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" +rand-0.7.3/src/distributions/bernoulli.rs:116:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +rand-0.7.3/src/distributions/bernoulli.rs:123:21 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" +rand-0.7.3/src/distributions/bernoulli.rs:123:21 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" +rand-0.7.3/src/distributions/bernoulli.rs:63:26 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand-0.7.3/src/distributions/bernoulli.rs:63:27 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +rand-0.7.3/src/distributions/bernoulli.rs:67:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand-0.7.3/src/distributions/bernoulli.rs:95:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +rand-0.7.3/src/distributions/bernoulli.rs:96:13 clippy::manual_range_contains "manual `Range::contains` implementation" +rand-0.7.3/src/distributions/binomial.rs:107:23 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand-0.7.3/src/distributions/binomial.rs:112:44 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand-0.7.3/src/distributions/binomial.rs:116:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rand-0.7.3/src/distributions/binomial.rs:150:28 clippy::redundant_else "redundant else block" +rand-0.7.3/src/distributions/binomial.rs:153:24 clippy::if_not_else "unnecessary boolean `not` operation" +rand-0.7.3/src/distributions/binomial.rs:158:28 clippy::redundant_else "redundant else block" +rand-0.7.3/src/distributions/binomial.rs:164:33 clippy::cast_sign_loss "casting `i64` to `u64` may lose the sign of the value" +rand-0.7.3/src/distributions/binomial.rs:166:28 clippy::redundant_else "redundant else block" +rand-0.7.3/src/distributions/binomial.rs:175:47 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand-0.7.3/src/distributions/binomial.rs:185:38 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand-0.7.3/src/distributions/binomial.rs:194:38 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand-0.7.3/src/distributions/binomial.rs:202:28 clippy::redundant_else "redundant else block" +rand-0.7.3/src/distributions/binomial.rs:209:25 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand-0.7.3/src/distributions/binomial.rs:221:26 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand-0.7.3/src/distributions/binomial.rs:222:26 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand-0.7.3/src/distributions/binomial.rs:223:25 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand-0.7.3/src/distributions/binomial.rs:224:25 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand-0.7.3/src/distributions/binomial.rs:226:17 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rand-0.7.3/src/distributions/binomial.rs:233:32 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand-0.7.3/src/distributions/binomial.rs:234:27 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand-0.7.3/src/distributions/binomial.rs:251:22 clippy::cast_sign_loss "casting `i64` to `u64` may lose the sign of the value" +rand-0.7.3/src/distributions/binomial.rs:255:9 clippy::if_not_else "unnecessary `!=` operation" +rand-0.7.3/src/distributions/binomial.rs:35:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +rand-0.7.3/src/distributions/binomial.rs:35:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/distributions/binomial.rs:45:17 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand-0.7.3/src/distributions/binomial.rs:46:5 clippy::cast_possible_truncation "casting `f64` to `i64` may truncate the value" +rand-0.7.3/src/distributions/binomial.rs:50:5 clippy::too_many_lines "this function has too many lines (143/100)" +rand-0.7.3/src/distributions/binomial.rs:76:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rand-0.7.3/src/distributions/binomial.rs:78:12 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand-0.7.3/src/distributions/binomial.rs:81:21 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand-0.7.3/src/distributions/binomial.rs:82:32 clippy::cast_possible_truncation "casting `u64` to `i32` may truncate the value" +rand-0.7.3/src/distributions/binomial.rs:88:26 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand-0.7.3/src/distributions/binomial.rs:99:21 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand-0.7.3/src/distributions/cauchy.rs:33:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +rand-0.7.3/src/distributions/cauchy.rs:33:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/distributions/dirichlet.rs:52:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/distributions/dirichlet.rs:64:32 clippy::unseparated_literal_suffix "float type suffix should be separated by an underscore" +rand-0.7.3/src/distributions/dirichlet.rs:65:23 clippy::unseparated_literal_suffix "float type suffix should be separated by an underscore" +rand-0.7.3/src/distributions/exponential.rs:76:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +rand-0.7.3/src/distributions/exponential.rs:76:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/distributions/float.rs:73:1 clippy::module_name_repetitions "item name ends with its containing module's name" +rand-0.7.3/src/distributions/gamma.rs:13:5 clippy::enum_glob_use "usage of wildcard import for enum variants" +rand-0.7.3/src/distributions/gamma.rs:14:5 clippy::enum_glob_use "usage of wildcard import for enum variants" +rand-0.7.3/src/distributions/gamma.rs:189:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +rand-0.7.3/src/distributions/gamma.rs:189:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/distributions/gamma.rs:230:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +rand-0.7.3/src/distributions/gamma.rs:230:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/distributions/gamma.rs:259:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +rand-0.7.3/src/distributions/gamma.rs:259:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/distributions/gamma.rs:287:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +rand-0.7.3/src/distributions/gamma.rs:287:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/distributions/gamma.rs:90:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +rand-0.7.3/src/distributions/gamma.rs:90:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/distributions/integer.rs:23:9 clippy::cast_possible_truncation "casting `u32` to `u8` may truncate the value" +rand-0.7.3/src/distributions/integer.rs:30:9 clippy::cast_possible_truncation "casting `u32` to `u16` may truncate the value" +rand-0.7.3/src/distributions/integer.rs:69:9 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +rand-0.7.3/src/distributions/mod.rs:263:5 clippy::inline_always "you have declared `#[inline(always)]` on `next`. This is usually a bad idea" +rand-0.7.3/src/distributions/normal.rs:100:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/distributions/normal.rs:119:1 clippy::module_name_repetitions "item name ends with its containing module's name" +rand-0.7.3/src/distributions/normal.rs:131:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/distributions/normal.rs:31:1 clippy::module_name_repetitions "item name ends with its containing module's name" +rand-0.7.3/src/distributions/normal.rs:47:25 clippy::unseparated_literal_suffix "float type suffix should be separated by an underscore" +rand-0.7.3/src/distributions/normal.rs:48:25 clippy::unseparated_literal_suffix "float type suffix should be separated by an underscore" +rand-0.7.3/src/distributions/other.rs:89:9 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +rand-0.7.3/src/distributions/pareto.rs:32:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/distributions/poisson.rs:35:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +rand-0.7.3/src/distributions/poisson.rs:35:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/distributions/poisson.rs:87:30 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" +rand-0.7.3/src/distributions/poisson.rs:87:30 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" +rand-0.7.3/src/distributions/triangular.rs:32:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/distributions/uniform.rs:146:4 clippy::needless_doctest_main "needless `fn main` in doctest" +rand-0.7.3/src/distributions/uniform.rs:199:1 clippy::module_name_repetitions "item name ends with its containing module's name" +rand-0.7.3/src/distributions/uniform.rs:214:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand-0.7.3/src/distributions/uniform.rs:283:14 clippy::doc_markdown "you should put `SampleUniform` between ticks in the documentation" +rand-0.7.3/src/distributions/uniform.rs:283:46 clippy::doc_markdown "you should put `SampleUniform` between ticks in the documentation" +rand-0.7.3/src/distributions/uniform.rs:296:5 clippy::inline_always "you have declared `#[inline(always)]` on `borrow`. This is usually a bad idea" +rand-0.7.3/src/distributions/uniform.rs:304:5 clippy::inline_always "you have declared `#[inline(always)]` on `borrow`. This is usually a bad idea" +rand-0.7.3/src/distributions/uniform.rs:350:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +rand-0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" +rand-0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" +rand-0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" +rand-0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" +rand-0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" +rand-0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" +rand-0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" +rand-0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" +rand-0.7.3/src/distributions/uniform.rs:56:10 clippy::doc_markdown "you should put `SampleBorrow` between ticks in the documentation" +rand-0.7.3/src/distributions/uniform.rs:647:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand-0.7.3/src/distributions/uniform.rs:840:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand-0.7.3/src/distributions/uniform.rs:913:13 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" +rand-0.7.3/src/distributions/uniform.rs:943:54 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +rand-0.7.3/src/distributions/unit_circle.rs:30:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/distributions/unit_sphere.rs:24:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand-0.7.3/src/distributions/unit_sphere.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/distributions/utils.rs:218:18 clippy::upper_case_acronyms "name `FloatSIMDUtils` contains a capitalized acronym" +rand-0.7.3/src/distributions/utils.rs:247:15 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" +rand-0.7.3/src/distributions/utils.rs:248:20 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" +rand-0.7.3/src/distributions/utils.rs:249:18 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" +rand-0.7.3/src/distributions/utils.rs:253:18 clippy::upper_case_acronyms "name `FloatAsSIMD` contains a capitalized acronym" +rand-0.7.3/src/distributions/utils.rs:254:5 clippy::inline_always "you have declared `#[inline(always)]` on `lanes`. This is usually a bad idea" +rand-0.7.3/src/distributions/utils.rs:258:5 clippy::inline_always "you have declared `#[inline(always)]` on `splat`. This is usually a bad idea" +rand-0.7.3/src/distributions/utils.rs:262:5 clippy::inline_always "you have declared `#[inline(always)]` on `extract`. This is usually a bad idea" +rand-0.7.3/src/distributions/utils.rs:267:5 clippy::inline_always "you have declared `#[inline(always)]` on `replace`. This is usually a bad idea" +rand-0.7.3/src/distributions/utils.rs:274:18 clippy::upper_case_acronyms "name `BoolAsSIMD` contains a capitalized acronym" +rand-0.7.3/src/distributions/utils.rs:281:5 clippy::inline_always "you have declared `#[inline(always)]` on `any`. This is usually a bad idea" +rand-0.7.3/src/distributions/utils.rs:286:5 clippy::inline_always "you have declared `#[inline(always)]` on `all`. This is usually a bad idea" +rand-0.7.3/src/distributions/utils.rs:291:5 clippy::inline_always "you have declared `#[inline(always)]` on `none`. This is usually a bad idea" +rand-0.7.3/src/distributions/utils.rs:488:17 clippy::doc_markdown "you should put `x_i` between ticks in the documentation" +rand-0.7.3/src/distributions/utils.rs:489:50 clippy::doc_markdown "you should put `x_i` between ticks in the documentation" +rand-0.7.3/src/distributions/utils.rs:489:63 clippy::doc_markdown "you should put `f(x_i` between ticks in the documentation" +rand-0.7.3/src/distributions/utils.rs:490:40 clippy::doc_markdown "you should put `f(x_i` between ticks in the documentation" +rand-0.7.3/src/distributions/utils.rs:490:49 clippy::doc_markdown "you should put `f(x_{i+1` between ticks in the documentation" +rand-0.7.3/src/distributions/utils.rs:518:17 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +rand-0.7.3/src/distributions/weibull.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/distributions/weighted/alias_method.rs:113:21 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" +rand-0.7.3/src/distributions/weighted/alias_method.rs:125:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rand-0.7.3/src/distributions/weighted/alias_method.rs:131:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rand-0.7.3/src/distributions/weighted/alias_method.rs:180:36 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +rand-0.7.3/src/distributions/weighted/alias_method.rs:182:34 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +rand-0.7.3/src/distributions/weighted/alias_method.rs:259:28 clippy::clone_on_copy "using `clone` on type `distributions::uniform::Uniform` which implements the `Copy` trait" +rand-0.7.3/src/distributions/weighted/alias_method.rs:296:9 clippy::map_clone "you are using an explicit closure for copying elements" +rand-0.7.3/src/distributions/weighted/alias_method.rs:321:9 clippy::map_clone "you are using an explicit closure for copying elements" +rand-0.7.3/src/distributions/weighted/alias_method.rs:78:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +rand-0.7.3/src/distributions/weighted/alias_method.rs:78:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +rand-0.7.3/src/distributions/weighted/alias_method.rs:78:5 clippy::too_many_lines "this function has too many lines (106/100)" +rand-0.7.3/src/distributions/weighted/alias_method.rs:85:17 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +rand-0.7.3/src/distributions/weighted/alias_method.rs:87:31 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +rand-0.7.3/src/distributions/weighted/mod.rs:100:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +rand-0.7.3/src/distributions/weighted/mod.rs:144:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +rand-0.7.3/src/distributions/weighted/mod.rs:144:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +rand-0.7.3/src/distributions/weighted/mod.rs:169:16 clippy::int_plus_one "unnecessary `>= y + 1` or `x - 1 >=`" +rand-0.7.3/src/distributions/weighted/mod.rs:386:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand-0.7.3/src/distributions/weighted/mod.rs:85:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand-0.7.3/src/lib.rs:333:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +rand-0.7.3/src/lib.rs:404:14 clippy::wrong_self_convention "methods called `to_*` usually take self by reference; consider choosing a less ambiguous name" +rand-0.7.3/src/lib.rs:552:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +rand-0.7.3/src/rngs/adapter/read.rs:47:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand-0.7.3/src/rngs/adapter/read.rs:89:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand-0.7.3/src/rngs/adapter/reseeding.rs:100:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +rand-0.7.3/src/rngs/adapter/reseeding.rs:112:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea" +rand-0.7.3/src/rngs/adapter/reseeding.rs:117:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea" +rand-0.7.3/src/rngs/adapter/reseeding.rs:198:13 clippy::cast_possible_wrap "casting `u64` to `i64` may wrap around the value" +rand-0.7.3/src/rngs/adapter/reseeding.rs:231:9 clippy::cast_possible_wrap "casting `usize` to `isize` may wrap around the value" +rand-0.7.3/src/rngs/adapter/reseeding.rs:27:28 clippy::doc_markdown "you should put `ChaCha` between ticks in the documentation" +rand-0.7.3/src/rngs/adapter/reseeding.rs:79:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand-0.7.3/src/rngs/entropy.rs:24:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand-0.7.3/src/rngs/entropy.rs:34:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/rngs/mock.rs:36:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/rngs/mock.rs:47:9 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +rand-0.7.3/src/rngs/mod.rs:61:74 clippy::doc_markdown "you should put `ChaCha20` between ticks in the documentation" +rand-0.7.3/src/rngs/std.rs:25:39 clippy::doc_markdown "you should put `ChaCha` between ticks in the documentation" +rand-0.7.3/src/rngs/std.rs:32:10 clippy::doc_markdown "you should put `rand_chacha` between ticks in the documentation" +rand-0.7.3/src/rngs/std.rs:36:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand-0.7.3/src/rngs/std.rs:39:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea" +rand-0.7.3/src/rngs/std.rs:44:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea" +rand-0.7.3/src/rngs/std.rs:49:5 clippy::inline_always "you have declared `#[inline(always)]` on `fill_bytes`. This is usually a bad idea" +rand-0.7.3/src/rngs/std.rs:54:5 clippy::inline_always "you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea" +rand-0.7.3/src/rngs/std.rs:63:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_seed`. This is usually a bad idea" +rand-0.7.3/src/rngs/std.rs:68:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_rng`. This is usually a bad idea" +rand-0.7.3/src/rngs/thread.rs:57:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand-0.7.3/src/rngs/thread.rs:80:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +rand-0.7.3/src/rngs/thread.rs:80:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand-0.7.3/src/rngs/thread.rs:80:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +rand-0.7.3/src/rngs/thread.rs:81:35 clippy::redundant_closure_for_method_calls "redundant closure found" +rand-0.7.3/src/rngs/thread.rs:93:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea" +rand-0.7.3/src/rngs/thread.rs:98:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea" +rand-0.7.3/src/seq/index.rs:127:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand-0.7.3/src/seq/index.rs:139:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +rand-0.7.3/src/seq/index.rs:159:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand-0.7.3/src/seq/index.rs:171:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +rand-0.7.3/src/seq/index.rs:180:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +rand-0.7.3/src/seq/index.rs:213:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +rand-0.7.3/src/seq/index.rs:223:18 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +rand-0.7.3/src/seq/index.rs:224:18 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +rand-0.7.3/src/seq/index.rs:233:25 clippy::cast_precision_loss "casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide)" +rand-0.7.3/src/seq/index.rs:236:27 clippy::cast_precision_loss "casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide)" +rand-0.7.3/src/seq/index.rs:244:12 clippy::cast_precision_loss "casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide)" +rand-0.7.3/src/seq/index.rs:244:37 clippy::cast_precision_loss "casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide)" +rand-0.7.3/src/seq/index.rs:29:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand-0.7.3/src/seq/index.rs:39:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/seq/index.rs:48:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/seq/index.rs:60:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/seq/index.rs:69:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/seq/index.rs:78:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/seq/index.rs:87:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand-0.7.3/src/seq/index.rs:87:5 clippy::should_implement_trait "method `into_iter` can be confused for the standard trait method `std::iter::IntoIterator::into_iter`" +rand-0.7.3/src/seq/index.rs:97:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +rand-0.7.3/src/seq/mod.rs:141:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +rand-0.7.3/src/seq/mod.rs:168:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +rand-0.7.3/src/seq/mod.rs:229:4 clippy::needless_doctest_main "needless `fn main` in doctest" +rand-0.7.3/src/seq/mod.rs:292:29 clippy::cast_precision_loss "casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +rand-0.7.3/src/seq/mod.rs:410:23 clippy::default_trait_access "calling `std::marker::PhantomData::default()` is more clear than this expression" +rand-0.7.3/src/seq/mod.rs:45:4 clippy::needless_doctest_main "needless `fn main` in doctest" +rand-0.7.3/src/seq/mod.rs:527:26 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +rand_core-0.6.0/src/block.rs:117:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand_core-0.6.0/src/block.rs:153:5 clippy::inline_always "you have declared `#[inline(always)]` on `index`. This is usually a bad idea" +rand_core-0.6.0/src/block.rs:168:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +rand_core-0.6.0/src/block.rs:230:5 clippy::inline_always "you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea" +rand_core-0.6.0/src/block.rs:240:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_seed`. This is usually a bad idea" +rand_core-0.6.0/src/block.rs:245:5 clippy::inline_always "you have declared `#[inline(always)]` on `seed_from_u64`. This is usually a bad idea" +rand_core-0.6.0/src/block.rs:250:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_rng`. This is usually a bad idea" +rand_core-0.6.0/src/block.rs:280:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand_core-0.6.0/src/block.rs:319:5 clippy::inline_always "you have declared `#[inline(always)]` on `index`. This is usually a bad idea" +rand_core-0.6.0/src/block.rs:335:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +rand_core-0.6.0/src/block.rs:405:5 clippy::inline_always "you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea" +rand_core-0.6.0/src/block.rs:415:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_seed`. This is usually a bad idea" +rand_core-0.6.0/src/block.rs:420:5 clippy::inline_always "you have declared `#[inline(always)]` on `seed_from_u64`. This is usually a bad idea" +rand_core-0.6.0/src/block.rs:425:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_rng`. This is usually a bad idea" +rand_core-0.6.0/src/block.rs:67:14 clippy::doc_markdown "you should put `module][crate::block` between ticks in the documentation" +rand_core-0.6.0/src/block.rs:68:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rand_core-0.6.0/src/error.rs:106:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand_core-0.6.0/src/error.rs:87:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand_core-0.6.0/src/error.rs:95:74 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +rand_core-0.6.0/src/le.rs:18:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +rand_core-0.6.0/src/le.rs:27:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +rand_core-0.6.0/src/lib.rs:179:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +rand_core-0.6.0/src/lib.rs:301:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rand_core-0.6.0/src/lib.rs:303:26 clippy::unreadable_literal "long literal lacking separators" +rand_core-0.6.0/src/lib.rs:304:26 clippy::unreadable_literal "long literal lacking separators" +rand_core-0.6.0/src/lib.rs:313:30 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +rand_core-0.6.0/src/lib.rs:314:23 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +rand_core-0.6.0/src/lib.rs:346:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +rand_core-0.6.0/src/lib.rs:381:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea" +rand_core-0.6.0/src/lib.rs:386:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea" +rand_core-0.6.0/src/lib.rs:391:5 clippy::inline_always "you have declared `#[inline(always)]` on `fill_bytes`. This is usually a bad idea" +rand_core-0.6.0/src/lib.rs:396:5 clippy::inline_always "you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea" +rayon-1.5.0/src/collections/binary_heap.rs:7:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/collections/binary_heap.rs:8:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/collections/btree_map.rs:7:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/collections/btree_map.rs:8:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/collections/btree_set.rs:7:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/collections/btree_set.rs:8:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/collections/hash_map.rs:10:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/collections/hash_map.rs:9:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/collections/hash_set.rs:10:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/collections/hash_set.rs:9:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/collections/linked_list.rs:7:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/collections/linked_list.rs:8:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/collections/mod.rs:59:32 clippy::mem_replace_with_default "replacing a value of type `T` with `T::default()` is better expressed using `std::mem::take`" +rayon-1.5.0/src/collections/vec_deque.rs:8:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/collections/vec_deque.rs:9:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/compile_fail/cannot_collect_filtermap_data.rs:2:1 clippy::needless_doctest_main "needless `fn main` in doctest" +rayon-1.5.0/src/compile_fail/cannot_zip_filtered_data.rs:2:1 clippy::needless_doctest_main "needless `fn main` in doctest" +rayon-1.5.0/src/compile_fail/cell_par_iter.rs:2:1 clippy::needless_doctest_main "needless `fn main` in doctest" +rayon-1.5.0/src/compile_fail/no_send_par_iter.rs:25:1 clippy::needless_doctest_main "needless `fn main` in doctest" +rayon-1.5.0/src/compile_fail/no_send_par_iter.rs:46:1 clippy::needless_doctest_main "needless `fn main` in doctest" +rayon-1.5.0/src/compile_fail/no_send_par_iter.rs:4:1 clippy::needless_doctest_main "needless `fn main` in doctest" +rayon-1.5.0/src/compile_fail/rc_par_iter.rs:2:1 clippy::needless_doctest_main "needless `fn main` in doctest" +rayon-1.5.0/src/iter/chain.rs:103:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/chain.rs:122:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/chain.rs:128:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/chain.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/chain.rs:221:36 clippy::doc_markdown "you should put `ExactSizeIterator` between ticks in the documentation" +rayon-1.5.0/src/iter/chain.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/chain.rs:51:38 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" +rayon-1.5.0/src/iter/chain.rs:58:14 clippy::shadow_unrelated "`a` is being shadowed" +rayon-1.5.0/src/iter/chain.rs:58:17 clippy::shadow_unrelated "`b` is being shadowed" +rayon-1.5.0/src/iter/chain.rs:78:14 clippy::shadow_unrelated "`a` is being shadowed" +rayon-1.5.0/src/iter/chain.rs:78:17 clippy::shadow_unrelated "`b` is being shadowed" +rayon-1.5.0/src/iter/chain.rs:97:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/chunks.rs:3:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/chunks.rs:4:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/chunks.rs:77:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/chunks.rs:83:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/cloned.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/cloned.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/cloned.rs:71:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/cloned.rs:75:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/collect/consumer.rs:141:5 clippy::doc_markdown "you should put `CollectReducer` between ticks in the documentation" +rayon-1.5.0/src/iter/collect/consumer.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/collect/consumer.rs:28:5 clippy::doc_markdown "you should put `CollectResult` between ticks in the documentation" +rayon-1.5.0/src/iter/collect/consumer.rs:36:37 clippy::mut_mut "generally you want to avoid `&mut &mut _` if possible" +rayon-1.5.0/src/iter/collect/consumer.rs:36:37 clippy::mut_mut "generally you want to avoid `&mut &mut _` if possible" +rayon-1.5.0/src/iter/collect/mod.rs:154:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +rayon-1.5.0/src/iter/copied.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/copied.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/copied.rs:71:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/copied.rs:75:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/empty.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/empty.rs:24:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +rayon-1.5.0/src/iter/empty.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/enumerate.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/enumerate.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/enumerate.rs:64:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/enumerate.rs:68:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/extend.rs:143:63 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon-1.5.0/src/iter/extend.rs:182:57 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon-1.5.0/src/iter/extend.rs:218:32 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon-1.5.0/src/iter/extend.rs:218:59 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon-1.5.0/src/iter/extend.rs:25:42 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon-1.5.0/src/iter/extend.rs:287:62 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon-1.5.0/src/iter/extend.rs:322:56 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon-1.5.0/src/iter/extend.rs:41:27 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon-1.5.0/src/iter/extend.rs:47:30 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon-1.5.0/src/iter/extend.rs:47:56 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon-1.5.0/src/iter/extend.rs:47:74 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon-1.5.0/src/iter/extend.rs:53:29 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon-1.5.0/src/iter/extend.rs:57:36 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon-1.5.0/src/iter/extend.rs:59:61 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" +rayon-1.5.0/src/iter/filter.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/filter.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/filter_map.rs:123:9 clippy::option_if_let_else "use Option::map_or instead of an if let/else" +rayon-1.5.0/src/iter/filter_map.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/filter_map.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/find.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/find.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/find_first_last/mod.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/find_first_last/mod.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/find_first_last/mod.rs:32:67 clippy::doc_markdown "you should put `MatchPosition` between ticks in the documentation" +rayon-1.5.0/src/iter/flat_map.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/flat_map.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/flat_map_iter.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/flat_map_iter.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/flatten.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/flatten.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/flatten_iter.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/flatten_iter.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/fold.rs:158:13 clippy::similar_names "binding's name is too similar to existing binding" +rayon-1.5.0/src/iter/fold.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/fold.rs:204:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rayon-1.5.0/src/iter/fold.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/for_each.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/for_each.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/inspect.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/inspect.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/inspect.rs:83:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/inspect.rs:88:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/interleave.rs:111:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/interleave.rs:119:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/interleave.rs:195:30 clippy::doc_markdown "you should put `self.i_len` between ticks in the documentation" +rayon-1.5.0/src/iter/interleave.rs:195:43 clippy::doc_markdown "you should put `self.j_len` between ticks in the documentation" +rayon-1.5.0/src/iter/interleave.rs:199:23 clippy::doc_markdown "you should put `self.i_len` between ticks in the documentation" +rayon-1.5.0/src/iter/interleave.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/interleave.rs:200:23 clippy::doc_markdown "you should put `self.j_len` between ticks in the documentation" +rayon-1.5.0/src/iter/interleave.rs:249:41 clippy::doc_markdown "you should put `DoubleEndedIterator` between ticks in the documentation" +rayon-1.5.0/src/iter/interleave.rs:250:5 clippy::doc_markdown "you should put `ExactSizeIterator` between ticks in the documentation" +rayon-1.5.0/src/iter/interleave.rs:263:33 clippy::doc_markdown "you should put `InterleaveSeq` between ticks in the documentation" +rayon-1.5.0/src/iter/interleave.rs:280:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +rayon-1.5.0/src/iter/interleave.rs:285:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +rayon-1.5.0/src/iter/interleave.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/interleave.rs:313:9 clippy::comparison_chain "`if` chain can be rewritten with `match`" +rayon-1.5.0/src/iter/interleave.rs:82:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/interleave.rs:90:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/interleave_shortest.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/intersperse.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/intersperse.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/intersperse.rs:90:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/intersperse.rs:96:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/len.rs:12:1 clippy::module_name_repetitions "item name ends with its containing module's name" +rayon-1.5.0/src/iter/len.rs:146:1 clippy::module_name_repetitions "item name ends with its containing module's name" +rayon-1.5.0/src/iter/len.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/len.rs:200:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/len.rs:205:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/len.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/len.rs:66:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/len.rs:71:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/map.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/map.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/map.rs:84:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/map.rs:89:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/map_with.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/map_with.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/map_with.rs:419:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/map_with.rs:425:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/map_with.rs:90:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/map_with.rs:96:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/mod.rs:1874:24 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +rayon-1.5.0/src/iter/mod.rs:2171:1 clippy::len_without_is_empty "trait `IndexedParallelIterator` has a `len` method but no (possibly inherited) `is_empty` method" +rayon-1.5.0/src/iter/mod.rs:2371:26 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +rayon-1.5.0/src/iter/mod.rs:2411:26 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +rayon-1.5.0/src/iter/mod.rs:82:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/multizip.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/multizip.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/noop.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/once.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/once.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/panic_fuse.rs:102:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/panic_fuse.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/panic_fuse.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/panic_fuse.rs:98:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/par_bridge.rs:136:28 clippy::redundant_else "redundant else block" +rayon-1.5.0/src/iter/par_bridge.rs:163:28 clippy::redundant_else "redundant else block" +rayon-1.5.0/src/iter/plumbing/mod.rs:216:58 clippy::doc_markdown "you should put `find_first` between ticks in the documentation" +rayon-1.5.0/src/iter/plumbing/mod.rs:359:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/plumbing/mod.rs:364:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/plumbing/mod.rs:399:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/plumbing/mod.rs:53:19 clippy::doc_markdown "you should put `DoubleEndedIterator` between ticks in the documentation" +rayon-1.5.0/src/iter/plumbing/mod.rs:53:43 clippy::doc_markdown "you should put `ExactSizeIterator` between ticks in the documentation" +rayon-1.5.0/src/iter/plumbing/mod.rs:54:31 clippy::doc_markdown "you should put `IntoIterator` between ticks in the documentation" +rayon-1.5.0/src/iter/plumbing/mod.rs:55:5 clippy::doc_markdown "you should put `IntoIterator` between ticks in the documentation" +rayon-1.5.0/src/iter/positions.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/positions.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/product.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/reduce.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/repeat.rs:103:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rayon-1.5.0/src/iter/repeat.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/repeat.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/rev.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/rev.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/rev.rs:63:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/rev.rs:68:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/skip.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/skip.rs:3:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/skip.rs:68:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/skip.rs:73:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/splitter.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/splitter.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/step_by.rs:4:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/step_by.rs:5:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/step_by.rs:73:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/step_by.rs:79:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/sum.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/take.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/take.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/take.rs:67:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/take.rs:72:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/try_fold.rs:190:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rayon-1.5.0/src/iter/try_fold.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/try_fold.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/try_reduce.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/try_reduce_with.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/unzip.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/unzip.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/update.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/update.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/update.rs:82:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/update.rs:87:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/while_some.rs:130:22 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +rayon-1.5.0/src/iter/while_some.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/while_some.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/zip.rs:102:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/zip.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/zip.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/zip.rs:74:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/zip.rs:79:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/zip.rs:97:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/zip_eq.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/iter/zip_eq.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/option.rs:8:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/option.rs:9:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/par_either.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/par_either.rs:3:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/private.rs:9:1 clippy::module_name_repetitions "item name starts with its containing module's name" +rayon-1.5.0/src/range.rs:19:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/range.rs:20:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/range_inclusive.rs:194:9 clippy::range_plus_one "an inclusive range would be more readable" +rayon-1.5.0/src/range_inclusive.rs:194:9 clippy::range_plus_one "an inclusive range would be more readable" +rayon-1.5.0/src/range_inclusive.rs:19:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/range_inclusive.rs:209:9 clippy::range_plus_one "an inclusive range would be more readable" +rayon-1.5.0/src/range_inclusive.rs:209:9 clippy::range_plus_one "an inclusive range would be more readable" +rayon-1.5.0/src/range_inclusive.rs:20:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/range_inclusive.rs:231:9 clippy::range_plus_one "an inclusive range would be more readable" +rayon-1.5.0/src/range_inclusive.rs:231:9 clippy::range_plus_one "an inclusive range would be more readable" +rayon-1.5.0/src/result.rs:8:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/result.rs:9:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/slice/mergesort.rs:102:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/slice/mergesort.rs:109:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/slice/mergesort.rs:114:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/slice/mergesort.rs:211:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/slice/mergesort.rs:217:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/slice/mergesort.rs:251:5 clippy::doc_markdown "you should put `TimSort` between ticks in the documentation" +rayon-1.5.0/src/slice/mergesort.rs:252:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +rayon-1.5.0/src/slice/mergesort.rs:286:59 clippy::doc_markdown "you should put `TimSort` between ticks in the documentation" +rayon-1.5.0/src/slice/mergesort.rs:333:24 clippy::redundant_else "redundant else block" +rayon-1.5.0/src/slice/mergesort.rs:513:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/slice/mergesort.rs:521:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/slice/mergesort.rs:7:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/slice/mergesort.rs:98:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/slice/mod.rs:15:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/slice/mod.rs:16:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/slice/mod.rs:17:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/slice/mod.rs:25:1 clippy::module_name_repetitions "item name ends with its containing module's name" +rayon-1.5.0/src/slice/mod.rs:657:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rayon-1.5.0/src/slice/mod.rs:971:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +rayon-1.5.0/src/slice/quicksort.rs:230:36 clippy::doc_markdown "you should put `BlockQuicksort` between ticks in the documentation" +rayon-1.5.0/src/slice/quicksort.rs:233:1 clippy::too_many_lines "this function has too many lines (117/100)" +rayon-1.5.0/src/slice/quicksort.rs:258:26 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +rayon-1.5.0/src/slice/quicksort.rs:265:26 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +rayon-1.5.0/src/slice/quicksort.rs:268:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/slice/quicksort.rs:308:30 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" +rayon-1.5.0/src/slice/quicksort.rs:325:30 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" +rayon-1.5.0/src/slice/quicksort.rs:393:36 clippy::cast_possible_wrap "casting `u8` to `isize` may wrap around the value on targets with 32-bit wide pointers" +rayon-1.5.0/src/slice/quicksort.rs:405:40 clippy::cast_possible_wrap "casting `u8` to `isize` may wrap around the value on targets with 32-bit wide pointers" +rayon-1.5.0/src/slice/quicksort.rs:430:14 clippy::shadow_unrelated "`pivot` is being shadowed" +rayon-1.5.0/src/slice/quicksort.rs:439:13 clippy::shadow_unrelated "`pivot` is being shadowed" +rayon-1.5.0/src/slice/quicksort.rs:482:10 clippy::shadow_unrelated "`pivot` is being shadowed" +rayon-1.5.0/src/slice/quicksort.rs:491:9 clippy::shadow_unrelated "`pivot` is being shadowed" +rayon-1.5.0/src/slice/quicksort.rs:534:26 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +rayon-1.5.0/src/slice/quicksort.rs:545:17 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +rayon-1.5.0/src/slice/quicksort.rs:588:17 clippy::identity_op "the operation is ineffective. Consider reducing it to `len / 4`" +rayon-1.5.0/src/slice/quicksort.rs:716:14 clippy::shadow_unrelated "`pivot` is being shadowed" +rayon-1.5.0/src/split_producer.rs:56:16 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" +rayon-1.5.0/src/split_producer.rs:92:9 clippy::option_if_let_else "use Option::map_or instead of an if let/else" +rayon-1.5.0/src/str.rs:16:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/str.rs:17:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/str.rs:18:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/str.rs:25:5 clippy::cast_possible_wrap "casting `u8` to `i8` may wrap around the value" +rayon-1.5.0/src/str.rs:715:9 clippy::manual_strip "stripping a suffix manually" +rayon-1.5.0/src/string.rs:5:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/vec.rs:137:12 clippy::len_zero "length comparison to zero" +rayon-1.5.0/src/vec.rs:8:5 clippy::wildcard_imports "usage of wildcard import" +rayon-1.5.0/src/vec.rs:9:5 clippy::wildcard_imports "usage of wildcard import" +regex-1.3.2/src/backtrack.rs:100:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/backtrack.rs:133:17 clippy::same_item_push "it looks like the same item is being pushed into this Vec" +regex-1.3.2/src/backtrack.rs:145:20 clippy::if_not_else "unnecessary boolean `not` operation" +regex-1.3.2/src/backtrack.rs:199:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/backtrack.rs:223:29 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/backtrack.rs:230:66 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/backtrack.rs:284:21 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" +regex-1.3.2/src/backtrack.rs:287:5 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex-1.3.2/src/backtrack.rs:97:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/backtrack.rs:98:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/backtrack.rs:99:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:1005:32 clippy::unreadable_literal "long literal lacking separators" +regex-1.3.2/src/compile.rs:1006:21 clippy::unreadable_literal "long literal lacking separators" +regex-1.3.2/src/compile.rs:1008:18 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" +regex-1.3.2/src/compile.rs:1009:18 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" +regex-1.3.2/src/compile.rs:1010:9 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +regex-1.3.2/src/compile.rs:102:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/compile.rs:1037:37 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" +regex-1.3.2/src/compile.rs:1037:55 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" +regex-1.3.2/src/compile.rs:1040:28 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" +regex-1.3.2/src/compile.rs:1040:38 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" +regex-1.3.2/src/compile.rs:1051:25 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +regex-1.3.2/src/compile.rs:1071:8 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" +regex-1.3.2/src/compile.rs:112:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +regex-1.3.2/src/compile.rs:112:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +regex-1.3.2/src/compile.rs:154:30 clippy::redundant_closure_for_method_calls "redundant closure found" +regex-1.3.2/src/compile.rs:156:30 clippy::redundant_closure_for_method_calls "redundant closure found" +regex-1.3.2/src/compile.rs:185:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +regex-1.3.2/src/compile.rs:187:40 clippy::redundant_closure_for_method_calls "redundant closure found" +regex-1.3.2/src/compile.rs:201:53 clippy::doc_markdown "you should put `MaybeInsts` between ticks in the documentation" +regex-1.3.2/src/compile.rs:241:63 clippy::doc_markdown "you should put `c_concat` between ticks in the documentation" +regex-1.3.2/src/compile.rs:245:5 clippy::too_many_lines "this function has too many lines (111/100)" +regex-1.3.2/src/compile.rs:247:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/compile.rs:373:24 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:373:36 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:378:12 clippy::if_not_else "unnecessary boolean `not` operation" +regex-1.3.2/src/compile.rs:400:37 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:407:51 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:409:24 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:417:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +regex-1.3.2/src/compile.rs:42:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/compile.rs:42:5 clippy::new_without_default "you should consider adding a `Default` implementation for `compile::Compiler`" +regex-1.3.2/src/compile.rs:444:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +regex-1.3.2/src/compile.rs:445:57 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:446:20 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:466:20 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:466:32 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:519:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/compile.rs:55:57 clippy::doc_markdown "you should put `size_limit` between ticks in the documentation" +regex-1.3.2/src/compile.rs:58:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/compile.rs:748:41 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:74:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/compile.rs:751:54 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:765:41 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:765:55 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:825:39 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:825:51 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:828:49 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:828:61 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:830:59 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:830:71 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:832:43 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:835:41 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:835:53 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:835:67 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:83:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/compile.rs:896:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +regex-1.3.2/src/compile.rs:905:17 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:953:17 clippy::doc_markdown "you should put `HashMap` between ticks in the documentation" +regex-1.3.2/src/compile.rs:95:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/compile.rs:980:26 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +regex-1.3.2/src/compile.rs:994:44 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/compile.rs:994:54 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/dfa.rs:1007:17 clippy::similar_names "binding's name is too similar to existing binding" +regex-1.3.2/src/dfa.rs:1010:22 clippy::similar_names "binding's name is too similar to existing binding" +regex-1.3.2/src/dfa.rs:1059:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/dfa.rs:1060:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/dfa.rs:1084:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex-1.3.2/src/dfa.rs:1087:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex-1.3.2/src/dfa.rs:1090:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex-1.3.2/src/dfa.rs:1093:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex-1.3.2/src/dfa.rs:1096:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex-1.3.2/src/dfa.rs:1101:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex-1.3.2/src/dfa.rs:1104:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex-1.3.2/src/dfa.rs:1107:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex-1.3.2/src/dfa.rs:1117:30 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex-1.3.2/src/dfa.rs:1120:47 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex-1.3.2/src/dfa.rs:1121:30 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex-1.3.2/src/dfa.rs:1129:13 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" +regex-1.3.2/src/dfa.rs:1134:13 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" +regex-1.3.2/src/dfa.rs:1185:68 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" +regex-1.3.2/src/dfa.rs:1193:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/dfa.rs:1244:50 clippy::doc_markdown "you should put `current_state` between ticks in the documentation" +regex-1.3.2/src/dfa.rs:1338:58 clippy::doc_markdown "you should put `STATE_DEAD` between ticks in the documentation" +regex-1.3.2/src/dfa.rs:1339:9 clippy::doc_markdown "you should put `STATE_UNKNOWN` between ticks in the documentation" +regex-1.3.2/src/dfa.rs:1366:25 clippy::doc_markdown "you should put `STATE_DEAD` between ticks in the documentation" +regex-1.3.2/src/dfa.rs:1366:46 clippy::doc_markdown "you should put `STATE_UNKNOWN` between ticks in the documentation" +regex-1.3.2/src/dfa.rs:1367:41 clippy::inline_always "you have declared `#[inline(always)]` on `start_state`. This is usually a bad idea" +regex-1.3.2/src/dfa.rs:1380:14 clippy::identity_op "the operation is ineffective. Consider reducing it to `(empty_flags.start as u8)`" +regex-1.3.2/src/dfa.rs:1388:15 clippy::match_on_vec_items "indexing into a vector may panic" +regex-1.3.2/src/dfa.rs:1412:20 clippy::unused_self "unused `self` argument" +regex-1.3.2/src/dfa.rs:1438:9 clippy::unused_self "unused `self` argument" +regex-1.3.2/src/dfa.rs:1472:9 clippy::doc_markdown "you should put `StatePtr` between ticks in the documentation" +regex-1.3.2/src/dfa.rs:1490:54 clippy::cast_possible_truncation "casting `i32` to `u8` may truncate the value" +regex-1.3.2/src/dfa.rs:1490:54 clippy::cast_sign_loss "casting `i32` to `u8` may lose the sign of the value" +regex-1.3.2/src/dfa.rs:1521:20 clippy::doc_markdown "you should put `num_byte_classes` between ticks in the documentation" +regex-1.3.2/src/dfa.rs:1529:41 clippy::inline_always "you have declared `#[inline(always)]` on `byte_class`. This is usually a bad idea" +regex-1.3.2/src/dfa.rs:1537:14 clippy::doc_markdown "you should put `byte_class` between ticks in the documentation" +regex-1.3.2/src/dfa.rs:1538:41 clippy::inline_always "you have declared `#[inline(always)]` on `u8_class`. This is usually a bad idea" +regex-1.3.2/src/dfa.rs:1562:18 clippy::doc_markdown "you should put `STATE_START` between ticks in the documentation" +regex-1.3.2/src/dfa.rs:1614:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/dfa.rs:1651:38 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/dfa.rs:1700:17 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +regex-1.3.2/src/dfa.rs:1701:18 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex-1.3.2/src/dfa.rs:1705:19 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex-1.3.2/src/dfa.rs:1708:16 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +regex-1.3.2/src/dfa.rs:1709:18 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex-1.3.2/src/dfa.rs:1713:19 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex-1.3.2/src/dfa.rs:1716:18 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +regex-1.3.2/src/dfa.rs:1717:18 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex-1.3.2/src/dfa.rs:1721:19 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex-1.3.2/src/dfa.rs:1727:14 clippy::cast_lossless "casting `u8` to `u16` may become silently lossy if you later change the type" +regex-1.3.2/src/dfa.rs:1732:15 clippy::trivially_copy_pass_by_ref "this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +regex-1.3.2/src/dfa.rs:1736:22 clippy::trivially_copy_pass_by_ref "this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +regex-1.3.2/src/dfa.rs:1741:9 clippy::match_like_matches_macro "match expression looks like `matches!` macro" +regex-1.3.2/src/dfa.rs:1747:16 clippy::trivially_copy_pass_by_ref "this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +regex-1.3.2/src/dfa.rs:1751:18 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" +regex-1.3.2/src/dfa.rs:1815:38 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" +regex-1.3.2/src/dfa.rs:1821:21 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" +regex-1.3.2/src/dfa.rs:1824:5 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex-1.3.2/src/dfa.rs:1848:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +regex-1.3.2/src/dfa.rs:1850:18 clippy::cast_sign_loss "casting `i32` to `u32` may lose the sign of the value" +regex-1.3.2/src/dfa.rs:1857:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +regex-1.3.2/src/dfa.rs:1860:17 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +regex-1.3.2/src/dfa.rs:1867:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +regex-1.3.2/src/dfa.rs:1870:19 clippy::cast_possible_truncation "casting `u32` to `u8` may truncate the value" +regex-1.3.2/src/dfa.rs:1873:15 clippy::cast_possible_truncation "casting `u32` to `u8` may truncate the value" +regex-1.3.2/src/dfa.rs:1876:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +regex-1.3.2/src/dfa.rs:1882:26 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +regex-1.3.2/src/dfa.rs:1884:15 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +regex-1.3.2/src/dfa.rs:277:17 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +regex-1.3.2/src/dfa.rs:277:31 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +regex-1.3.2/src/dfa.rs:295:20 clippy::cast_possible_truncation "casting `usize` to `i32` may truncate the value on targets with 64-bit wide pointers" +regex-1.3.2/src/dfa.rs:295:20 clippy::cast_possible_wrap "casting `usize` to `i32` may wrap around the value on targets with 32-bit wide pointers" +regex-1.3.2/src/dfa.rs:299:21 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" +regex-1.3.2/src/dfa.rs:34:46 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +regex-1.3.2/src/dfa.rs:398:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +regex-1.3.2/src/dfa.rs:446:41 clippy::inline_always "you have declared `#[inline(always)]` on `forward`. This is usually a bad idea" +regex-1.3.2/src/dfa.rs:457:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/dfa.rs:459:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/dfa.rs:460:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/dfa.rs:476:41 clippy::inline_always "you have declared `#[inline(always)]` on `reverse`. This is usually a bad idea" +regex-1.3.2/src/dfa.rs:487:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/dfa.rs:489:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/dfa.rs:490:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/dfa.rs:506:41 clippy::inline_always "you have declared `#[inline(always)]` on `forward_many`. This is usually a bad idea" +regex-1.3.2/src/dfa.rs:518:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/dfa.rs:520:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/dfa.rs:554:41 clippy::inline_always "you have declared `#[inline(always)]` on `exec_at`. This is usually a bad idea" +regex-1.3.2/src/dfa.rs:555:5 clippy::too_many_lines "this function has too many lines (101/100)" +regex-1.3.2/src/dfa.rs:58:9 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/dfa.rs:667:21 clippy::similar_names "binding's name is too similar to existing binding" +regex-1.3.2/src/dfa.rs:747:41 clippy::inline_always "you have declared `#[inline(always)]` on `exec_at_reverse`. This is usually a bad idea" +regex-1.3.2/src/dfa.rs:795:21 clippy::similar_names "binding's name is too similar to existing binding" +regex-1.3.2/src/dfa.rs:848:9 clippy::doc_markdown "you should put `next_si` between ticks in the documentation" +regex-1.3.2/src/dfa.rs:852:41 clippy::inline_always "you have declared `#[inline(always)]` on `next_si`. This is usually a bad idea" +regex-1.3.2/src/dfa.rs:885:12 clippy::doc_markdown "you should put `STATE_DEAD` between ticks in the documentation" +regex-1.3.2/src/dfa.rs:889:9 clippy::doc_markdown "you should put `STATE_UNKNOWN` between ticks in the documentation" +regex-1.3.2/src/dfa.rs:897:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/dfa.rs:979:29 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +regex-1.3.2/src/error.rs:6:1 clippy::manual_non_exhaustive "this seems like a manual implementation of the non-exhaustive pattern" +regex-1.3.2/src/exec.rs:1000:14 clippy::doc_markdown "you should put `captures_nfa` between ticks in the documentation" +regex-1.3.2/src/exec.rs:100:1 clippy::module_name_repetitions "item name starts with its containing module's name" +regex-1.3.2/src/exec.rs:1028:5 clippy::too_many_arguments "this function has too many arguments (9/7)" +regex-1.3.2/src/exec.rs:1039:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/exec.rs:1144:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/exec.rs:1179:26 clippy::match_same_arms "this `match` has identical arm bodies" +regex-1.3.2/src/exec.rs:122:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/exec.rs:1250:41 clippy::inline_always "you have declared `#[inline(always)]` on `searcher`. This is usually a bad idea" +regex-1.3.2/src/exec.rs:1260:41 clippy::inline_always "you have declared `#[inline(always)]` on `searcher_str`. This is usually a bad idea" +regex-1.3.2/src/exec.rs:1270:17 clippy::doc_markdown "you should put `RegexSet` between ticks in the documentation" +regex-1.3.2/src/exec.rs:1280:17 clippy::doc_markdown "you should put `RegexSet` between ticks in the documentation" +regex-1.3.2/src/exec.rs:137:9 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" +regex-1.3.2/src/exec.rs:142:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/exec.rs:1493:5 clippy::upper_case_acronyms "name `PikeVM` contains a capitalized acronym" +regex-1.3.2/src/exec.rs:158:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/exec.rs:168:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/exec.rs:181:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/exec.rs:195:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/exec.rs:204:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/exec.rs:210:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/exec.rs:245:62 clippy::if_same_then_else "this `if` has identical blocks" +regex-1.3.2/src/exec.rs:251:21 clippy::if_not_else "unnecessary boolean `not` operation" +regex-1.3.2/src/exec.rs:262:60 clippy::if_same_then_else "this `if` has identical blocks" +regex-1.3.2/src/exec.rs:268:21 clippy::if_not_else "unnecessary boolean `not` operation" +regex-1.3.2/src/exec.rs:278:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/exec.rs:281:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/exec.rs:286:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +regex-1.3.2/src/exec.rs:300:30 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/exec.rs:308:17 clippy::similar_names "binding's name is too similar to existing binding" +regex-1.3.2/src/exec.rs:329:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/exec.rs:330:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/exec.rs:331:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/exec.rs:334:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/exec.rs:340:19 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/exec.rs:344:27 clippy::unused_self "unused `self` argument" +regex-1.3.2/src/exec.rs:383:41 clippy::inline_always "you have declared `#[inline(always)]` on `shortest_match_at`. This is usually a bad idea" +regex-1.3.2/src/exec.rs:388:41 clippy::inline_always "you have declared `#[inline(always)]` on `is_match_at`. This is usually a bad idea" +regex-1.3.2/src/exec.rs:393:41 clippy::inline_always "you have declared `#[inline(always)]` on `find_at`. This is usually a bad idea" +regex-1.3.2/src/exec.rs:398:41 clippy::inline_always "you have declared `#[inline(always)]` on `captures_read_at`. This is usually a bad idea" +regex-1.3.2/src/exec.rs:425:41 clippy::inline_always "you have declared `#[inline(always)]` on `shortest_match_at`. This is usually a bad idea" +regex-1.3.2/src/exec.rs:44:1 clippy::module_name_repetitions "item name starts with its containing module's name" +regex-1.3.2/src/exec.rs:473:9 clippy::doc_markdown "you should put `shortest_match(...).is_some` between ticks in the documentation" +regex-1.3.2/src/exec.rs:474:41 clippy::inline_always "you have declared `#[inline(always)]` on `is_match_at`. This is usually a bad idea" +regex-1.3.2/src/exec.rs:524:41 clippy::inline_always "you have declared `#[inline(always)]` on `find_at`. This is usually a bad idea" +regex-1.3.2/src/exec.rs:52:1 clippy::module_name_repetitions "item name starts with its containing module's name" +regex-1.3.2/src/exec.rs:686:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/exec.rs:727:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/exec.rs:767:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/exec.rs:783:41 clippy::inline_always "you have declared `#[inline(always)]` on `shortest_dfa`. This is usually a bad idea" +regex-1.3.2/src/exec.rs:791:41 clippy::inline_always "you have declared `#[inline(always)]` on `shortest_dfa_reverse_suffix`. This is usually a bad idea" +regex-1.3.2/src/exec.rs:823:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/exec.rs:868:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/exec.rs:897:31 clippy::doc_markdown "you should put `shortest_nfa(...).is_some` between ticks in the documentation" +regex-1.3.2/src/exec.rs:899:9 clippy::doc_markdown "you should put `shortest_nfa` between ticks in the documentation" +regex-1.3.2/src/exec.rs:905:14 clippy::doc_markdown "you should put `match_nfa` between ticks in the documentation" +regex-1.3.2/src/exec.rs:930:14 clippy::doc_markdown "you should put `shortest_nfa` between ticks in the documentation" +regex-1.3.2/src/exec.rs:981:14 clippy::doc_markdown "you should put `find_nfa` between ticks in the documentation" +regex-1.3.2/src/expand.rs:170:27 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +regex-1.3.2/src/expand.rs:171:5 clippy::match_like_matches_macro "match expression looks like `matches!` macro" +regex-1.3.2/src/expand.rs:22:13 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +regex-1.3.2/src/expand.rs:27:23 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +regex-1.3.2/src/expand.rs:30:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +regex-1.3.2/src/expand.rs:38:30 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +regex-1.3.2/src/expand.rs:42:21 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +regex-1.3.2/src/expand.rs:50:1 clippy::module_name_repetitions "item name starts with its containing module's name" +regex-1.3.2/src/expand.rs:69:23 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +regex-1.3.2/src/expand.rs:80:28 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +regex-1.3.2/src/expand.rs:84:21 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +regex-1.3.2/src/expand.rs:8:1 clippy::module_name_repetitions "item name starts with its containing module's name" +regex-1.3.2/src/input.rs:142:1 clippy::module_name_repetitions "item name ends with its containing module's name" +regex-1.3.2/src/input.rs:146:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/input.rs:15:1 clippy::module_name_repetitions "item name starts with its containing module's name" +regex-1.3.2/src/input.rs:165:31 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/input.rs:178:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/input.rs:228:1 clippy::module_name_repetitions "item name ends with its containing module's name" +regex-1.3.2/src/input.rs:236:21 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/input.rs:236:33 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/input.rs:24:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/input.rs:271:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/input.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/input.rs:362:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/input.rs:370:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/input.rs:371:42 clippy::redundant_closure_for_method_calls "redundant closure found" +regex-1.3.2/src/input.rs:37:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/input.rs:388:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/input.rs:42:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/input.rs:47:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/input.rs:53:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/input.rs:58:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/input.rs:63:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/lib.rs:1:null clippy::cargo_common_metadata "package `regex` is missing `package.keywords` metadata" +regex-1.3.2/src/literal/imp.rs:101:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/literal/imp.rs:114:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/literal/imp.rs:127:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/literal/imp.rs:139:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/literal/imp.rs:144:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/literal/imp.rs:149:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/literal/imp.rs:154:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/literal/imp.rs:155:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/literal/imp.rs:160:30 clippy::match_same_arms "this `match` has identical arm bodies" +regex-1.3.2/src/literal/imp.rs:167:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/literal/imp.rs:168:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/literal/imp.rs:211:20 clippy::redundant_else "redundant else block" +regex-1.3.2/src/literal/imp.rs:239:5 clippy::upper_case_acronyms "name `AC` contains a capitalized acronym" +regex-1.3.2/src/literal/imp.rs:276:50 clippy::match_same_arms "this `match` has identical arm bodies" +regex-1.3.2/src/literal/imp.rs:342:41 clippy::inline_always "you have declared `#[inline(always)]` on `find`. This is usually a bad idea" +regex-1.3.2/src/literal/imp.rs:34:5 clippy::upper_case_acronyms "name `AC` contains a capitalized acronym" +regex-1.3.2/src/literal/imp.rs:435:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/literal/imp.rs:436:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/literal/imp.rs:437:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/literal/imp.rs:438:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/literal/imp.rs:439:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/literal/imp.rs:440:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/literal/imp.rs:455:41 clippy::inline_always "you have declared `#[inline(always)]` on `find`. This is usually a bad idea" +regex-1.3.2/src/literal/imp.rs:46:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/literal/imp.rs:481:41 clippy::inline_always "you have declared `#[inline(always)]` on `is_suffix`. This is usually a bad idea" +regex-1.3.2/src/literal/imp.rs:51:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/literal/imp.rs:579:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/literal/imp.rs:57:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/literal/imp.rs:580:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/literal/imp.rs:583:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/literal/imp.rs:602:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +regex-1.3.2/src/literal/imp.rs:622:24 clippy::redundant_else "redundant else block" +regex-1.3.2/src/literal/imp.rs:62:18 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +regex-1.3.2/src/literal/imp.rs:637:24 clippy::redundant_else "redundant else block" +regex-1.3.2/src/literal/imp.rs:648:9 clippy::needless_return "unneeded `return` statement" +regex-1.3.2/src/literal/imp.rs:651:44 clippy::doc_markdown "you should put `BoyerMooreSearch` between ticks in the documentation" +regex-1.3.2/src/literal/imp.rs:65:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/literal/imp.rs:68:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/literal/imp.rs:783:32 clippy::redundant_else "redundant else block" +regex-1.3.2/src/literal/imp.rs:786:42 clippy::manual_saturating_arithmetic "manual saturating arithmetic" +regex-1.3.2/src/literal/imp.rs:78:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/literal/imp.rs:84:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/literal/imp.rs:850:20 clippy::unreadable_literal "long literal lacking separators" +regex-1.3.2/src/literal/imp.rs:85:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/pikevm.rs:103:15 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/pikevm.rs:103:52 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/pikevm.rs:114:5 clippy::too_many_arguments "this function has too many arguments (8/7)" +regex-1.3.2/src/pikevm.rs:117:13 clippy::similar_names "binding's name is too similar to existing binding" +regex-1.3.2/src/pikevm.rs:124:17 clippy::similar_names "binding's name is too similar to existing binding" +regex-1.3.2/src/pikevm.rs:220:9 clippy::doc_markdown "you should put `thread_caps` between ticks in the documentation" +regex-1.3.2/src/pikevm.rs:222:16 clippy::doc_markdown "you should put `at_next` between ticks in the documentation" +regex-1.3.2/src/pikevm.rs:223:9 clippy::doc_markdown "you should put `at_next` between ticks in the documentation" +regex-1.3.2/src/pikevm.rs:224:5 clippy::too_many_arguments "this function has too many arguments (8/7)" +regex-1.3.2/src/pikevm.rs:234:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/pikevm.rs:303:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/pikevm.rs:331:29 clippy::mut_mut "this expression mutably borrows a mutable reference. Consider reborrowing" +regex-1.3.2/src/pikevm.rs:70:5 clippy::upper_case_acronyms "name `IP` contains a capitalized acronym" +regex-1.3.2/src/pikevm.rs:88:5 clippy::too_many_arguments "this function has too many arguments (8/7)" +regex-1.3.2/src/prog.rs:102:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/prog.rs:113:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/prog.rs:120:9 clippy::match_like_matches_macro "match expression looks like `matches!` macro" +regex-1.3.2/src/prog.rs:128:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/prog.rs:134:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/prog.rs:141:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/prog.rs:147:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/prog.rs:164:41 clippy::inline_always "you have declared `#[inline(always)]` on `deref`. This is usually a bad idea" +regex-1.3.2/src/prog.rs:172:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +regex-1.3.2/src/prog.rs:18:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +regex-1.3.2/src/prog.rs:236:13 clippy::write_with_newline "using `write!()` with a format string that ends in a single newline" +regex-1.3.2/src/prog.rs:300:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/prog.rs:301:9 clippy::match_like_matches_macro "match expression looks like `matches!` macro" +regex-1.3.2/src/prog.rs:382:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/prog.rs:409:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/prog.rs:80:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/prog.rs:80:5 clippy::new_without_default "you should consider adding a `Default` implementation for `prog::Program`" +regex-1.3.2/src/re_builder.rs:267:17 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +regex-1.3.2/src/re_builder.rs:267:17 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +regex-1.3.2/src/re_builder.rs:4:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +regex-1.3.2/src/re_builder.rs:57:17 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_builder.rs:57:17 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_builder.rs:68:17 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +regex-1.3.2/src/re_builder.rs:68:17 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +regex-1.3.2/src/re_bytes.rs:1017:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +regex-1.3.2/src/re_bytes.rs:1039:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +regex-1.3.2/src/re_bytes.rs:1093:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +regex-1.3.2/src/re_bytes.rs:1118:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +regex-1.3.2/src/re_bytes.rs:1133:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +regex-1.3.2/src/re_bytes.rs:118:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +regex-1.3.2/src/re_bytes.rs:256:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/re_bytes.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_bytes.rs:35:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_bytes.rs:42:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_bytes.rs:483:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +regex-1.3.2/src/re_bytes.rs:48:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_bytes.rs:558:29 clippy::doc_markdown "you should put `shortest_match` between ticks in the documentation" +regex-1.3.2/src/re_bytes.rs:55:33 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/re_bytes.rs:55:47 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/re_bytes.rs:572:29 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" +regex-1.3.2/src/re_bytes.rs:720:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/re_bytes.rs:817:5 clippy::doc_markdown "you should put `CaptureLocations` between ticks in the documentation" +regex-1.3.2/src/re_bytes.rs:843:1 clippy::len_without_is_empty "item `re_bytes::CaptureLocations` has a public `len` method but no corresponding `is_empty` method" +regex-1.3.2/src/re_bytes.rs:849:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_bytes.rs:858:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_bytes.rs:869:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_bytes.rs:891:1 clippy::len_without_is_empty "item `re_bytes::Captures<'t>` has a public `len` method but no corresponding `is_empty` method" +regex-1.3.2/src/re_bytes.rs:911:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_bytes.rs:917:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_bytes.rs:926:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_bytes.rs:955:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_set.rs:179:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/re_set.rs:179:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/re_set.rs:251:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_set.rs:251:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_set.rs:263:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_set.rs:263:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_set.rs:268:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_set.rs:268:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_set.rs:277:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_set.rs:277:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_set.rs:94:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +regex-1.3.2/src/re_set.rs:94:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +regex-1.3.2/src/re_trait.rs:136:29 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/re_unicode.rs:1019:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +regex-1.3.2/src/re_unicode.rs:1041:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +regex-1.3.2/src/re_unicode.rs:1088:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/re_unicode.rs:1135:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +regex-1.3.2/src/re_unicode.rs:1160:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +regex-1.3.2/src/re_unicode.rs:174:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +regex-1.3.2/src/re_unicode.rs:21:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +regex-1.3.2/src/re_unicode.rs:313:13 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/re_unicode.rs:38:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_unicode.rs:44:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_unicode.rs:51:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_unicode.rs:533:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +regex-1.3.2/src/re_unicode.rs:57:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_unicode.rs:617:29 clippy::doc_markdown "you should put `shortest_match` between ticks in the documentation" +regex-1.3.2/src/re_unicode.rs:631:29 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" +regex-1.3.2/src/re_unicode.rs:64:33 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/re_unicode.rs:64:47 clippy::redundant_field_names "redundant field names in struct initialization" +regex-1.3.2/src/re_unicode.rs:834:5 clippy::doc_markdown "you should put `CaptureLocations` between ticks in the documentation" +regex-1.3.2/src/re_unicode.rs:860:1 clippy::len_without_is_empty "item `re_unicode::CaptureLocations` has a public `len` method but no corresponding `is_empty` method" +regex-1.3.2/src/re_unicode.rs:866:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_unicode.rs:875:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_unicode.rs:886:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_unicode.rs:908:1 clippy::len_without_is_empty "item `re_unicode::Captures<'t>` has a public `len` method but no corresponding `is_empty` method" +regex-1.3.2/src/re_unicode.rs:928:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_unicode.rs:934:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_unicode.rs:943:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/re_unicode.rs:972:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +regex-1.3.2/src/sparse.rs:10:37 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +regex-1.3.2/src/sparse.rs:15:1 clippy::module_name_repetitions "item name starts with its containing module's name" +regex-1.3.2/src/utf8.rs:100:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex-1.3.2/src/utf8.rs:103:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex-1.3.2/src/utf8.rs:106:22 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +regex-1.3.2/src/utf8.rs:107:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +regex-1.3.2/src/utf8.rs:108:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +regex-1.3.2/src/utf8.rs:109:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +regex-1.3.2/src/utf8.rs:111:27 clippy::unreadable_literal "long literal lacking separators" +regex-1.3.2/src/utf8.rs:121:1 clippy::module_name_repetitions "item name ends with its containing module's name" +regex-1.3.2/src/utf8.rs:143:24 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex-1.3.2/src/utf8.rs:143:9 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex-1.3.2/src/utf8.rs:23:1 clippy::module_name_repetitions "item name ends with its containing module's name" +regex-1.3.2/src/utf8.rs:30:20 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex-1.3.2/src/utf8.rs:51:1 clippy::module_name_repetitions "item name ends with its containing module's name" +regex-1.3.2/src/utf8.rs:58:23 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex-1.3.2/src/utf8.rs:58:9 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex-1.3.2/src/utf8.rs:63:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex-1.3.2/src/utf8.rs:66:22 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +regex-1.3.2/src/utf8.rs:66:54 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +regex-1.3.2/src/utf8.rs:77:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex-1.3.2/src/utf8.rs:80:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex-1.3.2/src/utf8.rs:83:22 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +regex-1.3.2/src/utf8.rs:84:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +regex-1.3.2/src/utf8.rs:85:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +regex-1.3.2/src/utf8.rs:92:23 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex-1.3.2/src/utf8.rs:92:9 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +regex-1.3.2/src/utf8.rs:97:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +ripgrep-12.1.1//home/matthias/.rustup/toolchains/nightly-2021-02-03-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std/src/panic.rs:30:27 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep-12.1.1//home/matthias/.rustup/toolchains/nightly-2021-02-03-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std/src/panic.rs:30:27 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep-12.1.1//home/matthias/.rustup/toolchains/nightly-2021-02-03-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std/src/panic.rs:30:27 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep-12.1.1//home/matthias/.rustup/toolchains/nightly-2021-02-03-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std/src/panic.rs:30:27 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep-12.1.1/build.rs:133:19 clippy::option_as_ref_deref "called `.as_ref().map(|x| &**x)` on an Option value. This can be done more directly by calling `githash.as_deref()` instead" +ripgrep-12.1.1/build.rs:18:18 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +ripgrep-12.1.1/build.rs:225:14 clippy::redundant_closure_for_method_calls "redundant closure found" +ripgrep-12.1.1/build.rs:92:19 clippy::option_as_ref_deref "called `.as_ref().map(|x| &**x)` on an Option value. This can be done more directly by calling `githash.as_deref()` instead" +ripgrep-12.1.1/crates/core/app.rs:1408:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep-12.1.1/crates/core/app.rs:1408:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep-12.1.1/crates/core/app.rs:1409:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep-12.1.1/crates/core/app.rs:1409:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep-12.1.1/crates/core/app.rs:152:32 clippy::doc_markdown "you should put `clap::Arg` between ticks in the documentation" +ripgrep-12.1.1/crates/core/app.rs:152:32 clippy::doc_markdown "you should put `clap::Arg` between ticks in the documentation" +ripgrep-12.1.1/crates/core/app.rs:156:39 clippy::doc_markdown "you should put `clap::Arg` between ticks in the documentation" +ripgrep-12.1.1/crates/core/app.rs:156:39 clippy::doc_markdown "you should put `clap::Arg` between ticks in the documentation" +ripgrep-12.1.1/crates/core/app.rs:156:5 clippy::doc_markdown "you should put `RGArg` between ticks in the documentation" +ripgrep-12.1.1/crates/core/app.rs:156:5 clippy::doc_markdown "you should put `RGArg` between ticks in the documentation" +ripgrep-12.1.1/crates/core/app.rs:164:12 clippy::upper_case_acronyms "name `RGArg` contains a capitalized acronym" +ripgrep-12.1.1/crates/core/app.rs:164:12 clippy::upper_case_acronyms "name `RGArg` contains a capitalized acronym" +ripgrep-12.1.1/crates/core/app.rs:1668:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep-12.1.1/crates/core/app.rs:1668:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep-12.1.1/crates/core/app.rs:1669:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep-12.1.1/crates/core/app.rs:1669:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep-12.1.1/crates/core/app.rs:1821:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep-12.1.1/crates/core/app.rs:1821:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep-12.1.1/crates/core/app.rs:1822:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep-12.1.1/crates/core/app.rs:1822:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep-12.1.1/crates/core/app.rs:212:10 clippy::upper_case_acronyms "name `RGArgKind` contains a capitalized acronym" +ripgrep-12.1.1/crates/core/app.rs:212:10 clippy::upper_case_acronyms "name `RGArgKind` contains a capitalized acronym" +ripgrep-12.1.1/crates/core/app.rs:2999:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep-12.1.1/crates/core/app.rs:2999:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep-12.1.1/crates/core/app.rs:3000:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep-12.1.1/crates/core/app.rs:3000:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +ripgrep-12.1.1/crates/core/app.rs:367:54 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep-12.1.1/crates/core/app.rs:367:54 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep-12.1.1/crates/core/app.rs:414:59 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep-12.1.1/crates/core/app.rs:414:59 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep-12.1.1/crates/core/app.rs:417:57 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep-12.1.1/crates/core/app.rs:417:57 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep-12.1.1/crates/core/app.rs:417:57 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep-12.1.1/crates/core/app.rs:417:57 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep-12.1.1/crates/core/app.rs:75:9 clippy::doc_markdown "you should put `RIPGREP_BUILD_GIT_HASH` between ticks in the documentation" +ripgrep-12.1.1/crates/core/app.rs:75:9 clippy::doc_markdown "you should put `RIPGREP_BUILD_GIT_HASH` between ticks in the documentation" +ripgrep-12.1.1/crates/core/app.rs:87:5 clippy::if_not_else "unnecessary boolean `not` operation" +ripgrep-12.1.1/crates/core/app.rs:87:5 clippy::if_not_else "unnecessary boolean `not` operation" +ripgrep-12.1.1/crates/core/args.rs:1143:22 clippy::unused_self "unused `self` argument" +ripgrep-12.1.1/crates/core/args.rs:11:1 clippy::single_component_path_imports "this import is redundant" +ripgrep-12.1.1/crates/core/args.rs:1209:74 clippy::if_same_then_else "this `if` has identical blocks" +ripgrep-12.1.1/crates/core/args.rs:1282:13 clippy::similar_names "binding's name is too similar to existing binding" +ripgrep-12.1.1/crates/core/args.rs:1430:22 clippy::unused_self "unused `self` argument" +ripgrep-12.1.1/crates/core/args.rs:1438:21 clippy::doc_markdown "you should put `OsStr` between ticks in the documentation" +ripgrep-12.1.1/crates/core/args.rs:1520:44 clippy::redundant_closure_for_method_calls "redundant closure found" +ripgrep-12.1.1/crates/core/args.rs:1524:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +ripgrep-12.1.1/crates/core/args.rs:1635:14 clippy::doc_markdown "you should put `values_of_lossy` between ticks in the documentation" +ripgrep-12.1.1/crates/core/args.rs:1693:41 clippy::redundant_closure_for_method_calls "redundant closure found" +ripgrep-12.1.1/crates/core/args.rs:1770:17 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +ripgrep-12.1.1/crates/core/args.rs:287:13 clippy::similar_names "binding's name is too similar to existing binding" +ripgrep-12.1.1/crates/core/args.rs:33:1 clippy::single_component_path_imports "this import is redundant" +ripgrep-12.1.1/crates/core/args.rs:34:1 clippy::single_component_path_imports "this import is redundant" +ripgrep-12.1.1/crates/core/args.rs:35:1 clippy::single_component_path_imports "this import is redundant" +ripgrep-12.1.1/crates/core/args.rs:369:5 clippy::upper_case_acronyms "name `JSON` contains a capitalized acronym" +ripgrep-12.1.1/crates/core/args.rs:410:14 clippy::trivially_copy_pass_by_ref "this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +ripgrep-12.1.1/crates/core/args.rs:475:18 clippy::match_same_arms "this `match` has identical arm bodies" +ripgrep-12.1.1/crates/core/args.rs:512:19 clippy::doc_markdown "you should put `ArgMatches` between ticks in the documentation" +ripgrep-12.1.1/crates/core/args.rs:549:16 clippy::wrong_self_convention "methods called `to_*` usually take self by reference; consider choosing a less ambiguous name" +ripgrep-12.1.1/crates/core/args.rs:71:5 clippy::upper_case_acronyms "name `PCRE2Version` contains a capitalized acronym" +ripgrep-12.1.1/crates/core/args.rs:76:18 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +ripgrep-12.1.1/crates/core/args.rs:77:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +ripgrep-12.1.1/crates/core/args.rs:923:42 clippy::doc_markdown "you should put `BinaryDetection::quit` between ticks in the documentation" +ripgrep-12.1.1/crates/core/config.rs:13:1 clippy::single_component_path_imports "this import is redundant" +ripgrep-12.1.1/crates/core/config.rs:58:6 clippy::type_complexity "very complex type used. Consider factoring parts into `type` definitions" +ripgrep-12.1.1/crates/core/config.rs:79:6 clippy::type_complexity "very complex type used. Consider factoring parts into `type` definitions" +ripgrep-12.1.1/crates/core/logger.rs:11:30 clippy::doc_markdown "you should put `max_level` between ticks in the documentation" +ripgrep-12.1.1/crates/core/logger.rs:15:16 clippy::redundant_static_lifetimes "constants have by default a `'static` lifetime" +ripgrep-12.1.1/crates/core/main.rs:55:19 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +ripgrep-12.1.1/crates/core/main.rs:56:9 clippy::enum_glob_use "usage of wildcard import for enum variants" +ripgrep-12.1.1/crates/core/messages.rs:46:1 clippy::module_name_repetitions "item name ends with its containing module's name" +ripgrep-12.1.1/crates/core/messages.rs:51:1 clippy::module_name_repetitions "item name ends with its containing module's name" +ripgrep-12.1.1/crates/core/messages.rs:62:1 clippy::module_name_repetitions "item name ends with its containing module's name" +ripgrep-12.1.1/crates/core/path_printer.rs:27:1 clippy::module_name_repetitions "item name starts with its containing module's name" +ripgrep-12.1.1/crates/core/path_printer.rs:89:9 clippy::if_not_else "unnecessary boolean `not` operation" +ripgrep-12.1.1/crates/core/search.rs:185:1 clippy::module_name_repetitions "item name starts with its containing module's name" +ripgrep-12.1.1/crates/core/search.rs:224:5 clippy::upper_case_acronyms "name `JSON` contains a capitalized acronym" +ripgrep-12.1.1/crates/core/search.rs:292:9 clippy::write_with_newline "using `write!()` with a format string that ends in a single newline" +ripgrep-12.1.1/crates/core/search.rs:311:1 clippy::module_name_repetitions "item name starts with its containing module's name" +ripgrep-12.1.1/crates/core/search.rs:377:12 clippy::nonminimal_bool "this boolean expression can be simplified" +ripgrep-12.1.1/crates/core/search.rs:423:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +ripgrep-12.1.1/crates/core/search.rs:447:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +ripgrep-12.1.1/crates/core/search.rs:472:24 clippy::map_clone "you are using an explicit closure for cloning elements" +ripgrep-12.1.1/crates/core/search.rs:472:41 clippy::redundant_closure_for_method_calls "redundant closure found" +ripgrep-12.1.1/crates/core/search.rs:480:24 clippy::map_clone "you are using an explicit closure for cloning elements" +ripgrep-12.1.1/crates/core/search.rs:480:41 clippy::redundant_closure_for_method_calls "redundant closure found" +ripgrep-12.1.1/crates/core/search.rs:49:1 clippy::module_name_repetitions "item name starts with its containing module's name" +ripgrep-12.1.1/crates/core/search.rs:509:24 clippy::map_clone "you are using an explicit closure for cloning elements" +ripgrep-12.1.1/crates/core/search.rs:509:41 clippy::redundant_closure_for_method_calls "redundant closure found" +ripgrep-12.1.1/crates/core/search.rs:517:24 clippy::map_clone "you are using an explicit closure for cloning elements" +ripgrep-12.1.1/crates/core/search.rs:517:41 clippy::redundant_closure_for_method_calls "redundant closure found" +ripgrep-12.1.1/crates/core/search.rs:533:36 clippy::cast_lossless "casting `u32` to `f64` may become silently lossy if you later change the type" +ripgrep-12.1.1/crates/core/search.rs:533:5 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +ripgrep-12.1.1/crates/core/subject.rs:20:1 clippy::module_name_repetitions "item name starts with its containing module's name" +ripgrep-12.1.1/crates/core/subject.rs:4:1 clippy::single_component_path_imports "this import is redundant" +syn-1.0.54/build.rs:1:null clippy::cargo_common_metadata "package `syn` is missing `package.keywords` metadata" +syn-1.0.54/build.rs:1:null clippy::multiple_crate_versions "could not read cargo metadata: `cargo metadata` exited with an error: Downloading crates ...\n Downloaded syn-test-suite v0.0.0\nerror: failed to verify the checksum of `syn-test-suite v0.0.0`" +syn-1.0.54/src/generics.rs:174:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +syn-1.0.54/src/lib.rs:1:null clippy::cargo_common_metadata "package `syn` is missing `package.keywords` metadata" +syn-1.0.54/src/lib.rs:1:null clippy::multiple_crate_versions "could not read cargo metadata: `cargo metadata` exited with an error: Downloading crates ...\n Downloaded syn-test-suite v0.0.0\nerror: failed to verify the checksum of `syn-test-suite v0.0.0`" +syn-1.0.54/src/lit.rs:1397:40 clippy::redundant_else "redundant else block" +syn-1.0.54/src/lit.rs:1405:28 clippy::redundant_else "redundant else block" +syn-1.0.54/src/lit.rs:1485:32 clippy::redundant_else "redundant else block" +syn-1.0.54/src/lit.rs:343:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +syn-1.0.54/src/lit.rs:437:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +syn-1.0.54/src/lit.rs:916:9 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +syn-1.0.54/src/token.rs:974:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +syn-1.0.54/src/token.rs:996:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +unicode-xid-0.2.1/src/lib.rs:1:null clippy::cargo_common_metadata "package `unicode-xid` is missing `package.categories` metadata" +unicode-xid-0.2.1/src/lib.rs:56:11 clippy::upper_case_acronyms "name `UnicodeXID` contains a capitalized acronym" +unicode-xid-0.2.1/src/lib.rs:57:64 clippy::doc_markdown "you should put `XID_Start` between ticks in the documentation" +unicode-xid-0.2.1/src/lib.rs:60:10 clippy::doc_markdown "you should put `XID_Start` between ticks in the documentation" +unicode-xid-0.2.1/src/lib.rs:62:27 clippy::doc_markdown "you should put `ID_Start` between ticks in the documentation" +unicode-xid-0.2.1/src/lib.rs:62:67 clippy::doc_markdown "you should put `NFKx` between ticks in the documentation" +unicode-xid-0.2.1/src/lib.rs:63:21 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" +unicode-xid-0.2.1/src/lib.rs:65:61 clippy::doc_markdown "you should put `XID_Continue` between ticks in the documentation" +unicode-xid-0.2.1/src/lib.rs:68:10 clippy::doc_markdown "you should put `XID_Continue` between ticks in the documentation" +unicode-xid-0.2.1/src/lib.rs:70:28 clippy::doc_markdown "you should put `ID_Continue` between ticks in the documentation" +unicode-xid-0.2.1/src/lib.rs:70:72 clippy::doc_markdown "you should put `NFKx` between ticks in the documentation" +unicode-xid-0.2.1/src/lib.rs:71:24 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" +xsv-0.13.0/src/cmd/cat.rs:101:34 clippy::redundant_closure_for_method_calls "redundant closure found" +xsv-0.13.0/src/cmd/cat.rs:42:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +xsv-0.13.0/src/cmd/cat.rs:53:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/cat.rs:7:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv-0.13.0/src/cmd/count.rs:32:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/count.rs:38:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +xsv-0.13.0/src/cmd/count.rs:42:33 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +xsv-0.13.0/src/cmd/count.rs:50:5 clippy::unit_arg "passing a unit value to a function" +xsv-0.13.0/src/cmd/count.rs:7:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv-0.13.0/src/cmd/fixlengths.rs:45:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/fixlengths.rs:50:18 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +xsv-0.13.0/src/cmd/fixlengths.rs:62:30 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +xsv-0.13.0/src/cmd/fixlengths.rs:9:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv-0.13.0/src/cmd/flatten.rs:10:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv-0.13.0/src/cmd/flatten.rs:51:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/fmt.rs:50:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/fmt.rs:55:13 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/fmt.rs:7:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv-0.13.0/src/cmd/frequency.rs:148:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +xsv-0.13.0/src/cmd/frequency.rs:149:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +xsv-0.13.0/src/cmd/frequency.rs:15:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv-0.13.0/src/cmd/frequency.rs:169:13 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/frequency.rs:176:17 clippy::if_not_else "unnecessary boolean `not` operation" +xsv-0.13.0/src/cmd/frequency.rs:178:24 clippy::collapsible_else_if "this `else { if .. }` block can be collapsed" +xsv-0.13.0/src/cmd/frequency.rs:77:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/frequency.rs:93:31 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" +xsv-0.13.0/src/cmd/headers.rs:43:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/headers.rs:49:17 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" +xsv-0.13.0/src/cmd/headers.rs:9:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv-0.13.0/src/cmd/index.rs:11:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv-0.13.0/src/cmd/index.rs:45:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/input.rs:42:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/input.rs:47:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/input.rs:7:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv-0.13.0/src/cmd/join.rs:17:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv-0.13.0/src/cmd/join.rs:194:29 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/join.rs:224:22 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/join.rs:293:14 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/join.rs:293:20 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/join.rs:297:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv-0.13.0/src/cmd/join.rs:298:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv-0.13.0/src/cmd/join.rs:299:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv-0.13.0/src/cmd/join.rs:300:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv-0.13.0/src/cmd/join.rs:308:9 clippy::unused_self "unused `self` argument" +xsv-0.13.0/src/cmd/join.rs:342:38 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +xsv-0.13.0/src/cmd/join.rs:342:46 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +xsv-0.13.0/src/cmd/join.rs:347:9 clippy::if_not_else "unnecessary boolean `not` operation" +xsv-0.13.0/src/cmd/join.rs:372:44 clippy::redundant_closure_for_method_calls "redundant closure found" +xsv-0.13.0/src/cmd/join.rs:375:33 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/join.rs:392:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv-0.13.0/src/cmd/join.rs:403:29 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" +xsv-0.13.0/src/cmd/join.rs:426:13 clippy::if_not_else "unnecessary boolean `not` operation" +xsv-0.13.0/src/cmd/join.rs:77:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +xsv-0.13.0/src/cmd/join.rs:94:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/partition.rs:105:22 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/partition.rs:106:22 clippy::redundant_slicing "redundant slicing of the whole range" +xsv-0.13.0/src/cmd/partition.rs:139:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv-0.13.0/src/cmd/partition.rs:15:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv-0.13.0/src/cmd/partition.rs:169:9 clippy::if_not_else "unnecessary boolean `not` operation" +xsv-0.13.0/src/cmd/partition.rs:56:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/partition.rs:77:9 clippy::unused_self "unused `self` argument" +xsv-0.13.0/src/cmd/sample.rs:105:44 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +xsv-0.13.0/src/cmd/sample.rs:115:21 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +xsv-0.13.0/src/cmd/sample.rs:11:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv-0.13.0/src/cmd/sample.rs:51:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/sample.rs:58:19 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +xsv-0.13.0/src/cmd/sample.rs:69:9 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +xsv-0.13.0/src/cmd/sample.rs:75:16 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" +xsv-0.13.0/src/cmd/sample.rs:91:42 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +xsv-0.13.0/src/cmd/sample.rs:92:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +xsv-0.13.0/src/cmd/search.rs:51:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/search.rs:9:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv-0.13.0/src/cmd/select.rs:60:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/select.rs:8:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv-0.13.0/src/cmd/slice.rs:57:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/slice.rs:9:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv-0.13.0/src/cmd/sort.rs:11:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv-0.13.0/src/cmd/sort.rs:138:47 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +xsv-0.13.0/src/cmd/sort.rs:139:51 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +xsv-0.13.0/src/cmd/sort.rs:48:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/sort.rs:91:14 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" +xsv-0.13.0/src/cmd/split.rs:14:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv-0.13.0/src/cmd/split.rs:61:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/split.rs:94:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +xsv-0.13.0/src/cmd/split.rs:96:14 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +xsv-0.13.0/src/cmd/split.rs:99:13 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +xsv-0.13.0/src/cmd/stats.rs:110:36 clippy::redundant_closure_for_method_calls "redundant closure found" +xsv-0.13.0/src/cmd/stats.rs:127:14 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +xsv-0.13.0/src/cmd/stats.rs:138:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +xsv-0.13.0/src/cmd/stats.rs:139:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +xsv-0.13.0/src/cmd/stats.rs:162:25 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" +xsv-0.13.0/src/cmd/stats.rs:22:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv-0.13.0/src/cmd/stats.rs:231:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +xsv-0.13.0/src/cmd/stats.rs:262:35 clippy::default_trait_access "calling `cmd::stats::TypedSum::default()` is more clear than this expression" +xsv-0.13.0/src/cmd/stats.rs:263:40 clippy::default_trait_access "calling `cmd::stats::TypedMinMax::default()` is more clear than this expression" +xsv-0.13.0/src/cmd/stats.rs:264:39 clippy::default_trait_access "calling `stats::OnlineStats::default()` is more clear than this expression" +xsv-0.13.0/src/cmd/stats.rs:265:58 clippy::default_trait_access "calling `stats::Unsorted::default()` is more clear than this expression" +xsv-0.13.0/src/cmd/stats.rs:266:41 clippy::default_trait_access "calling `stats::Unsorted::default()` is more clear than this expression" +xsv-0.13.0/src/cmd/stats.rs:268:18 clippy::default_trait_access "calling `cmd::stats::FieldType::default()` is more clear than this expression" +xsv-0.13.0/src/cmd/stats.rs:269:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv-0.13.0/src/cmd/stats.rs:270:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv-0.13.0/src/cmd/stats.rs:271:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv-0.13.0/src/cmd/stats.rs:272:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv-0.13.0/src/cmd/stats.rs:273:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv-0.13.0/src/cmd/stats.rs:274:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv-0.13.0/src/cmd/stats.rs:283:9 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" +xsv-0.13.0/src/cmd/stats.rs:284:9 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" +xsv-0.13.0/src/cmd/stats.rs:285:9 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" +xsv-0.13.0/src/cmd/stats.rs:290:21 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" +xsv-0.13.0/src/cmd/stats.rs:293:25 clippy::match_same_arms "this `match` has identical arm bodies" +xsv-0.13.0/src/cmd/stats.rs:297:25 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" +xsv-0.13.0/src/cmd/stats.rs:301:21 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" +xsv-0.13.0/src/cmd/stats.rs:302:21 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" +xsv-0.13.0/src/cmd/stats.rs:308:18 clippy::wrong_self_convention "methods called `to_*` usually take self by reference; consider choosing a less ambiguous name" +xsv-0.13.0/src/cmd/stats.rs:318:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +xsv-0.13.0/src/cmd/stats.rs:322:45 clippy::redundant_closure_for_method_calls "redundant closure found" +xsv-0.13.0/src/cmd/stats.rs:322:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +xsv-0.13.0/src/cmd/stats.rs:327:9 clippy::if_not_else "unnecessary boolean `not` operation" +xsv-0.13.0/src/cmd/stats.rs:330:13 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +xsv-0.13.0/src/cmd/stats.rs:338:45 clippy::redundant_closure_for_method_calls "redundant closure found" +xsv-0.13.0/src/cmd/stats.rs:402:16 clippy::redundant_pattern_matching "redundant pattern matching, consider using `is_ok()`" +xsv-0.13.0/src/cmd/stats.rs:403:16 clippy::redundant_pattern_matching "redundant pattern matching, consider using `is_ok()`" +xsv-0.13.0/src/cmd/stats.rs:407:18 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +xsv-0.13.0/src/cmd/stats.rs:411:16 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +xsv-0.13.0/src/cmd/stats.rs:427:56 clippy::match_same_arms "this `match` has identical arm bodies" +xsv-0.13.0/src/cmd/stats.rs:429:56 clippy::match_same_arms "this `match` has identical arm bodies" +xsv-0.13.0/src/cmd/stats.rs:430:60 clippy::match_same_arms "this `match` has identical arm bodies" +xsv-0.13.0/src/cmd/stats.rs:430:60 clippy::match_same_arms "this `match` has identical arm bodies" +xsv-0.13.0/src/cmd/stats.rs:454:5 clippy::doc_markdown "you should put `TypedSum` between ticks in the documentation" +xsv-0.13.0/src/cmd/stats.rs:473:43 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +xsv-0.13.0/src/cmd/stats.rs:504:56 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +xsv-0.13.0/src/cmd/stats.rs:505:51 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +xsv-0.13.0/src/cmd/stats.rs:511:5 clippy::doc_markdown "you should put `TypedMinMax` between ticks in the documentation" +xsv-0.13.0/src/cmd/stats.rs:536:35 clippy::cast_possible_truncation "casting `f64` to `i64` may truncate the value" +xsv-0.13.0/src/cmd/stats.rs:544:33 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +xsv-0.13.0/src/cmd/stats.rs:592:22 clippy::default_trait_access "calling `stats::MinMax::default()` is more clear than this expression" +xsv-0.13.0/src/cmd/stats.rs:593:22 clippy::default_trait_access "calling `stats::MinMax::default()` is more clear than this expression" +xsv-0.13.0/src/cmd/stats.rs:594:23 clippy::default_trait_access "calling `stats::MinMax::default()` is more clear than this expression" +xsv-0.13.0/src/cmd/stats.rs:595:21 clippy::default_trait_access "calling `stats::MinMax::default()` is more clear than this expression" +xsv-0.13.0/src/cmd/stats.rs:71:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +xsv-0.13.0/src/cmd/stats.rs:86:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/table.rs:10:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv-0.13.0/src/cmd/table.rs:50:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/cmd/table.rs:54:9 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/config.rs:113:43 clippy::or_fun_call "use of `unwrap_or` followed by a function call" +xsv-0.13.0/src/config.rs:58:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +xsv-0.13.0/src/config.rs:77:28 clippy::explicit_deref_methods "explicit deref method call" +xsv-0.13.0/src/config.rs:90:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv-0.13.0/src/index.rs:31:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv-0.13.0/src/main.rs:164:49 clippy::redundant_clone "redundant clone" +xsv-0.13.0/src/main.rs:1:null clippy::cargo_common_metadata "package `xsv` is missing `package.categories` metadata" +xsv-0.13.0/src/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `rand_core`: 0.3.1, 0.4.2" +xsv-0.13.0/src/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `rand`: 0.3.23, 0.4.6" +xsv-0.13.0/src/main.rs:75:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +xsv-0.13.0/src/select.rs:13:1 clippy::module_name_repetitions "item name starts with its containing module's name" +xsv-0.13.0/src/select.rs:154:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +xsv-0.13.0/src/select.rs:250:33 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/select.rs:250:43 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/select.rs:255:39 clippy::range_plus_one "an inclusive range would be more readable" +xsv-0.13.0/src/select.rs:280:20 clippy::len_zero "length comparison to zero" +xsv-0.13.0/src/select.rs:29:13 clippy::redundant_field_names "redundant field names in struct initialization" +xsv-0.13.0/src/select.rs:360:62 clippy::trivially_copy_pass_by_ref "this argument (8 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +xsv-0.13.0/src/select.rs:360:9 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Option`" +xsv-0.13.0/src/select.rs:375:9 clippy::stable_sort_primitive "used `sort` on primitive type `usize`" +xsv-0.13.0/src/select.rs:379:18 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" +xsv-0.13.0/src/select.rs:416:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +xsv-0.13.0/src/select.rs:419:9 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Option`" +xsv-0.13.0/src/select.rs:420:27 clippy::option_option "consider using `Option` instead of `Option>` or a custom enum if you need to distinguish all 3 cases" +xsv-0.13.0/src/select.rs:99:17 clippy::similar_names "binding's name is too similar to existing binding" +xsv-0.13.0/src/util.rs:150:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +xsv-0.13.0/src/util.rs:37:33 clippy::map_clone "you are using an explicit closure for copying elements" +xsv-0.13.0/src/util.rs:90:1 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" + + + + +Stats + +clippy::clone_on_copy 1 +clippy::comparison_chain 1 +clippy::expect_fun_call 1 +clippy::explicit_deref_methods 1 +clippy::from_iter_instead_of_collect 1 +clippy::from_over_into 1 +clippy::int_plus_one 1 +clippy::manual_flatten 1 +clippy::manual_saturating_arithmetic 1 +clippy::mem_replace_with_default 1 +clippy::nonminimal_bool 1 +clippy::or_fun_call 1 +clippy::precedence 1 +clippy::pub_enum_variant_names 1 +clippy::redundant_clone 1 +clippy::redundant_slicing 1 +clippy::same_item_push 1 +clippy::should_implement_trait 1 +clippy::stable_sort_primitive 1 +clippy::unit_arg 1 +clippy::unnecessary_lazy_evaluations 1 +clippy::unsafe_derive_deserialize 1 +clippy::used_underscore_binding 1 +clippy::verbose_bit_mask 1 +clippy::while_let_on_iterator 1 +clippy::comparison_to_empty 2 +clippy::derive_hash_xor_eq 2 +clippy::expl_impl_clone_on_copy 2 +clippy::filter_map 2 +clippy::len_zero 2 +clippy::manual_non_exhaustive 2 +clippy::match_on_vec_items 2 +clippy::option_as_ref_deref 2 +clippy::option_option 2 +clippy::question_mark 2 +clippy::redundant_pattern_matching 2 +clippy::type_complexity 2 +clippy::unnecessary_cast 2 +clippy::unused_unit 2 +clippy::vec_init_then_push 2 +clippy::write_with_newline 2 +clippy::filter_map_next 3 +clippy::fn_params_excessive_bools 3 +clippy::if_same_then_else 3 +clippy::mut_mut 3 +clippy::ptr_arg 3 +clippy::zero_ptr 3 +clippy::let_underscore_drop 4 +clippy::too_many_arguments 4 +clippy::explicit_iter_loop 5 +clippy::field_reassign_with_default 5 +clippy::identity_op 5 +clippy::len_without_is_empty 5 +clippy::match_like_matches_macro 5 +clippy::needless_return 5 +clippy::new_without_default 5 +clippy::ptr_as_ptr 5 +clippy::collapsible_else_if 6 +clippy::manual_strip 6 +clippy::non_ascii_literal 6 +clippy::single_component_path_imports 6 +clippy::case_sensitive_file_extension_comparisons 7 +clippy::explicit_into_iter_loop 7 +clippy::map_clone 7 +clippy::option_map_unit_fn 7 +clippy::range_plus_one 7 +clippy::invalid_upcast_comparisons 8 +clippy::needless_question_mark 8 +clippy::wrong_self_convention 8 +clippy::manual_range_contains 10 +clippy::match_wildcard_for_single_variants 10 +clippy::missing_safety_doc 10 +clippy::needless_doctest_main 10 +clippy::multiple_crate_versions 11 +clippy::needless_lifetimes 12 +clippy::cargo_common_metadata 13 +clippy::shadow_unrelated 13 +clippy::linkedlist 14 +clippy::single_char_add_str 14 +clippy::option_if_let_else 15 +clippy::needless_pass_by_value 18 +clippy::upper_case_acronyms 18 +clippy::cast_possible_wrap 19 +clippy::cast_sign_loss 19 +clippy::unnecessary_wraps 19 +clippy::unused_self 19 +clippy::unusual_byte_groupings 19 +clippy::map_unwrap_or 20 +clippy::struct_excessive_bools 20 +clippy::redundant_static_lifetimes 21 +clippy::default_trait_access 22 +clippy::cast_lossless 23 +clippy::trivially_copy_pass_by_ref 26 +clippy::redundant_else 29 +clippy::too_many_lines 32 +clippy::if_not_else 35 +clippy::enum_glob_use 40 +clippy::unseparated_literal_suffix 41 +clippy::cast_precision_loss 44 +clippy::single_match_else 45 +clippy::inline_always 59 +clippy::match_same_arms 65 +clippy::similar_names 78 +clippy::cast_possible_truncation 95 +clippy::missing_panics_doc 108 +clippy::redundant_field_names 111 +clippy::redundant_closure_for_method_calls 135 +clippy::items_after_statements 139 +clippy::module_name_repetitions 142 +clippy::wildcard_imports 163 +clippy::doc_markdown 178 +clippy::missing_errors_doc 343 +clippy::unreadable_literal 365 +clippy::must_use_candidate 565 diff --git a/lintcheck-logs/logs.txt b/lintcheck-logs/logs.txt deleted file mode 100644 index 3bc7758033b..00000000000 --- a/lintcheck-logs/logs.txt +++ /dev/null @@ -1,3535 +0,0 @@ -clippy 0.1.51 (7f5bb7fd0 2021-02-06) - -cargo-0.49.0//home/matthias/.rustup/toolchains/nightly-2021-02-03-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/core/src/macros/mod.rs:409:34 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/build.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.categories` metadata" -cargo-0.49.0/build.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.keywords` metadata" -cargo-0.49.0/src/bin/cargo/cli.rs:104:34 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/bin/cargo/cli.rs:121:5 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo-0.49.0/src/bin/cargo/cli.rs:157:30 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/cli.rs:184:41 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" -cargo-0.49.0/src/bin/cargo/cli.rs:196:42 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/cli.rs:200:39 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/cli.rs:231:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo-0.49.0/src/bin/cargo/cli.rs:245:22 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" -cargo-0.49.0/src/bin/cargo/cli.rs:247:47 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/cli.rs:257:22 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/cli.rs:26:20 clippy::redundant_else "redundant else block" -cargo-0.49.0/src/bin/cargo/cli.rs:7:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/bench.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/bench.rs:76:59 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/commands/build.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/check.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/clean.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/doc.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/fetch.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/fix.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/generate_lockfile.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/git_checkout.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/help.rs:20:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/bin/cargo/commands/init.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/install.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/install.rs:97:16 clippy::option_if_let_else "use Option::map_or instead of an if let/else" -cargo-0.49.0/src/bin/cargo/commands/locate_project.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/login.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/metadata.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/mod.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/new.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/new.rs:20:24 clippy::option_if_let_else "use Option::map_or instead of an if let/else" -cargo-0.49.0/src/bin/cargo/commands/owner.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/owner.rs:38:43 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/commands/owner.rs:39:43 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/commands/owner.rs:40:43 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/commands/owner.rs:43:30 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/commands/owner.rs:46:30 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/commands/package.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/pkgid.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/publish.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/publish.rs:40:47 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/commands/read_manifest.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/run.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/rustc.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/rustdoc.rs:3:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/search.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/test.rs:127:54 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/commands/test.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/tree.rs:149:49 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/commands/tree.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/uninstall.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/update.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/vendor.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/vendor.rs:96:16 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" -cargo-0.49.0/src/bin/cargo/commands/verify_project.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/version.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/yank.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/yank.rs:32:36 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/commands/yank.rs:33:35 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/commands/yank.rs:34:36 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/commands/yank.rs:35:36 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/main.rs:100:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" -cargo-0.49.0/src/bin/cargo/main.rs:118:41 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/main.rs:137:43 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/main.rs:148:19 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/bin/cargo/main.rs:174:57 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/main.rs:18:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/main.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.categories` metadata" -cargo-0.49.0/src/bin/cargo/main.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.keywords` metadata" -cargo-0.49.0/src/bin/cargo/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `crossbeam-utils`: 0.6.6, 0.7.2" -cargo-0.49.0/src/bin/cargo/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `hex`: 0.3.2, 0.4.0" -cargo-0.49.0/src/bin/cargo/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `humantime`: 1.3.0, 2.0.0" -cargo-0.49.0/src/bin/cargo/main.rs:72:22 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/main.rs:94:13 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" -cargo-0.49.0/src/bin/cargo/main.rs:96:41 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/main.rs:98:60 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/compiler/build_config.rs:155:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -cargo-0.49.0/src/cargo/core/compiler/build_config.rs:170:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/build_config.rs:175:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/build_config.rs:180:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/build_config.rs:186:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/build_config.rs:197:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/build_config.rs:205:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/build_config.rs:51:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/build_config.rs:69:48 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -cargo-0.49.0/src/cargo/core/compiler/build_config.rs:96:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/build_context/mod.rs:44:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/build_context/mod.rs:83:20 clippy::doc_markdown "you should put `x86_64` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:108:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:121:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:149:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:411:9 clippy::needless_question_mark "Question mark operator is useless here" -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:420:69 clippy::doc_markdown "you should put `mode/target_kind` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:423:19 clippy::doc_markdown "you should put `CrateTypes` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:424:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:424:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:469:58 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:603:19 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:665:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:82:31 clippy::doc_markdown "you should put `FileType` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:83:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:84:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:96:31 clippy::doc_markdown "you should put `FileType` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:98:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/build_plan.rs:4:9 clippy::doc_markdown "you should put `BuildPlan` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/build_plan.rs:5:66 clippy::doc_markdown "you should put `BuildPlan` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/build_plan.rs:66:40 clippy::ptr_arg "writing `&PathBuf` instead of `&Path` involves a new object where a slice will do." -cargo-0.49.0/src/cargo/core/compiler/compilation.rs:150:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/compilation.rs:150:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/compiler/compilation.rs:169:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/compilation.rs:185:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/compilation.rs:193:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/compilation.rs:194:49 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/compiler/compilation.rs:198:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/compilation.rs:314:16 clippy::doc_markdown "you should put `rustc_tool` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/compilation.rs:91:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:118:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:123:18 clippy::case_sensitive_file_extension_comparisons "case-sensitive file extension comparison" -cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:147:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:157:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:157:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:33:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:49:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:69:48 clippy::case_sensitive_file_extension_comparisons "case-sensitive file extension comparison" -cargo-0.49.0/src/cargo/core/compiler/context/compilation_files.rs:204:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/core/compiler/context/compilation_files.rs:277:22 clippy::doc_markdown "you should put `OUT_DIR` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/context/compilation_files.rs:324:66 clippy::doc_markdown "you should put `FileType` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/context/compilation_files.rs:393:37 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/compiler/context/compilation_files.rs:426:71 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:125:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:125:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:125:5 clippy::too_many_lines "this function has too many lines (107/100)" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:270:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:286:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:308:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:308:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:340:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:340:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:349:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:349:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:354:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:358:21 clippy::doc_markdown "you should put `RunCustomBuild` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:361:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:374:43 clippy::doc_markdown "you should put `RunCustomBuild` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:378:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:383:41 clippy::doc_markdown "you should put `RunCustomBuild` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:384:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:384:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:391:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:397:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:523:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:538:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:542:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:83:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:92:25 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/core/compiler/crate_type.rs:16:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/crate_type.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/crate_type.rs:40:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/crate_type.rs:49:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/crate_type.rs:60:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:150:1 clippy::too_many_lines "this function has too many lines (230/100)" -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:353:56 clippy::manual_strip "stripping a prefix manually" -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:448:27 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:464:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:481:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:481:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:48:56 clippy::doc_markdown "you should put `RunCustomBuild` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:561:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:561:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:567:20 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:576:28 clippy::shadow_unrelated "`mut value` is being shadowed" -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:606:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:688:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:756:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:762:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:762:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:823:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1021:51 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1656:16 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1664:5 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1787:5 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1795:5 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1882:17 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1894:17 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1906:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1917:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1923:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1956:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1962:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1963:22 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1964:22 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1965:22 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1966:22 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1980:17 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1980:24 clippy::manual_strip "stripping a prefix manually" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1986:17 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:2016:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:61:5 clippy::doc_markdown "you should put `CompileMode` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:63:12 clippy::doc_markdown "you should put `CompileKind` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:67:7 clippy::doc_markdown "you should put `CARGO_DEFAULT_LIB_METADATA[^4` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:68:5 clippy::doc_markdown "you should put `package_id` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:71:19 clippy::doc_markdown "you should put `test/bench/for_host/edition` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:755:52 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:77:5 clippy::doc_markdown "you should put `is_std` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:816:5 clippy::too_many_lines "this function has too many lines (127/100)" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:863:64 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:875:33 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:876:32 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:896:30 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:897:30 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:991:37 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:12:5 clippy::doc_markdown "you should put `src/librustc_jobserver/lib.rs` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:329:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:332:23 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:34:53 clippy::doc_markdown "you should put `NeedsToken` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:35:6 clippy::doc_markdown "you should put `ReleaseToken` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:37:6 clippy::doc_markdown "you should put `NeedsToken` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:40:5 clippy::doc_markdown "you should put `NeedsToken` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:40:56 clippy::doc_markdown "you should put `NeedsToken` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:43:6 clippy::doc_markdown "you should put `ReleaseToken` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:748:16 clippy::collapsible_else_if "this `else { if .. }` block can be collapsed" -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:749:13 clippy::if_not_else "unnecessary boolean `not` operation" -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:786:26 clippy::unused_self "unused `self` argument" -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:81:61 clippy::doc_markdown "you should put `DrainState` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:865:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:871:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:890:9 clippy::unused_self "unused `self` argument" -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:93:24 clippy::doc_markdown "you should put `JobQueue` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/links.rs:8:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:1016:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:1094:19 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:1131:1 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:1268:34 clippy::case_sensitive_file_extension_comparisons "case-sensitive file extension comparison" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:1277:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:179:1 clippy::too_many_lines "this function has too many lines (162/100)" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:198:78 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:201:25 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:267:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:324:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:364:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:364:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:392:45 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:415:23 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:464:18 clippy::ptr_arg "writing `&PathBuf` instead of `&Path` involves a new object where a slice will do." -cargo-0.49.0/src/cargo/core/compiler/mod.rs:488:61 clippy::ptr_arg "writing `&PathBuf` instead of `&Path` involves a new object where a slice will do." -cargo-0.49.0/src/cargo/core/compiler/mod.rs:667:15 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:693:1 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:725:42 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:736:1 clippy::too_many_lines "this function has too many lines (141/100)" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:73:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:777:12 clippy::if_not_else "unnecessary boolean `not` operation" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:873:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/compiler/output_depinfo.rs:41:13 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" -cargo-0.49.0/src/cargo/core/compiler/rustdoc.rs:16:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/core/compiler/rustdoc.rs:57:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/core/compiler/rustdoc.rs:72:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/standard_lib.rs:134:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/standard_lib.rs:16:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/standard_lib.rs:30:28 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/compiler/standard_lib.rs:34:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/standard_lib.rs:34:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/compiler/timings.rs:16:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo-0.49.0/src/cargo/core/compiler/timings.rs:192:64 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo-0.49.0/src/cargo/core/compiler/timings.rs:212:58 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo-0.49.0/src/cargo/core/compiler/timings.rs:234:13 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" -cargo-0.49.0/src/cargo/core/compiler/timings.rs:355:13 clippy::cast_possible_truncation "casting `f64` to `u32` may truncate the value" -cargo-0.49.0/src/cargo/core/compiler/timings.rs:355:13 clippy::cast_sign_loss "casting `f64` to `u32` may lose the sign of the value" -cargo-0.49.0/src/cargo/core/compiler/timings.rs:397:38 clippy::cast_possible_truncation "casting `f64` to `u32` may truncate the value" -cargo-0.49.0/src/cargo/core/compiler/timings.rs:397:38 clippy::cast_sign_loss "casting `f64` to `u32` may lose the sign of the value" -cargo-0.49.0/src/cargo/core/compiler/timings.rs:484:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/compiler/timings.rs:605:38 clippy::doc_markdown "you should put `rmeta_time` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/timings.rs:605:50 clippy::doc_markdown "you should put `codegen_time` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/timings.rs:641:26 clippy::non_ascii_literal "literal non-ASCII character detected" -cargo-0.49.0/src/cargo/core/compiler/unit.rs:100:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/unit.rs:151:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/core/compiler/unit.rs:161:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/unit.rs:35:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/core/compiler/unit_dependencies.rs:154:29 clippy::doc_markdown "you should put `state.unit_dependencies` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/unit_dependencies.rs:213:1 clippy::too_many_lines "this function has too many lines (110/100)" -cargo-0.49.0/src/cargo/core/compiler/unit_dependencies.rs:52:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/unit_dependencies.rs:52:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/core/compiler/unit_graph.rs:65:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/unit_graph.rs:65:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/core/dependency.rs:157:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/dependency.rs:182:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/dependency.rs:203:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/dependency.rs:203:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/dependency.rs:224:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/dependency.rs:23:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo-0.49.0/src/cargo/core/dependency.rs:248:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/dependency.rs:270:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/dependency.rs:274:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/dependency.rs:278:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/dependency.rs:287:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/dependency.rs:291:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/dependency.rs:296:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/dependency.rs:305:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/dependency.rs:311:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/dependency.rs:319:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/dependency.rs:323:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/dependency.rs:337:75 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/dependency.rs:379:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/dependency.rs:397:56 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/dependency.rs:403:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/dependency.rs:408:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/dependency.rs:415:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/dependency.rs:419:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/dependency.rs:424:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/dependency.rs:428:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/dependency.rs:433:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/dependency.rs:438:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/dependency.rs:443:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/dependency.rs:449:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/dependency.rs:450:9 clippy::if_not_else "unnecessary `!=` operation" -cargo-0.49.0/src/cargo/core/features.rs:119:17 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/features.rs:229:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/features.rs:274:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/features.rs:278:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/features.rs:306:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/features.rs:338:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo-0.49.0/src/cargo/core/features.rs:362:25 clippy::option_option "consider using `Option` instead of `Option>` or a custom enum if you need to distinguish all 3 cases" -cargo-0.49.0/src/cargo/core/features.rs:380:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/features.rs:401:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/features.rs:409:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/features.rs:412:45 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/features.rs:416:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/features.rs:419:45 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/features.rs:424:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/features.rs:431:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/features.rs:477:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/features.rs:509:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/features.rs:518:5 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" -cargo-0.49.0/src/cargo/core/features.rs:542:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/features.rs:543:37 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/features.rs:547:60 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/features.rs:556:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/core/features.rs:563:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/core/manifest.rs:116:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -cargo-0.49.0/src/cargo/core/manifest.rs:118:58 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/manifest.rs:130:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -cargo-0.49.0/src/cargo/core/manifest.rs:143:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:159:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:162:34 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/manifest.rs:169:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:17:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/cargo/core/manifest.rs:189:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo-0.49.0/src/cargo/core/manifest.rs:215:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:222:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:22:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/core/manifest.rs:360:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:407:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:410:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:413:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:416:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:419:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:422:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:425:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:431:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:438:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:444:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:447:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:450:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:453:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:456:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:459:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:462:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:466:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:470:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:477:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:481:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:488:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/manifest.rs:512:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:516:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:520:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:524:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:528:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:538:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:557:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:561:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:565:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:569:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:577:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:581:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:588:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:617:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:632:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:648:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:659:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:66:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/core/manifest.rs:670:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:693:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:708:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:723:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:726:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:729:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:735:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:738:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:741:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:744:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:747:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:751:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:754:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:757:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:760:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:763:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:767:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:776:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:780:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:787:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:798:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:800:56 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/manifest.rs:805:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:809:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:818:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:823:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:828:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:831:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:834:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:839:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:85:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/core/manifest.rs:888:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:936:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package.rs:1075:28 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/package.rs:160:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package.rs:170:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package.rs:174:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package.rs:182:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package.rs:186:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package.rs:190:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package.rs:194:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/package.rs:194:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package.rs:198:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package.rs:202:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package.rs:206:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package.rs:210:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package.rs:217:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package.rs:221:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package.rs:222:35 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/package.rs:226:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package.rs:227:35 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/package.rs:230:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package.rs:239:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/package.rs:249:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package.rs:287:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/core/package.rs:385:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/package.rs:421:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -cargo-0.49.0/src/cargo/core/package.rs:425:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/package.rs:425:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/package.rs:452:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/package.rs:453:60 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/package.rs:459:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/package.rs:473:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/package.rs:552:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/package.rs:587:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/package.rs:588:9 clippy::needless_question_mark "Question mark operator is useless here" -cargo-0.49.0/src/cargo/core/package.rs:682:46 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" -cargo-0.49.0/src/cargo/core/package.rs:682:46 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" -cargo-0.49.0/src/cargo/core/package.rs:682:63 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" -cargo-0.49.0/src/cargo/core/package.rs:682:63 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" -cargo-0.49.0/src/cargo/core/package.rs:731:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/package.rs:790:13 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/core/package.rs:988:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/core/package_id.rs:115:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/package_id.rs:124:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/package_id.rs:124:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package_id.rs:139:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package_id.rs:142:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package_id.rs:145:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package_id.rs:149:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package_id.rs:157:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package_id.rs:161:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package_id.rs:169:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package_id.rs:174:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/core/package_id_spec.rs:101:39 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/package_id_spec.rs:143:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package_id_spec.rs:147:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package_id_spec.rs:151:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package_id_spec.rs:160:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package_id_spec.rs:179:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/package_id_spec.rs:212:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/package_id_spec.rs:231:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/core/package_id_spec.rs:51:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/package_id_spec.rs:51:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/package_id_spec.rs:77:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/package_id_spec.rs:88:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/profiles.rs:1004:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/profiles.rs:1004:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/profiles.rs:1014:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/profiles.rs:1018:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/profiles.rs:1028:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/profiles.rs:106:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/profiles.rs:143:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -cargo-0.49.0/src/cargo/core/profiles.rs:286:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/profiles.rs:286:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/profiles.rs:294:40 clippy::if_not_else "unnecessary boolean `not` operation" -cargo-0.49.0/src/cargo/core/profiles.rs:30:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/profiles.rs:342:25 clippy::shadow_unrelated "`maker` is being shadowed" -cargo-0.49.0/src/cargo/core/profiles.rs:370:41 clippy::unused_self "unused `self` argument" -cargo-0.49.0/src/cargo/core/profiles.rs:370:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/profiles.rs:372:9 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" -cargo-0.49.0/src/cargo/core/profiles.rs:382:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/profiles.rs:382:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/profiles.rs:383:28 clippy::if_not_else "unnecessary boolean `not` operation" -cargo-0.49.0/src/cargo/core/profiles.rs:397:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/profiles.rs:405:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/profiles.rs:607:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo-0.49.0/src/cargo/core/profiles.rs:909:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/profiles.rs:923:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/profiles.rs:934:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/profiles.rs:987:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/registry.rs:111:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/registry.rs:127:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/registry.rs:168:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/registry.rs:19:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/registry.rs:240:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/registry.rs:26:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/registry.rs:344:49 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/registry.rs:358:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/registry.rs:369:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/registry.rs:424:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/registry.rs:424:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/registry.rs:49:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/core/registry.rs:520:17 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/core/registry.rs:763:53 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/registry.rs:765:53 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/registry.rs:807:14 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/registry.rs:814:53 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/resolver/conflict_cache.rs:197:29 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/resolver/conflict_cache.rs:41:38 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" -cargo-0.49.0/src/cargo/core/resolver/context.rs:274:53 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/resolver/context.rs:42:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/core/resolver/context.rs:74:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/encode.rs:156:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/resolver/encode.rs:156:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/resolver/encode.rs:156:5 clippy::too_many_lines "this function has too many lines (164/100)" -cargo-0.49.0/src/cargo/core/resolver/encode.rs:339:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" -cargo-0.49.0/src/cargo/core/resolver/encode.rs:438:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/resolver/encode.rs:449:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/resolver/encode.rs:529:34 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/resolver/encode.rs:602:59 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/resolver/encode.rs:623:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/core/resolver/encode.rs:652:27 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/core/resolver/encode.rs:674:51 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/resolver/errors.rs:103:22 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/resolver/errors.rs:104:22 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/resolver/errors.rs:206:9 clippy::if_not_else "unnecessary boolean `not` operation" -cargo-0.49.0/src/cargo/core/resolver/errors.rs:257:45 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/resolver/errors.rs:27:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/errors.rs:305:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo-0.49.0/src/cargo/core/resolver/errors.rs:70:1 clippy::too_many_lines "this function has too many lines (207/100)" -cargo-0.49.0/src/cargo/core/resolver/features.rs:104:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/core/resolver/features.rs:111:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/features.rs:162:56 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/resolver/features.rs:179:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/core/resolver/features.rs:186:23 clippy::doc_markdown "you should put `RequestedFeatures` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/resolver/features.rs:187:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/features.rs:199:23 clippy::doc_markdown "you should put `RequestedFeatures` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/resolver/features.rs:200:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/features.rs:221:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/features.rs:231:21 clippy::doc_markdown "you should put `pkg_id/is_build` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/resolver/features.rs:233:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/features.rs:247:58 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/resolver/features.rs:278:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/resolver/features.rs:394:27 clippy::doc_markdown "you should put `FeatureValue` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/resolver/features.rs:460:19 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/core/resolver/features.rs:480:24 clippy::doc_markdown "you should put `FeatureValues` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/resolver/features.rs:496:24 clippy::doc_markdown "you should put `FeatureValues` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/resolver/features.rs:58:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/core/resolver/features.rs:67:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo-0.49.0/src/cargo/core/resolver/mod.rs:1017:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/resolver/mod.rs:1045:57 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/resolver/mod.rs:122:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/resolver/mod.rs:142:44 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/resolver/mod.rs:180:1 clippy::too_many_lines "this function has too many lines (225/100)" -cargo-0.49.0/src/cargo/core/resolver/mod.rs:311:17 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/core/resolver/mod.rs:421:52 clippy::filter_map_next "called `filter_map(..).next()` on an `Iterator`. This is more succinctly expressed by calling `.find_map(..)` instead." -cargo-0.49.0/src/cargo/core/resolver/mod.rs:457:69 clippy::filter_map_next "called `filter_map(..).next()` on an `Iterator`. This is more succinctly expressed by calling `.find_map(..)` instead." -cargo-0.49.0/src/cargo/core/resolver/mod.rs:470:37 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/core/resolver/mod.rs:607:11 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo-0.49.0/src/cargo/core/resolver/mod.rs:631:21 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/core/resolver/mod.rs:942:15 clippy::if_not_else "unnecessary boolean `not` operation" -cargo-0.49.0/src/cargo/core/resolver/mod.rs:988:20 clippy::redundant_else "redundant else block" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:120:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:132:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:199:24 clippy::redundant_else "redundant else block" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:235:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:239:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:255:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:259:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:263:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:269:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:273:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:273:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:274:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:280:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:284:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:288:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:292:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:296:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:300:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:315:13 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:354:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:362:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:60:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:76:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/types.rs:111:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/resolver/types.rs:121:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/types.rs:141:19 clippy::doc_markdown "you should put `ResolveOpts` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/resolver/types.rs:142:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/types.rs:149:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/types.rs:181:9 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" -cargo-0.49.0/src/cargo/core/resolver/types.rs:187:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -cargo-0.49.0/src/cargo/core/resolver/types.rs:261:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -cargo-0.49.0/src/cargo/core/shell.rs:113:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/shell.rs:130:9 clippy::single_match_else "you seem to be trying to use `match` for an equality check. Consider using `if`" -cargo-0.49.0/src/cargo/core/shell.rs:148:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/shell.rs:153:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/shell.rs:163:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/shell.rs:18:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/shell.rs:198:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/shell.rs:206:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/shell.rs:214:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/shell.rs:228:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/shell.rs:239:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/shell.rs:250:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/shell.rs:259:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/shell.rs:267:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/shell.rs:26:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/shell.rs:277:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/shell.rs:282:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/shell.rs:314:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/shell.rs:322:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/shell.rs:330:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/shell.rs:345:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/shell.rs:98:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/source/mod.rs:103:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/source/mod.rs:247:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/core/source/mod.rs:261:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/source/mod.rs:268:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/source/mod.rs:273:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/source/mod.rs:291:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/source/mod.rs:302:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/source/mod.rs:307:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/source/mod.rs:31:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/source/mod.rs:37:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/source/mod.rs:39:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/source/mod.rs:47:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/source/mod.rs:50:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/source/mod.rs:52:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/source/mod.rs:63:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/source/mod.rs:74:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/source/mod.rs:83:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/source/source_id.rs:107:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/source/source_id.rs:107:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/source/source_id.rs:128:50 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/source/source_id.rs:147:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/source/source_id.rs:156:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/source/source_id.rs:162:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/source/source_id.rs:166:19 clippy::doc_markdown "you should put `SourceId` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/source/source_id.rs:167:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/source/source_id.rs:171:19 clippy::doc_markdown "you should put `SourceId` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/source/source_id.rs:172:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/source/source_id.rs:178:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/source/source_id.rs:187:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/source/source_id.rs:187:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/source/source_id.rs:18:74 clippy::default_trait_access "calling `std::sync::Mutex::default()` is more clear than this expression" -cargo-0.49.0/src/cargo/core/source/source_id.rs:195:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/source/source_id.rs:207:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/source/source_id.rs:213:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/source/source_id.rs:217:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/source/source_id.rs:225:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/source/source_id.rs:228:16 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" -cargo-0.49.0/src/cargo/core/source/source_id.rs:236:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/source/source_id.rs:241:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/source/source_id.rs:252:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/source/source_id.rs:257:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/source/source_id.rs:262:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/source/source_id.rs:262:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/source/source_id.rs:305:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/source/source_id.rs:310:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/source/source_id.rs:318:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/source/source_id.rs:326:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/source/source_id.rs:338:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/source/source_id.rs:355:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/source/source_id.rs:393:61 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:394:42 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:395:42 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:397:71 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:397:71 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:398:47 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:398:47 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:399:47 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:399:47 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:401:63 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:401:63 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:401:63 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:402:43 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:402:43 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:402:43 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:403:43 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:403:43 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:403:43 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:406:21 clippy::enum_glob_use "usage of wildcard import for enum variants" -cargo-0.49.0/src/cargo/core/source/source_id.rs:412:41 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:413:36 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:414:36 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:420:47 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:420:47 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:512:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo-0.49.0/src/cargo/core/source/source_id.rs:513:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo-0.49.0/src/cargo/core/source/source_id.rs:517:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo-0.49.0/src/cargo/core/source/source_id.rs:518:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo-0.49.0/src/cargo/core/source/source_id.rs:525:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo-0.49.0/src/cargo/core/source/source_id.rs:526:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo-0.49.0/src/cargo/core/source/source_id.rs:530:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo-0.49.0/src/cargo/core/source/source_id.rs:531:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo-0.49.0/src/cargo/core/source/source_id.rs:535:33 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo-0.49.0/src/cargo/core/source/source_id.rs:536:37 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo-0.49.0/src/cargo/core/source/source_id.rs:537:42 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo-0.49.0/src/cargo/core/source/source_id.rs:538:38 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo-0.49.0/src/cargo/core/source/source_id.rs:548:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/core/source/source_id.rs:597:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/summary.rs:103:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/summary.rs:123:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/summary.rs:150:1 clippy::too_many_lines "this function has too many lines (141/100)" -cargo-0.49.0/src/cargo/core/summary.rs:158:9 clippy::enum_glob_use "usage of wildcard import for enum variants" -cargo-0.49.0/src/cargo/core/summary.rs:181:21 clippy::if_not_else "unnecessary boolean `not` operation" -cargo-0.49.0/src/cargo/core/summary.rs:192:28 clippy::redundant_else "redundant else block" -cargo-0.49.0/src/cargo/core/summary.rs:258:32 clippy::redundant_else "redundant else block" -cargo-0.49.0/src/cargo/core/summary.rs:281:28 clippy::redundant_else "redundant else block" -cargo-0.49.0/src/cargo/core/summary.rs:303:28 clippy::redundant_else "redundant else block" -cargo-0.49.0/src/cargo/core/summary.rs:321:51 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/summary.rs:344:5 clippy::doc_markdown "you should put `FeatureValue` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/summary.rs:350:85 clippy::doc_markdown "you should put `FeatureValue` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/summary.rs:36:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/summary.rs:378:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/summary.rs:386:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/summary.rs:387:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -cargo-0.49.0/src/cargo/core/summary.rs:407:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -cargo-0.49.0/src/cargo/core/summary.rs:69:34 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/summary.rs:75:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/summary.rs:78:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/summary.rs:81:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/summary.rs:84:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/summary.rs:87:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/summary.rs:90:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/summary.rs:93:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/summary.rs:96:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/summary.rs:99:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/workspace.rs:1056:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -cargo-0.49.0/src/cargo/core/workspace.rs:113:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/core/workspace.rs:1157:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/workspace.rs:128:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/core/workspace.rs:150:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/workspace.rs:159:16 clippy::redundant_else "redundant else block" -cargo-0.49.0/src/cargo/core/workspace.rs:197:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/workspace.rs:225:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/workspace.rs:225:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/workspace.rs:255:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/workspace.rs:267:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/workspace.rs:317:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/workspace.rs:329:37 clippy::doc_markdown "you should put `VirtualManifest` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/workspace.rs:410:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/workspace.rs:440:9 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -cargo-0.49.0/src/cargo/core/workspace.rs:511:32 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/core/workspace.rs:561:25 clippy::non_ascii_literal "literal non-ASCII character detected" -cargo-0.49.0/src/cargo/core/workspace.rs:613:13 clippy::filter_map "called `filter_map(..).map(..)` on an `Iterator`" -cargo-0.49.0/src/cargo/core/workspace.rs:615:22 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/workspace.rs:762:27 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/core/workspace.rs:784:17 clippy::if_not_else "unnecessary boolean `not` operation" -cargo-0.49.0/src/cargo/core/workspace.rs:849:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/workspace.rs:849:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/workspace.rs:893:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/workspace.rs:906:24 clippy::redundant_else "redundant else block" -cargo-0.49.0/src/cargo/core/workspace.rs:932:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/workspace.rs:932:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/lib.rs:177:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/lib.rs:177:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/lib.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.categories` metadata" -cargo-0.49.0/src/cargo/lib.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.keywords` metadata" -cargo-0.49.0/src/cargo/lib.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `crossbeam-utils`: 0.6.6, 0.7.2" -cargo-0.49.0/src/cargo/lib.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `hex`: 0.3.2, 0.4.0" -cargo-0.49.0/src/cargo/lib.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `humantime`: 1.3.0, 2.0.0" -cargo-0.49.0/src/cargo/ops/cargo_clean.rs:205:23 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/ops/cargo_clean.rs:27:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_clean.rs:27:1 clippy::too_many_lines "this function has too many lines (120/100)" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:1078:14 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:109:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:119:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:1227:17 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:127:35 clippy::from_iter_instead_of_collect "usage of `FromIterator::from_iter`" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:173:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:205:36 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:242:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:249:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:258:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:267:16 clippy::needless_question_mark "Question mark operator is useless here" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:275:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:275:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:275:1 clippy::too_many_lines "this function has too many lines (219/100)" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:468:9 clippy::default_trait_access "calling `std::collections::HashMap::default()` is more clear than this expression" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:548:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:556:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:574:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:583:21 clippy::doc_markdown "you should put `CompileFilter` between ticks in the documentation" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:584:5 clippy::fn_params_excessive_bools "more than 3 bools in function parameters" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:584:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:592:9 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:593:9 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:607:13 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:612:21 clippy::doc_markdown "you should put `CompileFilter` between ticks in the documentation" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:613:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:618:9 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:641:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:652:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:652:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:655:50 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:673:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:692:49 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:703:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:729:1 clippy::too_many_lines "this function has too many lines (205/100)" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:82:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:874:69 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/ops/cargo_doc.rs:20:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_fetch.rs:15:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_fetch.rs:27:46 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:160:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:175:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:22:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:37:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:37:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:37:1 clippy::too_many_lines "this function has too many lines (171/100)" -cargo-0.49.0/src/cargo/ops/cargo_install.rs:13:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/cargo/ops/cargo_install.rs:148:1 clippy::fn_params_excessive_bools "more than 3 bools in function parameters" -cargo-0.49.0/src/cargo/ops/cargo_install.rs:148:1 clippy::too_many_lines "this function has too many lines (316/100)" -cargo-0.49.0/src/cargo/ops/cargo_install.rs:178:24 clippy::collapsible_else_if "this `else { if .. }` block can be collapsed" -cargo-0.49.0/src/cargo/ops/cargo_install.rs:202:17 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/ops/cargo_install.rs:236:16 clippy::collapsible_else_if "this `else { if .. }` block can be collapsed" -cargo-0.49.0/src/cargo/ops/cargo_install.rs:312:64 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/ops/cargo_install.rs:32:13 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" -cargo-0.49.0/src/cargo/ops/cargo_install.rs:339:12 clippy::collapsible_else_if "this `else { if .. }` block can be collapsed" -cargo-0.49.0/src/cargo/ops/cargo_install.rs:37:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_install.rs:454:22 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/ops/cargo_install.rs:483:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/ops/cargo_install.rs:683:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_install.rs:708:5 clippy::manual_flatten "unnecessary `if let` since only the `Some` variant of the iterator element is used" -cargo-0.49.0/src/cargo/ops/cargo_new.rs:101:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_new.rs:245:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/ops/cargo_new.rs:251:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/ops/cargo_new.rs:367:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_new.rs:405:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_new.rs:489:5 clippy::doc_markdown "you should put `IgnoreList` between ticks in the documentation" -cargo-0.49.0/src/cargo/ops/cargo_new.rs:525:47 clippy::doc_markdown "you should put `IgnoreList` between ticks in the documentation" -cargo-0.49.0/src/cargo/ops/cargo_new.rs:525:9 clippy::doc_markdown "you should put `format_existing` between ticks in the documentation" -cargo-0.49.0/src/cargo/ops/cargo_new.rs:572:34 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/ops/cargo_new.rs:623:1 clippy::too_many_lines "this function has too many lines (130/100)" -cargo-0.49.0/src/cargo/ops/cargo_new.rs:781:5 clippy::filter_map_next "called `filter_map(..).next()` on an `Iterator`. This is more succinctly expressed by calling `.find_map(..)` instead." -cargo-0.49.0/src/cargo/ops/cargo_new.rs:800:16 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/ops/cargo_output_metadata.rs:163:36 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/ops/cargo_output_metadata.rs:27:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_output_metadata.rs:45:45 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/ops/cargo_package.rs:144:1 clippy::too_many_lines "this function has too many lines (112/100)" -cargo-0.49.0/src/cargo/ops/cargo_package.rs:207:13 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/ops/cargo_package.rs:25:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo-0.49.0/src/cargo/ops/cargo_package.rs:307:54 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/ops/cargo_package.rs:394:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/ops/cargo_package.rs:425:61 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/ops/cargo_package.rs:459:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/ops/cargo_package.rs:66:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_package.rs:93:20 clippy::if_not_else "unnecessary boolean `not` operation" -cargo-0.49.0/src/cargo/ops/cargo_pkgid.rs:5:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_read_manifest.rs:14:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_read_manifest.rs:171:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/ops/cargo_read_manifest.rs:37:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_read_manifest.rs:37:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/ops/cargo_read_manifest.rs:57:49 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/ops/cargo_read_manifest.rs:69:37 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/ops/cargo_run.rs:25:24 clippy::if_not_else "unnecessary boolean `not` operation" -cargo-0.49.0/src/cargo/ops/cargo_run.rs:35:9 clippy::if_not_else "unnecessary boolean `not` operation" -cargo-0.49.0/src/cargo/ops/cargo_run.rs:37:16 clippy::redundant_else "redundant else block" -cargo-0.49.0/src/cargo/ops/cargo_run.rs:53:9 clippy::if_not_else "unnecessary boolean `not` operation" -cargo-0.49.0/src/cargo/ops/cargo_run.rs:65:16 clippy::redundant_else "redundant else block" -cargo-0.49.0/src/cargo/ops/cargo_run.rs:9:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_run.rs:9:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/ops/cargo_test.rs:16:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_test.rs:43:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_test.rs:84:17 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/ops/cargo_uninstall.rs:14:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_uninstall.rs:7:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:147:9 clippy::doc_markdown "you should put `PackageId` between ticks in the documentation" -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:233:21 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:244:22 clippy::doc_markdown "you should put `PackageId` between ticks in the documentation" -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:244:63 clippy::doc_markdown "you should put `PackageId` between ticks in the documentation" -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:253:17 clippy::if_not_else "unnecessary boolean `not` operation" -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:370:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:505:8 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:525:10 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:542:27 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:542:5 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:561:20 clippy::redundant_else "redundant else block" -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:613:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:645:41 clippy::doc_markdown "you should put `BTreeSet` between ticks in the documentation" -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:92:19 clippy::doc_markdown "you should put `InstallTracker` between ticks in the documentation" -cargo-0.49.0/src/cargo/ops/fix.rs:200:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/fix.rs:200:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/ops/fix.rs:424:20 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" -cargo-0.49.0/src/cargo/ops/fix.rs:455:13 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/ops/fix.rs:506:17 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/ops/fix.rs:608:9 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" -cargo-0.49.0/src/cargo/ops/fix.rs:612:42 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/ops/fix.rs:619:48 clippy::manual_strip "stripping a prefix manually" -cargo-0.49.0/src/cargo/ops/fix.rs:66:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/ops/fix.rs:66:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo-0.49.0/src/cargo/ops/fix.rs:708:18 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/ops/fix.rs:77:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/lockfile.rs:154:13 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo-0.49.0/src/cargo/ops/lockfile.rs:217:9 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo-0.49.0/src/cargo/ops/lockfile.rs:30:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/lockfile.rs:35:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/lockfile.rs:35:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/ops/lockfile.rs:87:1 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -cargo-0.49.0/src/cargo/ops/lockfile.rs:8:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/lockfile.rs:8:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/ops/registry.rs:150:21 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/ops/registry.rs:188:1 clippy::too_many_lines "this function has too many lines (130/100)" -cargo-0.49.0/src/cargo/ops/registry.rs:212:32 clippy::if_not_else "unnecessary `!=` operation" -cargo-0.49.0/src/cargo/ops/registry.rs:222:53 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/ops/registry.rs:224:44 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/ops/registry.rs:31:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/ops/registry.rs:346:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/registry.rs:346:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/ops/registry.rs:351:26 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/ops/registry.rs:385:12 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo-0.49.0/src/cargo/ops/registry.rs:386:15 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo-0.49.0/src/cargo/ops/registry.rs:38:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo-0.49.0/src/cargo/ops/registry.rs:477:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/registry.rs:483:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/registry.rs:503:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/registry.rs:505:38 clippy::default_trait_access "calling `util::config::CargoHttpConfig::default()` is more clear than this expression" -cargo-0.49.0/src/cargo/ops/registry.rs:510:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/registry.rs:529:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/ops/registry.rs:53:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/registry.rs:53:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/ops/registry.rs:573:22 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/ops/registry.rs:608:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/registry.rs:621:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/registry.rs:671:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/registry.rs:671:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/ops/registry.rs:674:10 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo-0.49.0/src/cargo/ops/registry.rs:678:17 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/ops/registry.rs:730:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/registry.rs:731:16 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/ops/registry.rs:785:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/registry.rs:794:16 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/ops/registry.rs:828:14 clippy::doc_markdown "you should put `SourceId` between ticks in the documentation" -cargo-0.49.0/src/cargo/ops/registry.rs:848:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/resolve.rs:199:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/resolve.rs:199:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/ops/resolve.rs:199:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/ops/resolve.rs:199:1 clippy::too_many_lines "this function has too many lines (137/100)" -cargo-0.49.0/src/cargo/ops/resolve.rs:241:28 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/ops/resolve.rs:28:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/ops/resolve.rs:384:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/resolve.rs:417:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/resolve.rs:589:9 clippy::shadow_unrelated "`keep` is being shadowed" -cargo-0.49.0/src/cargo/ops/resolve.rs:58:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/resolve.rs:58:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/ops/resolve.rs:602:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/ops/resolve.rs:75:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/resolve.rs:75:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/ops/tree/graph.rs:129:26 clippy::doc_markdown "you should put `PackageIds` between ticks in the documentation" -cargo-0.49.0/src/cargo/ops/tree/graph.rs:152:15 clippy::match_on_vec_items "indexing into a vector may panic" -cargo-0.49.0/src/cargo/ops/tree/graph.rs:173:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/ops/tree/graph.rs:234:46 clippy::filter_map "called `filter(..).flat_map(..)` on an `Iterator`" -cargo-0.49.0/src/cargo/ops/tree/graph.rs:328:44 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/ops/tree/graph.rs:330:50 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/ops/tree/graph.rs:563:35 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/ops/tree/mod.rs:112:11 clippy::non_ascii_literal "literal non-ASCII character detected" -cargo-0.49.0/src/cargo/ops/tree/mod.rs:113:10 clippy::non_ascii_literal "literal non-ASCII character detected" -cargo-0.49.0/src/cargo/ops/tree/mod.rs:114:10 clippy::non_ascii_literal "literal non-ASCII character detected" -cargo-0.49.0/src/cargo/ops/tree/mod.rs:115:12 clippy::non_ascii_literal "literal non-ASCII character detected" -cargo-0.49.0/src/cargo/ops/tree/mod.rs:126:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/tree/mod.rs:21:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/ops/tree/mod.rs:21:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo-0.49.0/src/cargo/ops/tree/mod.rs:360:30 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/ops/tree/mod.rs:58:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/ops/vendor.rs:14:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/ops/vendor.rs:21:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/vendor.rs:21:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/ops/vendor.rs:314:34 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/ops/vendor.rs:320:29 clippy::case_sensitive_file_extension_comparisons "case-sensitive file extension comparison" -cargo-0.49.0/src/cargo/ops/vendor.rs:320:60 clippy::case_sensitive_file_extension_comparisons "case-sensitive file extension comparison" -cargo-0.49.0/src/cargo/ops/vendor.rs:324:13 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" -cargo-0.49.0/src/cargo/ops/vendor.rs:70:1 clippy::too_many_lines "this function has too many lines (175/100)" -cargo-0.49.0/src/cargo/sources/config.rs:102:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/config.rs:111:28 clippy::needless_question_mark "Question mark operator is useless here" -cargo-0.49.0/src/cargo/sources/config.rs:133:48 clippy::needless_question_mark "Question mark operator is useless here" -cargo-0.49.0/src/cargo/sources/config.rs:135:67 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/sources/config.rs:206:36 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo-0.49.0/src/cargo/sources/config.rs:282:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/sources/config.rs:70:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/config.rs:81:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/config.rs:97:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/sources/directory.rs:14:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/sources/directory.rs:90:56 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/sources/git/source.rs:14:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/sources/git/source.rs:25:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/git/source.rs:25:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/sources/git/source.rs:49:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/sources/git/source.rs:53:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/git/source.rs:53:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/sources/git/source.rs:69:20 clippy::comparison_to_empty "comparison to empty slice" -cargo-0.49.0/src/cargo/sources/git/utils.rs:1025:19 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/sources/git/utils.rs:1157:36 clippy::case_sensitive_file_extension_comparisons "case-sensitive file extension comparison" -cargo-0.49.0/src/cargo/sources/git/utils.rs:1158:9 clippy::manual_strip "stripping a suffix manually" -cargo-0.49.0/src/cargo/sources/git/utils.rs:134:12 clippy::upper_case_acronyms "name `GitShortID` contains a capitalized acronym" -cargo-0.49.0/src/cargo/sources/git/utils.rs:176:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/sources/git/utils.rs:180:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/sources/git/utils.rs:184:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/git/utils.rs:188:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/git/utils.rs:242:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/git/utils.rs:253:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/git/utils.rs:253:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/sources/git/utils.rs:262:13 clippy::if_not_else "unnecessary boolean `not` operation" -cargo-0.49.0/src/cargo/sources/git/utils.rs:289:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/git/utils.rs:294:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/sources/git/utils.rs:298:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/git/utils.rs:308:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/git/utils.rs:472:9 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" -cargo-0.49.0/src/cargo/sources/git/utils.rs:489:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/sources/git/utils.rs:503:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/sources/git/utils.rs:528:28 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/sources/git/utils.rs:537:21 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" -cargo-0.49.0/src/cargo/sources/git/utils.rs:588:1 clippy::too_many_lines "this function has too many lines (135/100)" -cargo-0.49.0/src/cargo/sources/git/utils.rs:692:9 clippy::vec_init_then_push "calls to `push` immediately after creation" -cargo-0.49.0/src/cargo/sources/git/utils.rs:758:9 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo-0.49.0/src/cargo/sources/git/utils.rs:858:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/path.rs:129:44 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/sources/path.rs:143:44 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/sources/path.rs:15:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/sources/path.rs:282:50 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/sources/path.rs:313:21 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/sources/path.rs:314:21 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/sources/path.rs:319:21 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/sources/path.rs:339:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/sources/path.rs:339:9 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -cargo-0.49.0/src/cargo/sources/path.rs:380:9 clippy::unused_self "unused `self` argument" -cargo-0.49.0/src/cargo/sources/path.rs:419:50 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/sources/path.rs:429:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/path.rs:460:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/sources/path.rs:473:43 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/sources/path.rs:482:43 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/sources/path.rs:55:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/sources/path.rs:63:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/path.rs:77:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/path.rs:98:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/registry/index.rs:117:23 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo-0.49.0/src/cargo/sources/registry/index.rs:121:70 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo-0.49.0/src/cargo/sources/registry/index.rs:167:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/sources/registry/index.rs:215:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/sources/registry/index.rs:324:23 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/sources/registry/index.rs:468:40 clippy::doc_markdown "you should put `SourceId` between ticks in the documentation" -cargo-0.49.0/src/cargo/sources/registry/index.rs:590:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/sources/registry/index.rs:648:17 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/sources/registry/index.rs:736:1 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -cargo-0.49.0/src/cargo/sources/registry/index.rs:95:37 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -cargo-0.49.0/src/cargo/sources/registry/local.rs:12:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/sources/registry/mod.rs:192:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/sources/registry/mod.rs:203:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/sources/registry/mod.rs:229:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/sources/registry/mod.rs:372:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/sources/registry/mod.rs:373:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/registry/mod.rs:375:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/registry/mod.rs:381:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/registry/mod.rs:382:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/registry/mod.rs:383:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/registry/mod.rs:384:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/registry/mod.rs:452:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/registry/mod.rs:582:20 clippy::redundant_else "redundant else block" -cargo-0.49.0/src/cargo/sources/registry/mod.rs:621:9 clippy::if_not_else "unnecessary `!=` operation" -cargo-0.49.0/src/cargo/sources/registry/remote.rs:139:17 clippy::unused_self "unused `self` argument" -cargo-0.49.0/src/cargo/sources/registry/remote.rs:32:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/sources/registry/remote.rs:72:13 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/sources/replaced.rs:12:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/sources/replaced.rs:5:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/util/canonical_url.rs:19:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/canonical_url.rs:19:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/util/canonical_url.rs:50:41 clippy::case_sensitive_file_extension_comparisons "case-sensitive file extension comparison" -cargo-0.49.0/src/cargo/util/canonical_url.rs:65:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/command_prelude.rs:218:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/command_prelude.rs:222:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/command_prelude.rs:234:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/command_prelude.rs:249:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/command_prelude.rs:264:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/command_prelude.rs:279:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/command_prelude.rs:298:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/command_prelude.rs:320:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/command_prelude.rs:328:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/command_prelude.rs:352:13 clippy::if_not_else "unnecessary boolean `not` operation" -cargo-0.49.0/src/cargo/util/command_prelude.rs:363:13 clippy::if_not_else "unnecessary boolean `not` operation" -cargo-0.49.0/src/cargo/util/command_prelude.rs:378:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/command_prelude.rs:387:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/command_prelude.rs:387:5 clippy::too_many_lines "this function has too many lines (104/100)" -cargo-0.49.0/src/cargo/util/command_prelude.rs:39:20 clippy::doc_markdown "you should put `arg_package_spec` between ticks in the documentation" -cargo-0.49.0/src/cargo/util/command_prelude.rs:504:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/command_prelude.rs:516:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/command_prelude.rs:530:40 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/util/command_prelude.rs:531:43 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/util/command_prelude.rs:536:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/command_prelude.rs:556:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/command_prelude.rs:575:49 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/util/command_prelude.rs:580:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/command_prelude.rs:631:18 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/util/command_prelude.rs:638:18 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/util/command_prelude.rs:647:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/command_prelude.rs:651:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/command_prelude.rs:662:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/command_prelude.rs:665:51 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/util/config/de.rs:420:16 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo-0.49.0/src/cargo/util/config/de.rs:46:25 clippy::doc_markdown "you should put `CV::List` between ticks in the documentation" -cargo-0.49.0/src/cargo/util/config/de.rs:47:24 clippy::doc_markdown "you should put `ConfigSeqAccess` between ticks in the documentation" -cargo-0.49.0/src/cargo/util/config/de.rs:527:53 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo-0.49.0/src/cargo/util/config/de.rs:530:53 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo-0.49.0/src/cargo/util/config/de.rs:532:68 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo-0.49.0/src/cargo/util/config/key.rs:11:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/util/config/key.rs:69:9 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo-0.49.0/src/cargo/util/config/mod.rs:100:71 clippy::doc_markdown "you should put `OptValue` between ticks in the documentation" -cargo-0.49.0/src/cargo/util/config/mod.rs:100:71 clippy::doc_markdown "you should put `OptValue` between ticks in the documentation" -cargo-0.49.0/src/cargo/util/config/mod.rs:100:71 clippy::doc_markdown "you should put `OptValue` between ticks in the documentation" -cargo-0.49.0/src/cargo/util/config/mod.rs:1049:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:1064:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:1090:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:1090:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:1166:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:1179:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:1181:33 clippy::needless_question_mark "Question mark operator is useless here" -cargo-0.49.0/src/cargo/util/config/mod.rs:1184:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:1186:33 clippy::needless_question_mark "Question mark operator is useless here" -cargo-0.49.0/src/cargo/util/config/mod.rs:1189:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:1191:33 clippy::needless_question_mark "Question mark operator is useless here" -cargo-0.49.0/src/cargo/util/config/mod.rs:1203:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:1211:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:1216:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:1225:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:1229:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:124:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo-0.49.0/src/cargo/util/config/mod.rs:1254:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:1263:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:1279:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:1281:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/util/config/mod.rs:1323:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/util/config/mod.rs:1339:39 clippy::unused_self "unused `self` argument" -cargo-0.49.0/src/cargo/util/config/mod.rs:1344:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/util/config/mod.rs:1420:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/util/config/mod.rs:1553:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:1560:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:1567:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:1574:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:1581:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:1588:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/config/mod.rs:1598:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/config/mod.rs:1619:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/config/mod.rs:1623:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:1623:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:1623:64 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo-0.49.0/src/cargo/util/config/mod.rs:1649:9 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" -cargo-0.49.0/src/cargo/util/config/mod.rs:1699:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/util/config/mod.rs:1730:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/util/config/mod.rs:1757:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/util/config/mod.rs:1770:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/util/config/mod.rs:1778:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/util/config/mod.rs:1804:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/util/config/mod.rs:1896:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/config/mod.rs:1901:5 clippy::doc_markdown "you should put `StringList` between ticks in the documentation" -cargo-0.49.0/src/cargo/util/config/mod.rs:214:13 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" -cargo-0.49.0/src/cargo/util/config/mod.rs:259:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:298:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:311:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:318:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:353:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:401:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:411:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:419:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:431:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:449:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:454:16 clippy::option_if_let_else "use Option::map_or instead of an if let/else" -cargo-0.49.0/src/cargo/util/config/mod.rs:547:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:556:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:582:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:595:20 clippy::doc_markdown "you should put `StringList` between ticks in the documentation" -cargo-0.49.0/src/cargo/util/config/mod.rs:689:20 clippy::unused_self "unused `self` argument" -cargo-0.49.0/src/cargo/util/config/mod.rs:699:5 clippy::fn_params_excessive_bools "more than 3 bools in function parameters" -cargo-0.49.0/src/cargo/util/config/mod.rs:699:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:719:58 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/util/config/mod.rs:816:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/path.rs:10:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/util/config/path.rs:14:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/config/path.rs:48:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/util/config/target.rs:12:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/util/config/target.rs:24:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/util/config/value.rs:29:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/util/config/value.rs:70:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/util/config/value.rs:80:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/config/value.rs:81:9 clippy::match_like_matches_macro "match expression looks like `matches!` macro" -cargo-0.49.0/src/cargo/util/cpu.rs:11:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/cpu.rs:22:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/cpu.rs:82:25 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -cargo-0.49.0/src/cargo/util/cpu.rs:82:9 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -cargo-0.49.0/src/cargo/util/dependency_queue.rs:109:27 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/util/dependency_queue.rs:125:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/util/dependency_queue.rs:151:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/dependency_queue.rs:156:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/dependency_queue.rs:168:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/util/dependency_queue.rs:46:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/dependency_queue.rs:66:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/util/dependency_queue.rs:91:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/util/diagnostic_server.rs:218:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/util/diagnostic_server.rs:230:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/diagnostic_server.rs:242:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/diagnostic_server.rs:58:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/diagnostic_server.rs:96:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/diagnostic_server.rs:96:5 clippy::too_many_lines "this function has too many lines (110/100)" -cargo-0.49.0/src/cargo/util/diagnostic_server.rs:99:21 clippy::shadow_unrelated "`msg` is being shadowed" -cargo-0.49.0/src/cargo/util/errors.rs:101:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/errors.rs:143:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/errors.rs:150:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/errors.rs:15:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/errors.rs:237:5 clippy::pub_enum_variant_names "variant name ends with the enum's name" -cargo-0.49.0/src/cargo/util/errors.rs:245:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/util/errors.rs:245:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/errors.rs:321:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/errors.rs:328:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/errors.rs:356:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/errors.rs:391:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/util/errors.rs:392:13 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/cargo/util/errors.rs:465:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/errors.rs:473:5 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" -cargo-0.49.0/src/cargo/util/errors.rs:66:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/flock.rs:115:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/flock.rs:11:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/cargo/util/flock.rs:134:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/flock.rs:142:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/flock.rs:150:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/flock.rs:156:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/flock.rs:170:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/flock.rs:192:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/flock.rs:29:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/util/flock.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/flock.rs:321:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/util/flock.rs:335:23 clippy::cast_possible_truncation "casting `i64` to `u32` may truncate the value" -cargo-0.49.0/src/cargo/util/flock.rs:335:23 clippy::cast_sign_loss "casting `i64` to `u32` may lose the sign of the value" -cargo-0.49.0/src/cargo/util/flock.rs:335:44 clippy::cast_possible_truncation "casting `i64` to `u32` may truncate the value" -cargo-0.49.0/src/cargo/util/flock.rs:379:35 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/util/flock.rs:37:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/util/flock.rs:37:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/flock.rs:43:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/util/flock.rs:43:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/flock.rs:52:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/flock.rs:52:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/util/graph.rs:10:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/graph.rs:41:51 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/util/graph.rs:45:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/hasher.rs:12:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/hasher.rs:9:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/util/hex.rs:10:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" -cargo-0.49.0/src/cargo/util/hex.rs:11:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" -cargo-0.49.0/src/cargo/util/hex.rs:12:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" -cargo-0.49.0/src/cargo/util/hex.rs:13:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" -cargo-0.49.0/src/cargo/util/hex.rs:14:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" -cargo-0.49.0/src/cargo/util/hex.rs:15:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" -cargo-0.49.0/src/cargo/util/hex.rs:25:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/hex.rs:6:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/util/hex.rs:6:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/hex.rs:8:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" -cargo-0.49.0/src/cargo/util/hex.rs:9:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" -cargo-0.49.0/src/cargo/util/important_paths.rs:23:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/important_paths.rs:6:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/interning.rs:66:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/util/interning.rs:66:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/interning.rs:77:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/into_url.rs:10:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/into_url_with_base.rs:9:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/job.rs:20:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/lev_distance.rs:3:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/lockserver.rs:111:32 clippy::redundant_else "redundant else block" -cargo-0.49.0/src/cargo/util/lockserver.rs:158:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/lockserver.rs:46:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/lockserver.rs:58:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/lockserver.rs:62:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/mod.rs:68:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/mod.rs:79:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/network.rs:12:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/network.rs:19:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/network.rs:84:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/paths.rs:109:12 clippy::redundant_else "redundant else block" -cargo-0.49.0/src/cargo/util/paths.rs:114:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/paths.rs:121:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/paths.rs:125:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/paths.rs:130:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/paths.rs:14:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/paths.rs:14:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/util/paths.rs:151:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/paths.rs:167:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/paths.rs:173:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/paths.rs:178:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/paths.rs:185:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/paths.rs:199:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/paths.rs:215:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/paths.rs:228:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/paths.rs:251:9 clippy::option_if_let_else "use Option::map_or instead of an if let/else" -cargo-0.49.0/src/cargo/util/paths.rs:267:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/paths.rs:276:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/paths.rs:29:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/paths.rs:303:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/paths.rs:312:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/paths.rs:346:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/paths.rs:415:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/paths.rs:445:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/paths.rs:459:45 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/util/paths.rs:469:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/paths.rs:469:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/util/paths.rs:54:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/paths.rs:61:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/util/paths.rs:61:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/paths.rs:63:19 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" -cargo-0.49.0/src/cargo/util/paths.rs:88:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/paths.rs:93:31 clippy::comparison_to_empty "comparison to empty slice" -cargo-0.49.0/src/cargo/util/process_builder.rs:106:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/process_builder.rs:111:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/process_builder.rs:122:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/process_builder.rs:132:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/process_builder.rs:152:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/process_builder.rs:185:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/process_builder.rs:190:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/process_builder.rs:218:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/process_builder.rs:218:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/util/process_builder.rs:307:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/process_builder.rs:343:39 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo-0.49.0/src/cargo/util/progress.rs:122:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/progress.rs:136:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/progress.rs:15:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/util/progress.rs:249:19 clippy::cast_precision_loss "casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -cargo-0.49.0/src/cargo/util/progress.rs:249:34 clippy::cast_precision_loss "casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -cargo-0.49.0/src/cargo/util/progress.rs:250:19 clippy::if_not_else "unnecessary boolean `not` operation" -cargo-0.49.0/src/cargo/util/progress.rs:263:22 clippy::cast_precision_loss "casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -cargo-0.49.0/src/cargo/util/progress.rs:264:22 clippy::cast_possible_truncation "casting `f64` to `usize` may truncate the value" -cargo-0.49.0/src/cargo/util/progress.rs:264:22 clippy::cast_sign_loss "casting `f64` to `usize` may lose the sign of the value" -cargo-0.49.0/src/cargo/util/progress.rs:269:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo-0.49.0/src/cargo/util/progress.rs:272:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo-0.49.0/src/cargo/util/progress.rs:274:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo-0.49.0/src/cargo/util/progress.rs:280:13 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo-0.49.0/src/cargo/util/progress.rs:282:9 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo-0.49.0/src/cargo/util/progress.rs:89:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/progress.rs:97:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/queue.rs:25:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/queue.rs:36:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/util/queue.rs:42:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/util/queue.rs:52:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/util/queue.rs:69:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/util/read2.rs:11:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/read2.rs:31:17 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/util/restricted_names.rs:13:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/restricted_names.rs:26:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/restricted_names.rs:35:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/restricted_names.rs:45:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/restricted_names.rs:87:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/util/restricted_names.rs:87:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/restricted_names.rs:89:21 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/util/restricted_names.rs:8:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/rustc.rs:103:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/rustc.rs:103:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/util/rustc.rs:114:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" -cargo-0.49.0/src/cargo/util/rustc.rs:115:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" -cargo-0.49.0/src/cargo/util/rustc.rs:162:17 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/util/rustc.rs:39:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/sha256.rs:10:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/sha256.rs:20:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/sha256.rs:31:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/sha256.rs:40:24 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo-0.49.0/src/cargo/util/to_semver.rs:5:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/toml/mod.rs:1005:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/toml/mod.rs:1005:5 clippy::too_many_lines "this function has too many lines (282/100)" -cargo-0.49.0/src/cargo/util/toml/mod.rs:1094:36 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/util/toml/mod.rs:1121:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/util/toml/mod.rs:1197:32 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" -cargo-0.49.0/src/cargo/util/toml/mod.rs:124:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/toml/mod.rs:1504:9 clippy::unused_self "unused `self` argument" -cargo-0.49.0/src/cargo/util/toml/mod.rs:1526:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/toml/mod.rs:1582:19 clippy::default_trait_access "calling `util::toml::DetailedTomlDependency::default()` is more clear than this expression" -cargo-0.49.0/src/cargo/util/toml/mod.rs:1598:5 clippy::too_many_lines "this function has too many lines (153/100)" -cargo-0.49.0/src/cargo/util/toml/mod.rs:1687:33 clippy::unnecessary_lazy_evaluations "unnecessary closure used to substitute value for `Option::None`" -cargo-0.49.0/src/cargo/util/toml/mod.rs:178:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/util/toml/mod.rs:248:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/util/toml/mod.rs:274:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/util/toml/mod.rs:277:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/toml/mod.rs:281:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/toml/mod.rs:285:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/toml/mod.rs:294:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/util/toml/mod.rs:31:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/toml/mod.rs:381:35 clippy::cast_possible_truncation "casting `i64` to `u32` may truncate the value" -cargo-0.49.0/src/cargo/util/toml/mod.rs:381:35 clippy::cast_sign_loss "casting `i64` to `u32` may lose the sign of the value" -cargo-0.49.0/src/cargo/util/toml/mod.rs:388:35 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" -cargo-0.49.0/src/cargo/util/toml/mod.rs:398:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/util/toml/mod.rs:450:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/toml/mod.rs:536:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/toml/mod.rs:783:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/util/toml/mod.rs:824:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/util/toml/mod.rs:834:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/toml/mod.rs:83:42 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/util/toml/mod.rs:852:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/toml/mod.rs:852:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/util/toml/mod.rs:852:5 clippy::too_many_lines "this function has too many lines (138/100)" -cargo-0.49.0/src/cargo/util/toml/mod.rs:962:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/util/toml/mod.rs:979:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/util/toml/mod.rs:98:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/util/toml/mod.rs:999:23 clippy::default_trait_access "calling `util::toml::DetailedTomlDependency::default()` is more clear than this expression" -cargo-0.49.0/src/cargo/util/toml/targets.rs:112:27 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/util/toml/targets.rs:325:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/util/toml/targets.rs:586:21 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/util/toml/targets.rs:593:42 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/util/toml/targets.rs:605:19 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/util/toml/targets.rs:612:42 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/util/toml/targets.rs:756:36 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/util/vcs.rs:10:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/vcs.rs:33:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/vcs.rs:37:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/vcs.rs:43:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/vcs.rs:47:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/vcs.rs:59:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/vcs.rs:66:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/workspace.rs:52:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/workspace.rs:56:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/workspace.rs:60:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/workspace.rs:64:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron-0.6.1/src/error.rs:24:1 clippy::module_name_repetitions "item name ends with its containing module's name" -iron-0.6.1/src/iron.rs:105:13 clippy::redundant_field_names "redundant field names in struct initialization" -iron-0.6.1/src/iron.rs:119:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron-0.6.1/src/iron.rs:133:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron-0.6.1/src/iron.rs:143:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron-0.6.1/src/iron.rs:149:13 clippy::redundant_field_names "redundant field names in struct initialization" -iron-0.6.1/src/iron.rs:167:49 clippy::similar_names "binding's name is too similar to existing binding" -iron-0.6.1/src/iron.rs:80:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron-0.6.1/src/iron.rs:85:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron-0.6.1/src/iron.rs:90:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron-0.6.1/src/lib.rs:1:null clippy::cargo_common_metadata "package `iron` is missing `package.categories` metadata" -iron-0.6.1/src/lib.rs:1:null clippy::cargo_common_metadata "package `iron` is missing `package.keywords` metadata" -iron-0.6.1/src/lib.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `log`: 0.3.9, 0.4.8" -iron-0.6.1/src/middleware/mod.rs:137:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron-0.6.1/src/middleware/mod.rs:150:1 clippy::module_name_repetitions "item name ends with its containing module's name" -iron-0.6.1/src/middleware/mod.rs:152:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron-0.6.1/src/middleware/mod.rs:159:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron-0.6.1/src/middleware/mod.rs:171:1 clippy::module_name_repetitions "item name ends with its containing module's name" -iron-0.6.1/src/middleware/mod.rs:173:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron-0.6.1/src/middleware/mod.rs:182:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron-0.6.1/src/middleware/mod.rs:192:1 clippy::module_name_repetitions "item name ends with its containing module's name" -iron-0.6.1/src/middleware/mod.rs:217:25 clippy::doc_markdown "you should put `ChainBuilder` between ticks in the documentation" -iron-0.6.1/src/middleware/mod.rs:264:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -iron-0.6.1/src/middleware/mod.rs:328:20 clippy::similar_names "binding's name is too similar to existing binding" -iron-0.6.1/src/middleware/mod.rs:360:16 clippy::similar_names "binding's name is too similar to existing binding" -iron-0.6.1/src/middleware/mod.rs:368:33 clippy::similar_names "binding's name is too similar to existing binding" -iron-0.6.1/src/middleware/mod.rs:428:40 clippy::similar_names "binding's name is too similar to existing binding" -iron-0.6.1/src/middleware/mod.rs:434:40 clippy::similar_names "binding's name is too similar to existing binding" -iron-0.6.1/src/middleware/mod.rs:444:40 clippy::similar_names "binding's name is too similar to existing binding" -iron-0.6.1/src/modifiers.rs:132:14 clippy::expect_fun_call "use of `expect` followed by a function call" -iron-0.6.1/src/request/mod.rs:113:24 clippy::similar_names "binding's name is too similar to existing binding" -iron-0.6.1/src/request/mod.rs:121:13 clippy::redundant_field_names "redundant field names in struct initialization" -iron-0.6.1/src/request/mod.rs:123:13 clippy::redundant_field_names "redundant field names in struct initialization" -iron-0.6.1/src/request/mod.rs:124:13 clippy::redundant_field_names "redundant field names in struct initialization" -iron-0.6.1/src/request/mod.rs:126:13 clippy::redundant_field_names "redundant field names in struct initialization" -iron-0.6.1/src/request/mod.rs:128:13 clippy::redundant_field_names "redundant field names in struct initialization" -iron-0.6.1/src/request/mod.rs:153:69 clippy::doc_markdown "you should put `HttpReader` between ticks in the documentation" -iron-0.6.1/src/request/mod.rs:154:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron-0.6.1/src/request/mod.rs:32:1 clippy::manual_non_exhaustive "this seems like a manual implementation of the non-exhaustive pattern" -iron-0.6.1/src/request/mod.rs:75:34 clippy::doc_markdown "you should put `HttpRequest` between ticks in the documentation" -iron-0.6.1/src/request/mod.rs:77:39 clippy::doc_markdown "you should put `HttpRequest` between ticks in the documentation" -iron-0.6.1/src/request/mod.rs:78:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron-0.6.1/src/request/mod.rs:82:13 clippy::similar_names "binding's name is too similar to existing binding" -iron-0.6.1/src/request/mod.rs:83:29 clippy::similar_names "binding's name is too similar to existing binding" -iron-0.6.1/src/request/mod.rs:85:24 clippy::similar_names "binding's name is too similar to existing binding" -iron-0.6.1/src/request/url.rs:109:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron-0.6.1/src/request/url.rs:117:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron-0.6.1/src/request/url.rs:129:1 clippy::from_over_into "an implementation of `From` is preferred since it gives you `Into<_>` for free where the reverse isn't true" -iron-0.6.1/src/request/url.rs:21:14 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" -iron-0.6.1/src/request/url.rs:22:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron-0.6.1/src/request/url.rs:31:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron-0.6.1/src/request/url.rs:47:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron-0.6.1/src/request/url.rs:52:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron-0.6.1/src/request/url.rs:57:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -iron-0.6.1/src/request/url.rs:57:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron-0.6.1/src/request/url.rs:63:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -iron-0.6.1/src/request/url.rs:63:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron-0.6.1/src/request/url.rs:73:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -iron-0.6.1/src/request/url.rs:73:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron-0.6.1/src/request/url.rs:83:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron-0.6.1/src/request/url.rs:96:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron-0.6.1/src/response.rs:121:19 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -iron-0.6.1/src/response.rs:125:43 clippy::redundant_closure_for_method_calls "redundant closure found" -iron-0.6.1/src/response.rs:139:41 clippy::redundant_closure_for_method_calls "redundant closure found" -iron-0.6.1/src/response.rs:24:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron-0.6.1/src/response.rs:95:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron-0.6.1/src/response.rs:95:5 clippy::new_without_default "you should consider adding a `Default` implementation for `response::Response`" -libc-0.2.81/build.rs:114:19 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" -libc-0.2.81/build.rs:124:5 clippy::question_mark "this block may be rewritten with the `?` operator" -libc-0.2.81/build.rs:133:5 clippy::question_mark "this block may be rewritten with the `?` operator" -libc-0.2.81/src/macros.rs:243:17 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" -libc-0.2.81/src/macros.rs:243:17 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" -libc-0.2.81/src/macros.rs:243:17 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" -libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:428:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:429:30 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:431:30 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:432:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:433:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:434:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:595:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:596:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:597:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:622:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:673:34 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:696:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:697:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:698:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:699:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:712:34 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:721:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:722:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:723:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:751:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:752:30 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:753:30 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:754:30 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:755:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:756:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:757:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:758:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:759:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:760:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:768:30 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:769:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:771:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:772:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:773:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:774:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:775:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:776:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:777:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:778:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:779:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:780:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:781:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:782:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:783:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:784:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:785:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:786:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:787:30 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:788:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:789:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:790:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:791:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:792:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:794:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:795:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:796:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:797:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:798:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:799:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:800:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:801:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:803:27 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:804:28 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:805:28 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:806:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:807:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:808:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:809:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:810:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:811:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:812:30 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:813:30 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:814:30 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:815:30 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:816:30 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:817:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:818:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:821:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:822:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:823:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:824:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:825:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:826:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:827:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:828:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:829:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:830:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:831:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:832:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:833:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:834:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:835:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:836:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:841:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:842:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:843:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:844:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:1120:38 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:178:34 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:291:5 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:291:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:299:11 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:302:5 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:302:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:312:11 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:352:20 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:355:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:355:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:359:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:359:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:363:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:363:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:367:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:367:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:371:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:371:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:534:36 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:645:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:727:40 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:728:40 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:729:39 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:731:44 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:732:36 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:733:41 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:734:43 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:735:42 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:736:40 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:737:36 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:738:37 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:741:39 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:742:40 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:743:40 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:744:40 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:745:40 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:746:43 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:747:42 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:748:40 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:749:39 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:750:41 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:751:41 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:752:43 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:753:42 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:755:42 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:756:41 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:757:41 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:758:39 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:759:39 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:761:41 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:762:44 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:763:45 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:764:40 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:765:40 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:766:40 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:767:44 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:768:44 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:769:39 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:770:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:771:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:772:37 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:773:39 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:774:45 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:775:41 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:776:39 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:803:34 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:841:30 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:842:37 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:982:40 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:984:46 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1209:36 clippy::cast_possible_truncation "casting `i32` to `i16` may truncate the value" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1210:36 clippy::cast_possible_truncation "casting `i32` to `i16` may truncate the value" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1235:39 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1236:41 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1274:42 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1324:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1333:37 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1334:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1346:34 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1346:34 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1346:34 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1347:37 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1347:37 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1347:37 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1348:36 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1348:36 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1348:36 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1349:37 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1349:37 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1349:37 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1350:35 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1350:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1350:35 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1351:36 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1351:36 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1351:36 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1352:31 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1352:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1352:31 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1419:36 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1420:36 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1421:36 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1422:36 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1423:36 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1490:37 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1561:46 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1562:45 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1567:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1568:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1586:26 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1587:34 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1588:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1589:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1897:38 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1898:51 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1900:39 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1969:34 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1970:34 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1971:36 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1972:36 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1973:36 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1974:37 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1975:37 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1976:36 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1977:36 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1978:39 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1979:39 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1980:39 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1981:39 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1982:39 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1983:39 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1984:38 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1985:38 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1986:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1987:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1988:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1989:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1990:38 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1991:37 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1992:37 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1993:38 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1994:37 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1995:37 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1996:37 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1997:37 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1998:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1999:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2000:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2001:34 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2002:34 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2003:34 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2004:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2005:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2032:30 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2033:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2034:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2035:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2036:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2037:28 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2038:27 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2039:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2041:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2042:28 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2043:27 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2044:34 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2045:27 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2046:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2048:28 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2049:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2050:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2051:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2052:26 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2053:36 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2318:42 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2321:38 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2331:39 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2487:42 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2488:42 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2489:43 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2490:43 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2491:43 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2493:47 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2494:44 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2495:46 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2496:47 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2497:49 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2498:48 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2499:50 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2500:45 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2572:9 clippy::needless_return "unneeded `return` statement" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2578:20 clippy::zero_ptr "`0 as *mut _` detected" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2588:13 clippy::zero_ptr "`0 as *mut _` detected" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2590:13 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2596:52 clippy::used_underscore_binding "used binding `_dummy` which is prefixed with an underscore. A leading underscore signals that a binding will not be used." -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2597:11 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2601:21 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2611:9 clippy::unused_unit "unneeded unit expression" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2619:9 clippy::unused_unit "unneeded unit expression" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2634:9 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2647:25 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2648:25 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2649:9 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2654:18 clippy::identity_op "the operation is ineffective. Consider reducing it to `(dev & 0x00000000000000ff)`" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2654:25 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2655:25 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2656:9 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2660:21 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2661:21 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2663:25 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2664:25 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2665:16 clippy::identity_op "the operation is ineffective. Consider reducing it to `(minor & 0x000000ff)`" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2665:25 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2666:25 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:954:34 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1000:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1001:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1002:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1016:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1017:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1018:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1019:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1020:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1029:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1030:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1031:30 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1032:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1033:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1034:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1035:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1041:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1042:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1043:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1044:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1045:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1046:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1047:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1048:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1049:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1050:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1051:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1053:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1054:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1055:30 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1056:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1057:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1058:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1059:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1060:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1073:42 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1074:43 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1075:37 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1076:37 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1077:41 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1078:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1079:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1080:36 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1081:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1082:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1083:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1084:38 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1086:30 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1087:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1089:30 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1090:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1091:30 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1094:40 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1095:37 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1096:41 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1097:40 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1098:39 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1099:34 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1100:36 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1101:38 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1102:37 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1105:44 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1106:41 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1107:42 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1108:42 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1109:41 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1110:46 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1111:41 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1112:44 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1113:40 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1114:47 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1115:36 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1126:34 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1127:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1128:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1179:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1180:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1218:27 clippy::identity_op "the operation is ineffective. Consider reducing it to `IPOPT_CONTROL`" -libc-0.2.81/src/unix/linux_like/mod.rs:1314:9 clippy::precedence "operator precedence can trip the unwary" -libc-0.2.81/src/unix/linux_like/mod.rs:1321:13 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" -libc-0.2.81/src/unix/linux_like/mod.rs:1323:13 clippy::zero_ptr "`0 as *mut _` detected" -libc-0.2.81/src/unix/linux_like/mod.rs:1332:9 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -libc-0.2.81/src/unix/linux_like/mod.rs:1337:9 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -libc-0.2.81/src/unix/linux_like/mod.rs:1341:18 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" -libc-0.2.81/src/unix/linux_like/mod.rs:1344:9 clippy::needless_return "unneeded `return` statement" -libc-0.2.81/src/unix/linux_like/mod.rs:1348:18 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" -libc-0.2.81/src/unix/linux_like/mod.rs:1350:9 clippy::needless_return "unneeded `return` statement" -libc-0.2.81/src/unix/linux_like/mod.rs:1354:18 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" -libc-0.2.81/src/unix/linux_like/mod.rs:1357:9 clippy::needless_return "unneeded `return` statement" -libc-0.2.81/src/unix/linux_like/mod.rs:1361:21 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" -libc-0.2.81/src/unix/linux_like/mod.rs:1381:9 clippy::cast_possible_truncation "casting `i32` to `i8` may truncate the value" -libc-0.2.81/src/unix/linux_like/mod.rs:1389:9 clippy::verbose_bit_mask "bit mask could be simplified with a call to `trailing_zeros`" -libc-0.2.81/src/unix/linux_like/mod.rs:446:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:591:36 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:592:38 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:593:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:594:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:595:34 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:596:36 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:597:37 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:598:37 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:599:39 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:600:34 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:601:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:602:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:607:37 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:608:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:764:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:765:39 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:991:30 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/mod.rs:198:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/mod.rs:199:28 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/mod.rs:201:35 clippy::unnecessary_cast "casting integer literal to `usize` is unnecessary" -libc-0.2.81/src/unix/mod.rs:202:35 clippy::unnecessary_cast "casting integer literal to `usize` is unnecessary" -libc-0.2.81/src/unix/mod.rs:282:40 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/mod.rs:284:41 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/mod.rs:285:36 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/mod.rs:34:10 clippy::upper_case_acronyms "name `DIR` contains a capitalized acronym" -libc-0.2.81/src/unix/mod.rs:386:10 clippy::upper_case_acronyms "name `FILE` contains a capitalized acronym" -log-0.4.11/src/lib.rs:1047:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:1053:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:1059:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:1093:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:1093:5 clippy::new_without_default "you should consider adding a `Default` implementation for `MetadataBuilder<'a>`" -log-0.4.11/src/lib.rs:1118:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:1177:1 clippy::inline_always "you have declared `#[inline(always)]` on `max_level`. This is usually a bad idea" -log-0.4.11/src/lib.rs:1178:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:1306:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -log-0.4.11/src/lib.rs:1306:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -log-0.4.11/src/lib.rs:1358:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:1359:5 clippy::if_not_else "unnecessary `!=` operation" -log-0.4.11/src/lib.rs:1407:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:329:27 clippy::derive_hash_xor_eq "you are deriving `Hash` but have implemented `PartialEq` explicitly" -log-0.4.11/src/lib.rs:356:1 clippy::expl_impl_clone_on_copy "you are implementing `Clone` explicitly on a `Copy` type" -log-0.4.11/src/lib.rs:448:12 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" -log-0.4.11/src/lib.rs:500:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:506:28 clippy::trivially_copy_pass_by_ref "this argument (8 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -log-0.4.11/src/lib.rs:506:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -log-0.4.11/src/lib.rs:506:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:520:27 clippy::derive_hash_xor_eq "you are deriving `Hash` but have implemented `PartialEq` explicitly" -log-0.4.11/src/lib.rs:538:1 clippy::expl_impl_clone_on_copy "you are implementing `Clone` explicitly on a `Copy` type" -log-0.4.11/src/lib.rs:653:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:661:21 clippy::trivially_copy_pass_by_ref "this argument (8 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -log-0.4.11/src/lib.rs:661:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:677:44 clippy::match_same_arms "this `match` has identical arm bodies" -log-0.4.11/src/lib.rs:758:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:764:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:770:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:776:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:782:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:788:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:794:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:803:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:809:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:818:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:908:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:908:5 clippy::new_without_default "you should consider adding a `Default` implementation for `RecordBuilder<'a>`" -log-0.4.11/src/lib.rs:995:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/detection.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -proc-macro2-1.0.24/src/fallback.rs:108:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" -proc-macro2-1.0.24/src/fallback.rs:269:20 clippy::unused_self "unused `self` argument" -proc-macro2-1.0.24/src/fallback.rs:430:24 clippy::trivially_copy_pass_by_ref "this argument (0 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -proc-macro2-1.0.24/src/fallback.rs:437:23 clippy::trivially_copy_pass_by_ref "this argument (0 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -proc-macro2-1.0.24/src/fallback.rs:437:23 clippy::unused_self "unused `self` argument" -proc-macro2-1.0.24/src/fallback.rs:471:17 clippy::trivially_copy_pass_by_ref "this argument (0 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -proc-macro2-1.0.24/src/fallback.rs:471:17 clippy::unused_self "unused `self` argument" -proc-macro2-1.0.24/src/fallback.rs:654:5 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" -proc-macro2-1.0.24/src/fallback.rs:655:12 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" -proc-macro2-1.0.24/src/fallback.rs:661:5 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" -proc-macro2-1.0.24/src/fallback.rs:662:12 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" -proc-macro2-1.0.24/src/fallback.rs:664:12 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" -proc-macro2-1.0.24/src/fallback.rs:674:37 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" -proc-macro2-1.0.24/src/fallback.rs:678:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -proc-macro2-1.0.24/src/fallback.rs:85:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -proc-macro2-1.0.24/src/fallback.rs:882:43 clippy::unused_self "unused `self` argument" -proc-macro2-1.0.24/src/lib.rs:1017:9 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:1081:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:1099:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:1117:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:1135:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:1141:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:1146:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:1151:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:1156:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:152:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:157:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:373:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:383:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:397:24 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -proc-macro2-1.0.24/src/lib.rs:397:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:403:23 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -proc-macro2-1.0.24/src/lib.rs:403:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:418:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:425:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:464:17 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -proc-macro2-1.0.24/src/lib.rs:500:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:626:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:633:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:641:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:652:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:662:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:672:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:734:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:743:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:752:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:757:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:788:19 clippy::doc_markdown "you should put `XID_Start` between ticks in the documentation" -proc-macro2-1.0.24/src/lib.rs:788:69 clippy::doc_markdown "you should put `XID_Continue` between ticks in the documentation" -proc-macro2-1.0.24/src/lib.rs:891:36 clippy::doc_markdown "you should put `syn::parse_str` between ticks in the documentation" -proc-macro2-1.0.24/src/lib.rs:894:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:911:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:996:9 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/parse.rs:552:5 clippy::while_let_on_iterator "this loop could be written as a `for` loop" -proc-macro2-1.0.24/src/parse.rs:584:21 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" -proc-macro2-1.0.24/src/parse.rs:602:20 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" -proc-macro2-1.0.24/src/parse.rs:696:29 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" -proc-macro2-1.0.24/src/parse.rs:702:34 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" -proc-macro2-1.0.24/src/parse.rs:708:34 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" -proc-macro2-1.0.24/src/parse.rs:793:5 clippy::vec_init_then_push "calls to `push` immediately after creation" -proc-macro2-1.0.24/src/parse.rs:803:15 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" -proc-macro2-1.0.24/src/parse.rs:808:15 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" -proc-macro2-1.0.24/src/wrapper.rs:415:24 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -proc-macro2-1.0.24/src/wrapper.rs:429:23 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -proc-macro2-1.0.24/src/wrapper.rs:492:17 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -puffin-02dd4a3/puffin-imgui/src/ui.rs:158:15 clippy::cast_precision_loss "casting `i64` to `f32` causes a loss of precision (`i64` is 64 bits wide, but `f32`'s mantissa is only 23 bits wide)" -puffin-02dd4a3/puffin-imgui/src/ui.rs:175:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -puffin-02dd4a3/puffin-imgui/src/ui.rs:183:5 clippy::too_many_lines "this function has too many lines (115/100)" -puffin-02dd4a3/puffin-imgui/src/ui.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -puffin-02dd4a3/puffin-imgui/src/ui.rs:207:16 clippy::collapsible_else_if "this `else { if .. }` block can be collapsed" -puffin-02dd4a3/puffin-imgui/src/ui.rs:271:67 clippy::cast_precision_loss "casting `i64` to `f32` causes a loss of precision (`i64` is 64 bits wide, but `f32`'s mantissa is only 23 bits wide)" -puffin-02dd4a3/puffin-imgui/src/ui.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -puffin-02dd4a3/puffin-imgui/src/ui.rs:376:29 clippy::cast_precision_loss "casting `i64` to `f32` causes a loss of precision (`i64` is 64 bits wide, but `f32`'s mantissa is only 23 bits wide)" -puffin-02dd4a3/puffin-imgui/src/ui.rs:381:44 clippy::cast_precision_loss "casting `i64` to `f32` causes a loss of precision (`i64` is 64 bits wide, but `f32`'s mantissa is only 23 bits wide)" -puffin-02dd4a3/puffin-imgui/src/ui.rs:453:9 clippy::similar_names "binding's name is too similar to existing binding" -puffin-02dd4a3/puffin-imgui/src/ui.rs:540:14 clippy::cast_possible_truncation "casting `f64` to `f32` may truncate the value" -puffin-02dd4a3/puffin-imgui/src/ui.rs:551:5 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -puffin-02dd4a3/puffin-imgui/src/ui.rs:584:39 clippy::cast_precision_loss "casting `usize` to `f32` causes a loss of precision (`usize` is 32 or 64 bits wide, but `f32`'s mantissa is only 23 bits wide)" -puffin-02dd4a3/puffin-imgui/src/ui.rs:59:26 clippy::unsafe_derive_deserialize "you are deriving `serde::Deserialize` on a type that has methods using `unsafe`" -puffin-02dd4a3/puffin-imgui/src/ui.rs:61:1 clippy::module_name_repetitions "item name ends with its containing module's name" -puffin-02dd4a3/puffin-imgui/src/ui.rs:627:39 clippy::cast_precision_loss "casting `usize` to `f32` causes a loss of precision (`usize` is 32 or 64 bits wide, but `f32`'s mantissa is only 23 bits wide)" -puffin-02dd4a3/puffin-imgui/src/ui.rs:674:47 clippy::cast_precision_loss "casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -puffin-02dd4a3/puffin-imgui/src/ui.rs:690:9 clippy::cast_precision_loss "casting `usize` to `f32` causes a loss of precision (`usize` is 32 or 64 bits wide, but `f32`'s mantissa is only 23 bits wide)" -puffin-02dd4a3/puffin/src/data.rs:102:25 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" -puffin-02dd4a3/puffin/src/data.rs:112:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -puffin-02dd4a3/puffin/src/data.rs:116:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -puffin-02dd4a3/puffin/src/data.rs:137:24 clippy::match_same_arms "this `match` has identical arm bodies" -puffin-02dd4a3/puffin/src/data.rs:177:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -puffin-02dd4a3/puffin/src/data.rs:211:21 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -puffin-02dd4a3/puffin/src/data.rs:24:5 clippy::wildcard_imports "usage of wildcard import" -puffin-02dd4a3/puffin/src/data.rs:75:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -puffin-02dd4a3/puffin/src/lib.rs:113:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -puffin-02dd4a3/puffin/src/lib.rs:147:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -puffin-02dd4a3/puffin/src/lib.rs:147:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -puffin-02dd4a3/puffin/src/lib.rs:165:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -puffin-02dd4a3/puffin/src/lib.rs:200:21 clippy::default_trait_access "calling `Stream::default()` is more clear than this expression" -puffin-02dd4a3/puffin/src/lib.rs:257:78 clippy::default_trait_access "calling `std::cell::RefCell::default()` is more clear than this expression" -puffin-02dd4a3/puffin/src/lib.rs:297:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -puffin-02dd4a3/puffin/src/lib.rs:302:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -puffin-02dd4a3/puffin/src/lib.rs:308:28 clippy::default_trait_access "calling `FullProfileData::default()` is more clear than this expression" -puffin-02dd4a3/puffin/src/lib.rs:316:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -puffin-02dd4a3/puffin/src/lib.rs:321:5 clippy::cast_possible_truncation "casting `u128` to `i64` may truncate the value" -puffin-02dd4a3/puffin/src/lib.rs:348:28 clippy::default_trait_access "calling `std::marker::PhantomData::default()` is more clear than this expression" -puffin-02dd4a3/puffin/src/lib.rs:359:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -puffin-02dd4a3/puffin/src/lib.rs:375:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -puffin-02dd4a3/puffin/src/lib.rs:376:5 clippy::option_if_let_else "use Option::map_or instead of an if let/else" -puffin-02dd4a3/puffin/src/lib.rs:377:9 clippy::option_if_let_else "use Option::map_or instead of an if let/else" -puffin-02dd4a3/puffin/src/lib.rs:406:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -puffin-02dd4a3/puffin/src/lib.rs:408:5 clippy::option_if_let_else "use Option::map_or instead of an if let/else" -puffin-02dd4a3/puffin/src/lib.rs:69:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -puffin-02dd4a3/puffin/src/lib.rs:73:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -puffin-02dd4a3/puffin/src/lib.rs:77:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -puffin-02dd4a3/puffin/src/merge.rs:21:1 clippy::module_name_repetitions "item name starts with its containing module's name" -puffin-02dd4a3/puffin/src/merge.rs:28:1 clippy::module_name_repetitions "item name starts with its containing module's name" -puffin-02dd4a3/puffin/src/merge.rs:28:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -puffin-02dd4a3/puffin/src/merge.rs:35:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -puffin-02dd4a3/puffin/src/merge.rs:35:1 clippy::module_name_repetitions "item name starts with its containing module's name" -puffin-02dd4a3/puffin/src/merge.rs:64:43 clippy::default_trait_access "calling `std::vec::Vec::default()` is more clear than this expression" -puffin-02dd4a3/puffin/src/merge.rs:65:54 clippy::default_trait_access "calling `std::collections::HashMap::default()` is more clear than this expression" -puffin-02dd4a3/puffin/src/merge.rs:9:1 clippy::module_name_repetitions "item name starts with its containing module's name" -quote-1.0.7/src/ext.rs:10:1 clippy::module_name_repetitions "item name ends with its containing module's name" -quote-1.0.7/src/ext.rs:7:5 clippy::doc_markdown "you should put `TokenStream` between ticks in the documentation" -quote-1.0.7/src/ident_fragment.rs:13:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -quote-1.0.7/src/ident_fragment.rs:51:31 clippy::manual_strip "stripping a prefix manually" -quote-1.0.7/src/runtime.rs:332:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -quote-1.0.7/src/runtime.rs:52:5 clippy::module_name_repetitions "item name ends with its containing module's name" -quote-1.0.7/src/runtime.rs:63:5 clippy::module_name_repetitions "item name ends with its containing module's name" -quote-1.0.7/src/runtime.rs:66:33 clippy::doc_markdown "you should put `DoesNotHaveIter` between ticks in the documentation" -quote-1.0.7/src/runtime.rs:80:5 clippy::module_name_repetitions "item name ends with its containing module's name" -rand-0.7.3/src/distributions/bernoulli.rs:103:20 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" -rand-0.7.3/src/distributions/bernoulli.rs:103:20 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" -rand-0.7.3/src/distributions/bernoulli.rs:116:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -rand-0.7.3/src/distributions/bernoulli.rs:123:21 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" -rand-0.7.3/src/distributions/bernoulli.rs:123:21 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" -rand-0.7.3/src/distributions/bernoulli.rs:63:26 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand-0.7.3/src/distributions/bernoulli.rs:63:27 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -rand-0.7.3/src/distributions/bernoulli.rs:67:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand-0.7.3/src/distributions/bernoulli.rs:95:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -rand-0.7.3/src/distributions/bernoulli.rs:96:13 clippy::manual_range_contains "manual `Range::contains` implementation" -rand-0.7.3/src/distributions/binomial.rs:107:23 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand-0.7.3/src/distributions/binomial.rs:112:44 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand-0.7.3/src/distributions/binomial.rs:116:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rand-0.7.3/src/distributions/binomial.rs:150:28 clippy::redundant_else "redundant else block" -rand-0.7.3/src/distributions/binomial.rs:153:24 clippy::if_not_else "unnecessary boolean `not` operation" -rand-0.7.3/src/distributions/binomial.rs:158:28 clippy::redundant_else "redundant else block" -rand-0.7.3/src/distributions/binomial.rs:164:33 clippy::cast_sign_loss "casting `i64` to `u64` may lose the sign of the value" -rand-0.7.3/src/distributions/binomial.rs:166:28 clippy::redundant_else "redundant else block" -rand-0.7.3/src/distributions/binomial.rs:175:47 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand-0.7.3/src/distributions/binomial.rs:185:38 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand-0.7.3/src/distributions/binomial.rs:194:38 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand-0.7.3/src/distributions/binomial.rs:202:28 clippy::redundant_else "redundant else block" -rand-0.7.3/src/distributions/binomial.rs:209:25 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand-0.7.3/src/distributions/binomial.rs:221:26 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand-0.7.3/src/distributions/binomial.rs:222:26 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand-0.7.3/src/distributions/binomial.rs:223:25 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand-0.7.3/src/distributions/binomial.rs:224:25 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand-0.7.3/src/distributions/binomial.rs:226:17 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rand-0.7.3/src/distributions/binomial.rs:233:32 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand-0.7.3/src/distributions/binomial.rs:234:27 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand-0.7.3/src/distributions/binomial.rs:251:22 clippy::cast_sign_loss "casting `i64` to `u64` may lose the sign of the value" -rand-0.7.3/src/distributions/binomial.rs:255:9 clippy::if_not_else "unnecessary `!=` operation" -rand-0.7.3/src/distributions/binomial.rs:35:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -rand-0.7.3/src/distributions/binomial.rs:35:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/distributions/binomial.rs:45:17 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand-0.7.3/src/distributions/binomial.rs:46:5 clippy::cast_possible_truncation "casting `f64` to `i64` may truncate the value" -rand-0.7.3/src/distributions/binomial.rs:50:5 clippy::too_many_lines "this function has too many lines (143/100)" -rand-0.7.3/src/distributions/binomial.rs:76:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rand-0.7.3/src/distributions/binomial.rs:78:12 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand-0.7.3/src/distributions/binomial.rs:81:21 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand-0.7.3/src/distributions/binomial.rs:82:32 clippy::cast_possible_truncation "casting `u64` to `i32` may truncate the value" -rand-0.7.3/src/distributions/binomial.rs:88:26 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand-0.7.3/src/distributions/binomial.rs:99:21 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand-0.7.3/src/distributions/cauchy.rs:33:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -rand-0.7.3/src/distributions/cauchy.rs:33:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/distributions/dirichlet.rs:52:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/distributions/dirichlet.rs:64:32 clippy::unseparated_literal_suffix "float type suffix should be separated by an underscore" -rand-0.7.3/src/distributions/dirichlet.rs:65:23 clippy::unseparated_literal_suffix "float type suffix should be separated by an underscore" -rand-0.7.3/src/distributions/exponential.rs:76:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -rand-0.7.3/src/distributions/exponential.rs:76:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/distributions/float.rs:73:1 clippy::module_name_repetitions "item name ends with its containing module's name" -rand-0.7.3/src/distributions/gamma.rs:13:5 clippy::enum_glob_use "usage of wildcard import for enum variants" -rand-0.7.3/src/distributions/gamma.rs:14:5 clippy::enum_glob_use "usage of wildcard import for enum variants" -rand-0.7.3/src/distributions/gamma.rs:189:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -rand-0.7.3/src/distributions/gamma.rs:189:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/distributions/gamma.rs:230:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -rand-0.7.3/src/distributions/gamma.rs:230:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/distributions/gamma.rs:259:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -rand-0.7.3/src/distributions/gamma.rs:259:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/distributions/gamma.rs:287:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -rand-0.7.3/src/distributions/gamma.rs:287:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/distributions/gamma.rs:90:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -rand-0.7.3/src/distributions/gamma.rs:90:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/distributions/integer.rs:23:9 clippy::cast_possible_truncation "casting `u32` to `u8` may truncate the value" -rand-0.7.3/src/distributions/integer.rs:30:9 clippy::cast_possible_truncation "casting `u32` to `u16` may truncate the value" -rand-0.7.3/src/distributions/integer.rs:69:9 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -rand-0.7.3/src/distributions/mod.rs:263:5 clippy::inline_always "you have declared `#[inline(always)]` on `next`. This is usually a bad idea" -rand-0.7.3/src/distributions/normal.rs:100:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/distributions/normal.rs:119:1 clippy::module_name_repetitions "item name ends with its containing module's name" -rand-0.7.3/src/distributions/normal.rs:131:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/distributions/normal.rs:31:1 clippy::module_name_repetitions "item name ends with its containing module's name" -rand-0.7.3/src/distributions/normal.rs:47:25 clippy::unseparated_literal_suffix "float type suffix should be separated by an underscore" -rand-0.7.3/src/distributions/normal.rs:48:25 clippy::unseparated_literal_suffix "float type suffix should be separated by an underscore" -rand-0.7.3/src/distributions/other.rs:89:9 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -rand-0.7.3/src/distributions/pareto.rs:32:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/distributions/poisson.rs:35:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -rand-0.7.3/src/distributions/poisson.rs:35:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/distributions/poisson.rs:87:30 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" -rand-0.7.3/src/distributions/poisson.rs:87:30 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" -rand-0.7.3/src/distributions/triangular.rs:32:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/distributions/uniform.rs:146:4 clippy::needless_doctest_main "needless `fn main` in doctest" -rand-0.7.3/src/distributions/uniform.rs:199:1 clippy::module_name_repetitions "item name ends with its containing module's name" -rand-0.7.3/src/distributions/uniform.rs:214:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand-0.7.3/src/distributions/uniform.rs:283:14 clippy::doc_markdown "you should put `SampleUniform` between ticks in the documentation" -rand-0.7.3/src/distributions/uniform.rs:283:46 clippy::doc_markdown "you should put `SampleUniform` between ticks in the documentation" -rand-0.7.3/src/distributions/uniform.rs:296:5 clippy::inline_always "you have declared `#[inline(always)]` on `borrow`. This is usually a bad idea" -rand-0.7.3/src/distributions/uniform.rs:304:5 clippy::inline_always "you have declared `#[inline(always)]` on `borrow`. This is usually a bad idea" -rand-0.7.3/src/distributions/uniform.rs:350:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand-0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" -rand-0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" -rand-0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" -rand-0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" -rand-0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" -rand-0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" -rand-0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" -rand-0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" -rand-0.7.3/src/distributions/uniform.rs:56:10 clippy::doc_markdown "you should put `SampleBorrow` between ticks in the documentation" -rand-0.7.3/src/distributions/uniform.rs:647:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand-0.7.3/src/distributions/uniform.rs:840:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand-0.7.3/src/distributions/uniform.rs:913:13 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" -rand-0.7.3/src/distributions/uniform.rs:943:54 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" -rand-0.7.3/src/distributions/unit_circle.rs:30:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/distributions/unit_sphere.rs:24:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand-0.7.3/src/distributions/unit_sphere.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/distributions/utils.rs:218:18 clippy::upper_case_acronyms "name `FloatSIMDUtils` contains a capitalized acronym" -rand-0.7.3/src/distributions/utils.rs:247:15 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" -rand-0.7.3/src/distributions/utils.rs:248:20 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" -rand-0.7.3/src/distributions/utils.rs:249:18 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" -rand-0.7.3/src/distributions/utils.rs:253:18 clippy::upper_case_acronyms "name `FloatAsSIMD` contains a capitalized acronym" -rand-0.7.3/src/distributions/utils.rs:254:5 clippy::inline_always "you have declared `#[inline(always)]` on `lanes`. This is usually a bad idea" -rand-0.7.3/src/distributions/utils.rs:258:5 clippy::inline_always "you have declared `#[inline(always)]` on `splat`. This is usually a bad idea" -rand-0.7.3/src/distributions/utils.rs:262:5 clippy::inline_always "you have declared `#[inline(always)]` on `extract`. This is usually a bad idea" -rand-0.7.3/src/distributions/utils.rs:267:5 clippy::inline_always "you have declared `#[inline(always)]` on `replace`. This is usually a bad idea" -rand-0.7.3/src/distributions/utils.rs:274:18 clippy::upper_case_acronyms "name `BoolAsSIMD` contains a capitalized acronym" -rand-0.7.3/src/distributions/utils.rs:281:5 clippy::inline_always "you have declared `#[inline(always)]` on `any`. This is usually a bad idea" -rand-0.7.3/src/distributions/utils.rs:286:5 clippy::inline_always "you have declared `#[inline(always)]` on `all`. This is usually a bad idea" -rand-0.7.3/src/distributions/utils.rs:291:5 clippy::inline_always "you have declared `#[inline(always)]` on `none`. This is usually a bad idea" -rand-0.7.3/src/distributions/utils.rs:488:17 clippy::doc_markdown "you should put `x_i` between ticks in the documentation" -rand-0.7.3/src/distributions/utils.rs:489:50 clippy::doc_markdown "you should put `x_i` between ticks in the documentation" -rand-0.7.3/src/distributions/utils.rs:489:63 clippy::doc_markdown "you should put `f(x_i` between ticks in the documentation" -rand-0.7.3/src/distributions/utils.rs:490:40 clippy::doc_markdown "you should put `f(x_i` between ticks in the documentation" -rand-0.7.3/src/distributions/utils.rs:490:49 clippy::doc_markdown "you should put `f(x_{i+1` between ticks in the documentation" -rand-0.7.3/src/distributions/utils.rs:518:17 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -rand-0.7.3/src/distributions/weibull.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/distributions/weighted/alias_method.rs:113:21 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" -rand-0.7.3/src/distributions/weighted/alias_method.rs:125:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rand-0.7.3/src/distributions/weighted/alias_method.rs:131:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rand-0.7.3/src/distributions/weighted/alias_method.rs:180:36 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -rand-0.7.3/src/distributions/weighted/alias_method.rs:182:34 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -rand-0.7.3/src/distributions/weighted/alias_method.rs:259:28 clippy::clone_on_copy "using `clone` on type `distributions::uniform::Uniform` which implements the `Copy` trait" -rand-0.7.3/src/distributions/weighted/alias_method.rs:296:9 clippy::map_clone "you are using an explicit closure for copying elements" -rand-0.7.3/src/distributions/weighted/alias_method.rs:321:9 clippy::map_clone "you are using an explicit closure for copying elements" -rand-0.7.3/src/distributions/weighted/alias_method.rs:78:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -rand-0.7.3/src/distributions/weighted/alias_method.rs:78:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -rand-0.7.3/src/distributions/weighted/alias_method.rs:78:5 clippy::too_many_lines "this function has too many lines (106/100)" -rand-0.7.3/src/distributions/weighted/alias_method.rs:85:17 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -rand-0.7.3/src/distributions/weighted/alias_method.rs:87:31 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" -rand-0.7.3/src/distributions/weighted/mod.rs:100:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -rand-0.7.3/src/distributions/weighted/mod.rs:144:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -rand-0.7.3/src/distributions/weighted/mod.rs:144:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -rand-0.7.3/src/distributions/weighted/mod.rs:169:16 clippy::int_plus_one "unnecessary `>= y + 1` or `x - 1 >=`" -rand-0.7.3/src/distributions/weighted/mod.rs:386:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand-0.7.3/src/distributions/weighted/mod.rs:85:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand-0.7.3/src/lib.rs:333:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -rand-0.7.3/src/lib.rs:404:14 clippy::wrong_self_convention "methods called `to_*` usually take self by reference; consider choosing a less ambiguous name" -rand-0.7.3/src/lib.rs:552:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -rand-0.7.3/src/rngs/adapter/read.rs:47:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand-0.7.3/src/rngs/adapter/read.rs:89:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand-0.7.3/src/rngs/adapter/reseeding.rs:100:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -rand-0.7.3/src/rngs/adapter/reseeding.rs:112:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea" -rand-0.7.3/src/rngs/adapter/reseeding.rs:117:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea" -rand-0.7.3/src/rngs/adapter/reseeding.rs:198:13 clippy::cast_possible_wrap "casting `u64` to `i64` may wrap around the value" -rand-0.7.3/src/rngs/adapter/reseeding.rs:231:9 clippy::cast_possible_wrap "casting `usize` to `isize` may wrap around the value" -rand-0.7.3/src/rngs/adapter/reseeding.rs:27:28 clippy::doc_markdown "you should put `ChaCha` between ticks in the documentation" -rand-0.7.3/src/rngs/adapter/reseeding.rs:79:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand-0.7.3/src/rngs/entropy.rs:24:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand-0.7.3/src/rngs/entropy.rs:34:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/rngs/mock.rs:36:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/rngs/mock.rs:47:9 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" -rand-0.7.3/src/rngs/mod.rs:61:74 clippy::doc_markdown "you should put `ChaCha20` between ticks in the documentation" -rand-0.7.3/src/rngs/std.rs:25:39 clippy::doc_markdown "you should put `ChaCha` between ticks in the documentation" -rand-0.7.3/src/rngs/std.rs:32:10 clippy::doc_markdown "you should put `rand_chacha` between ticks in the documentation" -rand-0.7.3/src/rngs/std.rs:36:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand-0.7.3/src/rngs/std.rs:39:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea" -rand-0.7.3/src/rngs/std.rs:44:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea" -rand-0.7.3/src/rngs/std.rs:49:5 clippy::inline_always "you have declared `#[inline(always)]` on `fill_bytes`. This is usually a bad idea" -rand-0.7.3/src/rngs/std.rs:54:5 clippy::inline_always "you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea" -rand-0.7.3/src/rngs/std.rs:63:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_seed`. This is usually a bad idea" -rand-0.7.3/src/rngs/std.rs:68:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_rng`. This is usually a bad idea" -rand-0.7.3/src/rngs/thread.rs:57:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand-0.7.3/src/rngs/thread.rs:80:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -rand-0.7.3/src/rngs/thread.rs:80:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand-0.7.3/src/rngs/thread.rs:80:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -rand-0.7.3/src/rngs/thread.rs:81:35 clippy::redundant_closure_for_method_calls "redundant closure found" -rand-0.7.3/src/rngs/thread.rs:93:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea" -rand-0.7.3/src/rngs/thread.rs:98:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea" -rand-0.7.3/src/seq/index.rs:127:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand-0.7.3/src/seq/index.rs:139:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -rand-0.7.3/src/seq/index.rs:159:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand-0.7.3/src/seq/index.rs:171:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -rand-0.7.3/src/seq/index.rs:180:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -rand-0.7.3/src/seq/index.rs:213:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -rand-0.7.3/src/seq/index.rs:223:18 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -rand-0.7.3/src/seq/index.rs:224:18 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -rand-0.7.3/src/seq/index.rs:233:25 clippy::cast_precision_loss "casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide)" -rand-0.7.3/src/seq/index.rs:236:27 clippy::cast_precision_loss "casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide)" -rand-0.7.3/src/seq/index.rs:244:12 clippy::cast_precision_loss "casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide)" -rand-0.7.3/src/seq/index.rs:244:37 clippy::cast_precision_loss "casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide)" -rand-0.7.3/src/seq/index.rs:29:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand-0.7.3/src/seq/index.rs:39:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/seq/index.rs:48:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/seq/index.rs:60:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/seq/index.rs:69:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/seq/index.rs:78:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/seq/index.rs:87:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/seq/index.rs:87:5 clippy::should_implement_trait "method `into_iter` can be confused for the standard trait method `std::iter::IntoIterator::into_iter`" -rand-0.7.3/src/seq/index.rs:97:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -rand-0.7.3/src/seq/mod.rs:141:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -rand-0.7.3/src/seq/mod.rs:168:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -rand-0.7.3/src/seq/mod.rs:229:4 clippy::needless_doctest_main "needless `fn main` in doctest" -rand-0.7.3/src/seq/mod.rs:292:29 clippy::cast_precision_loss "casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand-0.7.3/src/seq/mod.rs:410:23 clippy::default_trait_access "calling `std::marker::PhantomData::default()` is more clear than this expression" -rand-0.7.3/src/seq/mod.rs:45:4 clippy::needless_doctest_main "needless `fn main` in doctest" -rand-0.7.3/src/seq/mod.rs:527:26 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -rand_core-0.6.0/src/block.rs:117:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand_core-0.6.0/src/block.rs:153:5 clippy::inline_always "you have declared `#[inline(always)]` on `index`. This is usually a bad idea" -rand_core-0.6.0/src/block.rs:168:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -rand_core-0.6.0/src/block.rs:230:5 clippy::inline_always "you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea" -rand_core-0.6.0/src/block.rs:240:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_seed`. This is usually a bad idea" -rand_core-0.6.0/src/block.rs:245:5 clippy::inline_always "you have declared `#[inline(always)]` on `seed_from_u64`. This is usually a bad idea" -rand_core-0.6.0/src/block.rs:250:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_rng`. This is usually a bad idea" -rand_core-0.6.0/src/block.rs:280:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand_core-0.6.0/src/block.rs:319:5 clippy::inline_always "you have declared `#[inline(always)]` on `index`. This is usually a bad idea" -rand_core-0.6.0/src/block.rs:335:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -rand_core-0.6.0/src/block.rs:405:5 clippy::inline_always "you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea" -rand_core-0.6.0/src/block.rs:415:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_seed`. This is usually a bad idea" -rand_core-0.6.0/src/block.rs:420:5 clippy::inline_always "you have declared `#[inline(always)]` on `seed_from_u64`. This is usually a bad idea" -rand_core-0.6.0/src/block.rs:425:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_rng`. This is usually a bad idea" -rand_core-0.6.0/src/block.rs:67:14 clippy::doc_markdown "you should put `module][crate::block` between ticks in the documentation" -rand_core-0.6.0/src/block.rs:68:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand_core-0.6.0/src/error.rs:106:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand_core-0.6.0/src/error.rs:87:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand_core-0.6.0/src/error.rs:95:74 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -rand_core-0.6.0/src/le.rs:18:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -rand_core-0.6.0/src/le.rs:27:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -rand_core-0.6.0/src/lib.rs:179:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -rand_core-0.6.0/src/lib.rs:301:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand_core-0.6.0/src/lib.rs:303:26 clippy::unreadable_literal "long literal lacking separators" -rand_core-0.6.0/src/lib.rs:304:26 clippy::unreadable_literal "long literal lacking separators" -rand_core-0.6.0/src/lib.rs:313:30 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" -rand_core-0.6.0/src/lib.rs:314:23 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" -rand_core-0.6.0/src/lib.rs:346:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -rand_core-0.6.0/src/lib.rs:381:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea" -rand_core-0.6.0/src/lib.rs:386:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea" -rand_core-0.6.0/src/lib.rs:391:5 clippy::inline_always "you have declared `#[inline(always)]` on `fill_bytes`. This is usually a bad idea" -rand_core-0.6.0/src/lib.rs:396:5 clippy::inline_always "you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea" -rayon-1.5.0/src/collections/binary_heap.rs:7:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/collections/binary_heap.rs:8:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/collections/btree_map.rs:7:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/collections/btree_map.rs:8:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/collections/btree_set.rs:7:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/collections/btree_set.rs:8:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/collections/hash_map.rs:10:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/collections/hash_map.rs:9:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/collections/hash_set.rs:10:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/collections/hash_set.rs:9:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/collections/linked_list.rs:7:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/collections/linked_list.rs:8:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/collections/mod.rs:59:32 clippy::mem_replace_with_default "replacing a value of type `T` with `T::default()` is better expressed using `std::mem::take`" -rayon-1.5.0/src/collections/vec_deque.rs:8:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/collections/vec_deque.rs:9:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/compile_fail/cannot_collect_filtermap_data.rs:2:1 clippy::needless_doctest_main "needless `fn main` in doctest" -rayon-1.5.0/src/compile_fail/cannot_zip_filtered_data.rs:2:1 clippy::needless_doctest_main "needless `fn main` in doctest" -rayon-1.5.0/src/compile_fail/cell_par_iter.rs:2:1 clippy::needless_doctest_main "needless `fn main` in doctest" -rayon-1.5.0/src/compile_fail/no_send_par_iter.rs:25:1 clippy::needless_doctest_main "needless `fn main` in doctest" -rayon-1.5.0/src/compile_fail/no_send_par_iter.rs:46:1 clippy::needless_doctest_main "needless `fn main` in doctest" -rayon-1.5.0/src/compile_fail/no_send_par_iter.rs:4:1 clippy::needless_doctest_main "needless `fn main` in doctest" -rayon-1.5.0/src/compile_fail/rc_par_iter.rs:2:1 clippy::needless_doctest_main "needless `fn main` in doctest" -rayon-1.5.0/src/iter/chain.rs:103:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/chain.rs:122:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/chain.rs:128:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/chain.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/chain.rs:221:36 clippy::doc_markdown "you should put `ExactSizeIterator` between ticks in the documentation" -rayon-1.5.0/src/iter/chain.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/chain.rs:51:38 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" -rayon-1.5.0/src/iter/chain.rs:58:14 clippy::shadow_unrelated "`a` is being shadowed" -rayon-1.5.0/src/iter/chain.rs:58:17 clippy::shadow_unrelated "`b` is being shadowed" -rayon-1.5.0/src/iter/chain.rs:78:14 clippy::shadow_unrelated "`a` is being shadowed" -rayon-1.5.0/src/iter/chain.rs:78:17 clippy::shadow_unrelated "`b` is being shadowed" -rayon-1.5.0/src/iter/chain.rs:97:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/chunks.rs:3:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/chunks.rs:4:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/chunks.rs:77:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/chunks.rs:83:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/cloned.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/cloned.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/cloned.rs:71:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/cloned.rs:75:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/collect/consumer.rs:141:5 clippy::doc_markdown "you should put `CollectReducer` between ticks in the documentation" -rayon-1.5.0/src/iter/collect/consumer.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/collect/consumer.rs:28:5 clippy::doc_markdown "you should put `CollectResult` between ticks in the documentation" -rayon-1.5.0/src/iter/collect/consumer.rs:36:37 clippy::mut_mut "generally you want to avoid `&mut &mut _` if possible" -rayon-1.5.0/src/iter/collect/consumer.rs:36:37 clippy::mut_mut "generally you want to avoid `&mut &mut _` if possible" -rayon-1.5.0/src/iter/collect/mod.rs:154:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -rayon-1.5.0/src/iter/copied.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/copied.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/copied.rs:71:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/copied.rs:75:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/empty.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/empty.rs:24:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -rayon-1.5.0/src/iter/empty.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/enumerate.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/enumerate.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/enumerate.rs:64:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/enumerate.rs:68:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/extend.rs:143:63 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" -rayon-1.5.0/src/iter/extend.rs:182:57 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" -rayon-1.5.0/src/iter/extend.rs:218:32 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" -rayon-1.5.0/src/iter/extend.rs:218:59 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" -rayon-1.5.0/src/iter/extend.rs:25:42 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" -rayon-1.5.0/src/iter/extend.rs:287:62 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" -rayon-1.5.0/src/iter/extend.rs:322:56 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" -rayon-1.5.0/src/iter/extend.rs:41:27 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" -rayon-1.5.0/src/iter/extend.rs:47:30 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" -rayon-1.5.0/src/iter/extend.rs:47:56 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" -rayon-1.5.0/src/iter/extend.rs:47:74 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" -rayon-1.5.0/src/iter/extend.rs:53:29 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" -rayon-1.5.0/src/iter/extend.rs:57:36 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" -rayon-1.5.0/src/iter/extend.rs:59:61 clippy::linkedlist "I see you're using a LinkedList! Perhaps you meant some other data structure?" -rayon-1.5.0/src/iter/filter.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/filter.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/filter_map.rs:123:9 clippy::option_if_let_else "use Option::map_or instead of an if let/else" -rayon-1.5.0/src/iter/filter_map.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/filter_map.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/find.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/find.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/find_first_last/mod.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/find_first_last/mod.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/find_first_last/mod.rs:32:67 clippy::doc_markdown "you should put `MatchPosition` between ticks in the documentation" -rayon-1.5.0/src/iter/flat_map.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/flat_map.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/flat_map_iter.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/flat_map_iter.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/flatten.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/flatten.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/flatten_iter.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/flatten_iter.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/fold.rs:158:13 clippy::similar_names "binding's name is too similar to existing binding" -rayon-1.5.0/src/iter/fold.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/fold.rs:204:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rayon-1.5.0/src/iter/fold.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/for_each.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/for_each.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/inspect.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/inspect.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/inspect.rs:83:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/inspect.rs:88:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/interleave.rs:111:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/interleave.rs:119:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/interleave.rs:195:30 clippy::doc_markdown "you should put `self.i_len` between ticks in the documentation" -rayon-1.5.0/src/iter/interleave.rs:195:43 clippy::doc_markdown "you should put `self.j_len` between ticks in the documentation" -rayon-1.5.0/src/iter/interleave.rs:199:23 clippy::doc_markdown "you should put `self.i_len` between ticks in the documentation" -rayon-1.5.0/src/iter/interleave.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/interleave.rs:200:23 clippy::doc_markdown "you should put `self.j_len` between ticks in the documentation" -rayon-1.5.0/src/iter/interleave.rs:249:41 clippy::doc_markdown "you should put `DoubleEndedIterator` between ticks in the documentation" -rayon-1.5.0/src/iter/interleave.rs:250:5 clippy::doc_markdown "you should put `ExactSizeIterator` between ticks in the documentation" -rayon-1.5.0/src/iter/interleave.rs:263:33 clippy::doc_markdown "you should put `InterleaveSeq` between ticks in the documentation" -rayon-1.5.0/src/iter/interleave.rs:280:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" -rayon-1.5.0/src/iter/interleave.rs:285:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" -rayon-1.5.0/src/iter/interleave.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/interleave.rs:313:9 clippy::comparison_chain "`if` chain can be rewritten with `match`" -rayon-1.5.0/src/iter/interleave.rs:82:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/interleave.rs:90:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/interleave_shortest.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/intersperse.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/intersperse.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/intersperse.rs:90:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/intersperse.rs:96:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/len.rs:12:1 clippy::module_name_repetitions "item name ends with its containing module's name" -rayon-1.5.0/src/iter/len.rs:146:1 clippy::module_name_repetitions "item name ends with its containing module's name" -rayon-1.5.0/src/iter/len.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/len.rs:200:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/len.rs:205:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/len.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/len.rs:66:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/len.rs:71:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/map.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/map.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/map.rs:84:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/map.rs:89:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/map_with.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/map_with.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/map_with.rs:419:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/map_with.rs:425:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/map_with.rs:90:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/map_with.rs:96:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/mod.rs:1874:24 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -rayon-1.5.0/src/iter/mod.rs:2171:1 clippy::len_without_is_empty "trait `IndexedParallelIterator` has a `len` method but no (possibly inherited) `is_empty` method" -rayon-1.5.0/src/iter/mod.rs:2371:26 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -rayon-1.5.0/src/iter/mod.rs:2411:26 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -rayon-1.5.0/src/iter/mod.rs:82:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/multizip.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/multizip.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/noop.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/once.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/once.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/panic_fuse.rs:102:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/panic_fuse.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/panic_fuse.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/panic_fuse.rs:98:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/par_bridge.rs:136:28 clippy::redundant_else "redundant else block" -rayon-1.5.0/src/iter/par_bridge.rs:163:28 clippy::redundant_else "redundant else block" -rayon-1.5.0/src/iter/plumbing/mod.rs:216:58 clippy::doc_markdown "you should put `find_first` between ticks in the documentation" -rayon-1.5.0/src/iter/plumbing/mod.rs:359:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/plumbing/mod.rs:364:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/plumbing/mod.rs:399:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/plumbing/mod.rs:53:19 clippy::doc_markdown "you should put `DoubleEndedIterator` between ticks in the documentation" -rayon-1.5.0/src/iter/plumbing/mod.rs:53:43 clippy::doc_markdown "you should put `ExactSizeIterator` between ticks in the documentation" -rayon-1.5.0/src/iter/plumbing/mod.rs:54:31 clippy::doc_markdown "you should put `IntoIterator` between ticks in the documentation" -rayon-1.5.0/src/iter/plumbing/mod.rs:55:5 clippy::doc_markdown "you should put `IntoIterator` between ticks in the documentation" -rayon-1.5.0/src/iter/positions.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/positions.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/product.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/reduce.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/repeat.rs:103:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rayon-1.5.0/src/iter/repeat.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/repeat.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/rev.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/rev.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/rev.rs:63:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/rev.rs:68:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/skip.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/skip.rs:3:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/skip.rs:68:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/skip.rs:73:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/splitter.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/splitter.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/step_by.rs:4:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/step_by.rs:5:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/step_by.rs:73:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/step_by.rs:79:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/sum.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/take.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/take.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/take.rs:67:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/take.rs:72:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/try_fold.rs:190:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rayon-1.5.0/src/iter/try_fold.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/try_fold.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/try_reduce.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/try_reduce_with.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/unzip.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/unzip.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/update.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/update.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/update.rs:82:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/update.rs:87:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/while_some.rs:130:22 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -rayon-1.5.0/src/iter/while_some.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/while_some.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/zip.rs:102:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/zip.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/zip.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/zip.rs:74:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/zip.rs:79:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/zip.rs:97:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/zip_eq.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/zip_eq.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/option.rs:8:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/option.rs:9:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/par_either.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/par_either.rs:3:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/private.rs:9:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rayon-1.5.0/src/range.rs:19:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/range.rs:20:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/range_inclusive.rs:194:9 clippy::range_plus_one "an inclusive range would be more readable" -rayon-1.5.0/src/range_inclusive.rs:194:9 clippy::range_plus_one "an inclusive range would be more readable" -rayon-1.5.0/src/range_inclusive.rs:19:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/range_inclusive.rs:209:9 clippy::range_plus_one "an inclusive range would be more readable" -rayon-1.5.0/src/range_inclusive.rs:209:9 clippy::range_plus_one "an inclusive range would be more readable" -rayon-1.5.0/src/range_inclusive.rs:20:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/range_inclusive.rs:231:9 clippy::range_plus_one "an inclusive range would be more readable" -rayon-1.5.0/src/range_inclusive.rs:231:9 clippy::range_plus_one "an inclusive range would be more readable" -rayon-1.5.0/src/result.rs:8:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/result.rs:9:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/slice/mergesort.rs:102:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/slice/mergesort.rs:109:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/slice/mergesort.rs:114:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/slice/mergesort.rs:211:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/slice/mergesort.rs:217:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/slice/mergesort.rs:251:5 clippy::doc_markdown "you should put `TimSort` between ticks in the documentation" -rayon-1.5.0/src/slice/mergesort.rs:252:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" -rayon-1.5.0/src/slice/mergesort.rs:286:59 clippy::doc_markdown "you should put `TimSort` between ticks in the documentation" -rayon-1.5.0/src/slice/mergesort.rs:333:24 clippy::redundant_else "redundant else block" -rayon-1.5.0/src/slice/mergesort.rs:513:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/slice/mergesort.rs:521:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/slice/mergesort.rs:7:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/slice/mergesort.rs:98:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/slice/mod.rs:15:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/slice/mod.rs:16:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/slice/mod.rs:17:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/slice/mod.rs:25:1 clippy::module_name_repetitions "item name ends with its containing module's name" -rayon-1.5.0/src/slice/mod.rs:657:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rayon-1.5.0/src/slice/mod.rs:971:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rayon-1.5.0/src/slice/quicksort.rs:230:36 clippy::doc_markdown "you should put `BlockQuicksort` between ticks in the documentation" -rayon-1.5.0/src/slice/quicksort.rs:233:1 clippy::too_many_lines "this function has too many lines (117/100)" -rayon-1.5.0/src/slice/quicksort.rs:258:26 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -rayon-1.5.0/src/slice/quicksort.rs:265:26 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -rayon-1.5.0/src/slice/quicksort.rs:268:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/slice/quicksort.rs:308:30 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" -rayon-1.5.0/src/slice/quicksort.rs:325:30 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" -rayon-1.5.0/src/slice/quicksort.rs:393:36 clippy::cast_possible_wrap "casting `u8` to `isize` may wrap around the value on targets with 32-bit wide pointers" -rayon-1.5.0/src/slice/quicksort.rs:405:40 clippy::cast_possible_wrap "casting `u8` to `isize` may wrap around the value on targets with 32-bit wide pointers" -rayon-1.5.0/src/slice/quicksort.rs:430:14 clippy::shadow_unrelated "`pivot` is being shadowed" -rayon-1.5.0/src/slice/quicksort.rs:439:13 clippy::shadow_unrelated "`pivot` is being shadowed" -rayon-1.5.0/src/slice/quicksort.rs:482:10 clippy::shadow_unrelated "`pivot` is being shadowed" -rayon-1.5.0/src/slice/quicksort.rs:491:9 clippy::shadow_unrelated "`pivot` is being shadowed" -rayon-1.5.0/src/slice/quicksort.rs:534:26 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -rayon-1.5.0/src/slice/quicksort.rs:545:17 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -rayon-1.5.0/src/slice/quicksort.rs:588:17 clippy::identity_op "the operation is ineffective. Consider reducing it to `len / 4`" -rayon-1.5.0/src/slice/quicksort.rs:716:14 clippy::shadow_unrelated "`pivot` is being shadowed" -rayon-1.5.0/src/split_producer.rs:56:16 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" -rayon-1.5.0/src/split_producer.rs:92:9 clippy::option_if_let_else "use Option::map_or instead of an if let/else" -rayon-1.5.0/src/str.rs:16:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/str.rs:17:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/str.rs:18:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/str.rs:25:5 clippy::cast_possible_wrap "casting `u8` to `i8` may wrap around the value" -rayon-1.5.0/src/str.rs:715:9 clippy::manual_strip "stripping a suffix manually" -rayon-1.5.0/src/string.rs:5:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/vec.rs:137:12 clippy::len_zero "length comparison to zero" -rayon-1.5.0/src/vec.rs:8:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/vec.rs:9:5 clippy::wildcard_imports "usage of wildcard import" -regex-1.3.2/src/backtrack.rs:100:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/backtrack.rs:133:17 clippy::same_item_push "it looks like the same item is being pushed into this Vec" -regex-1.3.2/src/backtrack.rs:145:20 clippy::if_not_else "unnecessary boolean `not` operation" -regex-1.3.2/src/backtrack.rs:199:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/backtrack.rs:223:29 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/backtrack.rs:230:66 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/backtrack.rs:284:21 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" -regex-1.3.2/src/backtrack.rs:287:5 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex-1.3.2/src/backtrack.rs:97:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/backtrack.rs:98:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/backtrack.rs:99:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:1005:32 clippy::unreadable_literal "long literal lacking separators" -regex-1.3.2/src/compile.rs:1006:21 clippy::unreadable_literal "long literal lacking separators" -regex-1.3.2/src/compile.rs:1008:18 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" -regex-1.3.2/src/compile.rs:1009:18 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" -regex-1.3.2/src/compile.rs:1010:9 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -regex-1.3.2/src/compile.rs:102:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/compile.rs:1037:37 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" -regex-1.3.2/src/compile.rs:1037:55 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" -regex-1.3.2/src/compile.rs:1040:28 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" -regex-1.3.2/src/compile.rs:1040:38 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" -regex-1.3.2/src/compile.rs:1051:25 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -regex-1.3.2/src/compile.rs:1071:8 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" -regex-1.3.2/src/compile.rs:112:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -regex-1.3.2/src/compile.rs:112:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -regex-1.3.2/src/compile.rs:154:30 clippy::redundant_closure_for_method_calls "redundant closure found" -regex-1.3.2/src/compile.rs:156:30 clippy::redundant_closure_for_method_calls "redundant closure found" -regex-1.3.2/src/compile.rs:185:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -regex-1.3.2/src/compile.rs:187:40 clippy::redundant_closure_for_method_calls "redundant closure found" -regex-1.3.2/src/compile.rs:201:53 clippy::doc_markdown "you should put `MaybeInsts` between ticks in the documentation" -regex-1.3.2/src/compile.rs:241:63 clippy::doc_markdown "you should put `c_concat` between ticks in the documentation" -regex-1.3.2/src/compile.rs:245:5 clippy::too_many_lines "this function has too many lines (111/100)" -regex-1.3.2/src/compile.rs:247:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/compile.rs:373:24 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:373:36 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:378:12 clippy::if_not_else "unnecessary boolean `not` operation" -regex-1.3.2/src/compile.rs:400:37 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:407:51 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:409:24 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:417:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -regex-1.3.2/src/compile.rs:42:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/compile.rs:42:5 clippy::new_without_default "you should consider adding a `Default` implementation for `compile::Compiler`" -regex-1.3.2/src/compile.rs:444:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -regex-1.3.2/src/compile.rs:445:57 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:446:20 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:466:20 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:466:32 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:519:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/compile.rs:55:57 clippy::doc_markdown "you should put `size_limit` between ticks in the documentation" -regex-1.3.2/src/compile.rs:58:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/compile.rs:748:41 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:74:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/compile.rs:751:54 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:765:41 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:765:55 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:825:39 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:825:51 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:828:49 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:828:61 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:830:59 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:830:71 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:832:43 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:835:41 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:835:53 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:835:67 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:83:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/compile.rs:896:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -regex-1.3.2/src/compile.rs:905:17 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:953:17 clippy::doc_markdown "you should put `HashMap` between ticks in the documentation" -regex-1.3.2/src/compile.rs:95:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/compile.rs:980:26 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -regex-1.3.2/src/compile.rs:994:44 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:994:54 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/dfa.rs:1007:17 clippy::similar_names "binding's name is too similar to existing binding" -regex-1.3.2/src/dfa.rs:1010:22 clippy::similar_names "binding's name is too similar to existing binding" -regex-1.3.2/src/dfa.rs:1059:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/dfa.rs:1060:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/dfa.rs:1084:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex-1.3.2/src/dfa.rs:1087:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex-1.3.2/src/dfa.rs:1090:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex-1.3.2/src/dfa.rs:1093:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex-1.3.2/src/dfa.rs:1096:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex-1.3.2/src/dfa.rs:1101:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex-1.3.2/src/dfa.rs:1104:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex-1.3.2/src/dfa.rs:1107:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex-1.3.2/src/dfa.rs:1117:30 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex-1.3.2/src/dfa.rs:1120:47 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex-1.3.2/src/dfa.rs:1121:30 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex-1.3.2/src/dfa.rs:1129:13 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" -regex-1.3.2/src/dfa.rs:1134:13 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" -regex-1.3.2/src/dfa.rs:1185:68 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" -regex-1.3.2/src/dfa.rs:1193:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/dfa.rs:1244:50 clippy::doc_markdown "you should put `current_state` between ticks in the documentation" -regex-1.3.2/src/dfa.rs:1338:58 clippy::doc_markdown "you should put `STATE_DEAD` between ticks in the documentation" -regex-1.3.2/src/dfa.rs:1339:9 clippy::doc_markdown "you should put `STATE_UNKNOWN` between ticks in the documentation" -regex-1.3.2/src/dfa.rs:1366:25 clippy::doc_markdown "you should put `STATE_DEAD` between ticks in the documentation" -regex-1.3.2/src/dfa.rs:1366:46 clippy::doc_markdown "you should put `STATE_UNKNOWN` between ticks in the documentation" -regex-1.3.2/src/dfa.rs:1367:41 clippy::inline_always "you have declared `#[inline(always)]` on `start_state`. This is usually a bad idea" -regex-1.3.2/src/dfa.rs:1380:14 clippy::identity_op "the operation is ineffective. Consider reducing it to `(empty_flags.start as u8)`" -regex-1.3.2/src/dfa.rs:1388:15 clippy::match_on_vec_items "indexing into a vector may panic" -regex-1.3.2/src/dfa.rs:1412:20 clippy::unused_self "unused `self` argument" -regex-1.3.2/src/dfa.rs:1438:9 clippy::unused_self "unused `self` argument" -regex-1.3.2/src/dfa.rs:1472:9 clippy::doc_markdown "you should put `StatePtr` between ticks in the documentation" -regex-1.3.2/src/dfa.rs:1490:54 clippy::cast_possible_truncation "casting `i32` to `u8` may truncate the value" -regex-1.3.2/src/dfa.rs:1490:54 clippy::cast_sign_loss "casting `i32` to `u8` may lose the sign of the value" -regex-1.3.2/src/dfa.rs:1521:20 clippy::doc_markdown "you should put `num_byte_classes` between ticks in the documentation" -regex-1.3.2/src/dfa.rs:1529:41 clippy::inline_always "you have declared `#[inline(always)]` on `byte_class`. This is usually a bad idea" -regex-1.3.2/src/dfa.rs:1537:14 clippy::doc_markdown "you should put `byte_class` between ticks in the documentation" -regex-1.3.2/src/dfa.rs:1538:41 clippy::inline_always "you have declared `#[inline(always)]` on `u8_class`. This is usually a bad idea" -regex-1.3.2/src/dfa.rs:1562:18 clippy::doc_markdown "you should put `STATE_START` between ticks in the documentation" -regex-1.3.2/src/dfa.rs:1614:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/dfa.rs:1651:38 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/dfa.rs:1700:17 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -regex-1.3.2/src/dfa.rs:1701:18 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex-1.3.2/src/dfa.rs:1705:19 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex-1.3.2/src/dfa.rs:1708:16 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -regex-1.3.2/src/dfa.rs:1709:18 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex-1.3.2/src/dfa.rs:1713:19 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex-1.3.2/src/dfa.rs:1716:18 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -regex-1.3.2/src/dfa.rs:1717:18 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex-1.3.2/src/dfa.rs:1721:19 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex-1.3.2/src/dfa.rs:1727:14 clippy::cast_lossless "casting `u8` to `u16` may become silently lossy if you later change the type" -regex-1.3.2/src/dfa.rs:1732:15 clippy::trivially_copy_pass_by_ref "this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -regex-1.3.2/src/dfa.rs:1736:22 clippy::trivially_copy_pass_by_ref "this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -regex-1.3.2/src/dfa.rs:1741:9 clippy::match_like_matches_macro "match expression looks like `matches!` macro" -regex-1.3.2/src/dfa.rs:1747:16 clippy::trivially_copy_pass_by_ref "this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -regex-1.3.2/src/dfa.rs:1751:18 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" -regex-1.3.2/src/dfa.rs:1815:38 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" -regex-1.3.2/src/dfa.rs:1821:21 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" -regex-1.3.2/src/dfa.rs:1824:5 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex-1.3.2/src/dfa.rs:1848:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" -regex-1.3.2/src/dfa.rs:1850:18 clippy::cast_sign_loss "casting `i32` to `u32` may lose the sign of the value" -regex-1.3.2/src/dfa.rs:1857:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" -regex-1.3.2/src/dfa.rs:1860:17 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -regex-1.3.2/src/dfa.rs:1867:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" -regex-1.3.2/src/dfa.rs:1870:19 clippy::cast_possible_truncation "casting `u32` to `u8` may truncate the value" -regex-1.3.2/src/dfa.rs:1873:15 clippy::cast_possible_truncation "casting `u32` to `u8` may truncate the value" -regex-1.3.2/src/dfa.rs:1876:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" -regex-1.3.2/src/dfa.rs:1882:26 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" -regex-1.3.2/src/dfa.rs:1884:15 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" -regex-1.3.2/src/dfa.rs:277:17 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -regex-1.3.2/src/dfa.rs:277:31 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -regex-1.3.2/src/dfa.rs:295:20 clippy::cast_possible_truncation "casting `usize` to `i32` may truncate the value on targets with 64-bit wide pointers" -regex-1.3.2/src/dfa.rs:295:20 clippy::cast_possible_wrap "casting `usize` to `i32` may wrap around the value on targets with 32-bit wide pointers" -regex-1.3.2/src/dfa.rs:299:21 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" -regex-1.3.2/src/dfa.rs:34:46 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" -regex-1.3.2/src/dfa.rs:398:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -regex-1.3.2/src/dfa.rs:446:41 clippy::inline_always "you have declared `#[inline(always)]` on `forward`. This is usually a bad idea" -regex-1.3.2/src/dfa.rs:457:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/dfa.rs:459:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/dfa.rs:460:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/dfa.rs:476:41 clippy::inline_always "you have declared `#[inline(always)]` on `reverse`. This is usually a bad idea" -regex-1.3.2/src/dfa.rs:487:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/dfa.rs:489:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/dfa.rs:490:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/dfa.rs:506:41 clippy::inline_always "you have declared `#[inline(always)]` on `forward_many`. This is usually a bad idea" -regex-1.3.2/src/dfa.rs:518:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/dfa.rs:520:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/dfa.rs:554:41 clippy::inline_always "you have declared `#[inline(always)]` on `exec_at`. This is usually a bad idea" -regex-1.3.2/src/dfa.rs:555:5 clippy::too_many_lines "this function has too many lines (101/100)" -regex-1.3.2/src/dfa.rs:58:9 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/dfa.rs:667:21 clippy::similar_names "binding's name is too similar to existing binding" -regex-1.3.2/src/dfa.rs:747:41 clippy::inline_always "you have declared `#[inline(always)]` on `exec_at_reverse`. This is usually a bad idea" -regex-1.3.2/src/dfa.rs:795:21 clippy::similar_names "binding's name is too similar to existing binding" -regex-1.3.2/src/dfa.rs:848:9 clippy::doc_markdown "you should put `next_si` between ticks in the documentation" -regex-1.3.2/src/dfa.rs:852:41 clippy::inline_always "you have declared `#[inline(always)]` on `next_si`. This is usually a bad idea" -regex-1.3.2/src/dfa.rs:885:12 clippy::doc_markdown "you should put `STATE_DEAD` between ticks in the documentation" -regex-1.3.2/src/dfa.rs:889:9 clippy::doc_markdown "you should put `STATE_UNKNOWN` between ticks in the documentation" -regex-1.3.2/src/dfa.rs:897:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/dfa.rs:979:29 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex-1.3.2/src/error.rs:6:1 clippy::manual_non_exhaustive "this seems like a manual implementation of the non-exhaustive pattern" -regex-1.3.2/src/exec.rs:1000:14 clippy::doc_markdown "you should put `captures_nfa` between ticks in the documentation" -regex-1.3.2/src/exec.rs:100:1 clippy::module_name_repetitions "item name starts with its containing module's name" -regex-1.3.2/src/exec.rs:1028:5 clippy::too_many_arguments "this function has too many arguments (9/7)" -regex-1.3.2/src/exec.rs:1039:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/exec.rs:1144:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/exec.rs:1179:26 clippy::match_same_arms "this `match` has identical arm bodies" -regex-1.3.2/src/exec.rs:122:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/exec.rs:1250:41 clippy::inline_always "you have declared `#[inline(always)]` on `searcher`. This is usually a bad idea" -regex-1.3.2/src/exec.rs:1260:41 clippy::inline_always "you have declared `#[inline(always)]` on `searcher_str`. This is usually a bad idea" -regex-1.3.2/src/exec.rs:1270:17 clippy::doc_markdown "you should put `RegexSet` between ticks in the documentation" -regex-1.3.2/src/exec.rs:1280:17 clippy::doc_markdown "you should put `RegexSet` between ticks in the documentation" -regex-1.3.2/src/exec.rs:137:9 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" -regex-1.3.2/src/exec.rs:142:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/exec.rs:1493:5 clippy::upper_case_acronyms "name `PikeVM` contains a capitalized acronym" -regex-1.3.2/src/exec.rs:158:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/exec.rs:168:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/exec.rs:181:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/exec.rs:195:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/exec.rs:204:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/exec.rs:210:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/exec.rs:245:62 clippy::if_same_then_else "this `if` has identical blocks" -regex-1.3.2/src/exec.rs:251:21 clippy::if_not_else "unnecessary boolean `not` operation" -regex-1.3.2/src/exec.rs:262:60 clippy::if_same_then_else "this `if` has identical blocks" -regex-1.3.2/src/exec.rs:268:21 clippy::if_not_else "unnecessary boolean `not` operation" -regex-1.3.2/src/exec.rs:278:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/exec.rs:281:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/exec.rs:286:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -regex-1.3.2/src/exec.rs:300:30 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/exec.rs:308:17 clippy::similar_names "binding's name is too similar to existing binding" -regex-1.3.2/src/exec.rs:329:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/exec.rs:330:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/exec.rs:331:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/exec.rs:334:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/exec.rs:340:19 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/exec.rs:344:27 clippy::unused_self "unused `self` argument" -regex-1.3.2/src/exec.rs:383:41 clippy::inline_always "you have declared `#[inline(always)]` on `shortest_match_at`. This is usually a bad idea" -regex-1.3.2/src/exec.rs:388:41 clippy::inline_always "you have declared `#[inline(always)]` on `is_match_at`. This is usually a bad idea" -regex-1.3.2/src/exec.rs:393:41 clippy::inline_always "you have declared `#[inline(always)]` on `find_at`. This is usually a bad idea" -regex-1.3.2/src/exec.rs:398:41 clippy::inline_always "you have declared `#[inline(always)]` on `captures_read_at`. This is usually a bad idea" -regex-1.3.2/src/exec.rs:425:41 clippy::inline_always "you have declared `#[inline(always)]` on `shortest_match_at`. This is usually a bad idea" -regex-1.3.2/src/exec.rs:44:1 clippy::module_name_repetitions "item name starts with its containing module's name" -regex-1.3.2/src/exec.rs:473:9 clippy::doc_markdown "you should put `shortest_match(...).is_some` between ticks in the documentation" -regex-1.3.2/src/exec.rs:474:41 clippy::inline_always "you have declared `#[inline(always)]` on `is_match_at`. This is usually a bad idea" -regex-1.3.2/src/exec.rs:524:41 clippy::inline_always "you have declared `#[inline(always)]` on `find_at`. This is usually a bad idea" -regex-1.3.2/src/exec.rs:52:1 clippy::module_name_repetitions "item name starts with its containing module's name" -regex-1.3.2/src/exec.rs:686:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/exec.rs:727:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/exec.rs:767:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/exec.rs:783:41 clippy::inline_always "you have declared `#[inline(always)]` on `shortest_dfa`. This is usually a bad idea" -regex-1.3.2/src/exec.rs:791:41 clippy::inline_always "you have declared `#[inline(always)]` on `shortest_dfa_reverse_suffix`. This is usually a bad idea" -regex-1.3.2/src/exec.rs:823:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/exec.rs:868:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/exec.rs:897:31 clippy::doc_markdown "you should put `shortest_nfa(...).is_some` between ticks in the documentation" -regex-1.3.2/src/exec.rs:899:9 clippy::doc_markdown "you should put `shortest_nfa` between ticks in the documentation" -regex-1.3.2/src/exec.rs:905:14 clippy::doc_markdown "you should put `match_nfa` between ticks in the documentation" -regex-1.3.2/src/exec.rs:930:14 clippy::doc_markdown "you should put `shortest_nfa` between ticks in the documentation" -regex-1.3.2/src/exec.rs:981:14 clippy::doc_markdown "you should put `find_nfa` between ticks in the documentation" -regex-1.3.2/src/expand.rs:170:27 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -regex-1.3.2/src/expand.rs:171:5 clippy::match_like_matches_macro "match expression looks like `matches!` macro" -regex-1.3.2/src/expand.rs:22:13 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -regex-1.3.2/src/expand.rs:27:23 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -regex-1.3.2/src/expand.rs:30:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -regex-1.3.2/src/expand.rs:38:30 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" -regex-1.3.2/src/expand.rs:42:21 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" -regex-1.3.2/src/expand.rs:50:1 clippy::module_name_repetitions "item name starts with its containing module's name" -regex-1.3.2/src/expand.rs:69:23 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -regex-1.3.2/src/expand.rs:80:28 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" -regex-1.3.2/src/expand.rs:84:21 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" -regex-1.3.2/src/expand.rs:8:1 clippy::module_name_repetitions "item name starts with its containing module's name" -regex-1.3.2/src/input.rs:142:1 clippy::module_name_repetitions "item name ends with its containing module's name" -regex-1.3.2/src/input.rs:146:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/input.rs:15:1 clippy::module_name_repetitions "item name starts with its containing module's name" -regex-1.3.2/src/input.rs:165:31 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/input.rs:178:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/input.rs:228:1 clippy::module_name_repetitions "item name ends with its containing module's name" -regex-1.3.2/src/input.rs:236:21 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/input.rs:236:33 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/input.rs:24:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/input.rs:271:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/input.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/input.rs:362:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/input.rs:370:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/input.rs:371:42 clippy::redundant_closure_for_method_calls "redundant closure found" -regex-1.3.2/src/input.rs:37:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/input.rs:388:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/input.rs:42:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/input.rs:47:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/input.rs:53:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/input.rs:58:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/input.rs:63:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/lib.rs:1:null clippy::cargo_common_metadata "package `regex` is missing `package.keywords` metadata" -regex-1.3.2/src/literal/imp.rs:101:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/literal/imp.rs:114:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/literal/imp.rs:127:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/literal/imp.rs:139:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/literal/imp.rs:144:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/literal/imp.rs:149:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/literal/imp.rs:154:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/literal/imp.rs:155:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/literal/imp.rs:160:30 clippy::match_same_arms "this `match` has identical arm bodies" -regex-1.3.2/src/literal/imp.rs:167:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/literal/imp.rs:168:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/literal/imp.rs:211:20 clippy::redundant_else "redundant else block" -regex-1.3.2/src/literal/imp.rs:239:5 clippy::upper_case_acronyms "name `AC` contains a capitalized acronym" -regex-1.3.2/src/literal/imp.rs:276:50 clippy::match_same_arms "this `match` has identical arm bodies" -regex-1.3.2/src/literal/imp.rs:342:41 clippy::inline_always "you have declared `#[inline(always)]` on `find`. This is usually a bad idea" -regex-1.3.2/src/literal/imp.rs:34:5 clippy::upper_case_acronyms "name `AC` contains a capitalized acronym" -regex-1.3.2/src/literal/imp.rs:435:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/literal/imp.rs:436:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/literal/imp.rs:437:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/literal/imp.rs:438:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/literal/imp.rs:439:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/literal/imp.rs:440:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/literal/imp.rs:455:41 clippy::inline_always "you have declared `#[inline(always)]` on `find`. This is usually a bad idea" -regex-1.3.2/src/literal/imp.rs:46:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/literal/imp.rs:481:41 clippy::inline_always "you have declared `#[inline(always)]` on `is_suffix`. This is usually a bad idea" -regex-1.3.2/src/literal/imp.rs:51:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/literal/imp.rs:579:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/literal/imp.rs:57:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/literal/imp.rs:580:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/literal/imp.rs:583:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/literal/imp.rs:602:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -regex-1.3.2/src/literal/imp.rs:622:24 clippy::redundant_else "redundant else block" -regex-1.3.2/src/literal/imp.rs:62:18 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -regex-1.3.2/src/literal/imp.rs:637:24 clippy::redundant_else "redundant else block" -regex-1.3.2/src/literal/imp.rs:648:9 clippy::needless_return "unneeded `return` statement" -regex-1.3.2/src/literal/imp.rs:651:44 clippy::doc_markdown "you should put `BoyerMooreSearch` between ticks in the documentation" -regex-1.3.2/src/literal/imp.rs:65:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/literal/imp.rs:68:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/literal/imp.rs:783:32 clippy::redundant_else "redundant else block" -regex-1.3.2/src/literal/imp.rs:786:42 clippy::manual_saturating_arithmetic "manual saturating arithmetic" -regex-1.3.2/src/literal/imp.rs:78:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/literal/imp.rs:84:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/literal/imp.rs:850:20 clippy::unreadable_literal "long literal lacking separators" -regex-1.3.2/src/literal/imp.rs:85:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/pikevm.rs:103:15 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/pikevm.rs:103:52 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/pikevm.rs:114:5 clippy::too_many_arguments "this function has too many arguments (8/7)" -regex-1.3.2/src/pikevm.rs:117:13 clippy::similar_names "binding's name is too similar to existing binding" -regex-1.3.2/src/pikevm.rs:124:17 clippy::similar_names "binding's name is too similar to existing binding" -regex-1.3.2/src/pikevm.rs:220:9 clippy::doc_markdown "you should put `thread_caps` between ticks in the documentation" -regex-1.3.2/src/pikevm.rs:222:16 clippy::doc_markdown "you should put `at_next` between ticks in the documentation" -regex-1.3.2/src/pikevm.rs:223:9 clippy::doc_markdown "you should put `at_next` between ticks in the documentation" -regex-1.3.2/src/pikevm.rs:224:5 clippy::too_many_arguments "this function has too many arguments (8/7)" -regex-1.3.2/src/pikevm.rs:234:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/pikevm.rs:303:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/pikevm.rs:331:29 clippy::mut_mut "this expression mutably borrows a mutable reference. Consider reborrowing" -regex-1.3.2/src/pikevm.rs:70:5 clippy::upper_case_acronyms "name `IP` contains a capitalized acronym" -regex-1.3.2/src/pikevm.rs:88:5 clippy::too_many_arguments "this function has too many arguments (8/7)" -regex-1.3.2/src/prog.rs:102:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/prog.rs:113:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/prog.rs:120:9 clippy::match_like_matches_macro "match expression looks like `matches!` macro" -regex-1.3.2/src/prog.rs:128:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/prog.rs:134:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/prog.rs:141:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/prog.rs:147:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/prog.rs:164:41 clippy::inline_always "you have declared `#[inline(always)]` on `deref`. This is usually a bad idea" -regex-1.3.2/src/prog.rs:172:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/prog.rs:18:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -regex-1.3.2/src/prog.rs:236:13 clippy::write_with_newline "using `write!()` with a format string that ends in a single newline" -regex-1.3.2/src/prog.rs:300:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/prog.rs:301:9 clippy::match_like_matches_macro "match expression looks like `matches!` macro" -regex-1.3.2/src/prog.rs:382:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/prog.rs:409:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/prog.rs:80:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/prog.rs:80:5 clippy::new_without_default "you should consider adding a `Default` implementation for `prog::Program`" -regex-1.3.2/src/re_builder.rs:267:17 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -regex-1.3.2/src/re_builder.rs:267:17 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -regex-1.3.2/src/re_builder.rs:4:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -regex-1.3.2/src/re_builder.rs:57:17 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_builder.rs:57:17 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_builder.rs:68:17 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -regex-1.3.2/src/re_builder.rs:68:17 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -regex-1.3.2/src/re_bytes.rs:1017:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" -regex-1.3.2/src/re_bytes.rs:1039:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" -regex-1.3.2/src/re_bytes.rs:1093:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -regex-1.3.2/src/re_bytes.rs:1118:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -regex-1.3.2/src/re_bytes.rs:1133:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -regex-1.3.2/src/re_bytes.rs:118:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -regex-1.3.2/src/re_bytes.rs:256:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/re_bytes.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_bytes.rs:35:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_bytes.rs:42:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_bytes.rs:483:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -regex-1.3.2/src/re_bytes.rs:48:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_bytes.rs:558:29 clippy::doc_markdown "you should put `shortest_match` between ticks in the documentation" -regex-1.3.2/src/re_bytes.rs:55:33 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/re_bytes.rs:55:47 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/re_bytes.rs:572:29 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" -regex-1.3.2/src/re_bytes.rs:720:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/re_bytes.rs:817:5 clippy::doc_markdown "you should put `CaptureLocations` between ticks in the documentation" -regex-1.3.2/src/re_bytes.rs:843:1 clippy::len_without_is_empty "item `re_bytes::CaptureLocations` has a public `len` method but no corresponding `is_empty` method" -regex-1.3.2/src/re_bytes.rs:849:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_bytes.rs:858:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_bytes.rs:869:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_bytes.rs:891:1 clippy::len_without_is_empty "item `re_bytes::Captures<'t>` has a public `len` method but no corresponding `is_empty` method" -regex-1.3.2/src/re_bytes.rs:911:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_bytes.rs:917:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_bytes.rs:926:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_bytes.rs:955:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_set.rs:179:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/re_set.rs:179:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/re_set.rs:251:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_set.rs:251:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_set.rs:263:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_set.rs:263:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_set.rs:268:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_set.rs:268:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_set.rs:277:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_set.rs:277:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_set.rs:94:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -regex-1.3.2/src/re_set.rs:94:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -regex-1.3.2/src/re_trait.rs:136:29 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/re_unicode.rs:1019:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" -regex-1.3.2/src/re_unicode.rs:1041:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" -regex-1.3.2/src/re_unicode.rs:1088:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/re_unicode.rs:1135:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -regex-1.3.2/src/re_unicode.rs:1160:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -regex-1.3.2/src/re_unicode.rs:174:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -regex-1.3.2/src/re_unicode.rs:21:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -regex-1.3.2/src/re_unicode.rs:313:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/re_unicode.rs:38:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_unicode.rs:44:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_unicode.rs:51:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_unicode.rs:533:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -regex-1.3.2/src/re_unicode.rs:57:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_unicode.rs:617:29 clippy::doc_markdown "you should put `shortest_match` between ticks in the documentation" -regex-1.3.2/src/re_unicode.rs:631:29 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" -regex-1.3.2/src/re_unicode.rs:64:33 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/re_unicode.rs:64:47 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/re_unicode.rs:834:5 clippy::doc_markdown "you should put `CaptureLocations` between ticks in the documentation" -regex-1.3.2/src/re_unicode.rs:860:1 clippy::len_without_is_empty "item `re_unicode::CaptureLocations` has a public `len` method but no corresponding `is_empty` method" -regex-1.3.2/src/re_unicode.rs:866:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_unicode.rs:875:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_unicode.rs:886:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_unicode.rs:908:1 clippy::len_without_is_empty "item `re_unicode::Captures<'t>` has a public `len` method but no corresponding `is_empty` method" -regex-1.3.2/src/re_unicode.rs:928:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_unicode.rs:934:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_unicode.rs:943:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_unicode.rs:972:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/sparse.rs:10:37 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" -regex-1.3.2/src/sparse.rs:15:1 clippy::module_name_repetitions "item name starts with its containing module's name" -regex-1.3.2/src/utf8.rs:100:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex-1.3.2/src/utf8.rs:103:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex-1.3.2/src/utf8.rs:106:22 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" -regex-1.3.2/src/utf8.rs:107:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" -regex-1.3.2/src/utf8.rs:108:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" -regex-1.3.2/src/utf8.rs:109:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" -regex-1.3.2/src/utf8.rs:111:27 clippy::unreadable_literal "long literal lacking separators" -regex-1.3.2/src/utf8.rs:121:1 clippy::module_name_repetitions "item name ends with its containing module's name" -regex-1.3.2/src/utf8.rs:143:24 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex-1.3.2/src/utf8.rs:143:9 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex-1.3.2/src/utf8.rs:23:1 clippy::module_name_repetitions "item name ends with its containing module's name" -regex-1.3.2/src/utf8.rs:30:20 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex-1.3.2/src/utf8.rs:51:1 clippy::module_name_repetitions "item name ends with its containing module's name" -regex-1.3.2/src/utf8.rs:58:23 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex-1.3.2/src/utf8.rs:58:9 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex-1.3.2/src/utf8.rs:63:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex-1.3.2/src/utf8.rs:66:22 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" -regex-1.3.2/src/utf8.rs:66:54 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" -regex-1.3.2/src/utf8.rs:77:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex-1.3.2/src/utf8.rs:80:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex-1.3.2/src/utf8.rs:83:22 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" -regex-1.3.2/src/utf8.rs:84:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" -regex-1.3.2/src/utf8.rs:85:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" -regex-1.3.2/src/utf8.rs:92:23 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex-1.3.2/src/utf8.rs:92:9 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex-1.3.2/src/utf8.rs:97:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -ripgrep-12.1.1//home/matthias/.rustup/toolchains/nightly-2021-02-03-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std/src/panic.rs:30:27 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep-12.1.1//home/matthias/.rustup/toolchains/nightly-2021-02-03-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std/src/panic.rs:30:27 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep-12.1.1//home/matthias/.rustup/toolchains/nightly-2021-02-03-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std/src/panic.rs:30:27 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep-12.1.1//home/matthias/.rustup/toolchains/nightly-2021-02-03-x86_64-unknown-linux-gnu/lib/rustlib/src/rust/library/std/src/panic.rs:30:27 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep-12.1.1/build.rs:133:19 clippy::option_as_ref_deref "called `.as_ref().map(|x| &**x)` on an Option value. This can be done more directly by calling `githash.as_deref()` instead" -ripgrep-12.1.1/build.rs:18:18 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -ripgrep-12.1.1/build.rs:225:14 clippy::redundant_closure_for_method_calls "redundant closure found" -ripgrep-12.1.1/build.rs:92:19 clippy::option_as_ref_deref "called `.as_ref().map(|x| &**x)` on an Option value. This can be done more directly by calling `githash.as_deref()` instead" -ripgrep-12.1.1/crates/core/app.rs:1408:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep-12.1.1/crates/core/app.rs:1408:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep-12.1.1/crates/core/app.rs:1409:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep-12.1.1/crates/core/app.rs:1409:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep-12.1.1/crates/core/app.rs:152:32 clippy::doc_markdown "you should put `clap::Arg` between ticks in the documentation" -ripgrep-12.1.1/crates/core/app.rs:152:32 clippy::doc_markdown "you should put `clap::Arg` between ticks in the documentation" -ripgrep-12.1.1/crates/core/app.rs:156:39 clippy::doc_markdown "you should put `clap::Arg` between ticks in the documentation" -ripgrep-12.1.1/crates/core/app.rs:156:39 clippy::doc_markdown "you should put `clap::Arg` between ticks in the documentation" -ripgrep-12.1.1/crates/core/app.rs:156:5 clippy::doc_markdown "you should put `RGArg` between ticks in the documentation" -ripgrep-12.1.1/crates/core/app.rs:156:5 clippy::doc_markdown "you should put `RGArg` between ticks in the documentation" -ripgrep-12.1.1/crates/core/app.rs:164:12 clippy::upper_case_acronyms "name `RGArg` contains a capitalized acronym" -ripgrep-12.1.1/crates/core/app.rs:164:12 clippy::upper_case_acronyms "name `RGArg` contains a capitalized acronym" -ripgrep-12.1.1/crates/core/app.rs:1668:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep-12.1.1/crates/core/app.rs:1668:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep-12.1.1/crates/core/app.rs:1669:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep-12.1.1/crates/core/app.rs:1669:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep-12.1.1/crates/core/app.rs:1821:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep-12.1.1/crates/core/app.rs:1821:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep-12.1.1/crates/core/app.rs:1822:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep-12.1.1/crates/core/app.rs:1822:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep-12.1.1/crates/core/app.rs:212:10 clippy::upper_case_acronyms "name `RGArgKind` contains a capitalized acronym" -ripgrep-12.1.1/crates/core/app.rs:212:10 clippy::upper_case_acronyms "name `RGArgKind` contains a capitalized acronym" -ripgrep-12.1.1/crates/core/app.rs:2999:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep-12.1.1/crates/core/app.rs:2999:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep-12.1.1/crates/core/app.rs:3000:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep-12.1.1/crates/core/app.rs:3000:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep-12.1.1/crates/core/app.rs:367:54 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep-12.1.1/crates/core/app.rs:367:54 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep-12.1.1/crates/core/app.rs:414:59 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep-12.1.1/crates/core/app.rs:414:59 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep-12.1.1/crates/core/app.rs:417:57 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep-12.1.1/crates/core/app.rs:417:57 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep-12.1.1/crates/core/app.rs:417:57 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep-12.1.1/crates/core/app.rs:417:57 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep-12.1.1/crates/core/app.rs:75:9 clippy::doc_markdown "you should put `RIPGREP_BUILD_GIT_HASH` between ticks in the documentation" -ripgrep-12.1.1/crates/core/app.rs:75:9 clippy::doc_markdown "you should put `RIPGREP_BUILD_GIT_HASH` between ticks in the documentation" -ripgrep-12.1.1/crates/core/app.rs:87:5 clippy::if_not_else "unnecessary boolean `not` operation" -ripgrep-12.1.1/crates/core/app.rs:87:5 clippy::if_not_else "unnecessary boolean `not` operation" -ripgrep-12.1.1/crates/core/args.rs:1143:22 clippy::unused_self "unused `self` argument" -ripgrep-12.1.1/crates/core/args.rs:11:1 clippy::single_component_path_imports "this import is redundant" -ripgrep-12.1.1/crates/core/args.rs:1209:74 clippy::if_same_then_else "this `if` has identical blocks" -ripgrep-12.1.1/crates/core/args.rs:1282:13 clippy::similar_names "binding's name is too similar to existing binding" -ripgrep-12.1.1/crates/core/args.rs:1430:22 clippy::unused_self "unused `self` argument" -ripgrep-12.1.1/crates/core/args.rs:1438:21 clippy::doc_markdown "you should put `OsStr` between ticks in the documentation" -ripgrep-12.1.1/crates/core/args.rs:1520:44 clippy::redundant_closure_for_method_calls "redundant closure found" -ripgrep-12.1.1/crates/core/args.rs:1524:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -ripgrep-12.1.1/crates/core/args.rs:1635:14 clippy::doc_markdown "you should put `values_of_lossy` between ticks in the documentation" -ripgrep-12.1.1/crates/core/args.rs:1693:41 clippy::redundant_closure_for_method_calls "redundant closure found" -ripgrep-12.1.1/crates/core/args.rs:1770:17 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -ripgrep-12.1.1/crates/core/args.rs:287:13 clippy::similar_names "binding's name is too similar to existing binding" -ripgrep-12.1.1/crates/core/args.rs:33:1 clippy::single_component_path_imports "this import is redundant" -ripgrep-12.1.1/crates/core/args.rs:34:1 clippy::single_component_path_imports "this import is redundant" -ripgrep-12.1.1/crates/core/args.rs:35:1 clippy::single_component_path_imports "this import is redundant" -ripgrep-12.1.1/crates/core/args.rs:369:5 clippy::upper_case_acronyms "name `JSON` contains a capitalized acronym" -ripgrep-12.1.1/crates/core/args.rs:410:14 clippy::trivially_copy_pass_by_ref "this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -ripgrep-12.1.1/crates/core/args.rs:475:18 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep-12.1.1/crates/core/args.rs:512:19 clippy::doc_markdown "you should put `ArgMatches` between ticks in the documentation" -ripgrep-12.1.1/crates/core/args.rs:549:16 clippy::wrong_self_convention "methods called `to_*` usually take self by reference; consider choosing a less ambiguous name" -ripgrep-12.1.1/crates/core/args.rs:71:5 clippy::upper_case_acronyms "name `PCRE2Version` contains a capitalized acronym" -ripgrep-12.1.1/crates/core/args.rs:76:18 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -ripgrep-12.1.1/crates/core/args.rs:77:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -ripgrep-12.1.1/crates/core/args.rs:923:42 clippy::doc_markdown "you should put `BinaryDetection::quit` between ticks in the documentation" -ripgrep-12.1.1/crates/core/config.rs:13:1 clippy::single_component_path_imports "this import is redundant" -ripgrep-12.1.1/crates/core/config.rs:58:6 clippy::type_complexity "very complex type used. Consider factoring parts into `type` definitions" -ripgrep-12.1.1/crates/core/config.rs:79:6 clippy::type_complexity "very complex type used. Consider factoring parts into `type` definitions" -ripgrep-12.1.1/crates/core/logger.rs:11:30 clippy::doc_markdown "you should put `max_level` between ticks in the documentation" -ripgrep-12.1.1/crates/core/logger.rs:15:16 clippy::redundant_static_lifetimes "constants have by default a `'static` lifetime" -ripgrep-12.1.1/crates/core/main.rs:55:19 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -ripgrep-12.1.1/crates/core/main.rs:56:9 clippy::enum_glob_use "usage of wildcard import for enum variants" -ripgrep-12.1.1/crates/core/messages.rs:46:1 clippy::module_name_repetitions "item name ends with its containing module's name" -ripgrep-12.1.1/crates/core/messages.rs:51:1 clippy::module_name_repetitions "item name ends with its containing module's name" -ripgrep-12.1.1/crates/core/messages.rs:62:1 clippy::module_name_repetitions "item name ends with its containing module's name" -ripgrep-12.1.1/crates/core/path_printer.rs:27:1 clippy::module_name_repetitions "item name starts with its containing module's name" -ripgrep-12.1.1/crates/core/path_printer.rs:89:9 clippy::if_not_else "unnecessary boolean `not` operation" -ripgrep-12.1.1/crates/core/search.rs:185:1 clippy::module_name_repetitions "item name starts with its containing module's name" -ripgrep-12.1.1/crates/core/search.rs:224:5 clippy::upper_case_acronyms "name `JSON` contains a capitalized acronym" -ripgrep-12.1.1/crates/core/search.rs:292:9 clippy::write_with_newline "using `write!()` with a format string that ends in a single newline" -ripgrep-12.1.1/crates/core/search.rs:311:1 clippy::module_name_repetitions "item name starts with its containing module's name" -ripgrep-12.1.1/crates/core/search.rs:377:12 clippy::nonminimal_bool "this boolean expression can be simplified" -ripgrep-12.1.1/crates/core/search.rs:423:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -ripgrep-12.1.1/crates/core/search.rs:447:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -ripgrep-12.1.1/crates/core/search.rs:472:24 clippy::map_clone "you are using an explicit closure for cloning elements" -ripgrep-12.1.1/crates/core/search.rs:472:41 clippy::redundant_closure_for_method_calls "redundant closure found" -ripgrep-12.1.1/crates/core/search.rs:480:24 clippy::map_clone "you are using an explicit closure for cloning elements" -ripgrep-12.1.1/crates/core/search.rs:480:41 clippy::redundant_closure_for_method_calls "redundant closure found" -ripgrep-12.1.1/crates/core/search.rs:49:1 clippy::module_name_repetitions "item name starts with its containing module's name" -ripgrep-12.1.1/crates/core/search.rs:509:24 clippy::map_clone "you are using an explicit closure for cloning elements" -ripgrep-12.1.1/crates/core/search.rs:509:41 clippy::redundant_closure_for_method_calls "redundant closure found" -ripgrep-12.1.1/crates/core/search.rs:517:24 clippy::map_clone "you are using an explicit closure for cloning elements" -ripgrep-12.1.1/crates/core/search.rs:517:41 clippy::redundant_closure_for_method_calls "redundant closure found" -ripgrep-12.1.1/crates/core/search.rs:533:36 clippy::cast_lossless "casting `u32` to `f64` may become silently lossy if you later change the type" -ripgrep-12.1.1/crates/core/search.rs:533:5 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -ripgrep-12.1.1/crates/core/subject.rs:20:1 clippy::module_name_repetitions "item name starts with its containing module's name" -ripgrep-12.1.1/crates/core/subject.rs:4:1 clippy::single_component_path_imports "this import is redundant" -syn-1.0.54/build.rs:1:null clippy::cargo_common_metadata "package `syn` is missing `package.keywords` metadata" -syn-1.0.54/build.rs:1:null clippy::multiple_crate_versions "could not read cargo metadata: `cargo metadata` exited with an error: Downloading crates ...\n Downloaded syn-test-suite v0.0.0\nerror: failed to verify the checksum of `syn-test-suite v0.0.0`" -syn-1.0.54/src/generics.rs:174:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -syn-1.0.54/src/lib.rs:1:null clippy::cargo_common_metadata "package `syn` is missing `package.keywords` metadata" -syn-1.0.54/src/lib.rs:1:null clippy::multiple_crate_versions "could not read cargo metadata: `cargo metadata` exited with an error: Downloading crates ...\n Downloaded syn-test-suite v0.0.0\nerror: failed to verify the checksum of `syn-test-suite v0.0.0`" -syn-1.0.54/src/lit.rs:1397:40 clippy::redundant_else "redundant else block" -syn-1.0.54/src/lit.rs:1405:28 clippy::redundant_else "redundant else block" -syn-1.0.54/src/lit.rs:1485:32 clippy::redundant_else "redundant else block" -syn-1.0.54/src/lit.rs:343:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -syn-1.0.54/src/lit.rs:437:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -syn-1.0.54/src/lit.rs:916:9 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -syn-1.0.54/src/token.rs:974:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -syn-1.0.54/src/token.rs:996:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -unicode-xid-0.2.1/src/lib.rs:1:null clippy::cargo_common_metadata "package `unicode-xid` is missing `package.categories` metadata" -unicode-xid-0.2.1/src/lib.rs:56:11 clippy::upper_case_acronyms "name `UnicodeXID` contains a capitalized acronym" -unicode-xid-0.2.1/src/lib.rs:57:64 clippy::doc_markdown "you should put `XID_Start` between ticks in the documentation" -unicode-xid-0.2.1/src/lib.rs:60:10 clippy::doc_markdown "you should put `XID_Start` between ticks in the documentation" -unicode-xid-0.2.1/src/lib.rs:62:27 clippy::doc_markdown "you should put `ID_Start` between ticks in the documentation" -unicode-xid-0.2.1/src/lib.rs:62:67 clippy::doc_markdown "you should put `NFKx` between ticks in the documentation" -unicode-xid-0.2.1/src/lib.rs:63:21 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" -unicode-xid-0.2.1/src/lib.rs:65:61 clippy::doc_markdown "you should put `XID_Continue` between ticks in the documentation" -unicode-xid-0.2.1/src/lib.rs:68:10 clippy::doc_markdown "you should put `XID_Continue` between ticks in the documentation" -unicode-xid-0.2.1/src/lib.rs:70:28 clippy::doc_markdown "you should put `ID_Continue` between ticks in the documentation" -unicode-xid-0.2.1/src/lib.rs:70:72 clippy::doc_markdown "you should put `NFKx` between ticks in the documentation" -unicode-xid-0.2.1/src/lib.rs:71:24 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" -xsv-0.13.0/src/cmd/cat.rs:101:34 clippy::redundant_closure_for_method_calls "redundant closure found" -xsv-0.13.0/src/cmd/cat.rs:42:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -xsv-0.13.0/src/cmd/cat.rs:53:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/cat.rs:7:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv-0.13.0/src/cmd/count.rs:32:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/count.rs:38:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -xsv-0.13.0/src/cmd/count.rs:42:33 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -xsv-0.13.0/src/cmd/count.rs:50:5 clippy::unit_arg "passing a unit value to a function" -xsv-0.13.0/src/cmd/count.rs:7:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv-0.13.0/src/cmd/fixlengths.rs:45:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/fixlengths.rs:50:18 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -xsv-0.13.0/src/cmd/fixlengths.rs:62:30 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -xsv-0.13.0/src/cmd/fixlengths.rs:9:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv-0.13.0/src/cmd/flatten.rs:10:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv-0.13.0/src/cmd/flatten.rs:51:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/fmt.rs:50:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/fmt.rs:55:13 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/fmt.rs:7:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv-0.13.0/src/cmd/frequency.rs:148:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -xsv-0.13.0/src/cmd/frequency.rs:149:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -xsv-0.13.0/src/cmd/frequency.rs:15:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv-0.13.0/src/cmd/frequency.rs:169:13 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/frequency.rs:176:17 clippy::if_not_else "unnecessary boolean `not` operation" -xsv-0.13.0/src/cmd/frequency.rs:178:24 clippy::collapsible_else_if "this `else { if .. }` block can be collapsed" -xsv-0.13.0/src/cmd/frequency.rs:77:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/frequency.rs:93:31 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" -xsv-0.13.0/src/cmd/headers.rs:43:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/headers.rs:49:17 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" -xsv-0.13.0/src/cmd/headers.rs:9:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv-0.13.0/src/cmd/index.rs:11:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv-0.13.0/src/cmd/index.rs:45:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/input.rs:42:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/input.rs:47:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/input.rs:7:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv-0.13.0/src/cmd/join.rs:17:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv-0.13.0/src/cmd/join.rs:194:29 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/join.rs:224:22 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/join.rs:293:14 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/join.rs:293:20 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/join.rs:297:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv-0.13.0/src/cmd/join.rs:298:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv-0.13.0/src/cmd/join.rs:299:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv-0.13.0/src/cmd/join.rs:300:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv-0.13.0/src/cmd/join.rs:308:9 clippy::unused_self "unused `self` argument" -xsv-0.13.0/src/cmd/join.rs:342:38 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -xsv-0.13.0/src/cmd/join.rs:342:46 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -xsv-0.13.0/src/cmd/join.rs:347:9 clippy::if_not_else "unnecessary boolean `not` operation" -xsv-0.13.0/src/cmd/join.rs:372:44 clippy::redundant_closure_for_method_calls "redundant closure found" -xsv-0.13.0/src/cmd/join.rs:375:33 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/join.rs:392:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv-0.13.0/src/cmd/join.rs:403:29 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" -xsv-0.13.0/src/cmd/join.rs:426:13 clippy::if_not_else "unnecessary boolean `not` operation" -xsv-0.13.0/src/cmd/join.rs:77:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -xsv-0.13.0/src/cmd/join.rs:94:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/partition.rs:105:22 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/partition.rs:106:22 clippy::redundant_slicing "redundant slicing of the whole range" -xsv-0.13.0/src/cmd/partition.rs:139:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv-0.13.0/src/cmd/partition.rs:15:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv-0.13.0/src/cmd/partition.rs:169:9 clippy::if_not_else "unnecessary boolean `not` operation" -xsv-0.13.0/src/cmd/partition.rs:56:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/partition.rs:77:9 clippy::unused_self "unused `self` argument" -xsv-0.13.0/src/cmd/sample.rs:105:44 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -xsv-0.13.0/src/cmd/sample.rs:115:21 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -xsv-0.13.0/src/cmd/sample.rs:11:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv-0.13.0/src/cmd/sample.rs:51:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/sample.rs:58:19 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -xsv-0.13.0/src/cmd/sample.rs:69:9 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" -xsv-0.13.0/src/cmd/sample.rs:75:16 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" -xsv-0.13.0/src/cmd/sample.rs:91:42 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -xsv-0.13.0/src/cmd/sample.rs:92:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -xsv-0.13.0/src/cmd/search.rs:51:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/search.rs:9:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv-0.13.0/src/cmd/select.rs:60:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/select.rs:8:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv-0.13.0/src/cmd/slice.rs:57:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/slice.rs:9:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv-0.13.0/src/cmd/sort.rs:11:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv-0.13.0/src/cmd/sort.rs:138:47 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -xsv-0.13.0/src/cmd/sort.rs:139:51 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -xsv-0.13.0/src/cmd/sort.rs:48:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/sort.rs:91:14 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" -xsv-0.13.0/src/cmd/split.rs:14:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv-0.13.0/src/cmd/split.rs:61:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/split.rs:94:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -xsv-0.13.0/src/cmd/split.rs:96:14 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -xsv-0.13.0/src/cmd/split.rs:99:13 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -xsv-0.13.0/src/cmd/stats.rs:110:36 clippy::redundant_closure_for_method_calls "redundant closure found" -xsv-0.13.0/src/cmd/stats.rs:127:14 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -xsv-0.13.0/src/cmd/stats.rs:138:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -xsv-0.13.0/src/cmd/stats.rs:139:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -xsv-0.13.0/src/cmd/stats.rs:162:25 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" -xsv-0.13.0/src/cmd/stats.rs:22:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv-0.13.0/src/cmd/stats.rs:231:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -xsv-0.13.0/src/cmd/stats.rs:262:35 clippy::default_trait_access "calling `cmd::stats::TypedSum::default()` is more clear than this expression" -xsv-0.13.0/src/cmd/stats.rs:263:40 clippy::default_trait_access "calling `cmd::stats::TypedMinMax::default()` is more clear than this expression" -xsv-0.13.0/src/cmd/stats.rs:264:39 clippy::default_trait_access "calling `stats::OnlineStats::default()` is more clear than this expression" -xsv-0.13.0/src/cmd/stats.rs:265:58 clippy::default_trait_access "calling `stats::Unsorted::default()` is more clear than this expression" -xsv-0.13.0/src/cmd/stats.rs:266:41 clippy::default_trait_access "calling `stats::Unsorted::default()` is more clear than this expression" -xsv-0.13.0/src/cmd/stats.rs:268:18 clippy::default_trait_access "calling `cmd::stats::FieldType::default()` is more clear than this expression" -xsv-0.13.0/src/cmd/stats.rs:269:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv-0.13.0/src/cmd/stats.rs:270:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv-0.13.0/src/cmd/stats.rs:271:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv-0.13.0/src/cmd/stats.rs:272:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv-0.13.0/src/cmd/stats.rs:273:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv-0.13.0/src/cmd/stats.rs:274:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv-0.13.0/src/cmd/stats.rs:283:9 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" -xsv-0.13.0/src/cmd/stats.rs:284:9 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" -xsv-0.13.0/src/cmd/stats.rs:285:9 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" -xsv-0.13.0/src/cmd/stats.rs:290:21 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" -xsv-0.13.0/src/cmd/stats.rs:293:25 clippy::match_same_arms "this `match` has identical arm bodies" -xsv-0.13.0/src/cmd/stats.rs:297:25 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" -xsv-0.13.0/src/cmd/stats.rs:301:21 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" -xsv-0.13.0/src/cmd/stats.rs:302:21 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" -xsv-0.13.0/src/cmd/stats.rs:308:18 clippy::wrong_self_convention "methods called `to_*` usually take self by reference; consider choosing a less ambiguous name" -xsv-0.13.0/src/cmd/stats.rs:318:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -xsv-0.13.0/src/cmd/stats.rs:322:45 clippy::redundant_closure_for_method_calls "redundant closure found" -xsv-0.13.0/src/cmd/stats.rs:322:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -xsv-0.13.0/src/cmd/stats.rs:327:9 clippy::if_not_else "unnecessary boolean `not` operation" -xsv-0.13.0/src/cmd/stats.rs:330:13 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -xsv-0.13.0/src/cmd/stats.rs:338:45 clippy::redundant_closure_for_method_calls "redundant closure found" -xsv-0.13.0/src/cmd/stats.rs:402:16 clippy::redundant_pattern_matching "redundant pattern matching, consider using `is_ok()`" -xsv-0.13.0/src/cmd/stats.rs:403:16 clippy::redundant_pattern_matching "redundant pattern matching, consider using `is_ok()`" -xsv-0.13.0/src/cmd/stats.rs:407:18 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -xsv-0.13.0/src/cmd/stats.rs:411:16 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -xsv-0.13.0/src/cmd/stats.rs:427:56 clippy::match_same_arms "this `match` has identical arm bodies" -xsv-0.13.0/src/cmd/stats.rs:429:56 clippy::match_same_arms "this `match` has identical arm bodies" -xsv-0.13.0/src/cmd/stats.rs:430:60 clippy::match_same_arms "this `match` has identical arm bodies" -xsv-0.13.0/src/cmd/stats.rs:430:60 clippy::match_same_arms "this `match` has identical arm bodies" -xsv-0.13.0/src/cmd/stats.rs:454:5 clippy::doc_markdown "you should put `TypedSum` between ticks in the documentation" -xsv-0.13.0/src/cmd/stats.rs:473:43 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -xsv-0.13.0/src/cmd/stats.rs:504:56 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -xsv-0.13.0/src/cmd/stats.rs:505:51 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -xsv-0.13.0/src/cmd/stats.rs:511:5 clippy::doc_markdown "you should put `TypedMinMax` between ticks in the documentation" -xsv-0.13.0/src/cmd/stats.rs:536:35 clippy::cast_possible_truncation "casting `f64` to `i64` may truncate the value" -xsv-0.13.0/src/cmd/stats.rs:544:33 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -xsv-0.13.0/src/cmd/stats.rs:592:22 clippy::default_trait_access "calling `stats::MinMax::default()` is more clear than this expression" -xsv-0.13.0/src/cmd/stats.rs:593:22 clippy::default_trait_access "calling `stats::MinMax::default()` is more clear than this expression" -xsv-0.13.0/src/cmd/stats.rs:594:23 clippy::default_trait_access "calling `stats::MinMax::default()` is more clear than this expression" -xsv-0.13.0/src/cmd/stats.rs:595:21 clippy::default_trait_access "calling `stats::MinMax::default()` is more clear than this expression" -xsv-0.13.0/src/cmd/stats.rs:71:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -xsv-0.13.0/src/cmd/stats.rs:86:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/table.rs:10:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv-0.13.0/src/cmd/table.rs:50:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/table.rs:54:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/config.rs:113:43 clippy::or_fun_call "use of `unwrap_or` followed by a function call" -xsv-0.13.0/src/config.rs:58:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -xsv-0.13.0/src/config.rs:77:28 clippy::explicit_deref_methods "explicit deref method call" -xsv-0.13.0/src/config.rs:90:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv-0.13.0/src/index.rs:31:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv-0.13.0/src/main.rs:164:49 clippy::redundant_clone "redundant clone" -xsv-0.13.0/src/main.rs:1:null clippy::cargo_common_metadata "package `xsv` is missing `package.categories` metadata" -xsv-0.13.0/src/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `rand_core`: 0.3.1, 0.4.2" -xsv-0.13.0/src/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `rand`: 0.3.23, 0.4.6" -xsv-0.13.0/src/main.rs:75:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv-0.13.0/src/select.rs:13:1 clippy::module_name_repetitions "item name starts with its containing module's name" -xsv-0.13.0/src/select.rs:154:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -xsv-0.13.0/src/select.rs:250:33 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/select.rs:250:43 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/select.rs:255:39 clippy::range_plus_one "an inclusive range would be more readable" -xsv-0.13.0/src/select.rs:280:20 clippy::len_zero "length comparison to zero" -xsv-0.13.0/src/select.rs:29:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv-0.13.0/src/select.rs:360:62 clippy::trivially_copy_pass_by_ref "this argument (8 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -xsv-0.13.0/src/select.rs:360:9 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Option`" -xsv-0.13.0/src/select.rs:375:9 clippy::stable_sort_primitive "used `sort` on primitive type `usize`" -xsv-0.13.0/src/select.rs:379:18 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" -xsv-0.13.0/src/select.rs:416:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -xsv-0.13.0/src/select.rs:419:9 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Option`" -xsv-0.13.0/src/select.rs:420:27 clippy::option_option "consider using `Option` instead of `Option>` or a custom enum if you need to distinguish all 3 cases" -xsv-0.13.0/src/select.rs:99:17 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/util.rs:150:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" -xsv-0.13.0/src/util.rs:37:33 clippy::map_clone "you are using an explicit closure for copying elements" -xsv-0.13.0/src/util.rs:90:1 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" - - - - -Stats - -clippy::clone_on_copy 1 -clippy::comparison_chain 1 -clippy::expect_fun_call 1 -clippy::explicit_deref_methods 1 -clippy::from_iter_instead_of_collect 1 -clippy::from_over_into 1 -clippy::int_plus_one 1 -clippy::manual_flatten 1 -clippy::manual_saturating_arithmetic 1 -clippy::mem_replace_with_default 1 -clippy::nonminimal_bool 1 -clippy::or_fun_call 1 -clippy::precedence 1 -clippy::pub_enum_variant_names 1 -clippy::redundant_clone 1 -clippy::redundant_slicing 1 -clippy::same_item_push 1 -clippy::should_implement_trait 1 -clippy::stable_sort_primitive 1 -clippy::unit_arg 1 -clippy::unnecessary_lazy_evaluations 1 -clippy::unsafe_derive_deserialize 1 -clippy::used_underscore_binding 1 -clippy::verbose_bit_mask 1 -clippy::while_let_on_iterator 1 -clippy::comparison_to_empty 2 -clippy::derive_hash_xor_eq 2 -clippy::expl_impl_clone_on_copy 2 -clippy::filter_map 2 -clippy::len_zero 2 -clippy::manual_non_exhaustive 2 -clippy::match_on_vec_items 2 -clippy::option_as_ref_deref 2 -clippy::option_option 2 -clippy::question_mark 2 -clippy::redundant_pattern_matching 2 -clippy::type_complexity 2 -clippy::unnecessary_cast 2 -clippy::unused_unit 2 -clippy::vec_init_then_push 2 -clippy::write_with_newline 2 -clippy::filter_map_next 3 -clippy::fn_params_excessive_bools 3 -clippy::if_same_then_else 3 -clippy::mut_mut 3 -clippy::ptr_arg 3 -clippy::zero_ptr 3 -clippy::let_underscore_drop 4 -clippy::too_many_arguments 4 -clippy::explicit_iter_loop 5 -clippy::field_reassign_with_default 5 -clippy::identity_op 5 -clippy::len_without_is_empty 5 -clippy::match_like_matches_macro 5 -clippy::needless_return 5 -clippy::new_without_default 5 -clippy::ptr_as_ptr 5 -clippy::collapsible_else_if 6 -clippy::manual_strip 6 -clippy::non_ascii_literal 6 -clippy::single_component_path_imports 6 -clippy::case_sensitive_file_extension_comparisons 7 -clippy::explicit_into_iter_loop 7 -clippy::map_clone 7 -clippy::option_map_unit_fn 7 -clippy::range_plus_one 7 -clippy::invalid_upcast_comparisons 8 -clippy::needless_question_mark 8 -clippy::wrong_self_convention 8 -clippy::manual_range_contains 10 -clippy::match_wildcard_for_single_variants 10 -clippy::missing_safety_doc 10 -clippy::needless_doctest_main 10 -clippy::multiple_crate_versions 11 -clippy::needless_lifetimes 12 -clippy::cargo_common_metadata 13 -clippy::shadow_unrelated 13 -clippy::linkedlist 14 -clippy::single_char_add_str 14 -clippy::option_if_let_else 15 -clippy::needless_pass_by_value 18 -clippy::upper_case_acronyms 18 -clippy::cast_possible_wrap 19 -clippy::cast_sign_loss 19 -clippy::unnecessary_wraps 19 -clippy::unused_self 19 -clippy::unusual_byte_groupings 19 -clippy::map_unwrap_or 20 -clippy::struct_excessive_bools 20 -clippy::redundant_static_lifetimes 21 -clippy::default_trait_access 22 -clippy::cast_lossless 23 -clippy::trivially_copy_pass_by_ref 26 -clippy::redundant_else 29 -clippy::too_many_lines 32 -clippy::if_not_else 35 -clippy::enum_glob_use 40 -clippy::unseparated_literal_suffix 41 -clippy::cast_precision_loss 44 -clippy::single_match_else 45 -clippy::inline_always 59 -clippy::match_same_arms 65 -clippy::similar_names 78 -clippy::cast_possible_truncation 95 -clippy::missing_panics_doc 108 -clippy::redundant_field_names 111 -clippy::redundant_closure_for_method_calls 135 -clippy::items_after_statements 139 -clippy::module_name_repetitions 142 -clippy::wildcard_imports 163 -clippy::doc_markdown 178 -clippy::missing_errors_doc 343 -clippy::unreadable_literal 365 -clippy::must_use_candidate 565 -- cgit 1.4.1-3-g733a5 From 5e29aa6fdf4c8729ffd01c40aa17ad9bd501d1df Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Wed, 10 Feb 2021 11:32:10 +0100 Subject: lintcheck: add support for path sources --- clippy_dev/Cargo.toml | 3 ++- clippy_dev/README.md | 6 +++-- clippy_dev/lintcheck_crates.toml | 1 + clippy_dev/src/lintcheck.rs | 50 +++++++++++++++++++++++++++++++++++++--- 4 files changed, 54 insertions(+), 6 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/Cargo.toml b/clippy_dev/Cargo.toml index f48c1ee5ea2..5ac96e2210c 100644 --- a/clippy_dev/Cargo.toml +++ b/clippy_dev/Cargo.toml @@ -9,6 +9,7 @@ edition = "2018" bytecount = "0.6" clap = "2.33" flate2 = { version = "1.0.19", optional = true } +fs_extra = { version = "1.2.0", optional = true } itertools = "0.9" opener = "0.4" regex = "1" @@ -21,5 +22,5 @@ ureq = { version = "2.0.0-rc3", optional = true } walkdir = "2" [features] -lintcheck = ["flate2", "serde_json", "tar", "toml", "ureq", "serde"] +lintcheck = ["flate2", "serde_json", "tar", "toml", "ureq", "serde", "fs_extra"] deny-warnings = [] diff --git a/clippy_dev/README.md b/clippy_dev/README.md index 6ab8ecbdbca..3846e8bd4cc 100644 --- a/clippy_dev/README.md +++ b/clippy_dev/README.md @@ -1,8 +1,10 @@ -## Clippy-dev is a tool to ease clippys development, similar to `rustc`s `x.py`. +# Clippy Dev Tool + +The Clippy Dev Tool is a tool to ease Clippy development, similar to `rustc`s `x.py`. Functionalities (incomplete): -# lintcheck +## `lintcheck` Runs clippy on a fixed set of crates read from `clippy_dev/lintcheck_crates.toml` and saves logs of the lint warnings into the repo. We can then check the diff and spot new or disappearing warnings. diff --git a/clippy_dev/lintcheck_crates.toml b/clippy_dev/lintcheck_crates.toml index 2cddd3e6ee7..60e70ca4eb2 100644 --- a/clippy_dev/lintcheck_crates.toml +++ b/clippy_dev/lintcheck_crates.toml @@ -10,6 +10,7 @@ rayon = {name = "rayon", versions = ['1.5.0']} serde = {name = "serde", versions = ['1.0.118']} # top 10 crates.io dls bitflags = {name = "bitflags", versions = ['1.2.1']} +# crash = {name = "clippy_crash", path = "/tmp/clippy_crash"} libc = {name = "libc", versions = ['0.2.81']} log = {name = "log", versions = ['0.4.11']} proc-macro2 = {name = "proc-macro2", versions = ['1.0.24']} diff --git a/clippy_dev/src/lintcheck.rs b/clippy_dev/src/lintcheck.rs index faf13543f18..e9d0b420c3b 100644 --- a/clippy_dev/src/lintcheck.rs +++ b/clippy_dev/src/lintcheck.rs @@ -31,13 +31,15 @@ struct TomlCrate { versions: Option>, git_url: Option, git_hash: Option, + path: Option, } -// represents an archive we download from crates.io +// represents an archive we download from crates.io, or a git repo, or a local repo #[derive(Debug, Serialize, Deserialize, Eq, Hash, PartialEq)] enum CrateSource { CratesIo { name: String, version: String }, Git { name: String, url: String, commit: String }, + Path { name: String, path: PathBuf }, } // represents the extracted sourcecode of a crate @@ -111,7 +113,7 @@ impl CrateSource { }, CrateSource::Git { name, url, commit } => { let repo_path = { - let mut repo_path = PathBuf::from("target/lintcheck/downloads"); + let mut repo_path = PathBuf::from("target/lintcheck/crates"); // add a -git suffix in case we have the same crate from crates.io and a git repo repo_path.push(format!("{}-git", name)); repo_path @@ -139,6 +141,37 @@ impl CrateSource { path: repo_path, } }, + CrateSource::Path { name, path } => { + use fs_extra::dir; + + // simply copy the entire directory into our target dir + let copy_dest = PathBuf::from("target/lintcheck/crates/"); + + // the source path of the crate we copied, ${copy_dest}/crate_name + let crate_root = copy_dest.join(name); // .../crates/local_crate + + if !crate_root.exists() { + println!("Copying {} to {}", path.display(), copy_dest.display()); + + dir::copy(path, ©_dest, &dir::CopyOptions::new()).expect(&format!( + "Failed to copy from {}, to {}", + path.display(), + crate_root.display() + )); + } else { + println!( + "Not copying {} to {}, destination already exists", + path.display(), + crate_root.display() + ); + } + + Crate { + version: String::from("local"), + name: name.clone(), + path: crate_root, + } + }, } } } @@ -211,6 +244,13 @@ fn read_crates(toml_path: Option<&str>) -> (String, Vec) { // multiple Cratesources) let mut crate_sources = Vec::new(); tomlcrates.into_iter().for_each(|tk| { + if let Some(ref path) = tk.path { + crate_sources.push(CrateSource::Path { + name: tk.name.clone(), + path: PathBuf::from(path), + }); + } + // if we have multiple versions, save each one if let Some(ref versions) = tk.versions { versions.iter().for_each(|ver| { @@ -234,7 +274,10 @@ fn read_crates(toml_path: Option<&str>) -> (String, Vec) { { eprintln!("tomlkrate: {:?}", tk); if tk.git_hash.is_some() != tk.git_url.is_some() { - panic!("Encountered TomlCrate with only one of git_hash and git_url!") + panic!("Error: Encountered TomlCrate with only one of git_hash and git_url!"); + } + if tk.path.is_some() && (tk.git_hash.is_some() || tk.versions.is_some()) { + panic!("Error: TomlCrate can only have one of 'git_.*', 'version' or 'path' fields"); } unreachable!("Failed to translate TomlCrate into CrateSource!"); } @@ -298,6 +341,7 @@ pub fn run(clap_config: &ArgMatches) { let name = match krate { CrateSource::CratesIo { name, .. } => name, CrateSource::Git { name, .. } => name, + CrateSource::Path { name, .. } => name, }; name == only_one_crate }) { -- cgit 1.4.1-3-g733a5 From a6d493d52af32a347550ca7dd3fba77b50412128 Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Wed, 10 Feb 2021 12:50:36 +0100 Subject: lintcheck: collect ICEs --- clippy_dev/src/lintcheck.rs | 17 +++++++++++++++-- 1 file changed, 15 insertions(+), 2 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lintcheck.rs b/clippy_dev/src/lintcheck.rs index e9d0b420c3b..749a791b280 100644 --- a/clippy_dev/src/lintcheck.rs +++ b/clippy_dev/src/lintcheck.rs @@ -62,6 +62,7 @@ struct ClippyWarning { column: String, linttype: String, message: String, + ice: bool, } impl std::fmt::Display for ClippyWarning { @@ -209,8 +210,8 @@ impl Crate { let output_lines = stdout.lines(); let warnings: Vec = output_lines .into_iter() - // get all clippy warnings - .filter(|line| line.contains("clippy::")) + // get all clippy warnings and ICEs + .filter(|line| line.contains("clippy::") || line.contains("internal compiler error: ")) .map(|json_msg| parse_json_message(json_msg, &self)) .collect(); warnings @@ -306,6 +307,7 @@ fn parse_json_message(json_message: &str, krate: &Crate) -> ClippyWarning { .into(), linttype: jmsg["message"]["code"]["code"].to_string().trim_matches('"').into(), message: jmsg["message"]["message"].to_string().trim_matches('"').into(), + ice: json_message.contains("internal compiler error: "), } } @@ -372,6 +374,13 @@ pub fn run(clap_config: &ArgMatches) { // generate some stats: + // grab crashes/ICEs, save the crate name and the ice message + let ices: Vec<(&String, &String)> = clippy_warnings + .iter() + .filter(|warning| warning.ice) + .map(|w| (&w.crate_name, &w.message)) + .collect(); + // count lint type occurrences let mut counter: HashMap<&String, usize> = HashMap::new(); clippy_warnings @@ -397,6 +406,10 @@ pub fn run(clap_config: &ArgMatches) { // save the text into lintcheck-logs/logs.txt let mut text = clippy_ver; // clippy version number on top text.push_str(&format!("\n{}", all_msgs.join(""))); + text.push_str("ICEs:\n"); + ices.iter() + .for_each(|(cratename, msg)| text.push_str(&format!("{}: '{}'", cratename, msg))); + let file = format!("lintcheck-logs/{}_logs.txt", filename); write(file, text).unwrap(); } -- cgit 1.4.1-3-g733a5 From 5bbb1bc20a24ad64ab7a70d002ee95c5ce9d6f8a Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Sat, 13 Feb 2021 00:39:19 +0100 Subject: lintcheck: env var LINTCHECK_TOML can be used to override toml file location (has precedence over --crates-toml flag) --- clippy_dev/README.md | 2 +- clippy_dev/src/lintcheck.rs | 6 ++++-- 2 files changed, 5 insertions(+), 3 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/README.md b/clippy_dev/README.md index 3846e8bd4cc..a09365fadc4 100644 --- a/clippy_dev/README.md +++ b/clippy_dev/README.md @@ -21,7 +21,7 @@ cargo dev-lintcheck By default the logs will be saved into `lintcheck-logs/lintcheck_crates_logs.txt`. -You can set a custom sources.toml by adding `--crates-toml custom.toml` +You can set a custom sources.toml by adding `--crates-toml custom.toml` or using `LINTCHECK_TOML="custom.toml"` where `custom.toml` must be a relative path from the repo root. The results will then be saved to `lintcheck-logs/custom_logs.toml`. diff --git a/clippy_dev/src/lintcheck.rs b/clippy_dev/src/lintcheck.rs index 749a791b280..3836df39adc 100644 --- a/clippy_dev/src/lintcheck.rs +++ b/clippy_dev/src/lintcheck.rs @@ -11,7 +11,7 @@ use crate::clippy_project_root; use std::collections::HashMap; use std::process::Command; -use std::{fmt, fs::write, path::PathBuf}; +use std::{env, fmt, fs::write, path::PathBuf}; use clap::ArgMatches; use serde::{Deserialize, Serialize}; @@ -227,7 +227,9 @@ fn build_clippy() { // get a list of CrateSources we want to check from a "lintcheck_crates.toml" file. fn read_crates(toml_path: Option<&str>) -> (String, Vec) { - let toml_path = PathBuf::from(toml_path.unwrap_or("clippy_dev/lintcheck_crates.toml")); + let toml_path = PathBuf::from( + env::var("LINTCHECK_TOML").unwrap_or(toml_path.unwrap_or("clippy_dev/lintcheck_crates.toml").to_string()), + ); // save it so that we can use the name of the sources.toml as name for the logfile later. let toml_filename = toml_path.file_stem().unwrap().to_str().unwrap().to_string(); let toml_content: String = -- cgit 1.4.1-3-g733a5 From 1b744398718593d00cdccf81fc20b8a3cfd9ead4 Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Sun, 14 Feb 2021 18:37:08 +0100 Subject: lintcheck: rename struct field --- clippy_dev/src/lintcheck.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lintcheck.rs b/clippy_dev/src/lintcheck.rs index 3836df39adc..15b0e4a5a71 100644 --- a/clippy_dev/src/lintcheck.rs +++ b/clippy_dev/src/lintcheck.rs @@ -62,7 +62,7 @@ struct ClippyWarning { column: String, linttype: String, message: String, - ice: bool, + is_ice: bool, } impl std::fmt::Display for ClippyWarning { @@ -309,7 +309,7 @@ fn parse_json_message(json_message: &str, krate: &Crate) -> ClippyWarning { .into(), linttype: jmsg["message"]["code"]["code"].to_string().trim_matches('"').into(), message: jmsg["message"]["message"].to_string().trim_matches('"').into(), - ice: json_message.contains("internal compiler error: "), + is_ice: json_message.contains("internal compiler error: "), } } @@ -379,7 +379,7 @@ pub fn run(clap_config: &ArgMatches) { // grab crashes/ICEs, save the crate name and the ice message let ices: Vec<(&String, &String)> = clippy_warnings .iter() - .filter(|warning| warning.ice) + .filter(|warning| warning.is_ice) .map(|w| (&w.crate_name, &w.message)) .collect(); -- cgit 1.4.1-3-g733a5 From 4856e5f8fc37f1fbe3766a44f1cec9520e208a5a Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Sun, 14 Feb 2021 18:51:53 +0100 Subject: lintcheck: rename a few symbols, add documentation to functions --- clippy_dev/src/lintcheck.rs | 30 ++++++++++++++++++------------ 1 file changed, 18 insertions(+), 12 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lintcheck.rs b/clippy_dev/src/lintcheck.rs index 15b0e4a5a71..45620cc9e63 100644 --- a/clippy_dev/src/lintcheck.rs +++ b/clippy_dev/src/lintcheck.rs @@ -17,14 +17,14 @@ use clap::ArgMatches; use serde::{Deserialize, Serialize}; use serde_json::Value; -// use this to store the crates when interacting with the crates.toml file +/// List of sources to check, loaded from a .toml file #[derive(Debug, Serialize, Deserialize)] -struct CrateList { +struct SourceList { crates: HashMap, } -// crate data we stored in the toml, can have multiple versions per crate -// A single TomlCrate is laster mapped to several CrateSources in that case +/// A crate source stored inside the .toml +/// will be translated into on one of the `CrateSource` variants #[derive(Debug, Serialize, Deserialize)] struct TomlCrate { name: String, @@ -34,7 +34,8 @@ struct TomlCrate { path: Option, } -// represents an archive we download from crates.io, or a git repo, or a local repo +/// Represents an archive we download from crates.io, or a git repo, or a local repo/folder +/// Once processed (downloaded/extracted/cloned/copied...), this will be translated into a `Crate` #[derive(Debug, Serialize, Deserialize, Eq, Hash, PartialEq)] enum CrateSource { CratesIo { name: String, version: String }, @@ -42,9 +43,7 @@ enum CrateSource { Path { name: String, path: PathBuf }, } -// represents the extracted sourcecode of a crate -// we actually don't need to special-case git repos here because it does not matter for clippy, yay! -// (clippy only needs a simple path) +/// Represents the actual source code of a crate that we ran "cargo clippy" on #[derive(Debug)] struct Crate { version: String, @@ -53,6 +52,7 @@ struct Crate { path: PathBuf, } +/// A single warning that clippy issued while checking a `Crate` #[derive(Debug)] struct ClippyWarning { crate_name: String, @@ -76,6 +76,9 @@ impl std::fmt::Display for ClippyWarning { } impl CrateSource { + /// Makes the sources available on the disk for clippy to check. + /// Clones a git repo and checks out the specified commit or downloads a crate from crates.io or + /// copies a local folder fn download_and_extract(&self) -> Crate { match self { CrateSource::CratesIo { name, version } => { @@ -178,6 +181,8 @@ impl CrateSource { } impl Crate { + /// Run `cargo clippy` on the `Crate` and collect and return all the lint warnings that clippy + /// issued fn run_clippy_lints(&self, cargo_clippy_path: &PathBuf) -> Vec { println!("Linting {} {}...", &self.name, &self.version); let cargo_clippy_path = std::fs::canonicalize(cargo_clippy_path).unwrap(); @@ -218,6 +223,7 @@ impl Crate { } } +/// Builds clippy inside the repo to make sure we have a clippy executable we can use. fn build_clippy() { Command::new("cargo") .arg("build") @@ -225,7 +231,7 @@ fn build_clippy() { .expect("Failed to build clippy!"); } -// get a list of CrateSources we want to check from a "lintcheck_crates.toml" file. +/// Read a `toml` file and return a list of `CrateSources` that we want to check with clippy fn read_crates(toml_path: Option<&str>) -> (String, Vec) { let toml_path = PathBuf::from( env::var("LINTCHECK_TOML").unwrap_or(toml_path.unwrap_or("clippy_dev/lintcheck_crates.toml").to_string()), @@ -234,7 +240,7 @@ fn read_crates(toml_path: Option<&str>) -> (String, Vec) { let toml_filename = toml_path.file_stem().unwrap().to_str().unwrap().to_string(); let toml_content: String = std::fs::read_to_string(&toml_path).unwrap_or_else(|_| panic!("Failed to read {}", toml_path.display())); - let crate_list: CrateList = + let crate_list: SourceList = toml::from_str(&toml_content).unwrap_or_else(|e| panic!("Failed to parse {}: \n{}", toml_path.display(), e)); // parse the hashmap of the toml file into a list of crates let tomlcrates: Vec = crate_list @@ -288,7 +294,7 @@ fn read_crates(toml_path: Option<&str>) -> (String, Vec) { (toml_filename, crate_sources) } -// extract interesting data from a json lint message +/// Parse the json output of clippy and return a `ClippyWarning` fn parse_json_message(json_message: &str, krate: &Crate) -> ClippyWarning { let jmsg: Value = serde_json::from_str(&json_message).unwrap_or_else(|e| panic!("Failed to parse json:\n{:?}", e)); @@ -313,7 +319,7 @@ fn parse_json_message(json_message: &str, krate: &Crate) -> ClippyWarning { } } -// the main fn +/// lintchecks `main()` function pub fn run(clap_config: &ArgMatches) { let cargo_clippy_path: PathBuf = PathBuf::from("target/debug/cargo-clippy"); -- cgit 1.4.1-3-g733a5 From 214d821268628f7637d004c8e6b5eb7b69dd0583 Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Sun, 14 Feb 2021 18:59:32 +0100 Subject: lintcheck: put some code into a gather_stats() function --- clippy_dev/src/lintcheck.rs | 40 ++++++++++++++++++++++------------------ 1 file changed, 22 insertions(+), 18 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lintcheck.rs b/clippy_dev/src/lintcheck.rs index 45620cc9e63..ce05d4b0887 100644 --- a/clippy_dev/src/lintcheck.rs +++ b/clippy_dev/src/lintcheck.rs @@ -319,6 +319,26 @@ fn parse_json_message(json_message: &str, krate: &Crate) -> ClippyWarning { } } +/// Generate a short list of occuring lints-types and their count +fn gather_stats(clippy_warnings: &[ClippyWarning]) -> String { + // count lint type occurrences + let mut counter: HashMap<&String, usize> = HashMap::new(); + clippy_warnings + .iter() + .for_each(|wrn| *counter.entry(&wrn.linttype).or_insert(0) += 1); + + // collect into a tupled list for sorting + let mut stats: Vec<(&&String, &usize)> = counter.iter().map(|(lint, count)| (lint, count)).collect(); + // sort by "000{count} {clippy::lintname}" + // to not have a lint with 200 and 2 warnings take the same spot + stats.sort_by_key(|(lint, count)| format!("{:0>4}, {}", count, lint)); + + stats + .iter() + .map(|(lint, count)| format!("{} {}\n", lint, count)) + .collect::() +} + /// lintchecks `main()` function pub fn run(clap_config: &ArgMatches) { let cargo_clippy_path: PathBuf = PathBuf::from("target/debug/cargo-clippy"); @@ -380,7 +400,8 @@ pub fn run(clap_config: &ArgMatches) { .collect() }; - // generate some stats: + // generate some stats + let stats_formatted = gather_stats(&clippy_warnings); // grab crashes/ICEs, save the crate name and the ice message let ices: Vec<(&String, &String)> = clippy_warnings @@ -389,23 +410,6 @@ pub fn run(clap_config: &ArgMatches) { .map(|w| (&w.crate_name, &w.message)) .collect(); - // count lint type occurrences - let mut counter: HashMap<&String, usize> = HashMap::new(); - clippy_warnings - .iter() - .for_each(|wrn| *counter.entry(&wrn.linttype).or_insert(0) += 1); - - // collect into a tupled list for sorting - let mut stats: Vec<(&&String, &usize)> = counter.iter().map(|(lint, count)| (lint, count)).collect(); - // sort by "000{count} {clippy::lintname}" - // to not have a lint with 200 and 2 warnings take the same spot - stats.sort_by_key(|(lint, count)| format!("{:0>4}, {}", count, lint)); - - let stats_formatted: String = stats - .iter() - .map(|(lint, count)| format!("{} {}\n", lint, count)) - .collect::(); - let mut all_msgs: Vec = clippy_warnings.iter().map(|warning| warning.to_string()).collect(); all_msgs.sort(); all_msgs.push("\n\n\n\nStats\n\n".into()); -- cgit 1.4.1-3-g733a5 From f8dbcae9f42e7f238595fe604c1bfccba64b510e Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Mon, 15 Feb 2021 22:36:49 +0100 Subject: lintcheck: fix bug in downloade_and_extract() for git sources: we need to execute "git checkout xy" inside the repo dir! --- clippy_dev/src/lintcheck.rs | 1 + 1 file changed, 1 insertion(+) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lintcheck.rs b/clippy_dev/src/lintcheck.rs index ce05d4b0887..2077f393a3f 100644 --- a/clippy_dev/src/lintcheck.rs +++ b/clippy_dev/src/lintcheck.rs @@ -136,6 +136,7 @@ impl CrateSource { Command::new("git") .arg("checkout") .arg(commit) + .current_dir(&repo_path) .output() .expect("Failed to check out commit"); -- cgit 1.4.1-3-g733a5 From 8f1cceb6ffe1324d403702e2ccf48d96a74eb33b Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Mon, 15 Feb 2021 22:46:58 +0100 Subject: lintcheck: print warnings if we can't check out or clone a git repo --- clippy_dev/src/lintcheck.rs | 20 ++++++++++++++------ 1 file changed, 14 insertions(+), 6 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lintcheck.rs b/clippy_dev/src/lintcheck.rs index 2077f393a3f..017d1e09eec 100644 --- a/clippy_dev/src/lintcheck.rs +++ b/clippy_dev/src/lintcheck.rs @@ -125,20 +125,28 @@ impl CrateSource { // clone the repo if we have not done so if !repo_path.is_dir() { println!("Cloning {} and checking out {}", url, commit); - Command::new("git") + if !Command::new("git") .arg("clone") .arg(url) .arg(&repo_path) - .output() - .expect("Failed to clone git repo!"); + .status() + .expect("Failed to clone git repo!") + .success() + { + eprintln!("Failed to clone {} into {}", url, repo_path.display()) + } } // check out the commit/branch/whatever - Command::new("git") + if !Command::new("git") .arg("checkout") .arg(commit) .current_dir(&repo_path) - .output() - .expect("Failed to check out commit"); + .status() + .expect("Failed to check out commit") + .success() + { + eprintln!("Failed to checkout {} of repo at {}", commit, repo_path.display()) + } Crate { version: commit.clone(), -- cgit 1.4.1-3-g733a5 From 028692b46a52f2fe63e7ed18bb4f46ab83cdcb8c Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Mon, 15 Feb 2021 23:13:41 +0100 Subject: lintcheck: filter out messages that come from cargo-metadata errors or contain absolute paths to rustc source files The latter is especially annoying because the paths would change every time we bumped the pinned nightly version. --- clippy_dev/src/lintcheck.rs | 25 ++++++++++++++++++++++++- 1 file changed, 24 insertions(+), 1 deletion(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lintcheck.rs b/clippy_dev/src/lintcheck.rs index 017d1e09eec..e96e1446c0f 100644 --- a/clippy_dev/src/lintcheck.rs +++ b/clippy_dev/src/lintcheck.rs @@ -225,13 +225,36 @@ impl Crate { let warnings: Vec = output_lines .into_iter() // get all clippy warnings and ICEs - .filter(|line| line.contains("clippy::") || line.contains("internal compiler error: ")) + .filter(|line| filter_clippy_warnings(&line)) .map(|json_msg| parse_json_message(json_msg, &self)) .collect(); warnings } } +/// takes a single json-formatted clippy warnings and returns true (we are interested in that line) +/// or false (we aren't) +fn filter_clippy_warnings(line: &str) -> bool { + // we want to collect ICEs because clippy might have crashed. + // these are summarized later + if line.contains("internal compiler error: ") { + return true; + } + // in general, we want all clippy warnings + // however due to some kind of bug, sometimes there are absolute paths + // to libcore files inside the message + // or we end up with cargo-metadata output (https://github.com/rust-lang/rust-clippy/issues/6508) + + // filter out these message to avoid unnecessary noise in the logs + if line.contains("clippy::") + && !(line.contains("could not read cargo metadata") + || (line.contains(".rustup") && line.contains("toolchains"))) + { + return true; + } + false +} + /// Builds clippy inside the repo to make sure we have a clippy executable we can use. fn build_clippy() { Command::new("cargo") -- cgit 1.4.1-3-g733a5 From 2a28ea0beaca8b9de1d26ef4af9e264db1c143c4 Mon Sep 17 00:00:00 2001 From: flip1995 Date: Tue, 16 Feb 2021 13:38:01 +0100 Subject: Add command line options option to lintcheck crates config --- clippy_dev/README.md | 58 ++++++++++++++++++++++++++++----------------- clippy_dev/src/lintcheck.rs | 57 +++++++++++++++++++++++++++++++++----------- 2 files changed, 79 insertions(+), 36 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/README.md b/clippy_dev/README.md index 7c582b37535..7e794222a93 100644 --- a/clippy_dev/README.md +++ b/clippy_dev/README.md @@ -1,4 +1,4 @@ -# Clippy Dev Tool +# Clippy Dev Tool The Clippy Dev Tool is a tool to ease Clippy development, similar to `rustc`s `x.py`. @@ -28,25 +28,39 @@ The results will then be saved to `lintcheck-logs/custom_logs.toml`. ### Configuring the Crate Sources -The sources to check are saved in a `toml` file. -There are three types of sources. -A crates-io source: -````toml -bitflags = {name = "bitflags", versions = ['1.2.1']} -```` -Requires a "name" and one or multiple "versions" to be checked. +The sources to check are saved in a `toml` file. +There are three types of sources. -A git source: -````toml -puffin = {name = "puffin", git_url = "https://github.com/EmbarkStudios/puffin", git_hash = "02dd4a3"} -```` -Requires a name, the url to the repo and unique identifier of a commit, -branch or tag which is checked out before linting. -There is no way to always check `HEAD` because that would lead to changing lint-results as the repo would get updated. -If `git_url` or `git_hash` is missing, an error will be thrown. - -A local dependency: -````toml - clippy = {name = "clippy", path = "/home/user/clippy"} -```` -For when you want to add a repository that is not published yet. +1. Crates-io Source + + ````toml + bitflags = {name = "bitflags", versions = ['1.2.1']} + ```` + Requires a "name" and one or multiple "versions" to be checked. + +2. `git` Source + ````toml + puffin = {name = "puffin", git_url = "https://github.com/EmbarkStudios/puffin", git_hash = "02dd4a3"} + ```` + Requires a name, the url to the repo and unique identifier of a commit, + branch or tag which is checked out before linting. + There is no way to always check `HEAD` because that would lead to changing lint-results as the repo would get updated. + If `git_url` or `git_hash` is missing, an error will be thrown. + +3. Local Dependency + ````toml + clippy = {name = "clippy", path = "/home/user/clippy"} + ```` + For when you want to add a repository that is not published yet. + +#### Command Line Options (optional) + +```toml +bitflags = {name = "bitflags", versions = ['1.2.1'], options = ['-Wclippy::pedantic', '-Wclippy::cargo']} +``` + +It is possible to specify command line options for each crate. This makes it +possible to only check a crate for certain lint groups. If no options are +specified, the lint groups `clippy::all`, `clippy::pedantic`, and +`clippy::cargo` are checked. If an empty array is specified only `clippy::all` +is checked. diff --git a/clippy_dev/src/lintcheck.rs b/clippy_dev/src/lintcheck.rs index e96e1446c0f..b62784da548 100644 --- a/clippy_dev/src/lintcheck.rs +++ b/clippy_dev/src/lintcheck.rs @@ -32,15 +32,29 @@ struct TomlCrate { git_url: Option, git_hash: Option, path: Option, + options: Option>, } /// Represents an archive we download from crates.io, or a git repo, or a local repo/folder /// Once processed (downloaded/extracted/cloned/copied...), this will be translated into a `Crate` #[derive(Debug, Serialize, Deserialize, Eq, Hash, PartialEq)] enum CrateSource { - CratesIo { name: String, version: String }, - Git { name: String, url: String, commit: String }, - Path { name: String, path: PathBuf }, + CratesIo { + name: String, + version: String, + options: Option>, + }, + Git { + name: String, + url: String, + commit: String, + options: Option>, + }, + Path { + name: String, + path: PathBuf, + options: Option>, + }, } /// Represents the actual source code of a crate that we ran "cargo clippy" on @@ -50,6 +64,7 @@ struct Crate { name: String, // path to the extracted sources that clippy can check path: PathBuf, + options: Option>, } /// A single warning that clippy issued while checking a `Crate` @@ -81,7 +96,7 @@ impl CrateSource { /// copies a local folder fn download_and_extract(&self) -> Crate { match self { - CrateSource::CratesIo { name, version } => { + CrateSource::CratesIo { name, version, options } => { let extract_dir = PathBuf::from("target/lintcheck/crates"); let krate_download_dir = PathBuf::from("target/lintcheck/downloads"); @@ -113,9 +128,15 @@ impl CrateSource { version: version.clone(), name: name.clone(), path: extract_dir.join(format!("{}-{}/", name, version)), + options: options.clone(), } }, - CrateSource::Git { name, url, commit } => { + CrateSource::Git { + name, + url, + commit, + options, + } => { let repo_path = { let mut repo_path = PathBuf::from("target/lintcheck/crates"); // add a -git suffix in case we have the same crate from crates.io and a git repo @@ -152,9 +173,10 @@ impl CrateSource { version: commit.clone(), name: name.clone(), path: repo_path, + options: options.clone(), } }, - CrateSource::Path { name, path } => { + CrateSource::Path { name, path, options } => { use fs_extra::dir; // simply copy the entire directory into our target dir @@ -183,6 +205,7 @@ impl CrateSource { version: String::from("local"), name: name.clone(), path: crate_root, + options: options.clone(), } }, } @@ -198,18 +221,21 @@ impl Crate { let shared_target_dir = clippy_project_root().join("target/lintcheck/shared_target_dir/"); + let mut args = vec!["--", "--message-format=json", "--", "--cap-lints=warn"]; + + if let Some(options) = &self.options { + for opt in options { + args.push(opt); + } + } else { + args.extend(&["-Wclippy::pedantic", "-Wclippy::cargo"]) + } + let all_output = std::process::Command::new(&cargo_clippy_path) .env("CARGO_TARGET_DIR", shared_target_dir) // lint warnings will look like this: // src/cargo/ops/cargo_compile.rs:127:35: warning: usage of `FromIterator::from_iter` - .args(&[ - "--", - "--message-format=json", - "--", - "--cap-lints=warn", - "-Wclippy::pedantic", - "-Wclippy::cargo", - ]) + .args(&args) .current_dir(&self.path) .output() .unwrap_or_else(|error| { @@ -289,6 +315,7 @@ fn read_crates(toml_path: Option<&str>) -> (String, Vec) { crate_sources.push(CrateSource::Path { name: tk.name.clone(), path: PathBuf::from(path), + options: tk.options.clone(), }); } @@ -298,6 +325,7 @@ fn read_crates(toml_path: Option<&str>) -> (String, Vec) { crate_sources.push(CrateSource::CratesIo { name: tk.name.clone(), version: ver.to_string(), + options: tk.options.clone(), }); }) } @@ -307,6 +335,7 @@ fn read_crates(toml_path: Option<&str>) -> (String, Vec) { name: tk.name.clone(), url: tk.git_url.clone().unwrap(), commit: tk.git_hash.clone().unwrap(), + options: tk.options.clone(), }); } // if we have a version as well as a git data OR only one git data, something is funky -- cgit 1.4.1-3-g733a5 From dd5c9b7ddaadfe8aaceade8b0e6ec3424e550371 Mon Sep 17 00:00:00 2001 From: flip1995 Date: Tue, 16 Feb 2021 16:58:00 +0100 Subject: lintcheck: Slight improvements to the error reporting --- clippy_dev/src/lintcheck.rs | 13 ++++++++++--- 1 file changed, 10 insertions(+), 3 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lintcheck.rs b/clippy_dev/src/lintcheck.rs index b62784da548..cd3dd8143d5 100644 --- a/clippy_dev/src/lintcheck.rs +++ b/clippy_dev/src/lintcheck.rs @@ -283,10 +283,14 @@ fn filter_clippy_warnings(line: &str) -> bool { /// Builds clippy inside the repo to make sure we have a clippy executable we can use. fn build_clippy() { - Command::new("cargo") + let output = Command::new("cargo") .arg("build") .output() .expect("Failed to build clippy!"); + if !output.status.success() { + eprintln!("Failed to compile Clippy"); + eprintln!("stderr: {}", String::from_utf8_lossy(&output.stderr)) + } } /// Read a `toml` file and return a list of `CrateSources` that we want to check with clippy @@ -402,12 +406,14 @@ fn gather_stats(clippy_warnings: &[ClippyWarning]) -> String { /// lintchecks `main()` function pub fn run(clap_config: &ArgMatches) { - let cargo_clippy_path: PathBuf = PathBuf::from("target/debug/cargo-clippy"); - println!("Compiling clippy..."); build_clippy(); println!("Done compiling"); + let cargo_clippy_path: PathBuf = PathBuf::from("target/debug/cargo-clippy") + .canonicalize() + .expect("failed to canonicalize path to clippy binary"); + // assert that clippy is found assert!( cargo_clippy_path.is_file(), @@ -484,5 +490,6 @@ pub fn run(clap_config: &ArgMatches) { .for_each(|(cratename, msg)| text.push_str(&format!("{}: '{}'", cratename, msg))); let file = format!("lintcheck-logs/{}_logs.txt", filename); + println!("Writing logs to {}", file); write(file, text).unwrap(); } -- cgit 1.4.1-3-g733a5 From 90d3275b4507b3c4670e51df2e501ae6320b4191 Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Thu, 18 Feb 2021 19:09:12 +0100 Subject: lintcheck: parallelize Use rayon to figure out the threadcount and half that for core count. For each core, create a target dir that is used. Otherwise, when running multiple clippys with the same target-dir, cargo would lock the dir and prevent parallelism. This way we can run multiple clippys at the same time (on root crates) but we sacrifice cache-hits (when we already cargo-checked crate-deps). --- clippy_dev/Cargo.toml | 3 ++- clippy_dev/src/lintcheck.rs | 38 ++++++++++++++++++++++++++------ lintcheck-logs/lintcheck_crates_logs.txt | 2 +- 3 files changed, 34 insertions(+), 9 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/Cargo.toml b/clippy_dev/Cargo.toml index 5ac96e2210c..ebf157b80ac 100644 --- a/clippy_dev/Cargo.toml +++ b/clippy_dev/Cargo.toml @@ -19,8 +19,9 @@ shell-escape = "0.1" tar = { version = "0.4.30", optional = true } toml = { version = "0.5", optional = true } ureq = { version = "2.0.0-rc3", optional = true } +rayon = { version = "1.5.0", optional = true } walkdir = "2" [features] -lintcheck = ["flate2", "serde_json", "tar", "toml", "ureq", "serde", "fs_extra"] +lintcheck = ["flate2", "serde_json", "tar", "toml", "ureq", "serde", "fs_extra", "rayon"] deny-warnings = [] diff --git a/clippy_dev/src/lintcheck.rs b/clippy_dev/src/lintcheck.rs index cd3dd8143d5..92cb43079f8 100644 --- a/clippy_dev/src/lintcheck.rs +++ b/clippy_dev/src/lintcheck.rs @@ -11,9 +11,11 @@ use crate::clippy_project_root; use std::collections::HashMap; use std::process::Command; +use std::sync::atomic::{AtomicUsize, Ordering}; use std::{env, fmt, fs::write, path::PathBuf}; use clap::ArgMatches; +use rayon::prelude::*; use serde::{Deserialize, Serialize}; use serde_json::Value; @@ -215,11 +217,20 @@ impl CrateSource { impl Crate { /// Run `cargo clippy` on the `Crate` and collect and return all the lint warnings that clippy /// issued - fn run_clippy_lints(&self, cargo_clippy_path: &PathBuf) -> Vec { - println!("Linting {} {}...", &self.name, &self.version); + fn run_clippy_lints( + &self, + cargo_clippy_path: &PathBuf, + target_dir_index: &AtomicUsize, + thread_limit: usize, + ) -> Vec { + // advance the atomic index by one + let idx = target_dir_index.fetch_add(1, Ordering::SeqCst); + // "loop" the index within 0..thread_limit + let idx = idx % thread_limit; + println!("Linting {} {} in target dir {:?}", &self.name, &self.version, idx); let cargo_clippy_path = std::fs::canonicalize(cargo_clippy_path).unwrap(); - let shared_target_dir = clippy_project_root().join("target/lintcheck/shared_target_dir/"); + let shared_target_dir = clippy_project_root().join("target/lintcheck/shared_target_dir"); let mut args = vec!["--", "--message-format=json", "--", "--cap-lints=warn"]; @@ -232,7 +243,8 @@ impl Crate { } let all_output = std::process::Command::new(&cargo_clippy_path) - .env("CARGO_TARGET_DIR", shared_target_dir) + // use the looping index to create individual target dirs + .env("CARGO_TARGET_DIR", shared_target_dir.join(format!("_{:?}", idx))) // lint warnings will look like this: // src/cargo/ops/cargo_compile.rs:127:35: warning: usage of `FromIterator::from_iter` .args(&args) @@ -454,15 +466,27 @@ pub fn run(clap_config: &ArgMatches) { .into_iter() .map(|krate| krate.download_and_extract()) .filter(|krate| krate.name == only_one_crate) - .map(|krate| krate.run_clippy_lints(&cargo_clippy_path)) + .map(|krate| krate.run_clippy_lints(&cargo_clippy_path, &AtomicUsize::new(0), 1)) .flatten() .collect() } else { + let counter = std::sync::atomic::AtomicUsize::new(0); + + // Ask rayon for cpu (actually thread)count. + // Use one target dir for each cpu so that we can run N clippys in parallel. + // We need to use different target dirs because cargo would lock them for a single build otherwise, + // killing the parallelism. However this also means that deps will only be reused half/a + // quarter of the time which might result in a longer wall clock runtime + + // Rayon seems to return thread count so half that for core count + + let num_threads: usize = rayon::current_num_threads() / 2; + // check all crates (default) crates - .into_iter() + .into_par_iter() .map(|krate| krate.download_and_extract()) - .map(|krate| krate.run_clippy_lints(&cargo_clippy_path)) + .map(|krate| krate.run_clippy_lints(&cargo_clippy_path, &counter, num_threads)) .flatten() .collect() }; diff --git a/lintcheck-logs/lintcheck_crates_logs.txt b/lintcheck-logs/lintcheck_crates_logs.txt index c8cb46c8594..b8618256c89 100644 --- a/lintcheck-logs/lintcheck_crates_logs.txt +++ b/lintcheck-logs/lintcheck_crates_logs.txt @@ -1,4 +1,4 @@ -clippy 0.1.52 (bed115d55 2021-02-15) +clippy 0.1.52 (2f815ecd0 2021-02-18) cargo-0.49.0/build.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.categories` metadata" cargo-0.49.0/build.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.keywords` metadata" -- cgit 1.4.1-3-g733a5 From bb5f9d18a070a8bf6a4f4cb3188dace1316390ff Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Fri, 19 Feb 2021 21:48:52 +0100 Subject: lintcheck: tweak some comments --- clippy_dev/src/lintcheck.rs | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lintcheck.rs b/clippy_dev/src/lintcheck.rs index 92cb43079f8..4df7017b4e6 100644 --- a/clippy_dev/src/lintcheck.rs +++ b/clippy_dev/src/lintcheck.rs @@ -472,21 +472,23 @@ pub fn run(clap_config: &ArgMatches) { } else { let counter = std::sync::atomic::AtomicUsize::new(0); - // Ask rayon for cpu (actually thread)count. - // Use one target dir for each cpu so that we can run N clippys in parallel. + // Ask rayon for thread count. Assume that half of that is the number of physical cores + // Use one target dir for each core so that we can run N clippys in parallel. // We need to use different target dirs because cargo would lock them for a single build otherwise, // killing the parallelism. However this also means that deps will only be reused half/a // quarter of the time which might result in a longer wall clock runtime - // Rayon seems to return thread count so half that for core count + // This helps when we check many small crates with dep-trees that don't have a lot of branches in + // order to achive some kind of parallelism - let num_threads: usize = rayon::current_num_threads() / 2; + // Rayon seems to return thread count so half that for core count + let num_cpus: usize = rayon::current_num_threads() / 2; // check all crates (default) crates .into_par_iter() .map(|krate| krate.download_and_extract()) - .map(|krate| krate.run_clippy_lints(&cargo_clippy_path, &counter, num_threads)) + .map(|krate| krate.run_clippy_lints(&cargo_clippy_path, &counter, num_cpus)) .flatten() .collect() }; -- cgit 1.4.1-3-g733a5 From d19855131187d535488f01374e963f9b9394e8ad Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Fri, 19 Feb 2021 21:52:34 +0100 Subject: lintheck: show output (and compiler errors!) when compiling clippy for lintcheck --- clippy_dev/src/lintcheck.rs | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lintcheck.rs b/clippy_dev/src/lintcheck.rs index 4df7017b4e6..a228bc434cc 100644 --- a/clippy_dev/src/lintcheck.rs +++ b/clippy_dev/src/lintcheck.rs @@ -295,13 +295,13 @@ fn filter_clippy_warnings(line: &str) -> bool { /// Builds clippy inside the repo to make sure we have a clippy executable we can use. fn build_clippy() { - let output = Command::new("cargo") + let status = Command::new("cargo") .arg("build") - .output() + .status() .expect("Failed to build clippy!"); - if !output.status.success() { - eprintln!("Failed to compile Clippy"); - eprintln!("stderr: {}", String::from_utf8_lossy(&output.stderr)) + if !status.success() { + eprintln!("Error: Failed to compile Clippy!"); + std::process::exit(1); } } -- cgit 1.4.1-3-g733a5 From 4974734a24fb25eca67c571e1a19c0d1285c2d47 Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Fri, 19 Feb 2021 22:06:50 +0100 Subject: lintcheck: show progress percentage in the "Linting..." message --- clippy_dev/src/lintcheck.rs | 22 ++++++++++++++++------ lintcheck-logs/lintcheck_crates_logs.txt | 2 +- 2 files changed, 17 insertions(+), 7 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lintcheck.rs b/clippy_dev/src/lintcheck.rs index a228bc434cc..54b543f6f72 100644 --- a/clippy_dev/src/lintcheck.rs +++ b/clippy_dev/src/lintcheck.rs @@ -222,12 +222,17 @@ impl Crate { cargo_clippy_path: &PathBuf, target_dir_index: &AtomicUsize, thread_limit: usize, + total_crates_to_lint: usize, ) -> Vec { // advance the atomic index by one - let idx = target_dir_index.fetch_add(1, Ordering::SeqCst); + let index = target_dir_index.fetch_add(1, Ordering::SeqCst); // "loop" the index within 0..thread_limit - let idx = idx % thread_limit; - println!("Linting {} {} in target dir {:?}", &self.name, &self.version, idx); + let target_dir_index = index % thread_limit; + let perc = ((index * 100) as f32 / total_crates_to_lint as f32) as u8; + println!( + "{}/{} {}% Linting {} {} in target dir {:?}", + index, total_crates_to_lint, perc, &self.name, &self.version, target_dir_index + ); let cargo_clippy_path = std::fs::canonicalize(cargo_clippy_path).unwrap(); let shared_target_dir = clippy_project_root().join("target/lintcheck/shared_target_dir"); @@ -244,7 +249,10 @@ impl Crate { let all_output = std::process::Command::new(&cargo_clippy_path) // use the looping index to create individual target dirs - .env("CARGO_TARGET_DIR", shared_target_dir.join(format!("_{:?}", idx))) + .env( + "CARGO_TARGET_DIR", + shared_target_dir.join(format!("_{:?}", target_dir_index)), + ) // lint warnings will look like this: // src/cargo/ops/cargo_compile.rs:127:35: warning: usage of `FromIterator::from_iter` .args(&args) @@ -466,7 +474,7 @@ pub fn run(clap_config: &ArgMatches) { .into_iter() .map(|krate| krate.download_and_extract()) .filter(|krate| krate.name == only_one_crate) - .map(|krate| krate.run_clippy_lints(&cargo_clippy_path, &AtomicUsize::new(0), 1)) + .map(|krate| krate.run_clippy_lints(&cargo_clippy_path, &AtomicUsize::new(0), 1, 1)) .flatten() .collect() } else { @@ -484,11 +492,13 @@ pub fn run(clap_config: &ArgMatches) { // Rayon seems to return thread count so half that for core count let num_cpus: usize = rayon::current_num_threads() / 2; + let num_crates = crates.len(); + // check all crates (default) crates .into_par_iter() .map(|krate| krate.download_and_extract()) - .map(|krate| krate.run_clippy_lints(&cargo_clippy_path, &counter, num_cpus)) + .map(|krate| krate.run_clippy_lints(&cargo_clippy_path, &counter, num_cpus, num_crates)) .flatten() .collect() }; diff --git a/lintcheck-logs/lintcheck_crates_logs.txt b/lintcheck-logs/lintcheck_crates_logs.txt index b8618256c89..6fc4e26f7a6 100644 --- a/lintcheck-logs/lintcheck_crates_logs.txt +++ b/lintcheck-logs/lintcheck_crates_logs.txt @@ -1,4 +1,4 @@ -clippy 0.1.52 (2f815ecd0 2021-02-18) +clippy 0.1.52 (bb5f9d18a 2021-02-19) cargo-0.49.0/build.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.categories` metadata" cargo-0.49.0/build.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.keywords` metadata" -- cgit 1.4.1-3-g733a5 From 22aeec09e4375268ff9cbd7057d3b57aac47a2c5 Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Fri, 19 Feb 2021 22:16:53 +0100 Subject: lintcheck: sort crates before linting --- clippy_dev/src/lintcheck.rs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lintcheck.rs b/clippy_dev/src/lintcheck.rs index 54b543f6f72..fe2614e2de7 100644 --- a/clippy_dev/src/lintcheck.rs +++ b/clippy_dev/src/lintcheck.rs @@ -39,7 +39,7 @@ struct TomlCrate { /// Represents an archive we download from crates.io, or a git repo, or a local repo/folder /// Once processed (downloaded/extracted/cloned/copied...), this will be translated into a `Crate` -#[derive(Debug, Serialize, Deserialize, Eq, Hash, PartialEq)] +#[derive(Debug, Serialize, Deserialize, Eq, Hash, PartialEq, Ord, PartialOrd)] enum CrateSource { CratesIo { name: String, @@ -376,6 +376,9 @@ fn read_crates(toml_path: Option<&str>) -> (String, Vec) { unreachable!("Failed to translate TomlCrate into CrateSource!"); } }); + // sort the crates + crate_sources.sort(); + (toml_filename, crate_sources) } -- cgit 1.4.1-3-g733a5 From 8499a32859280e3f29a2b000450bcec13bf80b9c Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Fri, 19 Feb 2021 23:20:05 +0100 Subject: lintcheck: add -j option to configure threads. defaults to 1 -j 0 choses the number of threads automtically (= number of physical cores) --- clippy_dev/src/lintcheck.rs | 36 ++++++++++++++++++++++++++++++------ clippy_dev/src/main.rs | 8 ++++++++ 2 files changed, 38 insertions(+), 6 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lintcheck.rs b/clippy_dev/src/lintcheck.rs index fe2614e2de7..d9933f0963a 100644 --- a/clippy_dev/src/lintcheck.rs +++ b/clippy_dev/src/lintcheck.rs @@ -229,10 +229,19 @@ impl Crate { // "loop" the index within 0..thread_limit let target_dir_index = index % thread_limit; let perc = ((index * 100) as f32 / total_crates_to_lint as f32) as u8; - println!( - "{}/{} {}% Linting {} {} in target dir {:?}", - index, total_crates_to_lint, perc, &self.name, &self.version, target_dir_index - ); + + if thread_limit == 1 { + println!( + "{}/{} {}% Linting {} {}", + index, total_crates_to_lint, perc, &self.name, &self.version + ); + } else { + println!( + "{}/{} {}% Linting {} {} in target dir {:?}", + index, total_crates_to_lint, perc, &self.name, &self.version, target_dir_index + ); + } + let cargo_clippy_path = std::fs::canonicalize(cargo_clippy_path).unwrap(); let shared_target_dir = clippy_project_root().join("target/lintcheck/shared_target_dir"); @@ -492,8 +501,23 @@ pub fn run(clap_config: &ArgMatches) { // This helps when we check many small crates with dep-trees that don't have a lot of branches in // order to achive some kind of parallelism - // Rayon seems to return thread count so half that for core count - let num_cpus: usize = rayon::current_num_threads() / 2; + // by default, use a single thread + let num_cpus = match clap_config.value_of("threads") { + Some(threads) => { + let threads: usize = threads + .parse() + .expect(&format!("Failed to parse '{}' to a digit", threads)); + if threads == 0 { + // automatic choice + // Rayon seems to return thread count so half that for core count + (rayon::current_num_threads() / 2) as usize + } else { + threads + } + }, + // no -j passed, use a single thread + None => 1, + }; let num_crates = crates.len(); diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index 5dbd46935a5..505d465760c 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -69,6 +69,14 @@ fn get_clap_config<'a>() -> ArgMatches<'a> { .value_name("CRATES-SOURCES-TOML-PATH") .long("crates-toml") .help("set the path for a crates.toml where lintcheck should read the sources from"), + ) + .arg( + Arg::with_name("threads") + .takes_value(true) + .value_name("N") + .short("j") + .long("jobs") + .help("number of threads to use, 0 automatic choice"), ); let app = App::new("Clippy developer tooling") -- cgit 1.4.1-3-g733a5 From 5fe3b6c41aea8df1ce98cb682d83aa05c551b670 Mon Sep 17 00:00:00 2001 From: Yoshitomo Nakanishi Date: Mon, 22 Feb 2021 12:32:41 +0900 Subject: Quick fix cargo dev bless --- clippy_dev/src/bless.rs | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/bless.rs b/clippy_dev/src/bless.rs index 2a869e9d449..c4fa0a9aca7 100644 --- a/clippy_dev/src/bless.rs +++ b/clippy_dev/src/bless.rs @@ -42,9 +42,10 @@ pub fn bless(ignore_timestamp: bool) { .for_each(|f| { let test_name = f.path().strip_prefix(test_suite_dir).unwrap(); for &ext in &["stdout", "stderr", "fixed"] { + let test_name_ext = format!("stage-id.{}", ext); update_reference_file( f.path().with_extension(ext), - test_name.with_extension(ext), + test_name.with_extension(test_name_ext), ignore_timestamp, ); } -- cgit 1.4.1-3-g733a5 From 363f6d3dc6468dab9a07348fc180ab9ffe1f3fdd Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Tue, 23 Feb 2021 00:40:50 +0100 Subject: lintcheck: rerun if clippy changed Automatically clean lintchecks shared target dir (will force clippy to recheck sources) if the clippy binaries are older than the lintcheck logs. Also update lintcheck logs --- clippy_dev/src/lintcheck.rs | 50 ++++++++++++++++++++++++++++++-- lintcheck-logs/lintcheck_crates_logs.txt | 20 ++++++++----- 2 files changed, 59 insertions(+), 11 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lintcheck.rs b/clippy_dev/src/lintcheck.rs index d9933f0963a..2a6d9315311 100644 --- a/clippy_dev/src/lintcheck.rs +++ b/clippy_dev/src/lintcheck.rs @@ -310,6 +310,14 @@ fn filter_clippy_warnings(line: &str) -> bool { false } +/// get the path to lintchecks crate sources .toml file, check LINTCHECK_TOML first but if it's +/// empty use the default path +fn lintcheck_config_toml() -> PathBuf { + PathBuf::from( + env::var("LINTCHECK_TOML").unwrap_or(toml_path.unwrap_or("clippy_dev/lintcheck_crates.toml").to_string()), + ) +} + /// Builds clippy inside the repo to make sure we have a clippy executable we can use. fn build_clippy() { let status = Command::new("cargo") @@ -324,9 +332,7 @@ fn build_clippy() { /// Read a `toml` file and return a list of `CrateSources` that we want to check with clippy fn read_crates(toml_path: Option<&str>) -> (String, Vec) { - let toml_path = PathBuf::from( - env::var("LINTCHECK_TOML").unwrap_or(toml_path.unwrap_or("clippy_dev/lintcheck_crates.toml").to_string()), - ); + let toml_path = lintcheck_config_toml(); // save it so that we can use the name of the sources.toml as name for the logfile later. let toml_filename = toml_path.file_stem().unwrap().to_str().unwrap().to_string(); let toml_content: String = @@ -436,12 +442,50 @@ fn gather_stats(clippy_warnings: &[ClippyWarning]) -> String { .collect::() } +/// check if the latest modification of the logfile is older than the modification date of the +/// clippy binary, if this is true, we should clean the lintchec shared target directory and recheck +fn lintcheck_needs_rerun() -> bool { + let clippy_modified: std::time::SystemTime = { + let mut times = ["target/debug/clippy-driver", "target/debug/cargo-clippy"] + .into_iter() + .map(|p| { + std::fs::metadata(p) + .expect("failed to get metadata of file") + .modified() + .expect("failed to get modification date") + }); + // the lates modification of either of the binaries + std::cmp::max(times.next().unwrap(), times.next().unwrap()) + }; + + let logs_modified: std::time::SystemTime = std::fs::metadata(lintcheck_config_toml()) + .expect("failed to get metadata of file") + .modified() + .expect("failed to get modification date"); + + // if clippys modification time is bigger (older) than the logs mod time, we need to rerun lintcheck + clippy_modified > logs_modified +} + /// lintchecks `main()` function pub fn run(clap_config: &ArgMatches) { println!("Compiling clippy..."); build_clippy(); println!("Done compiling"); + // if the clippy bin is newer than our logs, throw away target dirs to force clippy to + // refresh the logs + if lintcheck_needs_rerun() { + let shared_target_dir = "target/lintcheck/shared_target_dir"; + if std::fs::metadata(&shared_target_dir) + .expect("failed to get metadata of shared target dir") + .is_dir() + { + println!("Clippy is newer than lint check logs, clearing lintcheck shared target dir..."); + std::fs::remove_dir_all(&shared_target_dir).expect("failed to remove target/lintcheck/shared_target_dir"); + } + } + let cargo_clippy_path: PathBuf = PathBuf::from("target/debug/cargo-clippy") .canonicalize() .expect("failed to canonicalize path to clippy binary"); diff --git a/lintcheck-logs/lintcheck_crates_logs.txt b/lintcheck-logs/lintcheck_crates_logs.txt index 6fc4e26f7a6..c23dd926f62 100644 --- a/lintcheck-logs/lintcheck_crates_logs.txt +++ b/lintcheck-logs/lintcheck_crates_logs.txt @@ -1,4 +1,4 @@ -clippy 0.1.52 (bb5f9d18a 2021-02-19) +clippy 0.1.52 (697f3b6d4 2021-02-22) cargo-0.49.0/build.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.categories` metadata" cargo-0.49.0/build.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.keywords` metadata" @@ -102,6 +102,7 @@ cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:424:5 clippy:: cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:469:58 clippy::redundant_closure_for_method_calls "redundant closure found" cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:603:19 clippy::redundant_closure_for_method_calls "redundant closure found" cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:665:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:697:12 clippy::inconsistent_struct_constructor "inconsistent struct constructor" cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:82:31 clippy::doc_markdown "you should put `FileType` between ticks in the documentation" cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:83:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:84:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" @@ -177,7 +178,7 @@ cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:606:5 clippy::missing_error cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:688:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:756:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:762:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:762:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:762:5 clippy::unnecessary_wraps "this function's return value is unnecessary" cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:823:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1021:51 clippy::redundant_closure_for_method_calls "redundant closure found" cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1656:16 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" @@ -233,7 +234,7 @@ cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:93:24 clippy::doc_markdown "yo cargo-0.49.0/src/cargo/core/compiler/links.rs:8:1 clippy::module_name_repetitions "item name ends with its containing module's name" cargo-0.49.0/src/cargo/core/compiler/mod.rs:1016:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" cargo-0.49.0/src/cargo/core/compiler/mod.rs:1094:19 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:1131:1 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:1131:1 clippy::unnecessary_wraps "this function's return value is unnecessary" cargo-0.49.0/src/cargo/core/compiler/mod.rs:1268:34 clippy::case_sensitive_file_extension_comparisons "case-sensitive file extension comparison" cargo-0.49.0/src/cargo/core/compiler/mod.rs:1277:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" cargo-0.49.0/src/cargo/core/compiler/mod.rs:179:1 clippy::too_many_lines "this function has too many lines (162/100)" @@ -242,13 +243,13 @@ cargo-0.49.0/src/cargo/core/compiler/mod.rs:201:25 clippy::single_match_else "yo cargo-0.49.0/src/cargo/core/compiler/mod.rs:267:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" cargo-0.49.0/src/cargo/core/compiler/mod.rs:324:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" cargo-0.49.0/src/cargo/core/compiler/mod.rs:364:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:364:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:364:5 clippy::unnecessary_wraps "this function's return value is unnecessary" cargo-0.49.0/src/cargo/core/compiler/mod.rs:392:45 clippy::redundant_closure_for_method_calls "redundant closure found" cargo-0.49.0/src/cargo/core/compiler/mod.rs:415:23 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" cargo-0.49.0/src/cargo/core/compiler/mod.rs:464:18 clippy::ptr_arg "writing `&PathBuf` instead of `&Path` involves a new object where a slice will do." cargo-0.49.0/src/cargo/core/compiler/mod.rs:488:61 clippy::ptr_arg "writing `&PathBuf` instead of `&Path` involves a new object where a slice will do." cargo-0.49.0/src/cargo/core/compiler/mod.rs:667:15 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:693:1 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo-0.49.0/src/cargo/core/compiler/mod.rs:693:1 clippy::unnecessary_wraps "this function's return value is unnecessary" cargo-0.49.0/src/cargo/core/compiler/mod.rs:725:42 clippy::match_same_arms "this `match` has identical arm bodies" cargo-0.49.0/src/cargo/core/compiler/mod.rs:736:1 clippy::too_many_lines "this function has too many lines (141/100)" cargo-0.49.0/src/cargo/core/compiler/mod.rs:73:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" @@ -486,7 +487,7 @@ cargo-0.49.0/src/cargo/core/profiles.rs:1014:5 clippy::must_use_candidate "this cargo-0.49.0/src/cargo/core/profiles.rs:1018:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" cargo-0.49.0/src/cargo/core/profiles.rs:1028:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" cargo-0.49.0/src/cargo/core/profiles.rs:106:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/profiles.rs:143:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo-0.49.0/src/cargo/core/profiles.rs:143:5 clippy::unnecessary_wraps "this function's return value is unnecessary" cargo-0.49.0/src/cargo/core/profiles.rs:286:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" cargo-0.49.0/src/cargo/core/profiles.rs:286:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" cargo-0.49.0/src/cargo/core/profiles.rs:294:40 clippy::if_not_else "unnecessary boolean `not` operation" @@ -887,7 +888,7 @@ cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:233:21 clippy::si cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:244:22 clippy::doc_markdown "you should put `PackageId` between ticks in the documentation" cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:244:63 clippy::doc_markdown "you should put `PackageId` between ticks in the documentation" cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:253:17 clippy::if_not_else "unnecessary boolean `not` operation" -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:370:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:370:5 clippy::unnecessary_wraps "this function's return value is unnecessary" cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:505:8 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:525:10 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:542:27 clippy::redundant_closure_for_method_calls "redundant closure found" @@ -1321,6 +1322,7 @@ cargo-0.49.0/src/cargo/util/process_builder.rs:185:5 clippy::missing_errors_doc cargo-0.49.0/src/cargo/util/process_builder.rs:190:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" cargo-0.49.0/src/cargo/util/process_builder.rs:218:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" cargo-0.49.0/src/cargo/util/process_builder.rs:218:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/util/process_builder.rs:278:22 clippy::inconsistent_struct_constructor "inconsistent struct constructor" cargo-0.49.0/src/cargo/util/process_builder.rs:307:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" cargo-0.49.0/src/cargo/util/process_builder.rs:343:39 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" cargo-0.49.0/src/cargo/util/progress.rs:122:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" @@ -2392,6 +2394,7 @@ rayon-1.5.0/src/iter/chain.rs:58:17 clippy::shadow_unrelated "`b` is being shado rayon-1.5.0/src/iter/chain.rs:78:14 clippy::shadow_unrelated "`a` is being shadowed" rayon-1.5.0/src/iter/chain.rs:78:17 clippy::shadow_unrelated "`b` is being shadowed" rayon-1.5.0/src/iter/chain.rs:97:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +rayon-1.5.0/src/iter/chunks.rs:29:9 clippy::inconsistent_struct_constructor "inconsistent struct constructor" rayon-1.5.0/src/iter/chunks.rs:3:5 clippy::wildcard_imports "usage of wildcard import" rayon-1.5.0/src/iter/chunks.rs:4:5 clippy::wildcard_imports "usage of wildcard import" rayon-1.5.0/src/iter/chunks.rs:77:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" @@ -3279,7 +3282,7 @@ xsv-0.13.0/src/cmd/sort.rs:48:9 clippy::similar_names "binding's name is too sim xsv-0.13.0/src/cmd/sort.rs:91:14 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" xsv-0.13.0/src/cmd/split.rs:14:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" xsv-0.13.0/src/cmd/split.rs:61:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/split.rs:94:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +xsv-0.13.0/src/cmd/split.rs:94:5 clippy::unnecessary_wraps "this function's return value is unnecessary" xsv-0.13.0/src/cmd/split.rs:96:14 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" xsv-0.13.0/src/cmd/split.rs:99:13 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" xsv-0.13.0/src/cmd/stats.rs:110:36 clippy::redundant_closure_for_method_calls "redundant closure found" @@ -3416,6 +3419,7 @@ clippy::write_with_newline 2 clippy::filter_map_next 3 clippy::fn_params_excessive_bools 3 clippy::if_same_then_else 3 +clippy::inconsistent_struct_constructor 3 clippy::mut_mut 3 clippy::ptr_arg 3 clippy::zero_ptr 3 -- cgit 1.4.1-3-g733a5 From eaae95b613c9b466b98a13d7af474597cc0e62b1 Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Tue, 23 Feb 2021 12:58:12 +0100 Subject: lintcheck fix build (forgot to pass function parameter) and runtime (don't check metadata of directory if it does not exist) --- clippy_dev/src/lintcheck.rs | 39 +++++++++++++++++++++++++-------------- 1 file changed, 25 insertions(+), 14 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lintcheck.rs b/clippy_dev/src/lintcheck.rs index 2a6d9315311..b806f545284 100644 --- a/clippy_dev/src/lintcheck.rs +++ b/clippy_dev/src/lintcheck.rs @@ -312,9 +312,14 @@ fn filter_clippy_warnings(line: &str) -> bool { /// get the path to lintchecks crate sources .toml file, check LINTCHECK_TOML first but if it's /// empty use the default path -fn lintcheck_config_toml() -> PathBuf { +fn lintcheck_config_toml(toml_path: Option<&str>) -> PathBuf { PathBuf::from( - env::var("LINTCHECK_TOML").unwrap_or(toml_path.unwrap_or("clippy_dev/lintcheck_crates.toml").to_string()), + env::var("LINTCHECK_TOML").unwrap_or( + toml_path + .clone() + .unwrap_or("clippy_dev/lintcheck_crates.toml") + .to_string(), + ), ) } @@ -332,7 +337,7 @@ fn build_clippy() { /// Read a `toml` file and return a list of `CrateSources` that we want to check with clippy fn read_crates(toml_path: Option<&str>) -> (String, Vec) { - let toml_path = lintcheck_config_toml(); + let toml_path = lintcheck_config_toml(toml_path); // save it so that we can use the name of the sources.toml as name for the logfile later. let toml_filename = toml_path.file_stem().unwrap().to_str().unwrap().to_string(); let toml_content: String = @@ -444,10 +449,10 @@ fn gather_stats(clippy_warnings: &[ClippyWarning]) -> String { /// check if the latest modification of the logfile is older than the modification date of the /// clippy binary, if this is true, we should clean the lintchec shared target directory and recheck -fn lintcheck_needs_rerun() -> bool { +fn lintcheck_needs_rerun(toml_path: Option<&str>) -> bool { let clippy_modified: std::time::SystemTime = { let mut times = ["target/debug/clippy-driver", "target/debug/cargo-clippy"] - .into_iter() + .iter() .map(|p| { std::fs::metadata(p) .expect("failed to get metadata of file") @@ -458,7 +463,7 @@ fn lintcheck_needs_rerun() -> bool { std::cmp::max(times.next().unwrap(), times.next().unwrap()) }; - let logs_modified: std::time::SystemTime = std::fs::metadata(lintcheck_config_toml()) + let logs_modified: std::time::SystemTime = std::fs::metadata(lintcheck_config_toml(toml_path)) .expect("failed to get metadata of file") .modified() .expect("failed to get modification date"); @@ -473,16 +478,22 @@ pub fn run(clap_config: &ArgMatches) { build_clippy(); println!("Done compiling"); + let clap_toml_path = clap_config.value_of("crates-toml"); + // if the clippy bin is newer than our logs, throw away target dirs to force clippy to // refresh the logs - if lintcheck_needs_rerun() { + if lintcheck_needs_rerun(clap_toml_path) { let shared_target_dir = "target/lintcheck/shared_target_dir"; - if std::fs::metadata(&shared_target_dir) - .expect("failed to get metadata of shared target dir") - .is_dir() - { - println!("Clippy is newer than lint check logs, clearing lintcheck shared target dir..."); - std::fs::remove_dir_all(&shared_target_dir).expect("failed to remove target/lintcheck/shared_target_dir"); + match std::fs::metadata(&shared_target_dir) { + Ok(metadata) => { + if metadata.is_dir() { + println!("Clippy is newer than lint check logs, clearing lintcheck shared target dir..."); + std::fs::remove_dir_all(&shared_target_dir) + .expect("failed to remove target/lintcheck/shared_target_dir"); + } + }, + Err(_) => { // dir probably does not exist, don't remove anything + }, } } @@ -506,7 +517,7 @@ pub fn run(clap_config: &ArgMatches) { // download and extract the crates, then run clippy on them and collect clippys warnings // flatten into one big list of warnings - let (filename, crates) = read_crates(clap_config.value_of("crates-toml")); + let (filename, crates) = read_crates(clap_toml_path); let clippy_warnings: Vec = if let Some(only_one_crate) = clap_config.value_of("only") { // if we don't have the specified crate in the .toml, throw an error -- cgit 1.4.1-3-g733a5 From 12dc03033f9d441f1382a7684480c4a863b33bb8 Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Tue, 23 Feb 2021 21:27:32 +0100 Subject: lintcheck: fix bug when getting the config toml path. In order to check if we need to recheck crates, I was getting the path from clap only which is None if we don't pass it via cmdline args. Use the dedicated lintcheck_config_toml() fnuction instead! --- clippy_dev/src/lintcheck.rs | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lintcheck.rs b/clippy_dev/src/lintcheck.rs index b806f545284..a4e6fe76c32 100644 --- a/clippy_dev/src/lintcheck.rs +++ b/clippy_dev/src/lintcheck.rs @@ -336,8 +336,8 @@ fn build_clippy() { } /// Read a `toml` file and return a list of `CrateSources` that we want to check with clippy -fn read_crates(toml_path: Option<&str>) -> (String, Vec) { - let toml_path = lintcheck_config_toml(toml_path); +fn read_crates(clap_toml_path: Option<&str>) -> (String, Vec) { + let toml_path = lintcheck_config_toml(clap_toml_path); // save it so that we can use the name of the sources.toml as name for the logfile later. let toml_filename = toml_path.file_stem().unwrap().to_str().unwrap().to_string(); let toml_content: String = @@ -478,7 +478,8 @@ pub fn run(clap_config: &ArgMatches) { build_clippy(); println!("Done compiling"); - let clap_toml_path = clap_config.value_of("crates-toml"); + let clap_toml_path: Option<&str> = clap_config.value_of("crates-toml"); + let toml_path = lintcheck_config_toml(clap_toml_path); // if the clippy bin is newer than our logs, throw away target dirs to force clippy to // refresh the logs -- cgit 1.4.1-3-g733a5 From 3e1eea6c97ea71c43ebde4a171e5085947634155 Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Tue, 23 Feb 2021 21:23:36 +0100 Subject: lintcheck: print stats how lint counts have changed between runs --- clippy_dev/src/lintcheck.rs | 118 +++++++++++++++++++++++++++++++++++++------- 1 file changed, 100 insertions(+), 18 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lintcheck.rs b/clippy_dev/src/lintcheck.rs index a4e6fe76c32..601e88387b9 100644 --- a/clippy_dev/src/lintcheck.rs +++ b/clippy_dev/src/lintcheck.rs @@ -336,8 +336,7 @@ fn build_clippy() { } /// Read a `toml` file and return a list of `CrateSources` that we want to check with clippy -fn read_crates(clap_toml_path: Option<&str>) -> (String, Vec) { - let toml_path = lintcheck_config_toml(clap_toml_path); +fn read_crates(toml_path: &PathBuf) -> (String, Vec) { // save it so that we can use the name of the sources.toml as name for the logfile later. let toml_filename = toml_path.file_stem().unwrap().to_str().unwrap().to_string(); let toml_content: String = @@ -428,7 +427,7 @@ fn parse_json_message(json_message: &str, krate: &Crate) -> ClippyWarning { } /// Generate a short list of occuring lints-types and their count -fn gather_stats(clippy_warnings: &[ClippyWarning]) -> String { +fn gather_stats(clippy_warnings: &[ClippyWarning]) -> (String, HashMap<&String, usize>) { // count lint type occurrences let mut counter: HashMap<&String, usize> = HashMap::new(); clippy_warnings @@ -441,15 +440,17 @@ fn gather_stats(clippy_warnings: &[ClippyWarning]) -> String { // to not have a lint with 200 and 2 warnings take the same spot stats.sort_by_key(|(lint, count)| format!("{:0>4}, {}", count, lint)); - stats + let stats_string = stats .iter() .map(|(lint, count)| format!("{} {}\n", lint, count)) - .collect::() + .collect::(); + + (stats_string, counter) } /// check if the latest modification of the logfile is older than the modification date of the /// clippy binary, if this is true, we should clean the lintchec shared target directory and recheck -fn lintcheck_needs_rerun(toml_path: Option<&str>) -> bool { +fn lintcheck_needs_rerun(toml_path: &PathBuf) -> bool { let clippy_modified: std::time::SystemTime = { let mut times = ["target/debug/clippy-driver", "target/debug/cargo-clippy"] .iter() @@ -459,17 +460,18 @@ fn lintcheck_needs_rerun(toml_path: Option<&str>) -> bool { .modified() .expect("failed to get modification date") }); - // the lates modification of either of the binaries - std::cmp::max(times.next().unwrap(), times.next().unwrap()) + // the oldest modification of either of the binaries + std::cmp::min(times.next().unwrap(), times.next().unwrap()) }; - let logs_modified: std::time::SystemTime = std::fs::metadata(lintcheck_config_toml(toml_path)) + let logs_modified: std::time::SystemTime = std::fs::metadata(toml_path) .expect("failed to get metadata of file") .modified() .expect("failed to get modification date"); - // if clippys modification time is bigger (older) than the logs mod time, we need to rerun lintcheck - clippy_modified > logs_modified + // if clippys modification time is smaller (older) than the logs mod time, we need to rerun + // lintcheck + dbg!(clippy_modified < logs_modified) } /// lintchecks `main()` function @@ -479,11 +481,11 @@ pub fn run(clap_config: &ArgMatches) { println!("Done compiling"); let clap_toml_path: Option<&str> = clap_config.value_of("crates-toml"); - let toml_path = lintcheck_config_toml(clap_toml_path); + let toml_path: PathBuf = lintcheck_config_toml(clap_toml_path); // if the clippy bin is newer than our logs, throw away target dirs to force clippy to // refresh the logs - if lintcheck_needs_rerun(clap_toml_path) { + if dbg!(lintcheck_needs_rerun(&toml_path)) { let shared_target_dir = "target/lintcheck/shared_target_dir"; match std::fs::metadata(&shared_target_dir) { Ok(metadata) => { @@ -518,7 +520,9 @@ pub fn run(clap_config: &ArgMatches) { // download and extract the crates, then run clippy on them and collect clippys warnings // flatten into one big list of warnings - let (filename, crates) = read_crates(clap_toml_path); + let (filename, crates) = read_crates(&toml_path); + let file = format!("lintcheck-logs/{}_logs.txt", filename); + let old_stats = read_stats_from_file(&file); let clippy_warnings: Vec = if let Some(only_one_crate) = clap_config.value_of("only") { // if we don't have the specified crate in the .toml, throw an error @@ -587,7 +591,7 @@ pub fn run(clap_config: &ArgMatches) { }; // generate some stats - let stats_formatted = gather_stats(&clippy_warnings); + let (stats_formatted, new_stats) = gather_stats(&clippy_warnings); // grab crashes/ICEs, save the crate name and the ice message let ices: Vec<(&String, &String)> = clippy_warnings @@ -598,7 +602,7 @@ pub fn run(clap_config: &ArgMatches) { let mut all_msgs: Vec = clippy_warnings.iter().map(|warning| warning.to_string()).collect(); all_msgs.sort(); - all_msgs.push("\n\n\n\nStats\n\n".into()); + all_msgs.push("\n\n\n\nStats:\n".into()); all_msgs.push(stats_formatted); // save the text into lintcheck-logs/logs.txt @@ -608,7 +612,85 @@ pub fn run(clap_config: &ArgMatches) { ices.iter() .for_each(|(cratename, msg)| text.push_str(&format!("{}: '{}'", cratename, msg))); - let file = format!("lintcheck-logs/{}_logs.txt", filename); println!("Writing logs to {}", file); - write(file, text).unwrap(); + write(&file, text).unwrap(); + + print_stats(old_stats, new_stats); +} + +/// read the previous stats from the lintcheck-log file +fn read_stats_from_file(file_path: &String) -> HashMap { + let file_path = PathBuf::from(file_path); + dbg!(&file_path); + let file_content: String = match std::fs::read_to_string(file_path).ok() { + Some(content) => content, + None => { + eprintln!("RETURND"); + return HashMap::new(); + }, + }; + + let lines: Vec = file_content.lines().map(|l| l.to_string()).collect(); + + // search for the beginning "Stats:" and the end "ICEs:" of the section we want + let start = lines.iter().position(|line| line == "Stats:").unwrap(); + let end = lines.iter().position(|line| line == "ICEs:").unwrap(); + + let stats_lines = &lines[start + 1..=end - 1]; + + stats_lines + .into_iter() + .map(|line| { + let mut spl = line.split(" ").into_iter(); + ( + spl.next().unwrap().to_string(), + spl.next().unwrap().parse::().unwrap(), + ) + }) + .collect::>() +} + +/// print how lint counts changed between runs +fn print_stats(old_stats: HashMap, new_stats: HashMap<&String, usize>) { + let same_in_both_hashmaps = old_stats + .iter() + .filter(|(old_key, old_val)| new_stats.get::<&String>(&old_key) == Some(old_val)) + .map(|(k, v)| (k.to_string(), *v)) + .collect::>(); + + let mut old_stats_deduped = old_stats; + let mut new_stats_deduped = new_stats; + + // remove duplicates from both hashmaps + same_in_both_hashmaps.iter().for_each(|(k, v)| { + assert!(old_stats_deduped.remove(k) == Some(*v)); + assert!(new_stats_deduped.remove(k) == Some(*v)); + }); + + println!("\nStats:"); + + // list all new counts (key is in new stats but not in old stats) + new_stats_deduped + .iter() + .filter(|(new_key, _)| old_stats_deduped.get::(&new_key).is_none()) + .for_each(|(new_key, new_value)| { + println!("{} 0 => {}", new_key, new_value); + }); + + // list all changed counts (key is in both maps but value differs) + new_stats_deduped + .iter() + .filter(|(new_key, _new_val)| old_stats_deduped.get::(&new_key).is_some()) + .for_each(|(new_key, new_val)| { + let old_val = old_stats_deduped.get::(&new_key).unwrap(); + println!("{} {} => {}", new_key, old_val, new_val); + }); + + // list all gone counts (key is in old status but not in new stats) + old_stats_deduped + .iter() + .filter(|(old_key, _)| new_stats_deduped.get::<&String>(&old_key).is_none()) + .for_each(|(old_key, old_value)| { + println!("{} {} => 0", old_key, old_value); + }); } -- cgit 1.4.1-3-g733a5 From 90cf27e9f6f4573ff1938744e87dab9f413002a1 Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Fri, 26 Feb 2021 11:18:59 +0100 Subject: lintcheck: update logs and do minor fixes --- clippy_dev/src/lintcheck.rs | 5 ++--- lintcheck-logs/lintcheck_crates_logs.txt | 36 +++++++++++++++----------------- 2 files changed, 19 insertions(+), 22 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lintcheck.rs b/clippy_dev/src/lintcheck.rs index 601e88387b9..65e438bc0e8 100644 --- a/clippy_dev/src/lintcheck.rs +++ b/clippy_dev/src/lintcheck.rs @@ -471,7 +471,7 @@ fn lintcheck_needs_rerun(toml_path: &PathBuf) -> bool { // if clippys modification time is smaller (older) than the logs mod time, we need to rerun // lintcheck - dbg!(clippy_modified < logs_modified) + clippy_modified < logs_modified } /// lintchecks `main()` function @@ -485,7 +485,7 @@ pub fn run(clap_config: &ArgMatches) { // if the clippy bin is newer than our logs, throw away target dirs to force clippy to // refresh the logs - if dbg!(lintcheck_needs_rerun(&toml_path)) { + if lintcheck_needs_rerun(&toml_path) { let shared_target_dir = "target/lintcheck/shared_target_dir"; match std::fs::metadata(&shared_target_dir) { Ok(metadata) => { @@ -621,7 +621,6 @@ pub fn run(clap_config: &ArgMatches) { /// read the previous stats from the lintcheck-log file fn read_stats_from_file(file_path: &String) -> HashMap { let file_path = PathBuf::from(file_path); - dbg!(&file_path); let file_content: String = match std::fs::read_to_string(file_path).ok() { Some(content) => content, None => { diff --git a/lintcheck-logs/lintcheck_crates_logs.txt b/lintcheck-logs/lintcheck_crates_logs.txt index c23dd926f62..e3aeb76657f 100644 --- a/lintcheck-logs/lintcheck_crates_logs.txt +++ b/lintcheck-logs/lintcheck_crates_logs.txt @@ -1,4 +1,4 @@ -clippy 0.1.52 (697f3b6d4 2021-02-22) +clippy 0.1.52 (5c6cd87b9 2021-02-25) cargo-0.49.0/build.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.categories` metadata" cargo-0.49.0/build.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.keywords` metadata" @@ -77,6 +77,7 @@ cargo-0.49.0/src/bin/cargo/main.rs:1:null clippy::multiple_crate_versions "multi cargo-0.49.0/src/bin/cargo/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `hex`: 0.3.2, 0.4.0" cargo-0.49.0/src/bin/cargo/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `humantime`: 1.3.0, 2.0.0" cargo-0.49.0/src/bin/cargo/main.rs:72:22 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/bin/cargo/main.rs:79:40 clippy::manual_map "manual implementation of `Option::map`" cargo-0.49.0/src/bin/cargo/main.rs:94:13 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" cargo-0.49.0/src/bin/cargo/main.rs:96:41 clippy::redundant_closure_for_method_calls "redundant closure found" cargo-0.49.0/src/bin/cargo/main.rs:98:60 clippy::redundant_closure_for_method_calls "redundant closure found" @@ -199,6 +200,7 @@ cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1966:22 clippy::cast_possibl cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1980:17 clippy::similar_names "binding's name is too similar to existing binding" cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1980:24 clippy::manual_strip "stripping a prefix manually" cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1986:17 clippy::similar_names "binding's name is too similar to existing binding" +cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1986:27 clippy::manual_map "manual implementation of `Option::map`" cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:2016:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:61:5 clippy::doc_markdown "you should put `CompileMode` between ticks in the documentation" cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:63:12 clippy::doc_markdown "you should put `CompileKind` between ticks in the documentation" @@ -480,6 +482,7 @@ cargo-0.49.0/src/cargo/core/package_id_spec.rs:212:9 clippy::items_after_stateme cargo-0.49.0/src/cargo/core/package_id_spec.rs:231:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" cargo-0.49.0/src/cargo/core/package_id_spec.rs:51:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" cargo-0.49.0/src/cargo/core/package_id_spec.rs:51:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +cargo-0.49.0/src/cargo/core/package_id_spec.rs:64:23 clippy::manual_map "manual implementation of `Option::map`" cargo-0.49.0/src/cargo/core/package_id_spec.rs:77:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" cargo-0.49.0/src/cargo/core/package_id_spec.rs:88:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" cargo-0.49.0/src/cargo/core/profiles.rs:1004:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" @@ -757,6 +760,7 @@ cargo-0.49.0/src/cargo/core/workspace.rs:329:37 clippy::doc_markdown "you should cargo-0.49.0/src/cargo/core/workspace.rs:410:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" cargo-0.49.0/src/cargo/core/workspace.rs:440:9 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" cargo-0.49.0/src/cargo/core/workspace.rs:511:32 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +cargo-0.49.0/src/cargo/core/workspace.rs:531:13 clippy::manual_map "manual implementation of `Option::map`" cargo-0.49.0/src/cargo/core/workspace.rs:561:25 clippy::non_ascii_literal "literal non-ASCII character detected" cargo-0.49.0/src/cargo/core/workspace.rs:613:13 clippy::filter_map "called `filter_map(..).map(..)` on an `Iterator`" cargo-0.49.0/src/cargo/core/workspace.rs:615:22 clippy::redundant_closure_for_method_calls "redundant closure found" @@ -1001,6 +1005,7 @@ cargo-0.49.0/src/cargo/sources/directory.rs:14:1 clippy::module_name_repetitions cargo-0.49.0/src/cargo/sources/directory.rs:90:56 clippy::redundant_closure_for_method_calls "redundant closure found" cargo-0.49.0/src/cargo/sources/git/source.rs:14:1 clippy::module_name_repetitions "item name ends with its containing module's name" cargo-0.49.0/src/cargo/sources/git/source.rs:25:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/sources/git/source.rs:34:25 clippy::manual_map "manual implementation of `Option::map`" cargo-0.49.0/src/cargo/sources/git/source.rs:49:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" cargo-0.49.0/src/cargo/sources/git/source.rs:53:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" cargo-0.49.0/src/cargo/sources/git/source.rs:53:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" @@ -1008,7 +1013,6 @@ cargo-0.49.0/src/cargo/sources/git/source.rs:69:20 clippy::comparison_to_empty " cargo-0.49.0/src/cargo/sources/git/utils.rs:1025:19 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" cargo-0.49.0/src/cargo/sources/git/utils.rs:1157:36 clippy::case_sensitive_file_extension_comparisons "case-sensitive file extension comparison" cargo-0.49.0/src/cargo/sources/git/utils.rs:1158:9 clippy::manual_strip "stripping a suffix manually" -cargo-0.49.0/src/cargo/sources/git/utils.rs:134:12 clippy::upper_case_acronyms "name `GitShortID` contains a capitalized acronym" cargo-0.49.0/src/cargo/sources/git/utils.rs:176:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" cargo-0.49.0/src/cargo/sources/git/utils.rs:180:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" cargo-0.49.0/src/cargo/sources/git/utils.rs:184:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" @@ -1061,6 +1065,7 @@ cargo-0.49.0/src/cargo/sources/registry/local.rs:12:1 clippy::module_name_repeti cargo-0.49.0/src/cargo/sources/registry/mod.rs:192:1 clippy::module_name_repetitions "item name starts with its containing module's name" cargo-0.49.0/src/cargo/sources/registry/mod.rs:203:1 clippy::module_name_repetitions "item name starts with its containing module's name" cargo-0.49.0/src/cargo/sources/registry/mod.rs:229:1 clippy::module_name_repetitions "item name starts with its containing module's name" +cargo-0.49.0/src/cargo/sources/registry/mod.rs:340:24 clippy::manual_map "manual implementation of `Option::map`" cargo-0.49.0/src/cargo/sources/registry/mod.rs:372:1 clippy::module_name_repetitions "item name starts with its containing module's name" cargo-0.49.0/src/cargo/sources/registry/mod.rs:373:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" cargo-0.49.0/src/cargo/sources/registry/mod.rs:375:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" @@ -1085,6 +1090,7 @@ cargo-0.49.0/src/cargo/util/command_prelude.rs:222:1 clippy::must_use_candidate cargo-0.49.0/src/cargo/util/command_prelude.rs:234:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" cargo-0.49.0/src/cargo/util/command_prelude.rs:249:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" cargo-0.49.0/src/cargo/util/command_prelude.rs:264:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/command_prelude.rs:265:19 clippy::manual_map "manual implementation of `Option::map`" cargo-0.49.0/src/cargo/util/command_prelude.rs:279:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" cargo-0.49.0/src/cargo/util/command_prelude.rs:298:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" cargo-0.49.0/src/cargo/util/command_prelude.rs:320:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" @@ -1166,6 +1172,7 @@ cargo-0.49.0/src/cargo/util/config/mod.rs:1901:5 clippy::doc_markdown "you shoul cargo-0.49.0/src/cargo/util/config/mod.rs:214:13 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" cargo-0.49.0/src/cargo/util/config/mod.rs:259:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" cargo-0.49.0/src/cargo/util/config/mod.rs:298:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/config/mod.rs:299:12 clippy::manual_map "manual implementation of `Option::map`" cargo-0.49.0/src/cargo/util/config/mod.rs:311:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" cargo-0.49.0/src/cargo/util/config/mod.rs:318:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" cargo-0.49.0/src/cargo/util/config/mod.rs:353:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" @@ -1183,6 +1190,7 @@ cargo-0.49.0/src/cargo/util/config/mod.rs:689:20 clippy::unused_self "unused `se cargo-0.49.0/src/cargo/util/config/mod.rs:699:5 clippy::fn_params_excessive_bools "more than 3 bools in function parameters" cargo-0.49.0/src/cargo/util/config/mod.rs:699:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" cargo-0.49.0/src/cargo/util/config/mod.rs:719:58 clippy::redundant_closure_for_method_calls "redundant closure found" +cargo-0.49.0/src/cargo/util/config/mod.rs:748:30 clippy::manual_map "manual implementation of `Option::map`" cargo-0.49.0/src/cargo/util/config/mod.rs:816:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" cargo-0.49.0/src/cargo/util/config/path.rs:10:1 clippy::module_name_repetitions "item name ends with its containing module's name" cargo-0.49.0/src/cargo/util/config/path.rs:14:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" @@ -1241,6 +1249,7 @@ cargo-0.49.0/src/cargo/util/flock.rs:335:23 clippy::cast_sign_loss "casting `i64 cargo-0.49.0/src/cargo/util/flock.rs:335:44 clippy::cast_possible_truncation "casting `i64` to `u32` may truncate the value" cargo-0.49.0/src/cargo/util/flock.rs:379:35 clippy::match_same_arms "this `match` has identical arm bodies" cargo-0.49.0/src/cargo/util/flock.rs:37:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +cargo-0.49.0/src/cargo/util/flock.rs:43:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" cargo-0.49.0/src/cargo/util/flock.rs:43:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" cargo-0.49.0/src/cargo/util/flock.rs:52:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" cargo-0.49.0/src/cargo/util/flock.rs:52:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" @@ -1267,6 +1276,7 @@ cargo-0.49.0/src/cargo/util/interning.rs:66:5 clippy::missing_panics_doc "docs f cargo-0.49.0/src/cargo/util/interning.rs:66:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" cargo-0.49.0/src/cargo/util/interning.rs:77:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" cargo-0.49.0/src/cargo/util/into_url.rs:10:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +cargo-0.49.0/src/cargo/util/into_url_with_base.rs:14:24 clippy::manual_map "manual implementation of `Option::map`" cargo-0.49.0/src/cargo/util/into_url_with_base.rs:9:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" cargo-0.49.0/src/cargo/util/job.rs:20:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" cargo-0.49.0/src/cargo/util/lev_distance.rs:3:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" @@ -2232,16 +2242,13 @@ rand-0.7.3/src/distributions/uniform.rs:943:54 clippy::cast_possible_truncation rand-0.7.3/src/distributions/unit_circle.rs:30:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" rand-0.7.3/src/distributions/unit_sphere.rs:24:1 clippy::module_name_repetitions "item name starts with its containing module's name" rand-0.7.3/src/distributions/unit_sphere.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/distributions/utils.rs:218:18 clippy::upper_case_acronyms "name `FloatSIMDUtils` contains a capitalized acronym" rand-0.7.3/src/distributions/utils.rs:247:15 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" rand-0.7.3/src/distributions/utils.rs:248:20 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" rand-0.7.3/src/distributions/utils.rs:249:18 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" -rand-0.7.3/src/distributions/utils.rs:253:18 clippy::upper_case_acronyms "name `FloatAsSIMD` contains a capitalized acronym" rand-0.7.3/src/distributions/utils.rs:254:5 clippy::inline_always "you have declared `#[inline(always)]` on `lanes`. This is usually a bad idea" rand-0.7.3/src/distributions/utils.rs:258:5 clippy::inline_always "you have declared `#[inline(always)]` on `splat`. This is usually a bad idea" rand-0.7.3/src/distributions/utils.rs:262:5 clippy::inline_always "you have declared `#[inline(always)]` on `extract`. This is usually a bad idea" rand-0.7.3/src/distributions/utils.rs:267:5 clippy::inline_always "you have declared `#[inline(always)]` on `replace`. This is usually a bad idea" -rand-0.7.3/src/distributions/utils.rs:274:18 clippy::upper_case_acronyms "name `BoolAsSIMD` contains a capitalized acronym" rand-0.7.3/src/distributions/utils.rs:281:5 clippy::inline_always "you have declared `#[inline(always)]` on `any`. This is usually a bad idea" rand-0.7.3/src/distributions/utils.rs:286:5 clippy::inline_always "you have declared `#[inline(always)]` on `all`. This is usually a bad idea" rand-0.7.3/src/distributions/utils.rs:291:5 clippy::inline_always "you have declared `#[inline(always)]` on `none`. This is usually a bad idea" @@ -2820,7 +2827,6 @@ regex-1.3.2/src/exec.rs:1270:17 clippy::doc_markdown "you should put `RegexSet` regex-1.3.2/src/exec.rs:1280:17 clippy::doc_markdown "you should put `RegexSet` between ticks in the documentation" regex-1.3.2/src/exec.rs:137:9 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" regex-1.3.2/src/exec.rs:142:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/exec.rs:1493:5 clippy::upper_case_acronyms "name `PikeVM` contains a capitalized acronym" regex-1.3.2/src/exec.rs:158:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" regex-1.3.2/src/exec.rs:168:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" regex-1.3.2/src/exec.rs:181:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" @@ -2910,10 +2916,8 @@ regex-1.3.2/src/literal/imp.rs:160:30 clippy::match_same_arms "this `match` has regex-1.3.2/src/literal/imp.rs:167:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" regex-1.3.2/src/literal/imp.rs:168:13 clippy::enum_glob_use "usage of wildcard import for enum variants" regex-1.3.2/src/literal/imp.rs:211:20 clippy::redundant_else "redundant else block" -regex-1.3.2/src/literal/imp.rs:239:5 clippy::upper_case_acronyms "name `AC` contains a capitalized acronym" regex-1.3.2/src/literal/imp.rs:276:50 clippy::match_same_arms "this `match` has identical arm bodies" regex-1.3.2/src/literal/imp.rs:342:41 clippy::inline_always "you have declared `#[inline(always)]` on `find`. This is usually a bad idea" -regex-1.3.2/src/literal/imp.rs:34:5 clippy::upper_case_acronyms "name `AC` contains a capitalized acronym" regex-1.3.2/src/literal/imp.rs:435:13 clippy::redundant_field_names "redundant field names in struct initialization" regex-1.3.2/src/literal/imp.rs:436:13 clippy::redundant_field_names "redundant field names in struct initialization" regex-1.3.2/src/literal/imp.rs:437:13 clippy::redundant_field_names "redundant field names in struct initialization" @@ -2954,7 +2958,6 @@ regex-1.3.2/src/pikevm.rs:224:5 clippy::too_many_arguments "this function has to regex-1.3.2/src/pikevm.rs:234:13 clippy::enum_glob_use "usage of wildcard import for enum variants" regex-1.3.2/src/pikevm.rs:303:13 clippy::enum_glob_use "usage of wildcard import for enum variants" regex-1.3.2/src/pikevm.rs:331:29 clippy::mut_mut "this expression mutably borrows a mutable reference. Consider reborrowing" -regex-1.3.2/src/pikevm.rs:70:5 clippy::upper_case_acronyms "name `IP` contains a capitalized acronym" regex-1.3.2/src/pikevm.rs:88:5 clippy::too_many_arguments "this function has too many arguments (8/7)" regex-1.3.2/src/prog.rs:102:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" regex-1.3.2/src/prog.rs:113:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" @@ -3089,8 +3092,6 @@ ripgrep-12.1.1/crates/core/app.rs:156:39 clippy::doc_markdown "you should put `c ripgrep-12.1.1/crates/core/app.rs:156:39 clippy::doc_markdown "you should put `clap::Arg` between ticks in the documentation" ripgrep-12.1.1/crates/core/app.rs:156:5 clippy::doc_markdown "you should put `RGArg` between ticks in the documentation" ripgrep-12.1.1/crates/core/app.rs:156:5 clippy::doc_markdown "you should put `RGArg` between ticks in the documentation" -ripgrep-12.1.1/crates/core/app.rs:164:12 clippy::upper_case_acronyms "name `RGArg` contains a capitalized acronym" -ripgrep-12.1.1/crates/core/app.rs:164:12 clippy::upper_case_acronyms "name `RGArg` contains a capitalized acronym" ripgrep-12.1.1/crates/core/app.rs:1668:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" ripgrep-12.1.1/crates/core/app.rs:1668:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" ripgrep-12.1.1/crates/core/app.rs:1669:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" @@ -3099,8 +3100,6 @@ ripgrep-12.1.1/crates/core/app.rs:1821:5 clippy::items_after_statements "adding ripgrep-12.1.1/crates/core/app.rs:1821:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" ripgrep-12.1.1/crates/core/app.rs:1822:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" ripgrep-12.1.1/crates/core/app.rs:1822:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep-12.1.1/crates/core/app.rs:212:10 clippy::upper_case_acronyms "name `RGArgKind` contains a capitalized acronym" -ripgrep-12.1.1/crates/core/app.rs:212:10 clippy::upper_case_acronyms "name `RGArgKind` contains a capitalized acronym" ripgrep-12.1.1/crates/core/app.rs:2999:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" ripgrep-12.1.1/crates/core/app.rs:2999:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" ripgrep-12.1.1/crates/core/app.rs:3000:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" @@ -3138,7 +3137,6 @@ ripgrep-12.1.1/crates/core/args.rs:410:14 clippy::trivially_copy_pass_by_ref "th ripgrep-12.1.1/crates/core/args.rs:475:18 clippy::match_same_arms "this `match` has identical arm bodies" ripgrep-12.1.1/crates/core/args.rs:512:19 clippy::doc_markdown "you should put `ArgMatches` between ticks in the documentation" ripgrep-12.1.1/crates/core/args.rs:549:16 clippy::wrong_self_convention "methods called `to_*` usually take self by reference; consider choosing a less ambiguous name" -ripgrep-12.1.1/crates/core/args.rs:71:5 clippy::upper_case_acronyms "name `PCRE2Version` contains a capitalized acronym" ripgrep-12.1.1/crates/core/args.rs:76:18 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" ripgrep-12.1.1/crates/core/args.rs:77:13 clippy::enum_glob_use "usage of wildcard import for enum variants" ripgrep-12.1.1/crates/core/args.rs:923:42 clippy::doc_markdown "you should put `BinaryDetection::quit` between ticks in the documentation" @@ -3188,8 +3186,8 @@ syn-1.0.54/src/lib.rs:1:null clippy::cargo_common_metadata "package `syn` is mis syn-1.0.54/src/lit.rs:1397:40 clippy::redundant_else "redundant else block" syn-1.0.54/src/lit.rs:1405:28 clippy::redundant_else "redundant else block" syn-1.0.54/src/lit.rs:1485:32 clippy::redundant_else "redundant else block" +syn-1.0.54/src/token.rs:974:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" unicode-xid-0.2.1/src/lib.rs:1:null clippy::cargo_common_metadata "package `unicode-xid` is missing `package.categories` metadata" -unicode-xid-0.2.1/src/lib.rs:56:11 clippy::upper_case_acronyms "name `UnicodeXID` contains a capitalized acronym" unicode-xid-0.2.1/src/lib.rs:57:64 clippy::doc_markdown "you should put `XID_Start` between ticks in the documentation" unicode-xid-0.2.1/src/lib.rs:60:10 clippy::doc_markdown "you should put `XID_Start` between ticks in the documentation" unicode-xid-0.2.1/src/lib.rs:62:27 clippy::doc_markdown "you should put `ID_Start` between ticks in the documentation" @@ -3375,8 +3373,7 @@ xsv-0.13.0/src/util.rs:90:1 clippy::needless_lifetimes "explicit lifetimes given -Stats - +Stats: clippy::clone_on_copy 1 clippy::comparison_chain 1 clippy::expect_fun_call 1 @@ -3424,6 +3421,7 @@ clippy::mut_mut 3 clippy::ptr_arg 3 clippy::zero_ptr 3 clippy::too_many_arguments 4 +clippy::upper_case_acronyms 4 clippy::explicit_iter_loop 5 clippy::field_reassign_with_default 5 clippy::identity_op 5 @@ -3445,6 +3443,7 @@ clippy::invalid_upcast_comparisons 8 clippy::needless_question_mark 8 clippy::wrong_self_convention 8 clippy::multiple_crate_versions 9 +clippy::manual_map 10 clippy::manual_range_contains 10 clippy::match_wildcard_for_single_variants 10 clippy::missing_safety_doc 10 @@ -3456,7 +3455,6 @@ clippy::linkedlist 14 clippy::single_char_add_str 14 clippy::option_if_let_else 15 clippy::needless_pass_by_value 18 -clippy::upper_case_acronyms 18 clippy::cast_possible_wrap 19 clippy::cast_sign_loss 19 clippy::unnecessary_wraps 19 @@ -3476,7 +3474,7 @@ clippy::enum_glob_use 40 clippy::unseparated_literal_suffix 41 clippy::cast_precision_loss 44 clippy::single_match_else 45 -clippy::missing_panics_doc 54 +clippy::missing_panics_doc 56 clippy::inline_always 59 clippy::match_same_arms 60 clippy::similar_names 78 -- cgit 1.4.1-3-g733a5 From d931d1b5e6d1ccb9290313dde986844966f3ee2b Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Sat, 27 Feb 2021 00:29:42 +0100 Subject: lintcheck: refactor: introduce a basic LintcheckConfig struct which holds the job limit and paths to the sources and log files --- clippy_dev/src/lintcheck.rs | 111 ++++++++++++++++++++++++++------------------ 1 file changed, 66 insertions(+), 45 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lintcheck.rs b/clippy_dev/src/lintcheck.rs index 65e438bc0e8..423daa0d190 100644 --- a/clippy_dev/src/lintcheck.rs +++ b/clippy_dev/src/lintcheck.rs @@ -287,6 +287,61 @@ impl Crate { } } +#[derive(Debug)] +struct LintcheckConfig { + // max number of jobs to spawn (default 1) + max_jobs: usize, + // we read the sources to check from here + sources_toml_path: PathBuf, + // we save the clippy lint results here + lintcheck_results_path: PathBuf, +} + +impl LintcheckConfig { + fn from_clap(clap_config: &ArgMatches) -> Self { + // first, check if we got anything passed via the LINTCHECK_TOML env var, + // if not, ask clap if we got any value for --crates-toml + // if not, use the default "clippy_dev/lintcheck_crates.toml" + let sources_toml = env::var("LINTCHECK_TOML").unwrap_or( + clap_config + .value_of("crates-toml") + .clone() + .unwrap_or("clippy_dev/lintcheck_crates.toml") + .to_string(), + ); + + let sources_toml_path = PathBuf::from(sources_toml); + + // for the path where we save the lint results, get the filename without extenstion ( so for + // wasd.toml, use "wasd"....) + let filename: PathBuf = sources_toml_path.file_stem().unwrap().into(); + let lintcheck_results_path = PathBuf::from(format!("lintcheck-logs/{}_logs.txt", filename.display())); + + let max_jobs = match clap_config.value_of("threads") { + Some(threads) => { + let threads: usize = threads + .parse() + .expect(&format!("Failed to parse '{}' to a digit", threads)); + if threads == 0 { + // automatic choice + // Rayon seems to return thread count so half that for core count + (rayon::current_num_threads() / 2) as usize + } else { + threads + } + }, + // no -j passed, use a single thread + None => 1, + }; + + LintcheckConfig { + max_jobs, + sources_toml_path, + lintcheck_results_path, + } + } +} + /// takes a single json-formatted clippy warnings and returns true (we are interested in that line) /// or false (we aren't) fn filter_clippy_warnings(line: &str) -> bool { @@ -310,19 +365,6 @@ fn filter_clippy_warnings(line: &str) -> bool { false } -/// get the path to lintchecks crate sources .toml file, check LINTCHECK_TOML first but if it's -/// empty use the default path -fn lintcheck_config_toml(toml_path: Option<&str>) -> PathBuf { - PathBuf::from( - env::var("LINTCHECK_TOML").unwrap_or( - toml_path - .clone() - .unwrap_or("clippy_dev/lintcheck_crates.toml") - .to_string(), - ), - ) -} - /// Builds clippy inside the repo to make sure we have a clippy executable we can use. fn build_clippy() { let status = Command::new("cargo") @@ -336,9 +378,7 @@ fn build_clippy() { } /// Read a `toml` file and return a list of `CrateSources` that we want to check with clippy -fn read_crates(toml_path: &PathBuf) -> (String, Vec) { - // save it so that we can use the name of the sources.toml as name for the logfile later. - let toml_filename = toml_path.file_stem().unwrap().to_str().unwrap().to_string(); +fn read_crates(toml_path: &PathBuf) -> Vec { let toml_content: String = std::fs::read_to_string(&toml_path).unwrap_or_else(|_| panic!("Failed to read {}", toml_path.display())); let crate_list: SourceList = @@ -398,7 +438,7 @@ fn read_crates(toml_path: &PathBuf) -> (String, Vec) { // sort the crates crate_sources.sort(); - (toml_filename, crate_sources) + crate_sources } /// Parse the json output of clippy and return a `ClippyWarning` @@ -476,16 +516,15 @@ fn lintcheck_needs_rerun(toml_path: &PathBuf) -> bool { /// lintchecks `main()` function pub fn run(clap_config: &ArgMatches) { + let config = LintcheckConfig::from_clap(clap_config); + println!("Compiling clippy..."); build_clippy(); println!("Done compiling"); - let clap_toml_path: Option<&str> = clap_config.value_of("crates-toml"); - let toml_path: PathBuf = lintcheck_config_toml(clap_toml_path); - // if the clippy bin is newer than our logs, throw away target dirs to force clippy to // refresh the logs - if lintcheck_needs_rerun(&toml_path) { + if lintcheck_needs_rerun(&config.sources_toml_path) { let shared_target_dir = "target/lintcheck/shared_target_dir"; match std::fs::metadata(&shared_target_dir) { Ok(metadata) => { @@ -520,9 +559,8 @@ pub fn run(clap_config: &ArgMatches) { // download and extract the crates, then run clippy on them and collect clippys warnings // flatten into one big list of warnings - let (filename, crates) = read_crates(&toml_path); - let file = format!("lintcheck-logs/{}_logs.txt", filename); - let old_stats = read_stats_from_file(&file); + let crates = read_crates(&config.sources_toml_path); + let old_stats = read_stats_from_file(&config.lintcheck_results_path); let clippy_warnings: Vec = if let Some(only_one_crate) = clap_config.value_of("only") { // if we don't have the specified crate in the .toml, throw an error @@ -562,23 +600,7 @@ pub fn run(clap_config: &ArgMatches) { // order to achive some kind of parallelism // by default, use a single thread - let num_cpus = match clap_config.value_of("threads") { - Some(threads) => { - let threads: usize = threads - .parse() - .expect(&format!("Failed to parse '{}' to a digit", threads)); - if threads == 0 { - // automatic choice - // Rayon seems to return thread count so half that for core count - (rayon::current_num_threads() / 2) as usize - } else { - threads - } - }, - // no -j passed, use a single thread - None => 1, - }; - + let num_cpus = config.max_jobs; let num_crates = crates.len(); // check all crates (default) @@ -612,15 +634,14 @@ pub fn run(clap_config: &ArgMatches) { ices.iter() .for_each(|(cratename, msg)| text.push_str(&format!("{}: '{}'", cratename, msg))); - println!("Writing logs to {}", file); - write(&file, text).unwrap(); + println!("Writing logs to {}", config.lintcheck_results_path.display()); + write(&config.lintcheck_results_path, text).unwrap(); print_stats(old_stats, new_stats); } /// read the previous stats from the lintcheck-log file -fn read_stats_from_file(file_path: &String) -> HashMap { - let file_path = PathBuf::from(file_path); +fn read_stats_from_file(file_path: &PathBuf) -> HashMap { let file_content: String = match std::fs::read_to_string(file_path).ok() { Some(content) => content, None => { -- cgit 1.4.1-3-g733a5 From 2d9932d720480e9f5e6cbe96bd5aadfd754fc074 Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Sat, 27 Feb 2021 01:34:45 +0100 Subject: lintcheck: don't run clippy in parallel by default --- clippy_dev/src/lintcheck.rs | 57 ++++++++++++++++++++++++++++----------------- 1 file changed, 35 insertions(+), 22 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lintcheck.rs b/clippy_dev/src/lintcheck.rs index 423daa0d190..00f406a085e 100644 --- a/clippy_dev/src/lintcheck.rs +++ b/clippy_dev/src/lintcheck.rs @@ -588,28 +588,41 @@ pub fn run(clap_config: &ArgMatches) { .flatten() .collect() } else { - let counter = std::sync::atomic::AtomicUsize::new(0); - - // Ask rayon for thread count. Assume that half of that is the number of physical cores - // Use one target dir for each core so that we can run N clippys in parallel. - // We need to use different target dirs because cargo would lock them for a single build otherwise, - // killing the parallelism. However this also means that deps will only be reused half/a - // quarter of the time which might result in a longer wall clock runtime - - // This helps when we check many small crates with dep-trees that don't have a lot of branches in - // order to achive some kind of parallelism - - // by default, use a single thread - let num_cpus = config.max_jobs; - let num_crates = crates.len(); - - // check all crates (default) - crates - .into_par_iter() - .map(|krate| krate.download_and_extract()) - .map(|krate| krate.run_clippy_lints(&cargo_clippy_path, &counter, num_cpus, num_crates)) - .flatten() - .collect() + if config.max_jobs > 1 { + // run parallel with rayon + + let counter = AtomicUsize::new(0); + + // Ask rayon for thread count. Assume that half of that is the number of physical cores + // Use one target dir for each core so that we can run N clippys in parallel. + // We need to use different target dirs because cargo would lock them for a single build otherwise, + // killing the parallelism. However this also means that deps will only be reused half/a + // quarter of the time which might result in a longer wall clock runtime + + // This helps when we check many small crates with dep-trees that don't have a lot of branches in + // order to achive some kind of parallelism + + // by default, use a single thread + let num_cpus = config.max_jobs; + let num_crates = crates.len(); + + // check all crates (default) + crates + .into_par_iter() + .map(|krate| krate.download_and_extract()) + .map(|krate| krate.run_clippy_lints(&cargo_clippy_path, &counter, num_cpus, num_crates)) + .flatten() + .collect() + } else { + // run sequential + let num_crates = crates.len(); + crates + .into_iter() + .map(|krate| krate.download_and_extract()) + .map(|krate| krate.run_clippy_lints(&cargo_clippy_path, &AtomicUsize::new(0), 1, num_crates)) + .flatten() + .collect() + } }; // generate some stats -- cgit 1.4.1-3-g733a5 From e3386041a291c25d692e29d28dbb8fbfd7ef9c5a Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Sat, 27 Feb 2021 12:05:27 +0100 Subject: lintcheck: uses consts for clippy driver and cargo clippy paths --- clippy_dev/src/lintcheck.rs | 24 ++++++++++++++---------- 1 file changed, 14 insertions(+), 10 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lintcheck.rs b/clippy_dev/src/lintcheck.rs index 00f406a085e..24af64626cb 100644 --- a/clippy_dev/src/lintcheck.rs +++ b/clippy_dev/src/lintcheck.rs @@ -19,6 +19,9 @@ use rayon::prelude::*; use serde::{Deserialize, Serialize}; use serde_json::Value; +const CLIPPY_DRIVER_PATH: &str = "target/debug/clippy-driver"; +const CARGO_CLIPPY_PATH: &str = "target/debug/cargo-clippy"; + /// List of sources to check, loaded from a .toml file #[derive(Debug, Serialize, Deserialize)] struct SourceList { @@ -317,6 +320,9 @@ impl LintcheckConfig { let filename: PathBuf = sources_toml_path.file_stem().unwrap().into(); let lintcheck_results_path = PathBuf::from(format!("lintcheck-logs/{}_logs.txt", filename.display())); + // look at the --threads arg, if 0 is passed, ask rayon rayon how many threads it would spawn and + // use half of that for the physical core count + // by default use a single thread let max_jobs = match clap_config.value_of("threads") { Some(threads) => { let threads: usize = threads @@ -492,14 +498,12 @@ fn gather_stats(clippy_warnings: &[ClippyWarning]) -> (String, HashMap<&String, /// clippy binary, if this is true, we should clean the lintchec shared target directory and recheck fn lintcheck_needs_rerun(toml_path: &PathBuf) -> bool { let clippy_modified: std::time::SystemTime = { - let mut times = ["target/debug/clippy-driver", "target/debug/cargo-clippy"] - .iter() - .map(|p| { - std::fs::metadata(p) - .expect("failed to get metadata of file") - .modified() - .expect("failed to get modification date") - }); + let mut times = [CLIPPY_DRIVER_PATH, CARGO_CLIPPY_PATH].iter().map(|p| { + std::fs::metadata(p) + .expect("failed to get metadata of file") + .modified() + .expect("failed to get modification date") + }); // the oldest modification of either of the binaries std::cmp::min(times.next().unwrap(), times.next().unwrap()) }; @@ -539,7 +543,7 @@ pub fn run(clap_config: &ArgMatches) { } } - let cargo_clippy_path: PathBuf = PathBuf::from("target/debug/cargo-clippy") + let cargo_clippy_path: PathBuf = PathBuf::from(CARGO_CLIPPY_PATH) .canonicalize() .expect("failed to canonicalize path to clippy binary"); @@ -550,7 +554,7 @@ pub fn run(clap_config: &ArgMatches) { cargo_clippy_path.display() ); - let clippy_ver = std::process::Command::new("target/debug/cargo-clippy") + let clippy_ver = std::process::Command::new(CARGO_CLIPPY_PATH) .arg("--version") .output() .map(|o| String::from_utf8_lossy(&o.stdout).into_owned()) -- cgit 1.4.1-3-g733a5 From 1b1ed9359eef9f69c4d384ad1592ba5e1b1d83af Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Sat, 27 Feb 2021 12:29:13 +0100 Subject: lintcheck: put the full paths (target/lintcheck/sources/...) to the source files of a warning into the lintcheck log This is more convenient when reviewing new lint warnings that popped up in the logs --- clippy_dev/src/lintcheck.rs | 2 +- lintcheck-logs/lintcheck_crates_logs.txt | 6728 +++++++++++++++--------------- 2 files changed, 3369 insertions(+), 3361 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lintcheck.rs b/clippy_dev/src/lintcheck.rs index 24af64626cb..622dad1740b 100644 --- a/clippy_dev/src/lintcheck.rs +++ b/clippy_dev/src/lintcheck.rs @@ -89,7 +89,7 @@ impl std::fmt::Display for ClippyWarning { fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { writeln!( f, - r#"{}-{}/{}:{}:{} {} "{}""#, + r#"target/lintcheck/sources/{}-{}/{}:{}:{} {} "{}""#, &self.crate_name, &self.crate_version, &self.file, &self.line, &self.column, &self.linttype, &self.message ) } diff --git a/lintcheck-logs/lintcheck_crates_logs.txt b/lintcheck-logs/lintcheck_crates_logs.txt index cf6af1a549a..b0ba84ed3f7 100644 --- a/lintcheck-logs/lintcheck_crates_logs.txt +++ b/lintcheck-logs/lintcheck_crates_logs.txt @@ -1,3364 +1,3371 @@ -clippy 0.1.52 (524f54c57 2021-02-26) +clippy 0.1.52 (e3386041a 2021-02-28) -cargo-0.49.0/build.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.categories` metadata" -cargo-0.49.0/build.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.keywords` metadata" -cargo-0.49.0/src/bin/cargo/cli.rs:104:34 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/bin/cargo/cli.rs:121:5 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo-0.49.0/src/bin/cargo/cli.rs:157:30 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/cli.rs:184:41 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" -cargo-0.49.0/src/bin/cargo/cli.rs:196:42 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/cli.rs:200:39 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/cli.rs:231:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo-0.49.0/src/bin/cargo/cli.rs:245:22 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" -cargo-0.49.0/src/bin/cargo/cli.rs:247:47 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/cli.rs:257:22 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/cli.rs:26:20 clippy::redundant_else "redundant else block" -cargo-0.49.0/src/bin/cargo/cli.rs:7:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/bench.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/bench.rs:76:59 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/commands/build.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/check.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/clean.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/doc.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/fetch.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/fetch.rs:22:5 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" -cargo-0.49.0/src/bin/cargo/commands/fix.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/generate_lockfile.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/git_checkout.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/help.rs:20:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/bin/cargo/commands/init.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/install.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/install.rs:97:16 clippy::option_if_let_else "use Option::map_or instead of an if let/else" -cargo-0.49.0/src/bin/cargo/commands/locate_project.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/login.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/metadata.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/mod.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/new.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/new.rs:20:24 clippy::option_if_let_else "use Option::map_or instead of an if let/else" -cargo-0.49.0/src/bin/cargo/commands/owner.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/owner.rs:38:43 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/commands/owner.rs:39:43 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/commands/owner.rs:40:43 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/commands/owner.rs:43:30 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/commands/owner.rs:46:30 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/commands/package.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/pkgid.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/publish.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/publish.rs:40:47 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/commands/read_manifest.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/run.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/rustc.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/rustdoc.rs:3:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/search.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/test.rs:127:54 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/commands/test.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/tree.rs:149:49 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/commands/tree.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/uninstall.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/update.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/vendor.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/vendor.rs:96:16 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" -cargo-0.49.0/src/bin/cargo/commands/verify_project.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/version.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/yank.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/commands/yank.rs:32:36 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/commands/yank.rs:33:35 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/commands/yank.rs:34:36 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/commands/yank.rs:35:36 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/main.rs:100:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" -cargo-0.49.0/src/bin/cargo/main.rs:118:41 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/main.rs:137:43 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/main.rs:148:19 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/bin/cargo/main.rs:174:57 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/main.rs:18:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/bin/cargo/main.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.categories` metadata" -cargo-0.49.0/src/bin/cargo/main.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.keywords` metadata" -cargo-0.49.0/src/bin/cargo/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `crossbeam-utils`: 0.6.6, 0.7.2" -cargo-0.49.0/src/bin/cargo/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `hex`: 0.3.2, 0.4.0" -cargo-0.49.0/src/bin/cargo/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `humantime`: 1.3.0, 2.0.0" -cargo-0.49.0/src/bin/cargo/main.rs:72:22 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/main.rs:94:13 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" -cargo-0.49.0/src/bin/cargo/main.rs:96:41 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/bin/cargo/main.rs:98:60 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/compiler/build_config.rs:155:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -cargo-0.49.0/src/cargo/core/compiler/build_config.rs:170:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/build_config.rs:175:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/build_config.rs:180:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/build_config.rs:186:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/build_config.rs:197:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/build_config.rs:205:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/build_config.rs:51:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/build_config.rs:69:48 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -cargo-0.49.0/src/cargo/core/compiler/build_config.rs:96:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/build_context/mod.rs:44:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/build_context/mod.rs:83:20 clippy::doc_markdown "you should put `x86_64` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:108:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:121:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:149:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:411:9 clippy::needless_question_mark "question mark operator is useless here" -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:420:69 clippy::doc_markdown "you should put `mode/target_kind` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:423:19 clippy::doc_markdown "you should put `CrateTypes` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:424:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:469:58 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:603:19 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:665:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:697:12 clippy::inconsistent_struct_constructor "inconsistent struct constructor" -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:82:31 clippy::doc_markdown "you should put `FileType` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:83:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:84:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:96:31 clippy::doc_markdown "you should put `FileType` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:98:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/build_plan.rs:4:9 clippy::doc_markdown "you should put `BuildPlan` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/build_plan.rs:5:66 clippy::doc_markdown "you should put `BuildPlan` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/build_plan.rs:66:40 clippy::ptr_arg "writing `&PathBuf` instead of `&Path` involves a new object where a slice will do" -cargo-0.49.0/src/cargo/core/compiler/compilation.rs:150:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/compilation.rs:150:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/compiler/compilation.rs:169:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/compilation.rs:185:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/compilation.rs:193:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/compilation.rs:194:49 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/compiler/compilation.rs:198:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/compilation.rs:314:16 clippy::doc_markdown "you should put `rustc_tool` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/compilation.rs:91:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:118:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:123:18 clippy::case_sensitive_file_extension_comparisons "case-sensitive file extension comparison" -cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:147:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:157:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:157:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:33:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:49:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:69:48 clippy::case_sensitive_file_extension_comparisons "case-sensitive file extension comparison" -cargo-0.49.0/src/cargo/core/compiler/context/compilation_files.rs:204:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/core/compiler/context/compilation_files.rs:277:22 clippy::doc_markdown "you should put `OUT_DIR` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/context/compilation_files.rs:324:66 clippy::doc_markdown "you should put `FileType` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/context/compilation_files.rs:393:37 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/compiler/context/compilation_files.rs:426:71 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:125:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:125:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:125:5 clippy::too_many_lines "this function has too many lines (107/100)" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:270:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:286:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:308:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:308:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:340:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:340:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:349:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:349:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:354:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:358:21 clippy::doc_markdown "you should put `RunCustomBuild` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:361:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:374:43 clippy::doc_markdown "you should put `RunCustomBuild` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:378:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:383:41 clippy::doc_markdown "you should put `RunCustomBuild` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:384:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:391:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:397:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:523:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:538:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:542:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:83:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:92:25 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/core/compiler/crate_type.rs:16:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/crate_type.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/crate_type.rs:40:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/crate_type.rs:49:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/crate_type.rs:60:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:150:1 clippy::too_many_lines "this function has too many lines (230/100)" -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:353:56 clippy::manual_strip "stripping a prefix manually" -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:448:27 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:464:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:481:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:481:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:48:56 clippy::doc_markdown "you should put `RunCustomBuild` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:561:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:567:20 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:576:28 clippy::shadow_unrelated "`mut value` is being shadowed" -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:606:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:688:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:756:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:762:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:762:5 clippy::unnecessary_wraps "this function's return value is unnecessary" -cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:823:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1021:51 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1656:16 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1664:5 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1787:5 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1795:5 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1882:17 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1894:17 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1906:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1917:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1923:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1956:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1962:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1963:22 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1964:22 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1965:22 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1966:22 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1980:17 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1980:24 clippy::manual_strip "stripping a prefix manually" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1986:17 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:2016:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:61:5 clippy::doc_markdown "you should put `CompileMode` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:63:12 clippy::doc_markdown "you should put `CompileKind` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:67:7 clippy::doc_markdown "you should put `CARGO_DEFAULT_LIB_METADATA[^4` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:68:5 clippy::doc_markdown "you should put `package_id` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:71:19 clippy::doc_markdown "you should put `test/bench/for_host/edition` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:755:52 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:77:5 clippy::doc_markdown "you should put `is_std` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:816:5 clippy::too_many_lines "this function has too many lines (127/100)" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:863:64 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:875:33 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:876:32 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:896:30 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:897:30 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:991:37 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:12:5 clippy::doc_markdown "you should put `src/librustc_jobserver/lib.rs` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:329:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:332:23 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:34:53 clippy::doc_markdown "you should put `NeedsToken` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:35:6 clippy::doc_markdown "you should put `ReleaseToken` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:37:6 clippy::doc_markdown "you should put `NeedsToken` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:40:5 clippy::doc_markdown "you should put `NeedsToken` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:40:56 clippy::doc_markdown "you should put `NeedsToken` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:43:6 clippy::doc_markdown "you should put `ReleaseToken` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:748:16 clippy::collapsible_else_if "this `else { if .. }` block can be collapsed" -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:749:13 clippy::if_not_else "unnecessary boolean `not` operation" -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:786:26 clippy::unused_self "unused `self` argument" -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:81:61 clippy::doc_markdown "you should put `DrainState` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:865:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:871:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:890:9 clippy::unused_self "unused `self` argument" -cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:93:24 clippy::doc_markdown "you should put `JobQueue` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/links.rs:8:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:1016:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:1094:19 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:1131:1 clippy::unnecessary_wraps "this function's return value is unnecessary" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:1268:34 clippy::case_sensitive_file_extension_comparisons "case-sensitive file extension comparison" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:1277:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:179:1 clippy::too_many_lines "this function has too many lines (162/100)" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:198:78 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:201:25 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:267:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:324:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:364:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:364:5 clippy::unnecessary_wraps "this function's return value is unnecessary" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:392:45 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:415:23 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:464:18 clippy::ptr_arg "writing `&PathBuf` instead of `&Path` involves a new object where a slice will do" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:488:61 clippy::ptr_arg "writing `&PathBuf` instead of `&Path` involves a new object where a slice will do" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:667:15 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:693:1 clippy::unnecessary_wraps "this function's return value is unnecessary" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:725:42 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:736:1 clippy::too_many_lines "this function has too many lines (141/100)" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:73:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:777:12 clippy::if_not_else "unnecessary boolean `not` operation" -cargo-0.49.0/src/cargo/core/compiler/mod.rs:873:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/compiler/output_depinfo.rs:41:13 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" -cargo-0.49.0/src/cargo/core/compiler/rustdoc.rs:16:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/core/compiler/rustdoc.rs:57:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/core/compiler/rustdoc.rs:72:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/standard_lib.rs:134:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/standard_lib.rs:16:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/standard_lib.rs:30:28 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/compiler/standard_lib.rs:34:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/standard_lib.rs:34:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/compiler/timings.rs:16:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo-0.49.0/src/cargo/core/compiler/timings.rs:192:64 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo-0.49.0/src/cargo/core/compiler/timings.rs:212:58 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo-0.49.0/src/cargo/core/compiler/timings.rs:234:13 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" -cargo-0.49.0/src/cargo/core/compiler/timings.rs:355:13 clippy::cast_possible_truncation "casting `f64` to `u32` may truncate the value" -cargo-0.49.0/src/cargo/core/compiler/timings.rs:355:13 clippy::cast_sign_loss "casting `f64` to `u32` may lose the sign of the value" -cargo-0.49.0/src/cargo/core/compiler/timings.rs:397:38 clippy::cast_possible_truncation "casting `f64` to `u32` may truncate the value" -cargo-0.49.0/src/cargo/core/compiler/timings.rs:397:38 clippy::cast_sign_loss "casting `f64` to `u32` may lose the sign of the value" -cargo-0.49.0/src/cargo/core/compiler/timings.rs:484:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/compiler/timings.rs:605:38 clippy::doc_markdown "you should put `rmeta_time` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/timings.rs:605:50 clippy::doc_markdown "you should put `codegen_time` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/timings.rs:641:26 clippy::non_ascii_literal "literal non-ASCII character detected" -cargo-0.49.0/src/cargo/core/compiler/unit.rs:100:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/unit.rs:151:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/core/compiler/unit.rs:161:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/compiler/unit.rs:35:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/core/compiler/unit_dependencies.rs:154:29 clippy::doc_markdown "you should put `state.unit_dependencies` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/compiler/unit_dependencies.rs:213:1 clippy::too_many_lines "this function has too many lines (110/100)" -cargo-0.49.0/src/cargo/core/compiler/unit_dependencies.rs:52:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/unit_dependencies.rs:52:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/core/compiler/unit_graph.rs:65:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/compiler/unit_graph.rs:65:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/core/dependency.rs:157:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/dependency.rs:182:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/dependency.rs:203:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/dependency.rs:224:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/dependency.rs:23:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo-0.49.0/src/cargo/core/dependency.rs:248:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/dependency.rs:270:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/dependency.rs:274:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/dependency.rs:278:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/dependency.rs:287:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/dependency.rs:291:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/dependency.rs:305:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/dependency.rs:311:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/dependency.rs:319:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/dependency.rs:337:75 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/dependency.rs:397:56 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/dependency.rs:403:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/dependency.rs:408:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/dependency.rs:415:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/dependency.rs:419:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/dependency.rs:424:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/dependency.rs:428:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/dependency.rs:433:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/dependency.rs:438:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/dependency.rs:443:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/dependency.rs:449:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/dependency.rs:450:9 clippy::if_not_else "unnecessary `!=` operation" -cargo-0.49.0/src/cargo/core/features.rs:119:17 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/features.rs:229:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/features.rs:274:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/features.rs:278:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/features.rs:306:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/features.rs:338:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo-0.49.0/src/cargo/core/features.rs:362:25 clippy::option_option "consider using `Option` instead of `Option>` or a custom enum if you need to distinguish all 3 cases" -cargo-0.49.0/src/cargo/core/features.rs:380:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/features.rs:401:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/features.rs:409:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/features.rs:412:45 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/features.rs:416:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/features.rs:419:45 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/features.rs:424:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/features.rs:431:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/features.rs:477:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/features.rs:509:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/features.rs:518:5 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" -cargo-0.49.0/src/cargo/core/features.rs:542:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/features.rs:543:37 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/features.rs:547:60 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/features.rs:556:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/core/features.rs:563:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/core/manifest.rs:116:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -cargo-0.49.0/src/cargo/core/manifest.rs:118:58 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/manifest.rs:130:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -cargo-0.49.0/src/cargo/core/manifest.rs:143:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:159:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:162:34 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/manifest.rs:169:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:17:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/cargo/core/manifest.rs:189:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo-0.49.0/src/cargo/core/manifest.rs:215:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:222:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:22:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/core/manifest.rs:360:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:407:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:410:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:413:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:416:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:419:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:422:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:425:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:431:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:438:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:444:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:447:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:450:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:453:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:456:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:459:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:462:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:466:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:470:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:477:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:481:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:488:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/manifest.rs:512:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:516:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:520:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:524:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:528:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:538:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:557:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:561:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:565:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:569:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:577:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:581:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:588:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:617:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:632:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:648:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:659:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:66:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/core/manifest.rs:670:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:693:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:708:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:723:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:726:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:729:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:735:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:738:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:741:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:744:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:747:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:751:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:754:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:757:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:760:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:763:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:767:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:776:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:780:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:787:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:798:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:800:56 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/manifest.rs:805:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:809:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:818:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:823:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:828:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:831:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:834:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:839:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:85:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/core/manifest.rs:888:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/manifest.rs:936:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package.rs:1075:28 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/package.rs:160:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package.rs:170:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package.rs:174:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package.rs:182:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package.rs:186:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package.rs:190:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package.rs:194:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/package.rs:194:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package.rs:198:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package.rs:202:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package.rs:206:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package.rs:210:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package.rs:217:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package.rs:221:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package.rs:222:35 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/package.rs:226:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package.rs:227:35 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/package.rs:230:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package.rs:239:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/package.rs:249:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package.rs:287:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/core/package.rs:385:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/package.rs:421:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -cargo-0.49.0/src/cargo/core/package.rs:425:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/package.rs:452:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/package.rs:453:60 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/package.rs:459:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/package.rs:473:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/package.rs:587:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/package.rs:588:9 clippy::needless_question_mark "question mark operator is useless here" -cargo-0.49.0/src/cargo/core/package.rs:682:46 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" -cargo-0.49.0/src/cargo/core/package.rs:682:46 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" -cargo-0.49.0/src/cargo/core/package.rs:682:63 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" -cargo-0.49.0/src/cargo/core/package.rs:682:63 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" -cargo-0.49.0/src/cargo/core/package.rs:731:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/package.rs:790:13 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/core/package.rs:988:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/core/package_id.rs:115:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/package_id.rs:124:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/package_id.rs:124:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package_id.rs:139:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package_id.rs:142:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package_id.rs:145:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package_id.rs:149:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package_id.rs:157:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package_id.rs:161:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package_id.rs:169:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package_id.rs:174:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/core/package_id_spec.rs:101:39 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/package_id_spec.rs:143:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package_id_spec.rs:147:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package_id_spec.rs:151:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package_id_spec.rs:160:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/package_id_spec.rs:179:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/package_id_spec.rs:212:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/package_id_spec.rs:231:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/core/package_id_spec.rs:51:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/package_id_spec.rs:51:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/package_id_spec.rs:77:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/package_id_spec.rs:88:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/profiles.rs:1004:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/profiles.rs:1014:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/profiles.rs:1018:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/profiles.rs:1028:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/profiles.rs:106:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/profiles.rs:143:5 clippy::unnecessary_wraps "this function's return value is unnecessary" -cargo-0.49.0/src/cargo/core/profiles.rs:286:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/profiles.rs:286:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/profiles.rs:294:40 clippy::if_not_else "unnecessary boolean `not` operation" -cargo-0.49.0/src/cargo/core/profiles.rs:30:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/profiles.rs:342:25 clippy::shadow_unrelated "`maker` is being shadowed" -cargo-0.49.0/src/cargo/core/profiles.rs:370:41 clippy::unused_self "unused `self` argument" -cargo-0.49.0/src/cargo/core/profiles.rs:370:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/profiles.rs:372:9 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" -cargo-0.49.0/src/cargo/core/profiles.rs:382:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/profiles.rs:382:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/profiles.rs:383:28 clippy::if_not_else "unnecessary boolean `not` operation" -cargo-0.49.0/src/cargo/core/profiles.rs:397:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/profiles.rs:405:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/profiles.rs:607:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo-0.49.0/src/cargo/core/profiles.rs:909:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/profiles.rs:923:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/profiles.rs:934:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/profiles.rs:987:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/registry.rs:111:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/registry.rs:127:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/registry.rs:168:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/registry.rs:19:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/registry.rs:240:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/registry.rs:26:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/registry.rs:344:49 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/registry.rs:369:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/registry.rs:424:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/registry.rs:49:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/core/registry.rs:520:17 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/core/registry.rs:763:53 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/registry.rs:765:53 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/registry.rs:807:14 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/registry.rs:814:53 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/resolver/conflict_cache.rs:197:29 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/resolver/conflict_cache.rs:41:38 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" -cargo-0.49.0/src/cargo/core/resolver/context.rs:274:53 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/resolver/context.rs:42:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/core/resolver/context.rs:74:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/encode.rs:156:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/resolver/encode.rs:156:5 clippy::too_many_lines "this function has too many lines (164/100)" -cargo-0.49.0/src/cargo/core/resolver/encode.rs:339:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" -cargo-0.49.0/src/cargo/core/resolver/encode.rs:438:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/resolver/encode.rs:449:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/resolver/encode.rs:529:34 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/resolver/encode.rs:602:59 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/resolver/encode.rs:623:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/core/resolver/encode.rs:652:27 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/core/resolver/encode.rs:674:51 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/resolver/errors.rs:103:22 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/resolver/errors.rs:104:22 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/resolver/errors.rs:206:9 clippy::if_not_else "unnecessary boolean `not` operation" -cargo-0.49.0/src/cargo/core/resolver/errors.rs:257:45 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/resolver/errors.rs:27:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/errors.rs:305:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo-0.49.0/src/cargo/core/resolver/errors.rs:70:1 clippy::too_many_lines "this function has too many lines (207/100)" -cargo-0.49.0/src/cargo/core/resolver/features.rs:104:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/core/resolver/features.rs:111:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/features.rs:162:56 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/resolver/features.rs:179:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/core/resolver/features.rs:186:23 clippy::doc_markdown "you should put `RequestedFeatures` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/resolver/features.rs:187:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/features.rs:199:23 clippy::doc_markdown "you should put `RequestedFeatures` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/resolver/features.rs:200:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/features.rs:221:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/features.rs:231:21 clippy::doc_markdown "you should put `pkg_id/is_build` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/resolver/features.rs:233:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/features.rs:247:58 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/resolver/features.rs:278:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/resolver/features.rs:394:27 clippy::doc_markdown "you should put `FeatureValue` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/resolver/features.rs:460:19 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/core/resolver/features.rs:480:24 clippy::doc_markdown "you should put `FeatureValues` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/resolver/features.rs:496:24 clippy::doc_markdown "you should put `FeatureValues` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/resolver/features.rs:58:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/core/resolver/features.rs:67:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo-0.49.0/src/cargo/core/resolver/mod.rs:1017:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/core/resolver/mod.rs:1045:57 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/resolver/mod.rs:122:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/resolver/mod.rs:142:44 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/resolver/mod.rs:180:1 clippy::too_many_lines "this function has too many lines (225/100)" -cargo-0.49.0/src/cargo/core/resolver/mod.rs:311:17 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/core/resolver/mod.rs:421:52 clippy::filter_map_next "called `filter_map(..).next()` on an `Iterator`. This is more succinctly expressed by calling `.find_map(..)` instead" -cargo-0.49.0/src/cargo/core/resolver/mod.rs:457:69 clippy::filter_map_next "called `filter_map(..).next()` on an `Iterator`. This is more succinctly expressed by calling `.find_map(..)` instead" -cargo-0.49.0/src/cargo/core/resolver/mod.rs:470:37 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/core/resolver/mod.rs:607:11 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo-0.49.0/src/cargo/core/resolver/mod.rs:631:21 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/core/resolver/mod.rs:942:15 clippy::if_not_else "unnecessary boolean `not` operation" -cargo-0.49.0/src/cargo/core/resolver/mod.rs:988:20 clippy::redundant_else "redundant else block" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:120:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:132:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:199:24 clippy::redundant_else "redundant else block" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:235:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:239:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:255:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:259:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:263:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:269:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:273:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:274:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:280:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:284:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:288:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:292:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:296:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:300:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:315:13 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:354:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:362:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:60:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/core/resolver/resolve.rs:76:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/types.rs:111:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/resolver/types.rs:121:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/types.rs:141:19 clippy::doc_markdown "you should put `ResolveOpts` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/resolver/types.rs:142:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/types.rs:149:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/resolver/types.rs:181:9 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" -cargo-0.49.0/src/cargo/core/resolver/types.rs:187:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -cargo-0.49.0/src/cargo/core/resolver/types.rs:261:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -cargo-0.49.0/src/cargo/core/shell.rs:113:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/shell.rs:130:9 clippy::single_match_else "you seem to be trying to use `match` for an equality check. Consider using `if`" -cargo-0.49.0/src/cargo/core/shell.rs:148:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/shell.rs:153:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/shell.rs:163:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/shell.rs:18:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/shell.rs:198:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/shell.rs:206:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/shell.rs:214:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/shell.rs:228:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/shell.rs:239:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/shell.rs:250:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/shell.rs:259:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/shell.rs:267:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/shell.rs:26:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/shell.rs:277:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/shell.rs:282:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/shell.rs:314:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/shell.rs:322:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/shell.rs:330:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/shell.rs:345:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/shell.rs:459:9 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" -cargo-0.49.0/src/cargo/core/shell.rs:98:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/source/mod.rs:103:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/source/mod.rs:247:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/core/source/mod.rs:261:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/source/mod.rs:268:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/source/mod.rs:273:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/source/mod.rs:291:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/source/mod.rs:302:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/source/mod.rs:307:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/source/mod.rs:31:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/source/mod.rs:37:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/source/mod.rs:39:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/source/mod.rs:47:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/source/mod.rs:50:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/source/mod.rs:52:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/source/mod.rs:63:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/source/mod.rs:74:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/source/mod.rs:83:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/source/source_id.rs:107:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/source/source_id.rs:107:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/source/source_id.rs:128:50 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/source/source_id.rs:147:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/source/source_id.rs:156:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/source/source_id.rs:162:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/source/source_id.rs:166:19 clippy::doc_markdown "you should put `SourceId` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/source/source_id.rs:167:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/source/source_id.rs:171:19 clippy::doc_markdown "you should put `SourceId` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/source/source_id.rs:172:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/source/source_id.rs:178:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/source/source_id.rs:187:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/source/source_id.rs:187:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/source/source_id.rs:18:74 clippy::default_trait_access "calling `std::sync::Mutex::default()` is more clear than this expression" -cargo-0.49.0/src/cargo/core/source/source_id.rs:195:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/source/source_id.rs:207:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/source/source_id.rs:213:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/source/source_id.rs:217:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/source/source_id.rs:225:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/source/source_id.rs:228:16 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" -cargo-0.49.0/src/cargo/core/source/source_id.rs:236:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/source/source_id.rs:241:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/source/source_id.rs:252:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/source/source_id.rs:257:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/source/source_id.rs:262:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/source/source_id.rs:305:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/source/source_id.rs:310:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/source/source_id.rs:318:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/source/source_id.rs:326:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/source/source_id.rs:338:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/source/source_id.rs:355:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/source/source_id.rs:393:61 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:394:42 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:395:42 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:397:71 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:397:71 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:398:47 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:398:47 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:399:47 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:399:47 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:401:63 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:401:63 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:401:63 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:402:43 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:402:43 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:402:43 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:403:43 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:403:43 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:403:43 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:406:21 clippy::enum_glob_use "usage of wildcard import for enum variants" -cargo-0.49.0/src/cargo/core/source/source_id.rs:412:41 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:413:36 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:414:36 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:420:47 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:420:47 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/source/source_id.rs:512:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo-0.49.0/src/cargo/core/source/source_id.rs:513:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo-0.49.0/src/cargo/core/source/source_id.rs:517:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo-0.49.0/src/cargo/core/source/source_id.rs:518:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo-0.49.0/src/cargo/core/source/source_id.rs:525:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo-0.49.0/src/cargo/core/source/source_id.rs:526:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo-0.49.0/src/cargo/core/source/source_id.rs:530:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo-0.49.0/src/cargo/core/source/source_id.rs:531:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo-0.49.0/src/cargo/core/source/source_id.rs:535:33 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo-0.49.0/src/cargo/core/source/source_id.rs:536:37 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo-0.49.0/src/cargo/core/source/source_id.rs:537:42 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo-0.49.0/src/cargo/core/source/source_id.rs:538:38 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo-0.49.0/src/cargo/core/source/source_id.rs:548:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/core/source/source_id.rs:597:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/summary.rs:103:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/summary.rs:123:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/summary.rs:150:1 clippy::too_many_lines "this function has too many lines (141/100)" -cargo-0.49.0/src/cargo/core/summary.rs:158:9 clippy::enum_glob_use "usage of wildcard import for enum variants" -cargo-0.49.0/src/cargo/core/summary.rs:181:21 clippy::if_not_else "unnecessary boolean `not` operation" -cargo-0.49.0/src/cargo/core/summary.rs:192:28 clippy::redundant_else "redundant else block" -cargo-0.49.0/src/cargo/core/summary.rs:258:32 clippy::redundant_else "redundant else block" -cargo-0.49.0/src/cargo/core/summary.rs:281:28 clippy::redundant_else "redundant else block" -cargo-0.49.0/src/cargo/core/summary.rs:303:28 clippy::redundant_else "redundant else block" -cargo-0.49.0/src/cargo/core/summary.rs:321:51 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/core/summary.rs:344:5 clippy::doc_markdown "you should put `FeatureValue` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/summary.rs:350:85 clippy::doc_markdown "you should put `FeatureValue` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/summary.rs:36:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/summary.rs:378:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/summary.rs:386:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/summary.rs:387:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -cargo-0.49.0/src/cargo/core/summary.rs:407:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -cargo-0.49.0/src/cargo/core/summary.rs:69:34 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/summary.rs:75:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/summary.rs:78:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/summary.rs:81:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/summary.rs:84:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/summary.rs:87:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/summary.rs:90:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/summary.rs:93:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/summary.rs:96:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/summary.rs:99:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/workspace.rs:1056:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -cargo-0.49.0/src/cargo/core/workspace.rs:113:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/core/workspace.rs:1157:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/core/workspace.rs:128:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/core/workspace.rs:150:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/workspace.rs:159:16 clippy::redundant_else "redundant else block" -cargo-0.49.0/src/cargo/core/workspace.rs:197:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/workspace.rs:225:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/workspace.rs:225:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/workspace.rs:255:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/workspace.rs:267:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/workspace.rs:317:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/workspace.rs:329:37 clippy::doc_markdown "you should put `VirtualManifest` between ticks in the documentation" -cargo-0.49.0/src/cargo/core/workspace.rs:410:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/workspace.rs:440:9 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -cargo-0.49.0/src/cargo/core/workspace.rs:511:32 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/core/workspace.rs:561:25 clippy::non_ascii_literal "literal non-ASCII character detected" -cargo-0.49.0/src/cargo/core/workspace.rs:613:13 clippy::filter_map "called `filter_map(..).map(..)` on an `Iterator`" -cargo-0.49.0/src/cargo/core/workspace.rs:615:22 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/core/workspace.rs:762:27 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/core/workspace.rs:784:17 clippy::if_not_else "unnecessary boolean `not` operation" -cargo-0.49.0/src/cargo/core/workspace.rs:849:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/workspace.rs:849:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/core/workspace.rs:893:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/core/workspace.rs:906:24 clippy::redundant_else "redundant else block" -cargo-0.49.0/src/cargo/core/workspace.rs:932:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/lib.rs:177:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/lib.rs:177:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/lib.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.categories` metadata" -cargo-0.49.0/src/cargo/lib.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.keywords` metadata" -cargo-0.49.0/src/cargo/lib.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `crossbeam-utils`: 0.6.6, 0.7.2" -cargo-0.49.0/src/cargo/lib.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `hex`: 0.3.2, 0.4.0" -cargo-0.49.0/src/cargo/lib.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `humantime`: 1.3.0, 2.0.0" -cargo-0.49.0/src/cargo/ops/cargo_clean.rs:205:23 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/ops/cargo_clean.rs:27:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_clean.rs:27:1 clippy::too_many_lines "this function has too many lines (120/100)" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:1078:14 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:109:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:119:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:1227:17 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:127:35 clippy::from_iter_instead_of_collect "usage of `FromIterator::from_iter`" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:173:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:205:36 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:242:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:249:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:258:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:267:16 clippy::needless_question_mark "question mark operator is useless here" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:275:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:275:1 clippy::too_many_lines "this function has too many lines (219/100)" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:468:9 clippy::default_trait_access "calling `std::collections::HashMap::default()` is more clear than this expression" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:548:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:556:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:574:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:583:21 clippy::doc_markdown "you should put `CompileFilter` between ticks in the documentation" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:584:5 clippy::fn_params_excessive_bools "more than 3 bools in function parameters" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:584:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:592:9 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:593:9 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:607:13 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:612:21 clippy::doc_markdown "you should put `CompileFilter` between ticks in the documentation" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:613:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:618:9 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:641:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:652:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:655:50 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:673:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:692:49 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:703:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:729:1 clippy::too_many_lines "this function has too many lines (205/100)" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:82:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_compile.rs:874:69 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/ops/cargo_doc.rs:20:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_fetch.rs:15:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_fetch.rs:27:46 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:160:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:175:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:22:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:37:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:37:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:37:1 clippy::too_many_lines "this function has too many lines (171/100)" -cargo-0.49.0/src/cargo/ops/cargo_install.rs:13:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/cargo/ops/cargo_install.rs:148:1 clippy::fn_params_excessive_bools "more than 3 bools in function parameters" -cargo-0.49.0/src/cargo/ops/cargo_install.rs:148:1 clippy::too_many_lines "this function has too many lines (316/100)" -cargo-0.49.0/src/cargo/ops/cargo_install.rs:178:24 clippy::collapsible_else_if "this `else { if .. }` block can be collapsed" -cargo-0.49.0/src/cargo/ops/cargo_install.rs:202:17 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/ops/cargo_install.rs:236:16 clippy::collapsible_else_if "this `else { if .. }` block can be collapsed" -cargo-0.49.0/src/cargo/ops/cargo_install.rs:312:64 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/ops/cargo_install.rs:32:13 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" -cargo-0.49.0/src/cargo/ops/cargo_install.rs:339:12 clippy::collapsible_else_if "this `else { if .. }` block can be collapsed" -cargo-0.49.0/src/cargo/ops/cargo_install.rs:37:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_install.rs:454:22 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/ops/cargo_install.rs:483:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/ops/cargo_install.rs:683:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_install.rs:708:5 clippy::manual_flatten "unnecessary `if let` since only the `Some` variant of the iterator element is used" -cargo-0.49.0/src/cargo/ops/cargo_new.rs:101:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_new.rs:245:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/ops/cargo_new.rs:251:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/ops/cargo_new.rs:367:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_new.rs:405:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_new.rs:489:5 clippy::doc_markdown "you should put `IgnoreList` between ticks in the documentation" -cargo-0.49.0/src/cargo/ops/cargo_new.rs:525:47 clippy::doc_markdown "you should put `IgnoreList` between ticks in the documentation" -cargo-0.49.0/src/cargo/ops/cargo_new.rs:525:9 clippy::doc_markdown "you should put `format_existing` between ticks in the documentation" -cargo-0.49.0/src/cargo/ops/cargo_new.rs:572:34 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/ops/cargo_new.rs:623:1 clippy::too_many_lines "this function has too many lines (130/100)" -cargo-0.49.0/src/cargo/ops/cargo_new.rs:781:5 clippy::filter_map_next "called `filter_map(..).next()` on an `Iterator`. This is more succinctly expressed by calling `.find_map(..)` instead" -cargo-0.49.0/src/cargo/ops/cargo_new.rs:800:16 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/ops/cargo_output_metadata.rs:163:36 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/ops/cargo_output_metadata.rs:27:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_output_metadata.rs:45:45 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/ops/cargo_package.rs:144:1 clippy::too_many_lines "this function has too many lines (112/100)" -cargo-0.49.0/src/cargo/ops/cargo_package.rs:207:13 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/ops/cargo_package.rs:25:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo-0.49.0/src/cargo/ops/cargo_package.rs:307:54 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/ops/cargo_package.rs:394:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/ops/cargo_package.rs:425:61 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/ops/cargo_package.rs:459:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/ops/cargo_package.rs:66:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_package.rs:69:9 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" -cargo-0.49.0/src/cargo/ops/cargo_package.rs:93:20 clippy::if_not_else "unnecessary boolean `not` operation" -cargo-0.49.0/src/cargo/ops/cargo_pkgid.rs:5:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_read_manifest.rs:14:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_read_manifest.rs:171:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/ops/cargo_read_manifest.rs:37:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_read_manifest.rs:37:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/ops/cargo_read_manifest.rs:57:49 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/ops/cargo_read_manifest.rs:69:37 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/ops/cargo_run.rs:25:24 clippy::if_not_else "unnecessary boolean `not` operation" -cargo-0.49.0/src/cargo/ops/cargo_run.rs:35:9 clippy::if_not_else "unnecessary boolean `not` operation" -cargo-0.49.0/src/cargo/ops/cargo_run.rs:37:16 clippy::redundant_else "redundant else block" -cargo-0.49.0/src/cargo/ops/cargo_run.rs:53:9 clippy::if_not_else "unnecessary boolean `not` operation" -cargo-0.49.0/src/cargo/ops/cargo_run.rs:65:16 clippy::redundant_else "redundant else block" -cargo-0.49.0/src/cargo/ops/cargo_run.rs:9:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_test.rs:16:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_test.rs:43:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_test.rs:84:17 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/ops/cargo_uninstall.rs:14:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/cargo_uninstall.rs:7:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:147:9 clippy::doc_markdown "you should put `PackageId` between ticks in the documentation" -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:233:21 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:244:22 clippy::doc_markdown "you should put `PackageId` between ticks in the documentation" -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:244:63 clippy::doc_markdown "you should put `PackageId` between ticks in the documentation" -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:253:17 clippy::if_not_else "unnecessary boolean `not` operation" -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:370:5 clippy::unnecessary_wraps "this function's return value is unnecessary" -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:505:8 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:525:10 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:542:27 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:542:5 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:561:20 clippy::redundant_else "redundant else block" -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:613:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:645:41 clippy::doc_markdown "you should put `BTreeSet` between ticks in the documentation" -cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:92:19 clippy::doc_markdown "you should put `InstallTracker` between ticks in the documentation" -cargo-0.49.0/src/cargo/ops/fix.rs:200:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/fix.rs:200:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/ops/fix.rs:424:20 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" -cargo-0.49.0/src/cargo/ops/fix.rs:455:13 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/ops/fix.rs:506:17 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/ops/fix.rs:608:9 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" -cargo-0.49.0/src/cargo/ops/fix.rs:612:42 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/ops/fix.rs:619:48 clippy::manual_strip "stripping a prefix manually" -cargo-0.49.0/src/cargo/ops/fix.rs:66:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/ops/fix.rs:66:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo-0.49.0/src/cargo/ops/fix.rs:708:18 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/ops/fix.rs:77:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/lockfile.rs:154:13 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo-0.49.0/src/cargo/ops/lockfile.rs:217:9 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo-0.49.0/src/cargo/ops/lockfile.rs:30:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/lockfile.rs:35:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/lockfile.rs:35:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/ops/lockfile.rs:87:1 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -cargo-0.49.0/src/cargo/ops/lockfile.rs:8:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/lockfile.rs:8:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/ops/registry.rs:150:21 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/ops/registry.rs:188:1 clippy::too_many_lines "this function has too many lines (130/100)" -cargo-0.49.0/src/cargo/ops/registry.rs:212:32 clippy::if_not_else "unnecessary `!=` operation" -cargo-0.49.0/src/cargo/ops/registry.rs:222:53 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/ops/registry.rs:224:44 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/ops/registry.rs:31:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/ops/registry.rs:346:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/registry.rs:346:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/ops/registry.rs:351:26 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/ops/registry.rs:385:12 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo-0.49.0/src/cargo/ops/registry.rs:386:15 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo-0.49.0/src/cargo/ops/registry.rs:38:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo-0.49.0/src/cargo/ops/registry.rs:477:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/registry.rs:483:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/registry.rs:503:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/registry.rs:505:38 clippy::default_trait_access "calling `util::config::CargoHttpConfig::default()` is more clear than this expression" -cargo-0.49.0/src/cargo/ops/registry.rs:510:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/registry.rs:529:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/ops/registry.rs:53:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/registry.rs:53:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/ops/registry.rs:573:22 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/ops/registry.rs:608:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/registry.rs:621:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/registry.rs:671:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/registry.rs:671:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/ops/registry.rs:674:10 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo-0.49.0/src/cargo/ops/registry.rs:678:17 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/ops/registry.rs:730:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/registry.rs:731:16 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/ops/registry.rs:785:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/registry.rs:794:16 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/ops/registry.rs:828:14 clippy::doc_markdown "you should put `SourceId` between ticks in the documentation" -cargo-0.49.0/src/cargo/ops/registry.rs:848:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/resolve.rs:199:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/resolve.rs:199:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/ops/resolve.rs:199:1 clippy::too_many_lines "this function has too many lines (137/100)" -cargo-0.49.0/src/cargo/ops/resolve.rs:241:28 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/ops/resolve.rs:28:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/ops/resolve.rs:384:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/resolve.rs:417:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/resolve.rs:589:9 clippy::shadow_unrelated "`keep` is being shadowed" -cargo-0.49.0/src/cargo/ops/resolve.rs:58:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/resolve.rs:58:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/ops/resolve.rs:602:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/ops/resolve.rs:75:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/resolve.rs:75:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/ops/tree/graph.rs:129:26 clippy::doc_markdown "you should put `PackageIds` between ticks in the documentation" -cargo-0.49.0/src/cargo/ops/tree/graph.rs:152:15 clippy::match_on_vec_items "indexing into a vector may panic" -cargo-0.49.0/src/cargo/ops/tree/graph.rs:173:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/ops/tree/graph.rs:234:46 clippy::filter_map "called `filter(..).flat_map(..)` on an `Iterator`" -cargo-0.49.0/src/cargo/ops/tree/graph.rs:328:44 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/ops/tree/graph.rs:330:50 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/ops/tree/graph.rs:563:35 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/ops/tree/mod.rs:112:11 clippy::non_ascii_literal "literal non-ASCII character detected" -cargo-0.49.0/src/cargo/ops/tree/mod.rs:113:10 clippy::non_ascii_literal "literal non-ASCII character detected" -cargo-0.49.0/src/cargo/ops/tree/mod.rs:114:10 clippy::non_ascii_literal "literal non-ASCII character detected" -cargo-0.49.0/src/cargo/ops/tree/mod.rs:115:12 clippy::non_ascii_literal "literal non-ASCII character detected" -cargo-0.49.0/src/cargo/ops/tree/mod.rs:126:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/tree/mod.rs:21:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/ops/tree/mod.rs:21:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo-0.49.0/src/cargo/ops/tree/mod.rs:360:30 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/ops/tree/mod.rs:58:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/ops/vendor.rs:14:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/ops/vendor.rs:215:9 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" -cargo-0.49.0/src/cargo/ops/vendor.rs:21:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/ops/vendor.rs:21:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/ops/vendor.rs:314:34 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/ops/vendor.rs:320:29 clippy::case_sensitive_file_extension_comparisons "case-sensitive file extension comparison" -cargo-0.49.0/src/cargo/ops/vendor.rs:320:60 clippy::case_sensitive_file_extension_comparisons "case-sensitive file extension comparison" -cargo-0.49.0/src/cargo/ops/vendor.rs:324:13 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" -cargo-0.49.0/src/cargo/ops/vendor.rs:70:1 clippy::too_many_lines "this function has too many lines (175/100)" -cargo-0.49.0/src/cargo/sources/config.rs:102:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/config.rs:111:28 clippy::needless_question_mark "question mark operator is useless here" -cargo-0.49.0/src/cargo/sources/config.rs:133:48 clippy::needless_question_mark "question mark operator is useless here" -cargo-0.49.0/src/cargo/sources/config.rs:135:67 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/sources/config.rs:206:36 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo-0.49.0/src/cargo/sources/config.rs:282:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/sources/config.rs:70:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/config.rs:81:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/config.rs:97:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/sources/directory.rs:14:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/sources/directory.rs:90:56 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/sources/git/source.rs:14:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/sources/git/source.rs:25:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/git/source.rs:49:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/sources/git/source.rs:53:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/git/source.rs:53:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/sources/git/source.rs:69:20 clippy::comparison_to_empty "comparison to empty slice" -cargo-0.49.0/src/cargo/sources/git/utils.rs:1025:19 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/sources/git/utils.rs:1157:36 clippy::case_sensitive_file_extension_comparisons "case-sensitive file extension comparison" -cargo-0.49.0/src/cargo/sources/git/utils.rs:1158:9 clippy::manual_strip "stripping a suffix manually" -cargo-0.49.0/src/cargo/sources/git/utils.rs:176:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/sources/git/utils.rs:180:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/sources/git/utils.rs:184:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/git/utils.rs:188:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/git/utils.rs:242:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/git/utils.rs:253:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/git/utils.rs:262:13 clippy::if_not_else "unnecessary boolean `not` operation" -cargo-0.49.0/src/cargo/sources/git/utils.rs:289:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/git/utils.rs:294:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/sources/git/utils.rs:298:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/git/utils.rs:308:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/git/utils.rs:472:9 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" -cargo-0.49.0/src/cargo/sources/git/utils.rs:489:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/sources/git/utils.rs:503:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/sources/git/utils.rs:528:28 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/sources/git/utils.rs:537:21 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" -cargo-0.49.0/src/cargo/sources/git/utils.rs:588:1 clippy::too_many_lines "this function has too many lines (135/100)" -cargo-0.49.0/src/cargo/sources/git/utils.rs:692:9 clippy::vec_init_then_push "calls to `push` immediately after creation" -cargo-0.49.0/src/cargo/sources/git/utils.rs:758:9 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo-0.49.0/src/cargo/sources/git/utils.rs:858:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/path.rs:129:44 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/sources/path.rs:143:44 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/sources/path.rs:15:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/sources/path.rs:282:50 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/sources/path.rs:313:21 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/sources/path.rs:314:21 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/sources/path.rs:319:21 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/sources/path.rs:339:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/sources/path.rs:339:9 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -cargo-0.49.0/src/cargo/sources/path.rs:380:9 clippy::unused_self "unused `self` argument" -cargo-0.49.0/src/cargo/sources/path.rs:419:50 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/sources/path.rs:429:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/path.rs:460:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/sources/path.rs:473:43 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/sources/path.rs:482:43 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/sources/path.rs:63:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/path.rs:77:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/path.rs:98:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/registry/index.rs:117:23 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo-0.49.0/src/cargo/sources/registry/index.rs:121:70 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo-0.49.0/src/cargo/sources/registry/index.rs:167:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/sources/registry/index.rs:215:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/sources/registry/index.rs:324:23 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/sources/registry/index.rs:468:40 clippy::doc_markdown "you should put `SourceId` between ticks in the documentation" -cargo-0.49.0/src/cargo/sources/registry/index.rs:590:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/sources/registry/index.rs:648:17 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/sources/registry/index.rs:736:1 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -cargo-0.49.0/src/cargo/sources/registry/index.rs:95:37 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -cargo-0.49.0/src/cargo/sources/registry/local.rs:12:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/sources/registry/mod.rs:192:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/sources/registry/mod.rs:203:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/sources/registry/mod.rs:229:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/sources/registry/mod.rs:372:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/sources/registry/mod.rs:373:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/registry/mod.rs:375:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/registry/mod.rs:381:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/registry/mod.rs:382:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/registry/mod.rs:383:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/registry/mod.rs:384:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/registry/mod.rs:452:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/sources/registry/mod.rs:582:20 clippy::redundant_else "redundant else block" -cargo-0.49.0/src/cargo/sources/registry/mod.rs:621:9 clippy::if_not_else "unnecessary `!=` operation" -cargo-0.49.0/src/cargo/sources/registry/remote.rs:139:17 clippy::unused_self "unused `self` argument" -cargo-0.49.0/src/cargo/sources/registry/remote.rs:32:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/sources/registry/remote.rs:72:13 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/sources/replaced.rs:12:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/sources/replaced.rs:5:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/util/canonical_url.rs:19:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/canonical_url.rs:19:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/util/canonical_url.rs:50:41 clippy::case_sensitive_file_extension_comparisons "case-sensitive file extension comparison" -cargo-0.49.0/src/cargo/util/canonical_url.rs:65:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/command_prelude.rs:218:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/command_prelude.rs:222:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/command_prelude.rs:234:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/command_prelude.rs:249:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/command_prelude.rs:264:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/command_prelude.rs:279:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/command_prelude.rs:298:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/command_prelude.rs:320:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/command_prelude.rs:328:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/command_prelude.rs:352:13 clippy::if_not_else "unnecessary boolean `not` operation" -cargo-0.49.0/src/cargo/util/command_prelude.rs:363:13 clippy::if_not_else "unnecessary boolean `not` operation" -cargo-0.49.0/src/cargo/util/command_prelude.rs:378:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/command_prelude.rs:387:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/command_prelude.rs:387:5 clippy::too_many_lines "this function has too many lines (104/100)" -cargo-0.49.0/src/cargo/util/command_prelude.rs:39:20 clippy::doc_markdown "you should put `arg_package_spec` between ticks in the documentation" -cargo-0.49.0/src/cargo/util/command_prelude.rs:504:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/command_prelude.rs:516:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/command_prelude.rs:530:40 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/util/command_prelude.rs:531:43 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/util/command_prelude.rs:536:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/command_prelude.rs:556:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/command_prelude.rs:575:49 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/util/command_prelude.rs:580:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/command_prelude.rs:631:18 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/util/command_prelude.rs:638:18 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/util/command_prelude.rs:647:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/command_prelude.rs:651:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/command_prelude.rs:662:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/command_prelude.rs:665:51 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/util/config/de.rs:420:16 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo-0.49.0/src/cargo/util/config/de.rs:46:25 clippy::doc_markdown "you should put `CV::List` between ticks in the documentation" -cargo-0.49.0/src/cargo/util/config/de.rs:47:24 clippy::doc_markdown "you should put `ConfigSeqAccess` between ticks in the documentation" -cargo-0.49.0/src/cargo/util/config/de.rs:527:53 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo-0.49.0/src/cargo/util/config/de.rs:530:53 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo-0.49.0/src/cargo/util/config/de.rs:532:68 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo-0.49.0/src/cargo/util/config/key.rs:11:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/util/config/key.rs:69:9 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo-0.49.0/src/cargo/util/config/mod.rs:100:71 clippy::doc_markdown "you should put `OptValue` between ticks in the documentation" -cargo-0.49.0/src/cargo/util/config/mod.rs:100:71 clippy::doc_markdown "you should put `OptValue` between ticks in the documentation" -cargo-0.49.0/src/cargo/util/config/mod.rs:100:71 clippy::doc_markdown "you should put `OptValue` between ticks in the documentation" -cargo-0.49.0/src/cargo/util/config/mod.rs:1049:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:1064:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:1090:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:1166:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:1179:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:1181:33 clippy::needless_question_mark "question mark operator is useless here" -cargo-0.49.0/src/cargo/util/config/mod.rs:1184:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:1186:33 clippy::needless_question_mark "question mark operator is useless here" -cargo-0.49.0/src/cargo/util/config/mod.rs:1189:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:1191:33 clippy::needless_question_mark "question mark operator is useless here" -cargo-0.49.0/src/cargo/util/config/mod.rs:1203:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:1211:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:1216:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:1225:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:1229:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:124:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -cargo-0.49.0/src/cargo/util/config/mod.rs:1254:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:1279:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:1281:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -cargo-0.49.0/src/cargo/util/config/mod.rs:1323:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/util/config/mod.rs:1339:39 clippy::unused_self "unused `self` argument" -cargo-0.49.0/src/cargo/util/config/mod.rs:1344:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/util/config/mod.rs:1420:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/util/config/mod.rs:1553:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:1560:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:1567:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:1574:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:1581:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:1588:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/config/mod.rs:1598:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/config/mod.rs:1619:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/config/mod.rs:1623:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:1623:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:1623:64 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo-0.49.0/src/cargo/util/config/mod.rs:1649:9 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" -cargo-0.49.0/src/cargo/util/config/mod.rs:1699:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/util/config/mod.rs:1730:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/util/config/mod.rs:1757:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/util/config/mod.rs:1770:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/util/config/mod.rs:1778:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/util/config/mod.rs:1804:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/util/config/mod.rs:1896:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/config/mod.rs:1901:5 clippy::doc_markdown "you should put `StringList` between ticks in the documentation" -cargo-0.49.0/src/cargo/util/config/mod.rs:214:13 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" -cargo-0.49.0/src/cargo/util/config/mod.rs:259:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:298:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:311:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:318:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:353:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:401:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:411:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:419:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:431:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:449:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:454:16 clippy::option_if_let_else "use Option::map_or instead of an if let/else" -cargo-0.49.0/src/cargo/util/config/mod.rs:547:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:556:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:582:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:595:20 clippy::doc_markdown "you should put `StringList` between ticks in the documentation" -cargo-0.49.0/src/cargo/util/config/mod.rs:689:20 clippy::unused_self "unused `self` argument" -cargo-0.49.0/src/cargo/util/config/mod.rs:699:5 clippy::fn_params_excessive_bools "more than 3 bools in function parameters" -cargo-0.49.0/src/cargo/util/config/mod.rs:699:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/mod.rs:719:58 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/util/config/mod.rs:816:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/config/path.rs:10:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/util/config/path.rs:14:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/config/path.rs:48:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/util/config/target.rs:12:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/util/config/target.rs:24:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/util/config/value.rs:29:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/util/config/value.rs:70:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/util/config/value.rs:80:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/config/value.rs:81:9 clippy::match_like_matches_macro "match expression looks like `matches!` macro" -cargo-0.49.0/src/cargo/util/cpu.rs:11:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/cpu.rs:22:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/cpu.rs:82:25 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -cargo-0.49.0/src/cargo/util/cpu.rs:82:9 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -cargo-0.49.0/src/cargo/util/dependency_queue.rs:109:27 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/util/dependency_queue.rs:125:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/util/dependency_queue.rs:151:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/dependency_queue.rs:156:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/dependency_queue.rs:168:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/util/dependency_queue.rs:46:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/dependency_queue.rs:91:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/util/diagnostic_server.rs:218:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/util/diagnostic_server.rs:230:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/diagnostic_server.rs:242:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/diagnostic_server.rs:58:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/diagnostic_server.rs:96:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/diagnostic_server.rs:96:5 clippy::too_many_lines "this function has too many lines (110/100)" -cargo-0.49.0/src/cargo/util/diagnostic_server.rs:99:21 clippy::shadow_unrelated "`msg` is being shadowed" -cargo-0.49.0/src/cargo/util/errors.rs:101:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/errors.rs:143:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/errors.rs:150:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/errors.rs:15:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/errors.rs:237:5 clippy::pub_enum_variant_names "variant name ends with the enum's name" -cargo-0.49.0/src/cargo/util/errors.rs:245:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/errors.rs:321:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/errors.rs:328:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/errors.rs:356:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/errors.rs:391:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/util/errors.rs:392:13 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/cargo/util/errors.rs:465:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/errors.rs:473:5 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" -cargo-0.49.0/src/cargo/util/errors.rs:66:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/flock.rs:115:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/flock.rs:11:5 clippy::wildcard_imports "usage of wildcard import" -cargo-0.49.0/src/cargo/util/flock.rs:134:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/flock.rs:142:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/flock.rs:150:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/flock.rs:156:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/flock.rs:170:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/flock.rs:192:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/flock.rs:29:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/util/flock.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/flock.rs:321:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/util/flock.rs:335:23 clippy::cast_possible_truncation "casting `i64` to `u32` may truncate the value" -cargo-0.49.0/src/cargo/util/flock.rs:335:23 clippy::cast_sign_loss "casting `i64` to `u32` may lose the sign of the value" -cargo-0.49.0/src/cargo/util/flock.rs:335:44 clippy::cast_possible_truncation "casting `i64` to `u32` may truncate the value" -cargo-0.49.0/src/cargo/util/flock.rs:379:35 clippy::match_same_arms "this `match` has identical arm bodies" -cargo-0.49.0/src/cargo/util/flock.rs:37:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/flock.rs:43:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/util/flock.rs:43:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/flock.rs:52:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/flock.rs:52:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/util/flock.rs:96:17 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" -cargo-0.49.0/src/cargo/util/graph.rs:10:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/graph.rs:41:51 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/util/graph.rs:45:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/hasher.rs:12:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/hasher.rs:9:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/util/hex.rs:10:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" -cargo-0.49.0/src/cargo/util/hex.rs:11:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" -cargo-0.49.0/src/cargo/util/hex.rs:12:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" -cargo-0.49.0/src/cargo/util/hex.rs:13:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" -cargo-0.49.0/src/cargo/util/hex.rs:14:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" -cargo-0.49.0/src/cargo/util/hex.rs:15:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" -cargo-0.49.0/src/cargo/util/hex.rs:25:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/hex.rs:6:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/util/hex.rs:6:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/hex.rs:8:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" -cargo-0.49.0/src/cargo/util/hex.rs:9:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" -cargo-0.49.0/src/cargo/util/important_paths.rs:23:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/important_paths.rs:6:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/interning.rs:66:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/util/interning.rs:66:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/interning.rs:77:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/into_url.rs:10:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/into_url_with_base.rs:9:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/job.rs:20:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/lev_distance.rs:3:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/lockserver.rs:111:32 clippy::redundant_else "redundant else block" -cargo-0.49.0/src/cargo/util/lockserver.rs:158:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/lockserver.rs:46:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/lockserver.rs:58:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/lockserver.rs:62:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/mod.rs:68:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/mod.rs:79:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/network.rs:12:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/network.rs:19:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/network.rs:84:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/paths.rs:109:12 clippy::redundant_else "redundant else block" -cargo-0.49.0/src/cargo/util/paths.rs:114:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/paths.rs:121:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/paths.rs:125:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/paths.rs:130:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/paths.rs:14:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/paths.rs:14:1 clippy::module_name_repetitions "item name ends with its containing module's name" -cargo-0.49.0/src/cargo/util/paths.rs:151:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/paths.rs:167:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/paths.rs:173:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/paths.rs:178:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/paths.rs:185:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/paths.rs:199:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/paths.rs:215:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/paths.rs:228:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/paths.rs:251:9 clippy::option_if_let_else "use Option::map_or instead of an if let/else" -cargo-0.49.0/src/cargo/util/paths.rs:267:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/paths.rs:276:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/paths.rs:29:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/paths.rs:303:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/paths.rs:312:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/paths.rs:346:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/paths.rs:415:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/paths.rs:445:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/paths.rs:459:45 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/util/paths.rs:469:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/paths.rs:469:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/util/paths.rs:514:5 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" -cargo-0.49.0/src/cargo/util/paths.rs:54:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/paths.rs:61:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/paths.rs:63:19 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" -cargo-0.49.0/src/cargo/util/paths.rs:88:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/paths.rs:93:31 clippy::comparison_to_empty "comparison to empty slice" -cargo-0.49.0/src/cargo/util/process_builder.rs:106:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/process_builder.rs:111:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/process_builder.rs:122:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/process_builder.rs:132:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/process_builder.rs:152:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/process_builder.rs:185:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/process_builder.rs:190:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/process_builder.rs:218:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/process_builder.rs:218:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/util/process_builder.rs:278:22 clippy::inconsistent_struct_constructor "inconsistent struct constructor" -cargo-0.49.0/src/cargo/util/process_builder.rs:307:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/process_builder.rs:343:39 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -cargo-0.49.0/src/cargo/util/progress.rs:122:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/progress.rs:136:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/progress.rs:15:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/util/progress.rs:249:19 clippy::cast_precision_loss "casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -cargo-0.49.0/src/cargo/util/progress.rs:249:34 clippy::cast_precision_loss "casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -cargo-0.49.0/src/cargo/util/progress.rs:250:19 clippy::if_not_else "unnecessary boolean `not` operation" -cargo-0.49.0/src/cargo/util/progress.rs:263:22 clippy::cast_precision_loss "casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -cargo-0.49.0/src/cargo/util/progress.rs:264:22 clippy::cast_possible_truncation "casting `f64` to `usize` may truncate the value" -cargo-0.49.0/src/cargo/util/progress.rs:264:22 clippy::cast_sign_loss "casting `f64` to `usize` may lose the sign of the value" -cargo-0.49.0/src/cargo/util/progress.rs:269:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo-0.49.0/src/cargo/util/progress.rs:272:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo-0.49.0/src/cargo/util/progress.rs:274:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo-0.49.0/src/cargo/util/progress.rs:280:13 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo-0.49.0/src/cargo/util/progress.rs:282:9 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -cargo-0.49.0/src/cargo/util/progress.rs:89:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/progress.rs:97:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/queue.rs:25:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/queue.rs:36:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/util/queue.rs:42:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/util/queue.rs:52:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/util/queue.rs:69:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/util/read2.rs:11:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/read2.rs:31:17 clippy::similar_names "binding's name is too similar to existing binding" -cargo-0.49.0/src/cargo/util/restricted_names.rs:13:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/restricted_names.rs:26:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/restricted_names.rs:35:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/restricted_names.rs:45:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/restricted_names.rs:87:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/util/restricted_names.rs:87:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/restricted_names.rs:89:21 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/util/restricted_names.rs:8:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/rustc.rs:103:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/rustc.rs:103:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/util/rustc.rs:114:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" -cargo-0.49.0/src/cargo/util/rustc.rs:115:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" -cargo-0.49.0/src/cargo/util/rustc.rs:162:17 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/util/rustc.rs:39:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/sha256.rs:10:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/sha256.rs:16:9 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" -cargo-0.49.0/src/cargo/util/sha256.rs:20:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/sha256.rs:31:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/sha256.rs:40:24 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -cargo-0.49.0/src/cargo/util/to_semver.rs:5:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/toml/mod.rs:1005:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/toml/mod.rs:1005:5 clippy::too_many_lines "this function has too many lines (282/100)" -cargo-0.49.0/src/cargo/util/toml/mod.rs:1094:36 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/util/toml/mod.rs:1121:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/util/toml/mod.rs:1197:32 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" -cargo-0.49.0/src/cargo/util/toml/mod.rs:124:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/toml/mod.rs:1504:9 clippy::unused_self "unused `self` argument" -cargo-0.49.0/src/cargo/util/toml/mod.rs:1526:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/toml/mod.rs:1582:19 clippy::default_trait_access "calling `util::toml::DetailedTomlDependency::default()` is more clear than this expression" -cargo-0.49.0/src/cargo/util/toml/mod.rs:1598:5 clippy::too_many_lines "this function has too many lines (153/100)" -cargo-0.49.0/src/cargo/util/toml/mod.rs:1687:33 clippy::unnecessary_lazy_evaluations "unnecessary closure used to substitute value for `Option::None`" -cargo-0.49.0/src/cargo/util/toml/mod.rs:178:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/util/toml/mod.rs:248:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/util/toml/mod.rs:274:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/util/toml/mod.rs:277:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/toml/mod.rs:281:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/toml/mod.rs:285:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/toml/mod.rs:294:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/util/toml/mod.rs:31:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/toml/mod.rs:381:35 clippy::cast_possible_truncation "casting `i64` to `u32` may truncate the value" -cargo-0.49.0/src/cargo/util/toml/mod.rs:381:35 clippy::cast_sign_loss "casting `i64` to `u32` may lose the sign of the value" -cargo-0.49.0/src/cargo/util/toml/mod.rs:388:35 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" -cargo-0.49.0/src/cargo/util/toml/mod.rs:398:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/util/toml/mod.rs:450:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/toml/mod.rs:536:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/toml/mod.rs:783:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/util/toml/mod.rs:824:1 clippy::module_name_repetitions "item name starts with its containing module's name" -cargo-0.49.0/src/cargo/util/toml/mod.rs:834:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/toml/mod.rs:83:42 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/util/toml/mod.rs:852:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/toml/mod.rs:852:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -cargo-0.49.0/src/cargo/util/toml/mod.rs:852:5 clippy::too_many_lines "this function has too many lines (138/100)" -cargo-0.49.0/src/cargo/util/toml/mod.rs:962:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/util/toml/mod.rs:979:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/util/toml/mod.rs:98:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/util/toml/mod.rs:999:23 clippy::default_trait_access "calling `util::toml::DetailedTomlDependency::default()` is more clear than this expression" -cargo-0.49.0/src/cargo/util/toml/targets.rs:112:27 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/util/toml/targets.rs:325:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -cargo-0.49.0/src/cargo/util/toml/targets.rs:586:21 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/util/toml/targets.rs:593:42 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/util/toml/targets.rs:605:19 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/util/toml/targets.rs:612:42 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/util/toml/targets.rs:756:36 clippy::redundant_closure_for_method_calls "redundant closure found" -cargo-0.49.0/src/cargo/util/vcs.rs:10:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -cargo-0.49.0/src/cargo/util/vcs.rs:33:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/vcs.rs:37:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/vcs.rs:43:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/vcs.rs:47:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/vcs.rs:59:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/vcs.rs:66:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/workspace.rs:52:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/workspace.rs:56:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/workspace.rs:60:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -cargo-0.49.0/src/cargo/util/workspace.rs:64:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron-0.6.1/src/error.rs:24:1 clippy::module_name_repetitions "item name ends with its containing module's name" -iron-0.6.1/src/iron.rs:105:13 clippy::redundant_field_names "redundant field names in struct initialization" -iron-0.6.1/src/iron.rs:119:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron-0.6.1/src/iron.rs:133:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron-0.6.1/src/iron.rs:143:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron-0.6.1/src/iron.rs:149:13 clippy::redundant_field_names "redundant field names in struct initialization" -iron-0.6.1/src/iron.rs:167:49 clippy::similar_names "binding's name is too similar to existing binding" -iron-0.6.1/src/iron.rs:196:9 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" -iron-0.6.1/src/iron.rs:80:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron-0.6.1/src/iron.rs:85:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron-0.6.1/src/iron.rs:90:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron-0.6.1/src/lib.rs:1:null clippy::cargo_common_metadata "package `iron` is missing `package.categories` metadata" -iron-0.6.1/src/lib.rs:1:null clippy::cargo_common_metadata "package `iron` is missing `package.keywords` metadata" -iron-0.6.1/src/lib.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `log`: 0.3.9, 0.4.8" -iron-0.6.1/src/middleware/mod.rs:137:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron-0.6.1/src/middleware/mod.rs:150:1 clippy::module_name_repetitions "item name ends with its containing module's name" -iron-0.6.1/src/middleware/mod.rs:152:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron-0.6.1/src/middleware/mod.rs:159:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron-0.6.1/src/middleware/mod.rs:171:1 clippy::module_name_repetitions "item name ends with its containing module's name" -iron-0.6.1/src/middleware/mod.rs:173:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron-0.6.1/src/middleware/mod.rs:182:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron-0.6.1/src/middleware/mod.rs:192:1 clippy::module_name_repetitions "item name ends with its containing module's name" -iron-0.6.1/src/middleware/mod.rs:217:25 clippy::doc_markdown "you should put `ChainBuilder` between ticks in the documentation" -iron-0.6.1/src/middleware/mod.rs:264:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -iron-0.6.1/src/middleware/mod.rs:328:20 clippy::similar_names "binding's name is too similar to existing binding" -iron-0.6.1/src/middleware/mod.rs:360:16 clippy::similar_names "binding's name is too similar to existing binding" -iron-0.6.1/src/middleware/mod.rs:368:33 clippy::similar_names "binding's name is too similar to existing binding" -iron-0.6.1/src/middleware/mod.rs:428:40 clippy::similar_names "binding's name is too similar to existing binding" -iron-0.6.1/src/middleware/mod.rs:434:40 clippy::similar_names "binding's name is too similar to existing binding" -iron-0.6.1/src/middleware/mod.rs:444:40 clippy::similar_names "binding's name is too similar to existing binding" -iron-0.6.1/src/modifiers.rs:132:14 clippy::expect_fun_call "use of `expect` followed by a function call" -iron-0.6.1/src/request/mod.rs:113:24 clippy::similar_names "binding's name is too similar to existing binding" -iron-0.6.1/src/request/mod.rs:121:13 clippy::redundant_field_names "redundant field names in struct initialization" -iron-0.6.1/src/request/mod.rs:123:13 clippy::redundant_field_names "redundant field names in struct initialization" -iron-0.6.1/src/request/mod.rs:124:13 clippy::redundant_field_names "redundant field names in struct initialization" -iron-0.6.1/src/request/mod.rs:126:13 clippy::redundant_field_names "redundant field names in struct initialization" -iron-0.6.1/src/request/mod.rs:128:13 clippy::redundant_field_names "redundant field names in struct initialization" -iron-0.6.1/src/request/mod.rs:153:69 clippy::doc_markdown "you should put `HttpReader` between ticks in the documentation" -iron-0.6.1/src/request/mod.rs:154:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron-0.6.1/src/request/mod.rs:32:1 clippy::manual_non_exhaustive "this seems like a manual implementation of the non-exhaustive pattern" -iron-0.6.1/src/request/mod.rs:75:34 clippy::doc_markdown "you should put `HttpRequest` between ticks in the documentation" -iron-0.6.1/src/request/mod.rs:77:39 clippy::doc_markdown "you should put `HttpRequest` between ticks in the documentation" -iron-0.6.1/src/request/mod.rs:78:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron-0.6.1/src/request/mod.rs:82:13 clippy::similar_names "binding's name is too similar to existing binding" -iron-0.6.1/src/request/mod.rs:83:29 clippy::similar_names "binding's name is too similar to existing binding" -iron-0.6.1/src/request/mod.rs:85:24 clippy::similar_names "binding's name is too similar to existing binding" -iron-0.6.1/src/request/url.rs:109:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron-0.6.1/src/request/url.rs:117:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron-0.6.1/src/request/url.rs:129:1 clippy::from_over_into "an implementation of `From` is preferred since it gives you `Into<_>` for free where the reverse isn't true" -iron-0.6.1/src/request/url.rs:21:14 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" -iron-0.6.1/src/request/url.rs:22:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron-0.6.1/src/request/url.rs:31:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron-0.6.1/src/request/url.rs:47:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron-0.6.1/src/request/url.rs:52:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron-0.6.1/src/request/url.rs:57:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -iron-0.6.1/src/request/url.rs:57:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron-0.6.1/src/request/url.rs:63:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -iron-0.6.1/src/request/url.rs:63:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron-0.6.1/src/request/url.rs:73:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -iron-0.6.1/src/request/url.rs:73:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron-0.6.1/src/request/url.rs:83:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron-0.6.1/src/request/url.rs:96:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron-0.6.1/src/response.rs:121:19 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -iron-0.6.1/src/response.rs:125:43 clippy::redundant_closure_for_method_calls "redundant closure found" -iron-0.6.1/src/response.rs:139:41 clippy::redundant_closure_for_method_calls "redundant closure found" -iron-0.6.1/src/response.rs:24:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -iron-0.6.1/src/response.rs:95:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -iron-0.6.1/src/response.rs:95:5 clippy::new_without_default "you should consider adding a `Default` implementation for `response::Response`" -libc-0.2.81/build.rs:114:19 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" -libc-0.2.81/build.rs:124:5 clippy::question_mark "this block may be rewritten with the `?` operator" -libc-0.2.81/build.rs:133:5 clippy::question_mark "this block may be rewritten with the `?` operator" -libc-0.2.81/src/macros.rs:243:17 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" -libc-0.2.81/src/macros.rs:243:17 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" -libc-0.2.81/src/macros.rs:243:17 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" -libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:428:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:429:30 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:431:30 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:432:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:433:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:434:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:595:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:596:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:597:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:622:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:673:34 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:696:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:697:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:698:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:699:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:712:34 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:721:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:722:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:723:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:751:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:752:30 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:753:30 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:754:30 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:755:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:756:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:757:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:758:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:759:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:760:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:768:30 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:769:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:771:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:772:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:773:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:774:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:775:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:776:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:777:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:778:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:779:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:780:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:781:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:782:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:783:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:784:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:785:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:786:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:787:30 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:788:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:789:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:790:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:791:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:792:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:794:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:795:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:796:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:797:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:798:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:799:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:800:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:801:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:803:27 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:804:28 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:805:28 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:806:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:807:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:808:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:809:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:810:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:811:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:812:30 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:813:30 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:814:30 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:815:30 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:816:30 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:817:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:818:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:821:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:822:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:823:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:824:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:825:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:826:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:827:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:828:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:829:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:830:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:831:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:832:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:833:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:834:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:835:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:836:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:841:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:842:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:843:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:844:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:1120:38 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:178:34 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:291:5 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:291:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:299:11 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:302:5 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:302:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:312:11 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:352:20 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:355:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:355:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:359:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:359:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:363:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:363:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:367:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:367:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:371:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:371:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:534:36 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:645:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:727:40 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:728:40 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:729:39 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:731:44 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:732:36 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:733:41 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:734:43 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:735:42 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:736:40 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:737:36 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:738:37 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:741:39 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:742:40 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:743:40 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:744:40 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:745:40 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:746:43 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:747:42 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:748:40 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:749:39 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:750:41 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:751:41 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:752:43 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:753:42 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:755:42 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:756:41 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:757:41 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:758:39 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:759:39 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:761:41 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:762:44 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:763:45 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:764:40 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:765:40 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:766:40 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:767:44 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:768:44 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:769:39 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:770:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:771:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:772:37 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:773:39 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:774:45 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:775:41 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:776:39 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:803:34 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:841:30 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:842:37 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:982:40 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:984:46 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1209:36 clippy::cast_possible_truncation "casting `i32` to `i16` may truncate the value" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1210:36 clippy::cast_possible_truncation "casting `i32` to `i16` may truncate the value" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1235:39 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1236:41 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1274:42 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1324:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1333:37 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1334:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1346:34 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1346:34 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1346:34 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1347:37 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1347:37 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1347:37 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1348:36 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1348:36 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1348:36 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1349:37 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1349:37 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1349:37 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1350:35 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1350:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1350:35 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1351:36 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1351:36 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1351:36 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1352:31 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1352:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1352:31 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1419:36 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1420:36 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1421:36 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1422:36 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1423:36 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1490:37 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1561:46 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1562:45 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1567:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1568:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1586:26 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1587:34 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1588:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1589:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1897:38 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1898:51 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1900:39 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1969:34 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1970:34 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1971:36 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1972:36 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1973:36 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1974:37 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1975:37 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1976:36 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1977:36 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1978:39 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1979:39 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1980:39 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1981:39 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1982:39 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1983:39 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1984:38 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1985:38 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1986:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1987:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1988:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1989:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1990:38 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1991:37 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1992:37 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1993:38 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1994:37 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1995:37 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1996:37 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1997:37 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1998:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:1999:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2000:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2001:34 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2002:34 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2003:34 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2004:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2005:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2032:30 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2033:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2034:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2035:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2036:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2037:28 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2038:27 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2039:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2041:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2042:28 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2043:27 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2044:34 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2045:27 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2046:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2048:28 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2049:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2050:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2051:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2052:26 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2053:36 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2318:42 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2321:38 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2331:39 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2487:42 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2488:42 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2489:43 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2490:43 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2491:43 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2493:47 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2494:44 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2495:46 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2496:47 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2497:49 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2498:48 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2499:50 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2500:45 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2572:9 clippy::needless_return "unneeded `return` statement" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2578:20 clippy::zero_ptr "`0 as *mut _` detected" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2588:13 clippy::zero_ptr "`0 as *mut _` detected" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2590:13 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2596:52 clippy::used_underscore_binding "used binding `_dummy` which is prefixed with an underscore. A leading underscore signals that a binding will not be used" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2597:11 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2601:21 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2611:9 clippy::unused_unit "unneeded unit expression" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2619:9 clippy::unused_unit "unneeded unit expression" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2634:9 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2647:25 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2648:25 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2649:9 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2654:18 clippy::identity_op "the operation is ineffective. Consider reducing it to `(dev & 0x00000000000000ff)`" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2654:25 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2655:25 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2656:9 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2660:21 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2661:21 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2663:25 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2664:25 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2665:16 clippy::identity_op "the operation is ineffective. Consider reducing it to `(minor & 0x000000ff)`" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2665:25 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:2666:25 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/linux/mod.rs:954:34 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1000:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1001:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1002:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1016:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1017:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1018:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1019:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1020:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1029:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1030:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1031:30 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1032:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1033:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1034:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1035:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1041:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1042:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1043:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1044:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1045:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1046:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1047:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1048:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1049:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1050:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1051:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1053:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1054:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1055:30 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1056:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1057:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1058:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1059:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1060:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1073:42 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1074:43 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1075:37 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1076:37 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1077:41 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1078:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1079:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1080:36 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1081:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1082:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1083:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1084:38 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1086:30 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1087:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1089:30 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1090:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1091:30 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1094:40 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1095:37 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1096:41 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1097:40 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1098:39 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1099:34 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1100:36 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1101:38 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1102:37 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1105:44 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1106:41 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1107:42 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1108:42 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1109:41 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1110:46 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1111:41 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1112:44 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1113:40 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1114:47 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1115:36 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1126:34 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1127:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1128:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1179:32 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1180:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:1218:27 clippy::identity_op "the operation is ineffective. Consider reducing it to `IPOPT_CONTROL`" -libc-0.2.81/src/unix/linux_like/mod.rs:1314:9 clippy::precedence "operator precedence can trip the unwary" -libc-0.2.81/src/unix/linux_like/mod.rs:1321:13 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" -libc-0.2.81/src/unix/linux_like/mod.rs:1323:13 clippy::zero_ptr "`0 as *mut _` detected" -libc-0.2.81/src/unix/linux_like/mod.rs:1332:9 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -libc-0.2.81/src/unix/linux_like/mod.rs:1337:9 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -libc-0.2.81/src/unix/linux_like/mod.rs:1341:18 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" -libc-0.2.81/src/unix/linux_like/mod.rs:1344:9 clippy::needless_return "unneeded `return` statement" -libc-0.2.81/src/unix/linux_like/mod.rs:1348:18 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" -libc-0.2.81/src/unix/linux_like/mod.rs:1350:9 clippy::needless_return "unneeded `return` statement" -libc-0.2.81/src/unix/linux_like/mod.rs:1354:18 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" -libc-0.2.81/src/unix/linux_like/mod.rs:1357:9 clippy::needless_return "unneeded `return` statement" -libc-0.2.81/src/unix/linux_like/mod.rs:1361:21 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" -libc-0.2.81/src/unix/linux_like/mod.rs:1381:9 clippy::cast_possible_truncation "casting `i32` to `i8` may truncate the value" -libc-0.2.81/src/unix/linux_like/mod.rs:1389:9 clippy::verbose_bit_mask "bit mask could be simplified with a call to `trailing_zeros`" -libc-0.2.81/src/unix/linux_like/mod.rs:446:31 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:591:36 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:592:38 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:593:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:594:33 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:595:34 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:596:36 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:597:37 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:598:37 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:599:39 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:600:34 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:601:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:602:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:607:37 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:608:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:764:35 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:765:39 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/linux_like/mod.rs:991:30 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/mod.rs:198:29 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/mod.rs:199:28 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/mod.rs:201:35 clippy::unnecessary_cast "casting integer literal to `usize` is unnecessary" -libc-0.2.81/src/unix/mod.rs:202:35 clippy::unnecessary_cast "casting integer literal to `usize` is unnecessary" -libc-0.2.81/src/unix/mod.rs:282:40 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/mod.rs:284:41 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/mod.rs:285:36 clippy::unreadable_literal "long literal lacking separators" -libc-0.2.81/src/unix/mod.rs:34:10 clippy::upper_case_acronyms "name `DIR` contains a capitalized acronym" -libc-0.2.81/src/unix/mod.rs:386:10 clippy::upper_case_acronyms "name `FILE` contains a capitalized acronym" -log-0.4.11/src/lib.rs:1047:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:1053:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:1059:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:1093:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:1093:5 clippy::new_without_default "you should consider adding a `Default` implementation for `MetadataBuilder<'a>`" -log-0.4.11/src/lib.rs:1118:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:1177:1 clippy::inline_always "you have declared `#[inline(always)]` on `max_level`. This is usually a bad idea" -log-0.4.11/src/lib.rs:1178:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:1306:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -log-0.4.11/src/lib.rs:1358:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:1359:5 clippy::if_not_else "unnecessary `!=` operation" -log-0.4.11/src/lib.rs:1407:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:356:1 clippy::expl_impl_clone_on_copy "you are implementing `Clone` explicitly on a `Copy` type" -log-0.4.11/src/lib.rs:448:12 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" -log-0.4.11/src/lib.rs:500:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:506:28 clippy::trivially_copy_pass_by_ref "this argument (8 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -log-0.4.11/src/lib.rs:506:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -log-0.4.11/src/lib.rs:506:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:538:1 clippy::expl_impl_clone_on_copy "you are implementing `Clone` explicitly on a `Copy` type" -log-0.4.11/src/lib.rs:653:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:661:21 clippy::trivially_copy_pass_by_ref "this argument (8 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -log-0.4.11/src/lib.rs:661:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:677:44 clippy::match_same_arms "this `match` has identical arm bodies" -log-0.4.11/src/lib.rs:758:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:764:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:770:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:776:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:782:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:788:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:794:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:803:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:809:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:818:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:908:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -log-0.4.11/src/lib.rs:908:5 clippy::new_without_default "you should consider adding a `Default` implementation for `RecordBuilder<'a>`" -log-0.4.11/src/lib.rs:995:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/detection.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -proc-macro2-1.0.24/src/fallback.rs:108:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" -proc-macro2-1.0.24/src/fallback.rs:269:20 clippy::unused_self "unused `self` argument" -proc-macro2-1.0.24/src/fallback.rs:430:24 clippy::trivially_copy_pass_by_ref "this argument (0 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -proc-macro2-1.0.24/src/fallback.rs:437:23 clippy::trivially_copy_pass_by_ref "this argument (0 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -proc-macro2-1.0.24/src/fallback.rs:437:23 clippy::unused_self "unused `self` argument" -proc-macro2-1.0.24/src/fallback.rs:471:17 clippy::trivially_copy_pass_by_ref "this argument (0 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -proc-macro2-1.0.24/src/fallback.rs:471:17 clippy::unused_self "unused `self` argument" -proc-macro2-1.0.24/src/fallback.rs:654:5 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" -proc-macro2-1.0.24/src/fallback.rs:655:12 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" -proc-macro2-1.0.24/src/fallback.rs:661:5 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" -proc-macro2-1.0.24/src/fallback.rs:662:12 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" -proc-macro2-1.0.24/src/fallback.rs:664:12 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" -proc-macro2-1.0.24/src/fallback.rs:674:37 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" -proc-macro2-1.0.24/src/fallback.rs:678:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -proc-macro2-1.0.24/src/fallback.rs:85:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -proc-macro2-1.0.24/src/fallback.rs:882:43 clippy::unused_self "unused `self` argument" -proc-macro2-1.0.24/src/lib.rs:1017:9 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:1081:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:1099:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:1117:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:1135:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:1141:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:1146:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:1151:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:1156:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:152:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:157:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:373:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:383:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:397:24 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -proc-macro2-1.0.24/src/lib.rs:397:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:403:23 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -proc-macro2-1.0.24/src/lib.rs:403:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:418:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:425:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:464:17 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -proc-macro2-1.0.24/src/lib.rs:500:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:626:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:633:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:641:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:652:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:662:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:672:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:734:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:743:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:752:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:757:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:788:19 clippy::doc_markdown "you should put `XID_Start` between ticks in the documentation" -proc-macro2-1.0.24/src/lib.rs:788:69 clippy::doc_markdown "you should put `XID_Continue` between ticks in the documentation" -proc-macro2-1.0.24/src/lib.rs:891:36 clippy::doc_markdown "you should put `syn::parse_str` between ticks in the documentation" -proc-macro2-1.0.24/src/lib.rs:894:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:911:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/lib.rs:996:9 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -proc-macro2-1.0.24/src/parse.rs:552:5 clippy::while_let_on_iterator "this loop could be written as a `for` loop" -proc-macro2-1.0.24/src/parse.rs:584:21 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" -proc-macro2-1.0.24/src/parse.rs:602:20 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" -proc-macro2-1.0.24/src/parse.rs:696:29 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" -proc-macro2-1.0.24/src/parse.rs:702:34 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" -proc-macro2-1.0.24/src/parse.rs:708:34 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" -proc-macro2-1.0.24/src/parse.rs:793:5 clippy::vec_init_then_push "calls to `push` immediately after creation" -proc-macro2-1.0.24/src/parse.rs:803:15 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" -proc-macro2-1.0.24/src/parse.rs:808:15 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" -proc-macro2-1.0.24/src/wrapper.rs:415:24 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -proc-macro2-1.0.24/src/wrapper.rs:429:23 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -proc-macro2-1.0.24/src/wrapper.rs:492:17 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -puffin-02dd4a3/puffin-imgui/src/ui.rs:158:15 clippy::cast_precision_loss "casting `i64` to `f32` causes a loss of precision (`i64` is 64 bits wide, but `f32`'s mantissa is only 23 bits wide)" -puffin-02dd4a3/puffin-imgui/src/ui.rs:175:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -puffin-02dd4a3/puffin-imgui/src/ui.rs:183:5 clippy::too_many_lines "this function has too many lines (115/100)" -puffin-02dd4a3/puffin-imgui/src/ui.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -puffin-02dd4a3/puffin-imgui/src/ui.rs:207:16 clippy::collapsible_else_if "this `else { if .. }` block can be collapsed" -puffin-02dd4a3/puffin-imgui/src/ui.rs:271:67 clippy::cast_precision_loss "casting `i64` to `f32` causes a loss of precision (`i64` is 64 bits wide, but `f32`'s mantissa is only 23 bits wide)" -puffin-02dd4a3/puffin-imgui/src/ui.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -puffin-02dd4a3/puffin-imgui/src/ui.rs:376:29 clippy::cast_precision_loss "casting `i64` to `f32` causes a loss of precision (`i64` is 64 bits wide, but `f32`'s mantissa is only 23 bits wide)" -puffin-02dd4a3/puffin-imgui/src/ui.rs:381:44 clippy::cast_precision_loss "casting `i64` to `f32` causes a loss of precision (`i64` is 64 bits wide, but `f32`'s mantissa is only 23 bits wide)" -puffin-02dd4a3/puffin-imgui/src/ui.rs:453:9 clippy::similar_names "binding's name is too similar to existing binding" -puffin-02dd4a3/puffin-imgui/src/ui.rs:540:14 clippy::cast_possible_truncation "casting `f64` to `f32` may truncate the value" -puffin-02dd4a3/puffin-imgui/src/ui.rs:551:5 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -puffin-02dd4a3/puffin-imgui/src/ui.rs:584:39 clippy::cast_precision_loss "casting `usize` to `f32` causes a loss of precision (`usize` is 32 or 64 bits wide, but `f32`'s mantissa is only 23 bits wide)" -puffin-02dd4a3/puffin-imgui/src/ui.rs:59:26 clippy::unsafe_derive_deserialize "you are deriving `serde::Deserialize` on a type that has methods using `unsafe`" -puffin-02dd4a3/puffin-imgui/src/ui.rs:61:1 clippy::module_name_repetitions "item name ends with its containing module's name" -puffin-02dd4a3/puffin-imgui/src/ui.rs:627:39 clippy::cast_precision_loss "casting `usize` to `f32` causes a loss of precision (`usize` is 32 or 64 bits wide, but `f32`'s mantissa is only 23 bits wide)" -puffin-02dd4a3/puffin-imgui/src/ui.rs:674:47 clippy::cast_precision_loss "casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -puffin-02dd4a3/puffin-imgui/src/ui.rs:690:9 clippy::cast_precision_loss "casting `usize` to `f32` causes a loss of precision (`usize` is 32 or 64 bits wide, but `f32`'s mantissa is only 23 bits wide)" -puffin-02dd4a3/puffin/src/data.rs:102:25 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" -puffin-02dd4a3/puffin/src/data.rs:112:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -puffin-02dd4a3/puffin/src/data.rs:116:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -puffin-02dd4a3/puffin/src/data.rs:137:24 clippy::match_same_arms "this `match` has identical arm bodies" -puffin-02dd4a3/puffin/src/data.rs:177:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -puffin-02dd4a3/puffin/src/data.rs:211:21 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -puffin-02dd4a3/puffin/src/data.rs:24:5 clippy::wildcard_imports "usage of wildcard import" -puffin-02dd4a3/puffin/src/lib.rs:113:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -puffin-02dd4a3/puffin/src/lib.rs:147:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -puffin-02dd4a3/puffin/src/lib.rs:147:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -puffin-02dd4a3/puffin/src/lib.rs:165:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -puffin-02dd4a3/puffin/src/lib.rs:200:21 clippy::default_trait_access "calling `Stream::default()` is more clear than this expression" -puffin-02dd4a3/puffin/src/lib.rs:257:78 clippy::default_trait_access "calling `std::cell::RefCell::default()` is more clear than this expression" -puffin-02dd4a3/puffin/src/lib.rs:297:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -puffin-02dd4a3/puffin/src/lib.rs:302:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -puffin-02dd4a3/puffin/src/lib.rs:308:28 clippy::default_trait_access "calling `FullProfileData::default()` is more clear than this expression" -puffin-02dd4a3/puffin/src/lib.rs:316:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -puffin-02dd4a3/puffin/src/lib.rs:321:5 clippy::cast_possible_truncation "casting `u128` to `i64` may truncate the value" -puffin-02dd4a3/puffin/src/lib.rs:348:28 clippy::default_trait_access "calling `std::marker::PhantomData::default()` is more clear than this expression" -puffin-02dd4a3/puffin/src/lib.rs:359:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -puffin-02dd4a3/puffin/src/lib.rs:375:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -puffin-02dd4a3/puffin/src/lib.rs:376:5 clippy::option_if_let_else "use Option::map_or instead of an if let/else" -puffin-02dd4a3/puffin/src/lib.rs:377:9 clippy::option_if_let_else "use Option::map_or instead of an if let/else" -puffin-02dd4a3/puffin/src/lib.rs:406:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -puffin-02dd4a3/puffin/src/lib.rs:408:5 clippy::option_if_let_else "use Option::map_or instead of an if let/else" -puffin-02dd4a3/puffin/src/lib.rs:69:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -puffin-02dd4a3/puffin/src/lib.rs:73:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -puffin-02dd4a3/puffin/src/lib.rs:77:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -puffin-02dd4a3/puffin/src/merge.rs:21:1 clippy::module_name_repetitions "item name starts with its containing module's name" -puffin-02dd4a3/puffin/src/merge.rs:28:1 clippy::module_name_repetitions "item name starts with its containing module's name" -puffin-02dd4a3/puffin/src/merge.rs:28:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -puffin-02dd4a3/puffin/src/merge.rs:35:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -puffin-02dd4a3/puffin/src/merge.rs:35:1 clippy::module_name_repetitions "item name starts with its containing module's name" -puffin-02dd4a3/puffin/src/merge.rs:64:43 clippy::default_trait_access "calling `std::vec::Vec::default()` is more clear than this expression" -puffin-02dd4a3/puffin/src/merge.rs:65:54 clippy::default_trait_access "calling `std::collections::HashMap::default()` is more clear than this expression" -puffin-02dd4a3/puffin/src/merge.rs:9:1 clippy::module_name_repetitions "item name starts with its containing module's name" -quote-1.0.7/src/ext.rs:10:1 clippy::module_name_repetitions "item name ends with its containing module's name" -quote-1.0.7/src/ext.rs:7:5 clippy::doc_markdown "you should put `TokenStream` between ticks in the documentation" -quote-1.0.7/src/ident_fragment.rs:13:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -quote-1.0.7/src/ident_fragment.rs:51:31 clippy::manual_strip "stripping a prefix manually" -quote-1.0.7/src/runtime.rs:52:5 clippy::module_name_repetitions "item name ends with its containing module's name" -quote-1.0.7/src/runtime.rs:63:5 clippy::module_name_repetitions "item name ends with its containing module's name" -quote-1.0.7/src/runtime.rs:66:33 clippy::doc_markdown "you should put `DoesNotHaveIter` between ticks in the documentation" -quote-1.0.7/src/runtime.rs:80:5 clippy::module_name_repetitions "item name ends with its containing module's name" -rand-0.7.3/src/distributions/bernoulli.rs:103:20 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" -rand-0.7.3/src/distributions/bernoulli.rs:103:20 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" -rand-0.7.3/src/distributions/bernoulli.rs:116:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -rand-0.7.3/src/distributions/bernoulli.rs:123:21 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" -rand-0.7.3/src/distributions/bernoulli.rs:123:21 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" -rand-0.7.3/src/distributions/bernoulli.rs:63:26 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand-0.7.3/src/distributions/bernoulli.rs:63:27 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -rand-0.7.3/src/distributions/bernoulli.rs:67:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand-0.7.3/src/distributions/bernoulli.rs:95:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -rand-0.7.3/src/distributions/bernoulli.rs:96:13 clippy::manual_range_contains "manual `Range::contains` implementation" -rand-0.7.3/src/distributions/binomial.rs:107:23 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand-0.7.3/src/distributions/binomial.rs:112:44 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand-0.7.3/src/distributions/binomial.rs:116:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rand-0.7.3/src/distributions/binomial.rs:150:28 clippy::redundant_else "redundant else block" -rand-0.7.3/src/distributions/binomial.rs:153:24 clippy::if_not_else "unnecessary boolean `not` operation" -rand-0.7.3/src/distributions/binomial.rs:158:28 clippy::redundant_else "redundant else block" -rand-0.7.3/src/distributions/binomial.rs:164:33 clippy::cast_sign_loss "casting `i64` to `u64` may lose the sign of the value" -rand-0.7.3/src/distributions/binomial.rs:166:28 clippy::redundant_else "redundant else block" -rand-0.7.3/src/distributions/binomial.rs:175:47 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand-0.7.3/src/distributions/binomial.rs:185:38 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand-0.7.3/src/distributions/binomial.rs:194:38 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand-0.7.3/src/distributions/binomial.rs:202:28 clippy::redundant_else "redundant else block" -rand-0.7.3/src/distributions/binomial.rs:209:25 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand-0.7.3/src/distributions/binomial.rs:221:26 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand-0.7.3/src/distributions/binomial.rs:222:26 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand-0.7.3/src/distributions/binomial.rs:223:25 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand-0.7.3/src/distributions/binomial.rs:224:25 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand-0.7.3/src/distributions/binomial.rs:226:17 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rand-0.7.3/src/distributions/binomial.rs:233:32 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand-0.7.3/src/distributions/binomial.rs:234:27 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand-0.7.3/src/distributions/binomial.rs:251:22 clippy::cast_sign_loss "casting `i64` to `u64` may lose the sign of the value" -rand-0.7.3/src/distributions/binomial.rs:255:9 clippy::if_not_else "unnecessary `!=` operation" -rand-0.7.3/src/distributions/binomial.rs:35:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/distributions/binomial.rs:45:17 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand-0.7.3/src/distributions/binomial.rs:46:5 clippy::cast_possible_truncation "casting `f64` to `i64` may truncate the value" -rand-0.7.3/src/distributions/binomial.rs:50:5 clippy::too_many_lines "this function has too many lines (143/100)" -rand-0.7.3/src/distributions/binomial.rs:76:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rand-0.7.3/src/distributions/binomial.rs:78:12 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand-0.7.3/src/distributions/binomial.rs:81:21 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand-0.7.3/src/distributions/binomial.rs:82:32 clippy::cast_possible_truncation "casting `u64` to `i32` may truncate the value" -rand-0.7.3/src/distributions/binomial.rs:88:26 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand-0.7.3/src/distributions/binomial.rs:99:21 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand-0.7.3/src/distributions/cauchy.rs:33:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/distributions/dirichlet.rs:52:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/distributions/dirichlet.rs:64:32 clippy::unseparated_literal_suffix "float type suffix should be separated by an underscore" -rand-0.7.3/src/distributions/dirichlet.rs:65:23 clippy::unseparated_literal_suffix "float type suffix should be separated by an underscore" -rand-0.7.3/src/distributions/exponential.rs:76:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/distributions/float.rs:73:1 clippy::module_name_repetitions "item name ends with its containing module's name" -rand-0.7.3/src/distributions/gamma.rs:13:5 clippy::enum_glob_use "usage of wildcard import for enum variants" -rand-0.7.3/src/distributions/gamma.rs:14:5 clippy::enum_glob_use "usage of wildcard import for enum variants" -rand-0.7.3/src/distributions/gamma.rs:189:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/distributions/gamma.rs:230:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/distributions/gamma.rs:259:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/distributions/gamma.rs:287:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/distributions/gamma.rs:90:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/distributions/integer.rs:23:9 clippy::cast_possible_truncation "casting `u32` to `u8` may truncate the value" -rand-0.7.3/src/distributions/integer.rs:30:9 clippy::cast_possible_truncation "casting `u32` to `u16` may truncate the value" -rand-0.7.3/src/distributions/integer.rs:69:9 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -rand-0.7.3/src/distributions/mod.rs:263:5 clippy::inline_always "you have declared `#[inline(always)]` on `next`. This is usually a bad idea" -rand-0.7.3/src/distributions/normal.rs:100:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/distributions/normal.rs:119:1 clippy::module_name_repetitions "item name ends with its containing module's name" -rand-0.7.3/src/distributions/normal.rs:131:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/distributions/normal.rs:31:1 clippy::module_name_repetitions "item name ends with its containing module's name" -rand-0.7.3/src/distributions/normal.rs:47:25 clippy::unseparated_literal_suffix "float type suffix should be separated by an underscore" -rand-0.7.3/src/distributions/normal.rs:48:25 clippy::unseparated_literal_suffix "float type suffix should be separated by an underscore" -rand-0.7.3/src/distributions/other.rs:89:9 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -rand-0.7.3/src/distributions/pareto.rs:32:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/distributions/poisson.rs:35:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/distributions/poisson.rs:87:30 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" -rand-0.7.3/src/distributions/poisson.rs:87:30 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" -rand-0.7.3/src/distributions/triangular.rs:32:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/distributions/uniform.rs:146:4 clippy::needless_doctest_main "needless `fn main` in doctest" -rand-0.7.3/src/distributions/uniform.rs:199:1 clippy::module_name_repetitions "item name ends with its containing module's name" -rand-0.7.3/src/distributions/uniform.rs:214:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand-0.7.3/src/distributions/uniform.rs:283:14 clippy::doc_markdown "you should put `SampleUniform` between ticks in the documentation" -rand-0.7.3/src/distributions/uniform.rs:283:46 clippy::doc_markdown "you should put `SampleUniform` between ticks in the documentation" -rand-0.7.3/src/distributions/uniform.rs:296:5 clippy::inline_always "you have declared `#[inline(always)]` on `borrow`. This is usually a bad idea" -rand-0.7.3/src/distributions/uniform.rs:304:5 clippy::inline_always "you have declared `#[inline(always)]` on `borrow`. This is usually a bad idea" -rand-0.7.3/src/distributions/uniform.rs:350:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" -rand-0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" -rand-0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" -rand-0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" -rand-0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" -rand-0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" -rand-0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" -rand-0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" -rand-0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" -rand-0.7.3/src/distributions/uniform.rs:56:10 clippy::doc_markdown "you should put `SampleBorrow` between ticks in the documentation" -rand-0.7.3/src/distributions/uniform.rs:647:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand-0.7.3/src/distributions/uniform.rs:840:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand-0.7.3/src/distributions/uniform.rs:913:13 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" -rand-0.7.3/src/distributions/uniform.rs:943:54 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" -rand-0.7.3/src/distributions/unit_circle.rs:30:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/distributions/unit_sphere.rs:24:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand-0.7.3/src/distributions/unit_sphere.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/distributions/utils.rs:247:15 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" -rand-0.7.3/src/distributions/utils.rs:248:20 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" -rand-0.7.3/src/distributions/utils.rs:249:18 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" -rand-0.7.3/src/distributions/utils.rs:254:5 clippy::inline_always "you have declared `#[inline(always)]` on `lanes`. This is usually a bad idea" -rand-0.7.3/src/distributions/utils.rs:258:5 clippy::inline_always "you have declared `#[inline(always)]` on `splat`. This is usually a bad idea" -rand-0.7.3/src/distributions/utils.rs:262:5 clippy::inline_always "you have declared `#[inline(always)]` on `extract`. This is usually a bad idea" -rand-0.7.3/src/distributions/utils.rs:267:5 clippy::inline_always "you have declared `#[inline(always)]` on `replace`. This is usually a bad idea" -rand-0.7.3/src/distributions/utils.rs:281:5 clippy::inline_always "you have declared `#[inline(always)]` on `any`. This is usually a bad idea" -rand-0.7.3/src/distributions/utils.rs:286:5 clippy::inline_always "you have declared `#[inline(always)]` on `all`. This is usually a bad idea" -rand-0.7.3/src/distributions/utils.rs:291:5 clippy::inline_always "you have declared `#[inline(always)]` on `none`. This is usually a bad idea" -rand-0.7.3/src/distributions/utils.rs:488:17 clippy::doc_markdown "you should put `x_i` between ticks in the documentation" -rand-0.7.3/src/distributions/utils.rs:489:50 clippy::doc_markdown "you should put `x_i` between ticks in the documentation" -rand-0.7.3/src/distributions/utils.rs:489:63 clippy::doc_markdown "you should put `f(x_i` between ticks in the documentation" -rand-0.7.3/src/distributions/utils.rs:490:40 clippy::doc_markdown "you should put `f(x_i` between ticks in the documentation" -rand-0.7.3/src/distributions/utils.rs:490:49 clippy::doc_markdown "you should put `f(x_{i+1` between ticks in the documentation" -rand-0.7.3/src/distributions/utils.rs:518:17 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -rand-0.7.3/src/distributions/weibull.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/distributions/weighted/alias_method.rs:113:21 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" -rand-0.7.3/src/distributions/weighted/alias_method.rs:125:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rand-0.7.3/src/distributions/weighted/alias_method.rs:131:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rand-0.7.3/src/distributions/weighted/alias_method.rs:180:36 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -rand-0.7.3/src/distributions/weighted/alias_method.rs:182:34 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -rand-0.7.3/src/distributions/weighted/alias_method.rs:259:28 clippy::clone_on_copy "using `clone` on type `distributions::uniform::Uniform` which implements the `Copy` trait" -rand-0.7.3/src/distributions/weighted/alias_method.rs:296:9 clippy::map_clone "you are using an explicit closure for copying elements" -rand-0.7.3/src/distributions/weighted/alias_method.rs:321:9 clippy::map_clone "you are using an explicit closure for copying elements" -rand-0.7.3/src/distributions/weighted/alias_method.rs:78:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -rand-0.7.3/src/distributions/weighted/alias_method.rs:78:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -rand-0.7.3/src/distributions/weighted/alias_method.rs:78:5 clippy::too_many_lines "this function has too many lines (106/100)" -rand-0.7.3/src/distributions/weighted/alias_method.rs:85:17 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -rand-0.7.3/src/distributions/weighted/alias_method.rs:87:31 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" -rand-0.7.3/src/distributions/weighted/mod.rs:100:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -rand-0.7.3/src/distributions/weighted/mod.rs:144:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -rand-0.7.3/src/distributions/weighted/mod.rs:144:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -rand-0.7.3/src/distributions/weighted/mod.rs:169:16 clippy::int_plus_one "unnecessary `>= y + 1` or `x - 1 >=`" -rand-0.7.3/src/distributions/weighted/mod.rs:386:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand-0.7.3/src/distributions/weighted/mod.rs:85:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand-0.7.3/src/lib.rs:333:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -rand-0.7.3/src/lib.rs:404:14 clippy::wrong_self_convention "methods called `to_*` usually take self by reference; consider choosing a less ambiguous name" -rand-0.7.3/src/lib.rs:552:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -rand-0.7.3/src/rngs/adapter/read.rs:47:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand-0.7.3/src/rngs/adapter/read.rs:89:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand-0.7.3/src/rngs/adapter/reseeding.rs:100:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -rand-0.7.3/src/rngs/adapter/reseeding.rs:112:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea" -rand-0.7.3/src/rngs/adapter/reseeding.rs:117:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea" -rand-0.7.3/src/rngs/adapter/reseeding.rs:198:13 clippy::cast_possible_wrap "casting `u64` to `i64` may wrap around the value" -rand-0.7.3/src/rngs/adapter/reseeding.rs:231:9 clippy::cast_possible_wrap "casting `usize` to `isize` may wrap around the value" -rand-0.7.3/src/rngs/adapter/reseeding.rs:249:13 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" -rand-0.7.3/src/rngs/adapter/reseeding.rs:27:28 clippy::doc_markdown "you should put `ChaCha` between ticks in the documentation" -rand-0.7.3/src/rngs/adapter/reseeding.rs:79:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand-0.7.3/src/rngs/entropy.rs:24:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand-0.7.3/src/rngs/entropy.rs:34:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/rngs/mock.rs:36:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/rngs/mock.rs:47:9 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" -rand-0.7.3/src/rngs/mod.rs:61:74 clippy::doc_markdown "you should put `ChaCha20` between ticks in the documentation" -rand-0.7.3/src/rngs/std.rs:25:39 clippy::doc_markdown "you should put `ChaCha` between ticks in the documentation" -rand-0.7.3/src/rngs/std.rs:32:10 clippy::doc_markdown "you should put `rand_chacha` between ticks in the documentation" -rand-0.7.3/src/rngs/std.rs:36:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand-0.7.3/src/rngs/std.rs:39:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea" -rand-0.7.3/src/rngs/std.rs:44:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea" -rand-0.7.3/src/rngs/std.rs:49:5 clippy::inline_always "you have declared `#[inline(always)]` on `fill_bytes`. This is usually a bad idea" -rand-0.7.3/src/rngs/std.rs:54:5 clippy::inline_always "you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea" -rand-0.7.3/src/rngs/std.rs:63:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_seed`. This is usually a bad idea" -rand-0.7.3/src/rngs/std.rs:68:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_rng`. This is usually a bad idea" -rand-0.7.3/src/rngs/thread.rs:57:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand-0.7.3/src/rngs/thread.rs:80:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -rand-0.7.3/src/rngs/thread.rs:80:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand-0.7.3/src/rngs/thread.rs:80:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -rand-0.7.3/src/rngs/thread.rs:81:35 clippy::redundant_closure_for_method_calls "redundant closure found" -rand-0.7.3/src/rngs/thread.rs:93:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea" -rand-0.7.3/src/rngs/thread.rs:98:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea" -rand-0.7.3/src/seq/index.rs:127:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand-0.7.3/src/seq/index.rs:139:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -rand-0.7.3/src/seq/index.rs:159:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand-0.7.3/src/seq/index.rs:171:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -rand-0.7.3/src/seq/index.rs:180:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -rand-0.7.3/src/seq/index.rs:223:18 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -rand-0.7.3/src/seq/index.rs:224:18 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -rand-0.7.3/src/seq/index.rs:233:25 clippy::cast_precision_loss "casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide)" -rand-0.7.3/src/seq/index.rs:236:27 clippy::cast_precision_loss "casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide)" -rand-0.7.3/src/seq/index.rs:244:12 clippy::cast_precision_loss "casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide)" -rand-0.7.3/src/seq/index.rs:244:37 clippy::cast_precision_loss "casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide)" -rand-0.7.3/src/seq/index.rs:29:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand-0.7.3/src/seq/index.rs:39:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/seq/index.rs:48:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/seq/index.rs:60:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/seq/index.rs:69:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/seq/index.rs:78:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/seq/index.rs:87:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand-0.7.3/src/seq/index.rs:87:5 clippy::should_implement_trait "method `into_iter` can be confused for the standard trait method `std::iter::IntoIterator::into_iter`" -rand-0.7.3/src/seq/index.rs:97:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -rand-0.7.3/src/seq/mod.rs:141:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -rand-0.7.3/src/seq/mod.rs:168:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -rand-0.7.3/src/seq/mod.rs:229:4 clippy::needless_doctest_main "needless `fn main` in doctest" -rand-0.7.3/src/seq/mod.rs:292:29 clippy::cast_precision_loss "casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -rand-0.7.3/src/seq/mod.rs:410:23 clippy::default_trait_access "calling `std::marker::PhantomData::default()` is more clear than this expression" -rand-0.7.3/src/seq/mod.rs:45:4 clippy::needless_doctest_main "needless `fn main` in doctest" -rand-0.7.3/src/seq/mod.rs:527:26 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -rand_core-0.6.0/src/block.rs:117:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand_core-0.6.0/src/block.rs:153:5 clippy::inline_always "you have declared `#[inline(always)]` on `index`. This is usually a bad idea" -rand_core-0.6.0/src/block.rs:230:5 clippy::inline_always "you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea" -rand_core-0.6.0/src/block.rs:240:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_seed`. This is usually a bad idea" -rand_core-0.6.0/src/block.rs:245:5 clippy::inline_always "you have declared `#[inline(always)]` on `seed_from_u64`. This is usually a bad idea" -rand_core-0.6.0/src/block.rs:250:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_rng`. This is usually a bad idea" -rand_core-0.6.0/src/block.rs:280:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand_core-0.6.0/src/block.rs:319:5 clippy::inline_always "you have declared `#[inline(always)]` on `index`. This is usually a bad idea" -rand_core-0.6.0/src/block.rs:405:5 clippy::inline_always "you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea" -rand_core-0.6.0/src/block.rs:415:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_seed`. This is usually a bad idea" -rand_core-0.6.0/src/block.rs:420:5 clippy::inline_always "you have declared `#[inline(always)]` on `seed_from_u64`. This is usually a bad idea" -rand_core-0.6.0/src/block.rs:425:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_rng`. This is usually a bad idea" -rand_core-0.6.0/src/block.rs:67:14 clippy::doc_markdown "you should put `module][crate::block` between ticks in the documentation" -rand_core-0.6.0/src/block.rs:68:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rand_core-0.6.0/src/error.rs:106:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand_core-0.6.0/src/error.rs:87:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand_core-0.6.0/src/error.rs:95:74 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -rand_core-0.6.0/src/lib.rs:179:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -rand_core-0.6.0/src/lib.rs:301:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rand_core-0.6.0/src/lib.rs:303:26 clippy::unreadable_literal "long literal lacking separators" -rand_core-0.6.0/src/lib.rs:304:26 clippy::unreadable_literal "long literal lacking separators" -rand_core-0.6.0/src/lib.rs:313:30 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" -rand_core-0.6.0/src/lib.rs:314:23 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" -rand_core-0.6.0/src/lib.rs:346:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -rand_core-0.6.0/src/lib.rs:381:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea" -rand_core-0.6.0/src/lib.rs:386:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea" -rand_core-0.6.0/src/lib.rs:391:5 clippy::inline_always "you have declared `#[inline(always)]` on `fill_bytes`. This is usually a bad idea" -rand_core-0.6.0/src/lib.rs:396:5 clippy::inline_always "you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea" -rayon-1.5.0/src/collections/binary_heap.rs:7:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/collections/binary_heap.rs:8:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/collections/btree_map.rs:7:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/collections/btree_map.rs:8:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/collections/btree_set.rs:7:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/collections/btree_set.rs:8:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/collections/hash_map.rs:10:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/collections/hash_map.rs:9:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/collections/hash_set.rs:10:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/collections/hash_set.rs:9:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/collections/linked_list.rs:7:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/collections/linked_list.rs:8:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/collections/mod.rs:59:32 clippy::mem_replace_with_default "replacing a value of type `T` with `T::default()` is better expressed using `std::mem::take`" -rayon-1.5.0/src/collections/vec_deque.rs:8:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/collections/vec_deque.rs:9:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/compile_fail/cannot_collect_filtermap_data.rs:2:1 clippy::needless_doctest_main "needless `fn main` in doctest" -rayon-1.5.0/src/compile_fail/cannot_zip_filtered_data.rs:2:1 clippy::needless_doctest_main "needless `fn main` in doctest" -rayon-1.5.0/src/compile_fail/cell_par_iter.rs:2:1 clippy::needless_doctest_main "needless `fn main` in doctest" -rayon-1.5.0/src/compile_fail/no_send_par_iter.rs:25:1 clippy::needless_doctest_main "needless `fn main` in doctest" -rayon-1.5.0/src/compile_fail/no_send_par_iter.rs:46:1 clippy::needless_doctest_main "needless `fn main` in doctest" -rayon-1.5.0/src/compile_fail/no_send_par_iter.rs:4:1 clippy::needless_doctest_main "needless `fn main` in doctest" -rayon-1.5.0/src/compile_fail/rc_par_iter.rs:2:1 clippy::needless_doctest_main "needless `fn main` in doctest" -rayon-1.5.0/src/iter/chain.rs:103:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/chain.rs:122:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/chain.rs:128:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/chain.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/chain.rs:221:36 clippy::doc_markdown "you should put `ExactSizeIterator` between ticks in the documentation" -rayon-1.5.0/src/iter/chain.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/chain.rs:51:38 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" -rayon-1.5.0/src/iter/chain.rs:58:14 clippy::shadow_unrelated "`a` is being shadowed" -rayon-1.5.0/src/iter/chain.rs:58:17 clippy::shadow_unrelated "`b` is being shadowed" -rayon-1.5.0/src/iter/chain.rs:78:14 clippy::shadow_unrelated "`a` is being shadowed" -rayon-1.5.0/src/iter/chain.rs:78:17 clippy::shadow_unrelated "`b` is being shadowed" -rayon-1.5.0/src/iter/chain.rs:97:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/chunks.rs:29:9 clippy::inconsistent_struct_constructor "inconsistent struct constructor" -rayon-1.5.0/src/iter/chunks.rs:3:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/chunks.rs:4:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/chunks.rs:77:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/chunks.rs:83:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/cloned.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/cloned.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/cloned.rs:71:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/cloned.rs:75:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/collect/consumer.rs:141:5 clippy::doc_markdown "you should put `CollectReducer` between ticks in the documentation" -rayon-1.5.0/src/iter/collect/consumer.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/collect/consumer.rs:28:5 clippy::doc_markdown "you should put `CollectResult` between ticks in the documentation" -rayon-1.5.0/src/iter/collect/consumer.rs:36:37 clippy::mut_mut "generally you want to avoid `&mut &mut _` if possible" -rayon-1.5.0/src/iter/collect/consumer.rs:36:37 clippy::mut_mut "generally you want to avoid `&mut &mut _` if possible" -rayon-1.5.0/src/iter/collect/mod.rs:154:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -rayon-1.5.0/src/iter/copied.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/copied.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/copied.rs:71:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/copied.rs:75:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/empty.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/empty.rs:24:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -rayon-1.5.0/src/iter/empty.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/enumerate.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/enumerate.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/enumerate.rs:64:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/enumerate.rs:68:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/extend.rs:143:63 clippy::linkedlist "you seem to be using a `LinkedList`! Perhaps you meant some other data structure?" -rayon-1.5.0/src/iter/extend.rs:182:57 clippy::linkedlist "you seem to be using a `LinkedList`! Perhaps you meant some other data structure?" -rayon-1.5.0/src/iter/extend.rs:218:32 clippy::linkedlist "you seem to be using a `LinkedList`! Perhaps you meant some other data structure?" -rayon-1.5.0/src/iter/extend.rs:218:59 clippy::linkedlist "you seem to be using a `LinkedList`! Perhaps you meant some other data structure?" -rayon-1.5.0/src/iter/extend.rs:25:42 clippy::linkedlist "you seem to be using a `LinkedList`! Perhaps you meant some other data structure?" -rayon-1.5.0/src/iter/extend.rs:287:62 clippy::linkedlist "you seem to be using a `LinkedList`! Perhaps you meant some other data structure?" -rayon-1.5.0/src/iter/extend.rs:322:56 clippy::linkedlist "you seem to be using a `LinkedList`! Perhaps you meant some other data structure?" -rayon-1.5.0/src/iter/extend.rs:41:27 clippy::linkedlist "you seem to be using a `LinkedList`! Perhaps you meant some other data structure?" -rayon-1.5.0/src/iter/extend.rs:47:30 clippy::linkedlist "you seem to be using a `LinkedList`! Perhaps you meant some other data structure?" -rayon-1.5.0/src/iter/extend.rs:47:56 clippy::linkedlist "you seem to be using a `LinkedList`! Perhaps you meant some other data structure?" -rayon-1.5.0/src/iter/extend.rs:47:74 clippy::linkedlist "you seem to be using a `LinkedList`! Perhaps you meant some other data structure?" -rayon-1.5.0/src/iter/extend.rs:53:29 clippy::linkedlist "you seem to be using a `LinkedList`! Perhaps you meant some other data structure?" -rayon-1.5.0/src/iter/extend.rs:57:36 clippy::linkedlist "you seem to be using a `LinkedList`! Perhaps you meant some other data structure?" -rayon-1.5.0/src/iter/extend.rs:59:61 clippy::linkedlist "you seem to be using a `LinkedList`! Perhaps you meant some other data structure?" -rayon-1.5.0/src/iter/filter.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/filter.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/filter_map.rs:123:9 clippy::option_if_let_else "use Option::map_or instead of an if let/else" -rayon-1.5.0/src/iter/filter_map.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/filter_map.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/find.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/find.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/find_first_last/mod.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/find_first_last/mod.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/find_first_last/mod.rs:32:67 clippy::doc_markdown "you should put `MatchPosition` between ticks in the documentation" -rayon-1.5.0/src/iter/flat_map.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/flat_map.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/flat_map_iter.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/flat_map_iter.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/flatten.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/flatten.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/flatten_iter.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/flatten_iter.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/fold.rs:158:13 clippy::similar_names "binding's name is too similar to existing binding" -rayon-1.5.0/src/iter/fold.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/fold.rs:204:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rayon-1.5.0/src/iter/fold.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/for_each.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/for_each.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/inspect.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/inspect.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/inspect.rs:83:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/inspect.rs:88:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/interleave.rs:111:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/interleave.rs:119:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/interleave.rs:195:30 clippy::doc_markdown "you should put `self.i_len` between ticks in the documentation" -rayon-1.5.0/src/iter/interleave.rs:195:43 clippy::doc_markdown "you should put `self.j_len` between ticks in the documentation" -rayon-1.5.0/src/iter/interleave.rs:199:23 clippy::doc_markdown "you should put `self.i_len` between ticks in the documentation" -rayon-1.5.0/src/iter/interleave.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/interleave.rs:200:23 clippy::doc_markdown "you should put `self.j_len` between ticks in the documentation" -rayon-1.5.0/src/iter/interleave.rs:249:41 clippy::doc_markdown "you should put `DoubleEndedIterator` between ticks in the documentation" -rayon-1.5.0/src/iter/interleave.rs:250:5 clippy::doc_markdown "you should put `ExactSizeIterator` between ticks in the documentation" -rayon-1.5.0/src/iter/interleave.rs:263:33 clippy::doc_markdown "you should put `InterleaveSeq` between ticks in the documentation" -rayon-1.5.0/src/iter/interleave.rs:280:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" -rayon-1.5.0/src/iter/interleave.rs:285:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" -rayon-1.5.0/src/iter/interleave.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/interleave.rs:313:9 clippy::comparison_chain "`if` chain can be rewritten with `match`" -rayon-1.5.0/src/iter/interleave.rs:82:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/interleave.rs:90:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/interleave_shortest.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/intersperse.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/intersperse.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/intersperse.rs:90:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/intersperse.rs:96:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/len.rs:12:1 clippy::module_name_repetitions "item name ends with its containing module's name" -rayon-1.5.0/src/iter/len.rs:146:1 clippy::module_name_repetitions "item name ends with its containing module's name" -rayon-1.5.0/src/iter/len.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/len.rs:200:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/len.rs:205:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/len.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/len.rs:66:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/len.rs:71:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/map.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/map.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/map.rs:84:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/map.rs:89:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/map_with.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/map_with.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/map_with.rs:419:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/map_with.rs:425:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/map_with.rs:90:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/map_with.rs:96:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/mod.rs:1874:24 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -rayon-1.5.0/src/iter/mod.rs:2171:1 clippy::len_without_is_empty "trait `IndexedParallelIterator` has a `len` method but no (possibly inherited) `is_empty` method" -rayon-1.5.0/src/iter/mod.rs:2371:26 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -rayon-1.5.0/src/iter/mod.rs:2411:26 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -rayon-1.5.0/src/iter/mod.rs:82:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/multizip.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/multizip.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/noop.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/once.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/once.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/panic_fuse.rs:102:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/panic_fuse.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/panic_fuse.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/panic_fuse.rs:98:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/par_bridge.rs:136:28 clippy::redundant_else "redundant else block" -rayon-1.5.0/src/iter/par_bridge.rs:163:28 clippy::redundant_else "redundant else block" -rayon-1.5.0/src/iter/plumbing/mod.rs:216:58 clippy::doc_markdown "you should put `find_first` between ticks in the documentation" -rayon-1.5.0/src/iter/plumbing/mod.rs:359:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/plumbing/mod.rs:364:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/plumbing/mod.rs:399:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/plumbing/mod.rs:53:19 clippy::doc_markdown "you should put `DoubleEndedIterator` between ticks in the documentation" -rayon-1.5.0/src/iter/plumbing/mod.rs:53:43 clippy::doc_markdown "you should put `ExactSizeIterator` between ticks in the documentation" -rayon-1.5.0/src/iter/plumbing/mod.rs:54:31 clippy::doc_markdown "you should put `IntoIterator` between ticks in the documentation" -rayon-1.5.0/src/iter/plumbing/mod.rs:55:5 clippy::doc_markdown "you should put `IntoIterator` between ticks in the documentation" -rayon-1.5.0/src/iter/positions.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/positions.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/product.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/reduce.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/repeat.rs:103:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rayon-1.5.0/src/iter/repeat.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/repeat.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/rev.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/rev.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/rev.rs:63:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/rev.rs:68:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/skip.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/skip.rs:3:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/skip.rs:68:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/skip.rs:73:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/splitter.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/splitter.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/step_by.rs:4:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/step_by.rs:5:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/step_by.rs:73:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/step_by.rs:79:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/sum.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/take.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/take.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/take.rs:67:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/take.rs:72:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/try_fold.rs:190:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rayon-1.5.0/src/iter/try_fold.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/try_fold.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/try_reduce.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/try_reduce_with.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/unzip.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/unzip.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/update.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/update.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/update.rs:82:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/update.rs:87:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/while_some.rs:130:22 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -rayon-1.5.0/src/iter/while_some.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/while_some.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/zip.rs:102:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/zip.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/zip.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/zip.rs:74:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/zip.rs:79:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/zip.rs:97:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/iter/zip_eq.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/iter/zip_eq.rs:2:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/option.rs:8:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/option.rs:9:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/par_either.rs:1:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/par_either.rs:3:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/private.rs:9:1 clippy::module_name_repetitions "item name starts with its containing module's name" -rayon-1.5.0/src/range.rs:19:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/range.rs:20:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/range_inclusive.rs:194:9 clippy::range_plus_one "an inclusive range would be more readable" -rayon-1.5.0/src/range_inclusive.rs:194:9 clippy::range_plus_one "an inclusive range would be more readable" -rayon-1.5.0/src/range_inclusive.rs:19:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/range_inclusive.rs:209:9 clippy::range_plus_one "an inclusive range would be more readable" -rayon-1.5.0/src/range_inclusive.rs:209:9 clippy::range_plus_one "an inclusive range would be more readable" -rayon-1.5.0/src/range_inclusive.rs:20:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/range_inclusive.rs:231:9 clippy::range_plus_one "an inclusive range would be more readable" -rayon-1.5.0/src/range_inclusive.rs:231:9 clippy::range_plus_one "an inclusive range would be more readable" -rayon-1.5.0/src/result.rs:8:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/result.rs:9:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/slice/mergesort.rs:102:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/slice/mergesort.rs:109:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/slice/mergesort.rs:114:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/slice/mergesort.rs:211:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/slice/mergesort.rs:217:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/slice/mergesort.rs:251:5 clippy::doc_markdown "you should put `TimSort` between ticks in the documentation" -rayon-1.5.0/src/slice/mergesort.rs:252:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" -rayon-1.5.0/src/slice/mergesort.rs:286:59 clippy::doc_markdown "you should put `TimSort` between ticks in the documentation" -rayon-1.5.0/src/slice/mergesort.rs:333:24 clippy::redundant_else "redundant else block" -rayon-1.5.0/src/slice/mergesort.rs:513:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/slice/mergesort.rs:521:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/slice/mergesort.rs:7:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/slice/mergesort.rs:98:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/slice/mod.rs:15:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/slice/mod.rs:16:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/slice/mod.rs:17:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/slice/mod.rs:25:1 clippy::module_name_repetitions "item name ends with its containing module's name" -rayon-1.5.0/src/slice/mod.rs:657:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rayon-1.5.0/src/slice/mod.rs:971:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -rayon-1.5.0/src/slice/quicksort.rs:230:36 clippy::doc_markdown "you should put `BlockQuicksort` between ticks in the documentation" -rayon-1.5.0/src/slice/quicksort.rs:233:1 clippy::too_many_lines "this function has too many lines (117/100)" -rayon-1.5.0/src/slice/quicksort.rs:258:26 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -rayon-1.5.0/src/slice/quicksort.rs:265:26 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -rayon-1.5.0/src/slice/quicksort.rs:268:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -rayon-1.5.0/src/slice/quicksort.rs:308:30 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" -rayon-1.5.0/src/slice/quicksort.rs:325:30 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" -rayon-1.5.0/src/slice/quicksort.rs:393:36 clippy::cast_possible_wrap "casting `u8` to `isize` may wrap around the value on targets with 32-bit wide pointers" -rayon-1.5.0/src/slice/quicksort.rs:405:40 clippy::cast_possible_wrap "casting `u8` to `isize` may wrap around the value on targets with 32-bit wide pointers" -rayon-1.5.0/src/slice/quicksort.rs:430:14 clippy::shadow_unrelated "`pivot` is being shadowed" -rayon-1.5.0/src/slice/quicksort.rs:439:13 clippy::shadow_unrelated "`pivot` is being shadowed" -rayon-1.5.0/src/slice/quicksort.rs:482:10 clippy::shadow_unrelated "`pivot` is being shadowed" -rayon-1.5.0/src/slice/quicksort.rs:491:9 clippy::shadow_unrelated "`pivot` is being shadowed" -rayon-1.5.0/src/slice/quicksort.rs:534:26 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -rayon-1.5.0/src/slice/quicksort.rs:545:17 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -rayon-1.5.0/src/slice/quicksort.rs:588:17 clippy::identity_op "the operation is ineffective. Consider reducing it to `len / 4`" -rayon-1.5.0/src/slice/quicksort.rs:716:14 clippy::shadow_unrelated "`pivot` is being shadowed" -rayon-1.5.0/src/split_producer.rs:56:16 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" -rayon-1.5.0/src/split_producer.rs:92:9 clippy::option_if_let_else "use Option::map_or instead of an if let/else" -rayon-1.5.0/src/str.rs:16:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/str.rs:17:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/str.rs:18:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/str.rs:25:5 clippy::cast_possible_wrap "casting `u8` to `i8` may wrap around the value" -rayon-1.5.0/src/str.rs:715:9 clippy::manual_strip "stripping a suffix manually" -rayon-1.5.0/src/string.rs:5:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/vec.rs:137:12 clippy::len_zero "length comparison to zero" -rayon-1.5.0/src/vec.rs:8:5 clippy::wildcard_imports "usage of wildcard import" -rayon-1.5.0/src/vec.rs:9:5 clippy::wildcard_imports "usage of wildcard import" -regex-1.3.2/src/backtrack.rs:100:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/backtrack.rs:133:17 clippy::same_item_push "it looks like the same item is being pushed into this Vec" -regex-1.3.2/src/backtrack.rs:145:20 clippy::if_not_else "unnecessary boolean `not` operation" -regex-1.3.2/src/backtrack.rs:199:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/backtrack.rs:223:29 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/backtrack.rs:230:66 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/backtrack.rs:284:21 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" -regex-1.3.2/src/backtrack.rs:287:5 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex-1.3.2/src/backtrack.rs:97:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/backtrack.rs:98:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/backtrack.rs:99:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:1005:32 clippy::unreadable_literal "long literal lacking separators" -regex-1.3.2/src/compile.rs:1006:21 clippy::unreadable_literal "long literal lacking separators" -regex-1.3.2/src/compile.rs:1008:18 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" -regex-1.3.2/src/compile.rs:1009:18 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" -regex-1.3.2/src/compile.rs:1010:9 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -regex-1.3.2/src/compile.rs:102:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/compile.rs:1037:37 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" -regex-1.3.2/src/compile.rs:1037:55 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" -regex-1.3.2/src/compile.rs:1040:28 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" -regex-1.3.2/src/compile.rs:1040:38 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" -regex-1.3.2/src/compile.rs:1051:25 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -regex-1.3.2/src/compile.rs:1071:8 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" -regex-1.3.2/src/compile.rs:112:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -regex-1.3.2/src/compile.rs:154:30 clippy::redundant_closure_for_method_calls "redundant closure found" -regex-1.3.2/src/compile.rs:156:30 clippy::redundant_closure_for_method_calls "redundant closure found" -regex-1.3.2/src/compile.rs:185:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -regex-1.3.2/src/compile.rs:187:40 clippy::redundant_closure_for_method_calls "redundant closure found" -regex-1.3.2/src/compile.rs:201:53 clippy::doc_markdown "you should put `MaybeInsts` between ticks in the documentation" -regex-1.3.2/src/compile.rs:241:63 clippy::doc_markdown "you should put `c_concat` between ticks in the documentation" -regex-1.3.2/src/compile.rs:245:5 clippy::too_many_lines "this function has too many lines (111/100)" -regex-1.3.2/src/compile.rs:247:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/compile.rs:373:24 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:373:36 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:378:12 clippy::if_not_else "unnecessary boolean `not` operation" -regex-1.3.2/src/compile.rs:400:37 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:407:51 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:409:24 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:417:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -regex-1.3.2/src/compile.rs:42:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/compile.rs:42:5 clippy::new_without_default "you should consider adding a `Default` implementation for `compile::Compiler`" -regex-1.3.2/src/compile.rs:444:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -regex-1.3.2/src/compile.rs:445:57 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:446:20 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:466:20 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:466:32 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:519:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/compile.rs:55:57 clippy::doc_markdown "you should put `size_limit` between ticks in the documentation" -regex-1.3.2/src/compile.rs:58:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/compile.rs:748:41 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:74:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/compile.rs:751:54 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:765:41 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:765:55 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:825:39 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:825:51 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:828:49 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:828:61 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:830:59 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:830:71 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:832:43 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:835:41 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:835:53 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:835:67 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:83:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/compile.rs:896:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -regex-1.3.2/src/compile.rs:905:17 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:953:17 clippy::doc_markdown "you should put `HashMap` between ticks in the documentation" -regex-1.3.2/src/compile.rs:95:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/compile.rs:980:26 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -regex-1.3.2/src/compile.rs:994:44 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/compile.rs:994:54 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/dfa.rs:1007:17 clippy::similar_names "binding's name is too similar to existing binding" -regex-1.3.2/src/dfa.rs:1010:22 clippy::similar_names "binding's name is too similar to existing binding" -regex-1.3.2/src/dfa.rs:1059:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/dfa.rs:1060:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/dfa.rs:1084:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex-1.3.2/src/dfa.rs:1087:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex-1.3.2/src/dfa.rs:1090:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex-1.3.2/src/dfa.rs:1093:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex-1.3.2/src/dfa.rs:1096:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex-1.3.2/src/dfa.rs:1101:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex-1.3.2/src/dfa.rs:1104:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex-1.3.2/src/dfa.rs:1107:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex-1.3.2/src/dfa.rs:1117:30 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex-1.3.2/src/dfa.rs:1120:47 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex-1.3.2/src/dfa.rs:1121:30 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex-1.3.2/src/dfa.rs:1129:13 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" -regex-1.3.2/src/dfa.rs:1134:13 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" -regex-1.3.2/src/dfa.rs:1185:68 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" -regex-1.3.2/src/dfa.rs:1193:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/dfa.rs:1244:50 clippy::doc_markdown "you should put `current_state` between ticks in the documentation" -regex-1.3.2/src/dfa.rs:1338:58 clippy::doc_markdown "you should put `STATE_DEAD` between ticks in the documentation" -regex-1.3.2/src/dfa.rs:1339:9 clippy::doc_markdown "you should put `STATE_UNKNOWN` between ticks in the documentation" -regex-1.3.2/src/dfa.rs:1366:25 clippy::doc_markdown "you should put `STATE_DEAD` between ticks in the documentation" -regex-1.3.2/src/dfa.rs:1366:46 clippy::doc_markdown "you should put `STATE_UNKNOWN` between ticks in the documentation" -regex-1.3.2/src/dfa.rs:1367:41 clippy::inline_always "you have declared `#[inline(always)]` on `start_state`. This is usually a bad idea" -regex-1.3.2/src/dfa.rs:1380:14 clippy::identity_op "the operation is ineffective. Consider reducing it to `(empty_flags.start as u8)`" -regex-1.3.2/src/dfa.rs:1388:15 clippy::match_on_vec_items "indexing into a vector may panic" -regex-1.3.2/src/dfa.rs:1412:20 clippy::unused_self "unused `self` argument" -regex-1.3.2/src/dfa.rs:1438:9 clippy::unused_self "unused `self` argument" -regex-1.3.2/src/dfa.rs:1472:9 clippy::doc_markdown "you should put `StatePtr` between ticks in the documentation" -regex-1.3.2/src/dfa.rs:1490:54 clippy::cast_possible_truncation "casting `i32` to `u8` may truncate the value" -regex-1.3.2/src/dfa.rs:1490:54 clippy::cast_sign_loss "casting `i32` to `u8` may lose the sign of the value" -regex-1.3.2/src/dfa.rs:1521:20 clippy::doc_markdown "you should put `num_byte_classes` between ticks in the documentation" -regex-1.3.2/src/dfa.rs:1529:41 clippy::inline_always "you have declared `#[inline(always)]` on `byte_class`. This is usually a bad idea" -regex-1.3.2/src/dfa.rs:1537:14 clippy::doc_markdown "you should put `byte_class` between ticks in the documentation" -regex-1.3.2/src/dfa.rs:1538:41 clippy::inline_always "you have declared `#[inline(always)]` on `u8_class`. This is usually a bad idea" -regex-1.3.2/src/dfa.rs:1562:18 clippy::doc_markdown "you should put `STATE_START` between ticks in the documentation" -regex-1.3.2/src/dfa.rs:1614:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/dfa.rs:1651:38 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/dfa.rs:1700:17 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -regex-1.3.2/src/dfa.rs:1701:18 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex-1.3.2/src/dfa.rs:1705:19 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex-1.3.2/src/dfa.rs:1708:16 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -regex-1.3.2/src/dfa.rs:1709:18 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex-1.3.2/src/dfa.rs:1713:19 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex-1.3.2/src/dfa.rs:1716:18 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -regex-1.3.2/src/dfa.rs:1717:18 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex-1.3.2/src/dfa.rs:1721:19 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex-1.3.2/src/dfa.rs:1727:14 clippy::cast_lossless "casting `u8` to `u16` may become silently lossy if you later change the type" -regex-1.3.2/src/dfa.rs:1732:15 clippy::trivially_copy_pass_by_ref "this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -regex-1.3.2/src/dfa.rs:1736:22 clippy::trivially_copy_pass_by_ref "this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -regex-1.3.2/src/dfa.rs:1741:9 clippy::match_like_matches_macro "match expression looks like `matches!` macro" -regex-1.3.2/src/dfa.rs:1747:16 clippy::trivially_copy_pass_by_ref "this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -regex-1.3.2/src/dfa.rs:1751:18 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" -regex-1.3.2/src/dfa.rs:1815:38 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" -regex-1.3.2/src/dfa.rs:1821:21 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" -regex-1.3.2/src/dfa.rs:1824:5 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex-1.3.2/src/dfa.rs:1848:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" -regex-1.3.2/src/dfa.rs:1850:18 clippy::cast_sign_loss "casting `i32` to `u32` may lose the sign of the value" -regex-1.3.2/src/dfa.rs:1857:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" -regex-1.3.2/src/dfa.rs:1860:17 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -regex-1.3.2/src/dfa.rs:1867:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" -regex-1.3.2/src/dfa.rs:1870:19 clippy::cast_possible_truncation "casting `u32` to `u8` may truncate the value" -regex-1.3.2/src/dfa.rs:1873:15 clippy::cast_possible_truncation "casting `u32` to `u8` may truncate the value" -regex-1.3.2/src/dfa.rs:1876:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" -regex-1.3.2/src/dfa.rs:1882:26 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" -regex-1.3.2/src/dfa.rs:1884:15 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" -regex-1.3.2/src/dfa.rs:277:17 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -regex-1.3.2/src/dfa.rs:277:31 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" -regex-1.3.2/src/dfa.rs:295:20 clippy::cast_possible_truncation "casting `usize` to `i32` may truncate the value on targets with 64-bit wide pointers" -regex-1.3.2/src/dfa.rs:295:20 clippy::cast_possible_wrap "casting `usize` to `i32` may wrap around the value on targets with 32-bit wide pointers" -regex-1.3.2/src/dfa.rs:299:21 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" -regex-1.3.2/src/dfa.rs:34:46 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" -regex-1.3.2/src/dfa.rs:398:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -regex-1.3.2/src/dfa.rs:446:41 clippy::inline_always "you have declared `#[inline(always)]` on `forward`. This is usually a bad idea" -regex-1.3.2/src/dfa.rs:457:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/dfa.rs:459:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/dfa.rs:460:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/dfa.rs:476:41 clippy::inline_always "you have declared `#[inline(always)]` on `reverse`. This is usually a bad idea" -regex-1.3.2/src/dfa.rs:487:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/dfa.rs:489:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/dfa.rs:490:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/dfa.rs:506:41 clippy::inline_always "you have declared `#[inline(always)]` on `forward_many`. This is usually a bad idea" -regex-1.3.2/src/dfa.rs:518:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/dfa.rs:520:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/dfa.rs:554:41 clippy::inline_always "you have declared `#[inline(always)]` on `exec_at`. This is usually a bad idea" -regex-1.3.2/src/dfa.rs:555:5 clippy::too_many_lines "this function has too many lines (101/100)" -regex-1.3.2/src/dfa.rs:58:9 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/dfa.rs:667:21 clippy::similar_names "binding's name is too similar to existing binding" -regex-1.3.2/src/dfa.rs:747:41 clippy::inline_always "you have declared `#[inline(always)]` on `exec_at_reverse`. This is usually a bad idea" -regex-1.3.2/src/dfa.rs:795:21 clippy::similar_names "binding's name is too similar to existing binding" -regex-1.3.2/src/dfa.rs:848:9 clippy::doc_markdown "you should put `next_si` between ticks in the documentation" -regex-1.3.2/src/dfa.rs:852:41 clippy::inline_always "you have declared `#[inline(always)]` on `next_si`. This is usually a bad idea" -regex-1.3.2/src/dfa.rs:885:12 clippy::doc_markdown "you should put `STATE_DEAD` between ticks in the documentation" -regex-1.3.2/src/dfa.rs:889:9 clippy::doc_markdown "you should put `STATE_UNKNOWN` between ticks in the documentation" -regex-1.3.2/src/dfa.rs:897:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/dfa.rs:979:29 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" -regex-1.3.2/src/error.rs:6:1 clippy::manual_non_exhaustive "this seems like a manual implementation of the non-exhaustive pattern" -regex-1.3.2/src/exec.rs:1000:14 clippy::doc_markdown "you should put `captures_nfa` between ticks in the documentation" -regex-1.3.2/src/exec.rs:100:1 clippy::module_name_repetitions "item name starts with its containing module's name" -regex-1.3.2/src/exec.rs:1028:5 clippy::too_many_arguments "this function has too many arguments (9/7)" -regex-1.3.2/src/exec.rs:1039:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/exec.rs:1144:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/exec.rs:1179:26 clippy::match_same_arms "this `match` has identical arm bodies" -regex-1.3.2/src/exec.rs:122:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/exec.rs:1250:41 clippy::inline_always "you have declared `#[inline(always)]` on `searcher`. This is usually a bad idea" -regex-1.3.2/src/exec.rs:1260:41 clippy::inline_always "you have declared `#[inline(always)]` on `searcher_str`. This is usually a bad idea" -regex-1.3.2/src/exec.rs:1270:17 clippy::doc_markdown "you should put `RegexSet` between ticks in the documentation" -regex-1.3.2/src/exec.rs:1280:17 clippy::doc_markdown "you should put `RegexSet` between ticks in the documentation" -regex-1.3.2/src/exec.rs:137:9 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" -regex-1.3.2/src/exec.rs:142:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/exec.rs:158:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/exec.rs:168:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/exec.rs:181:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/exec.rs:195:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/exec.rs:204:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/exec.rs:210:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/exec.rs:245:62 clippy::if_same_then_else "this `if` has identical blocks" -regex-1.3.2/src/exec.rs:251:21 clippy::if_not_else "unnecessary boolean `not` operation" -regex-1.3.2/src/exec.rs:262:60 clippy::if_same_then_else "this `if` has identical blocks" -regex-1.3.2/src/exec.rs:268:21 clippy::if_not_else "unnecessary boolean `not` operation" -regex-1.3.2/src/exec.rs:278:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/exec.rs:281:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/exec.rs:286:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -regex-1.3.2/src/exec.rs:300:30 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/exec.rs:308:17 clippy::similar_names "binding's name is too similar to existing binding" -regex-1.3.2/src/exec.rs:329:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/exec.rs:330:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/exec.rs:331:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/exec.rs:334:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/exec.rs:340:19 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/exec.rs:344:27 clippy::unused_self "unused `self` argument" -regex-1.3.2/src/exec.rs:383:41 clippy::inline_always "you have declared `#[inline(always)]` on `shortest_match_at`. This is usually a bad idea" -regex-1.3.2/src/exec.rs:388:41 clippy::inline_always "you have declared `#[inline(always)]` on `is_match_at`. This is usually a bad idea" -regex-1.3.2/src/exec.rs:393:41 clippy::inline_always "you have declared `#[inline(always)]` on `find_at`. This is usually a bad idea" -regex-1.3.2/src/exec.rs:398:41 clippy::inline_always "you have declared `#[inline(always)]` on `captures_read_at`. This is usually a bad idea" -regex-1.3.2/src/exec.rs:425:41 clippy::inline_always "you have declared `#[inline(always)]` on `shortest_match_at`. This is usually a bad idea" -regex-1.3.2/src/exec.rs:44:1 clippy::module_name_repetitions "item name starts with its containing module's name" -regex-1.3.2/src/exec.rs:473:9 clippy::doc_markdown "you should put `shortest_match(...).is_some` between ticks in the documentation" -regex-1.3.2/src/exec.rs:474:41 clippy::inline_always "you have declared `#[inline(always)]` on `is_match_at`. This is usually a bad idea" -regex-1.3.2/src/exec.rs:524:41 clippy::inline_always "you have declared `#[inline(always)]` on `find_at`. This is usually a bad idea" -regex-1.3.2/src/exec.rs:52:1 clippy::module_name_repetitions "item name starts with its containing module's name" -regex-1.3.2/src/exec.rs:686:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/exec.rs:727:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/exec.rs:767:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/exec.rs:783:41 clippy::inline_always "you have declared `#[inline(always)]` on `shortest_dfa`. This is usually a bad idea" -regex-1.3.2/src/exec.rs:791:41 clippy::inline_always "you have declared `#[inline(always)]` on `shortest_dfa_reverse_suffix`. This is usually a bad idea" -regex-1.3.2/src/exec.rs:823:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/exec.rs:868:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/exec.rs:897:31 clippy::doc_markdown "you should put `shortest_nfa(...).is_some` between ticks in the documentation" -regex-1.3.2/src/exec.rs:899:9 clippy::doc_markdown "you should put `shortest_nfa` between ticks in the documentation" -regex-1.3.2/src/exec.rs:905:14 clippy::doc_markdown "you should put `match_nfa` between ticks in the documentation" -regex-1.3.2/src/exec.rs:930:14 clippy::doc_markdown "you should put `shortest_nfa` between ticks in the documentation" -regex-1.3.2/src/exec.rs:981:14 clippy::doc_markdown "you should put `find_nfa` between ticks in the documentation" -regex-1.3.2/src/expand.rs:170:27 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -regex-1.3.2/src/expand.rs:171:5 clippy::match_like_matches_macro "match expression looks like `matches!` macro" -regex-1.3.2/src/expand.rs:22:13 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -regex-1.3.2/src/expand.rs:27:23 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -regex-1.3.2/src/expand.rs:30:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" -regex-1.3.2/src/expand.rs:38:30 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" -regex-1.3.2/src/expand.rs:42:21 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" -regex-1.3.2/src/expand.rs:50:1 clippy::module_name_repetitions "item name starts with its containing module's name" -regex-1.3.2/src/expand.rs:69:23 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -regex-1.3.2/src/expand.rs:80:28 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" -regex-1.3.2/src/expand.rs:84:21 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" -regex-1.3.2/src/expand.rs:8:1 clippy::module_name_repetitions "item name starts with its containing module's name" -regex-1.3.2/src/input.rs:142:1 clippy::module_name_repetitions "item name ends with its containing module's name" -regex-1.3.2/src/input.rs:146:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/input.rs:15:1 clippy::module_name_repetitions "item name starts with its containing module's name" -regex-1.3.2/src/input.rs:165:31 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/input.rs:178:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/input.rs:228:1 clippy::module_name_repetitions "item name ends with its containing module's name" -regex-1.3.2/src/input.rs:236:21 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/input.rs:236:33 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/input.rs:24:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/input.rs:271:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/input.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/input.rs:362:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/input.rs:370:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/input.rs:371:42 clippy::redundant_closure_for_method_calls "redundant closure found" -regex-1.3.2/src/input.rs:37:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/input.rs:388:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/input.rs:42:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/input.rs:47:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/input.rs:53:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/input.rs:58:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/input.rs:63:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/lib.rs:1:null clippy::cargo_common_metadata "package `regex` is missing `package.keywords` metadata" -regex-1.3.2/src/literal/imp.rs:101:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/literal/imp.rs:114:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/literal/imp.rs:127:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/literal/imp.rs:139:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/literal/imp.rs:144:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/literal/imp.rs:149:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/literal/imp.rs:154:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/literal/imp.rs:155:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/literal/imp.rs:160:30 clippy::match_same_arms "this `match` has identical arm bodies" -regex-1.3.2/src/literal/imp.rs:167:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/literal/imp.rs:168:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/literal/imp.rs:211:20 clippy::redundant_else "redundant else block" -regex-1.3.2/src/literal/imp.rs:276:50 clippy::match_same_arms "this `match` has identical arm bodies" -regex-1.3.2/src/literal/imp.rs:342:41 clippy::inline_always "you have declared `#[inline(always)]` on `find`. This is usually a bad idea" -regex-1.3.2/src/literal/imp.rs:435:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/literal/imp.rs:436:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/literal/imp.rs:437:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/literal/imp.rs:438:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/literal/imp.rs:439:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/literal/imp.rs:440:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/literal/imp.rs:455:41 clippy::inline_always "you have declared `#[inline(always)]` on `find`. This is usually a bad idea" -regex-1.3.2/src/literal/imp.rs:46:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/literal/imp.rs:481:41 clippy::inline_always "you have declared `#[inline(always)]` on `is_suffix`. This is usually a bad idea" -regex-1.3.2/src/literal/imp.rs:51:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/literal/imp.rs:579:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/literal/imp.rs:57:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/literal/imp.rs:580:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/literal/imp.rs:583:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/literal/imp.rs:602:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -regex-1.3.2/src/literal/imp.rs:622:24 clippy::redundant_else "redundant else block" -regex-1.3.2/src/literal/imp.rs:62:18 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -regex-1.3.2/src/literal/imp.rs:637:24 clippy::redundant_else "redundant else block" -regex-1.3.2/src/literal/imp.rs:648:9 clippy::needless_return "unneeded `return` statement" -regex-1.3.2/src/literal/imp.rs:651:44 clippy::doc_markdown "you should put `BoyerMooreSearch` between ticks in the documentation" -regex-1.3.2/src/literal/imp.rs:65:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/literal/imp.rs:68:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/literal/imp.rs:783:32 clippy::redundant_else "redundant else block" -regex-1.3.2/src/literal/imp.rs:786:42 clippy::manual_saturating_arithmetic "manual saturating arithmetic" -regex-1.3.2/src/literal/imp.rs:78:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/literal/imp.rs:84:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/literal/imp.rs:850:20 clippy::unreadable_literal "long literal lacking separators" -regex-1.3.2/src/literal/imp.rs:85:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/pikevm.rs:103:15 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/pikevm.rs:103:52 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/pikevm.rs:114:5 clippy::too_many_arguments "this function has too many arguments (8/7)" -regex-1.3.2/src/pikevm.rs:117:13 clippy::similar_names "binding's name is too similar to existing binding" -regex-1.3.2/src/pikevm.rs:124:17 clippy::similar_names "binding's name is too similar to existing binding" -regex-1.3.2/src/pikevm.rs:220:9 clippy::doc_markdown "you should put `thread_caps` between ticks in the documentation" -regex-1.3.2/src/pikevm.rs:222:16 clippy::doc_markdown "you should put `at_next` between ticks in the documentation" -regex-1.3.2/src/pikevm.rs:223:9 clippy::doc_markdown "you should put `at_next` between ticks in the documentation" -regex-1.3.2/src/pikevm.rs:224:5 clippy::too_many_arguments "this function has too many arguments (8/7)" -regex-1.3.2/src/pikevm.rs:234:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/pikevm.rs:303:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/pikevm.rs:331:29 clippy::mut_mut "this expression mutably borrows a mutable reference. Consider reborrowing" -regex-1.3.2/src/pikevm.rs:88:5 clippy::too_many_arguments "this function has too many arguments (8/7)" -regex-1.3.2/src/prog.rs:102:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/prog.rs:113:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/prog.rs:120:9 clippy::match_like_matches_macro "match expression looks like `matches!` macro" -regex-1.3.2/src/prog.rs:128:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/prog.rs:134:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/prog.rs:141:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/prog.rs:147:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/prog.rs:164:41 clippy::inline_always "you have declared `#[inline(always)]` on `deref`. This is usually a bad idea" -regex-1.3.2/src/prog.rs:172:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -regex-1.3.2/src/prog.rs:18:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -regex-1.3.2/src/prog.rs:236:13 clippy::write_with_newline "using `write!()` with a format string that ends in a single newline" -regex-1.3.2/src/prog.rs:300:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/prog.rs:301:9 clippy::match_like_matches_macro "match expression looks like `matches!` macro" -regex-1.3.2/src/prog.rs:382:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/prog.rs:409:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/prog.rs:80:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/prog.rs:80:5 clippy::new_without_default "you should consider adding a `Default` implementation for `prog::Program`" -regex-1.3.2/src/re_builder.rs:267:17 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -regex-1.3.2/src/re_builder.rs:267:17 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -regex-1.3.2/src/re_builder.rs:4:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -regex-1.3.2/src/re_builder.rs:57:17 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_builder.rs:57:17 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_builder.rs:68:17 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -regex-1.3.2/src/re_builder.rs:68:17 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -regex-1.3.2/src/re_bytes.rs:1017:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" -regex-1.3.2/src/re_bytes.rs:1039:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" -regex-1.3.2/src/re_bytes.rs:1093:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -regex-1.3.2/src/re_bytes.rs:1118:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -regex-1.3.2/src/re_bytes.rs:1133:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -regex-1.3.2/src/re_bytes.rs:118:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -regex-1.3.2/src/re_bytes.rs:256:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/re_bytes.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_bytes.rs:35:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_bytes.rs:42:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_bytes.rs:483:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -regex-1.3.2/src/re_bytes.rs:48:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_bytes.rs:558:29 clippy::doc_markdown "you should put `shortest_match` between ticks in the documentation" -regex-1.3.2/src/re_bytes.rs:55:33 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/re_bytes.rs:55:47 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/re_bytes.rs:572:29 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" -regex-1.3.2/src/re_bytes.rs:720:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/re_bytes.rs:817:5 clippy::doc_markdown "you should put `CaptureLocations` between ticks in the documentation" -regex-1.3.2/src/re_bytes.rs:843:1 clippy::len_without_is_empty "item `re_bytes::CaptureLocations` has a public `len` method but no corresponding `is_empty` method" -regex-1.3.2/src/re_bytes.rs:849:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_bytes.rs:858:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_bytes.rs:869:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_bytes.rs:891:1 clippy::len_without_is_empty "item `re_bytes::Captures<'t>` has a public `len` method but no corresponding `is_empty` method" -regex-1.3.2/src/re_bytes.rs:911:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_bytes.rs:917:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_bytes.rs:926:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_bytes.rs:955:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_set.rs:179:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/re_set.rs:179:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/re_set.rs:251:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_set.rs:251:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_set.rs:263:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_set.rs:263:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_set.rs:268:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_set.rs:268:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_set.rs:277:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_set.rs:277:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_set.rs:94:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -regex-1.3.2/src/re_set.rs:94:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -regex-1.3.2/src/re_trait.rs:136:29 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/re_unicode.rs:1019:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" -regex-1.3.2/src/re_unicode.rs:1041:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" -regex-1.3.2/src/re_unicode.rs:1088:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/re_unicode.rs:1135:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -regex-1.3.2/src/re_unicode.rs:1160:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -regex-1.3.2/src/re_unicode.rs:174:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" -regex-1.3.2/src/re_unicode.rs:21:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" -regex-1.3.2/src/re_unicode.rs:313:13 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/re_unicode.rs:38:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_unicode.rs:44:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_unicode.rs:51:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_unicode.rs:533:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -regex-1.3.2/src/re_unicode.rs:57:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_unicode.rs:617:29 clippy::doc_markdown "you should put `shortest_match` between ticks in the documentation" -regex-1.3.2/src/re_unicode.rs:631:29 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" -regex-1.3.2/src/re_unicode.rs:64:33 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/re_unicode.rs:64:47 clippy::redundant_field_names "redundant field names in struct initialization" -regex-1.3.2/src/re_unicode.rs:834:5 clippy::doc_markdown "you should put `CaptureLocations` between ticks in the documentation" -regex-1.3.2/src/re_unicode.rs:860:1 clippy::len_without_is_empty "item `re_unicode::CaptureLocations` has a public `len` method but no corresponding `is_empty` method" -regex-1.3.2/src/re_unicode.rs:866:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_unicode.rs:875:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_unicode.rs:886:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_unicode.rs:908:1 clippy::len_without_is_empty "item `re_unicode::Captures<'t>` has a public `len` method but no corresponding `is_empty` method" -regex-1.3.2/src/re_unicode.rs:928:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_unicode.rs:934:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_unicode.rs:943:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/re_unicode.rs:972:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" -regex-1.3.2/src/sparse.rs:10:37 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" -regex-1.3.2/src/sparse.rs:15:1 clippy::module_name_repetitions "item name starts with its containing module's name" -regex-1.3.2/src/utf8.rs:100:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex-1.3.2/src/utf8.rs:103:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex-1.3.2/src/utf8.rs:106:22 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" -regex-1.3.2/src/utf8.rs:107:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" -regex-1.3.2/src/utf8.rs:108:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" -regex-1.3.2/src/utf8.rs:109:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" -regex-1.3.2/src/utf8.rs:111:27 clippy::unreadable_literal "long literal lacking separators" -regex-1.3.2/src/utf8.rs:121:1 clippy::module_name_repetitions "item name ends with its containing module's name" -regex-1.3.2/src/utf8.rs:143:24 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex-1.3.2/src/utf8.rs:143:9 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex-1.3.2/src/utf8.rs:23:1 clippy::module_name_repetitions "item name ends with its containing module's name" -regex-1.3.2/src/utf8.rs:30:20 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex-1.3.2/src/utf8.rs:51:1 clippy::module_name_repetitions "item name ends with its containing module's name" -regex-1.3.2/src/utf8.rs:58:23 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex-1.3.2/src/utf8.rs:58:9 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex-1.3.2/src/utf8.rs:63:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex-1.3.2/src/utf8.rs:66:22 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" -regex-1.3.2/src/utf8.rs:66:54 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" -regex-1.3.2/src/utf8.rs:77:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex-1.3.2/src/utf8.rs:80:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex-1.3.2/src/utf8.rs:83:22 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" -regex-1.3.2/src/utf8.rs:84:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" -regex-1.3.2/src/utf8.rs:85:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" -regex-1.3.2/src/utf8.rs:92:23 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex-1.3.2/src/utf8.rs:92:9 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -regex-1.3.2/src/utf8.rs:97:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" -ripgrep-12.1.1/build.rs:133:19 clippy::option_as_ref_deref "called `.as_ref().map(|x| &**x)` on an Option value. This can be done more directly by calling `githash.as_deref()` instead" -ripgrep-12.1.1/build.rs:18:18 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -ripgrep-12.1.1/build.rs:225:14 clippy::redundant_closure_for_method_calls "redundant closure found" -ripgrep-12.1.1/build.rs:92:19 clippy::option_as_ref_deref "called `.as_ref().map(|x| &**x)` on an Option value. This can be done more directly by calling `githash.as_deref()` instead" -ripgrep-12.1.1/crates/core/app.rs:1408:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep-12.1.1/crates/core/app.rs:1408:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep-12.1.1/crates/core/app.rs:1409:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep-12.1.1/crates/core/app.rs:1409:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep-12.1.1/crates/core/app.rs:152:32 clippy::doc_markdown "you should put `clap::Arg` between ticks in the documentation" -ripgrep-12.1.1/crates/core/app.rs:152:32 clippy::doc_markdown "you should put `clap::Arg` between ticks in the documentation" -ripgrep-12.1.1/crates/core/app.rs:156:39 clippy::doc_markdown "you should put `clap::Arg` between ticks in the documentation" -ripgrep-12.1.1/crates/core/app.rs:156:39 clippy::doc_markdown "you should put `clap::Arg` between ticks in the documentation" -ripgrep-12.1.1/crates/core/app.rs:156:5 clippy::doc_markdown "you should put `RGArg` between ticks in the documentation" -ripgrep-12.1.1/crates/core/app.rs:156:5 clippy::doc_markdown "you should put `RGArg` between ticks in the documentation" -ripgrep-12.1.1/crates/core/app.rs:1668:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep-12.1.1/crates/core/app.rs:1668:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep-12.1.1/crates/core/app.rs:1669:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep-12.1.1/crates/core/app.rs:1669:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep-12.1.1/crates/core/app.rs:1821:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep-12.1.1/crates/core/app.rs:1821:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep-12.1.1/crates/core/app.rs:1822:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep-12.1.1/crates/core/app.rs:1822:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep-12.1.1/crates/core/app.rs:2999:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep-12.1.1/crates/core/app.rs:2999:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep-12.1.1/crates/core/app.rs:3000:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep-12.1.1/crates/core/app.rs:3000:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" -ripgrep-12.1.1/crates/core/app.rs:367:54 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep-12.1.1/crates/core/app.rs:367:54 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep-12.1.1/crates/core/app.rs:414:59 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep-12.1.1/crates/core/app.rs:414:59 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep-12.1.1/crates/core/app.rs:417:57 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep-12.1.1/crates/core/app.rs:417:57 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep-12.1.1/crates/core/app.rs:417:57 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep-12.1.1/crates/core/app.rs:417:57 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep-12.1.1/crates/core/app.rs:75:9 clippy::doc_markdown "you should put `RIPGREP_BUILD_GIT_HASH` between ticks in the documentation" -ripgrep-12.1.1/crates/core/app.rs:75:9 clippy::doc_markdown "you should put `RIPGREP_BUILD_GIT_HASH` between ticks in the documentation" -ripgrep-12.1.1/crates/core/app.rs:87:5 clippy::if_not_else "unnecessary boolean `not` operation" -ripgrep-12.1.1/crates/core/app.rs:87:5 clippy::if_not_else "unnecessary boolean `not` operation" -ripgrep-12.1.1/crates/core/args.rs:1143:22 clippy::unused_self "unused `self` argument" -ripgrep-12.1.1/crates/core/args.rs:11:1 clippy::single_component_path_imports "this import is redundant" -ripgrep-12.1.1/crates/core/args.rs:1209:74 clippy::if_same_then_else "this `if` has identical blocks" -ripgrep-12.1.1/crates/core/args.rs:1282:13 clippy::similar_names "binding's name is too similar to existing binding" -ripgrep-12.1.1/crates/core/args.rs:1430:22 clippy::unused_self "unused `self` argument" -ripgrep-12.1.1/crates/core/args.rs:1438:21 clippy::doc_markdown "you should put `OsStr` between ticks in the documentation" -ripgrep-12.1.1/crates/core/args.rs:1520:44 clippy::redundant_closure_for_method_calls "redundant closure found" -ripgrep-12.1.1/crates/core/args.rs:1524:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -ripgrep-12.1.1/crates/core/args.rs:1635:14 clippy::doc_markdown "you should put `values_of_lossy` between ticks in the documentation" -ripgrep-12.1.1/crates/core/args.rs:1693:41 clippy::redundant_closure_for_method_calls "redundant closure found" -ripgrep-12.1.1/crates/core/args.rs:1770:17 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -ripgrep-12.1.1/crates/core/args.rs:1829:5 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" -ripgrep-12.1.1/crates/core/args.rs:287:13 clippy::similar_names "binding's name is too similar to existing binding" -ripgrep-12.1.1/crates/core/args.rs:33:1 clippy::single_component_path_imports "this import is redundant" -ripgrep-12.1.1/crates/core/args.rs:34:1 clippy::single_component_path_imports "this import is redundant" -ripgrep-12.1.1/crates/core/args.rs:35:1 clippy::single_component_path_imports "this import is redundant" -ripgrep-12.1.1/crates/core/args.rs:369:5 clippy::upper_case_acronyms "name `JSON` contains a capitalized acronym" -ripgrep-12.1.1/crates/core/args.rs:410:14 clippy::trivially_copy_pass_by_ref "this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -ripgrep-12.1.1/crates/core/args.rs:475:18 clippy::match_same_arms "this `match` has identical arm bodies" -ripgrep-12.1.1/crates/core/args.rs:512:19 clippy::doc_markdown "you should put `ArgMatches` between ticks in the documentation" -ripgrep-12.1.1/crates/core/args.rs:549:16 clippy::wrong_self_convention "methods called `to_*` usually take self by reference; consider choosing a less ambiguous name" -ripgrep-12.1.1/crates/core/args.rs:76:18 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -ripgrep-12.1.1/crates/core/args.rs:77:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -ripgrep-12.1.1/crates/core/args.rs:923:42 clippy::doc_markdown "you should put `BinaryDetection::quit` between ticks in the documentation" -ripgrep-12.1.1/crates/core/config.rs:13:1 clippy::single_component_path_imports "this import is redundant" -ripgrep-12.1.1/crates/core/config.rs:58:6 clippy::type_complexity "very complex type used. Consider factoring parts into `type` definitions" -ripgrep-12.1.1/crates/core/config.rs:79:6 clippy::type_complexity "very complex type used. Consider factoring parts into `type` definitions" -ripgrep-12.1.1/crates/core/logger.rs:11:30 clippy::doc_markdown "you should put `max_level` between ticks in the documentation" -ripgrep-12.1.1/crates/core/logger.rs:15:16 clippy::redundant_static_lifetimes "constants have by default a `'static` lifetime" -ripgrep-12.1.1/crates/core/main.rs:114:9 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" -ripgrep-12.1.1/crates/core/main.rs:189:9 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" -ripgrep-12.1.1/crates/core/main.rs:55:19 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -ripgrep-12.1.1/crates/core/main.rs:56:9 clippy::enum_glob_use "usage of wildcard import for enum variants" -ripgrep-12.1.1/crates/core/messages.rs:46:1 clippy::module_name_repetitions "item name ends with its containing module's name" -ripgrep-12.1.1/crates/core/messages.rs:51:1 clippy::module_name_repetitions "item name ends with its containing module's name" -ripgrep-12.1.1/crates/core/messages.rs:62:1 clippy::module_name_repetitions "item name ends with its containing module's name" -ripgrep-12.1.1/crates/core/path_printer.rs:27:1 clippy::module_name_repetitions "item name starts with its containing module's name" -ripgrep-12.1.1/crates/core/path_printer.rs:89:9 clippy::if_not_else "unnecessary boolean `not` operation" -ripgrep-12.1.1/crates/core/search.rs:185:1 clippy::module_name_repetitions "item name starts with its containing module's name" -ripgrep-12.1.1/crates/core/search.rs:224:5 clippy::upper_case_acronyms "name `JSON` contains a capitalized acronym" -ripgrep-12.1.1/crates/core/search.rs:292:9 clippy::write_with_newline "using `write!()` with a format string that ends in a single newline" -ripgrep-12.1.1/crates/core/search.rs:311:1 clippy::module_name_repetitions "item name starts with its containing module's name" -ripgrep-12.1.1/crates/core/search.rs:377:12 clippy::nonminimal_bool "this boolean expression can be simplified" -ripgrep-12.1.1/crates/core/search.rs:423:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -ripgrep-12.1.1/crates/core/search.rs:447:13 clippy::enum_glob_use "usage of wildcard import for enum variants" -ripgrep-12.1.1/crates/core/search.rs:472:24 clippy::map_clone "you are using an explicit closure for cloning elements" -ripgrep-12.1.1/crates/core/search.rs:472:41 clippy::redundant_closure_for_method_calls "redundant closure found" -ripgrep-12.1.1/crates/core/search.rs:480:24 clippy::map_clone "you are using an explicit closure for cloning elements" -ripgrep-12.1.1/crates/core/search.rs:480:41 clippy::redundant_closure_for_method_calls "redundant closure found" -ripgrep-12.1.1/crates/core/search.rs:49:1 clippy::module_name_repetitions "item name starts with its containing module's name" -ripgrep-12.1.1/crates/core/search.rs:509:24 clippy::map_clone "you are using an explicit closure for cloning elements" -ripgrep-12.1.1/crates/core/search.rs:509:41 clippy::redundant_closure_for_method_calls "redundant closure found" -ripgrep-12.1.1/crates/core/search.rs:517:24 clippy::map_clone "you are using an explicit closure for cloning elements" -ripgrep-12.1.1/crates/core/search.rs:517:41 clippy::redundant_closure_for_method_calls "redundant closure found" -ripgrep-12.1.1/crates/core/search.rs:533:36 clippy::cast_lossless "casting `u32` to `f64` may become silently lossy if you later change the type" -ripgrep-12.1.1/crates/core/search.rs:533:5 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -ripgrep-12.1.1/crates/core/subject.rs:20:1 clippy::module_name_repetitions "item name starts with its containing module's name" -ripgrep-12.1.1/crates/core/subject.rs:4:1 clippy::single_component_path_imports "this import is redundant" -serde-1.0.118/src/de/mod.rs:1592:9 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" -serde-1.0.118/src/de/mod.rs:1616:9 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" -serde-1.0.118/src/de/mod.rs:1627:9 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" -serde-1.0.118/src/de/mod.rs:1638:9 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" -serde-1.0.118/src/de/mod.rs:1649:9 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" -serde-1.0.118/src/de/mod.rs:952:13 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" -serde-1.0.118/src/de/mod.rs:986:13 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" -syn-1.0.54/build.rs:1:null clippy::cargo_common_metadata "package `syn` is missing `package.keywords` metadata" -syn-1.0.54/src/lib.rs:1:null clippy::cargo_common_metadata "package `syn` is missing `package.keywords` metadata" -syn-1.0.54/src/lit.rs:1397:40 clippy::redundant_else "redundant else block" -syn-1.0.54/src/lit.rs:1405:28 clippy::redundant_else "redundant else block" -syn-1.0.54/src/lit.rs:1485:32 clippy::redundant_else "redundant else block" -syn-1.0.54/src/token.rs:974:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" -unicode-xid-0.2.1/src/lib.rs:1:null clippy::cargo_common_metadata "package `unicode-xid` is missing `package.categories` metadata" -unicode-xid-0.2.1/src/lib.rs:57:64 clippy::doc_markdown "you should put `XID_Start` between ticks in the documentation" -unicode-xid-0.2.1/src/lib.rs:60:10 clippy::doc_markdown "you should put `XID_Start` between ticks in the documentation" -unicode-xid-0.2.1/src/lib.rs:62:27 clippy::doc_markdown "you should put `ID_Start` between ticks in the documentation" -unicode-xid-0.2.1/src/lib.rs:62:67 clippy::doc_markdown "you should put `NFKx` between ticks in the documentation" -unicode-xid-0.2.1/src/lib.rs:63:21 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" -unicode-xid-0.2.1/src/lib.rs:65:61 clippy::doc_markdown "you should put `XID_Continue` between ticks in the documentation" -unicode-xid-0.2.1/src/lib.rs:68:10 clippy::doc_markdown "you should put `XID_Continue` between ticks in the documentation" -unicode-xid-0.2.1/src/lib.rs:70:28 clippy::doc_markdown "you should put `ID_Continue` between ticks in the documentation" -unicode-xid-0.2.1/src/lib.rs:70:72 clippy::doc_markdown "you should put `NFKx` between ticks in the documentation" -unicode-xid-0.2.1/src/lib.rs:71:24 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" -xsv-0.13.0/src/cmd/cat.rs:101:34 clippy::redundant_closure_for_method_calls "redundant closure found" -xsv-0.13.0/src/cmd/cat.rs:42:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -xsv-0.13.0/src/cmd/cat.rs:53:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/cat.rs:7:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv-0.13.0/src/cmd/count.rs:32:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/count.rs:38:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -xsv-0.13.0/src/cmd/count.rs:42:33 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -xsv-0.13.0/src/cmd/count.rs:7:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv-0.13.0/src/cmd/fixlengths.rs:45:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/fixlengths.rs:50:18 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -xsv-0.13.0/src/cmd/fixlengths.rs:62:30 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -xsv-0.13.0/src/cmd/fixlengths.rs:9:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv-0.13.0/src/cmd/flatten.rs:10:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv-0.13.0/src/cmd/flatten.rs:51:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/fmt.rs:50:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/fmt.rs:55:13 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/fmt.rs:7:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv-0.13.0/src/cmd/frequency.rs:148:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -xsv-0.13.0/src/cmd/frequency.rs:149:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -xsv-0.13.0/src/cmd/frequency.rs:15:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv-0.13.0/src/cmd/frequency.rs:169:13 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/frequency.rs:176:17 clippy::if_not_else "unnecessary boolean `not` operation" -xsv-0.13.0/src/cmd/frequency.rs:178:24 clippy::collapsible_else_if "this `else { if .. }` block can be collapsed" -xsv-0.13.0/src/cmd/frequency.rs:77:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/frequency.rs:93:31 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" -xsv-0.13.0/src/cmd/headers.rs:43:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/headers.rs:49:17 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" -xsv-0.13.0/src/cmd/headers.rs:9:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv-0.13.0/src/cmd/index.rs:11:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv-0.13.0/src/cmd/index.rs:45:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/input.rs:42:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/input.rs:47:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/input.rs:7:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv-0.13.0/src/cmd/join.rs:17:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv-0.13.0/src/cmd/join.rs:194:29 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/join.rs:224:22 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/join.rs:293:14 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/join.rs:293:20 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/join.rs:297:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv-0.13.0/src/cmd/join.rs:298:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv-0.13.0/src/cmd/join.rs:299:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv-0.13.0/src/cmd/join.rs:300:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv-0.13.0/src/cmd/join.rs:308:9 clippy::unused_self "unused `self` argument" -xsv-0.13.0/src/cmd/join.rs:342:38 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -xsv-0.13.0/src/cmd/join.rs:342:46 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" -xsv-0.13.0/src/cmd/join.rs:347:9 clippy::if_not_else "unnecessary boolean `not` operation" -xsv-0.13.0/src/cmd/join.rs:372:44 clippy::redundant_closure_for_method_calls "redundant closure found" -xsv-0.13.0/src/cmd/join.rs:375:33 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/join.rs:392:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv-0.13.0/src/cmd/join.rs:403:29 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" -xsv-0.13.0/src/cmd/join.rs:426:13 clippy::if_not_else "unnecessary boolean `not` operation" -xsv-0.13.0/src/cmd/join.rs:77:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -xsv-0.13.0/src/cmd/join.rs:94:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/partition.rs:105:22 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/partition.rs:106:22 clippy::redundant_slicing "redundant slicing of the whole range" -xsv-0.13.0/src/cmd/partition.rs:139:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv-0.13.0/src/cmd/partition.rs:15:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv-0.13.0/src/cmd/partition.rs:169:9 clippy::if_not_else "unnecessary boolean `not` operation" -xsv-0.13.0/src/cmd/partition.rs:56:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/partition.rs:77:9 clippy::unused_self "unused `self` argument" -xsv-0.13.0/src/cmd/sample.rs:105:44 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -xsv-0.13.0/src/cmd/sample.rs:115:21 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -xsv-0.13.0/src/cmd/sample.rs:11:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv-0.13.0/src/cmd/sample.rs:51:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/sample.rs:58:19 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -xsv-0.13.0/src/cmd/sample.rs:69:9 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" -xsv-0.13.0/src/cmd/sample.rs:75:16 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" -xsv-0.13.0/src/cmd/sample.rs:91:42 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -xsv-0.13.0/src/cmd/sample.rs:92:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -xsv-0.13.0/src/cmd/search.rs:51:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/search.rs:9:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv-0.13.0/src/cmd/select.rs:60:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/select.rs:8:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv-0.13.0/src/cmd/slice.rs:57:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/slice.rs:9:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv-0.13.0/src/cmd/sort.rs:11:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv-0.13.0/src/cmd/sort.rs:138:47 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -xsv-0.13.0/src/cmd/sort.rs:139:51 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -xsv-0.13.0/src/cmd/sort.rs:48:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/sort.rs:91:14 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" -xsv-0.13.0/src/cmd/split.rs:14:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv-0.13.0/src/cmd/split.rs:61:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/split.rs:94:5 clippy::unnecessary_wraps "this function's return value is unnecessary" -xsv-0.13.0/src/cmd/split.rs:96:14 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -xsv-0.13.0/src/cmd/split.rs:99:13 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -xsv-0.13.0/src/cmd/stats.rs:110:36 clippy::redundant_closure_for_method_calls "redundant closure found" -xsv-0.13.0/src/cmd/stats.rs:127:14 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" -xsv-0.13.0/src/cmd/stats.rs:138:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -xsv-0.13.0/src/cmd/stats.rs:139:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" -xsv-0.13.0/src/cmd/stats.rs:162:25 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" -xsv-0.13.0/src/cmd/stats.rs:22:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv-0.13.0/src/cmd/stats.rs:231:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -xsv-0.13.0/src/cmd/stats.rs:262:35 clippy::default_trait_access "calling `cmd::stats::TypedSum::default()` is more clear than this expression" -xsv-0.13.0/src/cmd/stats.rs:263:40 clippy::default_trait_access "calling `cmd::stats::TypedMinMax::default()` is more clear than this expression" -xsv-0.13.0/src/cmd/stats.rs:264:39 clippy::default_trait_access "calling `stats::OnlineStats::default()` is more clear than this expression" -xsv-0.13.0/src/cmd/stats.rs:265:58 clippy::default_trait_access "calling `stats::Unsorted::default()` is more clear than this expression" -xsv-0.13.0/src/cmd/stats.rs:266:41 clippy::default_trait_access "calling `stats::Unsorted::default()` is more clear than this expression" -xsv-0.13.0/src/cmd/stats.rs:268:18 clippy::default_trait_access "calling `cmd::stats::FieldType::default()` is more clear than this expression" -xsv-0.13.0/src/cmd/stats.rs:269:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv-0.13.0/src/cmd/stats.rs:270:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv-0.13.0/src/cmd/stats.rs:271:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv-0.13.0/src/cmd/stats.rs:272:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv-0.13.0/src/cmd/stats.rs:273:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv-0.13.0/src/cmd/stats.rs:274:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv-0.13.0/src/cmd/stats.rs:283:9 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" -xsv-0.13.0/src/cmd/stats.rs:284:9 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" -xsv-0.13.0/src/cmd/stats.rs:285:9 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" -xsv-0.13.0/src/cmd/stats.rs:290:21 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" -xsv-0.13.0/src/cmd/stats.rs:293:25 clippy::match_same_arms "this `match` has identical arm bodies" -xsv-0.13.0/src/cmd/stats.rs:297:25 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" -xsv-0.13.0/src/cmd/stats.rs:301:21 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" -xsv-0.13.0/src/cmd/stats.rs:302:21 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" -xsv-0.13.0/src/cmd/stats.rs:308:18 clippy::wrong_self_convention "methods called `to_*` usually take self by reference; consider choosing a less ambiguous name" -xsv-0.13.0/src/cmd/stats.rs:318:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -xsv-0.13.0/src/cmd/stats.rs:322:45 clippy::redundant_closure_for_method_calls "redundant closure found" -xsv-0.13.0/src/cmd/stats.rs:322:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -xsv-0.13.0/src/cmd/stats.rs:327:9 clippy::if_not_else "unnecessary boolean `not` operation" -xsv-0.13.0/src/cmd/stats.rs:330:13 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" -xsv-0.13.0/src/cmd/stats.rs:338:45 clippy::redundant_closure_for_method_calls "redundant closure found" -xsv-0.13.0/src/cmd/stats.rs:402:16 clippy::redundant_pattern_matching "redundant pattern matching, consider using `is_ok()`" -xsv-0.13.0/src/cmd/stats.rs:403:16 clippy::redundant_pattern_matching "redundant pattern matching, consider using `is_ok()`" -xsv-0.13.0/src/cmd/stats.rs:407:18 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -xsv-0.13.0/src/cmd/stats.rs:411:16 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -xsv-0.13.0/src/cmd/stats.rs:427:56 clippy::match_same_arms "this `match` has identical arm bodies" -xsv-0.13.0/src/cmd/stats.rs:429:56 clippy::match_same_arms "this `match` has identical arm bodies" -xsv-0.13.0/src/cmd/stats.rs:430:60 clippy::match_same_arms "this `match` has identical arm bodies" -xsv-0.13.0/src/cmd/stats.rs:430:60 clippy::match_same_arms "this `match` has identical arm bodies" -xsv-0.13.0/src/cmd/stats.rs:454:5 clippy::doc_markdown "you should put `TypedSum` between ticks in the documentation" -xsv-0.13.0/src/cmd/stats.rs:473:43 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -xsv-0.13.0/src/cmd/stats.rs:504:56 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -xsv-0.13.0/src/cmd/stats.rs:505:51 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -xsv-0.13.0/src/cmd/stats.rs:511:5 clippy::doc_markdown "you should put `TypedMinMax` between ticks in the documentation" -xsv-0.13.0/src/cmd/stats.rs:536:35 clippy::cast_possible_truncation "casting `f64` to `i64` may truncate the value" -xsv-0.13.0/src/cmd/stats.rs:544:33 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" -xsv-0.13.0/src/cmd/stats.rs:592:22 clippy::default_trait_access "calling `stats::MinMax::default()` is more clear than this expression" -xsv-0.13.0/src/cmd/stats.rs:593:22 clippy::default_trait_access "calling `stats::MinMax::default()` is more clear than this expression" -xsv-0.13.0/src/cmd/stats.rs:594:23 clippy::default_trait_access "calling `stats::MinMax::default()` is more clear than this expression" -xsv-0.13.0/src/cmd/stats.rs:595:21 clippy::default_trait_access "calling `stats::MinMax::default()` is more clear than this expression" -xsv-0.13.0/src/cmd/stats.rs:71:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -xsv-0.13.0/src/cmd/stats.rs:86:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/table.rs:10:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv-0.13.0/src/cmd/table.rs:50:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/cmd/table.rs:54:9 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/config.rs:113:43 clippy::or_fun_call "use of `unwrap_or` followed by a function call" -xsv-0.13.0/src/config.rs:58:1 clippy::struct_excessive_bools "more than 3 bools in a struct" -xsv-0.13.0/src/config.rs:77:28 clippy::explicit_deref_methods "explicit deref method call" -xsv-0.13.0/src/config.rs:90:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv-0.13.0/src/index.rs:31:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv-0.13.0/src/main.rs:164:49 clippy::redundant_clone "redundant clone" -xsv-0.13.0/src/main.rs:1:null clippy::cargo_common_metadata "package `xsv` is missing `package.categories` metadata" -xsv-0.13.0/src/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `rand_core`: 0.3.1, 0.4.2" -xsv-0.13.0/src/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `rand`: 0.3.23, 0.4.6" -xsv-0.13.0/src/main.rs:75:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" -xsv-0.13.0/src/select.rs:13:1 clippy::module_name_repetitions "item name starts with its containing module's name" -xsv-0.13.0/src/select.rs:154:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" -xsv-0.13.0/src/select.rs:250:33 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/select.rs:250:43 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/select.rs:255:39 clippy::range_plus_one "an inclusive range would be more readable" -xsv-0.13.0/src/select.rs:280:20 clippy::len_zero "length comparison to zero" -xsv-0.13.0/src/select.rs:29:13 clippy::redundant_field_names "redundant field names in struct initialization" -xsv-0.13.0/src/select.rs:360:62 clippy::trivially_copy_pass_by_ref "this argument (8 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" -xsv-0.13.0/src/select.rs:360:9 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Option`" -xsv-0.13.0/src/select.rs:375:9 clippy::stable_sort_primitive "used `sort` on primitive type `usize`" -xsv-0.13.0/src/select.rs:379:18 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" -xsv-0.13.0/src/select.rs:416:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" -xsv-0.13.0/src/select.rs:419:9 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Option`" -xsv-0.13.0/src/select.rs:420:27 clippy::option_option "consider using `Option` instead of `Option>` or a custom enum if you need to distinguish all 3 cases" -xsv-0.13.0/src/select.rs:99:17 clippy::similar_names "binding's name is too similar to existing binding" -xsv-0.13.0/src/util.rs:150:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" -xsv-0.13.0/src/util.rs:37:33 clippy::map_clone "you are using an explicit closure for copying elements" -xsv-0.13.0/src/util.rs:90:1 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +target/lintcheck/sources/cargo-0.49.0/build.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.categories` metadata" +target/lintcheck/sources/cargo-0.49.0/build.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.keywords` metadata" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/cli.rs:104:34 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/cli.rs:121:5 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/cli.rs:157:30 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/cli.rs:184:41 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/cli.rs:196:42 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/cli.rs:200:39 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/cli.rs:231:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/cli.rs:23:56 clippy::implicit_clone "implicitly cloning a `String` by calling `to_owned` on its dereferenced type" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/cli.rs:245:22 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/cli.rs:247:47 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/cli.rs:257:22 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/cli.rs:26:20 clippy::redundant_else "redundant else block" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/cli.rs:7:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/bench.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/bench.rs:76:59 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/build.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/check.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/clean.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/doc.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/fetch.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/fetch.rs:22:5 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/fix.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/generate_lockfile.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/git_checkout.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/help.rs:20:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/init.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/install.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/install.rs:97:16 clippy::option_if_let_else "use Option::map_or instead of an if let/else" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/locate_project.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/login.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/metadata.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/mod.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/new.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/new.rs:20:24 clippy::option_if_let_else "use Option::map_or instead of an if let/else" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/owner.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/owner.rs:38:43 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/owner.rs:39:43 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/owner.rs:40:43 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/owner.rs:43:30 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/owner.rs:46:30 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/package.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/pkgid.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/publish.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/publish.rs:40:47 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/read_manifest.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/run.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/rustc.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/rustdoc.rs:3:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/search.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/test.rs:127:54 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/test.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/tree.rs:149:49 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/tree.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/uninstall.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/update.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/vendor.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/vendor.rs:96:16 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/verify_project.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/version.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/yank.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/yank.rs:32:36 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/yank.rs:33:35 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/yank.rs:34:36 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/commands/yank.rs:35:36 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/main.rs:100:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/main.rs:118:41 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/main.rs:137:43 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/main.rs:148:19 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/main.rs:174:57 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/main.rs:18:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/main.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.categories` metadata" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/main.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.keywords` metadata" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `crossbeam-utils`: 0.6.6, 0.7.2" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `hex`: 0.3.2, 0.4.0" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `humantime`: 1.3.0, 2.0.0" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/main.rs:72:22 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/main.rs:94:13 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/main.rs:96:41 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/main.rs:98:60 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/build_config.rs:155:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/build_config.rs:170:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/build_config.rs:175:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/build_config.rs:180:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/build_config.rs:186:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/build_config.rs:197:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/build_config.rs:205:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/build_config.rs:51:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/build_config.rs:69:48 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/build_config.rs:96:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/build_context/mod.rs:44:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/build_context/mod.rs:83:20 clippy::doc_markdown "you should put `x86_64` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:108:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:121:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:149:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:411:9 clippy::needless_question_mark "question mark operator is useless here" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:420:69 clippy::doc_markdown "you should put `mode/target_kind` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:423:19 clippy::doc_markdown "you should put `CrateTypes` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:424:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:469:58 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:603:19 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:665:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:697:12 clippy::inconsistent_struct_constructor "inconsistent struct constructor" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:82:31 clippy::doc_markdown "you should put `FileType` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:83:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:84:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:96:31 clippy::doc_markdown "you should put `FileType` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/build_context/target_info.rs:98:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/build_plan.rs:4:9 clippy::doc_markdown "you should put `BuildPlan` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/build_plan.rs:5:66 clippy::doc_markdown "you should put `BuildPlan` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/build_plan.rs:66:40 clippy::ptr_arg "writing `&PathBuf` instead of `&Path` involves a new object where a slice will do" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/compilation.rs:150:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/compilation.rs:150:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/compilation.rs:169:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/compilation.rs:185:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/compilation.rs:193:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/compilation.rs:194:49 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/compilation.rs:198:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/compilation.rs:314:16 clippy::doc_markdown "you should put `rustc_tool` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/compilation.rs:91:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:118:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:123:18 clippy::case_sensitive_file_extension_comparisons "case-sensitive file extension comparison" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:147:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:157:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:157:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:33:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:49:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/compile_kind.rs:69:48 clippy::case_sensitive_file_extension_comparisons "case-sensitive file extension comparison" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/context/compilation_files.rs:204:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/context/compilation_files.rs:277:22 clippy::doc_markdown "you should put `OUT_DIR` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/context/compilation_files.rs:324:66 clippy::doc_markdown "you should put `FileType` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/context/compilation_files.rs:393:37 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/context/compilation_files.rs:426:71 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:125:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:125:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:125:5 clippy::too_many_lines "this function has too many lines (107/100)" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:270:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:286:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:308:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:308:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:340:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:340:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:349:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:349:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:354:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:358:21 clippy::doc_markdown "you should put `RunCustomBuild` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:361:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:374:43 clippy::doc_markdown "you should put `RunCustomBuild` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:378:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:383:41 clippy::doc_markdown "you should put `RunCustomBuild` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:384:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:391:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:397:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:523:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:538:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:542:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:83:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/context/mod.rs:92:25 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/crate_type.rs:16:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/crate_type.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/crate_type.rs:40:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/crate_type.rs:49:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/crate_type.rs:60:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:150:1 clippy::too_many_lines "this function has too many lines (230/100)" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:353:56 clippy::manual_strip "stripping a prefix manually" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:448:27 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:464:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:481:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:481:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:48:56 clippy::doc_markdown "you should put `RunCustomBuild` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:561:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:567:20 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:576:28 clippy::shadow_unrelated "`mut value` is being shadowed" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:606:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:688:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:756:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:762:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:762:5 clippy::unnecessary_wraps "this function's return value is unnecessary" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/custom_build.rs:823:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1021:51 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1656:16 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1664:5 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1787:5 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1795:5 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1882:17 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1894:17 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1906:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1917:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1923:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1956:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1962:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1963:22 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1964:22 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1965:22 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1966:22 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1980:17 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1980:24 clippy::manual_strip "stripping a prefix manually" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:1986:17 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:2016:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:61:5 clippy::doc_markdown "you should put `CompileMode` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:63:12 clippy::doc_markdown "you should put `CompileKind` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:67:7 clippy::doc_markdown "you should put `CARGO_DEFAULT_LIB_METADATA[^4` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:68:5 clippy::doc_markdown "you should put `package_id` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:71:19 clippy::doc_markdown "you should put `test/bench/for_host/edition` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:755:52 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:77:5 clippy::doc_markdown "you should put `is_std` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:816:5 clippy::too_many_lines "this function has too many lines (127/100)" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:863:64 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:875:33 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:876:32 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:896:30 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:897:30 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/fingerprint.rs:991:37 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:12:5 clippy::doc_markdown "you should put `src/librustc_jobserver/lib.rs` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:329:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:332:23 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:34:53 clippy::doc_markdown "you should put `NeedsToken` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:35:6 clippy::doc_markdown "you should put `ReleaseToken` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:37:6 clippy::doc_markdown "you should put `NeedsToken` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:40:5 clippy::doc_markdown "you should put `NeedsToken` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:40:56 clippy::doc_markdown "you should put `NeedsToken` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:43:6 clippy::doc_markdown "you should put `ReleaseToken` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:748:16 clippy::collapsible_else_if "this `else { if .. }` block can be collapsed" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:749:13 clippy::if_not_else "unnecessary boolean `not` operation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:786:26 clippy::unused_self "unused `self` argument" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:81:61 clippy::doc_markdown "you should put `DrainState` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:865:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:871:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:890:9 clippy::unused_self "unused `self` argument" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/job_queue.rs:93:24 clippy::doc_markdown "you should put `JobQueue` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/links.rs:8:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/mod.rs:1016:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/mod.rs:1094:19 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/mod.rs:1131:1 clippy::unnecessary_wraps "this function's return value is unnecessary" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/mod.rs:1268:34 clippy::case_sensitive_file_extension_comparisons "case-sensitive file extension comparison" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/mod.rs:1277:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/mod.rs:179:1 clippy::too_many_lines "this function has too many lines (162/100)" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/mod.rs:198:78 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/mod.rs:201:25 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/mod.rs:267:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/mod.rs:324:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/mod.rs:364:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/mod.rs:364:5 clippy::unnecessary_wraps "this function's return value is unnecessary" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/mod.rs:392:45 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/mod.rs:415:23 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/mod.rs:464:18 clippy::ptr_arg "writing `&PathBuf` instead of `&Path` involves a new object where a slice will do" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/mod.rs:488:61 clippy::ptr_arg "writing `&PathBuf` instead of `&Path` involves a new object where a slice will do" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/mod.rs:654:46 clippy::implicit_clone "implicitly cloning a `PathBuf` by calling `to_path_buf` on its dereferenced type" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/mod.rs:667:15 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/mod.rs:693:1 clippy::unnecessary_wraps "this function's return value is unnecessary" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/mod.rs:725:42 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/mod.rs:736:1 clippy::too_many_lines "this function has too many lines (141/100)" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/mod.rs:73:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/mod.rs:777:12 clippy::if_not_else "unnecessary boolean `not` operation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/mod.rs:873:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/output_depinfo.rs:41:13 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/rustdoc.rs:16:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/rustdoc.rs:57:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/rustdoc.rs:72:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/standard_lib.rs:134:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/standard_lib.rs:16:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/standard_lib.rs:30:28 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/standard_lib.rs:34:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/standard_lib.rs:34:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/timings.rs:16:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/timings.rs:192:64 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/timings.rs:212:58 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/timings.rs:234:13 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/timings.rs:355:13 clippy::cast_possible_truncation "casting `f64` to `u32` may truncate the value" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/timings.rs:355:13 clippy::cast_sign_loss "casting `f64` to `u32` may lose the sign of the value" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/timings.rs:397:38 clippy::cast_possible_truncation "casting `f64` to `u32` may truncate the value" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/timings.rs:397:38 clippy::cast_sign_loss "casting `f64` to `u32` may lose the sign of the value" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/timings.rs:484:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/timings.rs:605:38 clippy::doc_markdown "you should put `rmeta_time` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/timings.rs:605:50 clippy::doc_markdown "you should put `codegen_time` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/timings.rs:641:26 clippy::non_ascii_literal "literal non-ASCII character detected" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/unit.rs:100:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/unit.rs:151:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/unit.rs:161:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/unit.rs:35:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/unit_dependencies.rs:154:29 clippy::doc_markdown "you should put `state.unit_dependencies` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/unit_dependencies.rs:213:1 clippy::too_many_lines "this function has too many lines (110/100)" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/unit_dependencies.rs:52:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/unit_dependencies.rs:52:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/unit_graph.rs:65:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/compiler/unit_graph.rs:65:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/dependency.rs:157:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/dependency.rs:182:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/dependency.rs:203:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/dependency.rs:224:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/dependency.rs:23:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/dependency.rs:248:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/dependency.rs:270:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/dependency.rs:274:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/dependency.rs:278:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/dependency.rs:287:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/dependency.rs:291:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/dependency.rs:305:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/dependency.rs:311:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/dependency.rs:319:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/dependency.rs:337:75 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/dependency.rs:397:56 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/dependency.rs:403:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/dependency.rs:408:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/dependency.rs:415:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/dependency.rs:419:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/dependency.rs:424:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/dependency.rs:428:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/dependency.rs:433:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/dependency.rs:438:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/dependency.rs:443:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/dependency.rs:449:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/dependency.rs:450:9 clippy::if_not_else "unnecessary `!=` operation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/features.rs:119:17 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/features.rs:229:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/features.rs:274:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/features.rs:278:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/features.rs:306:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/features.rs:338:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/features.rs:362:25 clippy::option_option "consider using `Option` instead of `Option>` or a custom enum if you need to distinguish all 3 cases" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/features.rs:380:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/features.rs:401:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/features.rs:409:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/features.rs:412:45 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/features.rs:416:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/features.rs:419:45 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/features.rs:424:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/features.rs:431:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/features.rs:477:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/features.rs:509:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/features.rs:518:5 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/features.rs:542:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/features.rs:543:37 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/features.rs:547:60 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/features.rs:556:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/features.rs:563:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:116:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:118:58 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:130:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:143:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:159:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:162:34 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:169:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:17:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:189:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:215:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:222:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:22:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:320:46 clippy::implicit_clone "implicitly cloning a `PathBuf` by calling `to_path_buf` on its dereferenced type" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:360:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:407:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:410:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:413:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:416:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:419:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:422:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:425:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:431:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:438:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:444:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:447:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:450:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:453:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:456:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:459:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:462:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:466:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:470:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:477:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:481:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:488:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:512:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:516:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:520:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:524:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:528:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:538:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:557:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:561:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:565:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:569:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:577:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:581:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:588:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:617:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:632:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:648:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:659:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:66:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:670:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:693:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:708:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:723:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:726:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:729:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:735:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:738:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:741:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:744:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:747:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:751:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:754:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:757:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:760:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:763:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:767:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:776:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:780:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:787:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:798:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:800:56 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:805:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:809:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:818:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:823:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:828:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:831:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:834:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:839:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:85:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:888:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/manifest.rs:936:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package.rs:1075:28 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package.rs:160:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package.rs:170:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package.rs:174:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package.rs:182:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package.rs:186:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package.rs:190:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package.rs:194:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package.rs:194:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package.rs:198:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package.rs:202:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package.rs:206:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package.rs:210:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package.rs:217:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package.rs:221:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package.rs:222:35 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package.rs:226:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package.rs:227:35 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package.rs:230:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package.rs:239:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package.rs:249:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package.rs:287:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package.rs:385:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package.rs:421:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package.rs:425:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package.rs:452:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package.rs:453:60 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package.rs:459:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package.rs:473:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package.rs:587:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package.rs:588:9 clippy::needless_question_mark "question mark operator is useless here" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package.rs:682:46 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package.rs:682:46 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package.rs:682:63 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package.rs:682:63 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package.rs:731:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package.rs:790:13 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package.rs:988:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package_id.rs:115:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package_id.rs:124:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package_id.rs:124:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package_id.rs:139:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package_id.rs:142:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package_id.rs:145:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package_id.rs:149:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package_id.rs:157:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package_id.rs:161:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package_id.rs:169:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package_id.rs:174:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package_id_spec.rs:101:39 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package_id_spec.rs:143:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package_id_spec.rs:147:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package_id_spec.rs:151:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package_id_spec.rs:160:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package_id_spec.rs:179:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package_id_spec.rs:212:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package_id_spec.rs:231:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package_id_spec.rs:51:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package_id_spec.rs:51:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package_id_spec.rs:77:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/package_id_spec.rs:88:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/profiles.rs:1004:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/profiles.rs:1014:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/profiles.rs:1018:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/profiles.rs:1028:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/profiles.rs:106:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/profiles.rs:143:5 clippy::unnecessary_wraps "this function's return value is unnecessary" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/profiles.rs:204:54 clippy::implicit_clone "implicitly cloning a `InternedString` by calling `to_owned` on its dereferenced type" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/profiles.rs:286:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/profiles.rs:286:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/profiles.rs:294:40 clippy::if_not_else "unnecessary boolean `not` operation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/profiles.rs:30:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/profiles.rs:342:25 clippy::shadow_unrelated "`maker` is being shadowed" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/profiles.rs:370:41 clippy::unused_self "unused `self` argument" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/profiles.rs:370:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/profiles.rs:372:9 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/profiles.rs:382:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/profiles.rs:382:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/profiles.rs:383:28 clippy::if_not_else "unnecessary boolean `not` operation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/profiles.rs:397:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/profiles.rs:405:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/profiles.rs:607:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/profiles.rs:909:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/profiles.rs:923:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/profiles.rs:934:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/profiles.rs:987:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/registry.rs:111:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/registry.rs:127:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/registry.rs:168:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/registry.rs:19:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/registry.rs:240:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/registry.rs:26:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/registry.rs:344:49 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/registry.rs:369:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/registry.rs:424:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/registry.rs:49:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/registry.rs:520:17 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/registry.rs:763:53 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/registry.rs:765:53 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/registry.rs:807:14 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/registry.rs:814:53 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/conflict_cache.rs:197:29 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/conflict_cache.rs:41:38 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/context.rs:274:53 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/context.rs:42:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/context.rs:74:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/encode.rs:156:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/encode.rs:156:5 clippy::too_many_lines "this function has too many lines (164/100)" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/encode.rs:339:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/encode.rs:438:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/encode.rs:449:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/encode.rs:529:34 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/encode.rs:602:59 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/encode.rs:623:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/encode.rs:652:27 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/encode.rs:674:51 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/errors.rs:103:22 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/errors.rs:104:22 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/errors.rs:206:9 clippy::if_not_else "unnecessary boolean `not` operation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/errors.rs:257:45 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/errors.rs:27:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/errors.rs:305:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/errors.rs:70:1 clippy::too_many_lines "this function has too many lines (207/100)" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/features.rs:104:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/features.rs:111:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/features.rs:162:56 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/features.rs:179:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/features.rs:186:23 clippy::doc_markdown "you should put `RequestedFeatures` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/features.rs:187:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/features.rs:199:23 clippy::doc_markdown "you should put `RequestedFeatures` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/features.rs:200:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/features.rs:221:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/features.rs:231:21 clippy::doc_markdown "you should put `pkg_id/is_build` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/features.rs:233:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/features.rs:247:58 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/features.rs:278:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/features.rs:394:27 clippy::doc_markdown "you should put `FeatureValue` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/features.rs:460:19 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/features.rs:480:24 clippy::doc_markdown "you should put `FeatureValues` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/features.rs:496:24 clippy::doc_markdown "you should put `FeatureValues` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/features.rs:58:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/features.rs:67:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/mod.rs:1017:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/mod.rs:1045:57 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/mod.rs:122:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/mod.rs:142:44 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/mod.rs:180:1 clippy::too_many_lines "this function has too many lines (225/100)" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/mod.rs:311:17 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/mod.rs:421:52 clippy::filter_map_next "called `filter_map(..).next()` on an `Iterator`. This is more succinctly expressed by calling `.find_map(..)` instead" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/mod.rs:457:69 clippy::filter_map_next "called `filter_map(..).next()` on an `Iterator`. This is more succinctly expressed by calling `.find_map(..)` instead" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/mod.rs:470:37 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/mod.rs:607:11 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/mod.rs:631:21 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/mod.rs:942:15 clippy::if_not_else "unnecessary boolean `not` operation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/mod.rs:988:20 clippy::redundant_else "redundant else block" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/resolve.rs:120:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/resolve.rs:132:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/resolve.rs:199:24 clippy::redundant_else "redundant else block" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/resolve.rs:235:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/resolve.rs:239:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/resolve.rs:255:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/resolve.rs:259:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/resolve.rs:263:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/resolve.rs:269:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/resolve.rs:273:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/resolve.rs:274:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/resolve.rs:280:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/resolve.rs:284:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/resolve.rs:288:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/resolve.rs:292:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/resolve.rs:296:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/resolve.rs:300:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/resolve.rs:315:13 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/resolve.rs:354:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/resolve.rs:362:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/resolve.rs:60:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/resolve.rs:76:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/types.rs:111:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/types.rs:121:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/types.rs:141:19 clippy::doc_markdown "you should put `ResolveOpts` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/types.rs:142:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/types.rs:149:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/types.rs:181:9 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/types.rs:187:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/resolver/types.rs:261:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/shell.rs:113:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/shell.rs:130:9 clippy::single_match_else "you seem to be trying to use `match` for an equality check. Consider using `if`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/shell.rs:148:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/shell.rs:153:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/shell.rs:163:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/shell.rs:18:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/shell.rs:198:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/shell.rs:206:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/shell.rs:214:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/shell.rs:228:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/shell.rs:239:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/shell.rs:250:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/shell.rs:259:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/shell.rs:267:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/shell.rs:26:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/shell.rs:277:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/shell.rs:282:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/shell.rs:314:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/shell.rs:322:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/shell.rs:330:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/shell.rs:345:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/shell.rs:459:9 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/shell.rs:98:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/mod.rs:103:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/mod.rs:247:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/mod.rs:261:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/mod.rs:268:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/mod.rs:273:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/mod.rs:291:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/mod.rs:302:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/mod.rs:307:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/mod.rs:31:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/mod.rs:37:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/mod.rs:39:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/mod.rs:47:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/mod.rs:50:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/mod.rs:52:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/mod.rs:63:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/mod.rs:74:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/mod.rs:83:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:107:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:107:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:128:50 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:147:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:156:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:162:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:166:19 clippy::doc_markdown "you should put `SourceId` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:167:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:171:19 clippy::doc_markdown "you should put `SourceId` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:172:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:178:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:187:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:187:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:18:74 clippy::default_trait_access "calling `std::sync::Mutex::default()` is more clear than this expression" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:195:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:207:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:213:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:217:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:225:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:228:16 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:236:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:241:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:252:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:257:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:262:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:305:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:310:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:318:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:326:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:338:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:355:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:393:61 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:394:42 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:395:42 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:397:71 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:397:71 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:398:47 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:398:47 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:399:47 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:399:47 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:401:63 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:401:63 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:401:63 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:402:43 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:402:43 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:402:43 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:403:43 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:403:43 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:403:43 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:406:21 clippy::enum_glob_use "usage of wildcard import for enum variants" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:412:41 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:413:36 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:414:36 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:420:47 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:420:47 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:512:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:513:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:517:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:518:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:525:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:526:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:530:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:531:17 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:535:33 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:536:37 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:537:42 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:538:38 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:548:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/source/source_id.rs:597:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/summary.rs:103:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/summary.rs:123:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/summary.rs:150:1 clippy::too_many_lines "this function has too many lines (141/100)" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/summary.rs:158:9 clippy::enum_glob_use "usage of wildcard import for enum variants" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/summary.rs:181:21 clippy::if_not_else "unnecessary boolean `not` operation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/summary.rs:192:28 clippy::redundant_else "redundant else block" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/summary.rs:258:32 clippy::redundant_else "redundant else block" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/summary.rs:281:28 clippy::redundant_else "redundant else block" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/summary.rs:303:28 clippy::redundant_else "redundant else block" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/summary.rs:321:51 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/summary.rs:344:5 clippy::doc_markdown "you should put `FeatureValue` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/summary.rs:350:85 clippy::doc_markdown "you should put `FeatureValue` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/summary.rs:36:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/summary.rs:378:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/summary.rs:386:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/summary.rs:387:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/summary.rs:407:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/summary.rs:69:34 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/summary.rs:75:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/summary.rs:78:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/summary.rs:81:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/summary.rs:84:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/summary.rs:87:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/summary.rs:90:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/summary.rs:93:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/summary.rs:96:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/summary.rs:99:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/workspace.rs:1056:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/workspace.rs:113:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/workspace.rs:1157:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/workspace.rs:128:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/workspace.rs:150:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/workspace.rs:159:16 clippy::redundant_else "redundant else block" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/workspace.rs:197:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/workspace.rs:225:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/workspace.rs:225:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/workspace.rs:255:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/workspace.rs:267:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/workspace.rs:317:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/workspace.rs:329:37 clippy::doc_markdown "you should put `VirtualManifest` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/workspace.rs:410:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/workspace.rs:440:9 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/workspace.rs:511:32 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/workspace.rs:561:25 clippy::non_ascii_literal "literal non-ASCII character detected" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/workspace.rs:613:13 clippy::filter_map "called `filter_map(..).map(..)` on an `Iterator`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/workspace.rs:615:22 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/workspace.rs:762:27 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/workspace.rs:784:17 clippy::if_not_else "unnecessary boolean `not` operation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/workspace.rs:849:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/workspace.rs:849:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/workspace.rs:893:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/workspace.rs:906:24 clippy::redundant_else "redundant else block" +target/lintcheck/sources/cargo-0.49.0/src/cargo/core/workspace.rs:932:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/lib.rs:177:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/lib.rs:177:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/lib.rs:180:36 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/lib.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.categories` metadata" +target/lintcheck/sources/cargo-0.49.0/src/cargo/lib.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.keywords` metadata" +target/lintcheck/sources/cargo-0.49.0/src/cargo/lib.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `crossbeam-utils`: 0.6.6, 0.7.2" +target/lintcheck/sources/cargo-0.49.0/src/cargo/lib.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `hex`: 0.3.2, 0.4.0" +target/lintcheck/sources/cargo-0.49.0/src/cargo/lib.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `humantime`: 1.3.0, 2.0.0" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_clean.rs:205:23 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_clean.rs:27:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_clean.rs:27:1 clippy::too_many_lines "this function has too many lines (120/100)" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_compile.rs:1078:14 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_compile.rs:109:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_compile.rs:119:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_compile.rs:1227:17 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_compile.rs:127:35 clippy::from_iter_instead_of_collect "usage of `FromIterator::from_iter`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_compile.rs:173:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_compile.rs:205:36 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_compile.rs:242:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_compile.rs:249:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_compile.rs:258:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_compile.rs:267:16 clippy::needless_question_mark "question mark operator is useless here" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_compile.rs:275:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_compile.rs:275:1 clippy::too_many_lines "this function has too many lines (219/100)" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_compile.rs:468:9 clippy::default_trait_access "calling `std::collections::HashMap::default()` is more clear than this expression" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_compile.rs:548:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_compile.rs:556:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_compile.rs:574:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_compile.rs:583:21 clippy::doc_markdown "you should put `CompileFilter` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_compile.rs:584:5 clippy::fn_params_excessive_bools "more than 3 bools in function parameters" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_compile.rs:584:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_compile.rs:592:9 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_compile.rs:593:9 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_compile.rs:607:13 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_compile.rs:612:21 clippy::doc_markdown "you should put `CompileFilter` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_compile.rs:613:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_compile.rs:618:9 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_compile.rs:641:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_compile.rs:652:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_compile.rs:655:50 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_compile.rs:673:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_compile.rs:692:49 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_compile.rs:703:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_compile.rs:729:1 clippy::too_many_lines "this function has too many lines (205/100)" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_compile.rs:82:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_compile.rs:874:69 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_doc.rs:20:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_fetch.rs:15:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_fetch.rs:27:46 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:160:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:175:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:22:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:37:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:37:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_generate_lockfile.rs:37:1 clippy::too_many_lines "this function has too many lines (171/100)" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_install.rs:13:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_install.rs:148:1 clippy::fn_params_excessive_bools "more than 3 bools in function parameters" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_install.rs:148:1 clippy::too_many_lines "this function has too many lines (316/100)" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_install.rs:178:24 clippy::collapsible_else_if "this `else { if .. }` block can be collapsed" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_install.rs:202:17 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_install.rs:236:16 clippy::collapsible_else_if "this `else { if .. }` block can be collapsed" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_install.rs:312:64 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_install.rs:32:13 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_install.rs:339:12 clippy::collapsible_else_if "this `else { if .. }` block can be collapsed" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_install.rs:37:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_install.rs:454:22 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_install.rs:483:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_install.rs:683:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_install.rs:708:5 clippy::manual_flatten "unnecessary `if let` since only the `Some` variant of the iterator element is used" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_new.rs:101:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_new.rs:245:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_new.rs:251:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_new.rs:367:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_new.rs:405:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_new.rs:489:5 clippy::doc_markdown "you should put `IgnoreList` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_new.rs:525:47 clippy::doc_markdown "you should put `IgnoreList` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_new.rs:525:9 clippy::doc_markdown "you should put `format_existing` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_new.rs:572:34 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_new.rs:623:1 clippy::too_many_lines "this function has too many lines (130/100)" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_new.rs:781:5 clippy::filter_map_next "called `filter_map(..).next()` on an `Iterator`. This is more succinctly expressed by calling `.find_map(..)` instead" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_new.rs:800:16 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_output_metadata.rs:163:36 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_output_metadata.rs:27:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_output_metadata.rs:45:45 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_package.rs:144:1 clippy::too_many_lines "this function has too many lines (112/100)" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_package.rs:207:13 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_package.rs:25:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_package.rs:307:54 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_package.rs:394:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_package.rs:425:61 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_package.rs:459:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_package.rs:66:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_package.rs:69:9 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_package.rs:93:20 clippy::if_not_else "unnecessary boolean `not` operation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_pkgid.rs:5:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_read_manifest.rs:14:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_read_manifest.rs:171:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_read_manifest.rs:37:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_read_manifest.rs:37:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_read_manifest.rs:57:49 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_read_manifest.rs:69:37 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_run.rs:25:24 clippy::if_not_else "unnecessary boolean `not` operation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_run.rs:35:9 clippy::if_not_else "unnecessary boolean `not` operation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_run.rs:37:16 clippy::redundant_else "redundant else block" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_run.rs:53:9 clippy::if_not_else "unnecessary boolean `not` operation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_run.rs:65:16 clippy::redundant_else "redundant else block" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_run.rs:82:23 clippy::implicit_clone "implicitly cloning a `PathBuf` by calling `to_path_buf` on its dereferenced type" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_run.rs:9:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_test.rs:16:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_test.rs:43:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_test.rs:84:17 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_uninstall.rs:14:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/cargo_uninstall.rs:7:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:147:9 clippy::doc_markdown "you should put `PackageId` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:233:21 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:244:22 clippy::doc_markdown "you should put `PackageId` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:244:63 clippy::doc_markdown "you should put `PackageId` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:253:17 clippy::if_not_else "unnecessary boolean `not` operation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:370:5 clippy::unnecessary_wraps "this function's return value is unnecessary" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:505:8 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:525:10 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:542:27 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:542:5 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:561:20 clippy::redundant_else "redundant else block" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:613:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:645:41 clippy::doc_markdown "you should put `BTreeSet` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/common_for_install_and_uninstall.rs:92:19 clippy::doc_markdown "you should put `InstallTracker` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/fix.rs:200:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/fix.rs:200:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/fix.rs:424:20 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/fix.rs:455:13 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/fix.rs:506:17 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/fix.rs:608:9 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/fix.rs:612:42 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/fix.rs:619:48 clippy::manual_strip "stripping a prefix manually" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/fix.rs:66:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/fix.rs:66:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/fix.rs:708:18 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/fix.rs:77:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/lockfile.rs:154:13 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/lockfile.rs:217:9 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/lockfile.rs:30:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/lockfile.rs:35:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/lockfile.rs:35:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/lockfile.rs:87:1 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/lockfile.rs:8:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/lockfile.rs:8:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/registry.rs:150:21 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/registry.rs:188:1 clippy::too_many_lines "this function has too many lines (130/100)" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/registry.rs:212:32 clippy::if_not_else "unnecessary `!=` operation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/registry.rs:222:53 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/registry.rs:224:44 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/registry.rs:31:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/registry.rs:346:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/registry.rs:346:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/registry.rs:351:26 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/registry.rs:385:12 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/registry.rs:386:15 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/registry.rs:38:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/registry.rs:477:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/registry.rs:483:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/registry.rs:503:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/registry.rs:505:38 clippy::default_trait_access "calling `util::config::CargoHttpConfig::default()` is more clear than this expression" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/registry.rs:510:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/registry.rs:529:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/registry.rs:53:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/registry.rs:53:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/registry.rs:573:22 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/registry.rs:608:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/registry.rs:621:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/registry.rs:671:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/registry.rs:671:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/registry.rs:674:10 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/registry.rs:678:17 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/registry.rs:730:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/registry.rs:731:16 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/registry.rs:785:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/registry.rs:794:16 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/registry.rs:828:14 clippy::doc_markdown "you should put `SourceId` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/registry.rs:848:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/resolve.rs:199:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/resolve.rs:199:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/resolve.rs:199:1 clippy::too_many_lines "this function has too many lines (137/100)" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/resolve.rs:241:28 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/resolve.rs:28:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/resolve.rs:384:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/resolve.rs:417:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/resolve.rs:589:9 clippy::shadow_unrelated "`keep` is being shadowed" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/resolve.rs:58:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/resolve.rs:58:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/resolve.rs:602:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/resolve.rs:75:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/resolve.rs:75:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/tree/graph.rs:129:26 clippy::doc_markdown "you should put `PackageIds` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/tree/graph.rs:152:15 clippy::match_on_vec_items "indexing into a vector may panic" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/tree/graph.rs:173:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/tree/graph.rs:234:46 clippy::filter_map "called `filter(..).flat_map(..)` on an `Iterator`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/tree/graph.rs:328:44 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/tree/graph.rs:330:50 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/tree/graph.rs:563:35 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/tree/mod.rs:112:11 clippy::non_ascii_literal "literal non-ASCII character detected" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/tree/mod.rs:113:10 clippy::non_ascii_literal "literal non-ASCII character detected" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/tree/mod.rs:114:10 clippy::non_ascii_literal "literal non-ASCII character detected" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/tree/mod.rs:115:12 clippy::non_ascii_literal "literal non-ASCII character detected" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/tree/mod.rs:126:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/tree/mod.rs:21:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/tree/mod.rs:21:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/tree/mod.rs:360:30 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/tree/mod.rs:58:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/vendor.rs:14:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/vendor.rs:215:9 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/vendor.rs:21:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/vendor.rs:21:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/vendor.rs:314:34 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/vendor.rs:320:29 clippy::case_sensitive_file_extension_comparisons "case-sensitive file extension comparison" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/vendor.rs:320:60 clippy::case_sensitive_file_extension_comparisons "case-sensitive file extension comparison" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/vendor.rs:324:13 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +target/lintcheck/sources/cargo-0.49.0/src/cargo/ops/vendor.rs:70:1 clippy::too_many_lines "this function has too many lines (175/100)" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/config.rs:102:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/config.rs:111:28 clippy::needless_question_mark "question mark operator is useless here" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/config.rs:133:48 clippy::needless_question_mark "question mark operator is useless here" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/config.rs:135:67 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/config.rs:206:36 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/config.rs:282:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/config.rs:70:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/config.rs:81:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/config.rs:97:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/directory.rs:14:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/directory.rs:90:56 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/git/source.rs:14:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/git/source.rs:25:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/git/source.rs:49:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/git/source.rs:53:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/git/source.rs:53:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/git/source.rs:69:20 clippy::comparison_to_empty "comparison to empty slice" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/git/utils.rs:1025:19 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/git/utils.rs:1157:36 clippy::case_sensitive_file_extension_comparisons "case-sensitive file extension comparison" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/git/utils.rs:1158:9 clippy::manual_strip "stripping a suffix manually" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/git/utils.rs:176:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/git/utils.rs:180:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/git/utils.rs:184:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/git/utils.rs:188:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/git/utils.rs:242:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/git/utils.rs:253:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/git/utils.rs:262:13 clippy::if_not_else "unnecessary boolean `not` operation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/git/utils.rs:289:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/git/utils.rs:294:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/git/utils.rs:298:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/git/utils.rs:308:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/git/utils.rs:472:9 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/git/utils.rs:489:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/git/utils.rs:503:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/git/utils.rs:528:28 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/git/utils.rs:537:21 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/git/utils.rs:588:1 clippy::too_many_lines "this function has too many lines (135/100)" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/git/utils.rs:692:9 clippy::vec_init_then_push "calls to `push` immediately after creation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/git/utils.rs:758:9 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/git/utils.rs:858:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/path.rs:129:44 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/path.rs:143:44 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/path.rs:15:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/path.rs:282:50 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/path.rs:313:21 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/path.rs:314:21 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/path.rs:319:21 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/path.rs:339:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/path.rs:339:9 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/path.rs:380:9 clippy::unused_self "unused `self` argument" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/path.rs:419:50 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/path.rs:429:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/path.rs:460:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/path.rs:473:43 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/path.rs:482:43 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/path.rs:63:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/path.rs:77:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/path.rs:98:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/registry/index.rs:117:23 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/registry/index.rs:121:70 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/registry/index.rs:167:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/registry/index.rs:215:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/registry/index.rs:324:23 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/registry/index.rs:468:40 clippy::doc_markdown "you should put `SourceId` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/registry/index.rs:590:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/registry/index.rs:648:17 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/registry/index.rs:736:1 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/registry/index.rs:95:37 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/registry/local.rs:12:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/registry/mod.rs:192:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/registry/mod.rs:203:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/registry/mod.rs:229:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/registry/mod.rs:372:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/registry/mod.rs:373:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/registry/mod.rs:375:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/registry/mod.rs:381:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/registry/mod.rs:382:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/registry/mod.rs:383:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/registry/mod.rs:384:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/registry/mod.rs:452:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/registry/mod.rs:582:20 clippy::redundant_else "redundant else block" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/registry/mod.rs:621:9 clippy::if_not_else "unnecessary `!=` operation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/registry/remote.rs:139:17 clippy::unused_self "unused `self` argument" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/registry/remote.rs:32:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/registry/remote.rs:72:13 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/replaced.rs:12:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/sources/replaced.rs:5:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/canonical_url.rs:19:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/canonical_url.rs:19:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/canonical_url.rs:50:41 clippy::case_sensitive_file_extension_comparisons "case-sensitive file extension comparison" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/canonical_url.rs:65:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/command_prelude.rs:218:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/command_prelude.rs:222:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/command_prelude.rs:234:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/command_prelude.rs:249:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/command_prelude.rs:264:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/command_prelude.rs:279:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/command_prelude.rs:298:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/command_prelude.rs:320:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/command_prelude.rs:328:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/command_prelude.rs:352:13 clippy::if_not_else "unnecessary boolean `not` operation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/command_prelude.rs:363:13 clippy::if_not_else "unnecessary boolean `not` operation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/command_prelude.rs:378:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/command_prelude.rs:387:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/command_prelude.rs:387:5 clippy::too_many_lines "this function has too many lines (104/100)" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/command_prelude.rs:39:20 clippy::doc_markdown "you should put `arg_package_spec` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/command_prelude.rs:504:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/command_prelude.rs:516:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/command_prelude.rs:530:40 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/command_prelude.rs:531:43 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/command_prelude.rs:536:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/command_prelude.rs:556:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/command_prelude.rs:575:49 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/command_prelude.rs:580:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/command_prelude.rs:631:18 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/command_prelude.rs:638:18 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/command_prelude.rs:647:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/command_prelude.rs:651:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/command_prelude.rs:662:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/command_prelude.rs:665:51 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/de.rs:420:16 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/de.rs:46:25 clippy::doc_markdown "you should put `CV::List` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/de.rs:47:24 clippy::doc_markdown "you should put `ConfigSeqAccess` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/de.rs:527:53 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/de.rs:530:53 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/de.rs:532:68 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/key.rs:11:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/key.rs:69:9 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:100:71 clippy::doc_markdown "you should put `OptValue` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:100:71 clippy::doc_markdown "you should put `OptValue` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:100:71 clippy::doc_markdown "you should put `OptValue` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:1049:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:1064:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:1090:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:1166:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:1179:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:1181:33 clippy::needless_question_mark "question mark operator is useless here" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:1184:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:1186:33 clippy::needless_question_mark "question mark operator is useless here" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:1189:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:1191:33 clippy::needless_question_mark "question mark operator is useless here" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:1203:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:1211:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:1216:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:1225:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:1229:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:124:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:1254:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:1279:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:1281:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:1323:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:1339:39 clippy::unused_self "unused `self` argument" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:1344:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:1420:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:1553:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:1560:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:1567:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:1574:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:1581:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:1588:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:1598:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:1619:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:1623:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:1623:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:1623:64 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:1649:9 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:1699:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:1730:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:1757:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:1770:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:1778:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:1804:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:1896:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:1901:5 clippy::doc_markdown "you should put `StringList` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:214:13 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:259:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:298:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:311:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:318:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:353:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:401:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:411:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:419:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:431:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:449:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:454:16 clippy::option_if_let_else "use Option::map_or instead of an if let/else" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:547:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:556:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:582:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:595:20 clippy::doc_markdown "you should put `StringList` between ticks in the documentation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:689:20 clippy::unused_self "unused `self` argument" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:699:5 clippy::fn_params_excessive_bools "more than 3 bools in function parameters" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:699:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:719:58 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/mod.rs:816:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/path.rs:10:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/path.rs:14:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/path.rs:48:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/target.rs:12:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/target.rs:24:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/value.rs:29:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/value.rs:70:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/value.rs:80:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/config/value.rs:81:9 clippy::match_like_matches_macro "match expression looks like `matches!` macro" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/cpu.rs:11:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/cpu.rs:22:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/cpu.rs:82:25 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/cpu.rs:82:9 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/dependency_queue.rs:109:27 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/dependency_queue.rs:125:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/dependency_queue.rs:151:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/dependency_queue.rs:156:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/dependency_queue.rs:168:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/dependency_queue.rs:46:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/dependency_queue.rs:91:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/diagnostic_server.rs:218:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/diagnostic_server.rs:230:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/diagnostic_server.rs:242:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/diagnostic_server.rs:58:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/diagnostic_server.rs:96:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/diagnostic_server.rs:96:5 clippy::too_many_lines "this function has too many lines (110/100)" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/diagnostic_server.rs:99:21 clippy::shadow_unrelated "`msg` is being shadowed" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/errors.rs:101:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/errors.rs:143:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/errors.rs:150:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/errors.rs:15:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/errors.rs:237:5 clippy::pub_enum_variant_names "variant name ends with the enum's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/errors.rs:245:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/errors.rs:321:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/errors.rs:328:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/errors.rs:356:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/errors.rs:391:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/errors.rs:392:13 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/errors.rs:465:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/errors.rs:473:5 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/errors.rs:66:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/flock.rs:115:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/flock.rs:11:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/flock.rs:134:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/flock.rs:142:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/flock.rs:150:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/flock.rs:156:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/flock.rs:170:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/flock.rs:192:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/flock.rs:29:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/flock.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/flock.rs:321:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/flock.rs:335:23 clippy::cast_possible_truncation "casting `i64` to `u32` may truncate the value" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/flock.rs:335:23 clippy::cast_sign_loss "casting `i64` to `u32` may lose the sign of the value" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/flock.rs:335:44 clippy::cast_possible_truncation "casting `i64` to `u32` may truncate the value" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/flock.rs:379:35 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/flock.rs:37:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/flock.rs:43:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/flock.rs:43:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/flock.rs:52:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/flock.rs:52:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/flock.rs:96:17 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/graph.rs:10:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/graph.rs:41:51 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/graph.rs:45:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/hasher.rs:12:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/hasher.rs:9:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/hex.rs:10:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/hex.rs:11:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/hex.rs:12:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/hex.rs:13:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/hex.rs:14:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/hex.rs:15:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/hex.rs:25:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/hex.rs:6:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/hex.rs:6:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/hex.rs:8:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/hex.rs:9:9 clippy::cast_possible_truncation "casting `u64` to `u8` may truncate the value" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/important_paths.rs:23:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/important_paths.rs:6:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/interning.rs:66:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/interning.rs:66:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/interning.rs:77:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/into_url.rs:10:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/into_url_with_base.rs:9:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/job.rs:20:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/lev_distance.rs:3:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/lockserver.rs:111:32 clippy::redundant_else "redundant else block" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/lockserver.rs:158:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/lockserver.rs:46:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/lockserver.rs:58:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/lockserver.rs:62:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/mod.rs:68:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/mod.rs:79:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/network.rs:12:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/network.rs:19:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/network.rs:84:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/paths.rs:109:12 clippy::redundant_else "redundant else block" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/paths.rs:114:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/paths.rs:121:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/paths.rs:125:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/paths.rs:130:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/paths.rs:14:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/paths.rs:14:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/paths.rs:151:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/paths.rs:167:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/paths.rs:173:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/paths.rs:178:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/paths.rs:185:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/paths.rs:199:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/paths.rs:215:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/paths.rs:228:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/paths.rs:251:9 clippy::option_if_let_else "use Option::map_or instead of an if let/else" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/paths.rs:267:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/paths.rs:276:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/paths.rs:29:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/paths.rs:303:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/paths.rs:312:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/paths.rs:346:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/paths.rs:415:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/paths.rs:445:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/paths.rs:459:45 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/paths.rs:469:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/paths.rs:469:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/paths.rs:514:5 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/paths.rs:54:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/paths.rs:61:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/paths.rs:63:19 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/paths.rs:88:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/paths.rs:93:31 clippy::comparison_to_empty "comparison to empty slice" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/process_builder.rs:106:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/process_builder.rs:111:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/process_builder.rs:122:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/process_builder.rs:132:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/process_builder.rs:152:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/process_builder.rs:185:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/process_builder.rs:190:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/process_builder.rs:218:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/process_builder.rs:218:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/process_builder.rs:278:22 clippy::inconsistent_struct_constructor "inconsistent struct constructor" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/process_builder.rs:307:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/process_builder.rs:343:39 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/progress.rs:122:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/progress.rs:136:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/progress.rs:15:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/progress.rs:249:19 clippy::cast_precision_loss "casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/progress.rs:249:34 clippy::cast_precision_loss "casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/progress.rs:250:19 clippy::if_not_else "unnecessary boolean `not` operation" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/progress.rs:263:22 clippy::cast_precision_loss "casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/progress.rs:264:22 clippy::cast_possible_truncation "casting `f64` to `usize` may truncate the value" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/progress.rs:264:22 clippy::cast_sign_loss "casting `f64` to `usize` may lose the sign of the value" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/progress.rs:269:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/progress.rs:272:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/progress.rs:274:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/progress.rs:280:13 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/progress.rs:282:9 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/progress.rs:89:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/progress.rs:97:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/queue.rs:25:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/queue.rs:36:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/queue.rs:42:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/queue.rs:52:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/queue.rs:69:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/read2.rs:11:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/read2.rs:31:17 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/restricted_names.rs:13:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/restricted_names.rs:26:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/restricted_names.rs:35:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/restricted_names.rs:45:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/restricted_names.rs:87:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/restricted_names.rs:87:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/restricted_names.rs:89:21 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/restricted_names.rs:8:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/rustc.rs:103:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/rustc.rs:103:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/rustc.rs:114:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/rustc.rs:115:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/rustc.rs:162:17 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/rustc.rs:39:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/sha256.rs:10:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/sha256.rs:16:9 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/sha256.rs:20:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/sha256.rs:31:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/sha256.rs:40:24 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/to_semver.rs:5:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/toml/mod.rs:1005:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/toml/mod.rs:1005:5 clippy::too_many_lines "this function has too many lines (282/100)" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/toml/mod.rs:1094:36 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/toml/mod.rs:1121:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/toml/mod.rs:1197:32 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/toml/mod.rs:124:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/toml/mod.rs:1504:9 clippy::unused_self "unused `self` argument" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/toml/mod.rs:1526:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/toml/mod.rs:1582:19 clippy::default_trait_access "calling `util::toml::DetailedTomlDependency::default()` is more clear than this expression" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/toml/mod.rs:1598:5 clippy::too_many_lines "this function has too many lines (153/100)" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/toml/mod.rs:1687:33 clippy::unnecessary_lazy_evaluations "unnecessary closure used to substitute value for `Option::None`" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/toml/mod.rs:178:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/toml/mod.rs:248:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/toml/mod.rs:274:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/toml/mod.rs:277:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/toml/mod.rs:281:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/toml/mod.rs:285:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/toml/mod.rs:294:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/toml/mod.rs:31:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/toml/mod.rs:381:35 clippy::cast_possible_truncation "casting `i64` to `u32` may truncate the value" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/toml/mod.rs:381:35 clippy::cast_sign_loss "casting `i64` to `u32` may lose the sign of the value" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/toml/mod.rs:388:35 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/toml/mod.rs:398:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/toml/mod.rs:450:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/toml/mod.rs:536:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/toml/mod.rs:783:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/toml/mod.rs:824:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/toml/mod.rs:834:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/toml/mod.rs:83:42 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/toml/mod.rs:852:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/toml/mod.rs:852:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/toml/mod.rs:852:5 clippy::too_many_lines "this function has too many lines (138/100)" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/toml/mod.rs:962:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/toml/mod.rs:979:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/toml/mod.rs:98:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/toml/mod.rs:999:23 clippy::default_trait_access "calling `util::toml::DetailedTomlDependency::default()` is more clear than this expression" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/toml/targets.rs:112:27 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/toml/targets.rs:325:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/toml/targets.rs:586:21 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/toml/targets.rs:593:42 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/toml/targets.rs:605:19 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/toml/targets.rs:612:42 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/toml/targets.rs:756:36 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/vcs.rs:10:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/vcs.rs:33:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/vcs.rs:37:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/vcs.rs:43:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/vcs.rs:47:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/vcs.rs:59:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/vcs.rs:66:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/workspace.rs:52:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/workspace.rs:56:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/workspace.rs:60:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cargo-0.49.0/src/cargo/util/workspace.rs:64:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/iron-0.6.1/src/error.rs:24:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/iron-0.6.1/src/iron.rs:105:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/iron-0.6.1/src/iron.rs:119:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/iron-0.6.1/src/iron.rs:133:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/iron-0.6.1/src/iron.rs:143:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/iron-0.6.1/src/iron.rs:149:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/iron-0.6.1/src/iron.rs:167:49 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/iron-0.6.1/src/iron.rs:196:9 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" +target/lintcheck/sources/iron-0.6.1/src/iron.rs:80:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/iron-0.6.1/src/iron.rs:85:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/iron-0.6.1/src/iron.rs:90:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/iron-0.6.1/src/lib.rs:1:null clippy::cargo_common_metadata "package `iron` is missing `package.categories` metadata" +target/lintcheck/sources/iron-0.6.1/src/lib.rs:1:null clippy::cargo_common_metadata "package `iron` is missing `package.keywords` metadata" +target/lintcheck/sources/iron-0.6.1/src/lib.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `log`: 0.3.9, 0.4.8" +target/lintcheck/sources/iron-0.6.1/src/middleware/mod.rs:137:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/iron-0.6.1/src/middleware/mod.rs:150:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/iron-0.6.1/src/middleware/mod.rs:152:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/iron-0.6.1/src/middleware/mod.rs:159:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/iron-0.6.1/src/middleware/mod.rs:171:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/iron-0.6.1/src/middleware/mod.rs:173:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/iron-0.6.1/src/middleware/mod.rs:182:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/iron-0.6.1/src/middleware/mod.rs:192:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/iron-0.6.1/src/middleware/mod.rs:217:25 clippy::doc_markdown "you should put `ChainBuilder` between ticks in the documentation" +target/lintcheck/sources/iron-0.6.1/src/middleware/mod.rs:264:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/iron-0.6.1/src/middleware/mod.rs:328:20 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/iron-0.6.1/src/middleware/mod.rs:360:16 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/iron-0.6.1/src/middleware/mod.rs:368:33 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/iron-0.6.1/src/middleware/mod.rs:428:40 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/iron-0.6.1/src/middleware/mod.rs:434:40 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/iron-0.6.1/src/middleware/mod.rs:444:40 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/iron-0.6.1/src/modifiers.rs:132:14 clippy::expect_fun_call "use of `expect` followed by a function call" +target/lintcheck/sources/iron-0.6.1/src/request/mod.rs:113:24 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/iron-0.6.1/src/request/mod.rs:121:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/iron-0.6.1/src/request/mod.rs:123:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/iron-0.6.1/src/request/mod.rs:124:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/iron-0.6.1/src/request/mod.rs:126:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/iron-0.6.1/src/request/mod.rs:128:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/iron-0.6.1/src/request/mod.rs:153:69 clippy::doc_markdown "you should put `HttpReader` between ticks in the documentation" +target/lintcheck/sources/iron-0.6.1/src/request/mod.rs:154:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/iron-0.6.1/src/request/mod.rs:32:1 clippy::manual_non_exhaustive "this seems like a manual implementation of the non-exhaustive pattern" +target/lintcheck/sources/iron-0.6.1/src/request/mod.rs:75:34 clippy::doc_markdown "you should put `HttpRequest` between ticks in the documentation" +target/lintcheck/sources/iron-0.6.1/src/request/mod.rs:77:39 clippy::doc_markdown "you should put `HttpRequest` between ticks in the documentation" +target/lintcheck/sources/iron-0.6.1/src/request/mod.rs:78:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/iron-0.6.1/src/request/mod.rs:82:13 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/iron-0.6.1/src/request/mod.rs:83:29 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/iron-0.6.1/src/request/mod.rs:85:24 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/iron-0.6.1/src/request/url.rs:109:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/iron-0.6.1/src/request/url.rs:117:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/iron-0.6.1/src/request/url.rs:129:1 clippy::from_over_into "an implementation of `From` is preferred since it gives you `Into<_>` for free where the reverse isn't true" +target/lintcheck/sources/iron-0.6.1/src/request/url.rs:21:14 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +target/lintcheck/sources/iron-0.6.1/src/request/url.rs:22:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/iron-0.6.1/src/request/url.rs:31:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/iron-0.6.1/src/request/url.rs:47:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/iron-0.6.1/src/request/url.rs:52:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/iron-0.6.1/src/request/url.rs:57:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/iron-0.6.1/src/request/url.rs:57:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/iron-0.6.1/src/request/url.rs:63:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/iron-0.6.1/src/request/url.rs:63:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/iron-0.6.1/src/request/url.rs:73:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/iron-0.6.1/src/request/url.rs:73:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/iron-0.6.1/src/request/url.rs:83:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/iron-0.6.1/src/request/url.rs:96:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/iron-0.6.1/src/response.rs:121:19 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/iron-0.6.1/src/response.rs:125:43 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/iron-0.6.1/src/response.rs:139:41 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/iron-0.6.1/src/response.rs:24:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/iron-0.6.1/src/response.rs:95:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/iron-0.6.1/src/response.rs:95:5 clippy::new_without_default "you should consider adding a `Default` implementation for `response::Response`" +target/lintcheck/sources/libc-0.2.81/build.rs:114:19 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +target/lintcheck/sources/libc-0.2.81/build.rs:124:5 clippy::question_mark "this block may be rewritten with the `?` operator" +target/lintcheck/sources/libc-0.2.81/build.rs:133:5 clippy::question_mark "this block may be rewritten with the `?` operator" +target/lintcheck/sources/libc-0.2.81/src/macros.rs:243:17 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +target/lintcheck/sources/libc-0.2.81/src/macros.rs:243:17 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +target/lintcheck/sources/libc-0.2.81/src/macros.rs:243:17 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +target/lintcheck/sources/libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/libc-0.2.81/src/macros.rs:243:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/libc-0.2.81/src/macros.rs:259:null clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:428:29 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:429:30 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:431:30 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:432:32 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:433:29 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:434:32 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:595:33 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:596:33 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:597:35 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:622:32 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:673:34 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:696:33 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:697:35 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:698:33 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:699:35 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:712:34 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:721:35 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:722:32 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:723:32 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:751:31 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:752:30 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:753:30 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:754:30 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:755:29 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:756:29 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:757:29 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:758:29 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:759:29 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:760:29 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:768:30 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:769:31 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:771:31 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:772:29 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:773:29 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:774:29 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:775:32 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:776:31 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:777:32 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:778:32 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:779:31 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:780:32 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:781:32 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:782:31 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:783:31 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:784:32 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:785:33 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:786:33 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:787:30 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:788:32 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:789:32 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:790:32 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:791:32 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:792:33 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:794:31 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:795:31 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:796:31 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:797:32 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:798:31 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:799:31 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:800:31 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:801:31 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:803:27 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:804:28 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:805:28 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:806:29 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:807:29 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:808:29 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:809:29 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:810:29 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:811:29 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:812:30 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:813:30 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:814:30 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:815:30 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:816:30 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:817:31 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:818:31 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:821:31 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:822:31 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:823:32 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:824:32 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:825:32 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:826:32 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:827:32 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:828:32 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:829:33 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:830:33 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:831:33 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:832:33 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:833:33 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:834:33 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:835:33 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:836:33 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:841:32 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:842:32 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:843:32 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/b64/x86_64/mod.rs:844:33 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:1120:38 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:178:34 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:291:5 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:291:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:299:11 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:302:5 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:302:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:312:11 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:352:20 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:355:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:355:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:359:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:359:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:363:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:363:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:367:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:367:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:371:13 clippy::missing_safety_doc "unsafe function's docs miss `# Safety` section" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:371:13 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:534:36 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:645:31 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:727:40 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:728:40 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:729:39 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:731:44 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:732:36 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:733:41 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:734:43 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:735:42 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:736:40 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:737:36 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:738:37 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:741:39 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:742:40 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:743:40 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:744:40 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:745:40 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:746:43 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:747:42 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:748:40 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:749:39 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:750:41 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:751:41 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:752:43 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:753:42 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:755:42 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:756:41 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:757:41 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:758:39 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:759:39 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:761:41 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:762:44 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:763:45 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:764:40 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:765:40 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:766:40 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:767:44 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:768:44 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:769:39 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:770:35 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:771:35 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:772:37 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:773:39 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:774:45 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:775:41 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:776:39 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:803:34 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:841:30 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:842:37 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:982:40 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/gnu/mod.rs:984:46 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1209:36 clippy::cast_possible_truncation "casting `i32` to `i16` may truncate the value" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1210:36 clippy::cast_possible_truncation "casting `i32` to `i16` may truncate the value" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1235:39 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1236:41 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1274:42 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1324:31 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1333:37 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1334:35 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1346:34 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1346:34 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1346:34 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1347:37 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1347:37 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1347:37 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1348:36 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1348:36 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1348:36 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1349:37 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1349:37 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1349:37 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1350:35 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1350:35 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1350:35 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1351:36 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1351:36 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1351:36 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1352:31 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1352:31 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1352:31 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1419:36 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1420:36 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1421:36 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1422:36 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1423:36 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1490:37 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1561:46 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1562:45 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1567:31 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1568:32 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1586:26 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1587:34 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1588:31 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1589:31 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1897:38 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1898:51 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1900:39 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1969:34 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1970:34 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1971:36 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1972:36 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1973:36 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1974:37 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1975:37 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1976:36 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1977:36 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1978:39 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1979:39 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1980:39 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1981:39 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1982:39 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1983:39 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1984:38 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1985:38 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1986:35 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1987:35 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1988:35 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1989:35 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1990:38 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1991:37 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1992:37 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1993:38 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1994:37 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1995:37 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1996:37 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1997:37 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1998:33 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:1999:33 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2000:33 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2001:34 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2002:34 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2003:34 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2004:35 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2005:35 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2032:30 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2033:32 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2034:31 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2035:29 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2036:32 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2037:28 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2038:27 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2039:29 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2041:29 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2042:28 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2043:27 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2044:34 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2045:27 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2046:33 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2048:28 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2049:32 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2050:32 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2051:32 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2052:26 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2053:36 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2318:42 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2321:38 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2331:39 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2487:42 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2488:42 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2489:43 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2490:43 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2491:43 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2493:47 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2494:44 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2495:46 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2496:47 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2497:49 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2498:48 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2499:50 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2500:45 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2572:9 clippy::needless_return "unneeded `return` statement" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2578:20 clippy::zero_ptr "`0 as *mut _` detected" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2588:13 clippy::zero_ptr "`0 as *mut _` detected" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2590:13 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2596:52 clippy::used_underscore_binding "used binding `_dummy` which is prefixed with an underscore. A leading underscore signals that a binding will not be used" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2597:11 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2601:21 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2611:9 clippy::unused_unit "unneeded unit expression" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2619:9 clippy::unused_unit "unneeded unit expression" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2634:9 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2647:25 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2648:25 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2649:9 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2654:18 clippy::identity_op "the operation is ineffective. Consider reducing it to `(dev & 0x00000000000000ff)`" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2654:25 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2655:25 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2656:9 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2660:21 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2661:21 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2663:25 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2664:25 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2665:16 clippy::identity_op "the operation is ineffective. Consider reducing it to `(minor & 0x000000ff)`" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2665:25 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:2666:25 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/linux/mod.rs:954:34 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1000:31 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1001:32 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1002:32 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1016:29 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1017:32 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1018:33 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1019:33 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1020:33 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1029:29 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1030:29 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1031:30 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1032:29 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1033:29 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1034:29 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1035:29 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1041:32 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1042:32 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1043:32 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1044:32 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1045:31 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1046:32 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1047:31 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1048:31 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1049:31 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1050:31 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1051:33 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1053:29 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1054:33 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1055:30 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1056:31 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1057:31 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1058:32 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1059:31 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1060:31 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1073:42 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1074:43 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1075:37 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1076:37 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1077:41 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1078:35 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1079:35 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1080:36 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1081:35 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1082:35 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1083:31 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1084:38 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1086:30 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1087:32 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1089:30 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1090:33 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1091:30 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1094:40 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1095:37 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1096:41 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1097:40 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1098:39 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1099:34 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1100:36 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1101:38 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1102:37 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1105:44 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1106:41 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1107:42 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1108:42 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1109:41 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1110:46 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1111:41 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1112:44 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1113:40 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1114:47 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1115:36 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1126:34 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1127:29 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1128:31 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1179:32 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1180:31 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1218:27 clippy::identity_op "the operation is ineffective. Consider reducing it to `IPOPT_CONTROL`" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1314:9 clippy::precedence "operator precedence can trip the unwary" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1321:13 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1323:13 clippy::zero_ptr "`0 as *mut _` detected" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1332:9 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1337:9 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1341:18 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1344:9 clippy::needless_return "unneeded `return` statement" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1348:18 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1350:9 clippy::needless_return "unneeded `return` statement" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1354:18 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1357:9 clippy::needless_return "unneeded `return` statement" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1361:21 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1381:9 clippy::cast_possible_truncation "casting `i32` to `i8` may truncate the value" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:1389:9 clippy::verbose_bit_mask "bit mask could be simplified with a call to `trailing_zeros`" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:446:31 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:591:36 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:592:38 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:593:35 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:594:33 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:595:34 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:596:36 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:597:37 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:598:37 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:599:39 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:600:34 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:601:35 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:602:35 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:607:37 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:608:35 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:764:35 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:765:39 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/linux_like/mod.rs:991:30 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/mod.rs:198:29 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/mod.rs:199:28 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/mod.rs:201:35 clippy::unnecessary_cast "casting integer literal to `usize` is unnecessary" +target/lintcheck/sources/libc-0.2.81/src/unix/mod.rs:202:35 clippy::unnecessary_cast "casting integer literal to `usize` is unnecessary" +target/lintcheck/sources/libc-0.2.81/src/unix/mod.rs:282:40 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/mod.rs:284:41 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/mod.rs:285:36 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/libc-0.2.81/src/unix/mod.rs:34:10 clippy::upper_case_acronyms "name `DIR` contains a capitalized acronym" +target/lintcheck/sources/libc-0.2.81/src/unix/mod.rs:386:10 clippy::upper_case_acronyms "name `FILE` contains a capitalized acronym" +target/lintcheck/sources/log-0.4.11/src/lib.rs:1047:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/log-0.4.11/src/lib.rs:1053:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/log-0.4.11/src/lib.rs:1059:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/log-0.4.11/src/lib.rs:1093:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/log-0.4.11/src/lib.rs:1093:5 clippy::new_without_default "you should consider adding a `Default` implementation for `MetadataBuilder<'a>`" +target/lintcheck/sources/log-0.4.11/src/lib.rs:1118:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/log-0.4.11/src/lib.rs:1177:1 clippy::inline_always "you have declared `#[inline(always)]` on `max_level`. This is usually a bad idea" +target/lintcheck/sources/log-0.4.11/src/lib.rs:1178:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/log-0.4.11/src/lib.rs:1306:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/log-0.4.11/src/lib.rs:1358:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/log-0.4.11/src/lib.rs:1359:5 clippy::if_not_else "unnecessary `!=` operation" +target/lintcheck/sources/log-0.4.11/src/lib.rs:1407:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/log-0.4.11/src/lib.rs:356:1 clippy::expl_impl_clone_on_copy "you are implementing `Clone` explicitly on a `Copy` type" +target/lintcheck/sources/log-0.4.11/src/lib.rs:448:12 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +target/lintcheck/sources/log-0.4.11/src/lib.rs:500:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/log-0.4.11/src/lib.rs:506:28 clippy::trivially_copy_pass_by_ref "this argument (8 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +target/lintcheck/sources/log-0.4.11/src/lib.rs:506:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/log-0.4.11/src/lib.rs:506:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/log-0.4.11/src/lib.rs:538:1 clippy::expl_impl_clone_on_copy "you are implementing `Clone` explicitly on a `Copy` type" +target/lintcheck/sources/log-0.4.11/src/lib.rs:653:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/log-0.4.11/src/lib.rs:661:21 clippy::trivially_copy_pass_by_ref "this argument (8 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +target/lintcheck/sources/log-0.4.11/src/lib.rs:661:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/log-0.4.11/src/lib.rs:677:44 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/log-0.4.11/src/lib.rs:758:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/log-0.4.11/src/lib.rs:764:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/log-0.4.11/src/lib.rs:770:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/log-0.4.11/src/lib.rs:776:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/log-0.4.11/src/lib.rs:782:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/log-0.4.11/src/lib.rs:788:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/log-0.4.11/src/lib.rs:794:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/log-0.4.11/src/lib.rs:803:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/log-0.4.11/src/lib.rs:809:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/log-0.4.11/src/lib.rs:818:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/log-0.4.11/src/lib.rs:908:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/log-0.4.11/src/lib.rs:908:5 clippy::new_without_default "you should consider adding a `Default` implementation for `RecordBuilder<'a>`" +target/lintcheck/sources/log-0.4.11/src/lib.rs:995:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/proc-macro2-1.0.24/src/detection.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/proc-macro2-1.0.24/src/fallback.rs:108:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +target/lintcheck/sources/proc-macro2-1.0.24/src/fallback.rs:269:20 clippy::unused_self "unused `self` argument" +target/lintcheck/sources/proc-macro2-1.0.24/src/fallback.rs:430:24 clippy::trivially_copy_pass_by_ref "this argument (0 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +target/lintcheck/sources/proc-macro2-1.0.24/src/fallback.rs:437:23 clippy::trivially_copy_pass_by_ref "this argument (0 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +target/lintcheck/sources/proc-macro2-1.0.24/src/fallback.rs:437:23 clippy::unused_self "unused `self` argument" +target/lintcheck/sources/proc-macro2-1.0.24/src/fallback.rs:471:17 clippy::trivially_copy_pass_by_ref "this argument (0 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +target/lintcheck/sources/proc-macro2-1.0.24/src/fallback.rs:471:17 clippy::unused_self "unused `self` argument" +target/lintcheck/sources/proc-macro2-1.0.24/src/fallback.rs:654:5 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +target/lintcheck/sources/proc-macro2-1.0.24/src/fallback.rs:655:12 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +target/lintcheck/sources/proc-macro2-1.0.24/src/fallback.rs:661:5 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +target/lintcheck/sources/proc-macro2-1.0.24/src/fallback.rs:662:12 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +target/lintcheck/sources/proc-macro2-1.0.24/src/fallback.rs:664:12 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +target/lintcheck/sources/proc-macro2-1.0.24/src/fallback.rs:674:37 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +target/lintcheck/sources/proc-macro2-1.0.24/src/fallback.rs:678:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/proc-macro2-1.0.24/src/fallback.rs:85:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/proc-macro2-1.0.24/src/fallback.rs:882:43 clippy::unused_self "unused `self` argument" +target/lintcheck/sources/proc-macro2-1.0.24/src/lib.rs:1017:9 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/proc-macro2-1.0.24/src/lib.rs:1081:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/proc-macro2-1.0.24/src/lib.rs:1099:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/proc-macro2-1.0.24/src/lib.rs:1117:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/proc-macro2-1.0.24/src/lib.rs:1135:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/proc-macro2-1.0.24/src/lib.rs:1141:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/proc-macro2-1.0.24/src/lib.rs:1146:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/proc-macro2-1.0.24/src/lib.rs:1151:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/proc-macro2-1.0.24/src/lib.rs:1156:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/proc-macro2-1.0.24/src/lib.rs:152:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/proc-macro2-1.0.24/src/lib.rs:157:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/proc-macro2-1.0.24/src/lib.rs:373:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/proc-macro2-1.0.24/src/lib.rs:383:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/proc-macro2-1.0.24/src/lib.rs:397:24 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +target/lintcheck/sources/proc-macro2-1.0.24/src/lib.rs:397:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/proc-macro2-1.0.24/src/lib.rs:403:23 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +target/lintcheck/sources/proc-macro2-1.0.24/src/lib.rs:403:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/proc-macro2-1.0.24/src/lib.rs:418:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/proc-macro2-1.0.24/src/lib.rs:425:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/proc-macro2-1.0.24/src/lib.rs:464:17 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +target/lintcheck/sources/proc-macro2-1.0.24/src/lib.rs:500:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/proc-macro2-1.0.24/src/lib.rs:626:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/proc-macro2-1.0.24/src/lib.rs:633:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/proc-macro2-1.0.24/src/lib.rs:641:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/proc-macro2-1.0.24/src/lib.rs:652:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/proc-macro2-1.0.24/src/lib.rs:662:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/proc-macro2-1.0.24/src/lib.rs:672:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/proc-macro2-1.0.24/src/lib.rs:734:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/proc-macro2-1.0.24/src/lib.rs:743:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/proc-macro2-1.0.24/src/lib.rs:752:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/proc-macro2-1.0.24/src/lib.rs:757:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/proc-macro2-1.0.24/src/lib.rs:788:19 clippy::doc_markdown "you should put `XID_Start` between ticks in the documentation" +target/lintcheck/sources/proc-macro2-1.0.24/src/lib.rs:788:69 clippy::doc_markdown "you should put `XID_Continue` between ticks in the documentation" +target/lintcheck/sources/proc-macro2-1.0.24/src/lib.rs:891:36 clippy::doc_markdown "you should put `syn::parse_str` between ticks in the documentation" +target/lintcheck/sources/proc-macro2-1.0.24/src/lib.rs:894:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/proc-macro2-1.0.24/src/lib.rs:911:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/proc-macro2-1.0.24/src/lib.rs:996:9 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/proc-macro2-1.0.24/src/parse.rs:552:5 clippy::while_let_on_iterator "this loop could be written as a `for` loop" +target/lintcheck/sources/proc-macro2-1.0.24/src/parse.rs:584:21 clippy::manual_range_contains "manual `RangeInclusive::contains` implementation" +target/lintcheck/sources/proc-macro2-1.0.24/src/parse.rs:602:20 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +target/lintcheck/sources/proc-macro2-1.0.24/src/parse.rs:696:29 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" +target/lintcheck/sources/proc-macro2-1.0.24/src/parse.rs:702:34 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" +target/lintcheck/sources/proc-macro2-1.0.24/src/parse.rs:708:34 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" +target/lintcheck/sources/proc-macro2-1.0.24/src/parse.rs:793:5 clippy::vec_init_then_push "calls to `push` immediately after creation" +target/lintcheck/sources/proc-macro2-1.0.24/src/parse.rs:803:15 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" +target/lintcheck/sources/proc-macro2-1.0.24/src/parse.rs:808:15 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" +target/lintcheck/sources/proc-macro2-1.0.24/src/wrapper.rs:415:24 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +target/lintcheck/sources/proc-macro2-1.0.24/src/wrapper.rs:429:23 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +target/lintcheck/sources/proc-macro2-1.0.24/src/wrapper.rs:492:17 clippy::trivially_copy_pass_by_ref "this argument (4 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +target/lintcheck/sources/puffin-02dd4a3/puffin-imgui/src/ui.rs:158:15 clippy::cast_precision_loss "casting `i64` to `f32` causes a loss of precision (`i64` is 64 bits wide, but `f32`'s mantissa is only 23 bits wide)" +target/lintcheck/sources/puffin-02dd4a3/puffin-imgui/src/ui.rs:175:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/puffin-02dd4a3/puffin-imgui/src/ui.rs:183:5 clippy::too_many_lines "this function has too many lines (115/100)" +target/lintcheck/sources/puffin-02dd4a3/puffin-imgui/src/ui.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/puffin-02dd4a3/puffin-imgui/src/ui.rs:207:16 clippy::collapsible_else_if "this `else { if .. }` block can be collapsed" +target/lintcheck/sources/puffin-02dd4a3/puffin-imgui/src/ui.rs:271:67 clippy::cast_precision_loss "casting `i64` to `f32` causes a loss of precision (`i64` is 64 bits wide, but `f32`'s mantissa is only 23 bits wide)" +target/lintcheck/sources/puffin-02dd4a3/puffin-imgui/src/ui.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/puffin-02dd4a3/puffin-imgui/src/ui.rs:376:29 clippy::cast_precision_loss "casting `i64` to `f32` causes a loss of precision (`i64` is 64 bits wide, but `f32`'s mantissa is only 23 bits wide)" +target/lintcheck/sources/puffin-02dd4a3/puffin-imgui/src/ui.rs:381:44 clippy::cast_precision_loss "casting `i64` to `f32` causes a loss of precision (`i64` is 64 bits wide, but `f32`'s mantissa is only 23 bits wide)" +target/lintcheck/sources/puffin-02dd4a3/puffin-imgui/src/ui.rs:453:9 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/puffin-02dd4a3/puffin-imgui/src/ui.rs:540:14 clippy::cast_possible_truncation "casting `f64` to `f32` may truncate the value" +target/lintcheck/sources/puffin-02dd4a3/puffin-imgui/src/ui.rs:551:5 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +target/lintcheck/sources/puffin-02dd4a3/puffin-imgui/src/ui.rs:584:39 clippy::cast_precision_loss "casting `usize` to `f32` causes a loss of precision (`usize` is 32 or 64 bits wide, but `f32`'s mantissa is only 23 bits wide)" +target/lintcheck/sources/puffin-02dd4a3/puffin-imgui/src/ui.rs:59:26 clippy::unsafe_derive_deserialize "you are deriving `serde::Deserialize` on a type that has methods using `unsafe`" +target/lintcheck/sources/puffin-02dd4a3/puffin-imgui/src/ui.rs:61:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/puffin-02dd4a3/puffin-imgui/src/ui.rs:627:39 clippy::cast_precision_loss "casting `usize` to `f32` causes a loss of precision (`usize` is 32 or 64 bits wide, but `f32`'s mantissa is only 23 bits wide)" +target/lintcheck/sources/puffin-02dd4a3/puffin-imgui/src/ui.rs:674:47 clippy::cast_precision_loss "casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +target/lintcheck/sources/puffin-02dd4a3/puffin-imgui/src/ui.rs:690:9 clippy::cast_precision_loss "casting `usize` to `f32` causes a loss of precision (`usize` is 32 or 64 bits wide, but `f32`'s mantissa is only 23 bits wide)" +target/lintcheck/sources/puffin-02dd4a3/puffin/src/data.rs:102:25 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" +target/lintcheck/sources/puffin-02dd4a3/puffin/src/data.rs:112:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/puffin-02dd4a3/puffin/src/data.rs:116:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/puffin-02dd4a3/puffin/src/data.rs:137:24 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/puffin-02dd4a3/puffin/src/data.rs:177:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/puffin-02dd4a3/puffin/src/data.rs:211:21 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +target/lintcheck/sources/puffin-02dd4a3/puffin/src/data.rs:24:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/puffin-02dd4a3/puffin/src/lib.rs:113:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/puffin-02dd4a3/puffin/src/lib.rs:147:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/puffin-02dd4a3/puffin/src/lib.rs:147:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/puffin-02dd4a3/puffin/src/lib.rs:165:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/puffin-02dd4a3/puffin/src/lib.rs:200:21 clippy::default_trait_access "calling `Stream::default()` is more clear than this expression" +target/lintcheck/sources/puffin-02dd4a3/puffin/src/lib.rs:257:78 clippy::default_trait_access "calling `std::cell::RefCell::default()` is more clear than this expression" +target/lintcheck/sources/puffin-02dd4a3/puffin/src/lib.rs:297:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/puffin-02dd4a3/puffin/src/lib.rs:302:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/puffin-02dd4a3/puffin/src/lib.rs:308:28 clippy::default_trait_access "calling `FullProfileData::default()` is more clear than this expression" +target/lintcheck/sources/puffin-02dd4a3/puffin/src/lib.rs:316:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/puffin-02dd4a3/puffin/src/lib.rs:321:5 clippy::cast_possible_truncation "casting `u128` to `i64` may truncate the value" +target/lintcheck/sources/puffin-02dd4a3/puffin/src/lib.rs:348:28 clippy::default_trait_access "calling `std::marker::PhantomData::default()` is more clear than this expression" +target/lintcheck/sources/puffin-02dd4a3/puffin/src/lib.rs:359:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/puffin-02dd4a3/puffin/src/lib.rs:375:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/puffin-02dd4a3/puffin/src/lib.rs:376:5 clippy::option_if_let_else "use Option::map_or instead of an if let/else" +target/lintcheck/sources/puffin-02dd4a3/puffin/src/lib.rs:377:9 clippy::option_if_let_else "use Option::map_or instead of an if let/else" +target/lintcheck/sources/puffin-02dd4a3/puffin/src/lib.rs:406:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/puffin-02dd4a3/puffin/src/lib.rs:408:5 clippy::option_if_let_else "use Option::map_or instead of an if let/else" +target/lintcheck/sources/puffin-02dd4a3/puffin/src/lib.rs:69:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/puffin-02dd4a3/puffin/src/lib.rs:73:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/puffin-02dd4a3/puffin/src/lib.rs:77:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/puffin-02dd4a3/puffin/src/merge.rs:21:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/puffin-02dd4a3/puffin/src/merge.rs:28:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/puffin-02dd4a3/puffin/src/merge.rs:28:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/puffin-02dd4a3/puffin/src/merge.rs:35:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/puffin-02dd4a3/puffin/src/merge.rs:35:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/puffin-02dd4a3/puffin/src/merge.rs:64:43 clippy::default_trait_access "calling `std::vec::Vec::default()` is more clear than this expression" +target/lintcheck/sources/puffin-02dd4a3/puffin/src/merge.rs:65:54 clippy::default_trait_access "calling `std::collections::HashMap::default()` is more clear than this expression" +target/lintcheck/sources/puffin-02dd4a3/puffin/src/merge.rs:9:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/quote-1.0.7/src/ext.rs:10:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/quote-1.0.7/src/ext.rs:7:5 clippy::doc_markdown "you should put `TokenStream` between ticks in the documentation" +target/lintcheck/sources/quote-1.0.7/src/ident_fragment.rs:13:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/quote-1.0.7/src/ident_fragment.rs:51:31 clippy::manual_strip "stripping a prefix manually" +target/lintcheck/sources/quote-1.0.7/src/runtime.rs:52:5 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/quote-1.0.7/src/runtime.rs:63:5 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/quote-1.0.7/src/runtime.rs:66:33 clippy::doc_markdown "you should put `DoesNotHaveIter` between ticks in the documentation" +target/lintcheck/sources/quote-1.0.7/src/runtime.rs:80:5 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/rand-0.7.3/src/distributions/bernoulli.rs:103:20 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" +target/lintcheck/sources/rand-0.7.3/src/distributions/bernoulli.rs:103:20 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" +target/lintcheck/sources/rand-0.7.3/src/distributions/bernoulli.rs:116:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/rand-0.7.3/src/distributions/bernoulli.rs:123:21 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" +target/lintcheck/sources/rand-0.7.3/src/distributions/bernoulli.rs:123:21 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" +target/lintcheck/sources/rand-0.7.3/src/distributions/bernoulli.rs:63:26 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +target/lintcheck/sources/rand-0.7.3/src/distributions/bernoulli.rs:63:27 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +target/lintcheck/sources/rand-0.7.3/src/distributions/bernoulli.rs:67:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/rand-0.7.3/src/distributions/bernoulli.rs:95:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/rand-0.7.3/src/distributions/bernoulli.rs:96:13 clippy::manual_range_contains "manual `Range::contains` implementation" +target/lintcheck/sources/rand-0.7.3/src/distributions/binomial.rs:107:23 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +target/lintcheck/sources/rand-0.7.3/src/distributions/binomial.rs:112:44 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +target/lintcheck/sources/rand-0.7.3/src/distributions/binomial.rs:116:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rand-0.7.3/src/distributions/binomial.rs:150:28 clippy::redundant_else "redundant else block" +target/lintcheck/sources/rand-0.7.3/src/distributions/binomial.rs:153:24 clippy::if_not_else "unnecessary boolean `not` operation" +target/lintcheck/sources/rand-0.7.3/src/distributions/binomial.rs:158:28 clippy::redundant_else "redundant else block" +target/lintcheck/sources/rand-0.7.3/src/distributions/binomial.rs:164:33 clippy::cast_sign_loss "casting `i64` to `u64` may lose the sign of the value" +target/lintcheck/sources/rand-0.7.3/src/distributions/binomial.rs:166:28 clippy::redundant_else "redundant else block" +target/lintcheck/sources/rand-0.7.3/src/distributions/binomial.rs:175:47 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +target/lintcheck/sources/rand-0.7.3/src/distributions/binomial.rs:185:38 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +target/lintcheck/sources/rand-0.7.3/src/distributions/binomial.rs:194:38 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +target/lintcheck/sources/rand-0.7.3/src/distributions/binomial.rs:202:28 clippy::redundant_else "redundant else block" +target/lintcheck/sources/rand-0.7.3/src/distributions/binomial.rs:209:25 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +target/lintcheck/sources/rand-0.7.3/src/distributions/binomial.rs:221:26 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +target/lintcheck/sources/rand-0.7.3/src/distributions/binomial.rs:222:26 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +target/lintcheck/sources/rand-0.7.3/src/distributions/binomial.rs:223:25 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +target/lintcheck/sources/rand-0.7.3/src/distributions/binomial.rs:224:25 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +target/lintcheck/sources/rand-0.7.3/src/distributions/binomial.rs:226:17 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rand-0.7.3/src/distributions/binomial.rs:233:32 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +target/lintcheck/sources/rand-0.7.3/src/distributions/binomial.rs:234:27 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +target/lintcheck/sources/rand-0.7.3/src/distributions/binomial.rs:251:22 clippy::cast_sign_loss "casting `i64` to `u64` may lose the sign of the value" +target/lintcheck/sources/rand-0.7.3/src/distributions/binomial.rs:255:9 clippy::if_not_else "unnecessary `!=` operation" +target/lintcheck/sources/rand-0.7.3/src/distributions/binomial.rs:35:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/rand-0.7.3/src/distributions/binomial.rs:45:17 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +target/lintcheck/sources/rand-0.7.3/src/distributions/binomial.rs:46:5 clippy::cast_possible_truncation "casting `f64` to `i64` may truncate the value" +target/lintcheck/sources/rand-0.7.3/src/distributions/binomial.rs:50:5 clippy::too_many_lines "this function has too many lines (143/100)" +target/lintcheck/sources/rand-0.7.3/src/distributions/binomial.rs:76:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rand-0.7.3/src/distributions/binomial.rs:78:12 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +target/lintcheck/sources/rand-0.7.3/src/distributions/binomial.rs:81:21 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +target/lintcheck/sources/rand-0.7.3/src/distributions/binomial.rs:82:32 clippy::cast_possible_truncation "casting `u64` to `i32` may truncate the value" +target/lintcheck/sources/rand-0.7.3/src/distributions/binomial.rs:88:26 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +target/lintcheck/sources/rand-0.7.3/src/distributions/binomial.rs:99:21 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +target/lintcheck/sources/rand-0.7.3/src/distributions/cauchy.rs:33:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/rand-0.7.3/src/distributions/dirichlet.rs:52:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/rand-0.7.3/src/distributions/dirichlet.rs:64:32 clippy::unseparated_literal_suffix "float type suffix should be separated by an underscore" +target/lintcheck/sources/rand-0.7.3/src/distributions/dirichlet.rs:65:23 clippy::unseparated_literal_suffix "float type suffix should be separated by an underscore" +target/lintcheck/sources/rand-0.7.3/src/distributions/exponential.rs:76:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/rand-0.7.3/src/distributions/float.rs:73:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/rand-0.7.3/src/distributions/gamma.rs:13:5 clippy::enum_glob_use "usage of wildcard import for enum variants" +target/lintcheck/sources/rand-0.7.3/src/distributions/gamma.rs:14:5 clippy::enum_glob_use "usage of wildcard import for enum variants" +target/lintcheck/sources/rand-0.7.3/src/distributions/gamma.rs:189:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/rand-0.7.3/src/distributions/gamma.rs:230:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/rand-0.7.3/src/distributions/gamma.rs:259:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/rand-0.7.3/src/distributions/gamma.rs:287:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/rand-0.7.3/src/distributions/gamma.rs:90:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/rand-0.7.3/src/distributions/integer.rs:23:9 clippy::cast_possible_truncation "casting `u32` to `u8` may truncate the value" +target/lintcheck/sources/rand-0.7.3/src/distributions/integer.rs:30:9 clippy::cast_possible_truncation "casting `u32` to `u16` may truncate the value" +target/lintcheck/sources/rand-0.7.3/src/distributions/integer.rs:69:9 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +target/lintcheck/sources/rand-0.7.3/src/distributions/mod.rs:263:5 clippy::inline_always "you have declared `#[inline(always)]` on `next`. This is usually a bad idea" +target/lintcheck/sources/rand-0.7.3/src/distributions/normal.rs:100:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/rand-0.7.3/src/distributions/normal.rs:119:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/rand-0.7.3/src/distributions/normal.rs:131:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/rand-0.7.3/src/distributions/normal.rs:31:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/rand-0.7.3/src/distributions/normal.rs:47:25 clippy::unseparated_literal_suffix "float type suffix should be separated by an underscore" +target/lintcheck/sources/rand-0.7.3/src/distributions/normal.rs:48:25 clippy::unseparated_literal_suffix "float type suffix should be separated by an underscore" +target/lintcheck/sources/rand-0.7.3/src/distributions/other.rs:89:9 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +target/lintcheck/sources/rand-0.7.3/src/distributions/pareto.rs:32:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/rand-0.7.3/src/distributions/poisson.rs:35:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/rand-0.7.3/src/distributions/poisson.rs:87:30 clippy::cast_possible_truncation "casting `f64` to `u64` may truncate the value" +target/lintcheck/sources/rand-0.7.3/src/distributions/poisson.rs:87:30 clippy::cast_sign_loss "casting `f64` to `u64` may lose the sign of the value" +target/lintcheck/sources/rand-0.7.3/src/distributions/triangular.rs:32:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/rand-0.7.3/src/distributions/uniform.rs:146:4 clippy::needless_doctest_main "needless `fn main` in doctest" +target/lintcheck/sources/rand-0.7.3/src/distributions/uniform.rs:199:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/rand-0.7.3/src/distributions/uniform.rs:214:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/rand-0.7.3/src/distributions/uniform.rs:283:14 clippy::doc_markdown "you should put `SampleUniform` between ticks in the documentation" +target/lintcheck/sources/rand-0.7.3/src/distributions/uniform.rs:283:46 clippy::doc_markdown "you should put `SampleUniform` between ticks in the documentation" +target/lintcheck/sources/rand-0.7.3/src/distributions/uniform.rs:296:5 clippy::inline_always "you have declared `#[inline(always)]` on `borrow`. This is usually a bad idea" +target/lintcheck/sources/rand-0.7.3/src/distributions/uniform.rs:304:5 clippy::inline_always "you have declared `#[inline(always)]` on `borrow`. This is usually a bad idea" +target/lintcheck/sources/rand-0.7.3/src/distributions/uniform.rs:350:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/rand-0.7.3/src/distributions/uniform.rs:407:21 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/rand-0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" +target/lintcheck/sources/rand-0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" +target/lintcheck/sources/rand-0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" +target/lintcheck/sources/rand-0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" +target/lintcheck/sources/rand-0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" +target/lintcheck/sources/rand-0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" +target/lintcheck/sources/rand-0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" +target/lintcheck/sources/rand-0.7.3/src/distributions/uniform.rs:441:31 clippy::invalid_upcast_comparisons "because of the numeric bounds on `::core::u16::MAX` prior to casting, this expression is always false" +target/lintcheck/sources/rand-0.7.3/src/distributions/uniform.rs:56:10 clippy::doc_markdown "you should put `SampleBorrow` between ticks in the documentation" +target/lintcheck/sources/rand-0.7.3/src/distributions/uniform.rs:647:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/rand-0.7.3/src/distributions/uniform.rs:840:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/rand-0.7.3/src/distributions/uniform.rs:913:13 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" +target/lintcheck/sources/rand-0.7.3/src/distributions/uniform.rs:943:54 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +target/lintcheck/sources/rand-0.7.3/src/distributions/unit_circle.rs:30:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/rand-0.7.3/src/distributions/unit_sphere.rs:24:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/rand-0.7.3/src/distributions/unit_sphere.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/rand-0.7.3/src/distributions/utils.rs:247:15 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" +target/lintcheck/sources/rand-0.7.3/src/distributions/utils.rs:248:20 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" +target/lintcheck/sources/rand-0.7.3/src/distributions/utils.rs:249:18 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" +target/lintcheck/sources/rand-0.7.3/src/distributions/utils.rs:254:5 clippy::inline_always "you have declared `#[inline(always)]` on `lanes`. This is usually a bad idea" +target/lintcheck/sources/rand-0.7.3/src/distributions/utils.rs:258:5 clippy::inline_always "you have declared `#[inline(always)]` on `splat`. This is usually a bad idea" +target/lintcheck/sources/rand-0.7.3/src/distributions/utils.rs:262:5 clippy::inline_always "you have declared `#[inline(always)]` on `extract`. This is usually a bad idea" +target/lintcheck/sources/rand-0.7.3/src/distributions/utils.rs:267:5 clippy::inline_always "you have declared `#[inline(always)]` on `replace`. This is usually a bad idea" +target/lintcheck/sources/rand-0.7.3/src/distributions/utils.rs:281:5 clippy::inline_always "you have declared `#[inline(always)]` on `any`. This is usually a bad idea" +target/lintcheck/sources/rand-0.7.3/src/distributions/utils.rs:286:5 clippy::inline_always "you have declared `#[inline(always)]` on `all`. This is usually a bad idea" +target/lintcheck/sources/rand-0.7.3/src/distributions/utils.rs:291:5 clippy::inline_always "you have declared `#[inline(always)]` on `none`. This is usually a bad idea" +target/lintcheck/sources/rand-0.7.3/src/distributions/utils.rs:488:17 clippy::doc_markdown "you should put `x_i` between ticks in the documentation" +target/lintcheck/sources/rand-0.7.3/src/distributions/utils.rs:489:50 clippy::doc_markdown "you should put `x_i` between ticks in the documentation" +target/lintcheck/sources/rand-0.7.3/src/distributions/utils.rs:489:63 clippy::doc_markdown "you should put `f(x_i` between ticks in the documentation" +target/lintcheck/sources/rand-0.7.3/src/distributions/utils.rs:490:40 clippy::doc_markdown "you should put `f(x_i` between ticks in the documentation" +target/lintcheck/sources/rand-0.7.3/src/distributions/utils.rs:490:49 clippy::doc_markdown "you should put `f(x_{i+1` between ticks in the documentation" +target/lintcheck/sources/rand-0.7.3/src/distributions/utils.rs:518:17 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +target/lintcheck/sources/rand-0.7.3/src/distributions/weibull.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/rand-0.7.3/src/distributions/weighted/alias_method.rs:113:21 clippy::explicit_iter_loop "it is more concise to loop over references to containers instead of using explicit iteration methods" +target/lintcheck/sources/rand-0.7.3/src/distributions/weighted/alias_method.rs:125:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rand-0.7.3/src/distributions/weighted/alias_method.rs:131:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rand-0.7.3/src/distributions/weighted/alias_method.rs:180:36 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +target/lintcheck/sources/rand-0.7.3/src/distributions/weighted/alias_method.rs:182:34 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +target/lintcheck/sources/rand-0.7.3/src/distributions/weighted/alias_method.rs:259:28 clippy::clone_on_copy "using `clone` on type `distributions::uniform::Uniform` which implements the `Copy` trait" +target/lintcheck/sources/rand-0.7.3/src/distributions/weighted/alias_method.rs:296:9 clippy::map_clone "you are using an explicit closure for copying elements" +target/lintcheck/sources/rand-0.7.3/src/distributions/weighted/alias_method.rs:321:9 clippy::map_clone "you are using an explicit closure for copying elements" +target/lintcheck/sources/rand-0.7.3/src/distributions/weighted/alias_method.rs:78:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/rand-0.7.3/src/distributions/weighted/alias_method.rs:78:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/rand-0.7.3/src/distributions/weighted/alias_method.rs:78:5 clippy::too_many_lines "this function has too many lines (106/100)" +target/lintcheck/sources/rand-0.7.3/src/distributions/weighted/alias_method.rs:85:17 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +target/lintcheck/sources/rand-0.7.3/src/distributions/weighted/alias_method.rs:87:31 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +target/lintcheck/sources/rand-0.7.3/src/distributions/weighted/mod.rs:100:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/rand-0.7.3/src/distributions/weighted/mod.rs:144:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/rand-0.7.3/src/distributions/weighted/mod.rs:144:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/rand-0.7.3/src/distributions/weighted/mod.rs:169:16 clippy::int_plus_one "unnecessary `>= y + 1` or `x - 1 >=`" +target/lintcheck/sources/rand-0.7.3/src/distributions/weighted/mod.rs:386:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/rand-0.7.3/src/distributions/weighted/mod.rs:85:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/rand-0.7.3/src/lib.rs:333:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/rand-0.7.3/src/lib.rs:404:14 clippy::wrong_self_convention "methods called `to_*` usually take self by reference; consider choosing a less ambiguous name" +target/lintcheck/sources/rand-0.7.3/src/lib.rs:552:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/rand-0.7.3/src/rngs/adapter/read.rs:47:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/rand-0.7.3/src/rngs/adapter/read.rs:89:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/rand-0.7.3/src/rngs/adapter/reseeding.rs:100:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/rand-0.7.3/src/rngs/adapter/reseeding.rs:112:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea" +target/lintcheck/sources/rand-0.7.3/src/rngs/adapter/reseeding.rs:117:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea" +target/lintcheck/sources/rand-0.7.3/src/rngs/adapter/reseeding.rs:198:13 clippy::cast_possible_wrap "casting `u64` to `i64` may wrap around the value" +target/lintcheck/sources/rand-0.7.3/src/rngs/adapter/reseeding.rs:231:9 clippy::cast_possible_wrap "casting `usize` to `isize` may wrap around the value" +target/lintcheck/sources/rand-0.7.3/src/rngs/adapter/reseeding.rs:249:13 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" +target/lintcheck/sources/rand-0.7.3/src/rngs/adapter/reseeding.rs:27:28 clippy::doc_markdown "you should put `ChaCha` between ticks in the documentation" +target/lintcheck/sources/rand-0.7.3/src/rngs/adapter/reseeding.rs:79:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/rand-0.7.3/src/rngs/entropy.rs:24:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/rand-0.7.3/src/rngs/entropy.rs:34:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/rand-0.7.3/src/rngs/mock.rs:36:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/rand-0.7.3/src/rngs/mock.rs:47:9 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +target/lintcheck/sources/rand-0.7.3/src/rngs/mod.rs:61:74 clippy::doc_markdown "you should put `ChaCha20` between ticks in the documentation" +target/lintcheck/sources/rand-0.7.3/src/rngs/std.rs:25:39 clippy::doc_markdown "you should put `ChaCha` between ticks in the documentation" +target/lintcheck/sources/rand-0.7.3/src/rngs/std.rs:32:10 clippy::doc_markdown "you should put `rand_chacha` between ticks in the documentation" +target/lintcheck/sources/rand-0.7.3/src/rngs/std.rs:36:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/rand-0.7.3/src/rngs/std.rs:39:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea" +target/lintcheck/sources/rand-0.7.3/src/rngs/std.rs:44:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea" +target/lintcheck/sources/rand-0.7.3/src/rngs/std.rs:49:5 clippy::inline_always "you have declared `#[inline(always)]` on `fill_bytes`. This is usually a bad idea" +target/lintcheck/sources/rand-0.7.3/src/rngs/std.rs:54:5 clippy::inline_always "you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea" +target/lintcheck/sources/rand-0.7.3/src/rngs/std.rs:63:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_seed`. This is usually a bad idea" +target/lintcheck/sources/rand-0.7.3/src/rngs/std.rs:68:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_rng`. This is usually a bad idea" +target/lintcheck/sources/rand-0.7.3/src/rngs/thread.rs:57:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/rand-0.7.3/src/rngs/thread.rs:80:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/rand-0.7.3/src/rngs/thread.rs:80:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/rand-0.7.3/src/rngs/thread.rs:80:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/rand-0.7.3/src/rngs/thread.rs:81:35 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/rand-0.7.3/src/rngs/thread.rs:93:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea" +target/lintcheck/sources/rand-0.7.3/src/rngs/thread.rs:98:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea" +target/lintcheck/sources/rand-0.7.3/src/seq/index.rs:127:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/rand-0.7.3/src/seq/index.rs:139:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +target/lintcheck/sources/rand-0.7.3/src/seq/index.rs:159:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/rand-0.7.3/src/seq/index.rs:171:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +target/lintcheck/sources/rand-0.7.3/src/seq/index.rs:180:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +target/lintcheck/sources/rand-0.7.3/src/seq/index.rs:223:18 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +target/lintcheck/sources/rand-0.7.3/src/seq/index.rs:224:18 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +target/lintcheck/sources/rand-0.7.3/src/seq/index.rs:233:25 clippy::cast_precision_loss "casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide)" +target/lintcheck/sources/rand-0.7.3/src/seq/index.rs:236:27 clippy::cast_precision_loss "casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide)" +target/lintcheck/sources/rand-0.7.3/src/seq/index.rs:244:12 clippy::cast_precision_loss "casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide)" +target/lintcheck/sources/rand-0.7.3/src/seq/index.rs:244:37 clippy::cast_precision_loss "casting `u32` to `f32` causes a loss of precision (`u32` is 32 bits wide, but `f32`'s mantissa is only 23 bits wide)" +target/lintcheck/sources/rand-0.7.3/src/seq/index.rs:29:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/rand-0.7.3/src/seq/index.rs:39:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/rand-0.7.3/src/seq/index.rs:48:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/rand-0.7.3/src/seq/index.rs:60:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/rand-0.7.3/src/seq/index.rs:69:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/rand-0.7.3/src/seq/index.rs:78:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/rand-0.7.3/src/seq/index.rs:87:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/rand-0.7.3/src/seq/index.rs:87:5 clippy::should_implement_trait "method `into_iter` can be confused for the standard trait method `std::iter::IntoIterator::into_iter`" +target/lintcheck/sources/rand-0.7.3/src/seq/index.rs:97:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +target/lintcheck/sources/rand-0.7.3/src/seq/mod.rs:141:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/rand-0.7.3/src/seq/mod.rs:168:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/rand-0.7.3/src/seq/mod.rs:229:4 clippy::needless_doctest_main "needless `fn main` in doctest" +target/lintcheck/sources/rand-0.7.3/src/seq/mod.rs:292:29 clippy::cast_precision_loss "casting `usize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`usize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +target/lintcheck/sources/rand-0.7.3/src/seq/mod.rs:410:23 clippy::default_trait_access "calling `std::marker::PhantomData::default()` is more clear than this expression" +target/lintcheck/sources/rand-0.7.3/src/seq/mod.rs:45:4 clippy::needless_doctest_main "needless `fn main` in doctest" +target/lintcheck/sources/rand-0.7.3/src/seq/mod.rs:527:26 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +target/lintcheck/sources/rand_core-0.6.0/src/block.rs:117:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/rand_core-0.6.0/src/block.rs:153:5 clippy::inline_always "you have declared `#[inline(always)]` on `index`. This is usually a bad idea" +target/lintcheck/sources/rand_core-0.6.0/src/block.rs:230:5 clippy::inline_always "you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea" +target/lintcheck/sources/rand_core-0.6.0/src/block.rs:240:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_seed`. This is usually a bad idea" +target/lintcheck/sources/rand_core-0.6.0/src/block.rs:245:5 clippy::inline_always "you have declared `#[inline(always)]` on `seed_from_u64`. This is usually a bad idea" +target/lintcheck/sources/rand_core-0.6.0/src/block.rs:250:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_rng`. This is usually a bad idea" +target/lintcheck/sources/rand_core-0.6.0/src/block.rs:280:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/rand_core-0.6.0/src/block.rs:319:5 clippy::inline_always "you have declared `#[inline(always)]` on `index`. This is usually a bad idea" +target/lintcheck/sources/rand_core-0.6.0/src/block.rs:405:5 clippy::inline_always "you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea" +target/lintcheck/sources/rand_core-0.6.0/src/block.rs:415:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_seed`. This is usually a bad idea" +target/lintcheck/sources/rand_core-0.6.0/src/block.rs:420:5 clippy::inline_always "you have declared `#[inline(always)]` on `seed_from_u64`. This is usually a bad idea" +target/lintcheck/sources/rand_core-0.6.0/src/block.rs:425:5 clippy::inline_always "you have declared `#[inline(always)]` on `from_rng`. This is usually a bad idea" +target/lintcheck/sources/rand_core-0.6.0/src/block.rs:67:14 clippy::doc_markdown "you should put `module][crate::block` between ticks in the documentation" +target/lintcheck/sources/rand_core-0.6.0/src/block.rs:68:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/rand_core-0.6.0/src/error.rs:106:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/rand_core-0.6.0/src/error.rs:87:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/rand_core-0.6.0/src/error.rs:95:74 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +target/lintcheck/sources/rand_core-0.6.0/src/lib.rs:179:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/rand_core-0.6.0/src/lib.rs:301:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/rand_core-0.6.0/src/lib.rs:303:26 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/rand_core-0.6.0/src/lib.rs:304:26 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/rand_core-0.6.0/src/lib.rs:313:30 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +target/lintcheck/sources/rand_core-0.6.0/src/lib.rs:314:23 clippy::cast_possible_truncation "casting `u64` to `u32` may truncate the value" +target/lintcheck/sources/rand_core-0.6.0/src/lib.rs:346:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/rand_core-0.6.0/src/lib.rs:381:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u32`. This is usually a bad idea" +target/lintcheck/sources/rand_core-0.6.0/src/lib.rs:386:5 clippy::inline_always "you have declared `#[inline(always)]` on `next_u64`. This is usually a bad idea" +target/lintcheck/sources/rand_core-0.6.0/src/lib.rs:391:5 clippy::inline_always "you have declared `#[inline(always)]` on `fill_bytes`. This is usually a bad idea" +target/lintcheck/sources/rand_core-0.6.0/src/lib.rs:396:5 clippy::inline_always "you have declared `#[inline(always)]` on `try_fill_bytes`. This is usually a bad idea" +target/lintcheck/sources/rayon-1.5.0/src/collections/binary_heap.rs:7:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/collections/binary_heap.rs:8:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/collections/btree_map.rs:7:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/collections/btree_map.rs:8:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/collections/btree_set.rs:7:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/collections/btree_set.rs:8:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/collections/hash_map.rs:10:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/collections/hash_map.rs:9:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/collections/hash_set.rs:10:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/collections/hash_set.rs:9:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/collections/linked_list.rs:7:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/collections/linked_list.rs:8:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/collections/mod.rs:59:32 clippy::mem_replace_with_default "replacing a value of type `T` with `T::default()` is better expressed using `std::mem::take`" +target/lintcheck/sources/rayon-1.5.0/src/collections/vec_deque.rs:8:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/collections/vec_deque.rs:9:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/compile_fail/cannot_collect_filtermap_data.rs:2:1 clippy::needless_doctest_main "needless `fn main` in doctest" +target/lintcheck/sources/rayon-1.5.0/src/compile_fail/cannot_zip_filtered_data.rs:2:1 clippy::needless_doctest_main "needless `fn main` in doctest" +target/lintcheck/sources/rayon-1.5.0/src/compile_fail/cell_par_iter.rs:2:1 clippy::needless_doctest_main "needless `fn main` in doctest" +target/lintcheck/sources/rayon-1.5.0/src/compile_fail/no_send_par_iter.rs:25:1 clippy::needless_doctest_main "needless `fn main` in doctest" +target/lintcheck/sources/rayon-1.5.0/src/compile_fail/no_send_par_iter.rs:46:1 clippy::needless_doctest_main "needless `fn main` in doctest" +target/lintcheck/sources/rayon-1.5.0/src/compile_fail/no_send_par_iter.rs:4:1 clippy::needless_doctest_main "needless `fn main` in doctest" +target/lintcheck/sources/rayon-1.5.0/src/compile_fail/rc_par_iter.rs:2:1 clippy::needless_doctest_main "needless `fn main` in doctest" +target/lintcheck/sources/rayon-1.5.0/src/iter/chain.rs:103:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/chain.rs:122:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/chain.rs:128:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/chain.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/chain.rs:221:36 clippy::doc_markdown "you should put `ExactSizeIterator` between ticks in the documentation" +target/lintcheck/sources/rayon-1.5.0/src/iter/chain.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/chain.rs:51:38 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" +target/lintcheck/sources/rayon-1.5.0/src/iter/chain.rs:58:14 clippy::shadow_unrelated "`a` is being shadowed" +target/lintcheck/sources/rayon-1.5.0/src/iter/chain.rs:58:17 clippy::shadow_unrelated "`b` is being shadowed" +target/lintcheck/sources/rayon-1.5.0/src/iter/chain.rs:78:14 clippy::shadow_unrelated "`a` is being shadowed" +target/lintcheck/sources/rayon-1.5.0/src/iter/chain.rs:78:17 clippy::shadow_unrelated "`b` is being shadowed" +target/lintcheck/sources/rayon-1.5.0/src/iter/chain.rs:97:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/chunks.rs:29:9 clippy::inconsistent_struct_constructor "inconsistent struct constructor" +target/lintcheck/sources/rayon-1.5.0/src/iter/chunks.rs:3:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/chunks.rs:4:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/chunks.rs:77:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/chunks.rs:83:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/cloned.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/cloned.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/cloned.rs:71:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/cloned.rs:75:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/collect/consumer.rs:141:5 clippy::doc_markdown "you should put `CollectReducer` between ticks in the documentation" +target/lintcheck/sources/rayon-1.5.0/src/iter/collect/consumer.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/collect/consumer.rs:28:5 clippy::doc_markdown "you should put `CollectResult` between ticks in the documentation" +target/lintcheck/sources/rayon-1.5.0/src/iter/collect/consumer.rs:36:37 clippy::mut_mut "generally you want to avoid `&mut &mut _` if possible" +target/lintcheck/sources/rayon-1.5.0/src/iter/collect/consumer.rs:36:37 clippy::mut_mut "generally you want to avoid `&mut &mut _` if possible" +target/lintcheck/sources/rayon-1.5.0/src/iter/collect/mod.rs:154:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/rayon-1.5.0/src/iter/copied.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/copied.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/copied.rs:71:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/copied.rs:75:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/empty.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/empty.rs:24:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/rayon-1.5.0/src/iter/empty.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/enumerate.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/enumerate.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/enumerate.rs:64:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/enumerate.rs:68:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/extend.rs:143:63 clippy::linkedlist "you seem to be using a `LinkedList`! Perhaps you meant some other data structure?" +target/lintcheck/sources/rayon-1.5.0/src/iter/extend.rs:182:57 clippy::linkedlist "you seem to be using a `LinkedList`! Perhaps you meant some other data structure?" +target/lintcheck/sources/rayon-1.5.0/src/iter/extend.rs:218:32 clippy::linkedlist "you seem to be using a `LinkedList`! Perhaps you meant some other data structure?" +target/lintcheck/sources/rayon-1.5.0/src/iter/extend.rs:218:59 clippy::linkedlist "you seem to be using a `LinkedList`! Perhaps you meant some other data structure?" +target/lintcheck/sources/rayon-1.5.0/src/iter/extend.rs:25:42 clippy::linkedlist "you seem to be using a `LinkedList`! Perhaps you meant some other data structure?" +target/lintcheck/sources/rayon-1.5.0/src/iter/extend.rs:287:62 clippy::linkedlist "you seem to be using a `LinkedList`! Perhaps you meant some other data structure?" +target/lintcheck/sources/rayon-1.5.0/src/iter/extend.rs:322:56 clippy::linkedlist "you seem to be using a `LinkedList`! Perhaps you meant some other data structure?" +target/lintcheck/sources/rayon-1.5.0/src/iter/extend.rs:41:27 clippy::linkedlist "you seem to be using a `LinkedList`! Perhaps you meant some other data structure?" +target/lintcheck/sources/rayon-1.5.0/src/iter/extend.rs:47:30 clippy::linkedlist "you seem to be using a `LinkedList`! Perhaps you meant some other data structure?" +target/lintcheck/sources/rayon-1.5.0/src/iter/extend.rs:47:56 clippy::linkedlist "you seem to be using a `LinkedList`! Perhaps you meant some other data structure?" +target/lintcheck/sources/rayon-1.5.0/src/iter/extend.rs:47:74 clippy::linkedlist "you seem to be using a `LinkedList`! Perhaps you meant some other data structure?" +target/lintcheck/sources/rayon-1.5.0/src/iter/extend.rs:53:29 clippy::linkedlist "you seem to be using a `LinkedList`! Perhaps you meant some other data structure?" +target/lintcheck/sources/rayon-1.5.0/src/iter/extend.rs:57:36 clippy::linkedlist "you seem to be using a `LinkedList`! Perhaps you meant some other data structure?" +target/lintcheck/sources/rayon-1.5.0/src/iter/extend.rs:59:61 clippy::linkedlist "you seem to be using a `LinkedList`! Perhaps you meant some other data structure?" +target/lintcheck/sources/rayon-1.5.0/src/iter/filter.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/filter.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/filter_map.rs:123:9 clippy::option_if_let_else "use Option::map_or instead of an if let/else" +target/lintcheck/sources/rayon-1.5.0/src/iter/filter_map.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/filter_map.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/find.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/find.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/find_first_last/mod.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/find_first_last/mod.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/find_first_last/mod.rs:32:67 clippy::doc_markdown "you should put `MatchPosition` between ticks in the documentation" +target/lintcheck/sources/rayon-1.5.0/src/iter/flat_map.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/flat_map.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/flat_map_iter.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/flat_map_iter.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/flatten.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/flatten.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/flatten_iter.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/flatten_iter.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/fold.rs:158:13 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/rayon-1.5.0/src/iter/fold.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/fold.rs:204:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/rayon-1.5.0/src/iter/fold.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/for_each.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/for_each.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/inspect.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/inspect.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/inspect.rs:83:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/inspect.rs:88:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/interleave.rs:111:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/interleave.rs:119:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/interleave.rs:195:30 clippy::doc_markdown "you should put `self.i_len` between ticks in the documentation" +target/lintcheck/sources/rayon-1.5.0/src/iter/interleave.rs:195:43 clippy::doc_markdown "you should put `self.j_len` between ticks in the documentation" +target/lintcheck/sources/rayon-1.5.0/src/iter/interleave.rs:199:23 clippy::doc_markdown "you should put `self.i_len` between ticks in the documentation" +target/lintcheck/sources/rayon-1.5.0/src/iter/interleave.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/interleave.rs:200:23 clippy::doc_markdown "you should put `self.j_len` between ticks in the documentation" +target/lintcheck/sources/rayon-1.5.0/src/iter/interleave.rs:249:41 clippy::doc_markdown "you should put `DoubleEndedIterator` between ticks in the documentation" +target/lintcheck/sources/rayon-1.5.0/src/iter/interleave.rs:250:5 clippy::doc_markdown "you should put `ExactSizeIterator` between ticks in the documentation" +target/lintcheck/sources/rayon-1.5.0/src/iter/interleave.rs:263:33 clippy::doc_markdown "you should put `InterleaveSeq` between ticks in the documentation" +target/lintcheck/sources/rayon-1.5.0/src/iter/interleave.rs:280:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +target/lintcheck/sources/rayon-1.5.0/src/iter/interleave.rs:285:17 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +target/lintcheck/sources/rayon-1.5.0/src/iter/interleave.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/interleave.rs:313:9 clippy::comparison_chain "`if` chain can be rewritten with `match`" +target/lintcheck/sources/rayon-1.5.0/src/iter/interleave.rs:82:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/interleave.rs:90:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/interleave_shortest.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/intersperse.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/intersperse.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/intersperse.rs:90:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/intersperse.rs:96:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/len.rs:12:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/rayon-1.5.0/src/iter/len.rs:146:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/rayon-1.5.0/src/iter/len.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/len.rs:200:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/len.rs:205:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/len.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/len.rs:66:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/len.rs:71:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/map.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/map.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/map.rs:84:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/map.rs:89:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/map_with.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/map_with.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/map_with.rs:419:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/map_with.rs:425:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/map_with.rs:90:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/map_with.rs:96:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/mod.rs:1874:24 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +target/lintcheck/sources/rayon-1.5.0/src/iter/mod.rs:2171:1 clippy::len_without_is_empty "trait `IndexedParallelIterator` has a `len` method but no (possibly inherited) `is_empty` method" +target/lintcheck/sources/rayon-1.5.0/src/iter/mod.rs:2371:26 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +target/lintcheck/sources/rayon-1.5.0/src/iter/mod.rs:2411:26 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +target/lintcheck/sources/rayon-1.5.0/src/iter/mod.rs:82:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/multizip.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/multizip.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/noop.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/once.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/once.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/panic_fuse.rs:102:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/panic_fuse.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/panic_fuse.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/panic_fuse.rs:98:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/par_bridge.rs:136:28 clippy::redundant_else "redundant else block" +target/lintcheck/sources/rayon-1.5.0/src/iter/par_bridge.rs:163:28 clippy::redundant_else "redundant else block" +target/lintcheck/sources/rayon-1.5.0/src/iter/plumbing/mod.rs:216:58 clippy::doc_markdown "you should put `find_first` between ticks in the documentation" +target/lintcheck/sources/rayon-1.5.0/src/iter/plumbing/mod.rs:359:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/plumbing/mod.rs:364:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/plumbing/mod.rs:399:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/plumbing/mod.rs:53:19 clippy::doc_markdown "you should put `DoubleEndedIterator` between ticks in the documentation" +target/lintcheck/sources/rayon-1.5.0/src/iter/plumbing/mod.rs:53:43 clippy::doc_markdown "you should put `ExactSizeIterator` between ticks in the documentation" +target/lintcheck/sources/rayon-1.5.0/src/iter/plumbing/mod.rs:54:31 clippy::doc_markdown "you should put `IntoIterator` between ticks in the documentation" +target/lintcheck/sources/rayon-1.5.0/src/iter/plumbing/mod.rs:55:5 clippy::doc_markdown "you should put `IntoIterator` between ticks in the documentation" +target/lintcheck/sources/rayon-1.5.0/src/iter/positions.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/positions.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/product.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/reduce.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/repeat.rs:103:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/rayon-1.5.0/src/iter/repeat.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/repeat.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/rev.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/rev.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/rev.rs:63:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/rev.rs:68:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/skip.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/skip.rs:3:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/skip.rs:68:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/skip.rs:73:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/splitter.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/splitter.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/step_by.rs:4:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/step_by.rs:5:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/step_by.rs:73:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/step_by.rs:79:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/sum.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/take.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/take.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/take.rs:67:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/take.rs:72:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/try_fold.rs:190:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/rayon-1.5.0/src/iter/try_fold.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/try_fold.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/try_reduce.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/try_reduce_with.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/unzip.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/unzip.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/update.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/update.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/update.rs:82:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/update.rs:87:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/while_some.rs:130:22 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/rayon-1.5.0/src/iter/while_some.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/while_some.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/zip.rs:102:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/zip.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/zip.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/zip.rs:74:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/zip.rs:79:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/zip.rs:97:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/iter/zip_eq.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/iter/zip_eq.rs:2:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/option.rs:8:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/option.rs:9:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/par_either.rs:1:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/par_either.rs:3:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/private.rs:9:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/rayon-1.5.0/src/range.rs:19:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/range.rs:20:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/range_inclusive.rs:194:9 clippy::range_plus_one "an inclusive range would be more readable" +target/lintcheck/sources/rayon-1.5.0/src/range_inclusive.rs:194:9 clippy::range_plus_one "an inclusive range would be more readable" +target/lintcheck/sources/rayon-1.5.0/src/range_inclusive.rs:19:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/range_inclusive.rs:209:9 clippy::range_plus_one "an inclusive range would be more readable" +target/lintcheck/sources/rayon-1.5.0/src/range_inclusive.rs:209:9 clippy::range_plus_one "an inclusive range would be more readable" +target/lintcheck/sources/rayon-1.5.0/src/range_inclusive.rs:20:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/range_inclusive.rs:231:9 clippy::range_plus_one "an inclusive range would be more readable" +target/lintcheck/sources/rayon-1.5.0/src/range_inclusive.rs:231:9 clippy::range_plus_one "an inclusive range would be more readable" +target/lintcheck/sources/rayon-1.5.0/src/result.rs:8:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/result.rs:9:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/slice/mergesort.rs:102:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/slice/mergesort.rs:109:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/slice/mergesort.rs:114:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/slice/mergesort.rs:211:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/slice/mergesort.rs:217:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/slice/mergesort.rs:251:5 clippy::doc_markdown "you should put `TimSort` between ticks in the documentation" +target/lintcheck/sources/rayon-1.5.0/src/slice/mergesort.rs:252:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +target/lintcheck/sources/rayon-1.5.0/src/slice/mergesort.rs:286:59 clippy::doc_markdown "you should put `TimSort` between ticks in the documentation" +target/lintcheck/sources/rayon-1.5.0/src/slice/mergesort.rs:333:24 clippy::redundant_else "redundant else block" +target/lintcheck/sources/rayon-1.5.0/src/slice/mergesort.rs:513:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/slice/mergesort.rs:521:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/slice/mergesort.rs:7:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/slice/mergesort.rs:98:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/slice/mod.rs:15:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/slice/mod.rs:16:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/slice/mod.rs:17:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/slice/mod.rs:25:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/rayon-1.5.0/src/slice/mod.rs:657:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/rayon-1.5.0/src/slice/mod.rs:971:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/rayon-1.5.0/src/slice/quicksort.rs:230:36 clippy::doc_markdown "you should put `BlockQuicksort` between ticks in the documentation" +target/lintcheck/sources/rayon-1.5.0/src/slice/quicksort.rs:233:1 clippy::too_many_lines "this function has too many lines (117/100)" +target/lintcheck/sources/rayon-1.5.0/src/slice/quicksort.rs:258:26 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +target/lintcheck/sources/rayon-1.5.0/src/slice/quicksort.rs:265:26 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +target/lintcheck/sources/rayon-1.5.0/src/slice/quicksort.rs:268:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/rayon-1.5.0/src/slice/quicksort.rs:308:30 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" +target/lintcheck/sources/rayon-1.5.0/src/slice/quicksort.rs:325:30 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" +target/lintcheck/sources/rayon-1.5.0/src/slice/quicksort.rs:393:36 clippy::cast_possible_wrap "casting `u8` to `isize` may wrap around the value on targets with 32-bit wide pointers" +target/lintcheck/sources/rayon-1.5.0/src/slice/quicksort.rs:405:40 clippy::cast_possible_wrap "casting `u8` to `isize` may wrap around the value on targets with 32-bit wide pointers" +target/lintcheck/sources/rayon-1.5.0/src/slice/quicksort.rs:430:14 clippy::shadow_unrelated "`pivot` is being shadowed" +target/lintcheck/sources/rayon-1.5.0/src/slice/quicksort.rs:439:13 clippy::shadow_unrelated "`pivot` is being shadowed" +target/lintcheck/sources/rayon-1.5.0/src/slice/quicksort.rs:482:10 clippy::shadow_unrelated "`pivot` is being shadowed" +target/lintcheck/sources/rayon-1.5.0/src/slice/quicksort.rs:491:9 clippy::shadow_unrelated "`pivot` is being shadowed" +target/lintcheck/sources/rayon-1.5.0/src/slice/quicksort.rs:534:26 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +target/lintcheck/sources/rayon-1.5.0/src/slice/quicksort.rs:545:17 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +target/lintcheck/sources/rayon-1.5.0/src/slice/quicksort.rs:588:17 clippy::identity_op "the operation is ineffective. Consider reducing it to `len / 4`" +target/lintcheck/sources/rayon-1.5.0/src/slice/quicksort.rs:716:14 clippy::shadow_unrelated "`pivot` is being shadowed" +target/lintcheck/sources/rayon-1.5.0/src/split_producer.rs:56:16 clippy::option_if_let_else "use Option::map_or_else instead of an if let/else" +target/lintcheck/sources/rayon-1.5.0/src/split_producer.rs:92:9 clippy::option_if_let_else "use Option::map_or instead of an if let/else" +target/lintcheck/sources/rayon-1.5.0/src/str.rs:16:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/str.rs:17:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/str.rs:18:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/str.rs:25:5 clippy::cast_possible_wrap "casting `u8` to `i8` may wrap around the value" +target/lintcheck/sources/rayon-1.5.0/src/str.rs:715:9 clippy::manual_strip "stripping a suffix manually" +target/lintcheck/sources/rayon-1.5.0/src/string.rs:5:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/vec.rs:137:12 clippy::len_zero "length comparison to zero" +target/lintcheck/sources/rayon-1.5.0/src/vec.rs:8:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/rayon-1.5.0/src/vec.rs:9:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/regex-1.3.2/src/backtrack.rs:100:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/backtrack.rs:133:17 clippy::same_item_push "it looks like the same item is being pushed into this Vec" +target/lintcheck/sources/regex-1.3.2/src/backtrack.rs:145:20 clippy::if_not_else "unnecessary boolean `not` operation" +target/lintcheck/sources/regex-1.3.2/src/backtrack.rs:199:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +target/lintcheck/sources/regex-1.3.2/src/backtrack.rs:223:29 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/backtrack.rs:230:66 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/backtrack.rs:284:21 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" +target/lintcheck/sources/regex-1.3.2/src/backtrack.rs:287:5 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +target/lintcheck/sources/regex-1.3.2/src/backtrack.rs:97:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/backtrack.rs:98:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/backtrack.rs:99:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:1005:32 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:1006:21 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:1008:18 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:1009:18 clippy::cast_lossless "casting `u8` to `u64` may become silently lossy if you later change the type" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:1010:9 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:102:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:1037:37 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:1037:55 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:1040:28 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:1040:38 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:1051:25 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:1071:8 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:112:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:154:30 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:156:30 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:185:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:187:40 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:201:53 clippy::doc_markdown "you should put `MaybeInsts` between ticks in the documentation" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:241:63 clippy::doc_markdown "you should put `c_concat` between ticks in the documentation" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:245:5 clippy::too_many_lines "this function has too many lines (111/100)" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:247:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:373:24 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:373:36 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:378:12 clippy::if_not_else "unnecessary boolean `not` operation" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:400:37 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:407:51 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:409:24 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:417:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:42:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:42:5 clippy::new_without_default "you should consider adding a `Default` implementation for `compile::Compiler`" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:444:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:445:57 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:446:20 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:466:20 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:466:32 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:519:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:55:57 clippy::doc_markdown "you should put `size_limit` between ticks in the documentation" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:58:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:748:41 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:74:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:751:54 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:765:41 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:765:55 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:825:39 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:825:51 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:828:49 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:828:61 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:830:59 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:830:71 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:832:43 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:835:41 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:835:53 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:835:67 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:83:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:896:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:905:17 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:953:17 clippy::doc_markdown "you should put `HashMap` between ticks in the documentation" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:95:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:980:26 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:994:44 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/compile.rs:994:54 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1007:17 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1010:22 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1059:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1060:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1084:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1087:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1090:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1093:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1096:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1101:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1104:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1107:38 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1117:30 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1120:47 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1121:30 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1129:13 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1134:13 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1185:68 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1193:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1244:50 clippy::doc_markdown "you should put `current_state` between ticks in the documentation" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1338:58 clippy::doc_markdown "you should put `STATE_DEAD` between ticks in the documentation" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1339:9 clippy::doc_markdown "you should put `STATE_UNKNOWN` between ticks in the documentation" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1366:25 clippy::doc_markdown "you should put `STATE_DEAD` between ticks in the documentation" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1366:46 clippy::doc_markdown "you should put `STATE_UNKNOWN` between ticks in the documentation" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1367:41 clippy::inline_always "you have declared `#[inline(always)]` on `start_state`. This is usually a bad idea" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1380:14 clippy::identity_op "the operation is ineffective. Consider reducing it to `(empty_flags.start as u8)`" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1388:15 clippy::match_on_vec_items "indexing into a vector may panic" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1412:20 clippy::unused_self "unused `self` argument" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1438:9 clippy::unused_self "unused `self` argument" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1472:9 clippy::doc_markdown "you should put `StatePtr` between ticks in the documentation" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1490:54 clippy::cast_possible_truncation "casting `i32` to `u8` may truncate the value" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1490:54 clippy::cast_sign_loss "casting `i32` to `u8` may lose the sign of the value" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1521:20 clippy::doc_markdown "you should put `num_byte_classes` between ticks in the documentation" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1529:41 clippy::inline_always "you have declared `#[inline(always)]` on `byte_class`. This is usually a bad idea" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1537:14 clippy::doc_markdown "you should put `byte_class` between ticks in the documentation" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1538:41 clippy::inline_always "you have declared `#[inline(always)]` on `u8_class`. This is usually a bad idea" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1562:18 clippy::doc_markdown "you should put `STATE_START` between ticks in the documentation" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1614:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1651:38 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1700:17 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1701:18 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1705:19 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1708:16 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1709:18 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1713:19 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1716:18 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1717:18 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1721:19 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1727:14 clippy::cast_lossless "casting `u8` to `u16` may become silently lossy if you later change the type" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1732:15 clippy::trivially_copy_pass_by_ref "this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1736:22 clippy::trivially_copy_pass_by_ref "this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1741:9 clippy::match_like_matches_macro "match expression looks like `matches!` macro" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1747:16 clippy::trivially_copy_pass_by_ref "this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1751:18 clippy::cast_possible_truncation "casting `u16` to `u8` may truncate the value" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1815:38 clippy::cast_possible_truncation "casting `usize` to `u8` may truncate the value" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1821:21 clippy::cast_lossless "casting `u32` to `u64` may become silently lossy if you later change the type" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1824:5 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1848:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1850:18 clippy::cast_sign_loss "casting `i32` to `u32` may lose the sign of the value" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1857:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1860:17 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1867:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1870:19 clippy::cast_possible_truncation "casting `u32` to `u8` may truncate the value" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1873:15 clippy::cast_possible_truncation "casting `u32` to `u8` may truncate the value" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1876:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1882:26 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:1884:15 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:277:17 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:277:31 clippy::cast_possible_wrap "casting `u32` to `i32` may wrap around the value" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:295:20 clippy::cast_possible_truncation "casting `usize` to `i32` may truncate the value on targets with 64-bit wide pointers" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:295:20 clippy::cast_possible_wrap "casting `usize` to `i32` may wrap around the value on targets with 32-bit wide pointers" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:299:21 clippy::cast_sign_loss "casting `i32` to `usize` may lose the sign of the value" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:34:46 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:398:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:446:41 clippy::inline_always "you have declared `#[inline(always)]` on `forward`. This is usually a bad idea" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:457:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:459:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:460:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:476:41 clippy::inline_always "you have declared `#[inline(always)]` on `reverse`. This is usually a bad idea" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:487:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:489:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:490:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:506:41 clippy::inline_always "you have declared `#[inline(always)]` on `forward_many`. This is usually a bad idea" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:518:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:520:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:554:41 clippy::inline_always "you have declared `#[inline(always)]` on `exec_at`. This is usually a bad idea" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:555:5 clippy::too_many_lines "this function has too many lines (101/100)" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:58:9 clippy::enum_glob_use "usage of wildcard import for enum variants" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:667:21 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:747:41 clippy::inline_always "you have declared `#[inline(always)]` on `exec_at_reverse`. This is usually a bad idea" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:795:21 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:848:9 clippy::doc_markdown "you should put `next_si` between ticks in the documentation" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:852:41 clippy::inline_always "you have declared `#[inline(always)]` on `next_si`. This is usually a bad idea" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:885:12 clippy::doc_markdown "you should put `STATE_DEAD` between ticks in the documentation" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:889:9 clippy::doc_markdown "you should put `STATE_UNKNOWN` between ticks in the documentation" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:897:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +target/lintcheck/sources/regex-1.3.2/src/dfa.rs:979:29 clippy::cast_possible_truncation "casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers" +target/lintcheck/sources/regex-1.3.2/src/error.rs:6:1 clippy::manual_non_exhaustive "this seems like a manual implementation of the non-exhaustive pattern" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:1000:14 clippy::doc_markdown "you should put `captures_nfa` between ticks in the documentation" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:100:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:1028:5 clippy::too_many_arguments "this function has too many arguments (9/7)" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:1039:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:1144:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:1179:26 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:122:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:1250:41 clippy::inline_always "you have declared `#[inline(always)]` on `searcher`. This is usually a bad idea" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:1260:41 clippy::inline_always "you have declared `#[inline(always)]` on `searcher_str`. This is usually a bad idea" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:1270:17 clippy::doc_markdown "you should put `RegexSet` between ticks in the documentation" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:1280:17 clippy::doc_markdown "you should put `RegexSet` between ticks in the documentation" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:137:9 clippy::field_reassign_with_default "field assignment outside of initializer for an instance created with Default::default()" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:142:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:158:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:168:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:181:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:195:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:204:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:210:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:245:62 clippy::if_same_then_else "this `if` has identical blocks" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:251:21 clippy::if_not_else "unnecessary boolean `not` operation" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:262:60 clippy::if_same_then_else "this `if` has identical blocks" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:268:21 clippy::if_not_else "unnecessary boolean `not` operation" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:278:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:281:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:286:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:300:30 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:308:17 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:329:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:330:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:331:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:334:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:340:19 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:344:27 clippy::unused_self "unused `self` argument" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:383:41 clippy::inline_always "you have declared `#[inline(always)]` on `shortest_match_at`. This is usually a bad idea" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:388:41 clippy::inline_always "you have declared `#[inline(always)]` on `is_match_at`. This is usually a bad idea" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:393:41 clippy::inline_always "you have declared `#[inline(always)]` on `find_at`. This is usually a bad idea" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:398:41 clippy::inline_always "you have declared `#[inline(always)]` on `captures_read_at`. This is usually a bad idea" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:425:41 clippy::inline_always "you have declared `#[inline(always)]` on `shortest_match_at`. This is usually a bad idea" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:44:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:473:9 clippy::doc_markdown "you should put `shortest_match(...).is_some` between ticks in the documentation" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:474:41 clippy::inline_always "you have declared `#[inline(always)]` on `is_match_at`. This is usually a bad idea" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:524:41 clippy::inline_always "you have declared `#[inline(always)]` on `find_at`. This is usually a bad idea" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:52:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:686:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:727:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:767:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:783:41 clippy::inline_always "you have declared `#[inline(always)]` on `shortest_dfa`. This is usually a bad idea" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:791:41 clippy::inline_always "you have declared `#[inline(always)]` on `shortest_dfa_reverse_suffix`. This is usually a bad idea" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:823:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:868:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:897:31 clippy::doc_markdown "you should put `shortest_nfa(...).is_some` between ticks in the documentation" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:899:9 clippy::doc_markdown "you should put `shortest_nfa` between ticks in the documentation" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:905:14 clippy::doc_markdown "you should put `match_nfa` between ticks in the documentation" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:930:14 clippy::doc_markdown "you should put `shortest_nfa` between ticks in the documentation" +target/lintcheck/sources/regex-1.3.2/src/exec.rs:981:14 clippy::doc_markdown "you should put `find_nfa` between ticks in the documentation" +target/lintcheck/sources/regex-1.3.2/src/expand.rs:170:27 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +target/lintcheck/sources/regex-1.3.2/src/expand.rs:171:5 clippy::match_like_matches_macro "match expression looks like `matches!` macro" +target/lintcheck/sources/regex-1.3.2/src/expand.rs:22:13 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +target/lintcheck/sources/regex-1.3.2/src/expand.rs:27:23 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/regex-1.3.2/src/expand.rs:30:17 clippy::single_char_add_str "calling `push_str()` using a single-character string literal" +target/lintcheck/sources/regex-1.3.2/src/expand.rs:38:30 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +target/lintcheck/sources/regex-1.3.2/src/expand.rs:42:21 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +target/lintcheck/sources/regex-1.3.2/src/expand.rs:50:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/regex-1.3.2/src/expand.rs:69:23 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/regex-1.3.2/src/expand.rs:80:28 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +target/lintcheck/sources/regex-1.3.2/src/expand.rs:84:21 clippy::map_unwrap_or "called `map().unwrap_or()` on an `Option` value. This can be done more directly by calling `map_or(, )` instead" +target/lintcheck/sources/regex-1.3.2/src/expand.rs:8:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/regex-1.3.2/src/input.rs:142:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/regex-1.3.2/src/input.rs:146:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/input.rs:15:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/regex-1.3.2/src/input.rs:165:31 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/input.rs:178:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +target/lintcheck/sources/regex-1.3.2/src/input.rs:228:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/regex-1.3.2/src/input.rs:236:21 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/input.rs:236:33 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/input.rs:24:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/input.rs:271:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +target/lintcheck/sources/regex-1.3.2/src/input.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/input.rs:362:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/input.rs:370:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/input.rs:371:42 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/regex-1.3.2/src/input.rs:37:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/input.rs:388:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/input.rs:42:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/input.rs:47:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/input.rs:53:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/input.rs:58:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/input.rs:63:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/lib.rs:1:null clippy::cargo_common_metadata "package `regex` is missing `package.keywords` metadata" +target/lintcheck/sources/regex-1.3.2/src/literal/imp.rs:101:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/literal/imp.rs:114:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/literal/imp.rs:127:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/literal/imp.rs:139:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/literal/imp.rs:144:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/literal/imp.rs:149:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/literal/imp.rs:154:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/literal/imp.rs:155:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +target/lintcheck/sources/regex-1.3.2/src/literal/imp.rs:160:30 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/regex-1.3.2/src/literal/imp.rs:167:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/literal/imp.rs:168:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +target/lintcheck/sources/regex-1.3.2/src/literal/imp.rs:211:20 clippy::redundant_else "redundant else block" +target/lintcheck/sources/regex-1.3.2/src/literal/imp.rs:276:50 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/regex-1.3.2/src/literal/imp.rs:342:41 clippy::inline_always "you have declared `#[inline(always)]` on `find`. This is usually a bad idea" +target/lintcheck/sources/regex-1.3.2/src/literal/imp.rs:435:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/literal/imp.rs:436:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/literal/imp.rs:437:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/literal/imp.rs:438:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/literal/imp.rs:439:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/literal/imp.rs:440:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/literal/imp.rs:455:41 clippy::inline_always "you have declared `#[inline(always)]` on `find`. This is usually a bad idea" +target/lintcheck/sources/regex-1.3.2/src/literal/imp.rs:46:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/literal/imp.rs:481:41 clippy::inline_always "you have declared `#[inline(always)]` on `is_suffix`. This is usually a bad idea" +target/lintcheck/sources/regex-1.3.2/src/literal/imp.rs:51:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/literal/imp.rs:579:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/literal/imp.rs:57:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/literal/imp.rs:580:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/literal/imp.rs:583:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/literal/imp.rs:602:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/regex-1.3.2/src/literal/imp.rs:622:24 clippy::redundant_else "redundant else block" +target/lintcheck/sources/regex-1.3.2/src/literal/imp.rs:62:18 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +target/lintcheck/sources/regex-1.3.2/src/literal/imp.rs:637:24 clippy::redundant_else "redundant else block" +target/lintcheck/sources/regex-1.3.2/src/literal/imp.rs:648:9 clippy::needless_return "unneeded `return` statement" +target/lintcheck/sources/regex-1.3.2/src/literal/imp.rs:651:44 clippy::doc_markdown "you should put `BoyerMooreSearch` between ticks in the documentation" +target/lintcheck/sources/regex-1.3.2/src/literal/imp.rs:65:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/literal/imp.rs:68:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/literal/imp.rs:783:32 clippy::redundant_else "redundant else block" +target/lintcheck/sources/regex-1.3.2/src/literal/imp.rs:786:42 clippy::manual_saturating_arithmetic "manual saturating arithmetic" +target/lintcheck/sources/regex-1.3.2/src/literal/imp.rs:78:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/literal/imp.rs:84:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/literal/imp.rs:850:20 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/regex-1.3.2/src/literal/imp.rs:85:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +target/lintcheck/sources/regex-1.3.2/src/pikevm.rs:103:15 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/pikevm.rs:103:52 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/pikevm.rs:114:5 clippy::too_many_arguments "this function has too many arguments (8/7)" +target/lintcheck/sources/regex-1.3.2/src/pikevm.rs:117:13 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/regex-1.3.2/src/pikevm.rs:124:17 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/regex-1.3.2/src/pikevm.rs:220:9 clippy::doc_markdown "you should put `thread_caps` between ticks in the documentation" +target/lintcheck/sources/regex-1.3.2/src/pikevm.rs:222:16 clippy::doc_markdown "you should put `at_next` between ticks in the documentation" +target/lintcheck/sources/regex-1.3.2/src/pikevm.rs:223:9 clippy::doc_markdown "you should put `at_next` between ticks in the documentation" +target/lintcheck/sources/regex-1.3.2/src/pikevm.rs:224:5 clippy::too_many_arguments "this function has too many arguments (8/7)" +target/lintcheck/sources/regex-1.3.2/src/pikevm.rs:234:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +target/lintcheck/sources/regex-1.3.2/src/pikevm.rs:303:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +target/lintcheck/sources/regex-1.3.2/src/pikevm.rs:331:29 clippy::mut_mut "this expression mutably borrows a mutable reference. Consider reborrowing" +target/lintcheck/sources/regex-1.3.2/src/pikevm.rs:88:5 clippy::too_many_arguments "this function has too many arguments (8/7)" +target/lintcheck/sources/regex-1.3.2/src/prog.rs:102:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/prog.rs:113:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/prog.rs:120:9 clippy::match_like_matches_macro "match expression looks like `matches!` macro" +target/lintcheck/sources/regex-1.3.2/src/prog.rs:128:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/prog.rs:134:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/prog.rs:141:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/prog.rs:147:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/prog.rs:164:41 clippy::inline_always "you have declared `#[inline(always)]` on `deref`. This is usually a bad idea" +target/lintcheck/sources/regex-1.3.2/src/prog.rs:172:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +target/lintcheck/sources/regex-1.3.2/src/prog.rs:18:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +target/lintcheck/sources/regex-1.3.2/src/prog.rs:236:13 clippy::write_with_newline "using `write!()` with a format string that ends in a single newline" +target/lintcheck/sources/regex-1.3.2/src/prog.rs:300:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/prog.rs:301:9 clippy::match_like_matches_macro "match expression looks like `matches!` macro" +target/lintcheck/sources/regex-1.3.2/src/prog.rs:382:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/prog.rs:409:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/prog.rs:80:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/prog.rs:80:5 clippy::new_without_default "you should consider adding a `Default` implementation for `prog::Program`" +target/lintcheck/sources/regex-1.3.2/src/re_builder.rs:267:17 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/regex-1.3.2/src/re_builder.rs:267:17 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/regex-1.3.2/src/re_builder.rs:4:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +target/lintcheck/sources/regex-1.3.2/src/re_builder.rs:57:17 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/re_builder.rs:57:17 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/re_builder.rs:68:17 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/regex-1.3.2/src/re_builder.rs:68:17 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/regex-1.3.2/src/re_bytes.rs:1017:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +target/lintcheck/sources/regex-1.3.2/src/re_bytes.rs:1039:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +target/lintcheck/sources/regex-1.3.2/src/re_bytes.rs:1093:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +target/lintcheck/sources/regex-1.3.2/src/re_bytes.rs:1118:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +target/lintcheck/sources/regex-1.3.2/src/re_bytes.rs:1133:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +target/lintcheck/sources/regex-1.3.2/src/re_bytes.rs:118:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/regex-1.3.2/src/re_bytes.rs:256:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/re_bytes.rs:29:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/re_bytes.rs:35:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/re_bytes.rs:42:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/re_bytes.rs:483:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/regex-1.3.2/src/re_bytes.rs:48:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/re_bytes.rs:558:29 clippy::doc_markdown "you should put `shortest_match` between ticks in the documentation" +target/lintcheck/sources/regex-1.3.2/src/re_bytes.rs:55:33 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/re_bytes.rs:55:47 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/re_bytes.rs:572:29 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" +target/lintcheck/sources/regex-1.3.2/src/re_bytes.rs:720:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/re_bytes.rs:817:5 clippy::doc_markdown "you should put `CaptureLocations` between ticks in the documentation" +target/lintcheck/sources/regex-1.3.2/src/re_bytes.rs:843:1 clippy::len_without_is_empty "item `re_bytes::CaptureLocations` has a public `len` method but no corresponding `is_empty` method" +target/lintcheck/sources/regex-1.3.2/src/re_bytes.rs:849:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/re_bytes.rs:858:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/re_bytes.rs:869:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/re_bytes.rs:891:1 clippy::len_without_is_empty "item `re_bytes::Captures<'t>` has a public `len` method but no corresponding `is_empty` method" +target/lintcheck/sources/regex-1.3.2/src/re_bytes.rs:911:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/re_bytes.rs:917:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/re_bytes.rs:926:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/re_bytes.rs:955:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/re_set.rs:179:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/re_set.rs:179:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/re_set.rs:251:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/re_set.rs:251:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/re_set.rs:263:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/re_set.rs:263:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/re_set.rs:268:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/re_set.rs:268:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/re_set.rs:277:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/re_set.rs:277:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/re_set.rs:94:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/regex-1.3.2/src/re_set.rs:94:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/regex-1.3.2/src/re_trait.rs:136:29 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/re_unicode.rs:1019:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +target/lintcheck/sources/regex-1.3.2/src/re_unicode.rs:1041:9 clippy::map_unwrap_or "called `map().unwrap_or_else()` on an `Option` value. This can be done more directly by calling `map_or_else(, )` instead" +target/lintcheck/sources/regex-1.3.2/src/re_unicode.rs:1088:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/re_unicode.rs:1135:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +target/lintcheck/sources/regex-1.3.2/src/re_unicode.rs:1160:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +target/lintcheck/sources/regex-1.3.2/src/re_unicode.rs:174:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/regex-1.3.2/src/re_unicode.rs:21:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/re_unicode.rs:313:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/re_unicode.rs:38:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/re_unicode.rs:44:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/re_unicode.rs:51:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/re_unicode.rs:533:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/regex-1.3.2/src/re_unicode.rs:57:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/re_unicode.rs:617:29 clippy::doc_markdown "you should put `shortest_match` between ticks in the documentation" +target/lintcheck/sources/regex-1.3.2/src/re_unicode.rs:631:29 clippy::doc_markdown "you should put `is_match` between ticks in the documentation" +target/lintcheck/sources/regex-1.3.2/src/re_unicode.rs:64:33 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/re_unicode.rs:64:47 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/regex-1.3.2/src/re_unicode.rs:834:5 clippy::doc_markdown "you should put `CaptureLocations` between ticks in the documentation" +target/lintcheck/sources/regex-1.3.2/src/re_unicode.rs:860:1 clippy::len_without_is_empty "item `re_unicode::CaptureLocations` has a public `len` method but no corresponding `is_empty` method" +target/lintcheck/sources/regex-1.3.2/src/re_unicode.rs:866:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/re_unicode.rs:875:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/re_unicode.rs:886:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/re_unicode.rs:908:1 clippy::len_without_is_empty "item `re_unicode::Captures<'t>` has a public `len` method but no corresponding `is_empty` method" +target/lintcheck/sources/regex-1.3.2/src/re_unicode.rs:928:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/re_unicode.rs:934:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/re_unicode.rs:943:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/re_unicode.rs:972:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/regex-1.3.2/src/sparse.rs:10:37 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +target/lintcheck/sources/regex-1.3.2/src/sparse.rs:15:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/regex-1.3.2/src/utf8.rs:100:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +target/lintcheck/sources/regex-1.3.2/src/utf8.rs:103:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +target/lintcheck/sources/regex-1.3.2/src/utf8.rs:106:22 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +target/lintcheck/sources/regex-1.3.2/src/utf8.rs:107:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +target/lintcheck/sources/regex-1.3.2/src/utf8.rs:108:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +target/lintcheck/sources/regex-1.3.2/src/utf8.rs:109:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +target/lintcheck/sources/regex-1.3.2/src/utf8.rs:111:27 clippy::unreadable_literal "long literal lacking separators" +target/lintcheck/sources/regex-1.3.2/src/utf8.rs:121:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/regex-1.3.2/src/utf8.rs:143:24 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +target/lintcheck/sources/regex-1.3.2/src/utf8.rs:143:9 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +target/lintcheck/sources/regex-1.3.2/src/utf8.rs:23:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/regex-1.3.2/src/utf8.rs:30:20 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +target/lintcheck/sources/regex-1.3.2/src/utf8.rs:51:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/regex-1.3.2/src/utf8.rs:58:23 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +target/lintcheck/sources/regex-1.3.2/src/utf8.rs:58:9 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +target/lintcheck/sources/regex-1.3.2/src/utf8.rs:63:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +target/lintcheck/sources/regex-1.3.2/src/utf8.rs:66:22 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +target/lintcheck/sources/regex-1.3.2/src/utf8.rs:66:54 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +target/lintcheck/sources/regex-1.3.2/src/utf8.rs:77:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +target/lintcheck/sources/regex-1.3.2/src/utf8.rs:80:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +target/lintcheck/sources/regex-1.3.2/src/utf8.rs:83:22 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +target/lintcheck/sources/regex-1.3.2/src/utf8.rs:84:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +target/lintcheck/sources/regex-1.3.2/src/utf8.rs:85:19 clippy::cast_lossless "casting `u8` to `u32` may become silently lossy if you later change the type" +target/lintcheck/sources/regex-1.3.2/src/utf8.rs:92:23 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +target/lintcheck/sources/regex-1.3.2/src/utf8.rs:92:9 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +target/lintcheck/sources/regex-1.3.2/src/utf8.rs:97:16 clippy::unusual_byte_groupings "digits of hex or binary literal not grouped by four" +target/lintcheck/sources/ripgrep-12.1.1/build.rs:133:19 clippy::option_as_ref_deref "called `.as_ref().map(|x| &**x)` on an Option value. This can be done more directly by calling `githash.as_deref()` instead" +target/lintcheck/sources/ripgrep-12.1.1/build.rs:18:18 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/ripgrep-12.1.1/build.rs:225:14 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/ripgrep-12.1.1/build.rs:92:19 clippy::option_as_ref_deref "called `.as_ref().map(|x| &**x)` on an Option value. This can be done more directly by calling `githash.as_deref()` instead" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/app.rs:1408:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/app.rs:1408:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/app.rs:1409:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/app.rs:1409:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/app.rs:152:32 clippy::doc_markdown "you should put `clap::Arg` between ticks in the documentation" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/app.rs:152:32 clippy::doc_markdown "you should put `clap::Arg` between ticks in the documentation" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/app.rs:156:39 clippy::doc_markdown "you should put `clap::Arg` between ticks in the documentation" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/app.rs:156:39 clippy::doc_markdown "you should put `clap::Arg` between ticks in the documentation" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/app.rs:156:5 clippy::doc_markdown "you should put `RGArg` between ticks in the documentation" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/app.rs:156:5 clippy::doc_markdown "you should put `RGArg` between ticks in the documentation" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/app.rs:1668:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/app.rs:1668:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/app.rs:1669:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/app.rs:1669:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/app.rs:1821:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/app.rs:1821:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/app.rs:1822:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/app.rs:1822:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/app.rs:2999:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/app.rs:2999:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/app.rs:3000:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/app.rs:3000:5 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/app.rs:367:54 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/app.rs:367:54 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/app.rs:414:59 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/app.rs:414:59 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/app.rs:417:57 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/app.rs:417:57 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/app.rs:417:57 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/app.rs:417:57 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/app.rs:75:9 clippy::doc_markdown "you should put `RIPGREP_BUILD_GIT_HASH` between ticks in the documentation" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/app.rs:75:9 clippy::doc_markdown "you should put `RIPGREP_BUILD_GIT_HASH` between ticks in the documentation" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/app.rs:87:5 clippy::if_not_else "unnecessary boolean `not` operation" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/app.rs:87:5 clippy::if_not_else "unnecessary boolean `not` operation" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/args.rs:1143:22 clippy::unused_self "unused `self` argument" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/args.rs:11:1 clippy::single_component_path_imports "this import is redundant" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/args.rs:1209:74 clippy::if_same_then_else "this `if` has identical blocks" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/args.rs:1282:13 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/args.rs:1430:22 clippy::unused_self "unused `self` argument" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/args.rs:1438:21 clippy::doc_markdown "you should put `OsStr` between ticks in the documentation" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/args.rs:1520:44 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/args.rs:1524:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/args.rs:1635:14 clippy::doc_markdown "you should put `values_of_lossy` between ticks in the documentation" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/args.rs:1693:41 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/args.rs:1770:17 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/args.rs:1829:5 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/args.rs:287:13 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/args.rs:33:1 clippy::single_component_path_imports "this import is redundant" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/args.rs:34:1 clippy::single_component_path_imports "this import is redundant" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/args.rs:35:1 clippy::single_component_path_imports "this import is redundant" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/args.rs:369:5 clippy::upper_case_acronyms "name `JSON` contains a capitalized acronym" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/args.rs:410:14 clippy::trivially_copy_pass_by_ref "this argument (2 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/args.rs:475:18 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/args.rs:512:19 clippy::doc_markdown "you should put `ArgMatches` between ticks in the documentation" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/args.rs:549:16 clippy::wrong_self_convention "methods called `to_*` usually take self by reference; consider choosing a less ambiguous name" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/args.rs:76:18 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/args.rs:77:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/args.rs:923:42 clippy::doc_markdown "you should put `BinaryDetection::quit` between ticks in the documentation" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/config.rs:13:1 clippy::single_component_path_imports "this import is redundant" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/config.rs:58:6 clippy::type_complexity "very complex type used. Consider factoring parts into `type` definitions" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/config.rs:79:6 clippy::type_complexity "very complex type used. Consider factoring parts into `type` definitions" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/logger.rs:11:30 clippy::doc_markdown "you should put `max_level` between ticks in the documentation" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/logger.rs:15:16 clippy::redundant_static_lifetimes "constants have by default a `'static` lifetime" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/main.rs:114:9 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/main.rs:189:9 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/main.rs:55:19 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/main.rs:56:9 clippy::enum_glob_use "usage of wildcard import for enum variants" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/messages.rs:46:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/messages.rs:51:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/messages.rs:62:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/path_printer.rs:27:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/path_printer.rs:89:9 clippy::if_not_else "unnecessary boolean `not` operation" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/search.rs:185:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/search.rs:224:5 clippy::upper_case_acronyms "name `JSON` contains a capitalized acronym" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/search.rs:292:9 clippy::write_with_newline "using `write!()` with a format string that ends in a single newline" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/search.rs:311:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/search.rs:377:12 clippy::nonminimal_bool "this boolean expression can be simplified" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/search.rs:423:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/search.rs:447:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/search.rs:472:24 clippy::map_clone "you are using an explicit closure for cloning elements" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/search.rs:472:41 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/search.rs:480:24 clippy::map_clone "you are using an explicit closure for cloning elements" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/search.rs:480:41 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/search.rs:49:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/search.rs:509:24 clippy::map_clone "you are using an explicit closure for cloning elements" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/search.rs:509:41 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/search.rs:517:24 clippy::map_clone "you are using an explicit closure for cloning elements" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/search.rs:517:41 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/search.rs:533:36 clippy::cast_lossless "casting `u32` to `f64` may become silently lossy if you later change the type" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/search.rs:533:5 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/subject.rs:20:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/ripgrep-12.1.1/crates/core/subject.rs:4:1 clippy::single_component_path_imports "this import is redundant" +target/lintcheck/sources/serde-1.0.118/src/de/mod.rs:1592:9 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" +target/lintcheck/sources/serde-1.0.118/src/de/mod.rs:1616:9 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" +target/lintcheck/sources/serde-1.0.118/src/de/mod.rs:1627:9 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" +target/lintcheck/sources/serde-1.0.118/src/de/mod.rs:1638:9 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" +target/lintcheck/sources/serde-1.0.118/src/de/mod.rs:1649:9 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" +target/lintcheck/sources/serde-1.0.118/src/de/mod.rs:952:13 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" +target/lintcheck/sources/serde-1.0.118/src/de/mod.rs:986:13 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" +target/lintcheck/sources/syn-1.0.54/build.rs:1:null clippy::cargo_common_metadata "package `syn` is missing `package.keywords` metadata" +target/lintcheck/sources/syn-1.0.54/src/lib.rs:1:null clippy::cargo_common_metadata "package `syn` is missing `package.keywords` metadata" +target/lintcheck/sources/syn-1.0.54/src/lit.rs:1397:40 clippy::redundant_else "redundant else block" +target/lintcheck/sources/syn-1.0.54/src/lit.rs:1405:28 clippy::redundant_else "redundant else block" +target/lintcheck/sources/syn-1.0.54/src/lit.rs:1485:32 clippy::redundant_else "redundant else block" +target/lintcheck/sources/syn-1.0.54/src/token.rs:974:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/unicode-xid-0.2.1/src/lib.rs:1:null clippy::cargo_common_metadata "package `unicode-xid` is missing `package.categories` metadata" +target/lintcheck/sources/unicode-xid-0.2.1/src/lib.rs:57:64 clippy::doc_markdown "you should put `XID_Start` between ticks in the documentation" +target/lintcheck/sources/unicode-xid-0.2.1/src/lib.rs:60:10 clippy::doc_markdown "you should put `XID_Start` between ticks in the documentation" +target/lintcheck/sources/unicode-xid-0.2.1/src/lib.rs:62:27 clippy::doc_markdown "you should put `ID_Start` between ticks in the documentation" +target/lintcheck/sources/unicode-xid-0.2.1/src/lib.rs:62:67 clippy::doc_markdown "you should put `NFKx` between ticks in the documentation" +target/lintcheck/sources/unicode-xid-0.2.1/src/lib.rs:63:21 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" +target/lintcheck/sources/unicode-xid-0.2.1/src/lib.rs:65:61 clippy::doc_markdown "you should put `XID_Continue` between ticks in the documentation" +target/lintcheck/sources/unicode-xid-0.2.1/src/lib.rs:68:10 clippy::doc_markdown "you should put `XID_Continue` between ticks in the documentation" +target/lintcheck/sources/unicode-xid-0.2.1/src/lib.rs:70:28 clippy::doc_markdown "you should put `ID_Continue` between ticks in the documentation" +target/lintcheck/sources/unicode-xid-0.2.1/src/lib.rs:70:72 clippy::doc_markdown "you should put `NFKx` between ticks in the documentation" +target/lintcheck/sources/unicode-xid-0.2.1/src/lib.rs:71:24 clippy::wrong_self_convention "methods called `is_*` usually take self by reference or no self; consider choosing a less ambiguous name" +target/lintcheck/sources/xsv-0.13.0/src/cmd/cat.rs:101:34 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/xsv-0.13.0/src/cmd/cat.rs:42:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +target/lintcheck/sources/xsv-0.13.0/src/cmd/cat.rs:53:9 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/xsv-0.13.0/src/cmd/cat.rs:7:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +target/lintcheck/sources/xsv-0.13.0/src/cmd/count.rs:32:9 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/xsv-0.13.0/src/cmd/count.rs:38:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/xsv-0.13.0/src/cmd/count.rs:42:33 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +target/lintcheck/sources/xsv-0.13.0/src/cmd/count.rs:7:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +target/lintcheck/sources/xsv-0.13.0/src/cmd/fixlengths.rs:45:9 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/xsv-0.13.0/src/cmd/fixlengths.rs:50:18 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/xsv-0.13.0/src/cmd/fixlengths.rs:62:30 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +target/lintcheck/sources/xsv-0.13.0/src/cmd/fixlengths.rs:9:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +target/lintcheck/sources/xsv-0.13.0/src/cmd/flatten.rs:10:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +target/lintcheck/sources/xsv-0.13.0/src/cmd/flatten.rs:51:9 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/xsv-0.13.0/src/cmd/fmt.rs:50:9 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/xsv-0.13.0/src/cmd/fmt.rs:55:13 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/xsv-0.13.0/src/cmd/fmt.rs:7:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +target/lintcheck/sources/xsv-0.13.0/src/cmd/frequency.rs:148:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +target/lintcheck/sources/xsv-0.13.0/src/cmd/frequency.rs:149:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +target/lintcheck/sources/xsv-0.13.0/src/cmd/frequency.rs:15:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +target/lintcheck/sources/xsv-0.13.0/src/cmd/frequency.rs:169:13 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/xsv-0.13.0/src/cmd/frequency.rs:176:17 clippy::if_not_else "unnecessary boolean `not` operation" +target/lintcheck/sources/xsv-0.13.0/src/cmd/frequency.rs:178:24 clippy::collapsible_else_if "this `else { if .. }` block can be collapsed" +target/lintcheck/sources/xsv-0.13.0/src/cmd/frequency.rs:77:9 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/xsv-0.13.0/src/cmd/frequency.rs:93:31 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" +target/lintcheck/sources/xsv-0.13.0/src/cmd/headers.rs:43:9 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/xsv-0.13.0/src/cmd/headers.rs:49:17 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" +target/lintcheck/sources/xsv-0.13.0/src/cmd/headers.rs:9:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +target/lintcheck/sources/xsv-0.13.0/src/cmd/index.rs:11:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +target/lintcheck/sources/xsv-0.13.0/src/cmd/index.rs:45:9 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/xsv-0.13.0/src/cmd/input.rs:42:9 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/xsv-0.13.0/src/cmd/input.rs:47:9 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/xsv-0.13.0/src/cmd/input.rs:7:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +target/lintcheck/sources/xsv-0.13.0/src/cmd/join.rs:17:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +target/lintcheck/sources/xsv-0.13.0/src/cmd/join.rs:194:29 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/xsv-0.13.0/src/cmd/join.rs:224:22 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/xsv-0.13.0/src/cmd/join.rs:293:14 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/xsv-0.13.0/src/cmd/join.rs:293:20 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/xsv-0.13.0/src/cmd/join.rs:297:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/xsv-0.13.0/src/cmd/join.rs:298:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/xsv-0.13.0/src/cmd/join.rs:299:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/xsv-0.13.0/src/cmd/join.rs:300:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/xsv-0.13.0/src/cmd/join.rs:308:9 clippy::unused_self "unused `self` argument" +target/lintcheck/sources/xsv-0.13.0/src/cmd/join.rs:342:38 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +target/lintcheck/sources/xsv-0.13.0/src/cmd/join.rs:342:46 clippy::unseparated_literal_suffix "integer type suffix should be separated by an underscore" +target/lintcheck/sources/xsv-0.13.0/src/cmd/join.rs:347:9 clippy::if_not_else "unnecessary boolean `not` operation" +target/lintcheck/sources/xsv-0.13.0/src/cmd/join.rs:372:44 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/xsv-0.13.0/src/cmd/join.rs:375:33 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/xsv-0.13.0/src/cmd/join.rs:392:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/xsv-0.13.0/src/cmd/join.rs:403:29 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" +target/lintcheck/sources/xsv-0.13.0/src/cmd/join.rs:406:57 clippy::implicit_clone "implicitly cloning a `Vec` by calling `to_vec` on its dereferenced type" +target/lintcheck/sources/xsv-0.13.0/src/cmd/join.rs:426:13 clippy::if_not_else "unnecessary boolean `not` operation" +target/lintcheck/sources/xsv-0.13.0/src/cmd/join.rs:77:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +target/lintcheck/sources/xsv-0.13.0/src/cmd/join.rs:94:9 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/xsv-0.13.0/src/cmd/partition.rs:105:22 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/xsv-0.13.0/src/cmd/partition.rs:106:22 clippy::redundant_slicing "redundant slicing of the whole range" +target/lintcheck/sources/xsv-0.13.0/src/cmd/partition.rs:139:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/xsv-0.13.0/src/cmd/partition.rs:15:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +target/lintcheck/sources/xsv-0.13.0/src/cmd/partition.rs:169:9 clippy::if_not_else "unnecessary boolean `not` operation" +target/lintcheck/sources/xsv-0.13.0/src/cmd/partition.rs:56:9 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/xsv-0.13.0/src/cmd/partition.rs:77:9 clippy::unused_self "unused `self` argument" +target/lintcheck/sources/xsv-0.13.0/src/cmd/sample.rs:105:44 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +target/lintcheck/sources/xsv-0.13.0/src/cmd/sample.rs:115:21 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +target/lintcheck/sources/xsv-0.13.0/src/cmd/sample.rs:11:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +target/lintcheck/sources/xsv-0.13.0/src/cmd/sample.rs:51:9 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/xsv-0.13.0/src/cmd/sample.rs:58:19 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/xsv-0.13.0/src/cmd/sample.rs:69:9 clippy::match_wildcard_for_single_variants "wildcard match will miss any future added variants" +target/lintcheck/sources/xsv-0.13.0/src/cmd/sample.rs:75:16 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" +target/lintcheck/sources/xsv-0.13.0/src/cmd/sample.rs:91:42 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +target/lintcheck/sources/xsv-0.13.0/src/cmd/sample.rs:92:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +target/lintcheck/sources/xsv-0.13.0/src/cmd/search.rs:51:9 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/xsv-0.13.0/src/cmd/search.rs:9:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +target/lintcheck/sources/xsv-0.13.0/src/cmd/select.rs:60:9 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/xsv-0.13.0/src/cmd/select.rs:8:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +target/lintcheck/sources/xsv-0.13.0/src/cmd/slice.rs:57:9 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/xsv-0.13.0/src/cmd/slice.rs:9:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +target/lintcheck/sources/xsv-0.13.0/src/cmd/sort.rs:11:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +target/lintcheck/sources/xsv-0.13.0/src/cmd/sort.rs:138:47 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +target/lintcheck/sources/xsv-0.13.0/src/cmd/sort.rs:139:51 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +target/lintcheck/sources/xsv-0.13.0/src/cmd/sort.rs:48:9 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/xsv-0.13.0/src/cmd/sort.rs:91:14 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" +target/lintcheck/sources/xsv-0.13.0/src/cmd/split.rs:14:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +target/lintcheck/sources/xsv-0.13.0/src/cmd/split.rs:61:9 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/xsv-0.13.0/src/cmd/split.rs:94:5 clippy::unnecessary_wraps "this function's return value is unnecessary" +target/lintcheck/sources/xsv-0.13.0/src/cmd/split.rs:96:14 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +target/lintcheck/sources/xsv-0.13.0/src/cmd/split.rs:99:13 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:110:36 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:127:14 clippy::needless_pass_by_value "this argument is passed by value, but not consumed in the function body" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:138:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:139:43 clippy::cast_possible_truncation "casting `u64` to `usize` may truncate the value on targets with 32-bit wide pointers" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:162:25 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:22:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:231:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:262:35 clippy::default_trait_access "calling `cmd::stats::TypedSum::default()` is more clear than this expression" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:263:40 clippy::default_trait_access "calling `cmd::stats::TypedMinMax::default()` is more clear than this expression" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:264:39 clippy::default_trait_access "calling `stats::OnlineStats::default()` is more clear than this expression" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:265:58 clippy::default_trait_access "calling `stats::Unsorted::default()` is more clear than this expression" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:266:41 clippy::default_trait_access "calling `stats::Unsorted::default()` is more clear than this expression" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:268:18 clippy::default_trait_access "calling `cmd::stats::FieldType::default()` is more clear than this expression" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:269:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:270:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:271:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:272:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:273:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:274:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:283:9 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:284:9 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:285:9 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:290:21 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:293:25 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:297:25 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:301:21 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:302:21 clippy::option_map_unit_fn "called `map(f)` on an `Option` value where `f` is a closure that returns the unit type `()`" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:308:18 clippy::wrong_self_convention "methods called `to_*` usually take self by reference; consider choosing a less ambiguous name" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:318:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:322:45 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:322:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:327:9 clippy::if_not_else "unnecessary boolean `not` operation" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:330:13 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:338:45 clippy::redundant_closure_for_method_calls "redundant closure found" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:402:16 clippy::redundant_pattern_matching "redundant pattern matching, consider using `is_ok()`" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:403:16 clippy::redundant_pattern_matching "redundant pattern matching, consider using `is_ok()`" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:407:18 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:411:16 clippy::trivially_copy_pass_by_ref "this argument (1 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:427:56 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:429:56 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:430:60 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:430:60 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:454:5 clippy::doc_markdown "you should put `TypedSum` between ticks in the documentation" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:473:43 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:504:56 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:505:51 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:511:5 clippy::doc_markdown "you should put `TypedMinMax` between ticks in the documentation" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:536:35 clippy::cast_possible_truncation "casting `f64` to `i64` may truncate the value" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:544:33 clippy::cast_precision_loss "casting `i64` to `f64` causes a loss of precision (`i64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:592:22 clippy::default_trait_access "calling `stats::MinMax::default()` is more clear than this expression" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:593:22 clippy::default_trait_access "calling `stats::MinMax::default()` is more clear than this expression" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:594:23 clippy::default_trait_access "calling `stats::MinMax::default()` is more clear than this expression" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:595:21 clippy::default_trait_access "calling `stats::MinMax::default()` is more clear than this expression" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:71:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +target/lintcheck/sources/xsv-0.13.0/src/cmd/stats.rs:86:9 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/xsv-0.13.0/src/cmd/table.rs:10:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +target/lintcheck/sources/xsv-0.13.0/src/cmd/table.rs:50:9 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/xsv-0.13.0/src/cmd/table.rs:54:9 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/xsv-0.13.0/src/config.rs:113:43 clippy::or_fun_call "use of `unwrap_or` followed by a function call" +target/lintcheck/sources/xsv-0.13.0/src/config.rs:58:1 clippy::struct_excessive_bools "more than 3 bools in a struct" +target/lintcheck/sources/xsv-0.13.0/src/config.rs:77:28 clippy::explicit_deref_methods "explicit deref method call" +target/lintcheck/sources/xsv-0.13.0/src/config.rs:90:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/xsv-0.13.0/src/index.rs:31:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/xsv-0.13.0/src/main.rs:164:49 clippy::redundant_clone "redundant clone" +target/lintcheck/sources/xsv-0.13.0/src/main.rs:164:50 clippy::implicit_clone "implicitly cloning a `String` by calling `to_owned` on its dereferenced type" +target/lintcheck/sources/xsv-0.13.0/src/main.rs:1:null clippy::cargo_common_metadata "package `xsv` is missing `package.categories` metadata" +target/lintcheck/sources/xsv-0.13.0/src/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `rand_core`: 0.3.1, 0.4.2" +target/lintcheck/sources/xsv-0.13.0/src/main.rs:1:null clippy::multiple_crate_versions "multiple versions for dependency `rand`: 0.3.23, 0.4.6" +target/lintcheck/sources/xsv-0.13.0/src/main.rs:75:16 clippy::redundant_static_lifetimes "statics have by default a `'static` lifetime" +target/lintcheck/sources/xsv-0.13.0/src/select.rs:13:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/xsv-0.13.0/src/select.rs:154:5 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Result`" +target/lintcheck/sources/xsv-0.13.0/src/select.rs:250:33 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/xsv-0.13.0/src/select.rs:250:43 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/xsv-0.13.0/src/select.rs:255:39 clippy::range_plus_one "an inclusive range would be more readable" +target/lintcheck/sources/xsv-0.13.0/src/select.rs:280:20 clippy::len_zero "length comparison to zero" +target/lintcheck/sources/xsv-0.13.0/src/select.rs:29:13 clippy::redundant_field_names "redundant field names in struct initialization" +target/lintcheck/sources/xsv-0.13.0/src/select.rs:360:62 clippy::trivially_copy_pass_by_ref "this argument (8 byte) is passed by reference, but would be more efficient if passed by value (limit: 8 byte)" +target/lintcheck/sources/xsv-0.13.0/src/select.rs:360:9 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Option`" +target/lintcheck/sources/xsv-0.13.0/src/select.rs:375:9 clippy::stable_sort_primitive "used `sort` on primitive type `usize`" +target/lintcheck/sources/xsv-0.13.0/src/select.rs:379:18 clippy::explicit_into_iter_loop "it is more concise to loop over containers instead of using explicit iteration methods" +target/lintcheck/sources/xsv-0.13.0/src/select.rs:416:5 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" +target/lintcheck/sources/xsv-0.13.0/src/select.rs:419:9 clippy::unnecessary_wraps "this function's return value is unnecessarily wrapped by `Option`" +target/lintcheck/sources/xsv-0.13.0/src/select.rs:420:27 clippy::option_option "consider using `Option` instead of `Option>` or a custom enum if you need to distinguish all 3 cases" +target/lintcheck/sources/xsv-0.13.0/src/select.rs:99:17 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/xsv-0.13.0/src/util.rs:150:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +target/lintcheck/sources/xsv-0.13.0/src/util.rs:37:33 clippy::map_clone "you are using an explicit closure for copying elements" +target/lintcheck/sources/xsv-0.13.0/src/util.rs:90:1 clippy::needless_lifetimes "explicit lifetimes given in parameter types where they could be elided (or replaced with `'_` if needed by type declaration)" @@ -3426,6 +3433,7 @@ clippy::non_ascii_literal 6 clippy::single_component_path_imports 6 clippy::case_sensitive_file_extension_comparisons 7 clippy::explicit_into_iter_loop 7 +clippy::implicit_clone 7 clippy::map_clone 7 clippy::option_map_unit_fn 7 clippy::range_plus_one 7 -- cgit 1.4.1-3-g733a5 From 70d952e75123b9c0a935be77d1c58d5c1ed71af6 Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Sun, 28 Feb 2021 02:07:01 +0100 Subject: lintcheck: more fixes MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit fix a couple of issues when checking if lintcheck needed rerun after clippy binary changed. I was apparently still comparing the times wrongly, but it should be fixed™ now... I actually looked at the date of the sources.toml and not at the date of the log file! Also fix progress report counter not advancing in squential mode --- clippy_dev/src/lintcheck.rs | 23 +++++++++++------------ 1 file changed, 11 insertions(+), 12 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lintcheck.rs b/clippy_dev/src/lintcheck.rs index 622dad1740b..60e677b1e13 100644 --- a/clippy_dev/src/lintcheck.rs +++ b/clippy_dev/src/lintcheck.rs @@ -496,7 +496,7 @@ fn gather_stats(clippy_warnings: &[ClippyWarning]) -> (String, HashMap<&String, /// check if the latest modification of the logfile is older than the modification date of the /// clippy binary, if this is true, we should clean the lintchec shared target directory and recheck -fn lintcheck_needs_rerun(toml_path: &PathBuf) -> bool { +fn lintcheck_needs_rerun(lintcheck_logs_path: &PathBuf) -> bool { let clippy_modified: std::time::SystemTime = { let mut times = [CLIPPY_DRIVER_PATH, CARGO_CLIPPY_PATH].iter().map(|p| { std::fs::metadata(p) @@ -505,17 +505,17 @@ fn lintcheck_needs_rerun(toml_path: &PathBuf) -> bool { .expect("failed to get modification date") }); // the oldest modification of either of the binaries - std::cmp::min(times.next().unwrap(), times.next().unwrap()) + std::cmp::max(times.next().unwrap(), times.next().unwrap()) }; - let logs_modified: std::time::SystemTime = std::fs::metadata(toml_path) + let logs_modified: std::time::SystemTime = std::fs::metadata(lintcheck_logs_path) .expect("failed to get metadata of file") .modified() .expect("failed to get modification date"); - // if clippys modification time is smaller (older) than the logs mod time, we need to rerun - // lintcheck - clippy_modified < logs_modified + // time is represented in seconds since X + // logs_modified 2 and clippy_modified 5 means clippy binary is older and we need to recheck + logs_modified < clippy_modified } /// lintchecks `main()` function @@ -528,7 +528,7 @@ pub fn run(clap_config: &ArgMatches) { // if the clippy bin is newer than our logs, throw away target dirs to force clippy to // refresh the logs - if lintcheck_needs_rerun(&config.sources_toml_path) { + if lintcheck_needs_rerun(&config.lintcheck_results_path) { let shared_target_dir = "target/lintcheck/shared_target_dir"; match std::fs::metadata(&shared_target_dir) { Ok(metadata) => { @@ -538,8 +538,7 @@ pub fn run(clap_config: &ArgMatches) { .expect("failed to remove target/lintcheck/shared_target_dir"); } }, - Err(_) => { // dir probably does not exist, don't remove anything - }, + Err(_) => { /* dir probably does not exist, don't remove anything */ }, } } @@ -566,6 +565,8 @@ pub fn run(clap_config: &ArgMatches) { let crates = read_crates(&config.sources_toml_path); let old_stats = read_stats_from_file(&config.lintcheck_results_path); + let counter = AtomicUsize::new(1); + let clippy_warnings: Vec = if let Some(only_one_crate) = clap_config.value_of("only") { // if we don't have the specified crate in the .toml, throw an error if !crates.iter().any(|krate| { @@ -595,8 +596,6 @@ pub fn run(clap_config: &ArgMatches) { if config.max_jobs > 1 { // run parallel with rayon - let counter = AtomicUsize::new(0); - // Ask rayon for thread count. Assume that half of that is the number of physical cores // Use one target dir for each core so that we can run N clippys in parallel. // We need to use different target dirs because cargo would lock them for a single build otherwise, @@ -623,7 +622,7 @@ pub fn run(clap_config: &ArgMatches) { crates .into_iter() .map(|krate| krate.download_and_extract()) - .map(|krate| krate.run_clippy_lints(&cargo_clippy_path, &AtomicUsize::new(0), 1, num_crates)) + .map(|krate| krate.run_clippy_lints(&cargo_clippy_path, &counter, 1, num_crates)) .flatten() .collect() } -- cgit 1.4.1-3-g733a5 From 1ebaae8a158d414c23c83298135cdfa12c8b980a Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Sun, 28 Feb 2021 12:36:56 +0100 Subject: lintcheck: make download path and source path consts, move source directory from traget/lintcheck/crates to target/lintcheck/sources also update logfile with the dtolnay crates --- clippy_dev/src/lintcheck.rs | 11 ++++-- lintcheck-logs/lintcheck_crates_logs.txt | 64 ++++++++++++++++++++++++++------ 2 files changed, 59 insertions(+), 16 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lintcheck.rs b/clippy_dev/src/lintcheck.rs index 60e677b1e13..60cccfe2a63 100644 --- a/clippy_dev/src/lintcheck.rs +++ b/clippy_dev/src/lintcheck.rs @@ -22,6 +22,9 @@ use serde_json::Value; const CLIPPY_DRIVER_PATH: &str = "target/debug/clippy-driver"; const CARGO_CLIPPY_PATH: &str = "target/debug/cargo-clippy"; +const LINTCHECK_DOWNLOADS: &str = "target/lintcheck/downloads"; +const LINTCHECK_SOURCES: &str = "target/lintcheck/sources"; + /// List of sources to check, loaded from a .toml file #[derive(Debug, Serialize, Deserialize)] struct SourceList { @@ -102,8 +105,8 @@ impl CrateSource { fn download_and_extract(&self) -> Crate { match self { CrateSource::CratesIo { name, version, options } => { - let extract_dir = PathBuf::from("target/lintcheck/crates"); - let krate_download_dir = PathBuf::from("target/lintcheck/downloads"); + let extract_dir = PathBuf::from(LINTCHECK_SOURCES); + let krate_download_dir = PathBuf::from(LINTCHECK_DOWNLOADS); // url to download the crate from crates.io let url = format!("https://crates.io/api/v1/crates/{}/{}/download", name, version); @@ -143,7 +146,7 @@ impl CrateSource { options, } => { let repo_path = { - let mut repo_path = PathBuf::from("target/lintcheck/crates"); + let mut repo_path = PathBuf::from(LINTCHECK_SOURCES); // add a -git suffix in case we have the same crate from crates.io and a git repo repo_path.push(format!("{}-git", name)); repo_path @@ -185,7 +188,7 @@ impl CrateSource { use fs_extra::dir; // simply copy the entire directory into our target dir - let copy_dest = PathBuf::from("target/lintcheck/crates/"); + let copy_dest = PathBuf::from(format!("{}/", LINTCHECK_SOURCES)); // the source path of the crate we copied, ${copy_dest}/crate_name let crate_root = copy_dest.join(name); // .../crates/local_crate diff --git a/lintcheck-logs/lintcheck_crates_logs.txt b/lintcheck-logs/lintcheck_crates_logs.txt index b0ba84ed3f7..449af904efe 100644 --- a/lintcheck-logs/lintcheck_crates_logs.txt +++ b/lintcheck-logs/lintcheck_crates_logs.txt @@ -1,5 +1,26 @@ -clippy 0.1.52 (e3386041a 2021-02-28) +clippy 0.1.52 (70d952e75 2021-02-28) +target/lintcheck/sources/anyhow-1.0.38/build.rs:1:null clippy::cargo_common_metadata "package `anyhow` is missing `package.keywords` metadata" +target/lintcheck/sources/anyhow-1.0.38/src/error.rs:350:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/anyhow-1.0.38/src/lib.rs:1:null clippy::cargo_common_metadata "package `anyhow` is missing `package.keywords` metadata" +target/lintcheck/sources/async-trait-0.1.42/src/expand.rs:130:1 clippy::too_many_lines "this function has too many lines (104/100)" +target/lintcheck/sources/async-trait-0.1.42/src/expand.rs:156:26 clippy::default_trait_access "calling `syn::token::Where::default()` is more clear than this expression" +target/lintcheck/sources/async-trait-0.1.42/src/expand.rs:259:1 clippy::too_many_lines "this function has too many lines (204/100)" +target/lintcheck/sources/async-trait-0.1.42/src/expand.rs:414:35 clippy::shadow_unrelated "`generics` is being shadowed" +target/lintcheck/sources/async-trait-0.1.42/src/expand.rs:464:32 clippy::if_not_else "unnecessary `!=` operation" +target/lintcheck/sources/async-trait-0.1.42/src/lib.rs:102:7 clippy::doc_markdown "you should put `async_trait` between ticks in the documentation" +target/lintcheck/sources/async-trait-0.1.42/src/lib.rs:159:64 clippy::doc_markdown "you should put `async_trait` between ticks in the documentation" +target/lintcheck/sources/async-trait-0.1.42/src/lib.rs:1:null clippy::cargo_common_metadata "package `async-trait` is missing `package.categories` metadata" +target/lintcheck/sources/async-trait-0.1.42/src/lib.rs:1:null clippy::cargo_common_metadata "package `async-trait` is missing `package.keywords` metadata" +target/lintcheck/sources/async-trait-0.1.42/src/lib.rs:240:15 clippy::doc_markdown "you should put `async_trait` between ticks in the documentation" +target/lintcheck/sources/async-trait-0.1.42/src/lifetime.rs:5:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/async-trait-0.1.42/src/receiver.rs:102:34 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/async-trait-0.1.42/src/receiver.rs:107:29 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/async-trait-0.1.42/src/receiver.rs:137:38 clippy::default_trait_access "calling `syn::token::Colon2::default()` is more clear than this expression" +target/lintcheck/sources/async-trait-0.1.42/src/receiver.rs:162:55 clippy::default_trait_access "calling `syn::token::Colon2::default()` is more clear than this expression" +target/lintcheck/sources/async-trait-0.1.42/src/receiver.rs:167:42 clippy::default_trait_access "calling `syn::token::Colon2::default()` is more clear than this expression" +target/lintcheck/sources/async-trait-0.1.42/src/receiver.rs:73:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/async-trait-0.1.42/src/receiver.rs:97:34 clippy::similar_names "binding's name is too similar to existing binding" target/lintcheck/sources/cargo-0.49.0/build.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.categories` metadata" target/lintcheck/sources/cargo-0.49.0/build.rs:1:null clippy::cargo_common_metadata "package `cargo` is missing `package.keywords` metadata" target/lintcheck/sources/cargo-0.49.0/src/bin/cargo/cli.rs:104:34 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" @@ -1427,6 +1448,23 @@ target/lintcheck/sources/cargo-0.49.0/src/cargo/util/workspace.rs:52:1 clippy::m target/lintcheck/sources/cargo-0.49.0/src/cargo/util/workspace.rs:56:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" target/lintcheck/sources/cargo-0.49.0/src/cargo/util/workspace.rs:60:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" target/lintcheck/sources/cargo-0.49.0/src/cargo/util/workspace.rs:64:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cxx-1.0.32/src/rust_string.rs:15:20 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" +target/lintcheck/sources/cxx-1.0.32/src/rust_string.rs:19:24 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" +target/lintcheck/sources/cxx-1.0.32/src/rust_vec.rs:21:20 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" +target/lintcheck/sources/cxx-1.0.32/src/rust_vec.rs:25:24 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" +target/lintcheck/sources/cxx-1.0.32/src/rust_vec.rs:74:35 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" +target/lintcheck/sources/cxx-1.0.32/src/rust_vec.rs:78:39 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" +target/lintcheck/sources/cxx-1.0.32/src/rust_vec.rs:90:20 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" +target/lintcheck/sources/cxx-1.0.32/src/rust_vec.rs:94:24 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" +target/lintcheck/sources/cxx-1.0.32/src/shared_ptr.rs:108:20 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" +target/lintcheck/sources/cxx-1.0.32/src/shared_ptr.rs:165:9 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" +target/lintcheck/sources/cxx-1.0.32/src/shared_ptr.rs:54:20 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" +target/lintcheck/sources/cxx-1.0.32/src/shared_ptr.rs:62:20 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" +target/lintcheck/sources/cxx-1.0.32/src/shared_ptr.rs:75:20 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" +target/lintcheck/sources/cxx-1.0.32/src/unique_ptr.rs:185:9 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" +target/lintcheck/sources/cxx-1.0.32/src/unwind.rs:22:5 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" +target/lintcheck/sources/cxx-1.0.32/src/weak_ptr.rs:47:20 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" +target/lintcheck/sources/cxx-1.0.32/src/weak_ptr.rs:80:20 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" target/lintcheck/sources/iron-0.6.1/src/error.rs:24:1 clippy::module_name_repetitions "item name ends with its containing module's name" target/lintcheck/sources/iron-0.6.1/src/iron.rs:105:13 clippy::redundant_field_names "redundant field names in struct initialization" target/lintcheck/sources/iron-0.6.1/src/iron.rs:119:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" @@ -3176,12 +3214,14 @@ target/lintcheck/sources/serde-1.0.118/src/de/mod.rs:1638:9 clippy::let_undersco target/lintcheck/sources/serde-1.0.118/src/de/mod.rs:1649:9 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" target/lintcheck/sources/serde-1.0.118/src/de/mod.rs:952:13 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" target/lintcheck/sources/serde-1.0.118/src/de/mod.rs:986:13 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" +target/lintcheck/sources/serde_yaml-0.8.17/src/lib.rs:1:null clippy::cargo_common_metadata "package `serde_yaml` is missing `package.categories` metadata" target/lintcheck/sources/syn-1.0.54/build.rs:1:null clippy::cargo_common_metadata "package `syn` is missing `package.keywords` metadata" target/lintcheck/sources/syn-1.0.54/src/lib.rs:1:null clippy::cargo_common_metadata "package `syn` is missing `package.keywords` metadata" target/lintcheck/sources/syn-1.0.54/src/lit.rs:1397:40 clippy::redundant_else "redundant else block" target/lintcheck/sources/syn-1.0.54/src/lit.rs:1405:28 clippy::redundant_else "redundant else block" target/lintcheck/sources/syn-1.0.54/src/lit.rs:1485:32 clippy::redundant_else "redundant else block" target/lintcheck/sources/syn-1.0.54/src/token.rs:974:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/thiserror-1.0.24/src/lib.rs:1:null clippy::cargo_common_metadata "package `thiserror` is missing `package.keywords` metadata" target/lintcheck/sources/unicode-xid-0.2.1/src/lib.rs:1:null clippy::cargo_common_metadata "package `unicode-xid` is missing `package.categories` metadata" target/lintcheck/sources/unicode-xid-0.2.1/src/lib.rs:57:64 clippy::doc_markdown "you should put `XID_Start` between ticks in the documentation" target/lintcheck/sources/unicode-xid-0.2.1/src/lib.rs:60:10 clippy::doc_markdown "you should put `XID_Start` between ticks in the documentation" @@ -3426,7 +3466,6 @@ clippy::len_without_is_empty 5 clippy::match_like_matches_macro 5 clippy::needless_return 5 clippy::new_without_default 5 -clippy::ptr_as_ptr 5 clippy::collapsible_else_if 6 clippy::manual_strip 6 clippy::non_ascii_literal 6 @@ -3446,42 +3485,43 @@ clippy::match_wildcard_for_single_variants 10 clippy::missing_safety_doc 10 clippy::needless_doctest_main 10 clippy::needless_lifetimes 12 -clippy::cargo_common_metadata 13 -clippy::shadow_unrelated 13 clippy::linkedlist 14 +clippy::shadow_unrelated 14 clippy::single_char_add_str 14 clippy::option_if_let_else 15 clippy::needless_pass_by_value 18 +clippy::cargo_common_metadata 19 clippy::cast_possible_wrap 19 clippy::cast_sign_loss 19 +clippy::ptr_as_ptr 19 clippy::unnecessary_wraps 19 clippy::unused_self 19 clippy::unusual_byte_groupings 19 clippy::map_unwrap_or 20 clippy::struct_excessive_bools 20 clippy::redundant_static_lifetimes 21 -clippy::default_trait_access 22 clippy::cast_lossless 23 -clippy::let_underscore_drop 23 +clippy::default_trait_access 26 +clippy::let_underscore_drop 26 clippy::trivially_copy_pass_by_ref 26 clippy::redundant_else 29 -clippy::too_many_lines 32 -clippy::if_not_else 35 +clippy::too_many_lines 34 +clippy::if_not_else 36 clippy::enum_glob_use 40 clippy::unseparated_literal_suffix 41 clippy::cast_precision_loss 44 clippy::single_match_else 45 -clippy::missing_panics_doc 56 +clippy::missing_panics_doc 57 clippy::inline_always 59 clippy::match_same_arms 60 -clippy::similar_names 78 +clippy::similar_names 81 clippy::cast_possible_truncation 95 clippy::redundant_field_names 111 clippy::redundant_closure_for_method_calls 135 clippy::items_after_statements 139 -clippy::module_name_repetitions 142 +clippy::module_name_repetitions 144 clippy::wildcard_imports 163 -clippy::doc_markdown 178 +clippy::doc_markdown 181 clippy::missing_errors_doc 343 clippy::unreadable_literal 365 clippy::must_use_candidate 565 -- cgit 1.4.1-3-g733a5 From 25f909863b9946c65ae37375f8f95720b728cc9e Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Sun, 28 Feb 2021 13:59:47 +0100 Subject: update lintcheck_crates logs and fix typos --- clippy_dev/lintcheck_crates.toml | 2 +- clippy_dev/src/lintcheck.rs | 4 +- lintcheck-logs/lintcheck_crates_logs.txt | 93 +++++++++++++++++++++++++------- 3 files changed, 77 insertions(+), 22 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/lintcheck_crates.toml b/clippy_dev/lintcheck_crates.toml index f065b2de01e..dfee28f1a87 100644 --- a/clippy_dev/lintcheck_crates.toml +++ b/clippy_dev/lintcheck_crates.toml @@ -27,7 +27,7 @@ cxx = {name = "cxx", versions = ['1.0.32']} ryu = {name = "ryu", version = ['1.0.5']} serde_yaml = {name = "serde_yaml", versions = ['0.8.17']} thiserror = {name = "thiserror", versions = ['1.0.24']} -# some embark crates there are other interesting crates but +# some embark crates, there are other interesting crates but # unfortunately adding them increases lintcheck runtime drastically cfg-expr = {name = "cfg-expr", versions = ['0.7.1']} puffin = {name = "puffin", git_url = "https://github.com/EmbarkStudios/puffin", git_hash = "02dd4a3"} diff --git a/clippy_dev/src/lintcheck.rs b/clippy_dev/src/lintcheck.rs index 60cccfe2a63..1db0445559c 100644 --- a/clippy_dev/src/lintcheck.rs +++ b/clippy_dev/src/lintcheck.rs @@ -318,8 +318,8 @@ impl LintcheckConfig { let sources_toml_path = PathBuf::from(sources_toml); - // for the path where we save the lint results, get the filename without extenstion ( so for - // wasd.toml, use "wasd"....) + // for the path where we save the lint results, get the filename without extension (so for + // wasd.toml, use "wasd"...) let filename: PathBuf = sources_toml_path.file_stem().unwrap().into(); let lintcheck_results_path = PathBuf::from(format!("lintcheck-logs/{}_logs.txt", filename.display())); diff --git a/lintcheck-logs/lintcheck_crates_logs.txt b/lintcheck-logs/lintcheck_crates_logs.txt index 449af904efe..167024b3a05 100644 --- a/lintcheck-logs/lintcheck_crates_logs.txt +++ b/lintcheck-logs/lintcheck_crates_logs.txt @@ -1448,6 +1448,36 @@ target/lintcheck/sources/cargo-0.49.0/src/cargo/util/workspace.rs:52:1 clippy::m target/lintcheck/sources/cargo-0.49.0/src/cargo/util/workspace.rs:56:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" target/lintcheck/sources/cargo-0.49.0/src/cargo/util/workspace.rs:60:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" target/lintcheck/sources/cargo-0.49.0/src/cargo/util/workspace.rs:64:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cfg-expr-0.7.1/src/error.rs:107:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +target/lintcheck/sources/cfg-expr-0.7.1/src/error.rs:5:1 clippy::module_name_repetitions "item name ends with its containing module's name" +target/lintcheck/sources/cfg-expr-0.7.1/src/error.rs:74:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +target/lintcheck/sources/cfg-expr-0.7.1/src/error.rs:91:24 clippy::if_not_else "unnecessary boolean `not` operation" +target/lintcheck/sources/cfg-expr-0.7.1/src/expr/lexer.rs:102:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cfg-expr-0.7.1/src/expr/lexer.rs:125:33 clippy::redundant_slicing "redundant slicing of the whole range" +target/lintcheck/sources/cfg-expr-0.7.1/src/expr/lexer.rs:4:5 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +target/lintcheck/sources/cfg-expr-0.7.1/src/expr/lexer.rs:58:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/cfg-expr-0.7.1/src/expr/lexer.rs:76:1 clippy::module_name_repetitions "item name starts with its containing module's name" +target/lintcheck/sources/cfg-expr-0.7.1/src/expr/lexer.rs:97:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cfg-expr-0.7.1/src/expr/mod.rs:351:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +target/lintcheck/sources/cfg-expr-0.7.1/src/expr/mod.rs:464:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/cfg-expr-0.7.1/src/expr/mod.rs:57:13 clippy::enum_glob_use "usage of wildcard import for enum variants" +target/lintcheck/sources/cfg-expr-0.7.1/src/expr/mod.rs:586:33 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/cfg-expr-0.7.1/src/expr/mod.rs:599:32 clippy::match_same_arms "this `match` has identical arm bodies" +target/lintcheck/sources/cfg-expr-0.7.1/src/expr/parser.rs:116:31 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/cfg-expr-0.7.1/src/expr/parser.rs:124:36 clippy::similar_names "binding's name is too similar to existing binding" +target/lintcheck/sources/cfg-expr-0.7.1/src/expr/parser.rs:17:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/cfg-expr-0.7.1/src/expr/parser.rs:17:5 clippy::too_many_lines "this function has too many lines (345/100)" +target/lintcheck/sources/cfg-expr-0.7.1/src/expr/parser.rs:22:13 clippy::shadow_unrelated "`original` is being shadowed" +target/lintcheck/sources/cfg-expr-0.7.1/src/expr/parser.rs:243:36 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/cfg-expr-0.7.1/src/expr/parser.rs:254:34 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/cfg-expr-0.7.1/src/expr/parser.rs:25:9 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cfg-expr-0.7.1/src/expr/parser.rs:390:9 clippy::single_match_else "you seem to be trying to use `match` for destructuring a single pattern. Consider using `if let`" +target/lintcheck/sources/cfg-expr-0.7.1/src/expr/parser.rs:392:17 clippy::if_not_else "unnecessary `!=` operation" +target/lintcheck/sources/cfg-expr-0.7.1/src/expr/parser.rs:67:13 clippy::items_after_statements "adding items after statements is confusing, since items exist from the start of the scope" +target/lintcheck/sources/cfg-expr-0.7.1/src/lib.rs:1:null clippy::cargo_common_metadata "package `cfg-expr` is missing `package.categories` metadata" +target/lintcheck/sources/cfg-expr-0.7.1/src/targets/builtins.rs:11:5 clippy::wildcard_imports "usage of wildcard import" +target/lintcheck/sources/cfg-expr-0.7.1/src/targets/mod.rs:139:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/cfg-expr-0.7.1/src/targets/mod.rs:153:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" target/lintcheck/sources/cxx-1.0.32/src/rust_string.rs:15:20 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" target/lintcheck/sources/cxx-1.0.32/src/rust_string.rs:19:24 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" target/lintcheck/sources/cxx-1.0.32/src/rust_vec.rs:21:20 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" @@ -3207,6 +3237,12 @@ target/lintcheck/sources/ripgrep-12.1.1/crates/core/search.rs:533:36 clippy::cas target/lintcheck/sources/ripgrep-12.1.1/crates/core/search.rs:533:5 clippy::cast_precision_loss "casting `u64` to `f64` causes a loss of precision (`u64` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide)" target/lintcheck/sources/ripgrep-12.1.1/crates/core/subject.rs:20:1 clippy::module_name_repetitions "item name starts with its containing module's name" target/lintcheck/sources/ripgrep-12.1.1/crates/core/subject.rs:4:1 clippy::single_component_path_imports "this import is redundant" +target/lintcheck/sources/rpmalloc-0.2.0/src/lib.rs:103:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/rpmalloc-0.2.0/src/lib.rs:114:5 clippy::must_use_candidate "this method could have a `#[must_use]` attribute" +target/lintcheck/sources/rpmalloc-0.2.0/src/lib.rs:71:73 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +target/lintcheck/sources/rpmalloc-0.2.0/src/lib.rs:72:50 clippy::doc_markdown "you should put bare URLs between `<`/`>` or make a proper Markdown link" +target/lintcheck/sources/rpmalloc-0.2.0/src/lib.rs:92:9 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" +target/lintcheck/sources/rpmalloc-0.2.0/src/lib.rs:95:21 clippy::ptr_as_ptr "`as` casting between raw pointers without changing its mutability" target/lintcheck/sources/serde-1.0.118/src/de/mod.rs:1592:9 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" target/lintcheck/sources/serde-1.0.118/src/de/mod.rs:1616:9 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" target/lintcheck/sources/serde-1.0.118/src/de/mod.rs:1627:9 clippy::let_underscore_drop "non-binding `let` on a type that implements `Drop`" @@ -3221,6 +3257,25 @@ target/lintcheck/sources/syn-1.0.54/src/lit.rs:1397:40 clippy::redundant_else "r target/lintcheck/sources/syn-1.0.54/src/lit.rs:1405:28 clippy::redundant_else "redundant else block" target/lintcheck/sources/syn-1.0.54/src/lit.rs:1485:32 clippy::redundant_else "redundant else block" target/lintcheck/sources/syn-1.0.54/src/token.rs:974:5 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/tame-oidc-0.1.0/src/errors.rs:9:5 clippy::upper_case_acronyms "name `HTTP` contains a capitalized acronym" +target/lintcheck/sources/tame-oidc-0.1.0/src/lib.rs:1:null clippy::cargo_common_metadata "package `tame-oidc` is missing `package.categories` metadata" +target/lintcheck/sources/tame-oidc-0.1.0/src/oidc.rs:111:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/tame-oidc-0.1.0/src/oidc.rs:127:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/tame-oidc-0.1.0/src/oidc.rs:52:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/tame-oidc-0.1.0/src/oidc.rs:60:1 clippy::from_over_into "an implementation of `From` is preferred since it gives you `Into<_>` for free where the reverse isn't true" +target/lintcheck/sources/tame-oidc-0.1.0/src/oidc.rs:76:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/tame-oidc-0.1.0/src/provider.rs:107:1 clippy::missing_panics_doc "docs for function which may panic missing `# Panics` section" +target/lintcheck/sources/tame-oidc-0.1.0/src/provider.rs:107:1 clippy::must_use_candidate "this function could have a `#[must_use]` attribute" +target/lintcheck/sources/tame-oidc-0.1.0/src/provider.rs:118:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/tame-oidc-0.1.0/src/provider.rs:143:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/tame-oidc-0.1.0/src/provider.rs:159:1 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/tame-oidc-0.1.0/src/provider.rs:26:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/tame-oidc-0.1.0/src/provider.rs:38:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/tame-oidc-0.1.0/src/provider.rs:57:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/tame-oidc-0.1.0/src/provider.rs:71:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" +target/lintcheck/sources/tame-oidc-0.1.0/src/provider.rs:77:12 clippy::upper_case_acronyms "name `JWK` contains a capitalized acronym" +target/lintcheck/sources/tame-oidc-0.1.0/src/provider.rs:90:12 clippy::upper_case_acronyms "name `JWKS` contains a capitalized acronym" +target/lintcheck/sources/tame-oidc-0.1.0/src/provider.rs:95:5 clippy::missing_errors_doc "docs for function returning `Result` missing `# Errors` section" target/lintcheck/sources/thiserror-1.0.24/src/lib.rs:1:null clippy::cargo_common_metadata "package `thiserror` is missing `package.keywords` metadata" target/lintcheck/sources/unicode-xid-0.2.1/src/lib.rs:1:null clippy::cargo_common_metadata "package `unicode-xid` is missing `package.categories` metadata" target/lintcheck/sources/unicode-xid-0.2.1/src/lib.rs:57:64 clippy::doc_markdown "you should put `XID_Start` between ticks in the documentation" @@ -3416,7 +3471,6 @@ clippy::comparison_chain 1 clippy::expect_fun_call 1 clippy::explicit_deref_methods 1 clippy::from_iter_instead_of_collect 1 -clippy::from_over_into 1 clippy::int_plus_one 1 clippy::manual_flatten 1 clippy::manual_saturating_arithmetic 1 @@ -3426,7 +3480,6 @@ clippy::or_fun_call 1 clippy::precedence 1 clippy::pub_enum_variant_names 1 clippy::redundant_clone 1 -clippy::redundant_slicing 1 clippy::same_item_push 1 clippy::should_implement_trait 1 clippy::stable_sort_primitive 1 @@ -3438,6 +3491,7 @@ clippy::while_let_on_iterator 1 clippy::comparison_to_empty 2 clippy::expl_impl_clone_on_copy 2 clippy::filter_map 2 +clippy::from_over_into 2 clippy::len_zero 2 clippy::manual_non_exhaustive 2 clippy::match_on_vec_items 2 @@ -3445,6 +3499,7 @@ clippy::option_as_ref_deref 2 clippy::option_option 2 clippy::question_mark 2 clippy::redundant_pattern_matching 2 +clippy::redundant_slicing 2 clippy::type_complexity 2 clippy::unnecessary_cast 2 clippy::unused_unit 2 @@ -3458,7 +3513,6 @@ clippy::mut_mut 3 clippy::ptr_arg 3 clippy::zero_ptr 3 clippy::too_many_arguments 4 -clippy::upper_case_acronyms 4 clippy::explicit_iter_loop 5 clippy::field_reassign_with_default 5 clippy::identity_op 5 @@ -3476,6 +3530,7 @@ clippy::implicit_clone 7 clippy::map_clone 7 clippy::option_map_unit_fn 7 clippy::range_plus_one 7 +clippy::upper_case_acronyms 7 clippy::invalid_upcast_comparisons 8 clippy::needless_question_mark 8 clippy::wrong_self_convention 8 @@ -3486,43 +3541,43 @@ clippy::missing_safety_doc 10 clippy::needless_doctest_main 10 clippy::needless_lifetimes 12 clippy::linkedlist 14 -clippy::shadow_unrelated 14 clippy::single_char_add_str 14 clippy::option_if_let_else 15 +clippy::shadow_unrelated 15 clippy::needless_pass_by_value 18 -clippy::cargo_common_metadata 19 clippy::cast_possible_wrap 19 clippy::cast_sign_loss 19 -clippy::ptr_as_ptr 19 clippy::unnecessary_wraps 19 clippy::unused_self 19 clippy::unusual_byte_groupings 19 clippy::map_unwrap_or 20 clippy::struct_excessive_bools 20 +clippy::cargo_common_metadata 21 +clippy::ptr_as_ptr 21 clippy::redundant_static_lifetimes 21 clippy::cast_lossless 23 clippy::default_trait_access 26 clippy::let_underscore_drop 26 clippy::trivially_copy_pass_by_ref 26 clippy::redundant_else 29 -clippy::too_many_lines 34 -clippy::if_not_else 36 -clippy::enum_glob_use 40 +clippy::too_many_lines 35 +clippy::if_not_else 38 clippy::unseparated_literal_suffix 41 clippy::cast_precision_loss 44 -clippy::single_match_else 45 -clippy::missing_panics_doc 57 +clippy::enum_glob_use 44 +clippy::single_match_else 48 clippy::inline_always 59 -clippy::match_same_arms 60 -clippy::similar_names 81 +clippy::missing_panics_doc 59 +clippy::match_same_arms 62 +clippy::similar_names 83 clippy::cast_possible_truncation 95 clippy::redundant_field_names 111 clippy::redundant_closure_for_method_calls 135 -clippy::items_after_statements 139 -clippy::module_name_repetitions 144 -clippy::wildcard_imports 163 -clippy::doc_markdown 181 -clippy::missing_errors_doc 343 +clippy::items_after_statements 143 +clippy::module_name_repetitions 146 +clippy::wildcard_imports 164 +clippy::doc_markdown 184 +clippy::missing_errors_doc 356 clippy::unreadable_literal 365 -clippy::must_use_candidate 565 +clippy::must_use_candidate 571 ICEs: -- cgit 1.4.1-3-g733a5 From bbe641678c70924de9dd6624db819ef0324bbb22 Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Tue, 2 Mar 2021 20:20:51 +0100 Subject: lintcheck: fix clippy warnings --- clippy_dev/src/lintcheck.rs | 53 +++++++++++++++++++++++---------------------- 1 file changed, 27 insertions(+), 26 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lintcheck.rs b/clippy_dev/src/lintcheck.rs index 1db0445559c..977ff771a99 100644 --- a/clippy_dev/src/lintcheck.rs +++ b/clippy_dev/src/lintcheck.rs @@ -5,14 +5,19 @@ // positives. #![cfg(feature = "lintcheck")] -#![allow(clippy::filter_map)] +#![allow(clippy::filter_map, clippy::collapsible_else_if)] +#![allow(clippy::blocks_in_if_conditions)] // FP on `if x.iter().any(|x| ...)` use crate::clippy_project_root; use std::collections::HashMap; use std::process::Command; use std::sync::atomic::{AtomicUsize, Ordering}; -use std::{env, fmt, fs::write, path::PathBuf}; +use std::{ + env, fmt, + fs::write, + path::{Path, PathBuf}, +}; use clap::ArgMatches; use rayon::prelude::*; @@ -196,11 +201,9 @@ impl CrateSource { if !crate_root.exists() { println!("Copying {} to {}", path.display(), copy_dest.display()); - dir::copy(path, ©_dest, &dir::CopyOptions::new()).expect(&format!( - "Failed to copy from {}, to {}", - path.display(), - crate_root.display() - )); + dir::copy(path, ©_dest, &dir::CopyOptions::new()).unwrap_or_else(|_| { + panic!("Failed to copy from {}, to {}", path.display(), crate_root.display()) + }); } else { println!( "Not copying {} to {}, destination already exists", @@ -225,7 +228,7 @@ impl Crate { /// issued fn run_clippy_lints( &self, - cargo_clippy_path: &PathBuf, + cargo_clippy_path: &Path, target_dir_index: &AtomicUsize, thread_limit: usize, total_crates_to_lint: usize, @@ -308,13 +311,13 @@ impl LintcheckConfig { // first, check if we got anything passed via the LINTCHECK_TOML env var, // if not, ask clap if we got any value for --crates-toml // if not, use the default "clippy_dev/lintcheck_crates.toml" - let sources_toml = env::var("LINTCHECK_TOML").unwrap_or( + let sources_toml = env::var("LINTCHECK_TOML").unwrap_or_else(|_| { clap_config .value_of("crates-toml") .clone() .unwrap_or("clippy_dev/lintcheck_crates.toml") - .to_string(), - ); + .to_string() + }); let sources_toml_path = PathBuf::from(sources_toml); @@ -330,7 +333,7 @@ impl LintcheckConfig { Some(threads) => { let threads: usize = threads .parse() - .expect(&format!("Failed to parse '{}' to a digit", threads)); + .unwrap_or_else(|_| panic!("Failed to parse '{}' to a digit", threads)); if threads == 0 { // automatic choice // Rayon seems to return thread count so half that for core count @@ -387,7 +390,7 @@ fn build_clippy() { } /// Read a `toml` file and return a list of `CrateSources` that we want to check with clippy -fn read_crates(toml_path: &PathBuf) -> Vec { +fn read_crates(toml_path: &Path) -> Vec { let toml_content: String = std::fs::read_to_string(&toml_path).unwrap_or_else(|_| panic!("Failed to read {}", toml_path.display())); let crate_list: SourceList = @@ -499,7 +502,7 @@ fn gather_stats(clippy_warnings: &[ClippyWarning]) -> (String, HashMap<&String, /// check if the latest modification of the logfile is older than the modification date of the /// clippy binary, if this is true, we should clean the lintchec shared target directory and recheck -fn lintcheck_needs_rerun(lintcheck_logs_path: &PathBuf) -> bool { +fn lintcheck_needs_rerun(lintcheck_logs_path: &Path) -> bool { let clippy_modified: std::time::SystemTime = { let mut times = [CLIPPY_DRIVER_PATH, CARGO_CLIPPY_PATH].iter().map(|p| { std::fs::metadata(p) @@ -533,15 +536,13 @@ pub fn run(clap_config: &ArgMatches) { // refresh the logs if lintcheck_needs_rerun(&config.lintcheck_results_path) { let shared_target_dir = "target/lintcheck/shared_target_dir"; - match std::fs::metadata(&shared_target_dir) { - Ok(metadata) => { - if metadata.is_dir() { - println!("Clippy is newer than lint check logs, clearing lintcheck shared target dir..."); - std::fs::remove_dir_all(&shared_target_dir) - .expect("failed to remove target/lintcheck/shared_target_dir"); - } - }, - Err(_) => { /* dir probably does not exist, don't remove anything */ }, + // if we get an Err here, the shared target dir probably does simply not exist + if let Ok(metadata) = std::fs::metadata(&shared_target_dir) { + if metadata.is_dir() { + println!("Clippy is newer than lint check logs, clearing lintcheck shared target dir..."); + std::fs::remove_dir_all(&shared_target_dir) + .expect("failed to remove target/lintcheck/shared_target_dir"); + } } } @@ -660,7 +661,7 @@ pub fn run(clap_config: &ArgMatches) { } /// read the previous stats from the lintcheck-log file -fn read_stats_from_file(file_path: &PathBuf) -> HashMap { +fn read_stats_from_file(file_path: &Path) -> HashMap { let file_content: String = match std::fs::read_to_string(file_path).ok() { Some(content) => content, None => { @@ -678,9 +679,9 @@ fn read_stats_from_file(file_path: &PathBuf) -> HashMap { let stats_lines = &lines[start + 1..=end - 1]; stats_lines - .into_iter() + .iter() .map(|line| { - let mut spl = line.split(" ").into_iter(); + let mut spl = line.split(' '); ( spl.next().unwrap().to_string(), spl.next().unwrap().parse::().unwrap(), -- cgit 1.4.1-3-g733a5 From 37c4b11a84eb07c0d9a0b95ad81a7ae72ec1370a Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Thu, 4 Mar 2021 22:33:22 +0100 Subject: lintcheck: add test --- clippy_dev/src/lintcheck.rs | 32 +++++++++++++++++++++++++++++++- clippy_dev/test_sources.toml | 4 ++++ 2 files changed, 35 insertions(+), 1 deletion(-) create mode 100644 clippy_dev/test_sources.toml (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lintcheck.rs b/clippy_dev/src/lintcheck.rs index 977ff771a99..01f3c9a5bd8 100644 --- a/clippy_dev/src/lintcheck.rs +++ b/clippy_dev/src/lintcheck.rs @@ -503,6 +503,10 @@ fn gather_stats(clippy_warnings: &[ClippyWarning]) -> (String, HashMap<&String, /// check if the latest modification of the logfile is older than the modification date of the /// clippy binary, if this is true, we should clean the lintchec shared target directory and recheck fn lintcheck_needs_rerun(lintcheck_logs_path: &Path) -> bool { + if !lintcheck_logs_path.exists() { + return true; + } + let clippy_modified: std::time::SystemTime = { let mut times = [CLIPPY_DRIVER_PATH, CARGO_CLIPPY_PATH].iter().map(|p| { std::fs::metadata(p) @@ -665,7 +669,6 @@ fn read_stats_from_file(file_path: &Path) -> HashMap { let file_content: String = match std::fs::read_to_string(file_path).ok() { Some(content) => content, None => { - eprintln!("RETURND"); return HashMap::new(); }, }; @@ -734,3 +737,30 @@ fn print_stats(old_stats: HashMap, new_stats: HashMap<&String, us println!("{} {} => 0", old_key, old_value); }); } + +#[test] +fn lintcheck_test() { + let args = [ + "run", + "--target-dir", + "clippy_dev/target", + "--package", + "clippy_dev", + "--bin", + "clippy_dev", + "--manifest-path", + "clippy_dev/Cargo.toml", + "--features", + "lintcheck", + "--", + "lintcheck", + "--crates-toml", + "clippy_dev/test_sources.toml", + ]; + let status = std::process::Command::new("cargo") + .args(&args) + .current_dir("../" /* repo root */) + .status(); + + assert!(status.unwrap().success()); +} diff --git a/clippy_dev/test_sources.toml b/clippy_dev/test_sources.toml new file mode 100644 index 00000000000..4b0eb71ef4b --- /dev/null +++ b/clippy_dev/test_sources.toml @@ -0,0 +1,4 @@ +[crates] +cc = {name = "cc", versions = ['1.0.67']} +home = {name = "home", git_url = "https://github.com/brson/home", git_hash = "32044e53dfbdcd32bafad3109d1fbab805fc0f40"} +rustc_tools_util = {name = "rustc_tools_util", versions = ['0.2.0']} -- cgit 1.4.1-3-g733a5 From 4aaad086d2eff2d2f4e169551b6cffad22e7e751 Mon Sep 17 00:00:00 2001 From: flip1995 Date: Fri, 5 Mar 2021 11:10:15 +0100 Subject: Fix dogfood errors in clippy_dev --- clippy_dev/src/lib.rs | 2 +- clippy_dev/src/lintcheck.rs | 68 ++++++++++++++++++++++++++------------------- 2 files changed, 41 insertions(+), 29 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lib.rs b/clippy_dev/src/lib.rs index 01d1fc9211a..0244ff2b6c2 100644 --- a/clippy_dev/src/lib.rs +++ b/clippy_dev/src/lib.rs @@ -530,7 +530,7 @@ fn test_gen_deprecated() { #[should_panic] fn test_gen_deprecated_fail() { let lints = vec![Lint::new("should_assert_eq2", "group2", "abc", None, "module_name")]; - let _ = gen_deprecated(lints.iter()); + let _deprecated_lints = gen_deprecated(lints.iter()); } #[test] diff --git a/clippy_dev/src/lintcheck.rs b/clippy_dev/src/lintcheck.rs index 01f3c9a5bd8..81b86481f57 100644 --- a/clippy_dev/src/lintcheck.rs +++ b/clippy_dev/src/lintcheck.rs @@ -6,13 +6,12 @@ #![cfg(feature = "lintcheck")] #![allow(clippy::filter_map, clippy::collapsible_else_if)] -#![allow(clippy::blocks_in_if_conditions)] // FP on `if x.iter().any(|x| ...)` use crate::clippy_project_root; -use std::collections::HashMap; use std::process::Command; use std::sync::atomic::{AtomicUsize, Ordering}; +use std::{collections::HashMap, io::ErrorKind}; use std::{ env, fmt, fs::write, @@ -116,9 +115,21 @@ impl CrateSource { // url to download the crate from crates.io let url = format!("https://crates.io/api/v1/crates/{}/{}/download", name, version); println!("Downloading and extracting {} {} from {}", name, version, url); - let _ = std::fs::create_dir("target/lintcheck/"); - let _ = std::fs::create_dir(&krate_download_dir); - let _ = std::fs::create_dir(&extract_dir); + std::fs::create_dir("target/lintcheck/").unwrap_or_else(|err| { + if err.kind() != ErrorKind::AlreadyExists { + panic!("cannot create lintcheck target dir"); + } + }); + std::fs::create_dir(&krate_download_dir).unwrap_or_else(|err| { + if err.kind() != ErrorKind::AlreadyExists { + panic!("cannot create crate download dir"); + } + }); + std::fs::create_dir(&extract_dir).unwrap_or_else(|err| { + if err.kind() != ErrorKind::AlreadyExists { + panic!("cannot create crate extraction dir"); + } + }); let krate_file_path = krate_download_dir.join(format!("{}-{}.crate.tar.gz", name, version)); // don't download/extract if we already have done so @@ -198,18 +209,18 @@ impl CrateSource { // the source path of the crate we copied, ${copy_dest}/crate_name let crate_root = copy_dest.join(name); // .../crates/local_crate - if !crate_root.exists() { - println!("Copying {} to {}", path.display(), copy_dest.display()); - - dir::copy(path, ©_dest, &dir::CopyOptions::new()).unwrap_or_else(|_| { - panic!("Failed to copy from {}, to {}", path.display(), crate_root.display()) - }); - } else { + if crate_root.exists() { println!( "Not copying {} to {}, destination already exists", path.display(), crate_root.display() ); + } else { + println!("Copying {} to {}", path.display(), copy_dest.display()); + + dir::copy(path, ©_dest, &dir::CopyOptions::new()).unwrap_or_else(|_| { + panic!("Failed to copy from {}, to {}", path.display(), crate_root.display()) + }); } Crate { @@ -236,8 +247,8 @@ impl Crate { // advance the atomic index by one let index = target_dir_index.fetch_add(1, Ordering::SeqCst); // "loop" the index within 0..thread_limit - let target_dir_index = index % thread_limit; - let perc = ((index * 100) as f32 / total_crates_to_lint as f32) as u8; + let thread_index = index % thread_limit; + let perc = (index * 100) / total_crates_to_lint; if thread_limit == 1 { println!( @@ -247,7 +258,7 @@ impl Crate { } else { println!( "{}/{} {}% Linting {} {} in target dir {:?}", - index, total_crates_to_lint, perc, &self.name, &self.version, target_dir_index + index, total_crates_to_lint, perc, &self.name, &self.version, thread_index ); } @@ -269,7 +280,7 @@ impl Crate { // use the looping index to create individual target dirs .env( "CARGO_TARGET_DIR", - shared_target_dir.join(format!("_{:?}", target_dir_index)), + shared_target_dir.join(format!("_{:?}", thread_index)), ) // lint warnings will look like this: // src/cargo/ops/cargo_compile.rs:127:35: warning: usage of `FromIterator::from_iter` @@ -529,6 +540,10 @@ fn lintcheck_needs_rerun(lintcheck_logs_path: &Path) -> bool { } /// lintchecks `main()` function +/// +/// # Panics +/// +/// This function panics if the clippy binaries don't exist. pub fn run(clap_config: &ArgMatches) { let config = LintcheckConfig::from_clap(clap_config); @@ -579,9 +594,9 @@ pub fn run(clap_config: &ArgMatches) { // if we don't have the specified crate in the .toml, throw an error if !crates.iter().any(|krate| { let name = match krate { - CrateSource::CratesIo { name, .. } => name, - CrateSource::Git { name, .. } => name, - CrateSource::Path { name, .. } => name, + CrateSource::CratesIo { name, .. } | CrateSource::Git { name, .. } | CrateSource::Path { name, .. } => { + name + }, }; name == only_one_crate }) { @@ -597,8 +612,7 @@ pub fn run(clap_config: &ArgMatches) { .into_iter() .map(|krate| krate.download_and_extract()) .filter(|krate| krate.name == only_one_crate) - .map(|krate| krate.run_clippy_lints(&cargo_clippy_path, &AtomicUsize::new(0), 1, 1)) - .flatten() + .flat_map(|krate| krate.run_clippy_lints(&cargo_clippy_path, &AtomicUsize::new(0), 1, 1)) .collect() } else { if config.max_jobs > 1 { @@ -621,8 +635,7 @@ pub fn run(clap_config: &ArgMatches) { crates .into_par_iter() .map(|krate| krate.download_and_extract()) - .map(|krate| krate.run_clippy_lints(&cargo_clippy_path, &counter, num_cpus, num_crates)) - .flatten() + .flat_map(|krate| krate.run_clippy_lints(&cargo_clippy_path, &counter, num_cpus, num_crates)) .collect() } else { // run sequential @@ -630,8 +643,7 @@ pub fn run(clap_config: &ArgMatches) { crates .into_iter() .map(|krate| krate.download_and_extract()) - .map(|krate| krate.run_clippy_lints(&cargo_clippy_path, &counter, 1, num_crates)) - .flatten() + .flat_map(|krate| krate.run_clippy_lints(&cargo_clippy_path, &counter, 1, num_crates)) .collect() } }; @@ -646,7 +658,7 @@ pub fn run(clap_config: &ArgMatches) { .map(|w| (&w.crate_name, &w.message)) .collect(); - let mut all_msgs: Vec = clippy_warnings.iter().map(|warning| warning.to_string()).collect(); + let mut all_msgs: Vec = clippy_warnings.iter().map(ToString::to_string).collect(); all_msgs.sort(); all_msgs.push("\n\n\n\nStats:\n".into()); all_msgs.push(stats_formatted); @@ -673,13 +685,13 @@ fn read_stats_from_file(file_path: &Path) -> HashMap { }, }; - let lines: Vec = file_content.lines().map(|l| l.to_string()).collect(); + let lines: Vec = file_content.lines().map(ToString::to_string).collect(); // search for the beginning "Stats:" and the end "ICEs:" of the section we want let start = lines.iter().position(|line| line == "Stats:").unwrap(); let end = lines.iter().position(|line| line == "ICEs:").unwrap(); - let stats_lines = &lines[start + 1..=end - 1]; + let stats_lines = &lines[start + 1..end]; stats_lines .iter() -- cgit 1.4.1-3-g733a5 From 74eb44834cc12ce51396d94e98b04fdd0ad9bb64 Mon Sep 17 00:00:00 2001 From: flip1995 Date: Fri, 5 Mar 2021 14:06:43 +0100 Subject: Extract directory creation into its own function --- clippy_dev/src/lintcheck.rs | 39 ++++++++++++++++++++++++--------------- 1 file changed, 24 insertions(+), 15 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lintcheck.rs b/clippy_dev/src/lintcheck.rs index 81b86481f57..f01f14eb458 100644 --- a/clippy_dev/src/lintcheck.rs +++ b/clippy_dev/src/lintcheck.rs @@ -115,21 +115,7 @@ impl CrateSource { // url to download the crate from crates.io let url = format!("https://crates.io/api/v1/crates/{}/{}/download", name, version); println!("Downloading and extracting {} {} from {}", name, version, url); - std::fs::create_dir("target/lintcheck/").unwrap_or_else(|err| { - if err.kind() != ErrorKind::AlreadyExists { - panic!("cannot create lintcheck target dir"); - } - }); - std::fs::create_dir(&krate_download_dir).unwrap_or_else(|err| { - if err.kind() != ErrorKind::AlreadyExists { - panic!("cannot create crate download dir"); - } - }); - std::fs::create_dir(&extract_dir).unwrap_or_else(|err| { - if err.kind() != ErrorKind::AlreadyExists { - panic!("cannot create crate extraction dir"); - } - }); + create_dirs(&krate_download_dir, &extract_dir); let krate_file_path = krate_download_dir.join(format!("{}-{}.crate.tar.gz", name, version)); // don't download/extract if we already have done so @@ -750,6 +736,29 @@ fn print_stats(old_stats: HashMap, new_stats: HashMap<&String, us }); } +/// Create necessary directories to run the lintcheck tool. +/// +/// # Panics +/// +/// This function panics if creating one of the dirs fails. +fn create_dirs(krate_download_dir: &Path, extract_dir: &Path) { + std::fs::create_dir("target/lintcheck/").unwrap_or_else(|err| { + if err.kind() != ErrorKind::AlreadyExists { + panic!("cannot create lintcheck target dir"); + } + }); + std::fs::create_dir(&krate_download_dir).unwrap_or_else(|err| { + if err.kind() != ErrorKind::AlreadyExists { + panic!("cannot create crate download dir"); + } + }); + std::fs::create_dir(&extract_dir).unwrap_or_else(|err| { + if err.kind() != ErrorKind::AlreadyExists { + panic!("cannot create crate extraction dir"); + } + }); +} + #[test] fn lintcheck_test() { let args = [ -- cgit 1.4.1-3-g733a5 From 45424c7e757fc15c4dfe5b0ba281863173d785f4 Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Fri, 5 Mar 2021 09:30:12 +0100 Subject: lintcheck: add --fix mode which tries to apply lint suggestions to the sources and prints a warning if that fails Great for spotting false positives/broken suggestions of applicable lints. There are false positives though becasue I'm not sure yet how to silence rustc warnings while keeping clippy warnings. Sometimes rustc makes a suggestion that fails to apply and the implementation does not differenciate between clippy and rustc warnings when applying lint suggestions. changelog: none --- clippy_dev/src/lintcheck.rs | 49 +++++++++++++++++++++++++++++++++++++++++---- clippy_dev/src/main.rs | 3 ++- 2 files changed, 47 insertions(+), 5 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lintcheck.rs b/clippy_dev/src/lintcheck.rs index f01f14eb458..765d3349ec0 100644 --- a/clippy_dev/src/lintcheck.rs +++ b/clippy_dev/src/lintcheck.rs @@ -229,6 +229,7 @@ impl Crate { target_dir_index: &AtomicUsize, thread_limit: usize, total_crates_to_lint: usize, + fix: bool, ) -> Vec { // advance the atomic index by one let index = target_dir_index.fetch_add(1, Ordering::SeqCst); @@ -252,7 +253,18 @@ impl Crate { let shared_target_dir = clippy_project_root().join("target/lintcheck/shared_target_dir"); - let mut args = vec!["--", "--message-format=json", "--", "--cap-lints=warn"]; + let mut args = if fix { + vec![ + "-Zunstable-options", + "--fix", + "-Zunstable-options", + "--allow-no-vcs", + "--", + "--cap-lints=warn", + ] + } else { + vec!["--", "--message-format=json", "--", "--cap-lints=warn"] + }; if let Some(options) = &self.options { for opt in options { @@ -282,6 +294,23 @@ impl Crate { ); }); let stdout = String::from_utf8_lossy(&all_output.stdout); + let stderr = String::from_utf8_lossy(&all_output.stderr); + + if fix { + if let Some(stderr) = stderr + .lines() + .find(|line| line.contains("failed to automatically apply fixes suggested by rustc to crate")) + { + let subcrate = &stderr[63..]; + println!( + "ERROR: failed to apply some suggetion to {} / to (sub)crate {}", + self.name, subcrate + ); + } + // fast path, we don't need the warnings anyway + return Vec::new(); + } + let output_lines = stdout.lines(); let warnings: Vec = output_lines .into_iter() @@ -289,6 +318,7 @@ impl Crate { .filter(|line| filter_clippy_warnings(&line)) .map(|json_msg| parse_json_message(json_msg, &self)) .collect(); + warnings } } @@ -301,6 +331,8 @@ struct LintcheckConfig { sources_toml_path: PathBuf, // we save the clippy lint results here lintcheck_results_path: PathBuf, + // whether to just run --fix and not collect all the warnings + fix: bool, } impl LintcheckConfig { @@ -342,11 +374,13 @@ impl LintcheckConfig { // no -j passed, use a single thread None => 1, }; + let fix: bool = clap_config.is_present("fix"); LintcheckConfig { max_jobs, sources_toml_path, lintcheck_results_path, + fix, } } } @@ -598,7 +632,7 @@ pub fn run(clap_config: &ArgMatches) { .into_iter() .map(|krate| krate.download_and_extract()) .filter(|krate| krate.name == only_one_crate) - .flat_map(|krate| krate.run_clippy_lints(&cargo_clippy_path, &AtomicUsize::new(0), 1, 1)) + .flat_map(|krate| krate.run_clippy_lints(&cargo_clippy_path, &AtomicUsize::new(0), 1, 1, config.fix)) .collect() } else { if config.max_jobs > 1 { @@ -621,7 +655,9 @@ pub fn run(clap_config: &ArgMatches) { crates .into_par_iter() .map(|krate| krate.download_and_extract()) - .flat_map(|krate| krate.run_clippy_lints(&cargo_clippy_path, &counter, num_cpus, num_crates)) + .flat_map(|krate| { + krate.run_clippy_lints(&cargo_clippy_path, &counter, num_cpus, num_crates, config.fix) + }) .collect() } else { // run sequential @@ -629,11 +665,16 @@ pub fn run(clap_config: &ArgMatches) { crates .into_iter() .map(|krate| krate.download_and_extract()) - .flat_map(|krate| krate.run_clippy_lints(&cargo_clippy_path, &counter, 1, num_crates)) + .flat_map(|krate| krate.run_clippy_lints(&cargo_clippy_path, &counter, 1, num_crates, config.fix)) .collect() } }; + // if we are in --fix mode, don't change the log files, terminate here + if config.fix { + return; + } + // generate some stats let (stats_formatted, new_stats) = gather_stats(&clippy_warnings); diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index 505d465760c..33fef18d553 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -77,7 +77,8 @@ fn get_clap_config<'a>() -> ArgMatches<'a> { .short("j") .long("jobs") .help("number of threads to use, 0 automatic choice"), - ); + ) + .arg(Arg::with_name("fix").help("runs cargo clippy --fix and checks if all suggestions apply")); let app = App::new("Clippy developer tooling") .subcommand( -- cgit 1.4.1-3-g733a5 From 2546e6f006da4acc79dbed3711674e7d7b73f1f0 Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Sat, 6 Mar 2021 10:06:52 +0100 Subject: lintcheck: move out of clippy-dev into own crate --- .cargo/config | 2 +- clippy_dev/Cargo.toml | 9 - clippy_dev/src/lib.rs | 1 - clippy_dev/src/lintcheck.rs | 828 ------------------------------------- clippy_dev/src/main.rs | 45 +- lintcheck/Cargo.toml | 19 + lintcheck/README.md | 77 ++++ lintcheck/lintcheck_crates.toml | 35 ++ lintcheck/src/main.rs | 886 ++++++++++++++++++++++++++++++++++++++++ 9 files changed, 1021 insertions(+), 881 deletions(-) delete mode 100644 clippy_dev/src/lintcheck.rs create mode 100644 lintcheck/Cargo.toml create mode 100644 lintcheck/README.md create mode 100644 lintcheck/lintcheck_crates.toml create mode 100644 lintcheck/src/main.rs (limited to 'clippy_dev/src') diff --git a/.cargo/config b/.cargo/config index 1142cc470fe..ffa9a5bce85 100644 --- a/.cargo/config +++ b/.cargo/config @@ -1,7 +1,7 @@ [alias] uitest = "test --test compile-test" dev = "run --target-dir clippy_dev/target --package clippy_dev --bin clippy_dev --manifest-path clippy_dev/Cargo.toml --" -dev-lintcheck = "run --target-dir clippy_dev/target --package clippy_dev --bin clippy_dev --manifest-path clippy_dev/Cargo.toml --features lintcheck -- lintcheck" +dev-lintcheck = "run --target-dir lintcheck/target --package lintcheck --bin lintcheck --manifest-path lintcheck/Cargo.toml -- " [build] rustflags = ["-Zunstable-options"] diff --git a/clippy_dev/Cargo.toml b/clippy_dev/Cargo.toml index 5cfd5056f58..b1844e29b32 100644 --- a/clippy_dev/Cargo.toml +++ b/clippy_dev/Cargo.toml @@ -7,20 +7,11 @@ edition = "2018" [dependencies] bytecount = "0.6" clap = "2.33" -flate2 = { version = "1.0.19", optional = true } -fs_extra = { version = "1.2.0", optional = true } itertools = "0.9" opener = "0.4" regex = "1" -serde = { version = "1.0", features = ["derive"], optional = true } -serde_json = { version = "1.0", optional = true } shell-escape = "0.1" -tar = { version = "0.4.30", optional = true } -toml = { version = "0.5", optional = true } -ureq = { version = "2.0.0-rc3", optional = true } -rayon = { version = "1.5.0", optional = true } walkdir = "2" [features] -lintcheck = ["flate2", "serde_json", "tar", "toml", "ureq", "serde", "fs_extra", "rayon"] deny-warnings = [] diff --git a/clippy_dev/src/lib.rs b/clippy_dev/src/lib.rs index 0244ff2b6c2..a95abfaceaa 100644 --- a/clippy_dev/src/lib.rs +++ b/clippy_dev/src/lib.rs @@ -12,7 +12,6 @@ use walkdir::WalkDir; pub mod bless; pub mod fmt; -pub mod lintcheck; pub mod new_lint; pub mod ra_setup; pub mod serve; diff --git a/clippy_dev/src/lintcheck.rs b/clippy_dev/src/lintcheck.rs deleted file mode 100644 index 765d3349ec0..00000000000 --- a/clippy_dev/src/lintcheck.rs +++ /dev/null @@ -1,828 +0,0 @@ -// Run clippy on a fixed set of crates and collect the warnings. -// This helps observing the impact clippy changs have on a set of real-world code. -// -// When a new lint is introduced, we can search the results for new warnings and check for false -// positives. - -#![cfg(feature = "lintcheck")] -#![allow(clippy::filter_map, clippy::collapsible_else_if)] - -use crate::clippy_project_root; - -use std::process::Command; -use std::sync::atomic::{AtomicUsize, Ordering}; -use std::{collections::HashMap, io::ErrorKind}; -use std::{ - env, fmt, - fs::write, - path::{Path, PathBuf}, -}; - -use clap::ArgMatches; -use rayon::prelude::*; -use serde::{Deserialize, Serialize}; -use serde_json::Value; - -const CLIPPY_DRIVER_PATH: &str = "target/debug/clippy-driver"; -const CARGO_CLIPPY_PATH: &str = "target/debug/cargo-clippy"; - -const LINTCHECK_DOWNLOADS: &str = "target/lintcheck/downloads"; -const LINTCHECK_SOURCES: &str = "target/lintcheck/sources"; - -/// List of sources to check, loaded from a .toml file -#[derive(Debug, Serialize, Deserialize)] -struct SourceList { - crates: HashMap, -} - -/// A crate source stored inside the .toml -/// will be translated into on one of the `CrateSource` variants -#[derive(Debug, Serialize, Deserialize)] -struct TomlCrate { - name: String, - versions: Option>, - git_url: Option, - git_hash: Option, - path: Option, - options: Option>, -} - -/// Represents an archive we download from crates.io, or a git repo, or a local repo/folder -/// Once processed (downloaded/extracted/cloned/copied...), this will be translated into a `Crate` -#[derive(Debug, Serialize, Deserialize, Eq, Hash, PartialEq, Ord, PartialOrd)] -enum CrateSource { - CratesIo { - name: String, - version: String, - options: Option>, - }, - Git { - name: String, - url: String, - commit: String, - options: Option>, - }, - Path { - name: String, - path: PathBuf, - options: Option>, - }, -} - -/// Represents the actual source code of a crate that we ran "cargo clippy" on -#[derive(Debug)] -struct Crate { - version: String, - name: String, - // path to the extracted sources that clippy can check - path: PathBuf, - options: Option>, -} - -/// A single warning that clippy issued while checking a `Crate` -#[derive(Debug)] -struct ClippyWarning { - crate_name: String, - crate_version: String, - file: String, - line: String, - column: String, - linttype: String, - message: String, - is_ice: bool, -} - -impl std::fmt::Display for ClippyWarning { - fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { - writeln!( - f, - r#"target/lintcheck/sources/{}-{}/{}:{}:{} {} "{}""#, - &self.crate_name, &self.crate_version, &self.file, &self.line, &self.column, &self.linttype, &self.message - ) - } -} - -impl CrateSource { - /// Makes the sources available on the disk for clippy to check. - /// Clones a git repo and checks out the specified commit or downloads a crate from crates.io or - /// copies a local folder - fn download_and_extract(&self) -> Crate { - match self { - CrateSource::CratesIo { name, version, options } => { - let extract_dir = PathBuf::from(LINTCHECK_SOURCES); - let krate_download_dir = PathBuf::from(LINTCHECK_DOWNLOADS); - - // url to download the crate from crates.io - let url = format!("https://crates.io/api/v1/crates/{}/{}/download", name, version); - println!("Downloading and extracting {} {} from {}", name, version, url); - create_dirs(&krate_download_dir, &extract_dir); - - let krate_file_path = krate_download_dir.join(format!("{}-{}.crate.tar.gz", name, version)); - // don't download/extract if we already have done so - if !krate_file_path.is_file() { - // create a file path to download and write the crate data into - let mut krate_dest = std::fs::File::create(&krate_file_path).unwrap(); - let mut krate_req = ureq::get(&url).call().unwrap().into_reader(); - // copy the crate into the file - std::io::copy(&mut krate_req, &mut krate_dest).unwrap(); - - // unzip the tarball - let ungz_tar = flate2::read::GzDecoder::new(std::fs::File::open(&krate_file_path).unwrap()); - // extract the tar archive - let mut archive = tar::Archive::new(ungz_tar); - archive.unpack(&extract_dir).expect("Failed to extract!"); - } - // crate is extracted, return a new Krate object which contains the path to the extracted - // sources that clippy can check - Crate { - version: version.clone(), - name: name.clone(), - path: extract_dir.join(format!("{}-{}/", name, version)), - options: options.clone(), - } - }, - CrateSource::Git { - name, - url, - commit, - options, - } => { - let repo_path = { - let mut repo_path = PathBuf::from(LINTCHECK_SOURCES); - // add a -git suffix in case we have the same crate from crates.io and a git repo - repo_path.push(format!("{}-git", name)); - repo_path - }; - // clone the repo if we have not done so - if !repo_path.is_dir() { - println!("Cloning {} and checking out {}", url, commit); - if !Command::new("git") - .arg("clone") - .arg(url) - .arg(&repo_path) - .status() - .expect("Failed to clone git repo!") - .success() - { - eprintln!("Failed to clone {} into {}", url, repo_path.display()) - } - } - // check out the commit/branch/whatever - if !Command::new("git") - .arg("checkout") - .arg(commit) - .current_dir(&repo_path) - .status() - .expect("Failed to check out commit") - .success() - { - eprintln!("Failed to checkout {} of repo at {}", commit, repo_path.display()) - } - - Crate { - version: commit.clone(), - name: name.clone(), - path: repo_path, - options: options.clone(), - } - }, - CrateSource::Path { name, path, options } => { - use fs_extra::dir; - - // simply copy the entire directory into our target dir - let copy_dest = PathBuf::from(format!("{}/", LINTCHECK_SOURCES)); - - // the source path of the crate we copied, ${copy_dest}/crate_name - let crate_root = copy_dest.join(name); // .../crates/local_crate - - if crate_root.exists() { - println!( - "Not copying {} to {}, destination already exists", - path.display(), - crate_root.display() - ); - } else { - println!("Copying {} to {}", path.display(), copy_dest.display()); - - dir::copy(path, ©_dest, &dir::CopyOptions::new()).unwrap_or_else(|_| { - panic!("Failed to copy from {}, to {}", path.display(), crate_root.display()) - }); - } - - Crate { - version: String::from("local"), - name: name.clone(), - path: crate_root, - options: options.clone(), - } - }, - } - } -} - -impl Crate { - /// Run `cargo clippy` on the `Crate` and collect and return all the lint warnings that clippy - /// issued - fn run_clippy_lints( - &self, - cargo_clippy_path: &Path, - target_dir_index: &AtomicUsize, - thread_limit: usize, - total_crates_to_lint: usize, - fix: bool, - ) -> Vec { - // advance the atomic index by one - let index = target_dir_index.fetch_add(1, Ordering::SeqCst); - // "loop" the index within 0..thread_limit - let thread_index = index % thread_limit; - let perc = (index * 100) / total_crates_to_lint; - - if thread_limit == 1 { - println!( - "{}/{} {}% Linting {} {}", - index, total_crates_to_lint, perc, &self.name, &self.version - ); - } else { - println!( - "{}/{} {}% Linting {} {} in target dir {:?}", - index, total_crates_to_lint, perc, &self.name, &self.version, thread_index - ); - } - - let cargo_clippy_path = std::fs::canonicalize(cargo_clippy_path).unwrap(); - - let shared_target_dir = clippy_project_root().join("target/lintcheck/shared_target_dir"); - - let mut args = if fix { - vec![ - "-Zunstable-options", - "--fix", - "-Zunstable-options", - "--allow-no-vcs", - "--", - "--cap-lints=warn", - ] - } else { - vec!["--", "--message-format=json", "--", "--cap-lints=warn"] - }; - - if let Some(options) = &self.options { - for opt in options { - args.push(opt); - } - } else { - args.extend(&["-Wclippy::pedantic", "-Wclippy::cargo"]) - } - - let all_output = std::process::Command::new(&cargo_clippy_path) - // use the looping index to create individual target dirs - .env( - "CARGO_TARGET_DIR", - shared_target_dir.join(format!("_{:?}", thread_index)), - ) - // lint warnings will look like this: - // src/cargo/ops/cargo_compile.rs:127:35: warning: usage of `FromIterator::from_iter` - .args(&args) - .current_dir(&self.path) - .output() - .unwrap_or_else(|error| { - panic!( - "Encountered error:\n{:?}\ncargo_clippy_path: {}\ncrate path:{}\n", - error, - &cargo_clippy_path.display(), - &self.path.display() - ); - }); - let stdout = String::from_utf8_lossy(&all_output.stdout); - let stderr = String::from_utf8_lossy(&all_output.stderr); - - if fix { - if let Some(stderr) = stderr - .lines() - .find(|line| line.contains("failed to automatically apply fixes suggested by rustc to crate")) - { - let subcrate = &stderr[63..]; - println!( - "ERROR: failed to apply some suggetion to {} / to (sub)crate {}", - self.name, subcrate - ); - } - // fast path, we don't need the warnings anyway - return Vec::new(); - } - - let output_lines = stdout.lines(); - let warnings: Vec = output_lines - .into_iter() - // get all clippy warnings and ICEs - .filter(|line| filter_clippy_warnings(&line)) - .map(|json_msg| parse_json_message(json_msg, &self)) - .collect(); - - warnings - } -} - -#[derive(Debug)] -struct LintcheckConfig { - // max number of jobs to spawn (default 1) - max_jobs: usize, - // we read the sources to check from here - sources_toml_path: PathBuf, - // we save the clippy lint results here - lintcheck_results_path: PathBuf, - // whether to just run --fix and not collect all the warnings - fix: bool, -} - -impl LintcheckConfig { - fn from_clap(clap_config: &ArgMatches) -> Self { - // first, check if we got anything passed via the LINTCHECK_TOML env var, - // if not, ask clap if we got any value for --crates-toml - // if not, use the default "clippy_dev/lintcheck_crates.toml" - let sources_toml = env::var("LINTCHECK_TOML").unwrap_or_else(|_| { - clap_config - .value_of("crates-toml") - .clone() - .unwrap_or("clippy_dev/lintcheck_crates.toml") - .to_string() - }); - - let sources_toml_path = PathBuf::from(sources_toml); - - // for the path where we save the lint results, get the filename without extension (so for - // wasd.toml, use "wasd"...) - let filename: PathBuf = sources_toml_path.file_stem().unwrap().into(); - let lintcheck_results_path = PathBuf::from(format!("lintcheck-logs/{}_logs.txt", filename.display())); - - // look at the --threads arg, if 0 is passed, ask rayon rayon how many threads it would spawn and - // use half of that for the physical core count - // by default use a single thread - let max_jobs = match clap_config.value_of("threads") { - Some(threads) => { - let threads: usize = threads - .parse() - .unwrap_or_else(|_| panic!("Failed to parse '{}' to a digit", threads)); - if threads == 0 { - // automatic choice - // Rayon seems to return thread count so half that for core count - (rayon::current_num_threads() / 2) as usize - } else { - threads - } - }, - // no -j passed, use a single thread - None => 1, - }; - let fix: bool = clap_config.is_present("fix"); - - LintcheckConfig { - max_jobs, - sources_toml_path, - lintcheck_results_path, - fix, - } - } -} - -/// takes a single json-formatted clippy warnings and returns true (we are interested in that line) -/// or false (we aren't) -fn filter_clippy_warnings(line: &str) -> bool { - // we want to collect ICEs because clippy might have crashed. - // these are summarized later - if line.contains("internal compiler error: ") { - return true; - } - // in general, we want all clippy warnings - // however due to some kind of bug, sometimes there are absolute paths - // to libcore files inside the message - // or we end up with cargo-metadata output (https://github.com/rust-lang/rust-clippy/issues/6508) - - // filter out these message to avoid unnecessary noise in the logs - if line.contains("clippy::") - && !(line.contains("could not read cargo metadata") - || (line.contains(".rustup") && line.contains("toolchains"))) - { - return true; - } - false -} - -/// Builds clippy inside the repo to make sure we have a clippy executable we can use. -fn build_clippy() { - let status = Command::new("cargo") - .arg("build") - .status() - .expect("Failed to build clippy!"); - if !status.success() { - eprintln!("Error: Failed to compile Clippy!"); - std::process::exit(1); - } -} - -/// Read a `toml` file and return a list of `CrateSources` that we want to check with clippy -fn read_crates(toml_path: &Path) -> Vec { - let toml_content: String = - std::fs::read_to_string(&toml_path).unwrap_or_else(|_| panic!("Failed to read {}", toml_path.display())); - let crate_list: SourceList = - toml::from_str(&toml_content).unwrap_or_else(|e| panic!("Failed to parse {}: \n{}", toml_path.display(), e)); - // parse the hashmap of the toml file into a list of crates - let tomlcrates: Vec = crate_list - .crates - .into_iter() - .map(|(_cratename, tomlcrate)| tomlcrate) - .collect(); - - // flatten TomlCrates into CrateSources (one TomlCrates may represent several versions of a crate => - // multiple Cratesources) - let mut crate_sources = Vec::new(); - tomlcrates.into_iter().for_each(|tk| { - if let Some(ref path) = tk.path { - crate_sources.push(CrateSource::Path { - name: tk.name.clone(), - path: PathBuf::from(path), - options: tk.options.clone(), - }); - } - - // if we have multiple versions, save each one - if let Some(ref versions) = tk.versions { - versions.iter().for_each(|ver| { - crate_sources.push(CrateSource::CratesIo { - name: tk.name.clone(), - version: ver.to_string(), - options: tk.options.clone(), - }); - }) - } - // otherwise, we should have a git source - if tk.git_url.is_some() && tk.git_hash.is_some() { - crate_sources.push(CrateSource::Git { - name: tk.name.clone(), - url: tk.git_url.clone().unwrap(), - commit: tk.git_hash.clone().unwrap(), - options: tk.options.clone(), - }); - } - // if we have a version as well as a git data OR only one git data, something is funky - if tk.versions.is_some() && (tk.git_url.is_some() || tk.git_hash.is_some()) - || tk.git_hash.is_some() != tk.git_url.is_some() - { - eprintln!("tomlkrate: {:?}", tk); - if tk.git_hash.is_some() != tk.git_url.is_some() { - panic!("Error: Encountered TomlCrate with only one of git_hash and git_url!"); - } - if tk.path.is_some() && (tk.git_hash.is_some() || tk.versions.is_some()) { - panic!("Error: TomlCrate can only have one of 'git_.*', 'version' or 'path' fields"); - } - unreachable!("Failed to translate TomlCrate into CrateSource!"); - } - }); - // sort the crates - crate_sources.sort(); - - crate_sources -} - -/// Parse the json output of clippy and return a `ClippyWarning` -fn parse_json_message(json_message: &str, krate: &Crate) -> ClippyWarning { - let jmsg: Value = serde_json::from_str(&json_message).unwrap_or_else(|e| panic!("Failed to parse json:\n{:?}", e)); - - ClippyWarning { - crate_name: krate.name.to_string(), - crate_version: krate.version.to_string(), - file: jmsg["message"]["spans"][0]["file_name"] - .to_string() - .trim_matches('"') - .into(), - line: jmsg["message"]["spans"][0]["line_start"] - .to_string() - .trim_matches('"') - .into(), - column: jmsg["message"]["spans"][0]["text"][0]["highlight_start"] - .to_string() - .trim_matches('"') - .into(), - linttype: jmsg["message"]["code"]["code"].to_string().trim_matches('"').into(), - message: jmsg["message"]["message"].to_string().trim_matches('"').into(), - is_ice: json_message.contains("internal compiler error: "), - } -} - -/// Generate a short list of occuring lints-types and their count -fn gather_stats(clippy_warnings: &[ClippyWarning]) -> (String, HashMap<&String, usize>) { - // count lint type occurrences - let mut counter: HashMap<&String, usize> = HashMap::new(); - clippy_warnings - .iter() - .for_each(|wrn| *counter.entry(&wrn.linttype).or_insert(0) += 1); - - // collect into a tupled list for sorting - let mut stats: Vec<(&&String, &usize)> = counter.iter().map(|(lint, count)| (lint, count)).collect(); - // sort by "000{count} {clippy::lintname}" - // to not have a lint with 200 and 2 warnings take the same spot - stats.sort_by_key(|(lint, count)| format!("{:0>4}, {}", count, lint)); - - let stats_string = stats - .iter() - .map(|(lint, count)| format!("{} {}\n", lint, count)) - .collect::(); - - (stats_string, counter) -} - -/// check if the latest modification of the logfile is older than the modification date of the -/// clippy binary, if this is true, we should clean the lintchec shared target directory and recheck -fn lintcheck_needs_rerun(lintcheck_logs_path: &Path) -> bool { - if !lintcheck_logs_path.exists() { - return true; - } - - let clippy_modified: std::time::SystemTime = { - let mut times = [CLIPPY_DRIVER_PATH, CARGO_CLIPPY_PATH].iter().map(|p| { - std::fs::metadata(p) - .expect("failed to get metadata of file") - .modified() - .expect("failed to get modification date") - }); - // the oldest modification of either of the binaries - std::cmp::max(times.next().unwrap(), times.next().unwrap()) - }; - - let logs_modified: std::time::SystemTime = std::fs::metadata(lintcheck_logs_path) - .expect("failed to get metadata of file") - .modified() - .expect("failed to get modification date"); - - // time is represented in seconds since X - // logs_modified 2 and clippy_modified 5 means clippy binary is older and we need to recheck - logs_modified < clippy_modified -} - -/// lintchecks `main()` function -/// -/// # Panics -/// -/// This function panics if the clippy binaries don't exist. -pub fn run(clap_config: &ArgMatches) { - let config = LintcheckConfig::from_clap(clap_config); - - println!("Compiling clippy..."); - build_clippy(); - println!("Done compiling"); - - // if the clippy bin is newer than our logs, throw away target dirs to force clippy to - // refresh the logs - if lintcheck_needs_rerun(&config.lintcheck_results_path) { - let shared_target_dir = "target/lintcheck/shared_target_dir"; - // if we get an Err here, the shared target dir probably does simply not exist - if let Ok(metadata) = std::fs::metadata(&shared_target_dir) { - if metadata.is_dir() { - println!("Clippy is newer than lint check logs, clearing lintcheck shared target dir..."); - std::fs::remove_dir_all(&shared_target_dir) - .expect("failed to remove target/lintcheck/shared_target_dir"); - } - } - } - - let cargo_clippy_path: PathBuf = PathBuf::from(CARGO_CLIPPY_PATH) - .canonicalize() - .expect("failed to canonicalize path to clippy binary"); - - // assert that clippy is found - assert!( - cargo_clippy_path.is_file(), - "target/debug/cargo-clippy binary not found! {}", - cargo_clippy_path.display() - ); - - let clippy_ver = std::process::Command::new(CARGO_CLIPPY_PATH) - .arg("--version") - .output() - .map(|o| String::from_utf8_lossy(&o.stdout).into_owned()) - .expect("could not get clippy version!"); - - // download and extract the crates, then run clippy on them and collect clippys warnings - // flatten into one big list of warnings - - let crates = read_crates(&config.sources_toml_path); - let old_stats = read_stats_from_file(&config.lintcheck_results_path); - - let counter = AtomicUsize::new(1); - - let clippy_warnings: Vec = if let Some(only_one_crate) = clap_config.value_of("only") { - // if we don't have the specified crate in the .toml, throw an error - if !crates.iter().any(|krate| { - let name = match krate { - CrateSource::CratesIo { name, .. } | CrateSource::Git { name, .. } | CrateSource::Path { name, .. } => { - name - }, - }; - name == only_one_crate - }) { - eprintln!( - "ERROR: could not find crate '{}' in clippy_dev/lintcheck_crates.toml", - only_one_crate - ); - std::process::exit(1); - } - - // only check a single crate that was passed via cmdline - crates - .into_iter() - .map(|krate| krate.download_and_extract()) - .filter(|krate| krate.name == only_one_crate) - .flat_map(|krate| krate.run_clippy_lints(&cargo_clippy_path, &AtomicUsize::new(0), 1, 1, config.fix)) - .collect() - } else { - if config.max_jobs > 1 { - // run parallel with rayon - - // Ask rayon for thread count. Assume that half of that is the number of physical cores - // Use one target dir for each core so that we can run N clippys in parallel. - // We need to use different target dirs because cargo would lock them for a single build otherwise, - // killing the parallelism. However this also means that deps will only be reused half/a - // quarter of the time which might result in a longer wall clock runtime - - // This helps when we check many small crates with dep-trees that don't have a lot of branches in - // order to achive some kind of parallelism - - // by default, use a single thread - let num_cpus = config.max_jobs; - let num_crates = crates.len(); - - // check all crates (default) - crates - .into_par_iter() - .map(|krate| krate.download_and_extract()) - .flat_map(|krate| { - krate.run_clippy_lints(&cargo_clippy_path, &counter, num_cpus, num_crates, config.fix) - }) - .collect() - } else { - // run sequential - let num_crates = crates.len(); - crates - .into_iter() - .map(|krate| krate.download_and_extract()) - .flat_map(|krate| krate.run_clippy_lints(&cargo_clippy_path, &counter, 1, num_crates, config.fix)) - .collect() - } - }; - - // if we are in --fix mode, don't change the log files, terminate here - if config.fix { - return; - } - - // generate some stats - let (stats_formatted, new_stats) = gather_stats(&clippy_warnings); - - // grab crashes/ICEs, save the crate name and the ice message - let ices: Vec<(&String, &String)> = clippy_warnings - .iter() - .filter(|warning| warning.is_ice) - .map(|w| (&w.crate_name, &w.message)) - .collect(); - - let mut all_msgs: Vec = clippy_warnings.iter().map(ToString::to_string).collect(); - all_msgs.sort(); - all_msgs.push("\n\n\n\nStats:\n".into()); - all_msgs.push(stats_formatted); - - // save the text into lintcheck-logs/logs.txt - let mut text = clippy_ver; // clippy version number on top - text.push_str(&format!("\n{}", all_msgs.join(""))); - text.push_str("ICEs:\n"); - ices.iter() - .for_each(|(cratename, msg)| text.push_str(&format!("{}: '{}'", cratename, msg))); - - println!("Writing logs to {}", config.lintcheck_results_path.display()); - write(&config.lintcheck_results_path, text).unwrap(); - - print_stats(old_stats, new_stats); -} - -/// read the previous stats from the lintcheck-log file -fn read_stats_from_file(file_path: &Path) -> HashMap { - let file_content: String = match std::fs::read_to_string(file_path).ok() { - Some(content) => content, - None => { - return HashMap::new(); - }, - }; - - let lines: Vec = file_content.lines().map(ToString::to_string).collect(); - - // search for the beginning "Stats:" and the end "ICEs:" of the section we want - let start = lines.iter().position(|line| line == "Stats:").unwrap(); - let end = lines.iter().position(|line| line == "ICEs:").unwrap(); - - let stats_lines = &lines[start + 1..end]; - - stats_lines - .iter() - .map(|line| { - let mut spl = line.split(' '); - ( - spl.next().unwrap().to_string(), - spl.next().unwrap().parse::().unwrap(), - ) - }) - .collect::>() -} - -/// print how lint counts changed between runs -fn print_stats(old_stats: HashMap, new_stats: HashMap<&String, usize>) { - let same_in_both_hashmaps = old_stats - .iter() - .filter(|(old_key, old_val)| new_stats.get::<&String>(&old_key) == Some(old_val)) - .map(|(k, v)| (k.to_string(), *v)) - .collect::>(); - - let mut old_stats_deduped = old_stats; - let mut new_stats_deduped = new_stats; - - // remove duplicates from both hashmaps - same_in_both_hashmaps.iter().for_each(|(k, v)| { - assert!(old_stats_deduped.remove(k) == Some(*v)); - assert!(new_stats_deduped.remove(k) == Some(*v)); - }); - - println!("\nStats:"); - - // list all new counts (key is in new stats but not in old stats) - new_stats_deduped - .iter() - .filter(|(new_key, _)| old_stats_deduped.get::(&new_key).is_none()) - .for_each(|(new_key, new_value)| { - println!("{} 0 => {}", new_key, new_value); - }); - - // list all changed counts (key is in both maps but value differs) - new_stats_deduped - .iter() - .filter(|(new_key, _new_val)| old_stats_deduped.get::(&new_key).is_some()) - .for_each(|(new_key, new_val)| { - let old_val = old_stats_deduped.get::(&new_key).unwrap(); - println!("{} {} => {}", new_key, old_val, new_val); - }); - - // list all gone counts (key is in old status but not in new stats) - old_stats_deduped - .iter() - .filter(|(old_key, _)| new_stats_deduped.get::<&String>(&old_key).is_none()) - .for_each(|(old_key, old_value)| { - println!("{} {} => 0", old_key, old_value); - }); -} - -/// Create necessary directories to run the lintcheck tool. -/// -/// # Panics -/// -/// This function panics if creating one of the dirs fails. -fn create_dirs(krate_download_dir: &Path, extract_dir: &Path) { - std::fs::create_dir("target/lintcheck/").unwrap_or_else(|err| { - if err.kind() != ErrorKind::AlreadyExists { - panic!("cannot create lintcheck target dir"); - } - }); - std::fs::create_dir(&krate_download_dir).unwrap_or_else(|err| { - if err.kind() != ErrorKind::AlreadyExists { - panic!("cannot create crate download dir"); - } - }); - std::fs::create_dir(&extract_dir).unwrap_or_else(|err| { - if err.kind() != ErrorKind::AlreadyExists { - panic!("cannot create crate extraction dir"); - } - }); -} - -#[test] -fn lintcheck_test() { - let args = [ - "run", - "--target-dir", - "clippy_dev/target", - "--package", - "clippy_dev", - "--bin", - "clippy_dev", - "--manifest-path", - "clippy_dev/Cargo.toml", - "--features", - "lintcheck", - "--", - "lintcheck", - "--crates-toml", - "clippy_dev/test_sources.toml", - ]; - let status = std::process::Command::new("cargo") - .args(&args) - .current_dir("../" /* repo root */) - .status(); - - assert!(status.unwrap().success()); -} diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index 33fef18d553..2a9f3e5348c 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -2,10 +2,6 @@ use clap::{App, Arg, ArgMatches, SubCommand}; use clippy_dev::{bless, fmt, new_lint, ra_setup, serve, stderr_length_check, update_lints}; - -#[cfg(feature = "lintcheck")] -use clippy_dev::lintcheck; - fn main() { let matches = get_clap_config(); @@ -13,10 +9,6 @@ fn main() { ("bless", Some(matches)) => { bless::bless(matches.is_present("ignore-timestamp")); }, - #[cfg(feature = "lintcheck")] - ("lintcheck", Some(matches)) => { - lintcheck::run(&matches); - }, ("fmt", Some(matches)) => { fmt::run(matches.is_present("check"), matches.is_present("verbose")); }, @@ -53,34 +45,7 @@ fn main() { } fn get_clap_config<'a>() -> ArgMatches<'a> { - #[cfg(feature = "lintcheck")] - let lintcheck_sbcmd = SubCommand::with_name("lintcheck") - .about("run clippy on a set of crates and check output") - .arg( - Arg::with_name("only") - .takes_value(true) - .value_name("CRATE") - .long("only") - .help("only process a single crate of the list"), - ) - .arg( - Arg::with_name("crates-toml") - .takes_value(true) - .value_name("CRATES-SOURCES-TOML-PATH") - .long("crates-toml") - .help("set the path for a crates.toml where lintcheck should read the sources from"), - ) - .arg( - Arg::with_name("threads") - .takes_value(true) - .value_name("N") - .short("j") - .long("jobs") - .help("number of threads to use, 0 automatic choice"), - ) - .arg(Arg::with_name("fix").help("runs cargo clippy --fix and checks if all suggestions apply")); - - let app = App::new("Clippy developer tooling") + App::new("Clippy developer tooling") .subcommand( SubCommand::with_name("bless") .about("bless the test output changes") @@ -197,10 +162,6 @@ fn get_clap_config<'a>() -> ArgMatches<'a> { .validator_os(serve::validate_port), ) .arg(Arg::with_name("lint").help("Which lint's page to load initially (optional)")), - ); - - #[cfg(feature = "lintcheck")] - let app = app.subcommand(lintcheck_sbcmd); - - app.get_matches() + ) + .get_matches() } diff --git a/lintcheck/Cargo.toml b/lintcheck/Cargo.toml new file mode 100644 index 00000000000..071c1f89615 --- /dev/null +++ b/lintcheck/Cargo.toml @@ -0,0 +1,19 @@ +[package] +name = "lintcheck" +version = "0.0.1" +authors = ["Matthias Krüger "] +edition = "2018" + +[dependencies] +clap = "2.33" +flate2 = {version = "1.0.19"} +fs_extra = {version = "1.2.0"} +rayon = {version = "1.5.0"} +serde = {version = "1.0", features = ["derive"]} +serde_json = {version = "1.0"} +tar = {version = "0.4.30"} +toml = {version = "0.5"} +ureq = {version = "2.0.0-rc3"} + +[features] +deny-warnings = [] diff --git a/lintcheck/README.md b/lintcheck/README.md new file mode 100644 index 00000000000..a5ed9e27bd2 --- /dev/null +++ b/lintcheck/README.md @@ -0,0 +1,77 @@ +# Clippy Dev Tool + +The Clippy Dev Tool is a tool to ease Clippy development, similar to `rustc`s +`x.py`. + +Functionalities (incomplete): + +## `lintcheck` + +Runs clippy on a fixed set of crates read from +`clippy_dev/lintcheck_crates.toml` and saves logs of the lint warnings into the +repo. We can then check the diff and spot new or disappearing warnings. + +From the repo root, run: + +``` +cargo run --target-dir clippy_dev/target --package clippy_dev \ +--bin clippy_dev --manifest-path clippy_dev/Cargo.toml --features lintcheck -- lintcheck +``` + +or + +``` +cargo dev-lintcheck +``` + +By default the logs will be saved into +`lintcheck-logs/lintcheck_crates_logs.txt`. + +You can set a custom sources.toml by adding `--crates-toml custom.toml` or using +`LINTCHECK_TOML="custom.toml"` where `custom.toml` must be a relative path from +the repo root. + +The results will then be saved to `lintcheck-logs/custom_logs.toml`. + +### Configuring the Crate Sources + +The sources to check are saved in a `toml` file. There are three types of +sources. + +1. Crates-io Source + + ```toml + bitflags = {name = "bitflags", versions = ['1.2.1']} + ``` + Requires a "name" and one or multiple "versions" to be checked. + +2. `git` Source + ````toml + puffin = {name = "puffin", git_url = "https://github.com/EmbarkStudios/puffin", git_hash = "02dd4a3"} + ```` + Requires a name, the url to the repo and unique identifier of a commit, + branch or tag which is checked out before linting. There is no way to always + check `HEAD` because that would lead to changing lint-results as the repo + would get updated. If `git_url` or `git_hash` is missing, an error will be + thrown. + +3. Local Dependency + ```toml + clippy = {name = "clippy", path = "/home/user/clippy"} + ``` + For when you want to add a repository that is not published yet. + +#### Command Line Options (optional) + +```toml +bitflags = {name = "bitflags", versions = ['1.2.1'], options = ['-Wclippy::pedantic', '-Wclippy::cargo']} +``` + +It is possible to specify command line options for each crate. This makes it +possible to only check a crate for certain lint groups. If no options are +specified, the lint groups `clippy::all`, `clippy::pedantic`, and +`clippy::cargo` are checked. If an empty array is specified only `clippy::all` +is checked. + +**Note:** `-Wclippy::all` is always enabled by default, unless `-Aclippy::all` +is explicitly specified in the options. diff --git a/lintcheck/lintcheck_crates.toml b/lintcheck/lintcheck_crates.toml new file mode 100644 index 00000000000..dfee28f1a87 --- /dev/null +++ b/lintcheck/lintcheck_crates.toml @@ -0,0 +1,35 @@ +[crates] +# some of these are from cargotest +cargo = {name = "cargo", versions = ['0.49.0']} +iron = {name = "iron", versions = ['0.6.1']} +ripgrep = {name = "ripgrep", versions = ['12.1.1']} +xsv = {name = "xsv", versions = ['0.13.0']} +# commented out because of 173K clippy::match_same_arms msgs in language_type.rs +#tokei = { name = "tokei", versions = ['12.0.4']} +rayon = {name = "rayon", versions = ['1.5.0']} +serde = {name = "serde", versions = ['1.0.118']} +# top 10 crates.io dls +bitflags = {name = "bitflags", versions = ['1.2.1']} +# crash = {name = "clippy_crash", path = "/tmp/clippy_crash"} +libc = {name = "libc", versions = ['0.2.81']} +log = {name = "log", versions = ['0.4.11']} +proc-macro2 = {name = "proc-macro2", versions = ['1.0.24']} +quote = {name = "quote", versions = ['1.0.7']} +rand = {name = "rand", versions = ['0.7.3']} +rand_core = {name = "rand_core", versions = ['0.6.0']} +regex = {name = "regex", versions = ['1.3.2']} +syn = {name = "syn", versions = ['1.0.54']} +unicode-xid = {name = "unicode-xid", versions = ['0.2.1']} +# some more of dtolnays crates +anyhow = {name = "anyhow", versions = ['1.0.38']} +async-trait = {name = "async-trait", versions = ['0.1.42']} +cxx = {name = "cxx", versions = ['1.0.32']} +ryu = {name = "ryu", version = ['1.0.5']} +serde_yaml = {name = "serde_yaml", versions = ['0.8.17']} +thiserror = {name = "thiserror", versions = ['1.0.24']} +# some embark crates, there are other interesting crates but +# unfortunately adding them increases lintcheck runtime drastically +cfg-expr = {name = "cfg-expr", versions = ['0.7.1']} +puffin = {name = "puffin", git_url = "https://github.com/EmbarkStudios/puffin", git_hash = "02dd4a3"} +rpmalloc = {name = "rpmalloc", versions = ['0.2.0']} +tame-oidc = {name = "tame-oidc", versions = ['0.1.0']} diff --git a/lintcheck/src/main.rs b/lintcheck/src/main.rs new file mode 100644 index 00000000000..f5a54cfa8dc --- /dev/null +++ b/lintcheck/src/main.rs @@ -0,0 +1,886 @@ +// Run clippy on a fixed set of crates and collect the warnings. +// This helps observing the impact clippy changes have on a set of real-world code (and not just our testsuite). +// +// When a new lint is introduced, we can search the results for new warnings and check for false +// positives. + +#![allow(clippy::filter_map, clippy::collapsible_else_if)] + +use std::process::Command; +use std::sync::atomic::{AtomicUsize, Ordering}; +use std::{collections::HashMap, io::ErrorKind}; +use std::{ + env, fmt, + fs::write, + path::{Path, PathBuf}, +}; + +use clap::{App, Arg, ArgMatches, SubCommand}; +use rayon::prelude::*; +use serde::{Deserialize, Serialize}; +use serde_json::Value; + +const CLIPPY_DRIVER_PATH: &str = "target/debug/clippy-driver"; +const CARGO_CLIPPY_PATH: &str = "target/debug/cargo-clippy"; + +const LINTCHECK_DOWNLOADS: &str = "target/lintcheck/downloads"; +const LINTCHECK_SOURCES: &str = "target/lintcheck/sources"; + +/// List of sources to check, loaded from a .toml file +#[derive(Debug, Serialize, Deserialize)] +struct SourceList { + crates: HashMap, +} + +/// A crate source stored inside the .toml +/// will be translated into on one of the `CrateSource` variants +#[derive(Debug, Serialize, Deserialize)] +struct TomlCrate { + name: String, + versions: Option>, + git_url: Option, + git_hash: Option, + path: Option, + options: Option>, +} + +/// Represents an archive we download from crates.io, or a git repo, or a local repo/folder +/// Once processed (downloaded/extracted/cloned/copied...), this will be translated into a `Crate` +#[derive(Debug, Serialize, Deserialize, Eq, Hash, PartialEq, Ord, PartialOrd)] +enum CrateSource { + CratesIo { + name: String, + version: String, + options: Option>, + }, + Git { + name: String, + url: String, + commit: String, + options: Option>, + }, + Path { + name: String, + path: PathBuf, + options: Option>, + }, +} + +/// Represents the actual source code of a crate that we ran "cargo clippy" on +#[derive(Debug)] +struct Crate { + version: String, + name: String, + // path to the extracted sources that clippy can check + path: PathBuf, + options: Option>, +} + +/// A single warning that clippy issued while checking a `Crate` +#[derive(Debug)] +struct ClippyWarning { + crate_name: String, + crate_version: String, + file: String, + line: String, + column: String, + linttype: String, + message: String, + is_ice: bool, +} + +impl std::fmt::Display for ClippyWarning { + fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { + writeln!( + f, + r#"target/lintcheck/sources/{}-{}/{}:{}:{} {} "{}""#, + &self.crate_name, &self.crate_version, &self.file, &self.line, &self.column, &self.linttype, &self.message + ) + } +} + +impl CrateSource { + /// Makes the sources available on the disk for clippy to check. + /// Clones a git repo and checks out the specified commit or downloads a crate from crates.io or + /// copies a local folder + fn download_and_extract(&self) -> Crate { + match self { + CrateSource::CratesIo { name, version, options } => { + let extract_dir = PathBuf::from(LINTCHECK_SOURCES); + let krate_download_dir = PathBuf::from(LINTCHECK_DOWNLOADS); + + // url to download the crate from crates.io + let url = format!("https://crates.io/api/v1/crates/{}/{}/download", name, version); + println!("Downloading and extracting {} {} from {}", name, version, url); + create_dirs(&krate_download_dir, &extract_dir); + + let krate_file_path = krate_download_dir.join(format!("{}-{}.crate.tar.gz", name, version)); + // don't download/extract if we already have done so + if !krate_file_path.is_file() { + // create a file path to download and write the crate data into + let mut krate_dest = std::fs::File::create(&krate_file_path).unwrap(); + let mut krate_req = ureq::get(&url).call().unwrap().into_reader(); + // copy the crate into the file + std::io::copy(&mut krate_req, &mut krate_dest).unwrap(); + + // unzip the tarball + let ungz_tar = flate2::read::GzDecoder::new(std::fs::File::open(&krate_file_path).unwrap()); + // extract the tar archive + let mut archive = tar::Archive::new(ungz_tar); + archive.unpack(&extract_dir).expect("Failed to extract!"); + } + // crate is extracted, return a new Krate object which contains the path to the extracted + // sources that clippy can check + Crate { + version: version.clone(), + name: name.clone(), + path: extract_dir.join(format!("{}-{}/", name, version)), + options: options.clone(), + } + }, + CrateSource::Git { + name, + url, + commit, + options, + } => { + let repo_path = { + let mut repo_path = PathBuf::from(LINTCHECK_SOURCES); + // add a -git suffix in case we have the same crate from crates.io and a git repo + repo_path.push(format!("{}-git", name)); + repo_path + }; + // clone the repo if we have not done so + if !repo_path.is_dir() { + println!("Cloning {} and checking out {}", url, commit); + if !Command::new("git") + .arg("clone") + .arg(url) + .arg(&repo_path) + .status() + .expect("Failed to clone git repo!") + .success() + { + eprintln!("Failed to clone {} into {}", url, repo_path.display()) + } + } + // check out the commit/branch/whatever + if !Command::new("git") + .arg("checkout") + .arg(commit) + .current_dir(&repo_path) + .status() + .expect("Failed to check out commit") + .success() + { + eprintln!("Failed to checkout {} of repo at {}", commit, repo_path.display()) + } + + Crate { + version: commit.clone(), + name: name.clone(), + path: repo_path, + options: options.clone(), + } + }, + CrateSource::Path { name, path, options } => { + use fs_extra::dir; + + // simply copy the entire directory into our target dir + let copy_dest = PathBuf::from(format!("{}/", LINTCHECK_SOURCES)); + + // the source path of the crate we copied, ${copy_dest}/crate_name + let crate_root = copy_dest.join(name); // .../crates/local_crate + + if crate_root.exists() { + println!( + "Not copying {} to {}, destination already exists", + path.display(), + crate_root.display() + ); + } else { + println!("Copying {} to {}", path.display(), copy_dest.display()); + + dir::copy(path, ©_dest, &dir::CopyOptions::new()).unwrap_or_else(|_| { + panic!("Failed to copy from {}, to {}", path.display(), crate_root.display()) + }); + } + + Crate { + version: String::from("local"), + name: name.clone(), + path: crate_root, + options: options.clone(), + } + }, + } + } +} + +impl Crate { + /// Run `cargo clippy` on the `Crate` and collect and return all the lint warnings that clippy + /// issued + fn run_clippy_lints( + &self, + cargo_clippy_path: &Path, + target_dir_index: &AtomicUsize, + thread_limit: usize, + total_crates_to_lint: usize, + fix: bool, + ) -> Vec { + // advance the atomic index by one + let index = target_dir_index.fetch_add(1, Ordering::SeqCst); + // "loop" the index within 0..thread_limit + let thread_index = index % thread_limit; + let perc = (index * 100) / total_crates_to_lint; + + if thread_limit == 1 { + println!( + "{}/{} {}% Linting {} {}", + index, total_crates_to_lint, perc, &self.name, &self.version + ); + } else { + println!( + "{}/{} {}% Linting {} {} in target dir {:?}", + index, total_crates_to_lint, perc, &self.name, &self.version, thread_index + ); + } + + let cargo_clippy_path = std::fs::canonicalize(cargo_clippy_path).unwrap(); + + let shared_target_dir = clippy_project_root().join("target/lintcheck/shared_target_dir"); + + let mut args = if fix { + vec![ + "-Zunstable-options", + "--fix", + "-Zunstable-options", + "--allow-no-vcs", + "--", + "--cap-lints=warn", + ] + } else { + vec!["--", "--message-format=json", "--", "--cap-lints=warn"] + }; + + if let Some(options) = &self.options { + for opt in options { + args.push(opt); + } + } else { + args.extend(&["-Wclippy::pedantic", "-Wclippy::cargo"]) + } + + let all_output = std::process::Command::new(&cargo_clippy_path) + // use the looping index to create individual target dirs + .env( + "CARGO_TARGET_DIR", + shared_target_dir.join(format!("_{:?}", thread_index)), + ) + // lint warnings will look like this: + // src/cargo/ops/cargo_compile.rs:127:35: warning: usage of `FromIterator::from_iter` + .args(&args) + .current_dir(&self.path) + .output() + .unwrap_or_else(|error| { + panic!( + "Encountered error:\n{:?}\ncargo_clippy_path: {}\ncrate path:{}\n", + error, + &cargo_clippy_path.display(), + &self.path.display() + ); + }); + let stdout = String::from_utf8_lossy(&all_output.stdout); + let stderr = String::from_utf8_lossy(&all_output.stderr); + + if fix { + if let Some(stderr) = stderr + .lines() + .find(|line| line.contains("failed to automatically apply fixes suggested by rustc to crate")) + { + let subcrate = &stderr[63..]; + println!( + "ERROR: failed to apply some suggetion to {} / to (sub)crate {}", + self.name, subcrate + ); + } + // fast path, we don't need the warnings anyway + return Vec::new(); + } + + let output_lines = stdout.lines(); + let warnings: Vec = output_lines + .into_iter() + // get all clippy warnings and ICEs + .filter(|line| filter_clippy_warnings(&line)) + .map(|json_msg| parse_json_message(json_msg, &self)) + .collect(); + + warnings + } +} + +#[derive(Debug)] +struct LintcheckConfig { + // max number of jobs to spawn (default 1) + max_jobs: usize, + // we read the sources to check from here + sources_toml_path: PathBuf, + // we save the clippy lint results here + lintcheck_results_path: PathBuf, + // whether to just run --fix and not collect all the warnings + fix: bool, +} + +impl LintcheckConfig { + fn from_clap(clap_config: &ArgMatches) -> Self { + // first, check if we got anything passed via the LINTCHECK_TOML env var, + // if not, ask clap if we got any value for --crates-toml + // if not, use the default "clippy_dev/lintcheck_crates.toml" + let sources_toml = env::var("LINTCHECK_TOML").unwrap_or_else(|_| { + clap_config + .value_of("crates-toml") + .clone() + .unwrap_or("clippy_dev/lintcheck_crates.toml") + .to_string() + }); + + let sources_toml_path = PathBuf::from(sources_toml); + + // for the path where we save the lint results, get the filename without extension (so for + // wasd.toml, use "wasd"...) + let filename: PathBuf = sources_toml_path.file_stem().unwrap().into(); + let lintcheck_results_path = PathBuf::from(format!("lintcheck-logs/{}_logs.txt", filename.display())); + + // look at the --threads arg, if 0 is passed, ask rayon rayon how many threads it would spawn and + // use half of that for the physical core count + // by default use a single thread + let max_jobs = match clap_config.value_of("threads") { + Some(threads) => { + let threads: usize = threads + .parse() + .unwrap_or_else(|_| panic!("Failed to parse '{}' to a digit", threads)); + if threads == 0 { + // automatic choice + // Rayon seems to return thread count so half that for core count + (rayon::current_num_threads() / 2) as usize + } else { + threads + } + }, + // no -j passed, use a single thread + None => 1, + }; + let fix: bool = clap_config.is_present("fix"); + + LintcheckConfig { + max_jobs, + sources_toml_path, + lintcheck_results_path, + fix, + } + } +} + +/// takes a single json-formatted clippy warnings and returns true (we are interested in that line) +/// or false (we aren't) +fn filter_clippy_warnings(line: &str) -> bool { + // we want to collect ICEs because clippy might have crashed. + // these are summarized later + if line.contains("internal compiler error: ") { + return true; + } + // in general, we want all clippy warnings + // however due to some kind of bug, sometimes there are absolute paths + // to libcore files inside the message + // or we end up with cargo-metadata output (https://github.com/rust-lang/rust-clippy/issues/6508) + + // filter out these message to avoid unnecessary noise in the logs + if line.contains("clippy::") + && !(line.contains("could not read cargo metadata") + || (line.contains(".rustup") && line.contains("toolchains"))) + { + return true; + } + false +} + +/// Builds clippy inside the repo to make sure we have a clippy executable we can use. +fn build_clippy() { + let status = Command::new("cargo") + .arg("build") + .status() + .expect("Failed to build clippy!"); + if !status.success() { + eprintln!("Error: Failed to compile Clippy!"); + std::process::exit(1); + } +} + +/// Read a `toml` file and return a list of `CrateSources` that we want to check with clippy +fn read_crates(toml_path: &Path) -> Vec { + let toml_content: String = + std::fs::read_to_string(&toml_path).unwrap_or_else(|_| panic!("Failed to read {}", toml_path.display())); + let crate_list: SourceList = + toml::from_str(&toml_content).unwrap_or_else(|e| panic!("Failed to parse {}: \n{}", toml_path.display(), e)); + // parse the hashmap of the toml file into a list of crates + let tomlcrates: Vec = crate_list + .crates + .into_iter() + .map(|(_cratename, tomlcrate)| tomlcrate) + .collect(); + + // flatten TomlCrates into CrateSources (one TomlCrates may represent several versions of a crate => + // multiple Cratesources) + let mut crate_sources = Vec::new(); + tomlcrates.into_iter().for_each(|tk| { + if let Some(ref path) = tk.path { + crate_sources.push(CrateSource::Path { + name: tk.name.clone(), + path: PathBuf::from(path), + options: tk.options.clone(), + }); + } + + // if we have multiple versions, save each one + if let Some(ref versions) = tk.versions { + versions.iter().for_each(|ver| { + crate_sources.push(CrateSource::CratesIo { + name: tk.name.clone(), + version: ver.to_string(), + options: tk.options.clone(), + }); + }) + } + // otherwise, we should have a git source + if tk.git_url.is_some() && tk.git_hash.is_some() { + crate_sources.push(CrateSource::Git { + name: tk.name.clone(), + url: tk.git_url.clone().unwrap(), + commit: tk.git_hash.clone().unwrap(), + options: tk.options.clone(), + }); + } + // if we have a version as well as a git data OR only one git data, something is funky + if tk.versions.is_some() && (tk.git_url.is_some() || tk.git_hash.is_some()) + || tk.git_hash.is_some() != tk.git_url.is_some() + { + eprintln!("tomlkrate: {:?}", tk); + if tk.git_hash.is_some() != tk.git_url.is_some() { + panic!("Error: Encountered TomlCrate with only one of git_hash and git_url!"); + } + if tk.path.is_some() && (tk.git_hash.is_some() || tk.versions.is_some()) { + panic!("Error: TomlCrate can only have one of 'git_.*', 'version' or 'path' fields"); + } + unreachable!("Failed to translate TomlCrate into CrateSource!"); + } + }); + // sort the crates + crate_sources.sort(); + + crate_sources +} + +/// Parse the json output of clippy and return a `ClippyWarning` +fn parse_json_message(json_message: &str, krate: &Crate) -> ClippyWarning { + let jmsg: Value = serde_json::from_str(&json_message).unwrap_or_else(|e| panic!("Failed to parse json:\n{:?}", e)); + + ClippyWarning { + crate_name: krate.name.to_string(), + crate_version: krate.version.to_string(), + file: jmsg["message"]["spans"][0]["file_name"] + .to_string() + .trim_matches('"') + .into(), + line: jmsg["message"]["spans"][0]["line_start"] + .to_string() + .trim_matches('"') + .into(), + column: jmsg["message"]["spans"][0]["text"][0]["highlight_start"] + .to_string() + .trim_matches('"') + .into(), + linttype: jmsg["message"]["code"]["code"].to_string().trim_matches('"').into(), + message: jmsg["message"]["message"].to_string().trim_matches('"').into(), + is_ice: json_message.contains("internal compiler error: "), + } +} + +/// Generate a short list of occuring lints-types and their count +fn gather_stats(clippy_warnings: &[ClippyWarning]) -> (String, HashMap<&String, usize>) { + // count lint type occurrences + let mut counter: HashMap<&String, usize> = HashMap::new(); + clippy_warnings + .iter() + .for_each(|wrn| *counter.entry(&wrn.linttype).or_insert(0) += 1); + + // collect into a tupled list for sorting + let mut stats: Vec<(&&String, &usize)> = counter.iter().map(|(lint, count)| (lint, count)).collect(); + // sort by "000{count} {clippy::lintname}" + // to not have a lint with 200 and 2 warnings take the same spot + stats.sort_by_key(|(lint, count)| format!("{:0>4}, {}", count, lint)); + + let stats_string = stats + .iter() + .map(|(lint, count)| format!("{} {}\n", lint, count)) + .collect::(); + + (stats_string, counter) +} + +/// check if the latest modification of the logfile is older than the modification date of the +/// clippy binary, if this is true, we should clean the lintchec shared target directory and recheck +fn lintcheck_needs_rerun(lintcheck_logs_path: &Path) -> bool { + if !lintcheck_logs_path.exists() { + return true; + } + + let clippy_modified: std::time::SystemTime = { + let mut times = [CLIPPY_DRIVER_PATH, CARGO_CLIPPY_PATH].iter().map(|p| { + std::fs::metadata(p) + .expect("failed to get metadata of file") + .modified() + .expect("failed to get modification date") + }); + // the oldest modification of either of the binaries + std::cmp::max(times.next().unwrap(), times.next().unwrap()) + }; + + let logs_modified: std::time::SystemTime = std::fs::metadata(lintcheck_logs_path) + .expect("failed to get metadata of file") + .modified() + .expect("failed to get modification date"); + + // time is represented in seconds since X + // logs_modified 2 and clippy_modified 5 means clippy binary is older and we need to recheck + logs_modified < clippy_modified +} + +/// lintchecks `main()` function +/// +/// # Panics +/// +/// This function panics if the clippy binaries don't exist. +pub fn main() { + let clap_config = &get_clap_config(); + + let config = LintcheckConfig::from_clap(clap_config); + + println!("Compiling clippy..."); + build_clippy(); + println!("Done compiling"); + + // if the clippy bin is newer than our logs, throw away target dirs to force clippy to + // refresh the logs + if lintcheck_needs_rerun(&config.lintcheck_results_path) { + let shared_target_dir = "target/lintcheck/shared_target_dir"; + // if we get an Err here, the shared target dir probably does simply not exist + if let Ok(metadata) = std::fs::metadata(&shared_target_dir) { + if metadata.is_dir() { + println!("Clippy is newer than lint check logs, clearing lintcheck shared target dir..."); + std::fs::remove_dir_all(&shared_target_dir) + .expect("failed to remove target/lintcheck/shared_target_dir"); + } + } + } + + let cargo_clippy_path: PathBuf = PathBuf::from(CARGO_CLIPPY_PATH) + .canonicalize() + .expect("failed to canonicalize path to clippy binary"); + + // assert that clippy is found + assert!( + cargo_clippy_path.is_file(), + "target/debug/cargo-clippy binary not found! {}", + cargo_clippy_path.display() + ); + + let clippy_ver = std::process::Command::new(CARGO_CLIPPY_PATH) + .arg("--version") + .output() + .map(|o| String::from_utf8_lossy(&o.stdout).into_owned()) + .expect("could not get clippy version!"); + + // download and extract the crates, then run clippy on them and collect clippys warnings + // flatten into one big list of warnings + + let crates = read_crates(&config.sources_toml_path); + let old_stats = read_stats_from_file(&config.lintcheck_results_path); + + let counter = AtomicUsize::new(1); + + let clippy_warnings: Vec = if let Some(only_one_crate) = clap_config.value_of("only") { + // if we don't have the specified crate in the .toml, throw an error + if !crates.iter().any(|krate| { + let name = match krate { + CrateSource::CratesIo { name, .. } | CrateSource::Git { name, .. } | CrateSource::Path { name, .. } => { + name + }, + }; + name == only_one_crate + }) { + eprintln!( + "ERROR: could not find crate '{}' in clippy_dev/lintcheck_crates.toml", + only_one_crate + ); + std::process::exit(1); + } + + // only check a single crate that was passed via cmdline + crates + .into_iter() + .map(|krate| krate.download_and_extract()) + .filter(|krate| krate.name == only_one_crate) + .flat_map(|krate| krate.run_clippy_lints(&cargo_clippy_path, &AtomicUsize::new(0), 1, 1, config.fix)) + .collect() + } else { + if config.max_jobs > 1 { + // run parallel with rayon + + // Ask rayon for thread count. Assume that half of that is the number of physical cores + // Use one target dir for each core so that we can run N clippys in parallel. + // We need to use different target dirs because cargo would lock them for a single build otherwise, + // killing the parallelism. However this also means that deps will only be reused half/a + // quarter of the time which might result in a longer wall clock runtime + + // This helps when we check many small crates with dep-trees that don't have a lot of branches in + // order to achive some kind of parallelism + + // by default, use a single thread + let num_cpus = config.max_jobs; + let num_crates = crates.len(); + + // check all crates (default) + crates + .into_par_iter() + .map(|krate| krate.download_and_extract()) + .flat_map(|krate| { + krate.run_clippy_lints(&cargo_clippy_path, &counter, num_cpus, num_crates, config.fix) + }) + .collect() + } else { + // run sequential + let num_crates = crates.len(); + crates + .into_iter() + .map(|krate| krate.download_and_extract()) + .flat_map(|krate| krate.run_clippy_lints(&cargo_clippy_path, &counter, 1, num_crates, config.fix)) + .collect() + } + }; + + // if we are in --fix mode, don't change the log files, terminate here + if config.fix { + return; + } + + // generate some stats + let (stats_formatted, new_stats) = gather_stats(&clippy_warnings); + + // grab crashes/ICEs, save the crate name and the ice message + let ices: Vec<(&String, &String)> = clippy_warnings + .iter() + .filter(|warning| warning.is_ice) + .map(|w| (&w.crate_name, &w.message)) + .collect(); + + let mut all_msgs: Vec = clippy_warnings.iter().map(ToString::to_string).collect(); + all_msgs.sort(); + all_msgs.push("\n\n\n\nStats:\n".into()); + all_msgs.push(stats_formatted); + + // save the text into lintcheck-logs/logs.txt + let mut text = clippy_ver; // clippy version number on top + text.push_str(&format!("\n{}", all_msgs.join(""))); + text.push_str("ICEs:\n"); + ices.iter() + .for_each(|(cratename, msg)| text.push_str(&format!("{}: '{}'", cratename, msg))); + + println!("Writing logs to {}", config.lintcheck_results_path.display()); + write(&config.lintcheck_results_path, text).unwrap(); + + print_stats(old_stats, new_stats); +} + +/// read the previous stats from the lintcheck-log file +fn read_stats_from_file(file_path: &Path) -> HashMap { + let file_content: String = match std::fs::read_to_string(file_path).ok() { + Some(content) => content, + None => { + return HashMap::new(); + }, + }; + + let lines: Vec = file_content.lines().map(ToString::to_string).collect(); + + // search for the beginning "Stats:" and the end "ICEs:" of the section we want + let start = lines.iter().position(|line| line == "Stats:").unwrap(); + let end = lines.iter().position(|line| line == "ICEs:").unwrap(); + + let stats_lines = &lines[start + 1..end]; + + stats_lines + .iter() + .map(|line| { + let mut spl = line.split(' '); + ( + spl.next().unwrap().to_string(), + spl.next().unwrap().parse::().unwrap(), + ) + }) + .collect::>() +} + +/// print how lint counts changed between runs +fn print_stats(old_stats: HashMap, new_stats: HashMap<&String, usize>) { + let same_in_both_hashmaps = old_stats + .iter() + .filter(|(old_key, old_val)| new_stats.get::<&String>(&old_key) == Some(old_val)) + .map(|(k, v)| (k.to_string(), *v)) + .collect::>(); + + let mut old_stats_deduped = old_stats; + let mut new_stats_deduped = new_stats; + + // remove duplicates from both hashmaps + same_in_both_hashmaps.iter().for_each(|(k, v)| { + assert!(old_stats_deduped.remove(k) == Some(*v)); + assert!(new_stats_deduped.remove(k) == Some(*v)); + }); + + println!("\nStats:"); + + // list all new counts (key is in new stats but not in old stats) + new_stats_deduped + .iter() + .filter(|(new_key, _)| old_stats_deduped.get::(&new_key).is_none()) + .for_each(|(new_key, new_value)| { + println!("{} 0 => {}", new_key, new_value); + }); + + // list all changed counts (key is in both maps but value differs) + new_stats_deduped + .iter() + .filter(|(new_key, _new_val)| old_stats_deduped.get::(&new_key).is_some()) + .for_each(|(new_key, new_val)| { + let old_val = old_stats_deduped.get::(&new_key).unwrap(); + println!("{} {} => {}", new_key, old_val, new_val); + }); + + // list all gone counts (key is in old status but not in new stats) + old_stats_deduped + .iter() + .filter(|(old_key, _)| new_stats_deduped.get::<&String>(&old_key).is_none()) + .for_each(|(old_key, old_value)| { + println!("{} {} => 0", old_key, old_value); + }); +} + +/// Create necessary directories to run the lintcheck tool. +/// +/// # Panics +/// +/// This function panics if creating one of the dirs fails. +fn create_dirs(krate_download_dir: &Path, extract_dir: &Path) { + std::fs::create_dir("target/lintcheck/").unwrap_or_else(|err| { + if err.kind() != ErrorKind::AlreadyExists { + panic!("cannot create lintcheck target dir"); + } + }); + std::fs::create_dir(&krate_download_dir).unwrap_or_else(|err| { + if err.kind() != ErrorKind::AlreadyExists { + panic!("cannot create crate download dir"); + } + }); + std::fs::create_dir(&extract_dir).unwrap_or_else(|err| { + if err.kind() != ErrorKind::AlreadyExists { + panic!("cannot create crate extraction dir"); + } + }); +} + +fn get_clap_config<'a>() -> ArgMatches<'a> { + let lintcheck_sbcmd = SubCommand::with_name("lintcheck") + .about("run clippy on a set of crates and check output") + .arg( + Arg::with_name("only") + .takes_value(true) + .value_name("CRATE") + .long("only") + .help("only process a single crate of the list"), + ) + .arg( + Arg::with_name("crates-toml") + .takes_value(true) + .value_name("CRATES-SOURCES-TOML-PATH") + .long("crates-toml") + .help("set the path for a crates.toml where lintcheck should read the sources from"), + ) + .arg( + Arg::with_name("threads") + .takes_value(true) + .value_name("N") + .short("j") + .long("jobs") + .help("number of threads to use, 0 automatic choice"), + ) + .arg(Arg::with_name("fix").help("runs cargo clippy --fix and checks if all suggestions apply")); + + let app = App::new("Clippy developer tooling"); + + let app = app.subcommand(lintcheck_sbcmd); + + app.get_matches() +} + +/// Returns the path to the Clippy project directory +/// +/// # Panics +/// +/// Panics if the current directory could not be retrieved, there was an error reading any of the +/// Cargo.toml files or ancestor directory is the clippy root directory +#[must_use] +pub fn clippy_project_root() -> PathBuf { + let current_dir = std::env::current_dir().unwrap(); + for path in current_dir.ancestors() { + let result = std::fs::read_to_string(path.join("Cargo.toml")); + if let Err(err) = &result { + if err.kind() == std::io::ErrorKind::NotFound { + continue; + } + } + + let content = result.unwrap(); + if content.contains("[package]\nname = \"clippy\"") { + return path.to_path_buf(); + } + } + panic!("error: Can't determine root of project. Please run inside a Clippy working dir."); +} + +#[test] +fn lintcheck_test() { + let args = [ + "run", + "--target-dir", + "clippy_dev/target", + "--package", + "clippy_dev", + "--bin", + "clippy_dev", + "--manifest-path", + "clippy_dev/Cargo.toml", + "--features", + "lintcheck", + "--", + "lintcheck", + "--crates-toml", + "clippy_dev/test_sources.toml", + ]; + let status = std::process::Command::new("cargo") + .args(&args) + .current_dir("../" /* repo root */) + .status(); + + assert!(status.unwrap().success()); +} -- cgit 1.4.1-3-g733a5 From b068b742ee9dac585cdaf781a09bbdabba9c27a4 Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Thu, 11 Mar 2021 15:18:56 +0100 Subject: lintcheck: fix --fix and document it in the readme. also hook lintcheck into clippy-dev so that `clippy dev fmt` formats it. --- clippy_dev/src/fmt.rs | 1 + lintcheck/README.md | 6 ++++++ lintcheck/src/main.rs | 6 +++++- 3 files changed, 12 insertions(+), 1 deletion(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/fmt.rs b/clippy_dev/src/fmt.rs index 4d0fdadbd85..a26d6aba10d 100644 --- a/clippy_dev/src/fmt.rs +++ b/clippy_dev/src/fmt.rs @@ -54,6 +54,7 @@ pub fn run(check: bool, verbose: bool) { success &= cargo_fmt(context, project_root.as_path())?; success &= cargo_fmt(context, &project_root.join("clippy_dev"))?; success &= cargo_fmt(context, &project_root.join("rustc_tools_util"))?; + success &= cargo_fmt(context, &project_root.join("lintcheck"))?; for entry in WalkDir::new(project_root.join("tests")) { let entry = entry?; diff --git a/lintcheck/README.md b/lintcheck/README.md index 68dbf564014..983f59efdbd 100644 --- a/lintcheck/README.md +++ b/lintcheck/README.md @@ -67,3 +67,9 @@ is checked. **Note:** `-Wclippy::all` is always enabled by default, unless `-Aclippy::all` is explicitly specified in the options. + +### Fix mode +You can run `./lintcheck/target/debug/lintcheck --fix` which will run Clippy with `-Zunstable-options --fix` and print a warning if Clippys suggestions fail to apply (if the resulting code does not build). +This lets us spot bad suggestions or false positives automatically in some cases. + +Please note that the target dir should be cleaned afterwards since clippy will modify the downloaded sources which can lead to unexpected results when running lintcheck again afterwards. \ No newline at end of file diff --git a/lintcheck/src/main.rs b/lintcheck/src/main.rs index 1964afd3609..4028be0bf65 100644 --- a/lintcheck/src/main.rs +++ b/lintcheck/src/main.rs @@ -862,7 +862,11 @@ fn get_clap_config<'a>() -> ArgMatches<'a> { .long("jobs") .help("number of threads to use, 0 automatic choice"), ) - .arg(Arg::with_name("fix").help("runs cargo clippy --fix and checks if all suggestions apply")) + .arg( + Arg::with_name("fix") + .long("--fix") + .help("runs cargo clippy --fix and checks if all suggestions apply"), + ) .get_matches() } -- cgit 1.4.1-3-g733a5 From a62e4263d5251e9c3eb36a22cb1670b42656b554 Mon Sep 17 00:00:00 2001 From: Matthias Krüger Date: Wed, 17 Mar 2021 10:12:20 +0100 Subject: rename `cargo dev ra_setup` to `cargo dev ide_setup` --- clippy_dev/src/fmt.rs | 2 +- clippy_dev/src/ide_setup.rs | 103 ++++++++++++++++++++++++++++++++++++++++++++ clippy_dev/src/lib.rs | 2 +- clippy_dev/src/main.rs | 8 ++-- clippy_dev/src/ra_setup.rs | 103 -------------------------------------------- doc/basics.md | 2 +- 6 files changed, 110 insertions(+), 110 deletions(-) create mode 100644 clippy_dev/src/ide_setup.rs delete mode 100644 clippy_dev/src/ra_setup.rs (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/fmt.rs b/clippy_dev/src/fmt.rs index a26d6aba10d..111c79c332d 100644 --- a/clippy_dev/src/fmt.rs +++ b/clippy_dev/src/fmt.rs @@ -90,7 +90,7 @@ pub fn run(check: bool, verbose: bool) { }, CliError::RaSetupActive => { eprintln!( - "error: a local rustc repo is enabled as path dependency via `cargo dev ra_setup`. + "error: a local rustc repo is enabled as path dependency via `cargo dev ide_setup`. Not formatting because that would format the local repo as well! Please revert the changes to Cargo.tomls first." ); diff --git a/clippy_dev/src/ide_setup.rs b/clippy_dev/src/ide_setup.rs new file mode 100644 index 00000000000..defb1133e44 --- /dev/null +++ b/clippy_dev/src/ide_setup.rs @@ -0,0 +1,103 @@ +use std::fs; +use std::fs::File; +use std::io::prelude::*; +use std::path::{Path, PathBuf}; + +// This module takes an absolute path to a rustc repo and alters the dependencies to point towards +// the respective rustc subcrates instead of using extern crate xyz. +// This allows rust analyzer to analyze rustc internals and show proper information inside clippy +// code. See https://github.com/rust-analyzer/rust-analyzer/issues/3517 and https://github.com/rust-lang/rust-clippy/issues/5514 for details + +/// # Panics +/// +/// Panics if `rustc_path` does not lead to a rustc repo or the files could not be read +pub fn run(rustc_path: Option<&str>) { + // we can unwrap here because the arg is required by clap + let rustc_path = PathBuf::from(rustc_path.unwrap()) + .canonicalize() + .expect("failed to get the absolute repo path"); + assert!(rustc_path.is_dir(), "path is not a directory"); + let rustc_source_basedir = rustc_path.join("compiler"); + assert!( + rustc_source_basedir.is_dir(), + "are you sure the path leads to a rustc repo?" + ); + + let clippy_root_manifest = fs::read_to_string("Cargo.toml").expect("failed to read ./Cargo.toml"); + let clippy_root_lib_rs = fs::read_to_string("src/driver.rs").expect("failed to read ./src/driver.rs"); + inject_deps_into_manifest( + &rustc_source_basedir, + "Cargo.toml", + &clippy_root_manifest, + &clippy_root_lib_rs, + ) + .expect("Failed to inject deps into ./Cargo.toml"); + + let clippy_lints_manifest = + fs::read_to_string("clippy_lints/Cargo.toml").expect("failed to read ./clippy_lints/Cargo.toml"); + let clippy_lints_lib_rs = + fs::read_to_string("clippy_lints/src/lib.rs").expect("failed to read ./clippy_lints/src/lib.rs"); + inject_deps_into_manifest( + &rustc_source_basedir, + "clippy_lints/Cargo.toml", + &clippy_lints_manifest, + &clippy_lints_lib_rs, + ) + .expect("Failed to inject deps into ./clippy_lints/Cargo.toml"); +} + +fn inject_deps_into_manifest( + rustc_source_dir: &Path, + manifest_path: &str, + cargo_toml: &str, + lib_rs: &str, +) -> std::io::Result<()> { + // do not inject deps if we have aleady done so + if cargo_toml.contains("[target.'cfg(NOT_A_PLATFORM)'.dependencies]") { + eprintln!( + "cargo dev ide_setup: warning: deps already found inside {}, doing nothing.", + manifest_path + ); + return Ok(()); + } + + let extern_crates = lib_rs + .lines() + // get the deps + .filter(|line| line.starts_with("extern crate")) + // we have something like "extern crate foo;", we only care about the "foo" + // ↓ ↓ + // extern crate rustc_middle; + .map(|s| &s[13..(s.len() - 1)]); + + let new_deps = extern_crates.map(|dep| { + // format the dependencies that are going to be put inside the Cargo.toml + format!( + "{dep} = {{ path = \"{source_path}/{dep}\" }}\n", + dep = dep, + source_path = rustc_source_dir.display() + ) + }); + + // format a new [dependencies]-block with the new deps we need to inject + let mut all_deps = String::from("[target.'cfg(NOT_A_PLATFORM)'.dependencies]\n"); + new_deps.for_each(|dep_line| { + all_deps.push_str(&dep_line); + }); + all_deps.push_str("\n[dependencies]\n"); + + // replace "[dependencies]" with + // [dependencies] + // dep1 = { path = ... } + // dep2 = { path = ... } + // etc + let new_manifest = cargo_toml.replacen("[dependencies]\n", &all_deps, 1); + + // println!("{}", new_manifest); + let mut file = File::create(manifest_path)?; + file.write_all(new_manifest.as_bytes())?; + + println!("Dependency paths injected: {}", manifest_path); + + Ok(()) +} diff --git a/clippy_dev/src/lib.rs b/clippy_dev/src/lib.rs index a95abfaceaa..a5e94683878 100644 --- a/clippy_dev/src/lib.rs +++ b/clippy_dev/src/lib.rs @@ -12,8 +12,8 @@ use walkdir::WalkDir; pub mod bless; pub mod fmt; +pub mod ide_setup; pub mod new_lint; -pub mod ra_setup; pub mod serve; pub mod stderr_length_check; pub mod update_lints; diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index 2a9f3e5348c..f4da783502c 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -1,7 +1,7 @@ #![cfg_attr(feature = "deny-warnings", deny(warnings))] use clap::{App, Arg, ArgMatches, SubCommand}; -use clippy_dev::{bless, fmt, new_lint, ra_setup, serve, stderr_length_check, update_lints}; +use clippy_dev::{bless, fmt, ide_setup, new_lint, serve, stderr_length_check, update_lints}; fn main() { let matches = get_clap_config(); @@ -34,7 +34,7 @@ fn main() { ("limit_stderr_length", _) => { stderr_length_check::check(); }, - ("ra_setup", Some(matches)) => ra_setup::run(matches.value_of("rustc-repo-path")), + ("ide_setup", Some(matches)) => ide_setup::run(matches.value_of("rustc-repo-path")), ("serve", Some(matches)) => { let port = matches.value_of("port").unwrap().parse().unwrap(); let lint = matches.value_of("lint"); @@ -138,8 +138,8 @@ fn get_clap_config<'a>() -> ArgMatches<'a> { .about("Ensures that stderr files do not grow longer than a certain amount of lines."), ) .subcommand( - SubCommand::with_name("ra_setup") - .about("Alter dependencies so rust-analyzer can find rustc internals") + SubCommand::with_name("ide_setup") + .about("Alter dependencies so Intellij Rust can find rustc internals") .arg( Arg::with_name("rustc-repo-path") .long("repo-path") diff --git a/clippy_dev/src/ra_setup.rs b/clippy_dev/src/ra_setup.rs deleted file mode 100644 index d0e2193ddc5..00000000000 --- a/clippy_dev/src/ra_setup.rs +++ /dev/null @@ -1,103 +0,0 @@ -use std::fs; -use std::fs::File; -use std::io::prelude::*; -use std::path::{Path, PathBuf}; - -// This module takes an absolute path to a rustc repo and alters the dependencies to point towards -// the respective rustc subcrates instead of using extern crate xyz. -// This allows rust analyzer to analyze rustc internals and show proper information inside clippy -// code. See https://github.com/rust-analyzer/rust-analyzer/issues/3517 and https://github.com/rust-lang/rust-clippy/issues/5514 for details - -/// # Panics -/// -/// Panics if `rustc_path` does not lead to a rustc repo or the files could not be read -pub fn run(rustc_path: Option<&str>) { - // we can unwrap here because the arg is required by clap - let rustc_path = PathBuf::from(rustc_path.unwrap()) - .canonicalize() - .expect("failed to get the absolute repo path"); - assert!(rustc_path.is_dir(), "path is not a directory"); - let rustc_source_basedir = rustc_path.join("compiler"); - assert!( - rustc_source_basedir.is_dir(), - "are you sure the path leads to a rustc repo?" - ); - - let clippy_root_manifest = fs::read_to_string("Cargo.toml").expect("failed to read ./Cargo.toml"); - let clippy_root_lib_rs = fs::read_to_string("src/driver.rs").expect("failed to read ./src/driver.rs"); - inject_deps_into_manifest( - &rustc_source_basedir, - "Cargo.toml", - &clippy_root_manifest, - &clippy_root_lib_rs, - ) - .expect("Failed to inject deps into ./Cargo.toml"); - - let clippy_lints_manifest = - fs::read_to_string("clippy_lints/Cargo.toml").expect("failed to read ./clippy_lints/Cargo.toml"); - let clippy_lints_lib_rs = - fs::read_to_string("clippy_lints/src/lib.rs").expect("failed to read ./clippy_lints/src/lib.rs"); - inject_deps_into_manifest( - &rustc_source_basedir, - "clippy_lints/Cargo.toml", - &clippy_lints_manifest, - &clippy_lints_lib_rs, - ) - .expect("Failed to inject deps into ./clippy_lints/Cargo.toml"); -} - -fn inject_deps_into_manifest( - rustc_source_dir: &Path, - manifest_path: &str, - cargo_toml: &str, - lib_rs: &str, -) -> std::io::Result<()> { - // do not inject deps if we have aleady done so - if cargo_toml.contains("[target.'cfg(NOT_A_PLATFORM)'.dependencies]") { - eprintln!( - "cargo dev ra_setup: warning: deps already found inside {}, doing nothing.", - manifest_path - ); - return Ok(()); - } - - let extern_crates = lib_rs - .lines() - // get the deps - .filter(|line| line.starts_with("extern crate")) - // we have something like "extern crate foo;", we only care about the "foo" - // ↓ ↓ - // extern crate rustc_middle; - .map(|s| &s[13..(s.len() - 1)]); - - let new_deps = extern_crates.map(|dep| { - // format the dependencies that are going to be put inside the Cargo.toml - format!( - "{dep} = {{ path = \"{source_path}/{dep}\" }}\n", - dep = dep, - source_path = rustc_source_dir.display() - ) - }); - - // format a new [dependencies]-block with the new deps we need to inject - let mut all_deps = String::from("[target.'cfg(NOT_A_PLATFORM)'.dependencies]\n"); - new_deps.for_each(|dep_line| { - all_deps.push_str(&dep_line); - }); - all_deps.push_str("\n[dependencies]\n"); - - // replace "[dependencies]" with - // [dependencies] - // dep1 = { path = ... } - // dep2 = { path = ... } - // etc - let new_manifest = cargo_toml.replacen("[dependencies]\n", &all_deps, 1); - - // println!("{}", new_manifest); - let mut file = File::create(manifest_path)?; - file.write_all(new_manifest.as_bytes())?; - - println!("Dependency paths injected: {}", manifest_path); - - Ok(()) -} diff --git a/doc/basics.md b/doc/basics.md index e00b61be041..5226875cc21 100644 --- a/doc/basics.md +++ b/doc/basics.md @@ -89,7 +89,7 @@ cargo dev update_lints # create a new lint and register it cargo dev new_lint # (experimental) Setup Clippy to work with IntelliJ-Rust -cargo dev ra_setup +cargo dev ide_setup ``` ## lintcheck -- cgit 1.4.1-3-g733a5 From 12fce557669a0de230399cf8e6eee4f5307bf87b Mon Sep 17 00:00:00 2001 From: Jason Newcomb Date: Fri, 2 Apr 2021 17:35:32 -0400 Subject: Fix all occurences of `needless_borrow` internally --- clippy_dev/src/fmt.rs | 2 +- clippy_dev/src/lib.rs | 16 +- clippy_lints/src/absurd_extreme_comparisons.rs | 4 +- clippy_lints/src/assertions_on_constants.rs | 12 +- clippy_lints/src/atomic_ordering.rs | 6 +- clippy_lints/src/attrs.rs | 4 +- clippy_lints/src/await_holding_invalid.rs | 2 +- clippy_lints/src/bytecount.rs | 14 +- clippy_lints/src/casts/cast_ptr_alignment.rs | 2 +- clippy_lints/src/casts/cast_sign_loss.rs | 6 +- clippy_lints/src/casts/mod.rs | 2 +- clippy_lints/src/checked_conversions.rs | 16 +- clippy_lints/src/cognitive_complexity.rs | 2 +- clippy_lints/src/comparison_chain.rs | 6 +- clippy_lints/src/copies.rs | 6 +- clippy_lints/src/create_dir.rs | 2 +- clippy_lints/src/default.rs | 10 +- clippy_lints/src/derive.rs | 4 +- clippy_lints/src/doc.rs | 4 +- clippy_lints/src/double_comparison.rs | 4 +- clippy_lints/src/double_parens.rs | 6 +- clippy_lints/src/drop_forget_ref.rs | 2 +- clippy_lints/src/duration_subsec.rs | 4 +- clippy_lints/src/entry.rs | 16 +- clippy_lints/src/eq_op.rs | 14 +- clippy_lints/src/erasing_op.rs | 2 +- clippy_lints/src/eta_reduction.rs | 18 +- clippy_lints/src/eval_order_dependence.rs | 18 +- clippy_lints/src/exit.rs | 2 +- clippy_lints/src/explicit_write.rs | 10 +- clippy_lints/src/fallible_impl_from.rs | 4 +- clippy_lints/src/float_equality_without_abs.rs | 6 +- clippy_lints/src/floating_point_arithmetic.rs | 42 +- clippy_lints/src/format.rs | 38 +- clippy_lints/src/functions/must_use.rs | 28 +- .../src/functions/not_unsafe_ptr_arg_deref.rs | 6 +- clippy_lints/src/functions/result_unit_err.rs | 8 +- clippy_lints/src/functions/too_many_arguments.rs | 2 +- clippy_lints/src/get_last_with_len.rs | 2 +- clippy_lints/src/identity_op.rs | 2 +- clippy_lints/src/if_let_mutex.rs | 6 +- clippy_lints/src/if_let_some_result.rs | 6 +- clippy_lints/src/if_then_some_else_none.rs | 12 +- clippy_lints/src/implicit_hasher.rs | 6 +- clippy_lints/src/implicit_return.rs | 4 +- clippy_lints/src/implicit_saturating_sub.rs | 16 +- clippy_lints/src/indexing_slicing.rs | 2 +- clippy_lints/src/infinite_iter.rs | 12 +- clippy_lints/src/invalid_upcast_comparisons.rs | 6 +- clippy_lints/src/large_enum_variant.rs | 2 +- clippy_lints/src/len_zero.rs | 15 +- clippy_lints/src/let_if_seq.rs | 24 +- clippy_lints/src/let_underscore.rs | 2 +- clippy_lints/src/lib.rs | 2446 ++++++++++---------- clippy_lints/src/lifetimes.rs | 20 +- clippy_lints/src/literal_representation.rs | 4 +- clippy_lints/src/loops/explicit_counter_loop.rs | 2 +- clippy_lints/src/loops/for_kv_map.rs | 4 +- clippy_lints/src/loops/manual_flatten.rs | 4 +- clippy_lints/src/loops/manual_memcpy.rs | 10 +- clippy_lints/src/loops/mod.rs | 6 +- clippy_lints/src/loops/needless_collect.rs | 24 +- clippy_lints/src/loops/needless_range_loop.rs | 18 +- clippy_lints/src/loops/never_loop.rs | 46 +- clippy_lints/src/loops/same_item_push.rs | 2 +- clippy_lints/src/loops/single_element_loop.rs | 4 +- clippy_lints/src/loops/utils.rs | 16 +- clippy_lints/src/loops/while_let_loop.rs | 12 +- clippy_lints/src/loops/while_let_on_iterator.rs | 12 +- clippy_lints/src/manual_strip.rs | 4 +- clippy_lints/src/map_clone.rs | 10 +- clippy_lints/src/map_err_ignore.rs | 2 +- clippy_lints/src/map_identity.rs | 12 +- clippy_lints/src/map_unit_fn.rs | 12 +- clippy_lints/src/match_on_vec_items.rs | 4 +- clippy_lints/src/matches.rs | 81 +- clippy_lints/src/mem_discriminant.rs | 4 +- clippy_lints/src/mem_forget.rs | 2 +- clippy_lints/src/mem_replace.rs | 16 +- clippy_lints/src/methods/bind_instead_of_map.rs | 4 +- clippy_lints/src/methods/chars_cmp.rs | 2 +- clippy_lints/src/methods/expect_fun_call.rs | 8 +- clippy_lints/src/methods/filter_map.rs | 6 +- clippy_lints/src/methods/flat_map_identity.rs | 2 +- clippy_lints/src/methods/implicit_clone.rs | 2 +- clippy_lints/src/methods/iter_next_slice.rs | 2 +- clippy_lints/src/methods/mod.rs | 22 +- clippy_lints/src/methods/option_as_ref_deref.rs | 6 +- clippy_lints/src/methods/or_fun_call.rs | 6 +- clippy_lints/src/methods/search_is_some.rs | 6 +- clippy_lints/src/methods/uninit_assumed_init.rs | 8 +- clippy_lints/src/methods/unnecessary_filter_map.rs | 14 +- clippy_lints/src/methods/unnecessary_fold.rs | 6 +- clippy_lints/src/methods/utils.rs | 2 +- clippy_lints/src/methods/zst_offset.rs | 2 +- clippy_lints/src/minmax.rs | 4 +- clippy_lints/src/misc.rs | 26 +- clippy_lints/src/missing_const_for_fn.rs | 2 +- clippy_lints/src/missing_inline.rs | 2 +- clippy_lints/src/mut_key.rs | 6 +- clippy_lints/src/mut_mut.rs | 4 +- clippy_lints/src/mut_reference.rs | 4 +- clippy_lints/src/needless_bool.rs | 18 +- clippy_lints/src/needless_borrow.rs | 2 +- clippy_lints/src/needless_borrowed_ref.rs | 2 +- clippy_lints/src/needless_for_each.rs | 2 +- clippy_lints/src/needless_pass_by_value.rs | 2 +- clippy_lints/src/needless_update.rs | 2 +- clippy_lints/src/neg_cmp_op_on_partial_ord.rs | 4 +- clippy_lints/src/neg_multiply.rs | 6 +- clippy_lints/src/no_effect.rs | 58 +- clippy_lints/src/non_octal_unix_permissions.rs | 4 +- clippy_lints/src/open_options.rs | 4 +- clippy_lints/src/option_if_let_else.rs | 8 +- clippy_lints/src/overflow_check_conditional.rs | 20 +- clippy_lints/src/pass_by_ref_or_value.rs | 4 +- clippy_lints/src/path_buf_push_overwrite.rs | 2 +- clippy_lints/src/pattern_type_mismatch.rs | 18 +- clippy_lints/src/ptr.rs | 22 +- clippy_lints/src/ptr_eq.rs | 8 +- clippy_lints/src/ptr_offset_with_cast.rs | 6 +- clippy_lints/src/question_mark.rs | 8 +- clippy_lints/src/ranges.rs | 24 +- clippy_lints/src/redundant_clone.rs | 10 +- clippy_lints/src/redundant_closure_call.rs | 16 +- clippy_lints/src/ref_option_ref.rs | 2 +- clippy_lints/src/regex.rs | 4 +- clippy_lints/src/repeat_once.rs | 4 +- clippy_lints/src/returns.rs | 16 +- clippy_lints/src/semicolon_if_nothing_returned.rs | 2 +- clippy_lints/src/shadow.rs | 69 +- clippy_lints/src/slow_vector_initialization.rs | 42 +- clippy_lints/src/strings.rs | 14 +- clippy_lints/src/suspicious_operation_groupings.rs | 16 +- clippy_lints/src/swap.rs | 30 +- clippy_lints/src/tabs_in_doc_comments.rs | 2 +- clippy_lints/src/to_string_in_display.rs | 2 +- clippy_lints/src/trait_bounds.rs | 4 +- clippy_lints/src/transmute/mod.rs | 2 +- .../src/transmute/transmute_float_to_int.rs | 2 +- clippy_lints/src/transmute/utils.rs | 2 +- clippy_lints/src/transmuting_null.rs | 6 +- clippy_lints/src/try_err.rs | 14 +- clippy_lints/src/types/borrowed_box.rs | 8 +- clippy_lints/src/types/mod.rs | 28 +- clippy_lints/src/types/type_complexity.rs | 4 +- clippy_lints/src/types/utils.rs | 2 +- clippy_lints/src/types/vec_box.rs | 4 +- clippy_lints/src/undropped_manually_drops.rs | 2 +- clippy_lints/src/unit_return_expecting_ord.rs | 2 +- clippy_lints/src/unit_types/let_unit_value.rs | 4 +- clippy_lints/src/unit_types/unit_arg.rs | 2 +- clippy_lints/src/unit_types/unit_cmp.rs | 4 +- clippy_lints/src/unit_types/utils.rs | 2 +- clippy_lints/src/unnamed_address.rs | 6 +- clippy_lints/src/unnecessary_sort_by.rs | 16 +- clippy_lints/src/unnecessary_wraps.rs | 2 +- clippy_lints/src/unused_io_amount.rs | 10 +- clippy_lints/src/unused_unit.rs | 2 +- clippy_lints/src/unwrap.rs | 4 +- clippy_lints/src/use_self.rs | 6 +- clippy_lints/src/useless_conversion.rs | 12 +- clippy_lints/src/utils/author.rs | 96 +- clippy_lints/src/utils/inspector.rs | 90 +- clippy_lints/src/utils/internal_lints.rs | 18 +- clippy_lints/src/vec.rs | 2 +- clippy_lints/src/vec_resize_to_zero.rs | 2 +- clippy_lints/src/zero_div_zero.rs | 2 +- clippy_lints/src/zero_sized_map_values.rs | 2 +- src/driver.rs | 12 +- tests/compile-test.rs | 16 +- tests/ui/borrow_interior_mutable_const/others.rs | 6 +- .../ui/borrow_interior_mutable_const/others.stderr | 28 +- tests/ui/collapsible_match2.rs | 7 +- tests/ui/collapsible_match2.stderr | 20 +- tests/ui/escape_analysis.rs | 4 +- tests/ui/implicit_clone.rs | 2 +- tests/ui/into_iter_on_ref.fixed | 2 +- tests/ui/into_iter_on_ref.rs | 2 +- tests/ui/ref_option_ref.rs | 2 +- tests/ui/ref_option_ref.stderr | 2 +- tests/ui/stable_sort_primitive.fixed | 2 +- tests/ui/stable_sort_primitive.rs | 2 +- 183 files changed, 2150 insertions(+), 2162 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/fmt.rs b/clippy_dev/src/fmt.rs index 111c79c332d..1517cdc9419 100644 --- a/clippy_dev/src/fmt.rs +++ b/clippy_dev/src/fmt.rs @@ -68,7 +68,7 @@ pub fn run(check: bool, verbose: bool) { continue; } - success &= rustfmt(context, &path)?; + success &= rustfmt(context, path)?; } Ok(success) diff --git a/clippy_dev/src/lib.rs b/clippy_dev/src/lib.rs index a5e94683878..1e5a140e964 100644 --- a/clippy_dev/src/lib.rs +++ b/clippy_dev/src/lib.rs @@ -101,7 +101,7 @@ impl Lint { #[must_use] pub fn gen_lint_group_list<'a>(lints: impl Iterator) -> Vec { lints - .map(|l| format!(" LintId::of(&{}::{}),", l.module, l.name.to_uppercase())) + .map(|l| format!(" LintId::of({}::{}),", l.module, l.name.to_uppercase())) .sorted() .collect::>() } @@ -154,17 +154,17 @@ pub fn gen_register_lint_list<'a>( let header = " store.register_lints(&[".to_string(); let footer = " ]);".to_string(); let internal_lints = internal_lints - .sorted_by_key(|l| format!(" &{}::{},", l.module, l.name.to_uppercase())) + .sorted_by_key(|l| format!(" {}::{},", l.module, l.name.to_uppercase())) .map(|l| { format!( - " #[cfg(feature = \"internal-lints\")]\n &{}::{},", + " #[cfg(feature = \"internal-lints\")]\n {}::{},", l.module, l.name.to_uppercase() ) }); let other_lints = usable_lints - .sorted_by_key(|l| format!(" &{}::{},", l.module, l.name.to_uppercase())) - .map(|l| format!(" &{}::{},", l.module, l.name.to_uppercase())) + .sorted_by_key(|l| format!(" {}::{},", l.module, l.name.to_uppercase())) + .map(|l| format!(" {}::{},", l.module, l.name.to_uppercase())) .sorted(); let mut lint_list = vec![header]; lint_list.extend(internal_lints); @@ -550,9 +550,9 @@ fn test_gen_lint_group_list() { Lint::new("internal", "internal_style", "abc", None, "module_name"), ]; let expected = vec![ - " LintId::of(&module_name::ABC),".to_string(), - " LintId::of(&module_name::INTERNAL),".to_string(), - " LintId::of(&module_name::SHOULD_ASSERT_EQ),".to_string(), + " LintId::of(module_name::ABC),".to_string(), + " LintId::of(module_name::INTERNAL),".to_string(), + " LintId::of(module_name::SHOULD_ASSERT_EQ),".to_string(), ]; assert_eq!(expected, gen_lint_group_list(lints.iter())); } diff --git a/clippy_lints/src/absurd_extreme_comparisons.rs b/clippy_lints/src/absurd_extreme_comparisons.rs index 33c720c666e..5fbf4bdbd18 100644 --- a/clippy_lints/src/absurd_extreme_comparisons.rs +++ b/clippy_lints/src/absurd_extreme_comparisons.rs @@ -44,7 +44,7 @@ declare_lint_pass!(AbsurdExtremeComparisons => [ABSURD_EXTREME_COMPARISONS]); impl<'tcx> LateLintPass<'tcx> for AbsurdExtremeComparisons { fn check_expr(&mut self, cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) { - if let ExprKind::Binary(ref cmp, ref lhs, ref rhs) = expr.kind { + if let ExprKind::Binary(ref cmp, lhs, rhs) = expr.kind { if let Some((culprit, result)) = detect_absurd_comparison(cx, cmp.node, lhs, rhs) { if !expr.span.from_expansion() { let msg = "this comparison involving the minimum or maximum element for this \ @@ -95,7 +95,7 @@ enum AbsurdComparisonResult { } fn is_cast_between_fixed_and_target<'tcx>(cx: &LateContext<'tcx>, expr: &'tcx Expr<'tcx>) -> bool { - if let ExprKind::Cast(ref cast_exp, _) = expr.kind { + if let ExprKind::Cast(cast_exp, _) = expr.kind { let precast_ty = cx.typeck_results().expr_ty(cast_exp); let cast_ty = cx.typeck_results().expr_ty(expr); diff --git a/clippy_lints/src/assertions_on_constants.rs b/clippy_lints/src/assertions_on_constants.rs index 16905781c56..a0993bb6913 100644 --- a/clippy_lints/src/assertions_on_constants.rs +++ b/clippy_lints/src/assertions_on_constants.rs @@ -71,7 +71,7 @@ impl<'tcx> LateLintPass<'tcx> for AssertionsOnConstants { return; } if_chain! { - if let ExprKind::Unary(_, ref lit) = e.kind; + if let ExprKind::Unary(_, lit) = e.kind; if let Some((Constant::Bool(is_true), _)) = constant(cx, cx.typeck_results(), lit); if is_true; then { @@ -82,7 +82,7 @@ impl<'tcx> LateLintPass<'tcx> for AssertionsOnConstants { if assert_span.from_expansion() { return; } - if let Some(assert_match) = match_assert_with_message(&cx, e) { + if let Some(assert_match) = match_assert_with_message(cx, e) { match assert_match { // matched assert but not message AssertKind::WithoutMessage(false) => lint_false_without_message(), @@ -113,17 +113,17 @@ enum AssertKind { /// where `message` is any expression and `c` is a constant bool. fn match_assert_with_message<'tcx>(cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) -> Option { if_chain! { - if let ExprKind::If(ref cond, ref then, _) = expr.kind; - if let ExprKind::Unary(UnOp::Not, ref expr) = cond.kind; + if let ExprKind::If(cond, then, _) = expr.kind; + if let ExprKind::Unary(UnOp::Not, expr) = cond.kind; // bind the first argument of the `assert!` macro if let Some((Constant::Bool(is_true), _)) = constant(cx, cx.typeck_results(), expr); // block - if let ExprKind::Block(ref block, _) = then.kind; + if let ExprKind::Block(block, _) = then.kind; if block.stmts.is_empty(); if let Some(block_expr) = &block.expr; // inner block is optional. unwrap it if it exists, or use the expression as is otherwise. if let Some(begin_panic_call) = match block_expr.kind { - ExprKind::Block(ref inner_block, _) => &inner_block.expr, + ExprKind::Block(inner_block, _) => &inner_block.expr, _ => &block.expr, }; // function call diff --git a/clippy_lints/src/atomic_ordering.rs b/clippy_lints/src/atomic_ordering.rs index dfb18199325..7ceb01f5590 100644 --- a/clippy_lints/src/atomic_ordering.rs +++ b/clippy_lints/src/atomic_ordering.rs @@ -85,7 +85,7 @@ fn match_ordering_def_path(cx: &LateContext<'_>, did: DefId, orderings: &[&str]) fn check_atomic_load_store(cx: &LateContext<'_>, expr: &Expr<'_>) { if_chain! { - if let ExprKind::MethodCall(ref method_path, _, args, _) = &expr.kind; + if let ExprKind::MethodCall(method_path, _, args, _) = &expr.kind; let method = method_path.ident.name.as_str(); if type_is_atomic(cx, &args[0]); if method == "load" || method == "store"; @@ -120,7 +120,7 @@ fn check_atomic_load_store(cx: &LateContext<'_>, expr: &Expr<'_>) { fn check_memory_fence(cx: &LateContext<'_>, expr: &Expr<'_>) { if_chain! { - if let ExprKind::Call(ref func, ref args) = expr.kind; + if let ExprKind::Call(func, args) = expr.kind; if let ExprKind::Path(ref func_qpath) = func.kind; if let Some(def_id) = cx.qpath_res(func_qpath, func.hir_id).opt_def_id(); if ["fence", "compiler_fence"] @@ -152,7 +152,7 @@ fn opt_ordering_defid(cx: &LateContext<'_>, ord_arg: &Expr<'_>) -> Option fn check_atomic_compare_exchange(cx: &LateContext<'_>, expr: &Expr<'_>) { if_chain! { - if let ExprKind::MethodCall(ref method_path, _, args, _) = &expr.kind; + if let ExprKind::MethodCall(method_path, _, args, _) = &expr.kind; let method = method_path.ident.name.as_str(); if type_is_atomic(cx, &args[0]); if method == "compare_exchange" || method == "compare_exchange_weak" || method == "fetch_update"; diff --git a/clippy_lints/src/attrs.rs b/clippy_lints/src/attrs.rs index 0ce46e1c214..382fb03d920 100644 --- a/clippy_lints/src/attrs.rs +++ b/clippy_lints/src/attrs.rs @@ -602,7 +602,7 @@ fn check_mismatched_target_os(cx: &EarlyContext<'_>, attr: &Attribute) { if let NestedMetaItem::MetaItem(meta) = item { match &meta.kind { MetaItemKind::List(list) => { - mismatched.extend(find_mismatched_target_os(&list)); + mismatched.extend(find_mismatched_target_os(list)); }, MetaItemKind::Word => { if_chain! { @@ -629,7 +629,7 @@ fn check_mismatched_target_os(cx: &EarlyContext<'_>, attr: &Attribute) { then { let mess = "operating system used in target family position"; - span_lint_and_then(cx, MISMATCHED_TARGET_OS, attr.span, &mess, |diag| { + span_lint_and_then(cx, MISMATCHED_TARGET_OS, attr.span, mess, |diag| { // Avoid showing the unix suggestion multiple times in case // we have more than one mismatch for unix-like systems let mut unix_suggested = false; diff --git a/clippy_lints/src/await_holding_invalid.rs b/clippy_lints/src/await_holding_invalid.rs index 68eee0520b3..1739a57a240 100644 --- a/clippy_lints/src/await_holding_invalid.rs +++ b/clippy_lints/src/await_holding_invalid.rs @@ -101,7 +101,7 @@ impl LateLintPass<'_> for AwaitHolding { let typeck_results = cx.tcx.typeck_body(body_id); check_interior_types( cx, - &typeck_results.generator_interior_types.as_ref().skip_binder(), + typeck_results.generator_interior_types.as_ref().skip_binder(), body.value.span, ); } diff --git a/clippy_lints/src/bytecount.rs b/clippy_lints/src/bytecount.rs index 1546d823167..877ae002d36 100644 --- a/clippy_lints/src/bytecount.rs +++ b/clippy_lints/src/bytecount.rs @@ -38,17 +38,17 @@ declare_lint_pass!(ByteCount => [NAIVE_BYTECOUNT]); impl<'tcx> LateLintPass<'tcx> for ByteCount { fn check_expr(&mut self, cx: &LateContext<'_>, expr: &Expr<'_>) { if_chain! { - if let ExprKind::MethodCall(ref count, _, ref count_args, _) = expr.kind; + if let ExprKind::MethodCall(count, _, count_args, _) = expr.kind; if count.ident.name == sym!(count); if count_args.len() == 1; - if let ExprKind::MethodCall(ref filter, _, ref filter_args, _) = count_args[0].kind; + if let ExprKind::MethodCall(filter, _, filter_args, _) = count_args[0].kind; if filter.ident.name == sym!(filter); if filter_args.len() == 2; if let ExprKind::Closure(_, _, body_id, _, _) = filter_args[1].kind; let body = cx.tcx.hir().body(body_id); if body.params.len() == 1; - if let Some(argname) = get_pat_name(&body.params[0].pat); - if let ExprKind::Binary(ref op, ref l, ref r) = body.value.kind; + if let Some(argname) = get_pat_name(body.params[0].pat); + if let ExprKind::Binary(ref op, l, r) = body.value.kind; if op.node == BinOpKind::Eq; if match_type(cx, cx.typeck_results().expr_ty(&filter_args[0]).peel_refs(), @@ -64,7 +64,7 @@ impl<'tcx> LateLintPass<'tcx> for ByteCount { if ty::Uint(UintTy::U8) != *cx.typeck_results().expr_ty(needle).peel_refs().kind() { return; } - let haystack = if let ExprKind::MethodCall(ref path, _, ref args, _) = + let haystack = if let ExprKind::MethodCall(path, _, args, _) = filter_args[0].kind { let p = path.ident.name; if (p == sym::iter || p == sym!(iter_mut)) && args.len() == 1 { @@ -98,10 +98,10 @@ fn check_arg(name: Symbol, arg: Symbol, needle: &Expr<'_>) -> bool { fn get_path_name(expr: &Expr<'_>) -> Option { match expr.kind { - ExprKind::Box(ref e) | ExprKind::AddrOf(BorrowKind::Ref, _, ref e) | ExprKind::Unary(UnOp::Deref, ref e) => { + ExprKind::Box(e) | ExprKind::AddrOf(BorrowKind::Ref, _, e) | ExprKind::Unary(UnOp::Deref, e) => { get_path_name(e) }, - ExprKind::Block(ref b, _) => { + ExprKind::Block(b, _) => { if b.stmts.is_empty() { b.expr.as_ref().and_then(|p| get_path_name(p)) } else { diff --git a/clippy_lints/src/casts/cast_ptr_alignment.rs b/clippy_lints/src/casts/cast_ptr_alignment.rs index 5208156ffd2..62a119d662b 100644 --- a/clippy_lints/src/casts/cast_ptr_alignment.rs +++ b/clippy_lints/src/casts/cast_ptr_alignment.rs @@ -10,7 +10,7 @@ use rustc_target::abi::LayoutOf; use super::CAST_PTR_ALIGNMENT; pub(super) fn check(cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) { - if let ExprKind::Cast(ref cast_expr, cast_to) = expr.kind { + if let ExprKind::Cast(cast_expr, cast_to) = expr.kind { if is_hir_ty_cfg_dependant(cx, cast_to) { return; } diff --git a/clippy_lints/src/casts/cast_sign_loss.rs b/clippy_lints/src/casts/cast_sign_loss.rs index bf722d0a3f4..040e0ca8864 100644 --- a/clippy_lints/src/casts/cast_sign_loss.rs +++ b/clippy_lints/src/casts/cast_sign_loss.rs @@ -30,7 +30,7 @@ fn should_lint(cx: &LateContext<'_>, cast_op: &Expr<'_>, cast_from: Ty<'_>, cast } // Don't lint for positive constants. - let const_val = constant(cx, &cx.typeck_results(), cast_op); + let const_val = constant(cx, cx.typeck_results(), cast_op); if_chain! { if let Some((Constant::Int(n), _)) = const_val; if let ty::Int(ity) = *cast_from.kind(); @@ -41,14 +41,14 @@ fn should_lint(cx: &LateContext<'_>, cast_op: &Expr<'_>, cast_from: Ty<'_>, cast } // Don't lint for the result of methods that always return non-negative values. - if let ExprKind::MethodCall(ref path, _, _, _) = cast_op.kind { + if let ExprKind::MethodCall(path, _, _, _) = cast_op.kind { let mut method_name = path.ident.name.as_str(); let allowed_methods = ["abs", "checked_abs", "rem_euclid", "checked_rem_euclid"]; if_chain! { if method_name == "unwrap"; if let Some(arglist) = method_chain_args(cast_op, &["unwrap"]); - if let ExprKind::MethodCall(ref inner_path, _, _, _) = &arglist[0][0].kind; + if let ExprKind::MethodCall(inner_path, _, _, _) = &arglist[0][0].kind; then { method_name = inner_path.ident.name.as_str(); } diff --git a/clippy_lints/src/casts/mod.rs b/clippy_lints/src/casts/mod.rs index d9e172c01a7..ae4fdd12c41 100644 --- a/clippy_lints/src/casts/mod.rs +++ b/clippy_lints/src/casts/mod.rs @@ -372,7 +372,7 @@ impl<'tcx> LateLintPass<'tcx> for Casts { return; } - if let ExprKind::Cast(ref cast_expr, cast_to) = expr.kind { + if let ExprKind::Cast(cast_expr, cast_to) = expr.kind { if is_hir_ty_cfg_dependant(cx, cast_to) { return; } diff --git a/clippy_lints/src/checked_conversions.rs b/clippy_lints/src/checked_conversions.rs index b38c70bcc41..d7136f84cc3 100644 --- a/clippy_lints/src/checked_conversions.rs +++ b/clippy_lints/src/checked_conversions.rs @@ -64,7 +64,7 @@ impl<'tcx> LateLintPass<'tcx> for CheckedConversions { let result = if_chain! { if !in_external_macro(cx.sess(), item.span); - if let ExprKind::Binary(op, ref left, ref right) = &item.kind; + if let ExprKind::Binary(op, left, right) = &item.kind; then { match op.node { @@ -200,7 +200,7 @@ impl ConversionType { /// Check for `expr <= (to_type::MAX as from_type)` fn check_upper_bound<'tcx>(expr: &'tcx Expr<'tcx>) -> Option> { if_chain! { - if let ExprKind::Binary(ref op, ref left, ref right) = &expr.kind; + if let ExprKind::Binary(ref op, left, right) = &expr.kind; if let Some((candidate, check)) = normalize_le_ge(op, left, right); if let Some((from, to)) = get_types_from_cast(check, INTS, "max_value", "MAX"); @@ -219,7 +219,7 @@ fn check_lower_bound<'tcx>(expr: &'tcx Expr<'tcx>) -> Option> { } // First of we need a binary containing the expression & the cast - if let ExprKind::Binary(ref op, ref left, ref right) = &expr.kind { + if let ExprKind::Binary(ref op, left, right) = &expr.kind { normalize_le_ge(op, right, left).and_then(|(l, r)| check_function(l, r)) } else { None @@ -260,7 +260,7 @@ fn get_types_from_cast<'a>( // or `to_type::MAX as from_type` let call_from_cast: Option<(&Expr<'_>, &str)> = if_chain! { // to_type::max_value(), from_type - if let ExprKind::Cast(ref limit, ref from_type) = &expr.kind; + if let ExprKind::Cast(limit, from_type) = &expr.kind; if let TyKind::Path(ref from_type_path) = &from_type.kind; if let Some(from_sym) = int_ty_to_sym(from_type_path); @@ -275,7 +275,7 @@ fn get_types_from_cast<'a>( let limit_from: Option<(&Expr<'_>, &str)> = call_from_cast.or_else(|| { if_chain! { // `from_type::from, to_type::max_value()` - if let ExprKind::Call(ref from_func, ref args) = &expr.kind; + if let ExprKind::Call(from_func, args) = &expr.kind; // `to_type::max_value()` if args.len() == 1; if let limit = &args[0]; @@ -317,9 +317,9 @@ fn get_types_from_cast<'a>( /// Gets the type which implements the called function fn get_implementing_type<'a>(path: &QPath<'_>, candidates: &'a [&str], function: &str) -> Option<&'a str> { if_chain! { - if let QPath::TypeRelative(ref ty, ref path) = &path; + if let QPath::TypeRelative(ty, path) = &path; if path.ident.name.as_str() == function; - if let TyKind::Path(QPath::Resolved(None, ref tp)) = &ty.kind; + if let TyKind::Path(QPath::Resolved(None, tp)) = &ty.kind; if let [int] = &*tp.segments; then { let name = &int.ident.name.as_str(); @@ -333,7 +333,7 @@ fn get_implementing_type<'a>(path: &QPath<'_>, candidates: &'a [&str], function: /// Gets the type as a string, if it is a supported integer fn int_ty_to_sym<'tcx>(path: &QPath<'_>) -> Option<&'tcx str> { if_chain! { - if let QPath::Resolved(_, ref path) = *path; + if let QPath::Resolved(_, path) = *path; if let [ty] = &*path.segments; then { let name = &ty.ident.name.as_str(); diff --git a/clippy_lints/src/cognitive_complexity.rs b/clippy_lints/src/cognitive_complexity.rs index 4cc542f723c..f62c6a9c325 100644 --- a/clippy_lints/src/cognitive_complexity.rs +++ b/clippy_lints/src/cognitive_complexity.rs @@ -152,7 +152,7 @@ impl<'tcx> Visitor<'tcx> for CcHelper { ExprKind::If(_, _, _) => { self.cc += 1; }, - ExprKind::Match(_, ref arms, _) => { + ExprKind::Match(_, arms, _) => { if arms.len() > 1 { self.cc += 1; } diff --git a/clippy_lints/src/comparison_chain.rs b/clippy_lints/src/comparison_chain.rs index d601cb7c224..31ae63b5184 100644 --- a/clippy_lints/src/comparison_chain.rs +++ b/clippy_lints/src/comparison_chain.rs @@ -71,10 +71,8 @@ impl<'tcx> LateLintPass<'tcx> for ComparisonChain { } for cond in conds.windows(2) { - if let ( - &ExprKind::Binary(ref kind1, ref lhs1, ref rhs1), - &ExprKind::Binary(ref kind2, ref lhs2, ref rhs2), - ) = (&cond[0].kind, &cond[1].kind) + if let (&ExprKind::Binary(ref kind1, lhs1, rhs1), &ExprKind::Binary(ref kind2, lhs2, rhs2)) = + (&cond[0].kind, &cond[1].kind) { if !kind_is_cmp(kind1.node) || !kind_is_cmp(kind2.node) { return; diff --git a/clippy_lints/src/copies.rs b/clippy_lints/src/copies.rs index 1b982221b06..8b503c9a030 100644 --- a/clippy_lints/src/copies.rs +++ b/clippy_lints/src/copies.rs @@ -160,7 +160,7 @@ impl<'tcx> LateLintPass<'tcx> for CopyAndPaste { if let ExprKind::If(_, _, _) = expr.kind { // skip ifs directly in else, it will be checked in the parent if if let Some(&Expr { - kind: ExprKind::If(_, _, Some(ref else_expr)), + kind: ExprKind::If(_, _, Some(else_expr)), .. }) = get_parent_expr(cx, expr) { @@ -247,7 +247,7 @@ fn lint_same_then_else<'tcx>( for value in &end_walker.uses { // Well we can't move this and all prev statements. So reset - if block_defs.contains(&value) { + if block_defs.contains(value) { moved_start = Some(index + 1); end_walker.defs.drain().for_each(|x| { block_defs.insert(x); @@ -555,7 +555,7 @@ impl<'a, 'tcx> Visitor<'tcx> for UsedValueFinderVisitor<'a, 'tcx> { } fn visit_qpath(&mut self, qpath: &'tcx rustc_hir::QPath<'tcx>, id: HirId, _span: rustc_span::Span) { - if let rustc_hir::QPath::Resolved(_, ref path) = *qpath { + if let rustc_hir::QPath::Resolved(_, path) = *qpath { if path.segments.len() == 1 { if let rustc_hir::def::Res::Local(var) = self.cx.qpath_res(qpath, id) { self.uses.insert(var); diff --git a/clippy_lints/src/create_dir.rs b/clippy_lints/src/create_dir.rs index ac890c90c97..7b5cce6462a 100644 --- a/clippy_lints/src/create_dir.rs +++ b/clippy_lints/src/create_dir.rs @@ -33,7 +33,7 @@ declare_lint_pass!(CreateDir => [CREATE_DIR]); impl LateLintPass<'_> for CreateDir { fn check_expr(&mut self, cx: &LateContext<'_>, expr: &Expr<'_>) { if_chain! { - if let ExprKind::Call(ref func, ref args) = expr.kind; + if let ExprKind::Call(func, args) = expr.kind; if let ExprKind::Path(ref path) = func.kind; if let Some(def_id) = cx.qpath_res(path, func.hir_id).opt_def_id(); if match_def_path(cx, def_id, &paths::STD_FS_CREATE_DIR); diff --git a/clippy_lints/src/default.rs b/clippy_lints/src/default.rs index 8a2146d93e8..710da8fe9e0 100644 --- a/clippy_lints/src/default.rs +++ b/clippy_lints/src/default.rs @@ -77,7 +77,7 @@ impl LateLintPass<'_> for Default { if_chain! { // Avoid cases already linted by `field_reassign_with_default` if !self.reassigned_linted.contains(&expr.span); - if let ExprKind::Call(ref path, ..) = expr.kind; + if let ExprKind::Call(path, ..) = expr.kind; if !any_parent_is_automatically_derived(cx.tcx, expr.hir_id); if let ExprKind::Path(ref qpath) = path.kind; if let Some(def_id) = cx.qpath_res(qpath, path.hir_id).opt_def_id(); @@ -246,7 +246,7 @@ impl LateLintPass<'_> for Default { /// Checks if the given expression is the `default` method belonging to the `Default` trait. fn is_expr_default<'tcx>(expr: &'tcx Expr<'tcx>, cx: &LateContext<'tcx>) -> bool { if_chain! { - if let ExprKind::Call(ref fn_expr, _) = &expr.kind; + if let ExprKind::Call(fn_expr, _) = &expr.kind; if let ExprKind::Path(qpath) = &fn_expr.kind; if let Res::Def(_, def_id) = cx.qpath_res(qpath, fn_expr.hir_id); then { @@ -262,11 +262,11 @@ fn is_expr_default<'tcx>(expr: &'tcx Expr<'tcx>, cx: &LateContext<'tcx>) -> bool fn field_reassigned_by_stmt<'tcx>(this: &Stmt<'tcx>, binding_name: Symbol) -> Option<(Ident, &'tcx Expr<'tcx>)> { if_chain! { // only take assignments - if let StmtKind::Semi(ref later_expr) = this.kind; - if let ExprKind::Assign(ref assign_lhs, ref assign_rhs, _) = later_expr.kind; + if let StmtKind::Semi(later_expr) = this.kind; + if let ExprKind::Assign(assign_lhs, assign_rhs, _) = later_expr.kind; // only take assignments to fields where the left-hand side field is a field of // the same binding as the previous statement - if let ExprKind::Field(ref binding, field_ident) = assign_lhs.kind; + if let ExprKind::Field(binding, field_ident) = assign_lhs.kind; if let ExprKind::Path(QPath::Resolved(_, path)) = binding.kind; if let Some(second_binding_name) = path.segments.last(); if second_binding_name.ident.name == binding_name; diff --git a/clippy_lints/src/derive.rs b/clippy_lints/src/derive.rs index 9fad85f8ef4..647af3bdc04 100644 --- a/clippy_lints/src/derive.rs +++ b/clippy_lints/src/derive.rs @@ -199,7 +199,7 @@ fn check_hash_peq<'tcx>( then { // Look for the PartialEq implementations for `ty` cx.tcx.for_each_relevant_impl(peq_trait_def_id, ty, |impl_id| { - let peq_is_automatically_derived = is_automatically_derived(&cx.tcx.get_attrs(impl_id)); + let peq_is_automatically_derived = is_automatically_derived(cx.tcx.get_attrs(impl_id)); if peq_is_automatically_derived == hash_is_automatically_derived { return; @@ -253,7 +253,7 @@ fn check_ord_partial_ord<'tcx>( then { // Look for the PartialOrd implementations for `ty` cx.tcx.for_each_relevant_impl(partial_ord_trait_def_id, ty, |impl_id| { - let partial_ord_is_automatically_derived = is_automatically_derived(&cx.tcx.get_attrs(impl_id)); + let partial_ord_is_automatically_derived = is_automatically_derived(cx.tcx.get_attrs(impl_id)); if partial_ord_is_automatically_derived == ord_is_automatically_derived { return; diff --git a/clippy_lints/src/doc.rs b/clippy_lints/src/doc.rs index b5796ccf43f..fb53b55ebd6 100644 --- a/clippy_lints/src/doc.rs +++ b/clippy_lints/src/doc.rs @@ -710,8 +710,8 @@ impl<'a, 'tcx> Visitor<'tcx> for FindPanicUnwrap<'a, 'tcx> { // check for `begin_panic` if_chain! { - if let ExprKind::Call(ref func_expr, _) = expr.kind; - if let ExprKind::Path(QPath::Resolved(_, ref path)) = func_expr.kind; + if let ExprKind::Call(func_expr, _) = expr.kind; + if let ExprKind::Path(QPath::Resolved(_, path)) = func_expr.kind; if let Some(path_def_id) = path.res.opt_def_id(); if match_panic_def_id(self.cx, path_def_id); if is_expn_of(expr.span, "unreachable").is_none(); diff --git a/clippy_lints/src/double_comparison.rs b/clippy_lints/src/double_comparison.rs index 1d291565ec1..58543ae6e4e 100644 --- a/clippy_lints/src/double_comparison.rs +++ b/clippy_lints/src/double_comparison.rs @@ -47,7 +47,7 @@ impl<'tcx> DoubleComparisons { }, _ => return, }; - if !(eq_expr_value(cx, &llhs, &rlhs) && eq_expr_value(cx, &lrhs, &rrhs)) { + if !(eq_expr_value(cx, llhs, rlhs) && eq_expr_value(cx, lrhs, rrhs)) { return; } macro_rules! lint_double_comparison { @@ -88,7 +88,7 @@ impl<'tcx> DoubleComparisons { impl<'tcx> LateLintPass<'tcx> for DoubleComparisons { fn check_expr(&mut self, cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) { - if let ExprKind::Binary(ref kind, ref lhs, ref rhs) = expr.kind { + if let ExprKind::Binary(ref kind, lhs, rhs) = expr.kind { Self::check_binop(cx, kind.node, lhs, rhs, expr.span); } } diff --git a/clippy_lints/src/double_parens.rs b/clippy_lints/src/double_parens.rs index 5afdcb3c09f..e4e4a93b011 100644 --- a/clippy_lints/src/double_parens.rs +++ b/clippy_lints/src/double_parens.rs @@ -50,7 +50,7 @@ impl EarlyLintPass for DoubleParens { match expr.kind { ExprKind::Paren(ref in_paren) => match in_paren.kind { ExprKind::Paren(_) | ExprKind::Tup(_) => { - span_lint(cx, DOUBLE_PARENS, expr.span, &msg); + span_lint(cx, DOUBLE_PARENS, expr.span, msg); }, _ => {}, }, @@ -58,7 +58,7 @@ impl EarlyLintPass for DoubleParens { if params.len() == 1 { let param = ¶ms[0]; if let ExprKind::Paren(_) = param.kind { - span_lint(cx, DOUBLE_PARENS, param.span, &msg); + span_lint(cx, DOUBLE_PARENS, param.span, msg); } } }, @@ -66,7 +66,7 @@ impl EarlyLintPass for DoubleParens { if params.len() == 2 { let param = ¶ms[1]; if let ExprKind::Paren(_) = param.kind { - span_lint(cx, DOUBLE_PARENS, param.span, &msg); + span_lint(cx, DOUBLE_PARENS, param.span, msg); } } }, diff --git a/clippy_lints/src/drop_forget_ref.rs b/clippy_lints/src/drop_forget_ref.rs index 7e7ec017bbb..b5b29760636 100644 --- a/clippy_lints/src/drop_forget_ref.rs +++ b/clippy_lints/src/drop_forget_ref.rs @@ -113,7 +113,7 @@ declare_lint_pass!(DropForgetRef => [DROP_REF, FORGET_REF, DROP_COPY, FORGET_COP impl<'tcx> LateLintPass<'tcx> for DropForgetRef { fn check_expr(&mut self, cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) { if_chain! { - if let ExprKind::Call(ref path, ref args) = expr.kind; + if let ExprKind::Call(path, args) = expr.kind; if let ExprKind::Path(ref qpath) = path.kind; if args.len() == 1; if let Some(def_id) = cx.qpath_res(qpath, path.hir_id).opt_def_id(); diff --git a/clippy_lints/src/duration_subsec.rs b/clippy_lints/src/duration_subsec.rs index 746c1f6df91..529807770f3 100644 --- a/clippy_lints/src/duration_subsec.rs +++ b/clippy_lints/src/duration_subsec.rs @@ -43,8 +43,8 @@ declare_lint_pass!(DurationSubsec => [DURATION_SUBSEC]); impl<'tcx> LateLintPass<'tcx> for DurationSubsec { fn check_expr(&mut self, cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) { if_chain! { - if let ExprKind::Binary(Spanned { node: BinOpKind::Div, .. }, ref left, ref right) = expr.kind; - if let ExprKind::MethodCall(ref method_path, _ , ref args, _) = left.kind; + if let ExprKind::Binary(Spanned { node: BinOpKind::Div, .. }, left, right) = expr.kind; + if let ExprKind::MethodCall(method_path, _ , args, _) = left.kind; if match_type(cx, cx.typeck_results().expr_ty(&args[0]).peel_refs(), &paths::DURATION); if let Some((Constant::Int(divisor), _)) = constant(cx, cx.typeck_results(), right); then { diff --git a/clippy_lints/src/entry.rs b/clippy_lints/src/entry.rs index 25eb048448c..a815df1691a 100644 --- a/clippy_lints/src/entry.rs +++ b/clippy_lints/src/entry.rs @@ -57,14 +57,14 @@ declare_lint_pass!(HashMapPass => [MAP_ENTRY]); impl<'tcx> LateLintPass<'tcx> for HashMapPass { fn check_expr(&mut self, cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) { - if let ExprKind::If(ref check, ref then_block, ref else_block) = expr.kind { - if let ExprKind::Unary(UnOp::Not, ref check) = check.kind { + if let ExprKind::If(check, then_block, ref else_block) = expr.kind { + if let ExprKind::Unary(UnOp::Not, check) = check.kind { if let Some((ty, map, key)) = check_cond(cx, check) { // in case of `if !m.contains_key(&k) { m.insert(k, v); }` // we can give a better error message let sole_expr = { else_block.is_none() - && if let ExprKind::Block(ref then_block, _) = then_block.kind { + && if let ExprKind::Block(then_block, _) = then_block.kind { (then_block.expr.is_some() as usize) + then_block.stmts.len() == 1 } else { true @@ -81,9 +81,9 @@ impl<'tcx> LateLintPass<'tcx> for HashMapPass { sole_expr, }; - walk_expr(&mut visitor, &**then_block); + walk_expr(&mut visitor, then_block); } - } else if let Some(ref else_block) = *else_block { + } else if let Some(else_block) = *else_block { if let Some((ty, map, key)) = check_cond(cx, check) { let mut visitor = InsertVisitor { cx, @@ -103,10 +103,10 @@ impl<'tcx> LateLintPass<'tcx> for HashMapPass { fn check_cond<'a>(cx: &LateContext<'_>, check: &'a Expr<'a>) -> Option<(&'static str, &'a Expr<'a>, &'a Expr<'a>)> { if_chain! { - if let ExprKind::MethodCall(ref path, _, ref params, _) = check.kind; + if let ExprKind::MethodCall(path, _, params, _) = check.kind; if params.len() >= 2; if path.ident.name == sym!(contains_key); - if let ExprKind::AddrOf(BorrowKind::Ref, _, ref key) = params[1].kind; + if let ExprKind::AddrOf(BorrowKind::Ref, _, key) = params[1].kind; then { let map = ¶ms[0]; let obj_ty = cx.typeck_results().expr_ty(map).peel_refs(); @@ -140,7 +140,7 @@ impl<'a, 'tcx, 'b> Visitor<'tcx> for InsertVisitor<'a, 'tcx, 'b> { fn visit_expr(&mut self, expr: &'tcx Expr<'_>) { if_chain! { - if let ExprKind::MethodCall(ref path, _, ref params, _) = expr.kind; + if let ExprKind::MethodCall(path, _, params, _) = expr.kind; if params.len() == 3; if path.ident.name == sym!(insert); if get_item_name(self.cx, self.map) == get_item_name(self.cx, ¶ms[0]); diff --git a/clippy_lints/src/eq_op.rs b/clippy_lints/src/eq_op.rs index 6d7046ac8b7..90f391b5f5c 100644 --- a/clippy_lints/src/eq_op.rs +++ b/clippy_lints/src/eq_op.rs @@ -65,12 +65,12 @@ const ASSERT_MACRO_NAMES: [&str; 4] = ["assert_eq", "assert_ne", "debug_assert_e impl<'tcx> LateLintPass<'tcx> for EqOp { #[allow(clippy::similar_names, clippy::too_many_lines)] fn check_expr(&mut self, cx: &LateContext<'tcx>, e: &'tcx Expr<'_>) { - if let ExprKind::Block(ref block, _) = e.kind { + if let ExprKind::Block(block, _) = e.kind { for stmt in block.stmts { for amn in &ASSERT_MACRO_NAMES { if_chain! { if is_expn_of(stmt.span, amn).is_some(); - if let StmtKind::Semi(ref matchexpr) = stmt.kind; + if let StmtKind::Semi(matchexpr) = stmt.kind; if let Some(macro_args) = higher::extract_assert_macro_args(matchexpr); if macro_args.len() == 2; let (lhs, rhs) = (macro_args[0], macro_args[1]); @@ -88,12 +88,12 @@ impl<'tcx> LateLintPass<'tcx> for EqOp { } } } - if let ExprKind::Binary(op, ref left, ref right) = e.kind { + if let ExprKind::Binary(op, left, right) = e.kind { if e.span.from_expansion() { return; } let macro_with_not_op = |expr_kind: &ExprKind<'_>| { - if let ExprKind::Unary(_, ref expr) = *expr_kind { + if let ExprKind::Unary(_, expr) = *expr_kind { in_macro(expr.span) } else { false @@ -135,7 +135,7 @@ impl<'tcx> LateLintPass<'tcx> for EqOp { // do not suggest to dereference literals (&ExprKind::Lit(..), _) | (_, &ExprKind::Lit(..)) => {}, // &foo == &bar - (&ExprKind::AddrOf(BorrowKind::Ref, _, ref l), &ExprKind::AddrOf(BorrowKind::Ref, _, ref r)) => { + (&ExprKind::AddrOf(BorrowKind::Ref, _, l), &ExprKind::AddrOf(BorrowKind::Ref, _, r)) => { let lty = cx.typeck_results().expr_ty(l); let rty = cx.typeck_results().expr_ty(r); let lcpy = is_copy(cx, lty); @@ -198,7 +198,7 @@ impl<'tcx> LateLintPass<'tcx> for EqOp { } }, // &foo == bar - (&ExprKind::AddrOf(BorrowKind::Ref, _, ref l), _) => { + (&ExprKind::AddrOf(BorrowKind::Ref, _, l), _) => { let lty = cx.typeck_results().expr_ty(l); let lcpy = is_copy(cx, lty); if (requires_ref || lcpy) @@ -222,7 +222,7 @@ impl<'tcx> LateLintPass<'tcx> for EqOp { } }, // foo == &bar - (_, &ExprKind::AddrOf(BorrowKind::Ref, _, ref r)) => { + (_, &ExprKind::AddrOf(BorrowKind::Ref, _, r)) => { let rty = cx.typeck_results().expr_ty(r); let rcpy = is_copy(cx, rty); if (requires_ref || rcpy) diff --git a/clippy_lints/src/erasing_op.rs b/clippy_lints/src/erasing_op.rs index 59602616781..f95ca86a2d0 100644 --- a/clippy_lints/src/erasing_op.rs +++ b/clippy_lints/src/erasing_op.rs @@ -34,7 +34,7 @@ impl<'tcx> LateLintPass<'tcx> for ErasingOp { if e.span.from_expansion() { return; } - if let ExprKind::Binary(ref cmp, ref left, ref right) = e.kind { + if let ExprKind::Binary(ref cmp, left, right) = e.kind { match cmp.node { BinOpKind::Mul | BinOpKind::BitAnd => { check(cx, left, e.span); diff --git a/clippy_lints/src/eta_reduction.rs b/clippy_lints/src/eta_reduction.rs index 99253555a95..2f1aa53236d 100644 --- a/clippy_lints/src/eta_reduction.rs +++ b/clippy_lints/src/eta_reduction.rs @@ -87,7 +87,7 @@ impl<'tcx> LateLintPass<'tcx> for EtaReduction { } fn check_closure(cx: &LateContext<'_>, expr: &Expr<'_>) { - if let ExprKind::Closure(_, ref decl, eid, _, _) = expr.kind { + if let ExprKind::Closure(_, decl, eid, _, _) = expr.kind { let body = cx.tcx.hir().body(eid); let ex = &body.value; @@ -109,7 +109,7 @@ fn check_closure(cx: &LateContext<'_>, expr: &Expr<'_>) { } if_chain!( - if let ExprKind::Call(ref caller, ref args) = ex.kind; + if let ExprKind::Call(caller, args) = ex.kind; if let ExprKind::Path(_) = caller.kind; @@ -142,7 +142,7 @@ fn check_closure(cx: &LateContext<'_>, expr: &Expr<'_>) { ); if_chain!( - if let ExprKind::MethodCall(ref path, _, ref args, _) = ex.kind; + if let ExprKind::MethodCall(path, _, args, _) = ex.kind; // Not the same number of arguments, there is no way the closure is the same as the function return; if args.len() == decl.inputs.len(); @@ -178,7 +178,7 @@ fn get_ufcs_type_name(cx: &LateContext<'_>, method_def_id: def_id::DefId, self_a let actual_type_of_self = &cx.typeck_results().node_type(self_arg.hir_id); if let Some(trait_id) = cx.tcx.trait_of_item(method_def_id) { - if match_borrow_depth(expected_type_of_self, &actual_type_of_self) + if match_borrow_depth(expected_type_of_self, actual_type_of_self) && implements_trait(cx, actual_type_of_self, trait_id, &[]) { return Some(cx.tcx.def_path_str(trait_id)); @@ -187,8 +187,8 @@ fn get_ufcs_type_name(cx: &LateContext<'_>, method_def_id: def_id::DefId, self_a cx.tcx.impl_of_method(method_def_id).and_then(|_| { //a type may implicitly implement other type's methods (e.g. Deref) - if match_types(expected_type_of_self, &actual_type_of_self) { - return Some(get_type_name(cx, &actual_type_of_self)); + if match_types(expected_type_of_self, actual_type_of_self) { + return Some(get_type_name(cx, actual_type_of_self)); } None }) @@ -196,7 +196,7 @@ fn get_ufcs_type_name(cx: &LateContext<'_>, method_def_id: def_id::DefId, self_a fn match_borrow_depth(lhs: Ty<'_>, rhs: Ty<'_>) -> bool { match (&lhs.kind(), &rhs.kind()) { - (ty::Ref(_, t1, mut1), ty::Ref(_, t2, mut2)) => mut1 == mut2 && match_borrow_depth(&t1, &t2), + (ty::Ref(_, t1, mut1), ty::Ref(_, t2, mut2)) => mut1 == mut2 && match_borrow_depth(t1, t2), (l, r) => !matches!((l, r), (ty::Ref(_, _, _), _) | (_, ty::Ref(_, _, _))), } } @@ -218,7 +218,7 @@ fn match_types(lhs: Ty<'_>, rhs: Ty<'_>) -> bool { fn get_type_name(cx: &LateContext<'_>, ty: Ty<'_>) -> String { match ty.kind() { ty::Adt(t, _) => cx.tcx.def_path_str(t.did), - ty::Ref(_, r, _) => get_type_name(cx, &r), + ty::Ref(_, r, _) => get_type_name(cx, r), _ => ty.to_string(), } } @@ -230,7 +230,7 @@ fn compare_inputs( for (closure_input, function_arg) in closure_inputs.zip(call_args) { if let PatKind::Binding(_, _, ident, _) = closure_input.pat.kind { // XXXManishearth Should I be checking the binding mode here? - if let ExprKind::Path(QPath::Resolved(None, ref p)) = function_arg.kind { + if let ExprKind::Path(QPath::Resolved(None, p)) = function_arg.kind { if p.segments.len() != 1 { // If it's a proper path, it can't be a local variable return false; diff --git a/clippy_lints/src/eval_order_dependence.rs b/clippy_lints/src/eval_order_dependence.rs index ea33a4d98fd..762f64fe37a 100644 --- a/clippy_lints/src/eval_order_dependence.rs +++ b/clippy_lints/src/eval_order_dependence.rs @@ -71,7 +71,7 @@ impl<'tcx> LateLintPass<'tcx> for EvalOrderDependence { fn check_expr(&mut self, cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) { // Find a write to a local variable. match expr.kind { - ExprKind::Assign(ref lhs, ..) | ExprKind::AssignOp(_, ref lhs, _) => { + ExprKind::Assign(lhs, ..) | ExprKind::AssignOp(_, lhs, _) => { if let Some(var) = path_to_local(lhs) { let mut visitor = ReadVisitor { cx, @@ -87,12 +87,12 @@ impl<'tcx> LateLintPass<'tcx> for EvalOrderDependence { } fn check_stmt(&mut self, cx: &LateContext<'tcx>, stmt: &'tcx Stmt<'_>) { match stmt.kind { - StmtKind::Local(ref local) => { - if let Local { init: Some(ref e), .. } = **local { + StmtKind::Local(local) => { + if let Local { init: Some(e), .. } = local { DivergenceVisitor { cx }.visit_expr(e); } }, - StmtKind::Expr(ref e) | StmtKind::Semi(ref e) => DivergenceVisitor { cx }.maybe_walk_expr(e), + StmtKind::Expr(e) | StmtKind::Semi(e) => DivergenceVisitor { cx }.maybe_walk_expr(e), StmtKind::Item(..) => {}, } } @@ -106,7 +106,7 @@ impl<'a, 'tcx> DivergenceVisitor<'a, 'tcx> { fn maybe_walk_expr(&mut self, e: &'tcx Expr<'_>) { match e.kind { ExprKind::Closure(..) => {}, - ExprKind::Match(ref e, arms, _) => { + ExprKind::Match(e, arms, _) => { self.visit_expr(e); for arm in arms { if let Some(Guard::If(if_expr)) = arm.guard { @@ -130,7 +130,7 @@ impl<'a, 'tcx> Visitor<'tcx> for DivergenceVisitor<'a, 'tcx> { fn visit_expr(&mut self, e: &'tcx Expr<'_>) { match e.kind { ExprKind::Continue(_) | ExprKind::Break(_, _) | ExprKind::Ret(_) => self.report_diverging_sub_expr(e), - ExprKind::Call(ref func, _) => { + ExprKind::Call(func, _) => { let typ = self.cx.typeck_results().expr_ty(func); match typ.kind() { ty::FnDef(..) | ty::FnPtr(_) => { @@ -266,10 +266,10 @@ fn check_expr<'a, 'tcx>(vis: &mut ReadVisitor<'a, 'tcx>, expr: &'tcx Expr<'_>) - fn check_stmt<'a, 'tcx>(vis: &mut ReadVisitor<'a, 'tcx>, stmt: &'tcx Stmt<'_>) -> StopEarly { match stmt.kind { - StmtKind::Expr(ref expr) | StmtKind::Semi(ref expr) => check_expr(vis, expr), + StmtKind::Expr(expr) | StmtKind::Semi(expr) => check_expr(vis, expr), // If the declaration is of a local variable, check its initializer // expression if it has one. Otherwise, keep going. - StmtKind::Local(ref local) => local + StmtKind::Local(local) => local .init .as_ref() .map_or(StopEarly::KeepGoing, |expr| check_expr(vis, expr)), @@ -343,7 +343,7 @@ impl<'a, 'tcx> Visitor<'tcx> for ReadVisitor<'a, 'tcx> { /// Returns `true` if `expr` is the LHS of an assignment, like `expr = ...`. fn is_in_assignment_position(cx: &LateContext<'_>, expr: &Expr<'_>) -> bool { if let Some(parent) = get_parent_expr(cx, expr) { - if let ExprKind::Assign(ref lhs, ..) = parent.kind { + if let ExprKind::Assign(lhs, ..) = parent.kind { return lhs.hir_id == expr.hir_id; } } diff --git a/clippy_lints/src/exit.rs b/clippy_lints/src/exit.rs index 84fac998662..16246e548b6 100644 --- a/clippy_lints/src/exit.rs +++ b/clippy_lints/src/exit.rs @@ -28,7 +28,7 @@ declare_lint_pass!(Exit => [EXIT]); impl<'tcx> LateLintPass<'tcx> for Exit { fn check_expr(&mut self, cx: &LateContext<'tcx>, e: &'tcx Expr<'_>) { if_chain! { - if let ExprKind::Call(ref path_expr, ref _args) = e.kind; + if let ExprKind::Call(path_expr, _args) = e.kind; if let ExprKind::Path(ref path) = path_expr.kind; if let Some(def_id) = cx.qpath_res(path, path_expr.hir_id).opt_def_id(); if match_def_path(cx, def_id, &paths::EXIT); diff --git a/clippy_lints/src/explicit_write.rs b/clippy_lints/src/explicit_write.rs index 4146b7baa10..da4936ff25b 100644 --- a/clippy_lints/src/explicit_write.rs +++ b/clippy_lints/src/explicit_write.rs @@ -34,11 +34,11 @@ impl<'tcx> LateLintPass<'tcx> for ExplicitWrite { fn check_expr(&mut self, cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) { if_chain! { // match call to unwrap - if let ExprKind::MethodCall(ref unwrap_fun, _, ref unwrap_args, _) = expr.kind; + if let ExprKind::MethodCall(unwrap_fun, _, unwrap_args, _) = expr.kind; if unwrap_fun.ident.name == sym::unwrap; // match call to write_fmt if !unwrap_args.is_empty(); - if let ExprKind::MethodCall(ref write_fun, _, write_args, _) = + if let ExprKind::MethodCall(write_fun, _, write_args, _) = unwrap_args[0].kind; if write_fun.ident.name == sym!(write_fmt); // match calls to std::io::stdout() / std::io::stderr () @@ -135,10 +135,10 @@ fn write_output_string(write_args: &[Expr<'_>]) -> Option { if_chain! { // Obtain the string that should be printed if write_args.len() > 1; - if let ExprKind::Call(_, ref output_args) = write_args[1].kind; + if let ExprKind::Call(_, output_args) = write_args[1].kind; if !output_args.is_empty(); - if let ExprKind::AddrOf(BorrowKind::Ref, _, ref output_string_expr) = output_args[0].kind; - if let ExprKind::Array(ref string_exprs) = output_string_expr.kind; + if let ExprKind::AddrOf(BorrowKind::Ref, _, output_string_expr) = output_args[0].kind; + if let ExprKind::Array(string_exprs) = output_string_expr.kind; // we only want to provide an automatic suggestion for simple (non-format) strings if string_exprs.len() == 1; if let ExprKind::Lit(ref lit) = string_exprs[0].kind; diff --git a/clippy_lints/src/fallible_impl_from.rs b/clippy_lints/src/fallible_impl_from.rs index 52a5a7acf0d..2937fcb9ca0 100644 --- a/clippy_lints/src/fallible_impl_from.rs +++ b/clippy_lints/src/fallible_impl_from.rs @@ -81,8 +81,8 @@ fn lint_impl_body<'tcx>(cx: &LateContext<'tcx>, impl_span: Span, impl_items: &[h fn visit_expr(&mut self, expr: &'tcx Expr<'_>) { // check for `begin_panic` if_chain! { - if let ExprKind::Call(ref func_expr, _) = expr.kind; - if let ExprKind::Path(QPath::Resolved(_, ref path)) = func_expr.kind; + if let ExprKind::Call(func_expr, _) = expr.kind; + if let ExprKind::Path(QPath::Resolved(_, path)) = func_expr.kind; if let Some(path_def_id) = path.res.opt_def_id(); if match_panic_def_id(self.lcx, path_def_id); if is_expn_of(expr.span, "unreachable").is_none(); diff --git a/clippy_lints/src/float_equality_without_abs.rs b/clippy_lints/src/float_equality_without_abs.rs index 0c59db360f9..b5ebe5f90ba 100644 --- a/clippy_lints/src/float_equality_without_abs.rs +++ b/clippy_lints/src/float_equality_without_abs.rs @@ -48,7 +48,7 @@ impl<'tcx> LateLintPass<'tcx> for FloatEqualityWithoutAbs { let rhs; // check if expr is a binary expression with a lt or gt operator - if let ExprKind::Binary(op, ref left, ref right) = expr.kind { + if let ExprKind::Binary(op, left, right) = expr.kind { match op.node { BinOpKind::Lt => { lhs = left; @@ -88,8 +88,8 @@ impl<'tcx> LateLintPass<'tcx> for FloatEqualityWithoutAbs { if let ty::Float(_) = t_val_r.kind(); then { - let sug_l = sugg::Sugg::hir(cx, &val_l, ".."); - let sug_r = sugg::Sugg::hir(cx, &val_r, ".."); + let sug_l = sugg::Sugg::hir(cx, val_l, ".."); + let sug_r = sugg::Sugg::hir(cx, val_r, ".."); // format the suggestion let suggestion = format!("{}.abs()", sugg::make_assoc(AssocOp::Subtract, &sug_l, &sug_r).maybe_par()); // spans the lint diff --git a/clippy_lints/src/floating_point_arithmetic.rs b/clippy_lints/src/floating_point_arithmetic.rs index 0b5f0379ce6..e0b687b0205 100644 --- a/clippy_lints/src/floating_point_arithmetic.rs +++ b/clippy_lints/src/floating_point_arithmetic.rs @@ -131,7 +131,7 @@ fn prepare_receiver_sugg<'a>(cx: &LateContext<'_>, mut expr: &'a Expr<'a>) -> Su let mut suggestion = Sugg::hir(cx, expr, ".."); if let ExprKind::Unary(UnOp::Neg, inner_expr) = &expr.kind { - expr = &inner_expr; + expr = inner_expr; } if_chain! { @@ -313,8 +313,8 @@ fn check_powi(cx: &LateContext<'_>, expr: &Expr<'_>, args: &[Expr<'_>]) { Spanned { node: BinOpKind::Add, .. }, - ref lhs, - ref rhs, + lhs, + rhs, ) = parent.kind { let other_addend = if lhs.hir_id == expr.hir_id { rhs } else { lhs }; @@ -329,7 +329,7 @@ fn check_powi(cx: &LateContext<'_>, expr: &Expr<'_>, args: &[Expr<'_>]) { "{}.mul_add({}, {})", Sugg::hir(cx, &args[0], ".."), Sugg::hir(cx, &args[0], ".."), - Sugg::hir(cx, &other_addend, ".."), + Sugg::hir(cx, other_addend, ".."), ), Applicability::MachineApplicable, ); @@ -356,18 +356,18 @@ fn detect_hypot(cx: &LateContext<'_>, args: &[Expr<'_>]) -> Option { Spanned { node: BinOpKind::Add, .. }, - ref add_lhs, - ref add_rhs, + add_lhs, + add_rhs, ) = args[0].kind { // check if expression of the form x * x + y * y if_chain! { - if let ExprKind::Binary(Spanned { node: BinOpKind::Mul, .. }, ref lmul_lhs, ref lmul_rhs) = add_lhs.kind; - if let ExprKind::Binary(Spanned { node: BinOpKind::Mul, .. }, ref rmul_lhs, ref rmul_rhs) = add_rhs.kind; + if let ExprKind::Binary(Spanned { node: BinOpKind::Mul, .. }, lmul_lhs, lmul_rhs) = add_lhs.kind; + if let ExprKind::Binary(Spanned { node: BinOpKind::Mul, .. }, rmul_lhs, rmul_rhs) = add_rhs.kind; if eq_expr_value(cx, lmul_lhs, lmul_rhs); if eq_expr_value(cx, rmul_lhs, rmul_rhs); then { - return Some(format!("{}.hypot({})", Sugg::hir(cx, &lmul_lhs, ".."), Sugg::hir(cx, &rmul_lhs, ".."))); + return Some(format!("{}.hypot({})", Sugg::hir(cx, lmul_lhs, ".."), Sugg::hir(cx, rmul_lhs, ".."))); } } @@ -376,13 +376,13 @@ fn detect_hypot(cx: &LateContext<'_>, args: &[Expr<'_>]) -> Option { if let ExprKind::MethodCall( PathSegment { ident: lmethod_name, .. }, ref _lspan, - ref largs, + largs, _ ) = add_lhs.kind; if let ExprKind::MethodCall( PathSegment { ident: rmethod_name, .. }, ref _rspan, - ref rargs, + rargs, _ ) = add_rhs.kind; if lmethod_name.as_str() == "powi" && rmethod_name.as_str() == "powi"; @@ -416,11 +416,11 @@ fn check_hypot(cx: &LateContext<'_>, expr: &Expr<'_>, args: &[Expr<'_>]) { // and suggest usage of `x.exp_m1() - (y - 1)` instead fn check_expm1(cx: &LateContext<'_>, expr: &Expr<'_>) { if_chain! { - if let ExprKind::Binary(Spanned { node: BinOpKind::Sub, .. }, ref lhs, ref rhs) = expr.kind; + if let ExprKind::Binary(Spanned { node: BinOpKind::Sub, .. }, lhs, rhs) = expr.kind; if cx.typeck_results().expr_ty(lhs).is_floating_point(); if let Some((value, _)) = constant(cx, cx.typeck_results(), rhs); if F32(1.0) == value || F64(1.0) == value; - if let ExprKind::MethodCall(ref path, _, ref method_args, _) = lhs.kind; + if let ExprKind::MethodCall(path, _, method_args, _) = lhs.kind; if cx.typeck_results().expr_ty(&method_args[0]).is_floating_point(); if path.ident.name.as_str() == "exp"; then { @@ -442,7 +442,7 @@ fn check_expm1(cx: &LateContext<'_>, expr: &Expr<'_>) { fn is_float_mul_expr<'a>(cx: &LateContext<'_>, expr: &'a Expr<'a>) -> Option<(&'a Expr<'a>, &'a Expr<'a>)> { if_chain! { - if let ExprKind::Binary(Spanned { node: BinOpKind::Mul, .. }, ref lhs, ref rhs) = &expr.kind; + if let ExprKind::Binary(Spanned { node: BinOpKind::Mul, .. }, lhs, rhs) = &expr.kind; if cx.typeck_results().expr_ty(lhs).is_floating_point(); if cx.typeck_results().expr_ty(rhs).is_floating_point(); then { @@ -604,8 +604,8 @@ fn check_custom_abs(cx: &LateContext<'_>, expr: &Expr<'_>) { fn are_same_base_logs(cx: &LateContext<'_>, expr_a: &Expr<'_>, expr_b: &Expr<'_>) -> bool { if_chain! { - if let ExprKind::MethodCall(PathSegment { ident: method_name_a, .. }, _, ref args_a, _) = expr_a.kind; - if let ExprKind::MethodCall(PathSegment { ident: method_name_b, .. }, _, ref args_b, _) = expr_b.kind; + if let ExprKind::MethodCall(PathSegment { ident: method_name_a, .. }, _, args_a, _) = expr_a.kind; + if let ExprKind::MethodCall(PathSegment { ident: method_name_b, .. }, _, args_b, _) = expr_b.kind; then { return method_name_a.as_str() == method_name_b.as_str() && args_a.len() == args_b.len() && @@ -630,8 +630,8 @@ fn check_log_division(cx: &LateContext<'_>, expr: &Expr<'_>) { rhs, ) = &expr.kind; if are_same_base_logs(cx, lhs, rhs); - if let ExprKind::MethodCall(_, _, ref largs, _) = lhs.kind; - if let ExprKind::MethodCall(_, _, ref rargs, _) = rhs.kind; + if let ExprKind::MethodCall(_, _, largs, _) = lhs.kind; + if let ExprKind::MethodCall(_, _, rargs, _) = rhs.kind; then { span_lint_and_sugg( cx, @@ -675,7 +675,7 @@ fn check_radians(cx: &LateContext<'_>, expr: &Expr<'_>) { expr.span, "conversion to degrees can be done more accurately", "consider using", - format!("{}.to_degrees()", Sugg::hir(cx, &mul_lhs, "..")), + format!("{}.to_degrees()", Sugg::hir(cx, mul_lhs, "..")), Applicability::MachineApplicable, ); } else if @@ -688,7 +688,7 @@ fn check_radians(cx: &LateContext<'_>, expr: &Expr<'_>) { expr.span, "conversion to radians can be done more accurately", "consider using", - format!("{}.to_radians()", Sugg::hir(cx, &mul_lhs, "..")), + format!("{}.to_radians()", Sugg::hir(cx, mul_lhs, "..")), Applicability::MachineApplicable, ); } @@ -698,7 +698,7 @@ fn check_radians(cx: &LateContext<'_>, expr: &Expr<'_>) { impl<'tcx> LateLintPass<'tcx> for FloatingPointArithmetic { fn check_expr(&mut self, cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) { - if let ExprKind::MethodCall(ref path, _, args, _) = &expr.kind { + if let ExprKind::MethodCall(path, _, args, _) = &expr.kind { let recv_ty = cx.typeck_results().expr_ty(&args[0]); if recv_ty.is_floating_point() { diff --git a/clippy_lints/src/format.rs b/clippy_lints/src/format.rs index a33f987b423..4729abbd8e3 100644 --- a/clippy_lints/src/format.rs +++ b/clippy_lints/src/format.rs @@ -78,8 +78,8 @@ fn span_useless_format(cx: &T, span: Span, help: &str, mut sugg: fn on_argumentv1_new<'tcx>(cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>, arms: &'tcx [Arm<'_>]) -> Option { if_chain! { - if let ExprKind::AddrOf(BorrowKind::Ref, _, ref format_args) = expr.kind; - if let ExprKind::Array(ref elems) = arms[0].body.kind; + if let ExprKind::AddrOf(BorrowKind::Ref, _, format_args) = expr.kind; + if let ExprKind::Array(elems) = arms[0].body.kind; if elems.len() == 1; if let Some(args) = match_function_call(cx, &elems[0], &paths::FMT_ARGUMENTV1_NEW); // matches `core::fmt::Display::fmt` @@ -88,10 +88,10 @@ fn on_argumentv1_new<'tcx>(cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>, arms: & if let Some(did) = cx.qpath_res(qpath, args[1].hir_id).opt_def_id(); if match_def_path(cx, did, &paths::DISPLAY_FMT_METHOD); // check `(arg0,)` in match block - if let PatKind::Tuple(ref pats, None) = arms[0].pat.kind; + if let PatKind::Tuple(pats, None) = arms[0].pat.kind; if pats.len() == 1; then { - let ty = cx.typeck_results().pat_ty(&pats[0]).peel_refs(); + let ty = cx.typeck_results().pat_ty(pats[0]).peel_refs(); if *ty.kind() != rustc_middle::ty::Str && !is_type_diagnostic_item(cx, ty, sym::string_type) { return None; } @@ -101,7 +101,7 @@ fn on_argumentv1_new<'tcx>(cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>, arms: & } } else { let snip = snippet(cx, format_args.span, ""); - if let ExprKind::MethodCall(ref path, _, _, _) = format_args.kind { + if let ExprKind::MethodCall(path, _, _, _) = format_args.kind { if path.ident.name == sym!(to_string) { return Some(format!("{}", snip)); } @@ -120,16 +120,16 @@ fn on_new_v1<'tcx>(cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) -> Option [], }` if tup.is_empty() { @@ -152,16 +152,16 @@ fn on_new_v1_fmt<'tcx>(cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) -> Option(cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) -> Option) -> bool { if_chain! { - if let ExprKind::AddrOf(BorrowKind::Ref, _, ref expr) = expr.kind; - if let ExprKind::Array(ref exprs) = expr.kind; + if let ExprKind::AddrOf(BorrowKind::Ref, _, expr) = expr.kind; + if let ExprKind::Array(exprs) = expr.kind; if exprs.len() == 1; // struct `core::fmt::rt::v1::Argument` - if let ExprKind::Struct(_, ref fields, _) = exprs[0].kind; + if let ExprKind::Struct(_, fields, _) = exprs[0].kind; if let Some(format_field) = fields.iter().find(|f| f.ident.name == sym::format); // struct `core::fmt::rt::v1::FormatSpec` - if let ExprKind::Struct(_, ref fields, _) = format_field.expr.kind; + if let ExprKind::Struct(_, fields, _) = format_field.expr.kind; if let Some(precision_field) = fields.iter().find(|f| f.ident.name == sym::precision); if let ExprKind::Path(ref precision_path) = precision_field.expr.kind; if last_path_segment(precision_path).ident.name == sym::Implied; diff --git a/clippy_lints/src/functions/must_use.rs b/clippy_lints/src/functions/must_use.rs index 9e943c647fe..db5fe90b663 100644 --- a/clippy_lints/src/functions/must_use.rs +++ b/clippy_lints/src/functions/must_use.rs @@ -25,12 +25,12 @@ pub(super) fn check_item(cx: &LateContext<'tcx>, item: &'tcx hir::Item<'_>) { let is_public = cx.access_levels.is_exported(item.hir_id()); let fn_header_span = item.span.with_hi(sig.decl.output.span().hi()); if let Some(attr) = attr { - check_needless_must_use(cx, &sig.decl, item.hir_id(), item.span, fn_header_span, attr); + check_needless_must_use(cx, sig.decl, item.hir_id(), item.span, fn_header_span, attr); return; } else if is_public && !is_proc_macro(cx.sess(), attrs) && attr_by_name(attrs, "no_mangle").is_none() { check_must_use_candidate( cx, - &sig.decl, + sig.decl, cx.tcx.hir().body(*body_id), item.span, item.hir_id(), @@ -48,11 +48,11 @@ pub(super) fn check_impl_item(cx: &LateContext<'tcx>, item: &'tcx hir::ImplItem< let attrs = cx.tcx.hir().attrs(item.hir_id()); let attr = must_use_attr(attrs); if let Some(attr) = attr { - check_needless_must_use(cx, &sig.decl, item.hir_id(), item.span, fn_header_span, attr); + check_needless_must_use(cx, sig.decl, item.hir_id(), item.span, fn_header_span, attr); } else if is_public && !is_proc_macro(cx.sess(), attrs) && trait_ref_of_method(cx, item.hir_id()).is_none() { check_must_use_candidate( cx, - &sig.decl, + sig.decl, cx.tcx.hir().body(*body_id), item.span, item.hir_id(), @@ -71,13 +71,13 @@ pub(super) fn check_trait_item(cx: &LateContext<'tcx>, item: &'tcx hir::TraitIte let attrs = cx.tcx.hir().attrs(item.hir_id()); let attr = must_use_attr(attrs); if let Some(attr) = attr { - check_needless_must_use(cx, &sig.decl, item.hir_id(), item.span, fn_header_span, attr); + check_needless_must_use(cx, sig.decl, item.hir_id(), item.span, fn_header_span, attr); } else if let hir::TraitFn::Provided(eid) = *eid { let body = cx.tcx.hir().body(eid); if attr.is_none() && is_public && !is_proc_macro(cx.sess(), attrs) { check_must_use_candidate( cx, - &sig.decl, + sig.decl, body, item.span, item.hir_id(), @@ -160,8 +160,8 @@ fn check_must_use_candidate<'tcx>( fn returns_unit(decl: &hir::FnDecl<'_>) -> bool { match decl.output { hir::FnRetTy::DefaultReturn(_) => true, - hir::FnRetTy::Return(ref ty) => match ty.kind { - hir::TyKind::Tup(ref tys) => tys.is_empty(), + hir::FnRetTy::Return(ty) => match ty.kind { + hir::TyKind::Tup(tys) => tys.is_empty(), hir::TyKind::Never => true, _ => false, }, @@ -170,7 +170,7 @@ fn returns_unit(decl: &hir::FnDecl<'_>) -> bool { fn has_mutable_arg(cx: &LateContext<'_>, body: &hir::Body<'_>) -> bool { let mut tys = DefIdSet::default(); - body.params.iter().any(|param| is_mutable_pat(cx, ¶m.pat, &mut tys)) + body.params.iter().any(|param| is_mutable_pat(cx, param.pat, &mut tys)) } fn is_mutable_pat(cx: &LateContext<'_>, pat: &hir::Pat<'_>, tys: &mut DefIdSet) -> bool { @@ -178,7 +178,7 @@ fn is_mutable_pat(cx: &LateContext<'_>, pat: &hir::Pat<'_>, tys: &mut DefIdSet) return false; // ignore `_` patterns } if cx.tcx.has_typeck_results(pat.hir_id.owner.to_def_id()) { - is_mutable_ty(cx, &cx.tcx.typeck(pat.hir_id.owner).pat_ty(pat), pat.span, tys) + is_mutable_ty(cx, cx.tcx.typeck(pat.hir_id.owner).pat_ty(pat), pat.span, tys) } else { false } @@ -190,12 +190,12 @@ fn is_mutable_ty<'tcx>(cx: &LateContext<'tcx>, ty: Ty<'tcx>, span: Span, tys: &m match *ty.kind() { // primitive types are never mutable ty::Bool | ty::Char | ty::Int(_) | ty::Uint(_) | ty::Float(_) | ty::Str => false, - ty::Adt(ref adt, ref substs) => { + ty::Adt(adt, substs) => { tys.insert(adt.did) && !ty.is_freeze(cx.tcx.at(span), cx.param_env) || KNOWN_WRAPPER_TYS.iter().any(|path| match_def_path(cx, adt.did, path)) && substs.types().any(|ty| is_mutable_ty(cx, ty, span, tys)) }, - ty::Tuple(ref substs) => substs.types().any(|ty| is_mutable_ty(cx, ty, span, tys)), + ty::Tuple(substs) => substs.types().any(|ty| is_mutable_ty(cx, ty, span, tys)), ty::Array(ty, _) | ty::Slice(ty) => is_mutable_ty(cx, ty, span, tys), ty::RawPtr(ty::TypeAndMut { ty, mutbl }) | ty::Ref(_, ty, mutbl) => { mutbl == hir::Mutability::Mut || is_mutable_ty(cx, ty, span, tys) @@ -239,7 +239,7 @@ impl<'a, 'tcx> intravisit::Visitor<'tcx> for StaticMutVisitor<'a, 'tcx> { tys.clear(); } }, - Assign(ref target, ..) | AssignOp(_, ref target, _) | AddrOf(_, hir::Mutability::Mut, ref target) => { + Assign(target, ..) | AssignOp(_, target, _) | AddrOf(_, hir::Mutability::Mut, target) => { self.mutates_static |= is_mutated_static(target) }, _ => {}, @@ -257,7 +257,7 @@ fn is_mutated_static(e: &hir::Expr<'_>) -> bool { match e.kind { Path(QPath::Resolved(_, path)) => !matches!(path.res, Res::Local(_)), Path(_) => true, - Field(ref inner, _) | Index(ref inner, _) => is_mutated_static(inner), + Field(inner, _) | Index(inner, _) => is_mutated_static(inner), _ => false, } } diff --git a/clippy_lints/src/functions/not_unsafe_ptr_arg_deref.rs b/clippy_lints/src/functions/not_unsafe_ptr_arg_deref.rs index cc69f4aed0c..b8ea6990866 100644 --- a/clippy_lints/src/functions/not_unsafe_ptr_arg_deref.rs +++ b/clippy_lints/src/functions/not_unsafe_ptr_arg_deref.rs @@ -27,7 +27,7 @@ pub(super) fn check_fn( pub(super) fn check_trait_item(cx: &LateContext<'tcx>, item: &'tcx hir::TraitItem<'_>) { if let hir::TraitItemKind::Fn(ref sig, hir::TraitFn::Provided(eid)) = item.kind { let body = cx.tcx.hir().body(eid); - check_raw_ptr(cx, sig.header.unsafety, &sig.decl, body, item.hir_id()); + check_raw_ptr(cx, sig.header.unsafety, sig.decl, body, item.hir_id()); } } @@ -77,7 +77,7 @@ impl<'a, 'tcx> intravisit::Visitor<'tcx> for DerefVisitor<'a, 'tcx> { fn visit_expr(&mut self, expr: &'tcx hir::Expr<'_>) { match expr.kind { - hir::ExprKind::Call(ref f, args) => { + hir::ExprKind::Call(f, args) => { let ty = self.typeck_results.expr_ty(f); if type_is_unsafe_function(self.cx, ty) { @@ -96,7 +96,7 @@ impl<'a, 'tcx> intravisit::Visitor<'tcx> for DerefVisitor<'a, 'tcx> { } } }, - hir::ExprKind::Unary(hir::UnOp::Deref, ref ptr) => self.check_arg(ptr), + hir::ExprKind::Unary(hir::UnOp::Deref, ptr) => self.check_arg(ptr), _ => (), } diff --git a/clippy_lints/src/functions/result_unit_err.rs b/clippy_lints/src/functions/result_unit_err.rs index 3d1092ce21f..c073f312d38 100644 --- a/clippy_lints/src/functions/result_unit_err.rs +++ b/clippy_lints/src/functions/result_unit_err.rs @@ -18,7 +18,7 @@ pub(super) fn check_item(cx: &LateContext<'tcx>, item: &'tcx hir::Item<'_>) { let is_public = cx.access_levels.is_exported(item.hir_id()); let fn_header_span = item.span.with_hi(sig.decl.output.span().hi()); if is_public { - check_result_unit_err(cx, &sig.decl, item.span, fn_header_span); + check_result_unit_err(cx, sig.decl, item.span, fn_header_span); } } } @@ -28,7 +28,7 @@ pub(super) fn check_impl_item(cx: &LateContext<'tcx>, item: &'tcx hir::ImplItem< let is_public = cx.access_levels.is_exported(item.hir_id()); let fn_header_span = item.span.with_hi(sig.decl.output.span().hi()); if is_public && trait_ref_of_method(cx, item.hir_id()).is_none() { - check_result_unit_err(cx, &sig.decl, item.span, fn_header_span); + check_result_unit_err(cx, sig.decl, item.span, fn_header_span); } } } @@ -38,7 +38,7 @@ pub(super) fn check_trait_item(cx: &LateContext<'tcx>, item: &'tcx hir::TraitIte let is_public = cx.access_levels.is_exported(item.hir_id()); let fn_header_span = item.span.with_hi(sig.decl.output.span().hi()); if is_public { - check_result_unit_err(cx, &sig.decl, item.span, fn_header_span); + check_result_unit_err(cx, sig.decl, item.span, fn_header_span); } } } @@ -46,7 +46,7 @@ pub(super) fn check_trait_item(cx: &LateContext<'tcx>, item: &'tcx hir::TraitIte fn check_result_unit_err(cx: &LateContext<'_>, decl: &hir::FnDecl<'_>, item_span: Span, fn_header_span: Span) { if_chain! { if !in_external_macro(cx.sess(), item_span); - if let hir::FnRetTy::Return(ref ty) = decl.output; + if let hir::FnRetTy::Return(ty) = decl.output; let ty = hir_ty_to_ty(cx.tcx, ty); if is_type_diagnostic_item(cx, ty, sym::result_type); if let ty::Adt(_, substs) = ty.kind(); diff --git a/clippy_lints/src/functions/too_many_arguments.rs b/clippy_lints/src/functions/too_many_arguments.rs index 62b1e6bd7ca..63a14d8d4cd 100644 --- a/clippy_lints/src/functions/too_many_arguments.rs +++ b/clippy_lints/src/functions/too_many_arguments.rs @@ -49,7 +49,7 @@ pub(super) fn check_trait_item( if sig.header.abi == Abi::Rust { check_arg_number( cx, - &sig.decl, + sig.decl, item.span.with_hi(sig.decl.output.span().hi()), too_many_arguments_threshold, ); diff --git a/clippy_lints/src/get_last_with_len.rs b/clippy_lints/src/get_last_with_len.rs index cbcef567c53..3707e792177 100644 --- a/clippy_lints/src/get_last_with_len.rs +++ b/clippy_lints/src/get_last_with_len.rs @@ -51,7 +51,7 @@ impl<'tcx> LateLintPass<'tcx> for GetLastWithLen { fn check_expr(&mut self, cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) { if_chain! { // Is a method call - if let ExprKind::MethodCall(ref path, _, ref args, _) = expr.kind; + if let ExprKind::MethodCall(path, _, args, _) = expr.kind; // Method name is "get" if path.ident.name == sym!(get); diff --git a/clippy_lints/src/identity_op.rs b/clippy_lints/src/identity_op.rs index 8bed5e1bf64..366b3b46a8a 100644 --- a/clippy_lints/src/identity_op.rs +++ b/clippy_lints/src/identity_op.rs @@ -35,7 +35,7 @@ impl<'tcx> LateLintPass<'tcx> for IdentityOp { if e.span.from_expansion() { return; } - if let ExprKind::Binary(cmp, ref left, ref right) = e.kind { + if let ExprKind::Binary(cmp, left, right) = e.kind { if is_allowed(cx, cmp, left, right) { return; } diff --git a/clippy_lints/src/if_let_mutex.rs b/clippy_lints/src/if_let_mutex.rs index 56dfcc6a506..f661f7ede82 100644 --- a/clippy_lints/src/if_let_mutex.rs +++ b/clippy_lints/src/if_let_mutex.rs @@ -55,8 +55,8 @@ impl<'tcx> LateLintPass<'tcx> for IfLetMutex { cx, }; if let ExprKind::Match( - ref op, - ref arms, + op, + arms, MatchSource::IfLetDesugar { contains_else_clause: true, }, @@ -64,7 +64,7 @@ impl<'tcx> LateLintPass<'tcx> for IfLetMutex { { op_visit.visit_expr(op); if op_visit.mutex_lock_called { - for arm in *arms { + for arm in arms { arm_visit.visit_arm(arm); } diff --git a/clippy_lints/src/if_let_some_result.rs b/clippy_lints/src/if_let_some_result.rs index 6e9280c8c7e..611da3744ee 100644 --- a/clippy_lints/src/if_let_some_result.rs +++ b/clippy_lints/src/if_let_some_result.rs @@ -44,9 +44,9 @@ declare_lint_pass!(OkIfLet => [IF_LET_SOME_RESULT]); impl<'tcx> LateLintPass<'tcx> for OkIfLet { fn check_expr(&mut self, cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) { if_chain! { //begin checking variables - if let ExprKind::Match(ref op, ref body, MatchSource::IfLetDesugar { .. }) = expr.kind; //test if expr is if let - if let ExprKind::MethodCall(_, ok_span, ref result_types, _) = op.kind; //check is expr.ok() has type Result.ok(, _) - if let PatKind::TupleStruct(QPath::Resolved(_, ref x), ref y, _) = body[0].pat.kind; //get operation + if let ExprKind::Match(op, body, MatchSource::IfLetDesugar { .. }) = expr.kind; //test if expr is if let + if let ExprKind::MethodCall(_, ok_span, result_types, _) = op.kind; //check is expr.ok() has type Result.ok(, _) + if let PatKind::TupleStruct(QPath::Resolved(_, x), y, _) = body[0].pat.kind; //get operation if method_chain_args(op, &["ok"]).is_some(); //test to see if using ok() methoduse std::marker::Sized; if is_type_diagnostic_item(cx, cx.typeck_results().expr_ty(&result_types[0]), sym::result_type); if rustc_hir_pretty::to_string(rustc_hir_pretty::NO_ANN, |s| s.print_path(x, false)) == "Some"; diff --git a/clippy_lints/src/if_then_some_else_none.rs b/clippy_lints/src/if_then_some_else_none.rs index 0b5bf060d4c..ee16519692f 100644 --- a/clippy_lints/src/if_then_some_else_none.rs +++ b/clippy_lints/src/if_then_some_else_none.rs @@ -72,15 +72,15 @@ impl LateLintPass<'_> for IfThenSomeElseNone { } if_chain! { - if let ExprKind::If(ref cond, ref then, Some(ref els)) = expr.kind; - if let ExprKind::Block(ref then_block, _) = then.kind; - if let Some(ref then_expr) = then_block.expr; - if let ExprKind::Call(ref then_call, [then_arg]) = then_expr.kind; + if let ExprKind::If(cond, then, Some(els)) = expr.kind; + if let ExprKind::Block(then_block, _) = then.kind; + if let Some(then_expr) = then_block.expr; + if let ExprKind::Call(then_call, [then_arg]) = then_expr.kind; if let ExprKind::Path(ref then_call_qpath) = then_call.kind; if match_qpath(then_call_qpath, &clippy_utils::paths::OPTION_SOME); - if let ExprKind::Block(ref els_block, _) = els.kind; + if let ExprKind::Block(els_block, _) = els.kind; if els_block.stmts.is_empty(); - if let Some(ref els_expr) = els_block.expr; + if let Some(els_expr) = els_block.expr; if let ExprKind::Path(ref els_call_qpath) = els_expr.kind; if match_qpath(els_call_qpath, &clippy_utils::paths::OPTION_NONE); then { diff --git a/clippy_lints/src/implicit_hasher.rs b/clippy_lints/src/implicit_hasher.rs index 0b748b4d72d..77a38544edc 100644 --- a/clippy_lints/src/implicit_hasher.rs +++ b/clippy_lints/src/implicit_hasher.rs @@ -207,7 +207,7 @@ enum ImplicitHasherType<'tcx> { impl<'tcx> ImplicitHasherType<'tcx> { /// Checks that `ty` is a target type without a `BuildHasher`. fn new(cx: &LateContext<'tcx>, hir_ty: &hir::Ty<'_>) -> Option { - if let TyKind::Path(QPath::Resolved(None, ref path)) = hir_ty.kind { + if let TyKind::Path(QPath::Resolved(None, path)) = hir_ty.kind { let params: Vec<_> = path .segments .last() @@ -330,8 +330,8 @@ impl<'a, 'b, 'tcx> Visitor<'tcx> for ImplicitHasherConstructorVisitor<'a, 'b, 't fn visit_expr(&mut self, e: &'tcx Expr<'_>) { if_chain! { - if let ExprKind::Call(ref fun, ref args) = e.kind; - if let ExprKind::Path(QPath::TypeRelative(ref ty, ref method)) = fun.kind; + if let ExprKind::Call(fun, args) = e.kind; + if let ExprKind::Path(QPath::TypeRelative(ty, method)) = fun.kind; if let TyKind::Path(QPath::Resolved(None, ty_path)) = ty.kind; then { if !TyS::same_type(self.target.ty(), self.maybe_typeck_results.unwrap().expr_ty(e)) { diff --git a/clippy_lints/src/implicit_return.rs b/clippy_lints/src/implicit_return.rs index 6863645a92d..6b379b0d59b 100644 --- a/clippy_lints/src/implicit_return.rs +++ b/clippy_lints/src/implicit_return.rs @@ -100,10 +100,10 @@ fn expr_match(cx: &LateContext<'_>, expr: &Expr<'_>) { if check_all_arms { for arm in arms { - expr_match(cx, &arm.body); + expr_match(cx, arm.body); } } else { - expr_match(cx, &arms.first().expect("`if let` doesn't have a single arm").body); + expr_match(cx, arms.first().expect("`if let` doesn't have a single arm").body); } }, // skip if it already has a return statement diff --git a/clippy_lints/src/implicit_saturating_sub.rs b/clippy_lints/src/implicit_saturating_sub.rs index 5207c628987..cba3183e869 100644 --- a/clippy_lints/src/implicit_saturating_sub.rs +++ b/clippy_lints/src/implicit_saturating_sub.rs @@ -46,21 +46,21 @@ impl<'tcx> LateLintPass<'tcx> for ImplicitSaturatingSub { if let ExprKind::If(cond, then, None) = &expr.kind; // Check if the conditional expression is a binary operation - if let ExprKind::Binary(ref cond_op, ref cond_left, ref cond_right) = cond.kind; + if let ExprKind::Binary(ref cond_op, cond_left, cond_right) = cond.kind; // Ensure that the binary operator is >, != and < if BinOpKind::Ne == cond_op.node || BinOpKind::Gt == cond_op.node || BinOpKind::Lt == cond_op.node; // Check if the true condition block has only one statement - if let ExprKind::Block(ref block, _) = then.kind; + if let ExprKind::Block(block, _) = then.kind; if block.stmts.len() == 1 && block.expr.is_none(); // Check if assign operation is done - if let StmtKind::Semi(ref e) = block.stmts[0].kind; + if let StmtKind::Semi(e) = block.stmts[0].kind; if let Some(target) = subtracts_one(cx, e); // Extracting out the variable name - if let ExprKind::Path(QPath::Resolved(_, ref ares_path)) = target.kind; + if let ExprKind::Path(QPath::Resolved(_, ares_path)) = target.kind; then { // Handle symmetric conditions in the if statement @@ -104,7 +104,7 @@ impl<'tcx> LateLintPass<'tcx> for ImplicitSaturatingSub { print_lint_and_sugg(cx, &var_name, expr); }; }, - ExprKind::Call(ref func, _) => { + ExprKind::Call(func, _) => { if let ExprKind::Path(ref cond_num_path) = func.kind { if INT_TYPES.iter().any(|int_type| match_qpath(cond_num_path, &[int_type, "min_value"])) { print_lint_and_sugg(cx, &var_name, expr); @@ -120,7 +120,7 @@ impl<'tcx> LateLintPass<'tcx> for ImplicitSaturatingSub { fn subtracts_one<'a>(cx: &LateContext<'_>, expr: &Expr<'a>) -> Option<&'a Expr<'a>> { match expr.kind { - ExprKind::AssignOp(ref op1, ref target, ref value) => { + ExprKind::AssignOp(ref op1, target, value) => { if_chain! { if BinOpKind::Sub == op1.node; // Check if literal being subtracted is one @@ -133,9 +133,9 @@ fn subtracts_one<'a>(cx: &LateContext<'_>, expr: &Expr<'a>) -> Option<&'a Expr<' } } }, - ExprKind::Assign(ref target, ref value, _) => { + ExprKind::Assign(target, value, _) => { if_chain! { - if let ExprKind::Binary(ref op1, ref left1, ref right1) = value.kind; + if let ExprKind::Binary(ref op1, left1, right1) = value.kind; if BinOpKind::Sub == op1.node; if SpanlessEq::new(cx).eq_expr(left1, target); diff --git a/clippy_lints/src/indexing_slicing.rs b/clippy_lints/src/indexing_slicing.rs index 94d39019608..1c54599abc4 100644 --- a/clippy_lints/src/indexing_slicing.rs +++ b/clippy_lints/src/indexing_slicing.rs @@ -88,7 +88,7 @@ declare_lint_pass!(IndexingSlicing => [INDEXING_SLICING, OUT_OF_BOUNDS_INDEXING] impl<'tcx> LateLintPass<'tcx> for IndexingSlicing { fn check_expr(&mut self, cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) { - if let ExprKind::Index(ref array, ref index) = &expr.kind { + if let ExprKind::Index(array, index) = &expr.kind { let ty = cx.typeck_results().expr_ty(array).peel_refs(); if let Some(range) = higher::range(index) { // Ranged indexes, i.e., &x[n..m], &x[n..], &x[..n] and &x[..] diff --git a/clippy_lints/src/infinite_iter.rs b/clippy_lints/src/infinite_iter.rs index fb35bc1e780..bbb4ddc613a 100644 --- a/clippy_lints/src/infinite_iter.rs +++ b/clippy_lints/src/infinite_iter.rs @@ -139,7 +139,7 @@ const HEURISTICS: [(&str, usize, Heuristic, Finiteness); 19] = [ fn is_infinite(cx: &LateContext<'_>, expr: &Expr<'_>) -> Finiteness { match expr.kind { - ExprKind::MethodCall(ref method, _, ref args, _) => { + ExprKind::MethodCall(method, _, args, _) => { for &(name, len, heuristic, cap) in &HEURISTICS { if method.ident.name.as_str() == name && args.len() == len { return (match heuristic { @@ -159,9 +159,9 @@ fn is_infinite(cx: &LateContext<'_>, expr: &Expr<'_>) -> Finiteness { } Finite }, - ExprKind::Block(ref block, _) => block.expr.as_ref().map_or(Finite, |e| is_infinite(cx, e)), - ExprKind::Box(ref e) | ExprKind::AddrOf(BorrowKind::Ref, _, ref e) => is_infinite(cx, e), - ExprKind::Call(ref path, _) => { + ExprKind::Block(block, _) => block.expr.as_ref().map_or(Finite, |e| is_infinite(cx, e)), + ExprKind::Box(e) | ExprKind::AddrOf(BorrowKind::Ref, _, e) => is_infinite(cx, e), + ExprKind::Call(path, _) => { if let ExprKind::Path(ref qpath) = path.kind { match_qpath(qpath, &paths::REPEAT).into() } else { @@ -215,7 +215,7 @@ const INFINITE_COLLECTORS: [&[&str]; 8] = [ fn complete_infinite_iter(cx: &LateContext<'_>, expr: &Expr<'_>) -> Finiteness { match expr.kind { - ExprKind::MethodCall(ref method, _, ref args, _) => { + ExprKind::MethodCall(method, _, args, _) => { for &(name, len) in &COMPLETING_METHODS { if method.ident.name.as_str() == name && args.len() == len { return is_infinite(cx, &args[0]); @@ -240,7 +240,7 @@ fn complete_infinite_iter(cx: &LateContext<'_>, expr: &Expr<'_>) -> Finiteness { } } }, - ExprKind::Binary(op, ref l, ref r) => { + ExprKind::Binary(op, l, r) => { if op.node.is_comparison() { return is_infinite(cx, l).and(is_infinite(cx, r)).and(MaybeInfinite); } diff --git a/clippy_lints/src/invalid_upcast_comparisons.rs b/clippy_lints/src/invalid_upcast_comparisons.rs index d183fc41f31..c67c02eefa5 100644 --- a/clippy_lints/src/invalid_upcast_comparisons.rs +++ b/clippy_lints/src/invalid_upcast_comparisons.rs @@ -86,7 +86,7 @@ impl Ord for FullInt { } fn numeric_cast_precast_bounds<'a>(cx: &LateContext<'_>, expr: &'a Expr<'_>) -> Option<(FullInt, FullInt)> { - if let ExprKind::Cast(ref cast_exp, _) = expr.kind { + if let ExprKind::Cast(cast_exp, _) = expr.kind { let pre_cast_ty = cx.typeck_results().expr_ty(cast_exp); let cast_ty = cx.typeck_results().expr_ty(expr); // if it's a cast from i32 to u32 wrapping will invalidate all these checks @@ -131,7 +131,7 @@ fn node_as_const_fullint<'tcx>(cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) -> } fn err_upcast_comparison(cx: &LateContext<'_>, span: Span, expr: &Expr<'_>, always: bool) { - if let ExprKind::Cast(ref cast_val, _) = expr.kind { + if let ExprKind::Cast(cast_val, _) = expr.kind { span_lint( cx, INVALID_UPCAST_COMPARISONS, @@ -203,7 +203,7 @@ fn upcast_comparison_bounds_err<'tcx>( impl<'tcx> LateLintPass<'tcx> for InvalidUpcastComparisons { fn check_expr(&mut self, cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) { - if let ExprKind::Binary(ref cmp, ref lhs, ref rhs) = expr.kind { + if let ExprKind::Binary(ref cmp, lhs, rhs) = expr.kind { let normalized = comparisons::normalize_comparison(cmp.node, lhs, rhs); let (rel, normalized_lhs, normalized_rhs) = if let Some(val) = normalized { val diff --git a/clippy_lints/src/large_enum_variant.rs b/clippy_lints/src/large_enum_variant.rs index 76584dc1822..f166748d86b 100644 --- a/clippy_lints/src/large_enum_variant.rs +++ b/clippy_lints/src/large_enum_variant.rs @@ -113,7 +113,7 @@ impl<'tcx> LateLintPass<'tcx> for LargeEnumVariant { ); if variant.fields.len() == 1 { let span = match def.variants[i].data { - VariantData::Struct(ref fields, ..) | VariantData::Tuple(ref fields, ..) => { + VariantData::Struct(fields, ..) | VariantData::Tuple(fields, ..) => { fields[0].ty.span }, VariantData::Unit(..) => unreachable!(), diff --git a/clippy_lints/src/len_zero.rs b/clippy_lints/src/len_zero.rs index 78152ad9019..bb57adff7be 100644 --- a/clippy_lints/src/len_zero.rs +++ b/clippy_lints/src/len_zero.rs @@ -121,7 +121,7 @@ impl<'tcx> LateLintPass<'tcx> for LenZero { return; } - if let ItemKind::Trait(_, _, _, _, ref trait_items) = item.kind { + if let ItemKind::Trait(_, _, _, _, trait_items) = item.kind { check_trait_items(cx, item, trait_items); } } @@ -162,7 +162,7 @@ impl<'tcx> LateLintPass<'tcx> for LenZero { return; } - if let ExprKind::Binary(Spanned { node: cmp, .. }, ref left, ref right) = expr.kind { + if let ExprKind::Binary(Spanned { node: cmp, .. }, left, right) = expr.kind { match cmp { BinOpKind::Eq => { check_cmp(cx, expr.span, left, right, "", 0); // len == 0 @@ -372,8 +372,7 @@ fn check_for_is_empty( } fn check_cmp(cx: &LateContext<'_>, span: Span, method: &Expr<'_>, lit: &Expr<'_>, op: &str, compare_to: u32) { - if let (&ExprKind::MethodCall(ref method_path, _, ref args, _), &ExprKind::Lit(ref lit)) = (&method.kind, &lit.kind) - { + if let (&ExprKind::MethodCall(method_path, _, args, _), &ExprKind::Lit(ref lit)) = (&method.kind, &lit.kind) { // check if we are in an is_empty() method if let Some(name) = get_item_name(cx, method) { if name.as_str() == "is_empty" { @@ -451,7 +450,7 @@ fn is_empty_string(expr: &Expr<'_>) -> bool { } fn is_empty_array(expr: &Expr<'_>) -> bool { - if let ExprKind::Array(ref arr) = expr.kind { + if let ExprKind::Array(arr) = expr.kind { return arr.is_empty(); } false @@ -480,17 +479,17 @@ fn has_is_empty(cx: &LateContext<'_>, expr: &Expr<'_>) -> bool { cx.tcx .associated_items(*imp) .in_definition_order() - .any(|item| is_is_empty(cx, &item)) + .any(|item| is_is_empty(cx, item)) }) } let ty = &cx.typeck_results().expr_ty(expr).peel_refs(); match ty.kind() { - ty::Dynamic(ref tt, ..) => tt.principal().map_or(false, |principal| { + ty::Dynamic(tt, ..) => tt.principal().map_or(false, |principal| { cx.tcx .associated_items(principal.def_id()) .in_definition_order() - .any(|item| is_is_empty(cx, &item)) + .any(|item| is_is_empty(cx, item)) }), ty::Projection(ref proj) => has_is_empty_impl(cx, proj.item_def_id), ty::Adt(id, _) => has_is_empty_impl(cx, id.did), diff --git a/clippy_lints/src/let_if_seq.rs b/clippy_lints/src/let_if_seq.rs index 2d7d9c9befb..67eae4d87bb 100644 --- a/clippy_lints/src/let_if_seq.rs +++ b/clippy_lints/src/let_if_seq.rs @@ -61,13 +61,13 @@ impl<'tcx> LateLintPass<'tcx> for LetIfSeq { while let Some(stmt) = it.next() { if_chain! { if let Some(expr) = it.peek(); - if let hir::StmtKind::Local(ref local) = stmt.kind; + if let hir::StmtKind::Local(local) = stmt.kind; if let hir::PatKind::Binding(mode, canonical_id, ident, None) = local.pat.kind; - if let hir::StmtKind::Expr(ref if_) = expr.kind; - if let hir::ExprKind::If(ref cond, ref then, ref else_) = if_.kind; + if let hir::StmtKind::Expr(if_) = expr.kind; + if let hir::ExprKind::If(cond, then, ref else_) = if_.kind; let mut used_visitor = LocalUsedVisitor::new(cx, canonical_id); if !used_visitor.check_expr(cond); - if let hir::ExprKind::Block(ref then, _) = then.kind; + if let hir::ExprKind::Block(then, _) = then.kind; if let Some(value) = check_assign(cx, canonical_id, &*then); if !used_visitor.check_expr(value); then { @@ -79,20 +79,20 @@ impl<'tcx> LateLintPass<'tcx> for LetIfSeq { ); if has_interior_mutability { return; } - let (default_multi_stmts, default) = if let Some(ref else_) = *else_ { - if let hir::ExprKind::Block(ref else_, _) = else_.kind { + let (default_multi_stmts, default) = if let Some(else_) = *else_ { + if let hir::ExprKind::Block(else_, _) = else_.kind { if let Some(default) = check_assign(cx, canonical_id, else_) { (else_.stmts.len() > 1, default) - } else if let Some(ref default) = local.init { - (true, &**default) + } else if let Some(default) = local.init { + (true, default) } else { continue; } } else { continue; } - } else if let Some(ref default) = local.init { - (false, &**default) + } else if let Some(default) = local.init { + (false, default) } else { continue; }; @@ -144,8 +144,8 @@ fn check_assign<'tcx>( if_chain! { if block.expr.is_none(); if let Some(expr) = block.stmts.iter().last(); - if let hir::StmtKind::Semi(ref expr) = expr.kind; - if let hir::ExprKind::Assign(ref var, ref value, _) = expr.kind; + if let hir::StmtKind::Semi(expr) = expr.kind; + if let hir::ExprKind::Assign(var, value, _) = expr.kind; if path_to_local_id(var, decl); then { let mut v = LocalUsedVisitor::new(cx, decl); diff --git a/clippy_lints/src/let_underscore.rs b/clippy_lints/src/let_underscore.rs index 7e3a76ded2c..17e23781db7 100644 --- a/clippy_lints/src/let_underscore.rs +++ b/clippy_lints/src/let_underscore.rs @@ -116,7 +116,7 @@ impl<'tcx> LateLintPass<'tcx> for LetUnderscore { if_chain! { if let PatKind::Wild = local.pat.kind; - if let Some(ref init) = local.init; + if let Some(init) = local.init; then { let init_ty = cx.typeck_results().expr_ty(init); let contains_sync_guard = init_ty.walk().any(|inner| match inner.unpack() { diff --git a/clippy_lints/src/lib.rs b/clippy_lints/src/lib.rs index 43e89c2475f..cd92b551abd 100644 --- a/clippy_lints/src/lib.rs +++ b/clippy_lints/src/lib.rs @@ -541,482 +541,482 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf: // begin register lints, do not remove this comment, it’s used in `update_lints` store.register_lints(&[ #[cfg(feature = "internal-lints")] - &utils::internal_lints::CLIPPY_LINTS_INTERNAL, + utils::internal_lints::CLIPPY_LINTS_INTERNAL, #[cfg(feature = "internal-lints")] - &utils::internal_lints::COLLAPSIBLE_SPAN_LINT_CALLS, + utils::internal_lints::COLLAPSIBLE_SPAN_LINT_CALLS, #[cfg(feature = "internal-lints")] - &utils::internal_lints::COMPILER_LINT_FUNCTIONS, + utils::internal_lints::COMPILER_LINT_FUNCTIONS, #[cfg(feature = "internal-lints")] - &utils::internal_lints::DEFAULT_LINT, + utils::internal_lints::DEFAULT_LINT, #[cfg(feature = "internal-lints")] - &utils::internal_lints::IF_CHAIN_STYLE, + utils::internal_lints::IF_CHAIN_STYLE, #[cfg(feature = "internal-lints")] - &utils::internal_lints::INTERNING_DEFINED_SYMBOL, + utils::internal_lints::INTERNING_DEFINED_SYMBOL, #[cfg(feature = "internal-lints")] - &utils::internal_lints::INVALID_PATHS, + utils::internal_lints::INVALID_PATHS, #[cfg(feature = "internal-lints")] - &utils::internal_lints::LINT_WITHOUT_LINT_PASS, + utils::internal_lints::LINT_WITHOUT_LINT_PASS, #[cfg(feature = "internal-lints")] - &utils::internal_lints::MATCH_TYPE_ON_DIAGNOSTIC_ITEM, + utils::internal_lints::MATCH_TYPE_ON_DIAGNOSTIC_ITEM, #[cfg(feature = "internal-lints")] - &utils::internal_lints::OUTER_EXPN_EXPN_DATA, + utils::internal_lints::OUTER_EXPN_EXPN_DATA, #[cfg(feature = "internal-lints")] - &utils::internal_lints::PRODUCE_ICE, + utils::internal_lints::PRODUCE_ICE, #[cfg(feature = "internal-lints")] - &utils::internal_lints::UNNECESSARY_SYMBOL_STR, - &absurd_extreme_comparisons::ABSURD_EXTREME_COMPARISONS, - &approx_const::APPROX_CONSTANT, - &arithmetic::FLOAT_ARITHMETIC, - &arithmetic::INTEGER_ARITHMETIC, - &as_conversions::AS_CONVERSIONS, - &asm_syntax::INLINE_ASM_X86_ATT_SYNTAX, - &asm_syntax::INLINE_ASM_X86_INTEL_SYNTAX, - &assertions_on_constants::ASSERTIONS_ON_CONSTANTS, - &assign_ops::ASSIGN_OP_PATTERN, - &assign_ops::MISREFACTORED_ASSIGN_OP, - &async_yields_async::ASYNC_YIELDS_ASYNC, - &atomic_ordering::INVALID_ATOMIC_ORDERING, - &attrs::BLANKET_CLIPPY_RESTRICTION_LINTS, - &attrs::DEPRECATED_CFG_ATTR, - &attrs::DEPRECATED_SEMVER, - &attrs::EMPTY_LINE_AFTER_OUTER_ATTR, - &attrs::INLINE_ALWAYS, - &attrs::MISMATCHED_TARGET_OS, - &attrs::USELESS_ATTRIBUTE, - &await_holding_invalid::AWAIT_HOLDING_LOCK, - &await_holding_invalid::AWAIT_HOLDING_REFCELL_REF, - &bit_mask::BAD_BIT_MASK, - &bit_mask::INEFFECTIVE_BIT_MASK, - &bit_mask::VERBOSE_BIT_MASK, - &blacklisted_name::BLACKLISTED_NAME, - &blocks_in_if_conditions::BLOCKS_IN_IF_CONDITIONS, - &booleans::LOGIC_BUG, - &booleans::NONMINIMAL_BOOL, - &bytecount::NAIVE_BYTECOUNT, - &cargo_common_metadata::CARGO_COMMON_METADATA, - &case_sensitive_file_extension_comparisons::CASE_SENSITIVE_FILE_EXTENSION_COMPARISONS, - &casts::CAST_LOSSLESS, - &casts::CAST_POSSIBLE_TRUNCATION, - &casts::CAST_POSSIBLE_WRAP, - &casts::CAST_PRECISION_LOSS, - &casts::CAST_PTR_ALIGNMENT, - &casts::CAST_REF_TO_MUT, - &casts::CAST_SIGN_LOSS, - &casts::CHAR_LIT_AS_U8, - &casts::FN_TO_NUMERIC_CAST, - &casts::FN_TO_NUMERIC_CAST_WITH_TRUNCATION, - &casts::PTR_AS_PTR, - &casts::UNNECESSARY_CAST, - &checked_conversions::CHECKED_CONVERSIONS, - &cognitive_complexity::COGNITIVE_COMPLEXITY, - &collapsible_if::COLLAPSIBLE_ELSE_IF, - &collapsible_if::COLLAPSIBLE_IF, - &collapsible_match::COLLAPSIBLE_MATCH, - &comparison_chain::COMPARISON_CHAIN, - &copies::BRANCHES_SHARING_CODE, - &copies::IFS_SAME_COND, - &copies::IF_SAME_THEN_ELSE, - &copies::SAME_FUNCTIONS_IN_IF_CONDITION, - ©_iterator::COPY_ITERATOR, - &create_dir::CREATE_DIR, - &dbg_macro::DBG_MACRO, - &default::DEFAULT_TRAIT_ACCESS, - &default::FIELD_REASSIGN_WITH_DEFAULT, - &default_numeric_fallback::DEFAULT_NUMERIC_FALLBACK, - &dereference::EXPLICIT_DEREF_METHODS, - &derive::DERIVE_HASH_XOR_EQ, - &derive::DERIVE_ORD_XOR_PARTIAL_ORD, - &derive::EXPL_IMPL_CLONE_ON_COPY, - &derive::UNSAFE_DERIVE_DESERIALIZE, - &disallowed_method::DISALLOWED_METHOD, - &doc::DOC_MARKDOWN, - &doc::MISSING_ERRORS_DOC, - &doc::MISSING_PANICS_DOC, - &doc::MISSING_SAFETY_DOC, - &doc::NEEDLESS_DOCTEST_MAIN, - &double_comparison::DOUBLE_COMPARISONS, - &double_parens::DOUBLE_PARENS, - &drop_forget_ref::DROP_COPY, - &drop_forget_ref::DROP_REF, - &drop_forget_ref::FORGET_COPY, - &drop_forget_ref::FORGET_REF, - &duration_subsec::DURATION_SUBSEC, - &else_if_without_else::ELSE_IF_WITHOUT_ELSE, - &empty_enum::EMPTY_ENUM, - &entry::MAP_ENTRY, - &enum_clike::ENUM_CLIKE_UNPORTABLE_VARIANT, - &enum_variants::ENUM_VARIANT_NAMES, - &enum_variants::MODULE_INCEPTION, - &enum_variants::MODULE_NAME_REPETITIONS, - &enum_variants::PUB_ENUM_VARIANT_NAMES, - &eq_op::EQ_OP, - &eq_op::OP_REF, - &erasing_op::ERASING_OP, - &escape::BOXED_LOCAL, - &eta_reduction::REDUNDANT_CLOSURE, - &eta_reduction::REDUNDANT_CLOSURE_FOR_METHOD_CALLS, - &eval_order_dependence::DIVERGING_SUB_EXPRESSION, - &eval_order_dependence::EVAL_ORDER_DEPENDENCE, - &excessive_bools::FN_PARAMS_EXCESSIVE_BOOLS, - &excessive_bools::STRUCT_EXCESSIVE_BOOLS, - &exhaustive_items::EXHAUSTIVE_ENUMS, - &exhaustive_items::EXHAUSTIVE_STRUCTS, - &exit::EXIT, - &explicit_write::EXPLICIT_WRITE, - &fallible_impl_from::FALLIBLE_IMPL_FROM, - &float_equality_without_abs::FLOAT_EQUALITY_WITHOUT_ABS, - &float_literal::EXCESSIVE_PRECISION, - &float_literal::LOSSY_FLOAT_LITERAL, - &floating_point_arithmetic::IMPRECISE_FLOPS, - &floating_point_arithmetic::SUBOPTIMAL_FLOPS, - &format::USELESS_FORMAT, - &formatting::POSSIBLE_MISSING_COMMA, - &formatting::SUSPICIOUS_ASSIGNMENT_FORMATTING, - &formatting::SUSPICIOUS_ELSE_FORMATTING, - &formatting::SUSPICIOUS_UNARY_OP_FORMATTING, - &from_over_into::FROM_OVER_INTO, - &from_str_radix_10::FROM_STR_RADIX_10, - &functions::DOUBLE_MUST_USE, - &functions::MUST_USE_CANDIDATE, - &functions::MUST_USE_UNIT, - &functions::NOT_UNSAFE_PTR_ARG_DEREF, - &functions::RESULT_UNIT_ERR, - &functions::TOO_MANY_ARGUMENTS, - &functions::TOO_MANY_LINES, - &future_not_send::FUTURE_NOT_SEND, - &get_last_with_len::GET_LAST_WITH_LEN, - &identity_op::IDENTITY_OP, - &if_let_mutex::IF_LET_MUTEX, - &if_let_some_result::IF_LET_SOME_RESULT, - &if_not_else::IF_NOT_ELSE, - &if_then_some_else_none::IF_THEN_SOME_ELSE_NONE, - &implicit_hasher::IMPLICIT_HASHER, - &implicit_return::IMPLICIT_RETURN, - &implicit_saturating_sub::IMPLICIT_SATURATING_SUB, - &inconsistent_struct_constructor::INCONSISTENT_STRUCT_CONSTRUCTOR, - &indexing_slicing::INDEXING_SLICING, - &indexing_slicing::OUT_OF_BOUNDS_INDEXING, - &infinite_iter::INFINITE_ITER, - &infinite_iter::MAYBE_INFINITE_ITER, - &inherent_impl::MULTIPLE_INHERENT_IMPL, - &inherent_to_string::INHERENT_TO_STRING, - &inherent_to_string::INHERENT_TO_STRING_SHADOW_DISPLAY, - &inline_fn_without_body::INLINE_FN_WITHOUT_BODY, - &int_plus_one::INT_PLUS_ONE, - &integer_division::INTEGER_DIVISION, - &invalid_upcast_comparisons::INVALID_UPCAST_COMPARISONS, - &items_after_statements::ITEMS_AFTER_STATEMENTS, - &large_const_arrays::LARGE_CONST_ARRAYS, - &large_enum_variant::LARGE_ENUM_VARIANT, - &large_stack_arrays::LARGE_STACK_ARRAYS, - &len_zero::COMPARISON_TO_EMPTY, - &len_zero::LEN_WITHOUT_IS_EMPTY, - &len_zero::LEN_ZERO, - &let_if_seq::USELESS_LET_IF_SEQ, - &let_underscore::LET_UNDERSCORE_DROP, - &let_underscore::LET_UNDERSCORE_LOCK, - &let_underscore::LET_UNDERSCORE_MUST_USE, - &lifetimes::EXTRA_UNUSED_LIFETIMES, - &lifetimes::NEEDLESS_LIFETIMES, - &literal_representation::DECIMAL_LITERAL_REPRESENTATION, - &literal_representation::INCONSISTENT_DIGIT_GROUPING, - &literal_representation::LARGE_DIGIT_GROUPS, - &literal_representation::MISTYPED_LITERAL_SUFFIXES, - &literal_representation::UNREADABLE_LITERAL, - &literal_representation::UNUSUAL_BYTE_GROUPINGS, - &loops::EMPTY_LOOP, - &loops::EXPLICIT_COUNTER_LOOP, - &loops::EXPLICIT_INTO_ITER_LOOP, - &loops::EXPLICIT_ITER_LOOP, - &loops::FOR_KV_MAP, - &loops::FOR_LOOPS_OVER_FALLIBLES, - &loops::ITER_NEXT_LOOP, - &loops::MANUAL_FLATTEN, - &loops::MANUAL_MEMCPY, - &loops::MUT_RANGE_BOUND, - &loops::NEEDLESS_COLLECT, - &loops::NEEDLESS_RANGE_LOOP, - &loops::NEVER_LOOP, - &loops::SAME_ITEM_PUSH, - &loops::SINGLE_ELEMENT_LOOP, - &loops::WHILE_IMMUTABLE_CONDITION, - &loops::WHILE_LET_LOOP, - &loops::WHILE_LET_ON_ITERATOR, - ¯o_use::MACRO_USE_IMPORTS, - &main_recursion::MAIN_RECURSION, - &manual_async_fn::MANUAL_ASYNC_FN, - &manual_map::MANUAL_MAP, - &manual_non_exhaustive::MANUAL_NON_EXHAUSTIVE, - &manual_ok_or::MANUAL_OK_OR, - &manual_strip::MANUAL_STRIP, - &manual_unwrap_or::MANUAL_UNWRAP_OR, - &map_clone::MAP_CLONE, - &map_err_ignore::MAP_ERR_IGNORE, - &map_identity::MAP_IDENTITY, - &map_unit_fn::OPTION_MAP_UNIT_FN, - &map_unit_fn::RESULT_MAP_UNIT_FN, - &match_on_vec_items::MATCH_ON_VEC_ITEMS, - &matches::INFALLIBLE_DESTRUCTURING_MATCH, - &matches::MATCH_AS_REF, - &matches::MATCH_BOOL, - &matches::MATCH_LIKE_MATCHES_MACRO, - &matches::MATCH_OVERLAPPING_ARM, - &matches::MATCH_REF_PATS, - &matches::MATCH_SAME_ARMS, - &matches::MATCH_SINGLE_BINDING, - &matches::MATCH_WILDCARD_FOR_SINGLE_VARIANTS, - &matches::MATCH_WILD_ERR_ARM, - &matches::REDUNDANT_PATTERN_MATCHING, - &matches::REST_PAT_IN_FULLY_BOUND_STRUCTS, - &matches::SINGLE_MATCH, - &matches::SINGLE_MATCH_ELSE, - &matches::WILDCARD_ENUM_MATCH_ARM, - &matches::WILDCARD_IN_OR_PATTERNS, - &mem_discriminant::MEM_DISCRIMINANT_NON_ENUM, - &mem_forget::MEM_FORGET, - &mem_replace::MEM_REPLACE_OPTION_WITH_NONE, - &mem_replace::MEM_REPLACE_WITH_DEFAULT, - &mem_replace::MEM_REPLACE_WITH_UNINIT, - &methods::BIND_INSTEAD_OF_MAP, - &methods::BYTES_NTH, - &methods::CHARS_LAST_CMP, - &methods::CHARS_NEXT_CMP, - &methods::CLONE_DOUBLE_REF, - &methods::CLONE_ON_COPY, - &methods::CLONE_ON_REF_PTR, - &methods::EXPECT_FUN_CALL, - &methods::EXPECT_USED, - &methods::FILETYPE_IS_FILE, - &methods::FILTER_MAP, - &methods::FILTER_MAP_IDENTITY, - &methods::FILTER_MAP_NEXT, - &methods::FILTER_NEXT, - &methods::FLAT_MAP_IDENTITY, - &methods::FROM_ITER_INSTEAD_OF_COLLECT, - &methods::GET_UNWRAP, - &methods::IMPLICIT_CLONE, - &methods::INEFFICIENT_TO_STRING, - &methods::INSPECT_FOR_EACH, - &methods::INTO_ITER_ON_REF, - &methods::ITERATOR_STEP_BY_ZERO, - &methods::ITER_CLONED_COLLECT, - &methods::ITER_COUNT, - &methods::ITER_NEXT_SLICE, - &methods::ITER_NTH, - &methods::ITER_NTH_ZERO, - &methods::ITER_SKIP_NEXT, - &methods::MANUAL_FILTER_MAP, - &methods::MANUAL_FIND_MAP, - &methods::MANUAL_SATURATING_ARITHMETIC, - &methods::MAP_COLLECT_RESULT_UNIT, - &methods::MAP_FLATTEN, - &methods::MAP_UNWRAP_OR, - &methods::NEW_RET_NO_SELF, - &methods::OK_EXPECT, - &methods::OPTION_AS_REF_DEREF, - &methods::OPTION_FILTER_MAP, - &methods::OPTION_MAP_OR_NONE, - &methods::OR_FUN_CALL, - &methods::RESULT_MAP_OR_INTO_OPTION, - &methods::SEARCH_IS_SOME, - &methods::SHOULD_IMPLEMENT_TRAIT, - &methods::SINGLE_CHAR_ADD_STR, - &methods::SINGLE_CHAR_PATTERN, - &methods::SKIP_WHILE_NEXT, - &methods::STRING_EXTEND_CHARS, - &methods::SUSPICIOUS_MAP, - &methods::UNINIT_ASSUMED_INIT, - &methods::UNNECESSARY_FILTER_MAP, - &methods::UNNECESSARY_FOLD, - &methods::UNNECESSARY_LAZY_EVALUATIONS, - &methods::UNWRAP_USED, - &methods::USELESS_ASREF, - &methods::WRONG_PUB_SELF_CONVENTION, - &methods::WRONG_SELF_CONVENTION, - &methods::ZST_OFFSET, - &minmax::MIN_MAX, - &misc::CMP_NAN, - &misc::CMP_OWNED, - &misc::FLOAT_CMP, - &misc::FLOAT_CMP_CONST, - &misc::MODULO_ONE, - &misc::SHORT_CIRCUIT_STATEMENT, - &misc::TOPLEVEL_REF_ARG, - &misc::USED_UNDERSCORE_BINDING, - &misc::ZERO_PTR, - &misc_early::BUILTIN_TYPE_SHADOW, - &misc_early::DOUBLE_NEG, - &misc_early::DUPLICATE_UNDERSCORE_ARGUMENT, - &misc_early::MIXED_CASE_HEX_LITERALS, - &misc_early::REDUNDANT_PATTERN, - &misc_early::UNNEEDED_FIELD_PATTERN, - &misc_early::UNNEEDED_WILDCARD_PATTERN, - &misc_early::UNSEPARATED_LITERAL_SUFFIX, - &misc_early::ZERO_PREFIXED_LITERAL, - &missing_const_for_fn::MISSING_CONST_FOR_FN, - &missing_doc::MISSING_DOCS_IN_PRIVATE_ITEMS, - &missing_inline::MISSING_INLINE_IN_PUBLIC_ITEMS, - &modulo_arithmetic::MODULO_ARITHMETIC, - &multiple_crate_versions::MULTIPLE_CRATE_VERSIONS, - &mut_key::MUTABLE_KEY_TYPE, - &mut_mut::MUT_MUT, - &mut_mutex_lock::MUT_MUTEX_LOCK, - &mut_reference::UNNECESSARY_MUT_PASSED, - &mutable_debug_assertion::DEBUG_ASSERT_WITH_MUT_CALL, - &mutex_atomic::MUTEX_ATOMIC, - &mutex_atomic::MUTEX_INTEGER, - &needless_arbitrary_self_type::NEEDLESS_ARBITRARY_SELF_TYPE, - &needless_bool::BOOL_COMPARISON, - &needless_bool::NEEDLESS_BOOL, - &needless_borrow::NEEDLESS_BORROW, - &needless_borrowed_ref::NEEDLESS_BORROWED_REFERENCE, - &needless_continue::NEEDLESS_CONTINUE, - &needless_for_each::NEEDLESS_FOR_EACH, - &needless_pass_by_value::NEEDLESS_PASS_BY_VALUE, - &needless_question_mark::NEEDLESS_QUESTION_MARK, - &needless_update::NEEDLESS_UPDATE, - &neg_cmp_op_on_partial_ord::NEG_CMP_OP_ON_PARTIAL_ORD, - &neg_multiply::NEG_MULTIPLY, - &new_without_default::NEW_WITHOUT_DEFAULT, - &no_effect::NO_EFFECT, - &no_effect::UNNECESSARY_OPERATION, - &non_copy_const::BORROW_INTERIOR_MUTABLE_CONST, - &non_copy_const::DECLARE_INTERIOR_MUTABLE_CONST, - &non_expressive_names::JUST_UNDERSCORES_AND_DIGITS, - &non_expressive_names::MANY_SINGLE_CHAR_NAMES, - &non_expressive_names::SIMILAR_NAMES, - &non_octal_unix_permissions::NON_OCTAL_UNIX_PERMISSIONS, - &open_options::NONSENSICAL_OPEN_OPTIONS, - &option_env_unwrap::OPTION_ENV_UNWRAP, - &option_if_let_else::OPTION_IF_LET_ELSE, - &overflow_check_conditional::OVERFLOW_CHECK_CONDITIONAL, - &panic_in_result_fn::PANIC_IN_RESULT_FN, - &panic_unimplemented::PANIC, - &panic_unimplemented::TODO, - &panic_unimplemented::UNIMPLEMENTED, - &panic_unimplemented::UNREACHABLE, - &partialeq_ne_impl::PARTIALEQ_NE_IMPL, - &pass_by_ref_or_value::LARGE_TYPES_PASSED_BY_VALUE, - &pass_by_ref_or_value::TRIVIALLY_COPY_PASS_BY_REF, - &path_buf_push_overwrite::PATH_BUF_PUSH_OVERWRITE, - &pattern_type_mismatch::PATTERN_TYPE_MISMATCH, - &precedence::PRECEDENCE, - &ptr::CMP_NULL, - &ptr::MUT_FROM_REF, - &ptr::PTR_ARG, - &ptr_eq::PTR_EQ, - &ptr_offset_with_cast::PTR_OFFSET_WITH_CAST, - &question_mark::QUESTION_MARK, - &ranges::MANUAL_RANGE_CONTAINS, - &ranges::RANGE_MINUS_ONE, - &ranges::RANGE_PLUS_ONE, - &ranges::RANGE_ZIP_WITH_LEN, - &ranges::REVERSED_EMPTY_RANGES, - &redundant_clone::REDUNDANT_CLONE, - &redundant_closure_call::REDUNDANT_CLOSURE_CALL, - &redundant_else::REDUNDANT_ELSE, - &redundant_field_names::REDUNDANT_FIELD_NAMES, - &redundant_pub_crate::REDUNDANT_PUB_CRATE, - &redundant_slicing::REDUNDANT_SLICING, - &redundant_static_lifetimes::REDUNDANT_STATIC_LIFETIMES, - &ref_option_ref::REF_OPTION_REF, - &reference::DEREF_ADDROF, - &reference::REF_IN_DEREF, - ®ex::INVALID_REGEX, - ®ex::TRIVIAL_REGEX, - &repeat_once::REPEAT_ONCE, - &returns::LET_AND_RETURN, - &returns::NEEDLESS_RETURN, - &self_assignment::SELF_ASSIGNMENT, - &semicolon_if_nothing_returned::SEMICOLON_IF_NOTHING_RETURNED, - &serde_api::SERDE_API_MISUSE, - &shadow::SHADOW_REUSE, - &shadow::SHADOW_SAME, - &shadow::SHADOW_UNRELATED, - &single_component_path_imports::SINGLE_COMPONENT_PATH_IMPORTS, - &size_of_in_element_count::SIZE_OF_IN_ELEMENT_COUNT, - &slow_vector_initialization::SLOW_VECTOR_INITIALIZATION, - &stable_sort_primitive::STABLE_SORT_PRIMITIVE, - &strings::STRING_ADD, - &strings::STRING_ADD_ASSIGN, - &strings::STRING_FROM_UTF8_AS_BYTES, - &strings::STRING_LIT_AS_BYTES, - &strings::STRING_TO_STRING, - &strings::STR_TO_STRING, - &suspicious_operation_groupings::SUSPICIOUS_OPERATION_GROUPINGS, - &suspicious_trait_impl::SUSPICIOUS_ARITHMETIC_IMPL, - &suspicious_trait_impl::SUSPICIOUS_OP_ASSIGN_IMPL, - &swap::ALMOST_SWAPPED, - &swap::MANUAL_SWAP, - &tabs_in_doc_comments::TABS_IN_DOC_COMMENTS, - &temporary_assignment::TEMPORARY_ASSIGNMENT, - &to_digit_is_some::TO_DIGIT_IS_SOME, - &to_string_in_display::TO_STRING_IN_DISPLAY, - &trait_bounds::TRAIT_DUPLICATION_IN_BOUNDS, - &trait_bounds::TYPE_REPETITION_IN_BOUNDS, - &transmute::CROSSPOINTER_TRANSMUTE, - &transmute::TRANSMUTES_EXPRESSIBLE_AS_PTR_CASTS, - &transmute::TRANSMUTE_BYTES_TO_STR, - &transmute::TRANSMUTE_FLOAT_TO_INT, - &transmute::TRANSMUTE_INT_TO_BOOL, - &transmute::TRANSMUTE_INT_TO_CHAR, - &transmute::TRANSMUTE_INT_TO_FLOAT, - &transmute::TRANSMUTE_PTR_TO_PTR, - &transmute::TRANSMUTE_PTR_TO_REF, - &transmute::UNSOUND_COLLECTION_TRANSMUTE, - &transmute::USELESS_TRANSMUTE, - &transmute::WRONG_TRANSMUTE, - &transmuting_null::TRANSMUTING_NULL, - &try_err::TRY_ERR, - &types::BORROWED_BOX, - &types::BOX_VEC, - &types::LINKEDLIST, - &types::OPTION_OPTION, - &types::RC_BUFFER, - &types::REDUNDANT_ALLOCATION, - &types::TYPE_COMPLEXITY, - &types::VEC_BOX, - &undropped_manually_drops::UNDROPPED_MANUALLY_DROPS, - &unicode::INVISIBLE_CHARACTERS, - &unicode::NON_ASCII_LITERAL, - &unicode::UNICODE_NOT_NFC, - &unit_return_expecting_ord::UNIT_RETURN_EXPECTING_ORD, - &unit_types::LET_UNIT_VALUE, - &unit_types::UNIT_ARG, - &unit_types::UNIT_CMP, - &unnamed_address::FN_ADDRESS_COMPARISONS, - &unnamed_address::VTABLE_ADDRESS_COMPARISONS, - &unnecessary_sort_by::UNNECESSARY_SORT_BY, - &unnecessary_wraps::UNNECESSARY_WRAPS, - &unnested_or_patterns::UNNESTED_OR_PATTERNS, - &unsafe_removed_from_name::UNSAFE_REMOVED_FROM_NAME, - &unused_io_amount::UNUSED_IO_AMOUNT, - &unused_self::UNUSED_SELF, - &unused_unit::UNUSED_UNIT, - &unwrap::PANICKING_UNWRAP, - &unwrap::UNNECESSARY_UNWRAP, - &unwrap_in_result::UNWRAP_IN_RESULT, - &upper_case_acronyms::UPPER_CASE_ACRONYMS, - &use_self::USE_SELF, - &useless_conversion::USELESS_CONVERSION, - &vec::USELESS_VEC, - &vec_init_then_push::VEC_INIT_THEN_PUSH, - &vec_resize_to_zero::VEC_RESIZE_TO_ZERO, - &verbose_file_reads::VERBOSE_FILE_READS, - &wildcard_dependencies::WILDCARD_DEPENDENCIES, - &wildcard_imports::ENUM_GLOB_USE, - &wildcard_imports::WILDCARD_IMPORTS, - &write::PRINTLN_EMPTY_STRING, - &write::PRINT_LITERAL, - &write::PRINT_STDERR, - &write::PRINT_STDOUT, - &write::PRINT_WITH_NEWLINE, - &write::USE_DEBUG, - &write::WRITELN_EMPTY_STRING, - &write::WRITE_LITERAL, - &write::WRITE_WITH_NEWLINE, - &zero_div_zero::ZERO_DIVIDED_BY_ZERO, - &zero_sized_map_values::ZERO_SIZED_MAP_VALUES, + utils::internal_lints::UNNECESSARY_SYMBOL_STR, + absurd_extreme_comparisons::ABSURD_EXTREME_COMPARISONS, + approx_const::APPROX_CONSTANT, + arithmetic::FLOAT_ARITHMETIC, + arithmetic::INTEGER_ARITHMETIC, + as_conversions::AS_CONVERSIONS, + asm_syntax::INLINE_ASM_X86_ATT_SYNTAX, + asm_syntax::INLINE_ASM_X86_INTEL_SYNTAX, + assertions_on_constants::ASSERTIONS_ON_CONSTANTS, + assign_ops::ASSIGN_OP_PATTERN, + assign_ops::MISREFACTORED_ASSIGN_OP, + async_yields_async::ASYNC_YIELDS_ASYNC, + atomic_ordering::INVALID_ATOMIC_ORDERING, + attrs::BLANKET_CLIPPY_RESTRICTION_LINTS, + attrs::DEPRECATED_CFG_ATTR, + attrs::DEPRECATED_SEMVER, + attrs::EMPTY_LINE_AFTER_OUTER_ATTR, + attrs::INLINE_ALWAYS, + attrs::MISMATCHED_TARGET_OS, + attrs::USELESS_ATTRIBUTE, + await_holding_invalid::AWAIT_HOLDING_LOCK, + await_holding_invalid::AWAIT_HOLDING_REFCELL_REF, + bit_mask::BAD_BIT_MASK, + bit_mask::INEFFECTIVE_BIT_MASK, + bit_mask::VERBOSE_BIT_MASK, + blacklisted_name::BLACKLISTED_NAME, + blocks_in_if_conditions::BLOCKS_IN_IF_CONDITIONS, + booleans::LOGIC_BUG, + booleans::NONMINIMAL_BOOL, + bytecount::NAIVE_BYTECOUNT, + cargo_common_metadata::CARGO_COMMON_METADATA, + case_sensitive_file_extension_comparisons::CASE_SENSITIVE_FILE_EXTENSION_COMPARISONS, + casts::CAST_LOSSLESS, + casts::CAST_POSSIBLE_TRUNCATION, + casts::CAST_POSSIBLE_WRAP, + casts::CAST_PRECISION_LOSS, + casts::CAST_PTR_ALIGNMENT, + casts::CAST_REF_TO_MUT, + casts::CAST_SIGN_LOSS, + casts::CHAR_LIT_AS_U8, + casts::FN_TO_NUMERIC_CAST, + casts::FN_TO_NUMERIC_CAST_WITH_TRUNCATION, + casts::PTR_AS_PTR, + casts::UNNECESSARY_CAST, + checked_conversions::CHECKED_CONVERSIONS, + cognitive_complexity::COGNITIVE_COMPLEXITY, + collapsible_if::COLLAPSIBLE_ELSE_IF, + collapsible_if::COLLAPSIBLE_IF, + collapsible_match::COLLAPSIBLE_MATCH, + comparison_chain::COMPARISON_CHAIN, + copies::BRANCHES_SHARING_CODE, + copies::IFS_SAME_COND, + copies::IF_SAME_THEN_ELSE, + copies::SAME_FUNCTIONS_IN_IF_CONDITION, + copy_iterator::COPY_ITERATOR, + create_dir::CREATE_DIR, + dbg_macro::DBG_MACRO, + default::DEFAULT_TRAIT_ACCESS, + default::FIELD_REASSIGN_WITH_DEFAULT, + default_numeric_fallback::DEFAULT_NUMERIC_FALLBACK, + dereference::EXPLICIT_DEREF_METHODS, + derive::DERIVE_HASH_XOR_EQ, + derive::DERIVE_ORD_XOR_PARTIAL_ORD, + derive::EXPL_IMPL_CLONE_ON_COPY, + derive::UNSAFE_DERIVE_DESERIALIZE, + disallowed_method::DISALLOWED_METHOD, + doc::DOC_MARKDOWN, + doc::MISSING_ERRORS_DOC, + doc::MISSING_PANICS_DOC, + doc::MISSING_SAFETY_DOC, + doc::NEEDLESS_DOCTEST_MAIN, + double_comparison::DOUBLE_COMPARISONS, + double_parens::DOUBLE_PARENS, + drop_forget_ref::DROP_COPY, + drop_forget_ref::DROP_REF, + drop_forget_ref::FORGET_COPY, + drop_forget_ref::FORGET_REF, + duration_subsec::DURATION_SUBSEC, + else_if_without_else::ELSE_IF_WITHOUT_ELSE, + empty_enum::EMPTY_ENUM, + entry::MAP_ENTRY, + enum_clike::ENUM_CLIKE_UNPORTABLE_VARIANT, + enum_variants::ENUM_VARIANT_NAMES, + enum_variants::MODULE_INCEPTION, + enum_variants::MODULE_NAME_REPETITIONS, + enum_variants::PUB_ENUM_VARIANT_NAMES, + eq_op::EQ_OP, + eq_op::OP_REF, + erasing_op::ERASING_OP, + escape::BOXED_LOCAL, + eta_reduction::REDUNDANT_CLOSURE, + eta_reduction::REDUNDANT_CLOSURE_FOR_METHOD_CALLS, + eval_order_dependence::DIVERGING_SUB_EXPRESSION, + eval_order_dependence::EVAL_ORDER_DEPENDENCE, + excessive_bools::FN_PARAMS_EXCESSIVE_BOOLS, + excessive_bools::STRUCT_EXCESSIVE_BOOLS, + exhaustive_items::EXHAUSTIVE_ENUMS, + exhaustive_items::EXHAUSTIVE_STRUCTS, + exit::EXIT, + explicit_write::EXPLICIT_WRITE, + fallible_impl_from::FALLIBLE_IMPL_FROM, + float_equality_without_abs::FLOAT_EQUALITY_WITHOUT_ABS, + float_literal::EXCESSIVE_PRECISION, + float_literal::LOSSY_FLOAT_LITERAL, + floating_point_arithmetic::IMPRECISE_FLOPS, + floating_point_arithmetic::SUBOPTIMAL_FLOPS, + format::USELESS_FORMAT, + formatting::POSSIBLE_MISSING_COMMA, + formatting::SUSPICIOUS_ASSIGNMENT_FORMATTING, + formatting::SUSPICIOUS_ELSE_FORMATTING, + formatting::SUSPICIOUS_UNARY_OP_FORMATTING, + from_over_into::FROM_OVER_INTO, + from_str_radix_10::FROM_STR_RADIX_10, + functions::DOUBLE_MUST_USE, + functions::MUST_USE_CANDIDATE, + functions::MUST_USE_UNIT, + functions::NOT_UNSAFE_PTR_ARG_DEREF, + functions::RESULT_UNIT_ERR, + functions::TOO_MANY_ARGUMENTS, + functions::TOO_MANY_LINES, + future_not_send::FUTURE_NOT_SEND, + get_last_with_len::GET_LAST_WITH_LEN, + identity_op::IDENTITY_OP, + if_let_mutex::IF_LET_MUTEX, + if_let_some_result::IF_LET_SOME_RESULT, + if_not_else::IF_NOT_ELSE, + if_then_some_else_none::IF_THEN_SOME_ELSE_NONE, + implicit_hasher::IMPLICIT_HASHER, + implicit_return::IMPLICIT_RETURN, + implicit_saturating_sub::IMPLICIT_SATURATING_SUB, + inconsistent_struct_constructor::INCONSISTENT_STRUCT_CONSTRUCTOR, + indexing_slicing::INDEXING_SLICING, + indexing_slicing::OUT_OF_BOUNDS_INDEXING, + infinite_iter::INFINITE_ITER, + infinite_iter::MAYBE_INFINITE_ITER, + inherent_impl::MULTIPLE_INHERENT_IMPL, + inherent_to_string::INHERENT_TO_STRING, + inherent_to_string::INHERENT_TO_STRING_SHADOW_DISPLAY, + inline_fn_without_body::INLINE_FN_WITHOUT_BODY, + int_plus_one::INT_PLUS_ONE, + integer_division::INTEGER_DIVISION, + invalid_upcast_comparisons::INVALID_UPCAST_COMPARISONS, + items_after_statements::ITEMS_AFTER_STATEMENTS, + large_const_arrays::LARGE_CONST_ARRAYS, + large_enum_variant::LARGE_ENUM_VARIANT, + large_stack_arrays::LARGE_STACK_ARRAYS, + len_zero::COMPARISON_TO_EMPTY, + len_zero::LEN_WITHOUT_IS_EMPTY, + len_zero::LEN_ZERO, + let_if_seq::USELESS_LET_IF_SEQ, + let_underscore::LET_UNDERSCORE_DROP, + let_underscore::LET_UNDERSCORE_LOCK, + let_underscore::LET_UNDERSCORE_MUST_USE, + lifetimes::EXTRA_UNUSED_LIFETIMES, + lifetimes::NEEDLESS_LIFETIMES, + literal_representation::DECIMAL_LITERAL_REPRESENTATION, + literal_representation::INCONSISTENT_DIGIT_GROUPING, + literal_representation::LARGE_DIGIT_GROUPS, + literal_representation::MISTYPED_LITERAL_SUFFIXES, + literal_representation::UNREADABLE_LITERAL, + literal_representation::UNUSUAL_BYTE_GROUPINGS, + loops::EMPTY_LOOP, + loops::EXPLICIT_COUNTER_LOOP, + loops::EXPLICIT_INTO_ITER_LOOP, + loops::EXPLICIT_ITER_LOOP, + loops::FOR_KV_MAP, + loops::FOR_LOOPS_OVER_FALLIBLES, + loops::ITER_NEXT_LOOP, + loops::MANUAL_FLATTEN, + loops::MANUAL_MEMCPY, + loops::MUT_RANGE_BOUND, + loops::NEEDLESS_COLLECT, + loops::NEEDLESS_RANGE_LOOP, + loops::NEVER_LOOP, + loops::SAME_ITEM_PUSH, + loops::SINGLE_ELEMENT_LOOP, + loops::WHILE_IMMUTABLE_CONDITION, + loops::WHILE_LET_LOOP, + loops::WHILE_LET_ON_ITERATOR, + macro_use::MACRO_USE_IMPORTS, + main_recursion::MAIN_RECURSION, + manual_async_fn::MANUAL_ASYNC_FN, + manual_map::MANUAL_MAP, + manual_non_exhaustive::MANUAL_NON_EXHAUSTIVE, + manual_ok_or::MANUAL_OK_OR, + manual_strip::MANUAL_STRIP, + manual_unwrap_or::MANUAL_UNWRAP_OR, + map_clone::MAP_CLONE, + map_err_ignore::MAP_ERR_IGNORE, + map_identity::MAP_IDENTITY, + map_unit_fn::OPTION_MAP_UNIT_FN, + map_unit_fn::RESULT_MAP_UNIT_FN, + match_on_vec_items::MATCH_ON_VEC_ITEMS, + matches::INFALLIBLE_DESTRUCTURING_MATCH, + matches::MATCH_AS_REF, + matches::MATCH_BOOL, + matches::MATCH_LIKE_MATCHES_MACRO, + matches::MATCH_OVERLAPPING_ARM, + matches::MATCH_REF_PATS, + matches::MATCH_SAME_ARMS, + matches::MATCH_SINGLE_BINDING, + matches::MATCH_WILDCARD_FOR_SINGLE_VARIANTS, + matches::MATCH_WILD_ERR_ARM, + matches::REDUNDANT_PATTERN_MATCHING, + matches::REST_PAT_IN_FULLY_BOUND_STRUCTS, + matches::SINGLE_MATCH, + matches::SINGLE_MATCH_ELSE, + matches::WILDCARD_ENUM_MATCH_ARM, + matches::WILDCARD_IN_OR_PATTERNS, + mem_discriminant::MEM_DISCRIMINANT_NON_ENUM, + mem_forget::MEM_FORGET, + mem_replace::MEM_REPLACE_OPTION_WITH_NONE, + mem_replace::MEM_REPLACE_WITH_DEFAULT, + mem_replace::MEM_REPLACE_WITH_UNINIT, + methods::BIND_INSTEAD_OF_MAP, + methods::BYTES_NTH, + methods::CHARS_LAST_CMP, + methods::CHARS_NEXT_CMP, + methods::CLONE_DOUBLE_REF, + methods::CLONE_ON_COPY, + methods::CLONE_ON_REF_PTR, + methods::EXPECT_FUN_CALL, + methods::EXPECT_USED, + methods::FILETYPE_IS_FILE, + methods::FILTER_MAP, + methods::FILTER_MAP_IDENTITY, + methods::FILTER_MAP_NEXT, + methods::FILTER_NEXT, + methods::FLAT_MAP_IDENTITY, + methods::FROM_ITER_INSTEAD_OF_COLLECT, + methods::GET_UNWRAP, + methods::IMPLICIT_CLONE, + methods::INEFFICIENT_TO_STRING, + methods::INSPECT_FOR_EACH, + methods::INTO_ITER_ON_REF, + methods::ITERATOR_STEP_BY_ZERO, + methods::ITER_CLONED_COLLECT, + methods::ITER_COUNT, + methods::ITER_NEXT_SLICE, + methods::ITER_NTH, + methods::ITER_NTH_ZERO, + methods::ITER_SKIP_NEXT, + methods::MANUAL_FILTER_MAP, + methods::MANUAL_FIND_MAP, + methods::MANUAL_SATURATING_ARITHMETIC, + methods::MAP_COLLECT_RESULT_UNIT, + methods::MAP_FLATTEN, + methods::MAP_UNWRAP_OR, + methods::NEW_RET_NO_SELF, + methods::OK_EXPECT, + methods::OPTION_AS_REF_DEREF, + methods::OPTION_FILTER_MAP, + methods::OPTION_MAP_OR_NONE, + methods::OR_FUN_CALL, + methods::RESULT_MAP_OR_INTO_OPTION, + methods::SEARCH_IS_SOME, + methods::SHOULD_IMPLEMENT_TRAIT, + methods::SINGLE_CHAR_ADD_STR, + methods::SINGLE_CHAR_PATTERN, + methods::SKIP_WHILE_NEXT, + methods::STRING_EXTEND_CHARS, + methods::SUSPICIOUS_MAP, + methods::UNINIT_ASSUMED_INIT, + methods::UNNECESSARY_FILTER_MAP, + methods::UNNECESSARY_FOLD, + methods::UNNECESSARY_LAZY_EVALUATIONS, + methods::UNWRAP_USED, + methods::USELESS_ASREF, + methods::WRONG_PUB_SELF_CONVENTION, + methods::WRONG_SELF_CONVENTION, + methods::ZST_OFFSET, + minmax::MIN_MAX, + misc::CMP_NAN, + misc::CMP_OWNED, + misc::FLOAT_CMP, + misc::FLOAT_CMP_CONST, + misc::MODULO_ONE, + misc::SHORT_CIRCUIT_STATEMENT, + misc::TOPLEVEL_REF_ARG, + misc::USED_UNDERSCORE_BINDING, + misc::ZERO_PTR, + misc_early::BUILTIN_TYPE_SHADOW, + misc_early::DOUBLE_NEG, + misc_early::DUPLICATE_UNDERSCORE_ARGUMENT, + misc_early::MIXED_CASE_HEX_LITERALS, + misc_early::REDUNDANT_PATTERN, + misc_early::UNNEEDED_FIELD_PATTERN, + misc_early::UNNEEDED_WILDCARD_PATTERN, + misc_early::UNSEPARATED_LITERAL_SUFFIX, + misc_early::ZERO_PREFIXED_LITERAL, + missing_const_for_fn::MISSING_CONST_FOR_FN, + missing_doc::MISSING_DOCS_IN_PRIVATE_ITEMS, + missing_inline::MISSING_INLINE_IN_PUBLIC_ITEMS, + modulo_arithmetic::MODULO_ARITHMETIC, + multiple_crate_versions::MULTIPLE_CRATE_VERSIONS, + mut_key::MUTABLE_KEY_TYPE, + mut_mut::MUT_MUT, + mut_mutex_lock::MUT_MUTEX_LOCK, + mut_reference::UNNECESSARY_MUT_PASSED, + mutable_debug_assertion::DEBUG_ASSERT_WITH_MUT_CALL, + mutex_atomic::MUTEX_ATOMIC, + mutex_atomic::MUTEX_INTEGER, + needless_arbitrary_self_type::NEEDLESS_ARBITRARY_SELF_TYPE, + needless_bool::BOOL_COMPARISON, + needless_bool::NEEDLESS_BOOL, + needless_borrow::NEEDLESS_BORROW, + needless_borrowed_ref::NEEDLESS_BORROWED_REFERENCE, + needless_continue::NEEDLESS_CONTINUE, + needless_for_each::NEEDLESS_FOR_EACH, + needless_pass_by_value::NEEDLESS_PASS_BY_VALUE, + needless_question_mark::NEEDLESS_QUESTION_MARK, + needless_update::NEEDLESS_UPDATE, + neg_cmp_op_on_partial_ord::NEG_CMP_OP_ON_PARTIAL_ORD, + neg_multiply::NEG_MULTIPLY, + new_without_default::NEW_WITHOUT_DEFAULT, + no_effect::NO_EFFECT, + no_effect::UNNECESSARY_OPERATION, + non_copy_const::BORROW_INTERIOR_MUTABLE_CONST, + non_copy_const::DECLARE_INTERIOR_MUTABLE_CONST, + non_expressive_names::JUST_UNDERSCORES_AND_DIGITS, + non_expressive_names::MANY_SINGLE_CHAR_NAMES, + non_expressive_names::SIMILAR_NAMES, + non_octal_unix_permissions::NON_OCTAL_UNIX_PERMISSIONS, + open_options::NONSENSICAL_OPEN_OPTIONS, + option_env_unwrap::OPTION_ENV_UNWRAP, + option_if_let_else::OPTION_IF_LET_ELSE, + overflow_check_conditional::OVERFLOW_CHECK_CONDITIONAL, + panic_in_result_fn::PANIC_IN_RESULT_FN, + panic_unimplemented::PANIC, + panic_unimplemented::TODO, + panic_unimplemented::UNIMPLEMENTED, + panic_unimplemented::UNREACHABLE, + partialeq_ne_impl::PARTIALEQ_NE_IMPL, + pass_by_ref_or_value::LARGE_TYPES_PASSED_BY_VALUE, + pass_by_ref_or_value::TRIVIALLY_COPY_PASS_BY_REF, + path_buf_push_overwrite::PATH_BUF_PUSH_OVERWRITE, + pattern_type_mismatch::PATTERN_TYPE_MISMATCH, + precedence::PRECEDENCE, + ptr::CMP_NULL, + ptr::MUT_FROM_REF, + ptr::PTR_ARG, + ptr_eq::PTR_EQ, + ptr_offset_with_cast::PTR_OFFSET_WITH_CAST, + question_mark::QUESTION_MARK, + ranges::MANUAL_RANGE_CONTAINS, + ranges::RANGE_MINUS_ONE, + ranges::RANGE_PLUS_ONE, + ranges::RANGE_ZIP_WITH_LEN, + ranges::REVERSED_EMPTY_RANGES, + redundant_clone::REDUNDANT_CLONE, + redundant_closure_call::REDUNDANT_CLOSURE_CALL, + redundant_else::REDUNDANT_ELSE, + redundant_field_names::REDUNDANT_FIELD_NAMES, + redundant_pub_crate::REDUNDANT_PUB_CRATE, + redundant_slicing::REDUNDANT_SLICING, + redundant_static_lifetimes::REDUNDANT_STATIC_LIFETIMES, + ref_option_ref::REF_OPTION_REF, + reference::DEREF_ADDROF, + reference::REF_IN_DEREF, + regex::INVALID_REGEX, + regex::TRIVIAL_REGEX, + repeat_once::REPEAT_ONCE, + returns::LET_AND_RETURN, + returns::NEEDLESS_RETURN, + self_assignment::SELF_ASSIGNMENT, + semicolon_if_nothing_returned::SEMICOLON_IF_NOTHING_RETURNED, + serde_api::SERDE_API_MISUSE, + shadow::SHADOW_REUSE, + shadow::SHADOW_SAME, + shadow::SHADOW_UNRELATED, + single_component_path_imports::SINGLE_COMPONENT_PATH_IMPORTS, + size_of_in_element_count::SIZE_OF_IN_ELEMENT_COUNT, + slow_vector_initialization::SLOW_VECTOR_INITIALIZATION, + stable_sort_primitive::STABLE_SORT_PRIMITIVE, + strings::STRING_ADD, + strings::STRING_ADD_ASSIGN, + strings::STRING_FROM_UTF8_AS_BYTES, + strings::STRING_LIT_AS_BYTES, + strings::STRING_TO_STRING, + strings::STR_TO_STRING, + suspicious_operation_groupings::SUSPICIOUS_OPERATION_GROUPINGS, + suspicious_trait_impl::SUSPICIOUS_ARITHMETIC_IMPL, + suspicious_trait_impl::SUSPICIOUS_OP_ASSIGN_IMPL, + swap::ALMOST_SWAPPED, + swap::MANUAL_SWAP, + tabs_in_doc_comments::TABS_IN_DOC_COMMENTS, + temporary_assignment::TEMPORARY_ASSIGNMENT, + to_digit_is_some::TO_DIGIT_IS_SOME, + to_string_in_display::TO_STRING_IN_DISPLAY, + trait_bounds::TRAIT_DUPLICATION_IN_BOUNDS, + trait_bounds::TYPE_REPETITION_IN_BOUNDS, + transmute::CROSSPOINTER_TRANSMUTE, + transmute::TRANSMUTES_EXPRESSIBLE_AS_PTR_CASTS, + transmute::TRANSMUTE_BYTES_TO_STR, + transmute::TRANSMUTE_FLOAT_TO_INT, + transmute::TRANSMUTE_INT_TO_BOOL, + transmute::TRANSMUTE_INT_TO_CHAR, + transmute::TRANSMUTE_INT_TO_FLOAT, + transmute::TRANSMUTE_PTR_TO_PTR, + transmute::TRANSMUTE_PTR_TO_REF, + transmute::UNSOUND_COLLECTION_TRANSMUTE, + transmute::USELESS_TRANSMUTE, + transmute::WRONG_TRANSMUTE, + transmuting_null::TRANSMUTING_NULL, + try_err::TRY_ERR, + types::BORROWED_BOX, + types::BOX_VEC, + types::LINKEDLIST, + types::OPTION_OPTION, + types::RC_BUFFER, + types::REDUNDANT_ALLOCATION, + types::TYPE_COMPLEXITY, + types::VEC_BOX, + undropped_manually_drops::UNDROPPED_MANUALLY_DROPS, + unicode::INVISIBLE_CHARACTERS, + unicode::NON_ASCII_LITERAL, + unicode::UNICODE_NOT_NFC, + unit_return_expecting_ord::UNIT_RETURN_EXPECTING_ORD, + unit_types::LET_UNIT_VALUE, + unit_types::UNIT_ARG, + unit_types::UNIT_CMP, + unnamed_address::FN_ADDRESS_COMPARISONS, + unnamed_address::VTABLE_ADDRESS_COMPARISONS, + unnecessary_sort_by::UNNECESSARY_SORT_BY, + unnecessary_wraps::UNNECESSARY_WRAPS, + unnested_or_patterns::UNNESTED_OR_PATTERNS, + unsafe_removed_from_name::UNSAFE_REMOVED_FROM_NAME, + unused_io_amount::UNUSED_IO_AMOUNT, + unused_self::UNUSED_SELF, + unused_unit::UNUSED_UNIT, + unwrap::PANICKING_UNWRAP, + unwrap::UNNECESSARY_UNWRAP, + unwrap_in_result::UNWRAP_IN_RESULT, + upper_case_acronyms::UPPER_CASE_ACRONYMS, + use_self::USE_SELF, + useless_conversion::USELESS_CONVERSION, + vec::USELESS_VEC, + vec_init_then_push::VEC_INIT_THEN_PUSH, + vec_resize_to_zero::VEC_RESIZE_TO_ZERO, + verbose_file_reads::VERBOSE_FILE_READS, + wildcard_dependencies::WILDCARD_DEPENDENCIES, + wildcard_imports::ENUM_GLOB_USE, + wildcard_imports::WILDCARD_IMPORTS, + write::PRINTLN_EMPTY_STRING, + write::PRINT_LITERAL, + write::PRINT_STDERR, + write::PRINT_STDOUT, + write::PRINT_WITH_NEWLINE, + write::USE_DEBUG, + write::WRITELN_EMPTY_STRING, + write::WRITE_LITERAL, + write::WRITE_WITH_NEWLINE, + zero_div_zero::ZERO_DIVIDED_BY_ZERO, + zero_sized_map_values::ZERO_SIZED_MAP_VALUES, ]); // end register lints, do not remove this comment, it’s used in `update_lints` @@ -1295,792 +1295,792 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf: store.register_late_pass(move || box if_then_some_else_none::IfThenSomeElseNone::new(msrv)); store.register_group(true, "clippy::restriction", Some("clippy_restriction"), vec![ - LintId::of(&arithmetic::FLOAT_ARITHMETIC), - LintId::of(&arithmetic::INTEGER_ARITHMETIC), - LintId::of(&as_conversions::AS_CONVERSIONS), - LintId::of(&asm_syntax::INLINE_ASM_X86_ATT_SYNTAX), - LintId::of(&asm_syntax::INLINE_ASM_X86_INTEL_SYNTAX), - LintId::of(&create_dir::CREATE_DIR), - LintId::of(&dbg_macro::DBG_MACRO), - LintId::of(&default_numeric_fallback::DEFAULT_NUMERIC_FALLBACK), - LintId::of(&else_if_without_else::ELSE_IF_WITHOUT_ELSE), - LintId::of(&exhaustive_items::EXHAUSTIVE_ENUMS), - LintId::of(&exhaustive_items::EXHAUSTIVE_STRUCTS), - LintId::of(&exit::EXIT), - LintId::of(&float_literal::LOSSY_FLOAT_LITERAL), - LintId::of(&if_then_some_else_none::IF_THEN_SOME_ELSE_NONE), - LintId::of(&implicit_return::IMPLICIT_RETURN), - LintId::of(&indexing_slicing::INDEXING_SLICING), - LintId::of(&inherent_impl::MULTIPLE_INHERENT_IMPL), - LintId::of(&integer_division::INTEGER_DIVISION), - LintId::of(&let_underscore::LET_UNDERSCORE_MUST_USE), - LintId::of(&literal_representation::DECIMAL_LITERAL_REPRESENTATION), - LintId::of(&map_err_ignore::MAP_ERR_IGNORE), - LintId::of(&matches::REST_PAT_IN_FULLY_BOUND_STRUCTS), - LintId::of(&matches::WILDCARD_ENUM_MATCH_ARM), - LintId::of(&mem_forget::MEM_FORGET), - LintId::of(&methods::CLONE_ON_REF_PTR), - LintId::of(&methods::EXPECT_USED), - LintId::of(&methods::FILETYPE_IS_FILE), - LintId::of(&methods::GET_UNWRAP), - LintId::of(&methods::UNWRAP_USED), - LintId::of(&methods::WRONG_PUB_SELF_CONVENTION), - LintId::of(&misc::FLOAT_CMP_CONST), - LintId::of(&misc_early::UNNEEDED_FIELD_PATTERN), - LintId::of(&missing_doc::MISSING_DOCS_IN_PRIVATE_ITEMS), - LintId::of(&missing_inline::MISSING_INLINE_IN_PUBLIC_ITEMS), - LintId::of(&modulo_arithmetic::MODULO_ARITHMETIC), - LintId::of(&panic_in_result_fn::PANIC_IN_RESULT_FN), - LintId::of(&panic_unimplemented::PANIC), - LintId::of(&panic_unimplemented::TODO), - LintId::of(&panic_unimplemented::UNIMPLEMENTED), - LintId::of(&panic_unimplemented::UNREACHABLE), - LintId::of(&pattern_type_mismatch::PATTERN_TYPE_MISMATCH), - LintId::of(&semicolon_if_nothing_returned::SEMICOLON_IF_NOTHING_RETURNED), - LintId::of(&shadow::SHADOW_REUSE), - LintId::of(&shadow::SHADOW_SAME), - LintId::of(&strings::STRING_ADD), - LintId::of(&strings::STRING_TO_STRING), - LintId::of(&strings::STR_TO_STRING), - LintId::of(&types::RC_BUFFER), - LintId::of(&unwrap_in_result::UNWRAP_IN_RESULT), - LintId::of(&verbose_file_reads::VERBOSE_FILE_READS), - LintId::of(&write::PRINT_STDERR), - LintId::of(&write::PRINT_STDOUT), - LintId::of(&write::USE_DEBUG), + LintId::of(arithmetic::FLOAT_ARITHMETIC), + LintId::of(arithmetic::INTEGER_ARITHMETIC), + LintId::of(as_conversions::AS_CONVERSIONS), + LintId::of(asm_syntax::INLINE_ASM_X86_ATT_SYNTAX), + LintId::of(asm_syntax::INLINE_ASM_X86_INTEL_SYNTAX), + LintId::of(create_dir::CREATE_DIR), + LintId::of(dbg_macro::DBG_MACRO), + LintId::of(default_numeric_fallback::DEFAULT_NUMERIC_FALLBACK), + LintId::of(else_if_without_else::ELSE_IF_WITHOUT_ELSE), + LintId::of(exhaustive_items::EXHAUSTIVE_ENUMS), + LintId::of(exhaustive_items::EXHAUSTIVE_STRUCTS), + LintId::of(exit::EXIT), + LintId::of(float_literal::LOSSY_FLOAT_LITERAL), + LintId::of(if_then_some_else_none::IF_THEN_SOME_ELSE_NONE), + LintId::of(implicit_return::IMPLICIT_RETURN), + LintId::of(indexing_slicing::INDEXING_SLICING), + LintId::of(inherent_impl::MULTIPLE_INHERENT_IMPL), + LintId::of(integer_division::INTEGER_DIVISION), + LintId::of(let_underscore::LET_UNDERSCORE_MUST_USE), + LintId::of(literal_representation::DECIMAL_LITERAL_REPRESENTATION), + LintId::of(map_err_ignore::MAP_ERR_IGNORE), + LintId::of(matches::REST_PAT_IN_FULLY_BOUND_STRUCTS), + LintId::of(matches::WILDCARD_ENUM_MATCH_ARM), + LintId::of(mem_forget::MEM_FORGET), + LintId::of(methods::CLONE_ON_REF_PTR), + LintId::of(methods::EXPECT_USED), + LintId::of(methods::FILETYPE_IS_FILE), + LintId::of(methods::GET_UNWRAP), + LintId::of(methods::UNWRAP_USED), + LintId::of(methods::WRONG_PUB_SELF_CONVENTION), + LintId::of(misc::FLOAT_CMP_CONST), + LintId::of(misc_early::UNNEEDED_FIELD_PATTERN), + LintId::of(missing_doc::MISSING_DOCS_IN_PRIVATE_ITEMS), + LintId::of(missing_inline::MISSING_INLINE_IN_PUBLIC_ITEMS), + LintId::of(modulo_arithmetic::MODULO_ARITHMETIC), + LintId::of(panic_in_result_fn::PANIC_IN_RESULT_FN), + LintId::of(panic_unimplemented::PANIC), + LintId::of(panic_unimplemented::TODO), + LintId::of(panic_unimplemented::UNIMPLEMENTED), + LintId::of(panic_unimplemented::UNREACHABLE), + LintId::of(pattern_type_mismatch::PATTERN_TYPE_MISMATCH), + LintId::of(semicolon_if_nothing_returned::SEMICOLON_IF_NOTHING_RETURNED), + LintId::of(shadow::SHADOW_REUSE), + LintId::of(shadow::SHADOW_SAME), + LintId::of(strings::STRING_ADD), + LintId::of(strings::STRING_TO_STRING), + LintId::of(strings::STR_TO_STRING), + LintId::of(types::RC_BUFFER), + LintId::of(unwrap_in_result::UNWRAP_IN_RESULT), + LintId::of(verbose_file_reads::VERBOSE_FILE_READS), + LintId::of(write::PRINT_STDERR), + LintId::of(write::PRINT_STDOUT), + LintId::of(write::USE_DEBUG), ]); store.register_group(true, "clippy::pedantic", Some("clippy_pedantic"), vec![ - LintId::of(&attrs::INLINE_ALWAYS), - LintId::of(&await_holding_invalid::AWAIT_HOLDING_LOCK), - LintId::of(&await_holding_invalid::AWAIT_HOLDING_REFCELL_REF), - LintId::of(&bit_mask::VERBOSE_BIT_MASK), - LintId::of(&bytecount::NAIVE_BYTECOUNT), - LintId::of(&case_sensitive_file_extension_comparisons::CASE_SENSITIVE_FILE_EXTENSION_COMPARISONS), - LintId::of(&casts::CAST_LOSSLESS), - LintId::of(&casts::CAST_POSSIBLE_TRUNCATION), - LintId::of(&casts::CAST_POSSIBLE_WRAP), - LintId::of(&casts::CAST_PRECISION_LOSS), - LintId::of(&casts::CAST_PTR_ALIGNMENT), - LintId::of(&casts::CAST_SIGN_LOSS), - LintId::of(&casts::PTR_AS_PTR), - LintId::of(&checked_conversions::CHECKED_CONVERSIONS), - LintId::of(&copies::SAME_FUNCTIONS_IN_IF_CONDITION), - LintId::of(©_iterator::COPY_ITERATOR), - LintId::of(&default::DEFAULT_TRAIT_ACCESS), - LintId::of(&dereference::EXPLICIT_DEREF_METHODS), - LintId::of(&derive::EXPL_IMPL_CLONE_ON_COPY), - LintId::of(&derive::UNSAFE_DERIVE_DESERIALIZE), - LintId::of(&doc::DOC_MARKDOWN), - LintId::of(&doc::MISSING_ERRORS_DOC), - LintId::of(&doc::MISSING_PANICS_DOC), - LintId::of(&empty_enum::EMPTY_ENUM), - LintId::of(&enum_variants::MODULE_NAME_REPETITIONS), - LintId::of(&enum_variants::PUB_ENUM_VARIANT_NAMES), - LintId::of(&eta_reduction::REDUNDANT_CLOSURE_FOR_METHOD_CALLS), - LintId::of(&excessive_bools::FN_PARAMS_EXCESSIVE_BOOLS), - LintId::of(&excessive_bools::STRUCT_EXCESSIVE_BOOLS), - LintId::of(&functions::MUST_USE_CANDIDATE), - LintId::of(&functions::TOO_MANY_LINES), - LintId::of(&if_not_else::IF_NOT_ELSE), - LintId::of(&implicit_hasher::IMPLICIT_HASHER), - LintId::of(&implicit_saturating_sub::IMPLICIT_SATURATING_SUB), - LintId::of(&infinite_iter::MAYBE_INFINITE_ITER), - LintId::of(&invalid_upcast_comparisons::INVALID_UPCAST_COMPARISONS), - LintId::of(&items_after_statements::ITEMS_AFTER_STATEMENTS), - LintId::of(&large_stack_arrays::LARGE_STACK_ARRAYS), - LintId::of(&let_underscore::LET_UNDERSCORE_DROP), - LintId::of(&literal_representation::LARGE_DIGIT_GROUPS), - LintId::of(&literal_representation::UNREADABLE_LITERAL), - LintId::of(&loops::EXPLICIT_INTO_ITER_LOOP), - LintId::of(&loops::EXPLICIT_ITER_LOOP), - LintId::of(¯o_use::MACRO_USE_IMPORTS), - LintId::of(&manual_ok_or::MANUAL_OK_OR), - LintId::of(&match_on_vec_items::MATCH_ON_VEC_ITEMS), - LintId::of(&matches::MATCH_BOOL), - LintId::of(&matches::MATCH_SAME_ARMS), - LintId::of(&matches::MATCH_WILDCARD_FOR_SINGLE_VARIANTS), - LintId::of(&matches::MATCH_WILD_ERR_ARM), - LintId::of(&matches::SINGLE_MATCH_ELSE), - LintId::of(&methods::FILTER_MAP), - LintId::of(&methods::FILTER_MAP_NEXT), - LintId::of(&methods::IMPLICIT_CLONE), - LintId::of(&methods::INEFFICIENT_TO_STRING), - LintId::of(&methods::MAP_FLATTEN), - LintId::of(&methods::MAP_UNWRAP_OR), - LintId::of(&misc::USED_UNDERSCORE_BINDING), - LintId::of(&misc_early::UNSEPARATED_LITERAL_SUFFIX), - LintId::of(&mut_mut::MUT_MUT), - LintId::of(&needless_continue::NEEDLESS_CONTINUE), - LintId::of(&needless_for_each::NEEDLESS_FOR_EACH), - LintId::of(&needless_pass_by_value::NEEDLESS_PASS_BY_VALUE), - LintId::of(&non_expressive_names::SIMILAR_NAMES), - LintId::of(&option_if_let_else::OPTION_IF_LET_ELSE), - LintId::of(&pass_by_ref_or_value::LARGE_TYPES_PASSED_BY_VALUE), - LintId::of(&pass_by_ref_or_value::TRIVIALLY_COPY_PASS_BY_REF), - LintId::of(&ranges::RANGE_MINUS_ONE), - LintId::of(&ranges::RANGE_PLUS_ONE), - LintId::of(&redundant_else::REDUNDANT_ELSE), - LintId::of(&ref_option_ref::REF_OPTION_REF), - LintId::of(&shadow::SHADOW_UNRELATED), - LintId::of(&strings::STRING_ADD_ASSIGN), - LintId::of(&trait_bounds::TRAIT_DUPLICATION_IN_BOUNDS), - LintId::of(&trait_bounds::TYPE_REPETITION_IN_BOUNDS), - LintId::of(&types::LINKEDLIST), - LintId::of(&types::OPTION_OPTION), - LintId::of(&unicode::NON_ASCII_LITERAL), - LintId::of(&unicode::UNICODE_NOT_NFC), - LintId::of(&unit_types::LET_UNIT_VALUE), - LintId::of(&unnecessary_wraps::UNNECESSARY_WRAPS), - LintId::of(&unnested_or_patterns::UNNESTED_OR_PATTERNS), - LintId::of(&unused_self::UNUSED_SELF), - LintId::of(&wildcard_imports::ENUM_GLOB_USE), - LintId::of(&wildcard_imports::WILDCARD_IMPORTS), - LintId::of(&zero_sized_map_values::ZERO_SIZED_MAP_VALUES), + LintId::of(attrs::INLINE_ALWAYS), + LintId::of(await_holding_invalid::AWAIT_HOLDING_LOCK), + LintId::of(await_holding_invalid::AWAIT_HOLDING_REFCELL_REF), + LintId::of(bit_mask::VERBOSE_BIT_MASK), + LintId::of(bytecount::NAIVE_BYTECOUNT), + LintId::of(case_sensitive_file_extension_comparisons::CASE_SENSITIVE_FILE_EXTENSION_COMPARISONS), + LintId::of(casts::CAST_LOSSLESS), + LintId::of(casts::CAST_POSSIBLE_TRUNCATION), + LintId::of(casts::CAST_POSSIBLE_WRAP), + LintId::of(casts::CAST_PRECISION_LOSS), + LintId::of(casts::CAST_PTR_ALIGNMENT), + LintId::of(casts::CAST_SIGN_LOSS), + LintId::of(casts::PTR_AS_PTR), + LintId::of(checked_conversions::CHECKED_CONVERSIONS), + LintId::of(copies::SAME_FUNCTIONS_IN_IF_CONDITION), + LintId::of(copy_iterator::COPY_ITERATOR), + LintId::of(default::DEFAULT_TRAIT_ACCESS), + LintId::of(dereference::EXPLICIT_DEREF_METHODS), + LintId::of(derive::EXPL_IMPL_CLONE_ON_COPY), + LintId::of(derive::UNSAFE_DERIVE_DESERIALIZE), + LintId::of(doc::DOC_MARKDOWN), + LintId::of(doc::MISSING_ERRORS_DOC), + LintId::of(doc::MISSING_PANICS_DOC), + LintId::of(empty_enum::EMPTY_ENUM), + LintId::of(enum_variants::MODULE_NAME_REPETITIONS), + LintId::of(enum_variants::PUB_ENUM_VARIANT_NAMES), + LintId::of(eta_reduction::REDUNDANT_CLOSURE_FOR_METHOD_CALLS), + LintId::of(excessive_bools::FN_PARAMS_EXCESSIVE_BOOLS), + LintId::of(excessive_bools::STRUCT_EXCESSIVE_BOOLS), + LintId::of(functions::MUST_USE_CANDIDATE), + LintId::of(functions::TOO_MANY_LINES), + LintId::of(if_not_else::IF_NOT_ELSE), + LintId::of(implicit_hasher::IMPLICIT_HASHER), + LintId::of(implicit_saturating_sub::IMPLICIT_SATURATING_SUB), + LintId::of(infinite_iter::MAYBE_INFINITE_ITER), + LintId::of(invalid_upcast_comparisons::INVALID_UPCAST_COMPARISONS), + LintId::of(items_after_statements::ITEMS_AFTER_STATEMENTS), + LintId::of(large_stack_arrays::LARGE_STACK_ARRAYS), + LintId::of(let_underscore::LET_UNDERSCORE_DROP), + LintId::of(literal_representation::LARGE_DIGIT_GROUPS), + LintId::of(literal_representation::UNREADABLE_LITERAL), + LintId::of(loops::EXPLICIT_INTO_ITER_LOOP), + LintId::of(loops::EXPLICIT_ITER_LOOP), + LintId::of(macro_use::MACRO_USE_IMPORTS), + LintId::of(manual_ok_or::MANUAL_OK_OR), + LintId::of(match_on_vec_items::MATCH_ON_VEC_ITEMS), + LintId::of(matches::MATCH_BOOL), + LintId::of(matches::MATCH_SAME_ARMS), + LintId::of(matches::MATCH_WILDCARD_FOR_SINGLE_VARIANTS), + LintId::of(matches::MATCH_WILD_ERR_ARM), + LintId::of(matches::SINGLE_MATCH_ELSE), + LintId::of(methods::FILTER_MAP), + LintId::of(methods::FILTER_MAP_NEXT), + LintId::of(methods::IMPLICIT_CLONE), + LintId::of(methods::INEFFICIENT_TO_STRING), + LintId::of(methods::MAP_FLATTEN), + LintId::of(methods::MAP_UNWRAP_OR), + LintId::of(misc::USED_UNDERSCORE_BINDING), + LintId::of(misc_early::UNSEPARATED_LITERAL_SUFFIX), + LintId::of(mut_mut::MUT_MUT), + LintId::of(needless_continue::NEEDLESS_CONTINUE), + LintId::of(needless_for_each::NEEDLESS_FOR_EACH), + LintId::of(needless_pass_by_value::NEEDLESS_PASS_BY_VALUE), + LintId::of(non_expressive_names::SIMILAR_NAMES), + LintId::of(option_if_let_else::OPTION_IF_LET_ELSE), + LintId::of(pass_by_ref_or_value::LARGE_TYPES_PASSED_BY_VALUE), + LintId::of(pass_by_ref_or_value::TRIVIALLY_COPY_PASS_BY_REF), + LintId::of(ranges::RANGE_MINUS_ONE), + LintId::of(ranges::RANGE_PLUS_ONE), + LintId::of(redundant_else::REDUNDANT_ELSE), + LintId::of(ref_option_ref::REF_OPTION_REF), + LintId::of(shadow::SHADOW_UNRELATED), + LintId::of(strings::STRING_ADD_ASSIGN), + LintId::of(trait_bounds::TRAIT_DUPLICATION_IN_BOUNDS), + LintId::of(trait_bounds::TYPE_REPETITION_IN_BOUNDS), + LintId::of(types::LINKEDLIST), + LintId::of(types::OPTION_OPTION), + LintId::of(unicode::NON_ASCII_LITERAL), + LintId::of(unicode::UNICODE_NOT_NFC), + LintId::of(unit_types::LET_UNIT_VALUE), + LintId::of(unnecessary_wraps::UNNECESSARY_WRAPS), + LintId::of(unnested_or_patterns::UNNESTED_OR_PATTERNS), + LintId::of(unused_self::UNUSED_SELF), + LintId::of(wildcard_imports::ENUM_GLOB_USE), + LintId::of(wildcard_imports::WILDCARD_IMPORTS), + LintId::of(zero_sized_map_values::ZERO_SIZED_MAP_VALUES), ]); #[cfg(feature = "internal-lints")] store.register_group(true, "clippy::internal", Some("clippy_internal"), vec![ - LintId::of(&utils::internal_lints::CLIPPY_LINTS_INTERNAL), - LintId::of(&utils::internal_lints::COLLAPSIBLE_SPAN_LINT_CALLS), - LintId::of(&utils::internal_lints::COMPILER_LINT_FUNCTIONS), - LintId::of(&utils::internal_lints::DEFAULT_LINT), - LintId::of(&utils::internal_lints::IF_CHAIN_STYLE), - LintId::of(&utils::internal_lints::INTERNING_DEFINED_SYMBOL), - LintId::of(&utils::internal_lints::INVALID_PATHS), - LintId::of(&utils::internal_lints::LINT_WITHOUT_LINT_PASS), - LintId::of(&utils::internal_lints::MATCH_TYPE_ON_DIAGNOSTIC_ITEM), - LintId::of(&utils::internal_lints::OUTER_EXPN_EXPN_DATA), - LintId::of(&utils::internal_lints::PRODUCE_ICE), - LintId::of(&utils::internal_lints::UNNECESSARY_SYMBOL_STR), + LintId::of(utils::internal_lints::CLIPPY_LINTS_INTERNAL), + LintId::of(utils::internal_lints::COLLAPSIBLE_SPAN_LINT_CALLS), + LintId::of(utils::internal_lints::COMPILER_LINT_FUNCTIONS), + LintId::of(utils::internal_lints::DEFAULT_LINT), + LintId::of(utils::internal_lints::IF_CHAIN_STYLE), + LintId::of(utils::internal_lints::INTERNING_DEFINED_SYMBOL), + LintId::of(utils::internal_lints::INVALID_PATHS), + LintId::of(utils::internal_lints::LINT_WITHOUT_LINT_PASS), + LintId::of(utils::internal_lints::MATCH_TYPE_ON_DIAGNOSTIC_ITEM), + LintId::of(utils::internal_lints::OUTER_EXPN_EXPN_DATA), + LintId::of(utils::internal_lints::PRODUCE_ICE), + LintId::of(utils::internal_lints::UNNECESSARY_SYMBOL_STR), ]); store.register_group(true, "clippy::all", Some("clippy"), vec![ - LintId::of(&absurd_extreme_comparisons::ABSURD_EXTREME_COMPARISONS), - LintId::of(&approx_const::APPROX_CONSTANT), - LintId::of(&assertions_on_constants::ASSERTIONS_ON_CONSTANTS), - LintId::of(&assign_ops::ASSIGN_OP_PATTERN), - LintId::of(&assign_ops::MISREFACTORED_ASSIGN_OP), - LintId::of(&async_yields_async::ASYNC_YIELDS_ASYNC), - LintId::of(&atomic_ordering::INVALID_ATOMIC_ORDERING), - LintId::of(&attrs::BLANKET_CLIPPY_RESTRICTION_LINTS), - LintId::of(&attrs::DEPRECATED_CFG_ATTR), - LintId::of(&attrs::DEPRECATED_SEMVER), - LintId::of(&attrs::MISMATCHED_TARGET_OS), - LintId::of(&attrs::USELESS_ATTRIBUTE), - LintId::of(&bit_mask::BAD_BIT_MASK), - LintId::of(&bit_mask::INEFFECTIVE_BIT_MASK), - LintId::of(&blacklisted_name::BLACKLISTED_NAME), - LintId::of(&blocks_in_if_conditions::BLOCKS_IN_IF_CONDITIONS), - LintId::of(&booleans::LOGIC_BUG), - LintId::of(&booleans::NONMINIMAL_BOOL), - LintId::of(&casts::CAST_REF_TO_MUT), - LintId::of(&casts::CHAR_LIT_AS_U8), - LintId::of(&casts::FN_TO_NUMERIC_CAST), - LintId::of(&casts::FN_TO_NUMERIC_CAST_WITH_TRUNCATION), - LintId::of(&casts::UNNECESSARY_CAST), - LintId::of(&collapsible_if::COLLAPSIBLE_ELSE_IF), - LintId::of(&collapsible_if::COLLAPSIBLE_IF), - LintId::of(&collapsible_match::COLLAPSIBLE_MATCH), - LintId::of(&comparison_chain::COMPARISON_CHAIN), - LintId::of(&copies::BRANCHES_SHARING_CODE), - LintId::of(&copies::IFS_SAME_COND), - LintId::of(&copies::IF_SAME_THEN_ELSE), - LintId::of(&default::FIELD_REASSIGN_WITH_DEFAULT), - LintId::of(&derive::DERIVE_HASH_XOR_EQ), - LintId::of(&derive::DERIVE_ORD_XOR_PARTIAL_ORD), - LintId::of(&doc::MISSING_SAFETY_DOC), - LintId::of(&doc::NEEDLESS_DOCTEST_MAIN), - LintId::of(&double_comparison::DOUBLE_COMPARISONS), - LintId::of(&double_parens::DOUBLE_PARENS), - LintId::of(&drop_forget_ref::DROP_COPY), - LintId::of(&drop_forget_ref::DROP_REF), - LintId::of(&drop_forget_ref::FORGET_COPY), - LintId::of(&drop_forget_ref::FORGET_REF), - LintId::of(&duration_subsec::DURATION_SUBSEC), - LintId::of(&entry::MAP_ENTRY), - LintId::of(&enum_clike::ENUM_CLIKE_UNPORTABLE_VARIANT), - LintId::of(&enum_variants::ENUM_VARIANT_NAMES), - LintId::of(&enum_variants::MODULE_INCEPTION), - LintId::of(&eq_op::EQ_OP), - LintId::of(&eq_op::OP_REF), - LintId::of(&erasing_op::ERASING_OP), - LintId::of(&escape::BOXED_LOCAL), - LintId::of(&eta_reduction::REDUNDANT_CLOSURE), - LintId::of(&eval_order_dependence::DIVERGING_SUB_EXPRESSION), - LintId::of(&eval_order_dependence::EVAL_ORDER_DEPENDENCE), - LintId::of(&explicit_write::EXPLICIT_WRITE), - LintId::of(&float_equality_without_abs::FLOAT_EQUALITY_WITHOUT_ABS), - LintId::of(&float_literal::EXCESSIVE_PRECISION), - LintId::of(&format::USELESS_FORMAT), - LintId::of(&formatting::POSSIBLE_MISSING_COMMA), - LintId::of(&formatting::SUSPICIOUS_ASSIGNMENT_FORMATTING), - LintId::of(&formatting::SUSPICIOUS_ELSE_FORMATTING), - LintId::of(&formatting::SUSPICIOUS_UNARY_OP_FORMATTING), - LintId::of(&from_over_into::FROM_OVER_INTO), - LintId::of(&from_str_radix_10::FROM_STR_RADIX_10), - LintId::of(&functions::DOUBLE_MUST_USE), - LintId::of(&functions::MUST_USE_UNIT), - LintId::of(&functions::NOT_UNSAFE_PTR_ARG_DEREF), - LintId::of(&functions::RESULT_UNIT_ERR), - LintId::of(&functions::TOO_MANY_ARGUMENTS), - LintId::of(&get_last_with_len::GET_LAST_WITH_LEN), - LintId::of(&identity_op::IDENTITY_OP), - LintId::of(&if_let_mutex::IF_LET_MUTEX), - LintId::of(&if_let_some_result::IF_LET_SOME_RESULT), - LintId::of(&inconsistent_struct_constructor::INCONSISTENT_STRUCT_CONSTRUCTOR), - LintId::of(&indexing_slicing::OUT_OF_BOUNDS_INDEXING), - LintId::of(&infinite_iter::INFINITE_ITER), - LintId::of(&inherent_to_string::INHERENT_TO_STRING), - LintId::of(&inherent_to_string::INHERENT_TO_STRING_SHADOW_DISPLAY), - LintId::of(&inline_fn_without_body::INLINE_FN_WITHOUT_BODY), - LintId::of(&int_plus_one::INT_PLUS_ONE), - LintId::of(&large_const_arrays::LARGE_CONST_ARRAYS), - LintId::of(&large_enum_variant::LARGE_ENUM_VARIANT), - LintId::of(&len_zero::COMPARISON_TO_EMPTY), - LintId::of(&len_zero::LEN_WITHOUT_IS_EMPTY), - LintId::of(&len_zero::LEN_ZERO), - LintId::of(&let_underscore::LET_UNDERSCORE_LOCK), - LintId::of(&lifetimes::EXTRA_UNUSED_LIFETIMES), - LintId::of(&lifetimes::NEEDLESS_LIFETIMES), - LintId::of(&literal_representation::INCONSISTENT_DIGIT_GROUPING), - LintId::of(&literal_representation::MISTYPED_LITERAL_SUFFIXES), - LintId::of(&literal_representation::UNUSUAL_BYTE_GROUPINGS), - LintId::of(&loops::EMPTY_LOOP), - LintId::of(&loops::EXPLICIT_COUNTER_LOOP), - LintId::of(&loops::FOR_KV_MAP), - LintId::of(&loops::FOR_LOOPS_OVER_FALLIBLES), - LintId::of(&loops::ITER_NEXT_LOOP), - LintId::of(&loops::MANUAL_FLATTEN), - LintId::of(&loops::MANUAL_MEMCPY), - LintId::of(&loops::MUT_RANGE_BOUND), - LintId::of(&loops::NEEDLESS_COLLECT), - LintId::of(&loops::NEEDLESS_RANGE_LOOP), - LintId::of(&loops::NEVER_LOOP), - LintId::of(&loops::SAME_ITEM_PUSH), - LintId::of(&loops::SINGLE_ELEMENT_LOOP), - LintId::of(&loops::WHILE_IMMUTABLE_CONDITION), - LintId::of(&loops::WHILE_LET_LOOP), - LintId::of(&loops::WHILE_LET_ON_ITERATOR), - LintId::of(&main_recursion::MAIN_RECURSION), - LintId::of(&manual_async_fn::MANUAL_ASYNC_FN), - LintId::of(&manual_map::MANUAL_MAP), - LintId::of(&manual_non_exhaustive::MANUAL_NON_EXHAUSTIVE), - LintId::of(&manual_strip::MANUAL_STRIP), - LintId::of(&manual_unwrap_or::MANUAL_UNWRAP_OR), - LintId::of(&map_clone::MAP_CLONE), - LintId::of(&map_identity::MAP_IDENTITY), - LintId::of(&map_unit_fn::OPTION_MAP_UNIT_FN), - LintId::of(&map_unit_fn::RESULT_MAP_UNIT_FN), - LintId::of(&matches::INFALLIBLE_DESTRUCTURING_MATCH), - LintId::of(&matches::MATCH_AS_REF), - LintId::of(&matches::MATCH_LIKE_MATCHES_MACRO), - LintId::of(&matches::MATCH_OVERLAPPING_ARM), - LintId::of(&matches::MATCH_REF_PATS), - LintId::of(&matches::MATCH_SINGLE_BINDING), - LintId::of(&matches::REDUNDANT_PATTERN_MATCHING), - LintId::of(&matches::SINGLE_MATCH), - LintId::of(&matches::WILDCARD_IN_OR_PATTERNS), - LintId::of(&mem_discriminant::MEM_DISCRIMINANT_NON_ENUM), - LintId::of(&mem_replace::MEM_REPLACE_OPTION_WITH_NONE), - LintId::of(&mem_replace::MEM_REPLACE_WITH_DEFAULT), - LintId::of(&mem_replace::MEM_REPLACE_WITH_UNINIT), - LintId::of(&methods::BIND_INSTEAD_OF_MAP), - LintId::of(&methods::BYTES_NTH), - LintId::of(&methods::CHARS_LAST_CMP), - LintId::of(&methods::CHARS_NEXT_CMP), - LintId::of(&methods::CLONE_DOUBLE_REF), - LintId::of(&methods::CLONE_ON_COPY), - LintId::of(&methods::EXPECT_FUN_CALL), - LintId::of(&methods::FILTER_MAP_IDENTITY), - LintId::of(&methods::FILTER_NEXT), - LintId::of(&methods::FLAT_MAP_IDENTITY), - LintId::of(&methods::FROM_ITER_INSTEAD_OF_COLLECT), - LintId::of(&methods::INSPECT_FOR_EACH), - LintId::of(&methods::INTO_ITER_ON_REF), - LintId::of(&methods::ITERATOR_STEP_BY_ZERO), - LintId::of(&methods::ITER_CLONED_COLLECT), - LintId::of(&methods::ITER_COUNT), - LintId::of(&methods::ITER_NEXT_SLICE), - LintId::of(&methods::ITER_NTH), - LintId::of(&methods::ITER_NTH_ZERO), - LintId::of(&methods::ITER_SKIP_NEXT), - LintId::of(&methods::MANUAL_FILTER_MAP), - LintId::of(&methods::MANUAL_FIND_MAP), - LintId::of(&methods::MANUAL_SATURATING_ARITHMETIC), - LintId::of(&methods::MAP_COLLECT_RESULT_UNIT), - LintId::of(&methods::NEW_RET_NO_SELF), - LintId::of(&methods::OK_EXPECT), - LintId::of(&methods::OPTION_AS_REF_DEREF), - LintId::of(&methods::OPTION_FILTER_MAP), - LintId::of(&methods::OPTION_MAP_OR_NONE), - LintId::of(&methods::OR_FUN_CALL), - LintId::of(&methods::RESULT_MAP_OR_INTO_OPTION), - LintId::of(&methods::SEARCH_IS_SOME), - LintId::of(&methods::SHOULD_IMPLEMENT_TRAIT), - LintId::of(&methods::SINGLE_CHAR_ADD_STR), - LintId::of(&methods::SINGLE_CHAR_PATTERN), - LintId::of(&methods::SKIP_WHILE_NEXT), - LintId::of(&methods::STRING_EXTEND_CHARS), - LintId::of(&methods::SUSPICIOUS_MAP), - LintId::of(&methods::UNINIT_ASSUMED_INIT), - LintId::of(&methods::UNNECESSARY_FILTER_MAP), - LintId::of(&methods::UNNECESSARY_FOLD), - LintId::of(&methods::UNNECESSARY_LAZY_EVALUATIONS), - LintId::of(&methods::USELESS_ASREF), - LintId::of(&methods::WRONG_SELF_CONVENTION), - LintId::of(&methods::ZST_OFFSET), - LintId::of(&minmax::MIN_MAX), - LintId::of(&misc::CMP_NAN), - LintId::of(&misc::CMP_OWNED), - LintId::of(&misc::FLOAT_CMP), - LintId::of(&misc::MODULO_ONE), - LintId::of(&misc::SHORT_CIRCUIT_STATEMENT), - LintId::of(&misc::TOPLEVEL_REF_ARG), - LintId::of(&misc::ZERO_PTR), - LintId::of(&misc_early::BUILTIN_TYPE_SHADOW), - LintId::of(&misc_early::DOUBLE_NEG), - LintId::of(&misc_early::DUPLICATE_UNDERSCORE_ARGUMENT), - LintId::of(&misc_early::MIXED_CASE_HEX_LITERALS), - LintId::of(&misc_early::REDUNDANT_PATTERN), - LintId::of(&misc_early::UNNEEDED_WILDCARD_PATTERN), - LintId::of(&misc_early::ZERO_PREFIXED_LITERAL), - LintId::of(&mut_key::MUTABLE_KEY_TYPE), - LintId::of(&mut_mutex_lock::MUT_MUTEX_LOCK), - LintId::of(&mut_reference::UNNECESSARY_MUT_PASSED), - LintId::of(&mutex_atomic::MUTEX_ATOMIC), - LintId::of(&needless_arbitrary_self_type::NEEDLESS_ARBITRARY_SELF_TYPE), - LintId::of(&needless_bool::BOOL_COMPARISON), - LintId::of(&needless_bool::NEEDLESS_BOOL), - LintId::of(&needless_borrowed_ref::NEEDLESS_BORROWED_REFERENCE), - LintId::of(&needless_question_mark::NEEDLESS_QUESTION_MARK), - LintId::of(&needless_update::NEEDLESS_UPDATE), - LintId::of(&neg_cmp_op_on_partial_ord::NEG_CMP_OP_ON_PARTIAL_ORD), - LintId::of(&neg_multiply::NEG_MULTIPLY), - LintId::of(&new_without_default::NEW_WITHOUT_DEFAULT), - LintId::of(&no_effect::NO_EFFECT), - LintId::of(&no_effect::UNNECESSARY_OPERATION), - LintId::of(&non_copy_const::BORROW_INTERIOR_MUTABLE_CONST), - LintId::of(&non_copy_const::DECLARE_INTERIOR_MUTABLE_CONST), - LintId::of(&non_expressive_names::JUST_UNDERSCORES_AND_DIGITS), - LintId::of(&non_expressive_names::MANY_SINGLE_CHAR_NAMES), - LintId::of(&non_octal_unix_permissions::NON_OCTAL_UNIX_PERMISSIONS), - LintId::of(&open_options::NONSENSICAL_OPEN_OPTIONS), - LintId::of(&option_env_unwrap::OPTION_ENV_UNWRAP), - LintId::of(&overflow_check_conditional::OVERFLOW_CHECK_CONDITIONAL), - LintId::of(&partialeq_ne_impl::PARTIALEQ_NE_IMPL), - LintId::of(&precedence::PRECEDENCE), - LintId::of(&ptr::CMP_NULL), - LintId::of(&ptr::MUT_FROM_REF), - LintId::of(&ptr::PTR_ARG), - LintId::of(&ptr_eq::PTR_EQ), - LintId::of(&ptr_offset_with_cast::PTR_OFFSET_WITH_CAST), - LintId::of(&question_mark::QUESTION_MARK), - LintId::of(&ranges::MANUAL_RANGE_CONTAINS), - LintId::of(&ranges::RANGE_ZIP_WITH_LEN), - LintId::of(&ranges::REVERSED_EMPTY_RANGES), - LintId::of(&redundant_clone::REDUNDANT_CLONE), - LintId::of(&redundant_closure_call::REDUNDANT_CLOSURE_CALL), - LintId::of(&redundant_field_names::REDUNDANT_FIELD_NAMES), - LintId::of(&redundant_slicing::REDUNDANT_SLICING), - LintId::of(&redundant_static_lifetimes::REDUNDANT_STATIC_LIFETIMES), - LintId::of(&reference::DEREF_ADDROF), - LintId::of(&reference::REF_IN_DEREF), - LintId::of(®ex::INVALID_REGEX), - LintId::of(&repeat_once::REPEAT_ONCE), - LintId::of(&returns::LET_AND_RETURN), - LintId::of(&returns::NEEDLESS_RETURN), - LintId::of(&self_assignment::SELF_ASSIGNMENT), - LintId::of(&serde_api::SERDE_API_MISUSE), - LintId::of(&single_component_path_imports::SINGLE_COMPONENT_PATH_IMPORTS), - LintId::of(&size_of_in_element_count::SIZE_OF_IN_ELEMENT_COUNT), - LintId::of(&slow_vector_initialization::SLOW_VECTOR_INITIALIZATION), - LintId::of(&stable_sort_primitive::STABLE_SORT_PRIMITIVE), - LintId::of(&strings::STRING_FROM_UTF8_AS_BYTES), - LintId::of(&suspicious_operation_groupings::SUSPICIOUS_OPERATION_GROUPINGS), - LintId::of(&suspicious_trait_impl::SUSPICIOUS_ARITHMETIC_IMPL), - LintId::of(&suspicious_trait_impl::SUSPICIOUS_OP_ASSIGN_IMPL), - LintId::of(&swap::ALMOST_SWAPPED), - LintId::of(&swap::MANUAL_SWAP), - LintId::of(&tabs_in_doc_comments::TABS_IN_DOC_COMMENTS), - LintId::of(&temporary_assignment::TEMPORARY_ASSIGNMENT), - LintId::of(&to_digit_is_some::TO_DIGIT_IS_SOME), - LintId::of(&to_string_in_display::TO_STRING_IN_DISPLAY), - LintId::of(&transmute::CROSSPOINTER_TRANSMUTE), - LintId::of(&transmute::TRANSMUTES_EXPRESSIBLE_AS_PTR_CASTS), - LintId::of(&transmute::TRANSMUTE_BYTES_TO_STR), - LintId::of(&transmute::TRANSMUTE_FLOAT_TO_INT), - LintId::of(&transmute::TRANSMUTE_INT_TO_BOOL), - LintId::of(&transmute::TRANSMUTE_INT_TO_CHAR), - LintId::of(&transmute::TRANSMUTE_INT_TO_FLOAT), - LintId::of(&transmute::TRANSMUTE_PTR_TO_PTR), - LintId::of(&transmute::TRANSMUTE_PTR_TO_REF), - LintId::of(&transmute::UNSOUND_COLLECTION_TRANSMUTE), - LintId::of(&transmute::WRONG_TRANSMUTE), - LintId::of(&transmuting_null::TRANSMUTING_NULL), - LintId::of(&try_err::TRY_ERR), - LintId::of(&types::BORROWED_BOX), - LintId::of(&types::BOX_VEC), - LintId::of(&types::REDUNDANT_ALLOCATION), - LintId::of(&types::TYPE_COMPLEXITY), - LintId::of(&types::VEC_BOX), - LintId::of(&undropped_manually_drops::UNDROPPED_MANUALLY_DROPS), - LintId::of(&unicode::INVISIBLE_CHARACTERS), - LintId::of(&unit_return_expecting_ord::UNIT_RETURN_EXPECTING_ORD), - LintId::of(&unit_types::UNIT_ARG), - LintId::of(&unit_types::UNIT_CMP), - LintId::of(&unnamed_address::FN_ADDRESS_COMPARISONS), - LintId::of(&unnamed_address::VTABLE_ADDRESS_COMPARISONS), - LintId::of(&unnecessary_sort_by::UNNECESSARY_SORT_BY), - LintId::of(&unsafe_removed_from_name::UNSAFE_REMOVED_FROM_NAME), - LintId::of(&unused_io_amount::UNUSED_IO_AMOUNT), - LintId::of(&unused_unit::UNUSED_UNIT), - LintId::of(&unwrap::PANICKING_UNWRAP), - LintId::of(&unwrap::UNNECESSARY_UNWRAP), - LintId::of(&upper_case_acronyms::UPPER_CASE_ACRONYMS), - LintId::of(&useless_conversion::USELESS_CONVERSION), - LintId::of(&vec::USELESS_VEC), - LintId::of(&vec_init_then_push::VEC_INIT_THEN_PUSH), - LintId::of(&vec_resize_to_zero::VEC_RESIZE_TO_ZERO), - LintId::of(&write::PRINTLN_EMPTY_STRING), - LintId::of(&write::PRINT_LITERAL), - LintId::of(&write::PRINT_WITH_NEWLINE), - LintId::of(&write::WRITELN_EMPTY_STRING), - LintId::of(&write::WRITE_LITERAL), - LintId::of(&write::WRITE_WITH_NEWLINE), - LintId::of(&zero_div_zero::ZERO_DIVIDED_BY_ZERO), + LintId::of(absurd_extreme_comparisons::ABSURD_EXTREME_COMPARISONS), + LintId::of(approx_const::APPROX_CONSTANT), + LintId::of(assertions_on_constants::ASSERTIONS_ON_CONSTANTS), + LintId::of(assign_ops::ASSIGN_OP_PATTERN), + LintId::of(assign_ops::MISREFACTORED_ASSIGN_OP), + LintId::of(async_yields_async::ASYNC_YIELDS_ASYNC), + LintId::of(atomic_ordering::INVALID_ATOMIC_ORDERING), + LintId::of(attrs::BLANKET_CLIPPY_RESTRICTION_LINTS), + LintId::of(attrs::DEPRECATED_CFG_ATTR), + LintId::of(attrs::DEPRECATED_SEMVER), + LintId::of(attrs::MISMATCHED_TARGET_OS), + LintId::of(attrs::USELESS_ATTRIBUTE), + LintId::of(bit_mask::BAD_BIT_MASK), + LintId::of(bit_mask::INEFFECTIVE_BIT_MASK), + LintId::of(blacklisted_name::BLACKLISTED_NAME), + LintId::of(blocks_in_if_conditions::BLOCKS_IN_IF_CONDITIONS), + LintId::of(booleans::LOGIC_BUG), + LintId::of(booleans::NONMINIMAL_BOOL), + LintId::of(casts::CAST_REF_TO_MUT), + LintId::of(casts::CHAR_LIT_AS_U8), + LintId::of(casts::FN_TO_NUMERIC_CAST), + LintId::of(casts::FN_TO_NUMERIC_CAST_WITH_TRUNCATION), + LintId::of(casts::UNNECESSARY_CAST), + LintId::of(collapsible_if::COLLAPSIBLE_ELSE_IF), + LintId::of(collapsible_if::COLLAPSIBLE_IF), + LintId::of(collapsible_match::COLLAPSIBLE_MATCH), + LintId::of(comparison_chain::COMPARISON_CHAIN), + LintId::of(copies::BRANCHES_SHARING_CODE), + LintId::of(copies::IFS_SAME_COND), + LintId::of(copies::IF_SAME_THEN_ELSE), + LintId::of(default::FIELD_REASSIGN_WITH_DEFAULT), + LintId::of(derive::DERIVE_HASH_XOR_EQ), + LintId::of(derive::DERIVE_ORD_XOR_PARTIAL_ORD), + LintId::of(doc::MISSING_SAFETY_DOC), + LintId::of(doc::NEEDLESS_DOCTEST_MAIN), + LintId::of(double_comparison::DOUBLE_COMPARISONS), + LintId::of(double_parens::DOUBLE_PARENS), + LintId::of(drop_forget_ref::DROP_COPY), + LintId::of(drop_forget_ref::DROP_REF), + LintId::of(drop_forget_ref::FORGET_COPY), + LintId::of(drop_forget_ref::FORGET_REF), + LintId::of(duration_subsec::DURATION_SUBSEC), + LintId::of(entry::MAP_ENTRY), + LintId::of(enum_clike::ENUM_CLIKE_UNPORTABLE_VARIANT), + LintId::of(enum_variants::ENUM_VARIANT_NAMES), + LintId::of(enum_variants::MODULE_INCEPTION), + LintId::of(eq_op::EQ_OP), + LintId::of(eq_op::OP_REF), + LintId::of(erasing_op::ERASING_OP), + LintId::of(escape::BOXED_LOCAL), + LintId::of(eta_reduction::REDUNDANT_CLOSURE), + LintId::of(eval_order_dependence::DIVERGING_SUB_EXPRESSION), + LintId::of(eval_order_dependence::EVAL_ORDER_DEPENDENCE), + LintId::of(explicit_write::EXPLICIT_WRITE), + LintId::of(float_equality_without_abs::FLOAT_EQUALITY_WITHOUT_ABS), + LintId::of(float_literal::EXCESSIVE_PRECISION), + LintId::of(format::USELESS_FORMAT), + LintId::of(formatting::POSSIBLE_MISSING_COMMA), + LintId::of(formatting::SUSPICIOUS_ASSIGNMENT_FORMATTING), + LintId::of(formatting::SUSPICIOUS_ELSE_FORMATTING), + LintId::of(formatting::SUSPICIOUS_UNARY_OP_FORMATTING), + LintId::of(from_over_into::FROM_OVER_INTO), + LintId::of(from_str_radix_10::FROM_STR_RADIX_10), + LintId::of(functions::DOUBLE_MUST_USE), + LintId::of(functions::MUST_USE_UNIT), + LintId::of(functions::NOT_UNSAFE_PTR_ARG_DEREF), + LintId::of(functions::RESULT_UNIT_ERR), + LintId::of(functions::TOO_MANY_ARGUMENTS), + LintId::of(get_last_with_len::GET_LAST_WITH_LEN), + LintId::of(identity_op::IDENTITY_OP), + LintId::of(if_let_mutex::IF_LET_MUTEX), + LintId::of(if_let_some_result::IF_LET_SOME_RESULT), + LintId::of(inconsistent_struct_constructor::INCONSISTENT_STRUCT_CONSTRUCTOR), + LintId::of(indexing_slicing::OUT_OF_BOUNDS_INDEXING), + LintId::of(infinite_iter::INFINITE_ITER), + LintId::of(inherent_to_string::INHERENT_TO_STRING), + LintId::of(inherent_to_string::INHERENT_TO_STRING_SHADOW_DISPLAY), + LintId::of(inline_fn_without_body::INLINE_FN_WITHOUT_BODY), + LintId::of(int_plus_one::INT_PLUS_ONE), + LintId::of(large_const_arrays::LARGE_CONST_ARRAYS), + LintId::of(large_enum_variant::LARGE_ENUM_VARIANT), + LintId::of(len_zero::COMPARISON_TO_EMPTY), + LintId::of(len_zero::LEN_WITHOUT_IS_EMPTY), + LintId::of(len_zero::LEN_ZERO), + LintId::of(let_underscore::LET_UNDERSCORE_LOCK), + LintId::of(lifetimes::EXTRA_UNUSED_LIFETIMES), + LintId::of(lifetimes::NEEDLESS_LIFETIMES), + LintId::of(literal_representation::INCONSISTENT_DIGIT_GROUPING), + LintId::of(literal_representation::MISTYPED_LITERAL_SUFFIXES), + LintId::of(literal_representation::UNUSUAL_BYTE_GROUPINGS), + LintId::of(loops::EMPTY_LOOP), + LintId::of(loops::EXPLICIT_COUNTER_LOOP), + LintId::of(loops::FOR_KV_MAP), + LintId::of(loops::FOR_LOOPS_OVER_FALLIBLES), + LintId::of(loops::ITER_NEXT_LOOP), + LintId::of(loops::MANUAL_FLATTEN), + LintId::of(loops::MANUAL_MEMCPY), + LintId::of(loops::MUT_RANGE_BOUND), + LintId::of(loops::NEEDLESS_COLLECT), + LintId::of(loops::NEEDLESS_RANGE_LOOP), + LintId::of(loops::NEVER_LOOP), + LintId::of(loops::SAME_ITEM_PUSH), + LintId::of(loops::SINGLE_ELEMENT_LOOP), + LintId::of(loops::WHILE_IMMUTABLE_CONDITION), + LintId::of(loops::WHILE_LET_LOOP), + LintId::of(loops::WHILE_LET_ON_ITERATOR), + LintId::of(main_recursion::MAIN_RECURSION), + LintId::of(manual_async_fn::MANUAL_ASYNC_FN), + LintId::of(manual_map::MANUAL_MAP), + LintId::of(manual_non_exhaustive::MANUAL_NON_EXHAUSTIVE), + LintId::of(manual_strip::MANUAL_STRIP), + LintId::of(manual_unwrap_or::MANUAL_UNWRAP_OR), + LintId::of(map_clone::MAP_CLONE), + LintId::of(map_identity::MAP_IDENTITY), + LintId::of(map_unit_fn::OPTION_MAP_UNIT_FN), + LintId::of(map_unit_fn::RESULT_MAP_UNIT_FN), + LintId::of(matches::INFALLIBLE_DESTRUCTURING_MATCH), + LintId::of(matches::MATCH_AS_REF), + LintId::of(matches::MATCH_LIKE_MATCHES_MACRO), + LintId::of(matches::MATCH_OVERLAPPING_ARM), + LintId::of(matches::MATCH_REF_PATS), + LintId::of(matches::MATCH_SINGLE_BINDING), + LintId::of(matches::REDUNDANT_PATTERN_MATCHING), + LintId::of(matches::SINGLE_MATCH), + LintId::of(matches::WILDCARD_IN_OR_PATTERNS), + LintId::of(mem_discriminant::MEM_DISCRIMINANT_NON_ENUM), + LintId::of(mem_replace::MEM_REPLACE_OPTION_WITH_NONE), + LintId::of(mem_replace::MEM_REPLACE_WITH_DEFAULT), + LintId::of(mem_replace::MEM_REPLACE_WITH_UNINIT), + LintId::of(methods::BIND_INSTEAD_OF_MAP), + LintId::of(methods::BYTES_NTH), + LintId::of(methods::CHARS_LAST_CMP), + LintId::of(methods::CHARS_NEXT_CMP), + LintId::of(methods::CLONE_DOUBLE_REF), + LintId::of(methods::CLONE_ON_COPY), + LintId::of(methods::EXPECT_FUN_CALL), + LintId::of(methods::FILTER_MAP_IDENTITY), + LintId::of(methods::FILTER_NEXT), + LintId::of(methods::FLAT_MAP_IDENTITY), + LintId::of(methods::FROM_ITER_INSTEAD_OF_COLLECT), + LintId::of(methods::INSPECT_FOR_EACH), + LintId::of(methods::INTO_ITER_ON_REF), + LintId::of(methods::ITERATOR_STEP_BY_ZERO), + LintId::of(methods::ITER_CLONED_COLLECT), + LintId::of(methods::ITER_COUNT), + LintId::of(methods::ITER_NEXT_SLICE), + LintId::of(methods::ITER_NTH), + LintId::of(methods::ITER_NTH_ZERO), + LintId::of(methods::ITER_SKIP_NEXT), + LintId::of(methods::MANUAL_FILTER_MAP), + LintId::of(methods::MANUAL_FIND_MAP), + LintId::of(methods::MANUAL_SATURATING_ARITHMETIC), + LintId::of(methods::MAP_COLLECT_RESULT_UNIT), + LintId::of(methods::NEW_RET_NO_SELF), + LintId::of(methods::OK_EXPECT), + LintId::of(methods::OPTION_AS_REF_DEREF), + LintId::of(methods::OPTION_FILTER_MAP), + LintId::of(methods::OPTION_MAP_OR_NONE), + LintId::of(methods::OR_FUN_CALL), + LintId::of(methods::RESULT_MAP_OR_INTO_OPTION), + LintId::of(methods::SEARCH_IS_SOME), + LintId::of(methods::SHOULD_IMPLEMENT_TRAIT), + LintId::of(methods::SINGLE_CHAR_ADD_STR), + LintId::of(methods::SINGLE_CHAR_PATTERN), + LintId::of(methods::SKIP_WHILE_NEXT), + LintId::of(methods::STRING_EXTEND_CHARS), + LintId::of(methods::SUSPICIOUS_MAP), + LintId::of(methods::UNINIT_ASSUMED_INIT), + LintId::of(methods::UNNECESSARY_FILTER_MAP), + LintId::of(methods::UNNECESSARY_FOLD), + LintId::of(methods::UNNECESSARY_LAZY_EVALUATIONS), + LintId::of(methods::USELESS_ASREF), + LintId::of(methods::WRONG_SELF_CONVENTION), + LintId::of(methods::ZST_OFFSET), + LintId::of(minmax::MIN_MAX), + LintId::of(misc::CMP_NAN), + LintId::of(misc::CMP_OWNED), + LintId::of(misc::FLOAT_CMP), + LintId::of(misc::MODULO_ONE), + LintId::of(misc::SHORT_CIRCUIT_STATEMENT), + LintId::of(misc::TOPLEVEL_REF_ARG), + LintId::of(misc::ZERO_PTR), + LintId::of(misc_early::BUILTIN_TYPE_SHADOW), + LintId::of(misc_early::DOUBLE_NEG), + LintId::of(misc_early::DUPLICATE_UNDERSCORE_ARGUMENT), + LintId::of(misc_early::MIXED_CASE_HEX_LITERALS), + LintId::of(misc_early::REDUNDANT_PATTERN), + LintId::of(misc_early::UNNEEDED_WILDCARD_PATTERN), + LintId::of(misc_early::ZERO_PREFIXED_LITERAL), + LintId::of(mut_key::MUTABLE_KEY_TYPE), + LintId::of(mut_mutex_lock::MUT_MUTEX_LOCK), + LintId::of(mut_reference::UNNECESSARY_MUT_PASSED), + LintId::of(mutex_atomic::MUTEX_ATOMIC), + LintId::of(needless_arbitrary_self_type::NEEDLESS_ARBITRARY_SELF_TYPE), + LintId::of(needless_bool::BOOL_COMPARISON), + LintId::of(needless_bool::NEEDLESS_BOOL), + LintId::of(needless_borrowed_ref::NEEDLESS_BORROWED_REFERENCE), + LintId::of(needless_question_mark::NEEDLESS_QUESTION_MARK), + LintId::of(needless_update::NEEDLESS_UPDATE), + LintId::of(neg_cmp_op_on_partial_ord::NEG_CMP_OP_ON_PARTIAL_ORD), + LintId::of(neg_multiply::NEG_MULTIPLY), + LintId::of(new_without_default::NEW_WITHOUT_DEFAULT), + LintId::of(no_effect::NO_EFFECT), + LintId::of(no_effect::UNNECESSARY_OPERATION), + LintId::of(non_copy_const::BORROW_INTERIOR_MUTABLE_CONST), + LintId::of(non_copy_const::DECLARE_INTERIOR_MUTABLE_CONST), + LintId::of(non_expressive_names::JUST_UNDERSCORES_AND_DIGITS), + LintId::of(non_expressive_names::MANY_SINGLE_CHAR_NAMES), + LintId::of(non_octal_unix_permissions::NON_OCTAL_UNIX_PERMISSIONS), + LintId::of(open_options::NONSENSICAL_OPEN_OPTIONS), + LintId::of(option_env_unwrap::OPTION_ENV_UNWRAP), + LintId::of(overflow_check_conditional::OVERFLOW_CHECK_CONDITIONAL), + LintId::of(partialeq_ne_impl::PARTIALEQ_NE_IMPL), + LintId::of(precedence::PRECEDENCE), + LintId::of(ptr::CMP_NULL), + LintId::of(ptr::MUT_FROM_REF), + LintId::of(ptr::PTR_ARG), + LintId::of(ptr_eq::PTR_EQ), + LintId::of(ptr_offset_with_cast::PTR_OFFSET_WITH_CAST), + LintId::of(question_mark::QUESTION_MARK), + LintId::of(ranges::MANUAL_RANGE_CONTAINS), + LintId::of(ranges::RANGE_ZIP_WITH_LEN), + LintId::of(ranges::REVERSED_EMPTY_RANGES), + LintId::of(redundant_clone::REDUNDANT_CLONE), + LintId::of(redundant_closure_call::REDUNDANT_CLOSURE_CALL), + LintId::of(redundant_field_names::REDUNDANT_FIELD_NAMES), + LintId::of(redundant_slicing::REDUNDANT_SLICING), + LintId::of(redundant_static_lifetimes::REDUNDANT_STATIC_LIFETIMES), + LintId::of(reference::DEREF_ADDROF), + LintId::of(reference::REF_IN_DEREF), + LintId::of(regex::INVALID_REGEX), + LintId::of(repeat_once::REPEAT_ONCE), + LintId::of(returns::LET_AND_RETURN), + LintId::of(returns::NEEDLESS_RETURN), + LintId::of(self_assignment::SELF_ASSIGNMENT), + LintId::of(serde_api::SERDE_API_MISUSE), + LintId::of(single_component_path_imports::SINGLE_COMPONENT_PATH_IMPORTS), + LintId::of(size_of_in_element_count::SIZE_OF_IN_ELEMENT_COUNT), + LintId::of(slow_vector_initialization::SLOW_VECTOR_INITIALIZATION), + LintId::of(stable_sort_primitive::STABLE_SORT_PRIMITIVE), + LintId::of(strings::STRING_FROM_UTF8_AS_BYTES), + LintId::of(suspicious_operation_groupings::SUSPICIOUS_OPERATION_GROUPINGS), + LintId::of(suspicious_trait_impl::SUSPICIOUS_ARITHMETIC_IMPL), + LintId::of(suspicious_trait_impl::SUSPICIOUS_OP_ASSIGN_IMPL), + LintId::of(swap::ALMOST_SWAPPED), + LintId::of(swap::MANUAL_SWAP), + LintId::of(tabs_in_doc_comments::TABS_IN_DOC_COMMENTS), + LintId::of(temporary_assignment::TEMPORARY_ASSIGNMENT), + LintId::of(to_digit_is_some::TO_DIGIT_IS_SOME), + LintId::of(to_string_in_display::TO_STRING_IN_DISPLAY), + LintId::of(transmute::CROSSPOINTER_TRANSMUTE), + LintId::of(transmute::TRANSMUTES_EXPRESSIBLE_AS_PTR_CASTS), + LintId::of(transmute::TRANSMUTE_BYTES_TO_STR), + LintId::of(transmute::TRANSMUTE_FLOAT_TO_INT), + LintId::of(transmute::TRANSMUTE_INT_TO_BOOL), + LintId::of(transmute::TRANSMUTE_INT_TO_CHAR), + LintId::of(transmute::TRANSMUTE_INT_TO_FLOAT), + LintId::of(transmute::TRANSMUTE_PTR_TO_PTR), + LintId::of(transmute::TRANSMUTE_PTR_TO_REF), + LintId::of(transmute::UNSOUND_COLLECTION_TRANSMUTE), + LintId::of(transmute::WRONG_TRANSMUTE), + LintId::of(transmuting_null::TRANSMUTING_NULL), + LintId::of(try_err::TRY_ERR), + LintId::of(types::BORROWED_BOX), + LintId::of(types::BOX_VEC), + LintId::of(types::REDUNDANT_ALLOCATION), + LintId::of(types::TYPE_COMPLEXITY), + LintId::of(types::VEC_BOX), + LintId::of(undropped_manually_drops::UNDROPPED_MANUALLY_DROPS), + LintId::of(unicode::INVISIBLE_CHARACTERS), + LintId::of(unit_return_expecting_ord::UNIT_RETURN_EXPECTING_ORD), + LintId::of(unit_types::UNIT_ARG), + LintId::of(unit_types::UNIT_CMP), + LintId::of(unnamed_address::FN_ADDRESS_COMPARISONS), + LintId::of(unnamed_address::VTABLE_ADDRESS_COMPARISONS), + LintId::of(unnecessary_sort_by::UNNECESSARY_SORT_BY), + LintId::of(unsafe_removed_from_name::UNSAFE_REMOVED_FROM_NAME), + LintId::of(unused_io_amount::UNUSED_IO_AMOUNT), + LintId::of(unused_unit::UNUSED_UNIT), + LintId::of(unwrap::PANICKING_UNWRAP), + LintId::of(unwrap::UNNECESSARY_UNWRAP), + LintId::of(upper_case_acronyms::UPPER_CASE_ACRONYMS), + LintId::of(useless_conversion::USELESS_CONVERSION), + LintId::of(vec::USELESS_VEC), + LintId::of(vec_init_then_push::VEC_INIT_THEN_PUSH), + LintId::of(vec_resize_to_zero::VEC_RESIZE_TO_ZERO), + LintId::of(write::PRINTLN_EMPTY_STRING), + LintId::of(write::PRINT_LITERAL), + LintId::of(write::PRINT_WITH_NEWLINE), + LintId::of(write::WRITELN_EMPTY_STRING), + LintId::of(write::WRITE_LITERAL), + LintId::of(write::WRITE_WITH_NEWLINE), + LintId::of(zero_div_zero::ZERO_DIVIDED_BY_ZERO), ]); store.register_group(true, "clippy::style", Some("clippy_style"), vec![ - LintId::of(&assertions_on_constants::ASSERTIONS_ON_CONSTANTS), - LintId::of(&assign_ops::ASSIGN_OP_PATTERN), - LintId::of(&attrs::BLANKET_CLIPPY_RESTRICTION_LINTS), - LintId::of(&blacklisted_name::BLACKLISTED_NAME), - LintId::of(&blocks_in_if_conditions::BLOCKS_IN_IF_CONDITIONS), - LintId::of(&casts::FN_TO_NUMERIC_CAST), - LintId::of(&casts::FN_TO_NUMERIC_CAST_WITH_TRUNCATION), - LintId::of(&collapsible_if::COLLAPSIBLE_ELSE_IF), - LintId::of(&collapsible_if::COLLAPSIBLE_IF), - LintId::of(&collapsible_match::COLLAPSIBLE_MATCH), - LintId::of(&comparison_chain::COMPARISON_CHAIN), - LintId::of(&default::FIELD_REASSIGN_WITH_DEFAULT), - LintId::of(&doc::MISSING_SAFETY_DOC), - LintId::of(&doc::NEEDLESS_DOCTEST_MAIN), - LintId::of(&enum_variants::ENUM_VARIANT_NAMES), - LintId::of(&enum_variants::MODULE_INCEPTION), - LintId::of(&eq_op::OP_REF), - LintId::of(&eta_reduction::REDUNDANT_CLOSURE), - LintId::of(&float_literal::EXCESSIVE_PRECISION), - LintId::of(&formatting::SUSPICIOUS_ASSIGNMENT_FORMATTING), - LintId::of(&formatting::SUSPICIOUS_ELSE_FORMATTING), - LintId::of(&formatting::SUSPICIOUS_UNARY_OP_FORMATTING), - LintId::of(&from_over_into::FROM_OVER_INTO), - LintId::of(&from_str_radix_10::FROM_STR_RADIX_10), - LintId::of(&functions::DOUBLE_MUST_USE), - LintId::of(&functions::MUST_USE_UNIT), - LintId::of(&functions::RESULT_UNIT_ERR), - LintId::of(&if_let_some_result::IF_LET_SOME_RESULT), - LintId::of(&inconsistent_struct_constructor::INCONSISTENT_STRUCT_CONSTRUCTOR), - LintId::of(&inherent_to_string::INHERENT_TO_STRING), - LintId::of(&len_zero::COMPARISON_TO_EMPTY), - LintId::of(&len_zero::LEN_WITHOUT_IS_EMPTY), - LintId::of(&len_zero::LEN_ZERO), - LintId::of(&literal_representation::INCONSISTENT_DIGIT_GROUPING), - LintId::of(&literal_representation::UNUSUAL_BYTE_GROUPINGS), - LintId::of(&loops::EMPTY_LOOP), - LintId::of(&loops::FOR_KV_MAP), - LintId::of(&loops::NEEDLESS_RANGE_LOOP), - LintId::of(&loops::SAME_ITEM_PUSH), - LintId::of(&loops::WHILE_LET_ON_ITERATOR), - LintId::of(&main_recursion::MAIN_RECURSION), - LintId::of(&manual_async_fn::MANUAL_ASYNC_FN), - LintId::of(&manual_map::MANUAL_MAP), - LintId::of(&manual_non_exhaustive::MANUAL_NON_EXHAUSTIVE), - LintId::of(&map_clone::MAP_CLONE), - LintId::of(&matches::INFALLIBLE_DESTRUCTURING_MATCH), - LintId::of(&matches::MATCH_LIKE_MATCHES_MACRO), - LintId::of(&matches::MATCH_OVERLAPPING_ARM), - LintId::of(&matches::MATCH_REF_PATS), - LintId::of(&matches::REDUNDANT_PATTERN_MATCHING), - LintId::of(&matches::SINGLE_MATCH), - LintId::of(&mem_replace::MEM_REPLACE_OPTION_WITH_NONE), - LintId::of(&mem_replace::MEM_REPLACE_WITH_DEFAULT), - LintId::of(&methods::BYTES_NTH), - LintId::of(&methods::CHARS_LAST_CMP), - LintId::of(&methods::CHARS_NEXT_CMP), - LintId::of(&methods::FROM_ITER_INSTEAD_OF_COLLECT), - LintId::of(&methods::INTO_ITER_ON_REF), - LintId::of(&methods::ITER_CLONED_COLLECT), - LintId::of(&methods::ITER_NEXT_SLICE), - LintId::of(&methods::ITER_NTH_ZERO), - LintId::of(&methods::ITER_SKIP_NEXT), - LintId::of(&methods::MANUAL_SATURATING_ARITHMETIC), - LintId::of(&methods::MAP_COLLECT_RESULT_UNIT), - LintId::of(&methods::NEW_RET_NO_SELF), - LintId::of(&methods::OK_EXPECT), - LintId::of(&methods::OPTION_MAP_OR_NONE), - LintId::of(&methods::RESULT_MAP_OR_INTO_OPTION), - LintId::of(&methods::SHOULD_IMPLEMENT_TRAIT), - LintId::of(&methods::SINGLE_CHAR_ADD_STR), - LintId::of(&methods::STRING_EXTEND_CHARS), - LintId::of(&methods::UNNECESSARY_FOLD), - LintId::of(&methods::UNNECESSARY_LAZY_EVALUATIONS), - LintId::of(&methods::WRONG_SELF_CONVENTION), - LintId::of(&misc::TOPLEVEL_REF_ARG), - LintId::of(&misc::ZERO_PTR), - LintId::of(&misc_early::BUILTIN_TYPE_SHADOW), - LintId::of(&misc_early::DOUBLE_NEG), - LintId::of(&misc_early::DUPLICATE_UNDERSCORE_ARGUMENT), - LintId::of(&misc_early::MIXED_CASE_HEX_LITERALS), - LintId::of(&misc_early::REDUNDANT_PATTERN), - LintId::of(&mut_mutex_lock::MUT_MUTEX_LOCK), - LintId::of(&mut_reference::UNNECESSARY_MUT_PASSED), - LintId::of(&neg_multiply::NEG_MULTIPLY), - LintId::of(&new_without_default::NEW_WITHOUT_DEFAULT), - LintId::of(&non_copy_const::BORROW_INTERIOR_MUTABLE_CONST), - LintId::of(&non_copy_const::DECLARE_INTERIOR_MUTABLE_CONST), - LintId::of(&non_expressive_names::JUST_UNDERSCORES_AND_DIGITS), - LintId::of(&non_expressive_names::MANY_SINGLE_CHAR_NAMES), - LintId::of(&ptr::CMP_NULL), - LintId::of(&ptr::PTR_ARG), - LintId::of(&ptr_eq::PTR_EQ), - LintId::of(&question_mark::QUESTION_MARK), - LintId::of(&ranges::MANUAL_RANGE_CONTAINS), - LintId::of(&redundant_field_names::REDUNDANT_FIELD_NAMES), - LintId::of(&redundant_static_lifetimes::REDUNDANT_STATIC_LIFETIMES), - LintId::of(&returns::LET_AND_RETURN), - LintId::of(&returns::NEEDLESS_RETURN), - LintId::of(&single_component_path_imports::SINGLE_COMPONENT_PATH_IMPORTS), - LintId::of(&suspicious_operation_groupings::SUSPICIOUS_OPERATION_GROUPINGS), - LintId::of(&tabs_in_doc_comments::TABS_IN_DOC_COMMENTS), - LintId::of(&to_digit_is_some::TO_DIGIT_IS_SOME), - LintId::of(&try_err::TRY_ERR), - LintId::of(&unsafe_removed_from_name::UNSAFE_REMOVED_FROM_NAME), - LintId::of(&unused_unit::UNUSED_UNIT), - LintId::of(&upper_case_acronyms::UPPER_CASE_ACRONYMS), - LintId::of(&write::PRINTLN_EMPTY_STRING), - LintId::of(&write::PRINT_LITERAL), - LintId::of(&write::PRINT_WITH_NEWLINE), - LintId::of(&write::WRITELN_EMPTY_STRING), - LintId::of(&write::WRITE_LITERAL), - LintId::of(&write::WRITE_WITH_NEWLINE), + LintId::of(assertions_on_constants::ASSERTIONS_ON_CONSTANTS), + LintId::of(assign_ops::ASSIGN_OP_PATTERN), + LintId::of(attrs::BLANKET_CLIPPY_RESTRICTION_LINTS), + LintId::of(blacklisted_name::BLACKLISTED_NAME), + LintId::of(blocks_in_if_conditions::BLOCKS_IN_IF_CONDITIONS), + LintId::of(casts::FN_TO_NUMERIC_CAST), + LintId::of(casts::FN_TO_NUMERIC_CAST_WITH_TRUNCATION), + LintId::of(collapsible_if::COLLAPSIBLE_ELSE_IF), + LintId::of(collapsible_if::COLLAPSIBLE_IF), + LintId::of(collapsible_match::COLLAPSIBLE_MATCH), + LintId::of(comparison_chain::COMPARISON_CHAIN), + LintId::of(default::FIELD_REASSIGN_WITH_DEFAULT), + LintId::of(doc::MISSING_SAFETY_DOC), + LintId::of(doc::NEEDLESS_DOCTEST_MAIN), + LintId::of(enum_variants::ENUM_VARIANT_NAMES), + LintId::of(enum_variants::MODULE_INCEPTION), + LintId::of(eq_op::OP_REF), + LintId::of(eta_reduction::REDUNDANT_CLOSURE), + LintId::of(float_literal::EXCESSIVE_PRECISION), + LintId::of(formatting::SUSPICIOUS_ASSIGNMENT_FORMATTING), + LintId::of(formatting::SUSPICIOUS_ELSE_FORMATTING), + LintId::of(formatting::SUSPICIOUS_UNARY_OP_FORMATTING), + LintId::of(from_over_into::FROM_OVER_INTO), + LintId::of(from_str_radix_10::FROM_STR_RADIX_10), + LintId::of(functions::DOUBLE_MUST_USE), + LintId::of(functions::MUST_USE_UNIT), + LintId::of(functions::RESULT_UNIT_ERR), + LintId::of(if_let_some_result::IF_LET_SOME_RESULT), + LintId::of(inconsistent_struct_constructor::INCONSISTENT_STRUCT_CONSTRUCTOR), + LintId::of(inherent_to_string::INHERENT_TO_STRING), + LintId::of(len_zero::COMPARISON_TO_EMPTY), + LintId::of(len_zero::LEN_WITHOUT_IS_EMPTY), + LintId::of(len_zero::LEN_ZERO), + LintId::of(literal_representation::INCONSISTENT_DIGIT_GROUPING), + LintId::of(literal_representation::UNUSUAL_BYTE_GROUPINGS), + LintId::of(loops::EMPTY_LOOP), + LintId::of(loops::FOR_KV_MAP), + LintId::of(loops::NEEDLESS_RANGE_LOOP), + LintId::of(loops::SAME_ITEM_PUSH), + LintId::of(loops::WHILE_LET_ON_ITERATOR), + LintId::of(main_recursion::MAIN_RECURSION), + LintId::of(manual_async_fn::MANUAL_ASYNC_FN), + LintId::of(manual_map::MANUAL_MAP), + LintId::of(manual_non_exhaustive::MANUAL_NON_EXHAUSTIVE), + LintId::of(map_clone::MAP_CLONE), + LintId::of(matches::INFALLIBLE_DESTRUCTURING_MATCH), + LintId::of(matches::MATCH_LIKE_MATCHES_MACRO), + LintId::of(matches::MATCH_OVERLAPPING_ARM), + LintId::of(matches::MATCH_REF_PATS), + LintId::of(matches::REDUNDANT_PATTERN_MATCHING), + LintId::of(matches::SINGLE_MATCH), + LintId::of(mem_replace::MEM_REPLACE_OPTION_WITH_NONE), + LintId::of(mem_replace::MEM_REPLACE_WITH_DEFAULT), + LintId::of(methods::BYTES_NTH), + LintId::of(methods::CHARS_LAST_CMP), + LintId::of(methods::CHARS_NEXT_CMP), + LintId::of(methods::FROM_ITER_INSTEAD_OF_COLLECT), + LintId::of(methods::INTO_ITER_ON_REF), + LintId::of(methods::ITER_CLONED_COLLECT), + LintId::of(methods::ITER_NEXT_SLICE), + LintId::of(methods::ITER_NTH_ZERO), + LintId::of(methods::ITER_SKIP_NEXT), + LintId::of(methods::MANUAL_SATURATING_ARITHMETIC), + LintId::of(methods::MAP_COLLECT_RESULT_UNIT), + LintId::of(methods::NEW_RET_NO_SELF), + LintId::of(methods::OK_EXPECT), + LintId::of(methods::OPTION_MAP_OR_NONE), + LintId::of(methods::RESULT_MAP_OR_INTO_OPTION), + LintId::of(methods::SHOULD_IMPLEMENT_TRAIT), + LintId::of(methods::SINGLE_CHAR_ADD_STR), + LintId::of(methods::STRING_EXTEND_CHARS), + LintId::of(methods::UNNECESSARY_FOLD), + LintId::of(methods::UNNECESSARY_LAZY_EVALUATIONS), + LintId::of(methods::WRONG_SELF_CONVENTION), + LintId::of(misc::TOPLEVEL_REF_ARG), + LintId::of(misc::ZERO_PTR), + LintId::of(misc_early::BUILTIN_TYPE_SHADOW), + LintId::of(misc_early::DOUBLE_NEG), + LintId::of(misc_early::DUPLICATE_UNDERSCORE_ARGUMENT), + LintId::of(misc_early::MIXED_CASE_HEX_LITERALS), + LintId::of(misc_early::REDUNDANT_PATTERN), + LintId::of(mut_mutex_lock::MUT_MUTEX_LOCK), + LintId::of(mut_reference::UNNECESSARY_MUT_PASSED), + LintId::of(neg_multiply::NEG_MULTIPLY), + LintId::of(new_without_default::NEW_WITHOUT_DEFAULT), + LintId::of(non_copy_const::BORROW_INTERIOR_MUTABLE_CONST), + LintId::of(non_copy_const::DECLARE_INTERIOR_MUTABLE_CONST), + LintId::of(non_expressive_names::JUST_UNDERSCORES_AND_DIGITS), + LintId::of(non_expressive_names::MANY_SINGLE_CHAR_NAMES), + LintId::of(ptr::CMP_NULL), + LintId::of(ptr::PTR_ARG), + LintId::of(ptr_eq::PTR_EQ), + LintId::of(question_mark::QUESTION_MARK), + LintId::of(ranges::MANUAL_RANGE_CONTAINS), + LintId::of(redundant_field_names::REDUNDANT_FIELD_NAMES), + LintId::of(redundant_static_lifetimes::REDUNDANT_STATIC_LIFETIMES), + LintId::of(returns::LET_AND_RETURN), + LintId::of(returns::NEEDLESS_RETURN), + LintId::of(single_component_path_imports::SINGLE_COMPONENT_PATH_IMPORTS), + LintId::of(suspicious_operation_groupings::SUSPICIOUS_OPERATION_GROUPINGS), + LintId::of(tabs_in_doc_comments::TABS_IN_DOC_COMMENTS), + LintId::of(to_digit_is_some::TO_DIGIT_IS_SOME), + LintId::of(try_err::TRY_ERR), + LintId::of(unsafe_removed_from_name::UNSAFE_REMOVED_FROM_NAME), + LintId::of(unused_unit::UNUSED_UNIT), + LintId::of(upper_case_acronyms::UPPER_CASE_ACRONYMS), + LintId::of(write::PRINTLN_EMPTY_STRING), + LintId::of(write::PRINT_LITERAL), + LintId::of(write::PRINT_WITH_NEWLINE), + LintId::of(write::WRITELN_EMPTY_STRING), + LintId::of(write::WRITE_LITERAL), + LintId::of(write::WRITE_WITH_NEWLINE), ]); store.register_group(true, "clippy::complexity", Some("clippy_complexity"), vec![ - LintId::of(&assign_ops::MISREFACTORED_ASSIGN_OP), - LintId::of(&attrs::DEPRECATED_CFG_ATTR), - LintId::of(&booleans::NONMINIMAL_BOOL), - LintId::of(&casts::CHAR_LIT_AS_U8), - LintId::of(&casts::UNNECESSARY_CAST), - LintId::of(&copies::BRANCHES_SHARING_CODE), - LintId::of(&double_comparison::DOUBLE_COMPARISONS), - LintId::of(&double_parens::DOUBLE_PARENS), - LintId::of(&duration_subsec::DURATION_SUBSEC), - LintId::of(&eval_order_dependence::DIVERGING_SUB_EXPRESSION), - LintId::of(&eval_order_dependence::EVAL_ORDER_DEPENDENCE), - LintId::of(&explicit_write::EXPLICIT_WRITE), - LintId::of(&format::USELESS_FORMAT), - LintId::of(&functions::TOO_MANY_ARGUMENTS), - LintId::of(&get_last_with_len::GET_LAST_WITH_LEN), - LintId::of(&identity_op::IDENTITY_OP), - LintId::of(&int_plus_one::INT_PLUS_ONE), - LintId::of(&lifetimes::EXTRA_UNUSED_LIFETIMES), - LintId::of(&lifetimes::NEEDLESS_LIFETIMES), - LintId::of(&loops::EXPLICIT_COUNTER_LOOP), - LintId::of(&loops::MANUAL_FLATTEN), - LintId::of(&loops::MUT_RANGE_BOUND), - LintId::of(&loops::SINGLE_ELEMENT_LOOP), - LintId::of(&loops::WHILE_LET_LOOP), - LintId::of(&manual_strip::MANUAL_STRIP), - LintId::of(&manual_unwrap_or::MANUAL_UNWRAP_OR), - LintId::of(&map_identity::MAP_IDENTITY), - LintId::of(&map_unit_fn::OPTION_MAP_UNIT_FN), - LintId::of(&map_unit_fn::RESULT_MAP_UNIT_FN), - LintId::of(&matches::MATCH_AS_REF), - LintId::of(&matches::MATCH_SINGLE_BINDING), - LintId::of(&matches::WILDCARD_IN_OR_PATTERNS), - LintId::of(&methods::BIND_INSTEAD_OF_MAP), - LintId::of(&methods::CLONE_ON_COPY), - LintId::of(&methods::FILTER_MAP_IDENTITY), - LintId::of(&methods::FILTER_NEXT), - LintId::of(&methods::FLAT_MAP_IDENTITY), - LintId::of(&methods::INSPECT_FOR_EACH), - LintId::of(&methods::ITER_COUNT), - LintId::of(&methods::MANUAL_FILTER_MAP), - LintId::of(&methods::MANUAL_FIND_MAP), - LintId::of(&methods::OPTION_AS_REF_DEREF), - LintId::of(&methods::OPTION_FILTER_MAP), - LintId::of(&methods::SEARCH_IS_SOME), - LintId::of(&methods::SKIP_WHILE_NEXT), - LintId::of(&methods::SUSPICIOUS_MAP), - LintId::of(&methods::UNNECESSARY_FILTER_MAP), - LintId::of(&methods::USELESS_ASREF), - LintId::of(&misc::SHORT_CIRCUIT_STATEMENT), - LintId::of(&misc_early::UNNEEDED_WILDCARD_PATTERN), - LintId::of(&misc_early::ZERO_PREFIXED_LITERAL), - LintId::of(&needless_arbitrary_self_type::NEEDLESS_ARBITRARY_SELF_TYPE), - LintId::of(&needless_bool::BOOL_COMPARISON), - LintId::of(&needless_bool::NEEDLESS_BOOL), - LintId::of(&needless_borrowed_ref::NEEDLESS_BORROWED_REFERENCE), - LintId::of(&needless_question_mark::NEEDLESS_QUESTION_MARK), - LintId::of(&needless_update::NEEDLESS_UPDATE), - LintId::of(&neg_cmp_op_on_partial_ord::NEG_CMP_OP_ON_PARTIAL_ORD), - LintId::of(&no_effect::NO_EFFECT), - LintId::of(&no_effect::UNNECESSARY_OPERATION), - LintId::of(&overflow_check_conditional::OVERFLOW_CHECK_CONDITIONAL), - LintId::of(&partialeq_ne_impl::PARTIALEQ_NE_IMPL), - LintId::of(&precedence::PRECEDENCE), - LintId::of(&ptr_offset_with_cast::PTR_OFFSET_WITH_CAST), - LintId::of(&ranges::RANGE_ZIP_WITH_LEN), - LintId::of(&redundant_closure_call::REDUNDANT_CLOSURE_CALL), - LintId::of(&redundant_slicing::REDUNDANT_SLICING), - LintId::of(&reference::DEREF_ADDROF), - LintId::of(&reference::REF_IN_DEREF), - LintId::of(&repeat_once::REPEAT_ONCE), - LintId::of(&strings::STRING_FROM_UTF8_AS_BYTES), - LintId::of(&swap::MANUAL_SWAP), - LintId::of(&temporary_assignment::TEMPORARY_ASSIGNMENT), - LintId::of(&transmute::CROSSPOINTER_TRANSMUTE), - LintId::of(&transmute::TRANSMUTES_EXPRESSIBLE_AS_PTR_CASTS), - LintId::of(&transmute::TRANSMUTE_BYTES_TO_STR), - LintId::of(&transmute::TRANSMUTE_FLOAT_TO_INT), - LintId::of(&transmute::TRANSMUTE_INT_TO_BOOL), - LintId::of(&transmute::TRANSMUTE_INT_TO_CHAR), - LintId::of(&transmute::TRANSMUTE_INT_TO_FLOAT), - LintId::of(&transmute::TRANSMUTE_PTR_TO_PTR), - LintId::of(&transmute::TRANSMUTE_PTR_TO_REF), - LintId::of(&types::BORROWED_BOX), - LintId::of(&types::TYPE_COMPLEXITY), - LintId::of(&types::VEC_BOX), - LintId::of(&unit_types::UNIT_ARG), - LintId::of(&unnecessary_sort_by::UNNECESSARY_SORT_BY), - LintId::of(&unwrap::UNNECESSARY_UNWRAP), - LintId::of(&useless_conversion::USELESS_CONVERSION), - LintId::of(&zero_div_zero::ZERO_DIVIDED_BY_ZERO), + LintId::of(assign_ops::MISREFACTORED_ASSIGN_OP), + LintId::of(attrs::DEPRECATED_CFG_ATTR), + LintId::of(booleans::NONMINIMAL_BOOL), + LintId::of(casts::CHAR_LIT_AS_U8), + LintId::of(casts::UNNECESSARY_CAST), + LintId::of(copies::BRANCHES_SHARING_CODE), + LintId::of(double_comparison::DOUBLE_COMPARISONS), + LintId::of(double_parens::DOUBLE_PARENS), + LintId::of(duration_subsec::DURATION_SUBSEC), + LintId::of(eval_order_dependence::DIVERGING_SUB_EXPRESSION), + LintId::of(eval_order_dependence::EVAL_ORDER_DEPENDENCE), + LintId::of(explicit_write::EXPLICIT_WRITE), + LintId::of(format::USELESS_FORMAT), + LintId::of(functions::TOO_MANY_ARGUMENTS), + LintId::of(get_last_with_len::GET_LAST_WITH_LEN), + LintId::of(identity_op::IDENTITY_OP), + LintId::of(int_plus_one::INT_PLUS_ONE), + LintId::of(lifetimes::EXTRA_UNUSED_LIFETIMES), + LintId::of(lifetimes::NEEDLESS_LIFETIMES), + LintId::of(loops::EXPLICIT_COUNTER_LOOP), + LintId::of(loops::MANUAL_FLATTEN), + LintId::of(loops::MUT_RANGE_BOUND), + LintId::of(loops::SINGLE_ELEMENT_LOOP), + LintId::of(loops::WHILE_LET_LOOP), + LintId::of(manual_strip::MANUAL_STRIP), + LintId::of(manual_unwrap_or::MANUAL_UNWRAP_OR), + LintId::of(map_identity::MAP_IDENTITY), + LintId::of(map_unit_fn::OPTION_MAP_UNIT_FN), + LintId::of(map_unit_fn::RESULT_MAP_UNIT_FN), + LintId::of(matches::MATCH_AS_REF), + LintId::of(matches::MATCH_SINGLE_BINDING), + LintId::of(matches::WILDCARD_IN_OR_PATTERNS), + LintId::of(methods::BIND_INSTEAD_OF_MAP), + LintId::of(methods::CLONE_ON_COPY), + LintId::of(methods::FILTER_MAP_IDENTITY), + LintId::of(methods::FILTER_NEXT), + LintId::of(methods::FLAT_MAP_IDENTITY), + LintId::of(methods::INSPECT_FOR_EACH), + LintId::of(methods::ITER_COUNT), + LintId::of(methods::MANUAL_FILTER_MAP), + LintId::of(methods::MANUAL_FIND_MAP), + LintId::of(methods::OPTION_AS_REF_DEREF), + LintId::of(methods::OPTION_FILTER_MAP), + LintId::of(methods::SEARCH_IS_SOME), + LintId::of(methods::SKIP_WHILE_NEXT), + LintId::of(methods::SUSPICIOUS_MAP), + LintId::of(methods::UNNECESSARY_FILTER_MAP), + LintId::of(methods::USELESS_ASREF), + LintId::of(misc::SHORT_CIRCUIT_STATEMENT), + LintId::of(misc_early::UNNEEDED_WILDCARD_PATTERN), + LintId::of(misc_early::ZERO_PREFIXED_LITERAL), + LintId::of(needless_arbitrary_self_type::NEEDLESS_ARBITRARY_SELF_TYPE), + LintId::of(needless_bool::BOOL_COMPARISON), + LintId::of(needless_bool::NEEDLESS_BOOL), + LintId::of(needless_borrowed_ref::NEEDLESS_BORROWED_REFERENCE), + LintId::of(needless_question_mark::NEEDLESS_QUESTION_MARK), + LintId::of(needless_update::NEEDLESS_UPDATE), + LintId::of(neg_cmp_op_on_partial_ord::NEG_CMP_OP_ON_PARTIAL_ORD), + LintId::of(no_effect::NO_EFFECT), + LintId::of(no_effect::UNNECESSARY_OPERATION), + LintId::of(overflow_check_conditional::OVERFLOW_CHECK_CONDITIONAL), + LintId::of(partialeq_ne_impl::PARTIALEQ_NE_IMPL), + LintId::of(precedence::PRECEDENCE), + LintId::of(ptr_offset_with_cast::PTR_OFFSET_WITH_CAST), + LintId::of(ranges::RANGE_ZIP_WITH_LEN), + LintId::of(redundant_closure_call::REDUNDANT_CLOSURE_CALL), + LintId::of(redundant_slicing::REDUNDANT_SLICING), + LintId::of(reference::DEREF_ADDROF), + LintId::of(reference::REF_IN_DEREF), + LintId::of(repeat_once::REPEAT_ONCE), + LintId::of(strings::STRING_FROM_UTF8_AS_BYTES), + LintId::of(swap::MANUAL_SWAP), + LintId::of(temporary_assignment::TEMPORARY_ASSIGNMENT), + LintId::of(transmute::CROSSPOINTER_TRANSMUTE), + LintId::of(transmute::TRANSMUTES_EXPRESSIBLE_AS_PTR_CASTS), + LintId::of(transmute::TRANSMUTE_BYTES_TO_STR), + LintId::of(transmute::TRANSMUTE_FLOAT_TO_INT), + LintId::of(transmute::TRANSMUTE_INT_TO_BOOL), + LintId::of(transmute::TRANSMUTE_INT_TO_CHAR), + LintId::of(transmute::TRANSMUTE_INT_TO_FLOAT), + LintId::of(transmute::TRANSMUTE_PTR_TO_PTR), + LintId::of(transmute::TRANSMUTE_PTR_TO_REF), + LintId::of(types::BORROWED_BOX), + LintId::of(types::TYPE_COMPLEXITY), + LintId::of(types::VEC_BOX), + LintId::of(unit_types::UNIT_ARG), + LintId::of(unnecessary_sort_by::UNNECESSARY_SORT_BY), + LintId::of(unwrap::UNNECESSARY_UNWRAP), + LintId::of(useless_conversion::USELESS_CONVERSION), + LintId::of(zero_div_zero::ZERO_DIVIDED_BY_ZERO), ]); store.register_group(true, "clippy::correctness", Some("clippy_correctness"), vec![ - LintId::of(&absurd_extreme_comparisons::ABSURD_EXTREME_COMPARISONS), - LintId::of(&approx_const::APPROX_CONSTANT), - LintId::of(&async_yields_async::ASYNC_YIELDS_ASYNC), - LintId::of(&atomic_ordering::INVALID_ATOMIC_ORDERING), - LintId::of(&attrs::DEPRECATED_SEMVER), - LintId::of(&attrs::MISMATCHED_TARGET_OS), - LintId::of(&attrs::USELESS_ATTRIBUTE), - LintId::of(&bit_mask::BAD_BIT_MASK), - LintId::of(&bit_mask::INEFFECTIVE_BIT_MASK), - LintId::of(&booleans::LOGIC_BUG), - LintId::of(&casts::CAST_REF_TO_MUT), - LintId::of(&copies::IFS_SAME_COND), - LintId::of(&copies::IF_SAME_THEN_ELSE), - LintId::of(&derive::DERIVE_HASH_XOR_EQ), - LintId::of(&derive::DERIVE_ORD_XOR_PARTIAL_ORD), - LintId::of(&drop_forget_ref::DROP_COPY), - LintId::of(&drop_forget_ref::DROP_REF), - LintId::of(&drop_forget_ref::FORGET_COPY), - LintId::of(&drop_forget_ref::FORGET_REF), - LintId::of(&enum_clike::ENUM_CLIKE_UNPORTABLE_VARIANT), - LintId::of(&eq_op::EQ_OP), - LintId::of(&erasing_op::ERASING_OP), - LintId::of(&float_equality_without_abs::FLOAT_EQUALITY_WITHOUT_ABS), - LintId::of(&formatting::POSSIBLE_MISSING_COMMA), - LintId::of(&functions::NOT_UNSAFE_PTR_ARG_DEREF), - LintId::of(&if_let_mutex::IF_LET_MUTEX), - LintId::of(&indexing_slicing::OUT_OF_BOUNDS_INDEXING), - LintId::of(&infinite_iter::INFINITE_ITER), - LintId::of(&inherent_to_string::INHERENT_TO_STRING_SHADOW_DISPLAY), - LintId::of(&inline_fn_without_body::INLINE_FN_WITHOUT_BODY), - LintId::of(&let_underscore::LET_UNDERSCORE_LOCK), - LintId::of(&literal_representation::MISTYPED_LITERAL_SUFFIXES), - LintId::of(&loops::FOR_LOOPS_OVER_FALLIBLES), - LintId::of(&loops::ITER_NEXT_LOOP), - LintId::of(&loops::NEVER_LOOP), - LintId::of(&loops::WHILE_IMMUTABLE_CONDITION), - LintId::of(&mem_discriminant::MEM_DISCRIMINANT_NON_ENUM), - LintId::of(&mem_replace::MEM_REPLACE_WITH_UNINIT), - LintId::of(&methods::CLONE_DOUBLE_REF), - LintId::of(&methods::ITERATOR_STEP_BY_ZERO), - LintId::of(&methods::UNINIT_ASSUMED_INIT), - LintId::of(&methods::ZST_OFFSET), - LintId::of(&minmax::MIN_MAX), - LintId::of(&misc::CMP_NAN), - LintId::of(&misc::FLOAT_CMP), - LintId::of(&misc::MODULO_ONE), - LintId::of(&mut_key::MUTABLE_KEY_TYPE), - LintId::of(&non_octal_unix_permissions::NON_OCTAL_UNIX_PERMISSIONS), - LintId::of(&open_options::NONSENSICAL_OPEN_OPTIONS), - LintId::of(&option_env_unwrap::OPTION_ENV_UNWRAP), - LintId::of(&ptr::MUT_FROM_REF), - LintId::of(&ranges::REVERSED_EMPTY_RANGES), - LintId::of(®ex::INVALID_REGEX), - LintId::of(&self_assignment::SELF_ASSIGNMENT), - LintId::of(&serde_api::SERDE_API_MISUSE), - LintId::of(&size_of_in_element_count::SIZE_OF_IN_ELEMENT_COUNT), - LintId::of(&suspicious_trait_impl::SUSPICIOUS_ARITHMETIC_IMPL), - LintId::of(&suspicious_trait_impl::SUSPICIOUS_OP_ASSIGN_IMPL), - LintId::of(&swap::ALMOST_SWAPPED), - LintId::of(&to_string_in_display::TO_STRING_IN_DISPLAY), - LintId::of(&transmute::UNSOUND_COLLECTION_TRANSMUTE), - LintId::of(&transmute::WRONG_TRANSMUTE), - LintId::of(&transmuting_null::TRANSMUTING_NULL), - LintId::of(&undropped_manually_drops::UNDROPPED_MANUALLY_DROPS), - LintId::of(&unicode::INVISIBLE_CHARACTERS), - LintId::of(&unit_return_expecting_ord::UNIT_RETURN_EXPECTING_ORD), - LintId::of(&unit_types::UNIT_CMP), - LintId::of(&unnamed_address::FN_ADDRESS_COMPARISONS), - LintId::of(&unnamed_address::VTABLE_ADDRESS_COMPARISONS), - LintId::of(&unused_io_amount::UNUSED_IO_AMOUNT), - LintId::of(&unwrap::PANICKING_UNWRAP), - LintId::of(&vec_resize_to_zero::VEC_RESIZE_TO_ZERO), + LintId::of(absurd_extreme_comparisons::ABSURD_EXTREME_COMPARISONS), + LintId::of(approx_const::APPROX_CONSTANT), + LintId::of(async_yields_async::ASYNC_YIELDS_ASYNC), + LintId::of(atomic_ordering::INVALID_ATOMIC_ORDERING), + LintId::of(attrs::DEPRECATED_SEMVER), + LintId::of(attrs::MISMATCHED_TARGET_OS), + LintId::of(attrs::USELESS_ATTRIBUTE), + LintId::of(bit_mask::BAD_BIT_MASK), + LintId::of(bit_mask::INEFFECTIVE_BIT_MASK), + LintId::of(booleans::LOGIC_BUG), + LintId::of(casts::CAST_REF_TO_MUT), + LintId::of(copies::IFS_SAME_COND), + LintId::of(copies::IF_SAME_THEN_ELSE), + LintId::of(derive::DERIVE_HASH_XOR_EQ), + LintId::of(derive::DERIVE_ORD_XOR_PARTIAL_ORD), + LintId::of(drop_forget_ref::DROP_COPY), + LintId::of(drop_forget_ref::DROP_REF), + LintId::of(drop_forget_ref::FORGET_COPY), + LintId::of(drop_forget_ref::FORGET_REF), + LintId::of(enum_clike::ENUM_CLIKE_UNPORTABLE_VARIANT), + LintId::of(eq_op::EQ_OP), + LintId::of(erasing_op::ERASING_OP), + LintId::of(float_equality_without_abs::FLOAT_EQUALITY_WITHOUT_ABS), + LintId::of(formatting::POSSIBLE_MISSING_COMMA), + LintId::of(functions::NOT_UNSAFE_PTR_ARG_DEREF), + LintId::of(if_let_mutex::IF_LET_MUTEX), + LintId::of(indexing_slicing::OUT_OF_BOUNDS_INDEXING), + LintId::of(infinite_iter::INFINITE_ITER), + LintId::of(inherent_to_string::INHERENT_TO_STRING_SHADOW_DISPLAY), + LintId::of(inline_fn_without_body::INLINE_FN_WITHOUT_BODY), + LintId::of(let_underscore::LET_UNDERSCORE_LOCK), + LintId::of(literal_representation::MISTYPED_LITERAL_SUFFIXES), + LintId::of(loops::FOR_LOOPS_OVER_FALLIBLES), + LintId::of(loops::ITER_NEXT_LOOP), + LintId::of(loops::NEVER_LOOP), + LintId::of(loops::WHILE_IMMUTABLE_CONDITION), + LintId::of(mem_discriminant::MEM_DISCRIMINANT_NON_ENUM), + LintId::of(mem_replace::MEM_REPLACE_WITH_UNINIT), + LintId::of(methods::CLONE_DOUBLE_REF), + LintId::of(methods::ITERATOR_STEP_BY_ZERO), + LintId::of(methods::UNINIT_ASSUMED_INIT), + LintId::of(methods::ZST_OFFSET), + LintId::of(minmax::MIN_MAX), + LintId::of(misc::CMP_NAN), + LintId::of(misc::FLOAT_CMP), + LintId::of(misc::MODULO_ONE), + LintId::of(mut_key::MUTABLE_KEY_TYPE), + LintId::of(non_octal_unix_permissions::NON_OCTAL_UNIX_PERMISSIONS), + LintId::of(open_options::NONSENSICAL_OPEN_OPTIONS), + LintId::of(option_env_unwrap::OPTION_ENV_UNWRAP), + LintId::of(ptr::MUT_FROM_REF), + LintId::of(ranges::REVERSED_EMPTY_RANGES), + LintId::of(regex::INVALID_REGEX), + LintId::of(self_assignment::SELF_ASSIGNMENT), + LintId::of(serde_api::SERDE_API_MISUSE), + LintId::of(size_of_in_element_count::SIZE_OF_IN_ELEMENT_COUNT), + LintId::of(suspicious_trait_impl::SUSPICIOUS_ARITHMETIC_IMPL), + LintId::of(suspicious_trait_impl::SUSPICIOUS_OP_ASSIGN_IMPL), + LintId::of(swap::ALMOST_SWAPPED), + LintId::of(to_string_in_display::TO_STRING_IN_DISPLAY), + LintId::of(transmute::UNSOUND_COLLECTION_TRANSMUTE), + LintId::of(transmute::WRONG_TRANSMUTE), + LintId::of(transmuting_null::TRANSMUTING_NULL), + LintId::of(undropped_manually_drops::UNDROPPED_MANUALLY_DROPS), + LintId::of(unicode::INVISIBLE_CHARACTERS), + LintId::of(unit_return_expecting_ord::UNIT_RETURN_EXPECTING_ORD), + LintId::of(unit_types::UNIT_CMP), + LintId::of(unnamed_address::FN_ADDRESS_COMPARISONS), + LintId::of(unnamed_address::VTABLE_ADDRESS_COMPARISONS), + LintId::of(unused_io_amount::UNUSED_IO_AMOUNT), + LintId::of(unwrap::PANICKING_UNWRAP), + LintId::of(vec_resize_to_zero::VEC_RESIZE_TO_ZERO), ]); store.register_group(true, "clippy::perf", Some("clippy_perf"), vec![ - LintId::of(&entry::MAP_ENTRY), - LintId::of(&escape::BOXED_LOCAL), - LintId::of(&large_const_arrays::LARGE_CONST_ARRAYS), - LintId::of(&large_enum_variant::LARGE_ENUM_VARIANT), - LintId::of(&loops::MANUAL_MEMCPY), - LintId::of(&loops::NEEDLESS_COLLECT), - LintId::of(&methods::EXPECT_FUN_CALL), - LintId::of(&methods::ITER_NTH), - LintId::of(&methods::OR_FUN_CALL), - LintId::of(&methods::SINGLE_CHAR_PATTERN), - LintId::of(&misc::CMP_OWNED), - LintId::of(&mutex_atomic::MUTEX_ATOMIC), - LintId::of(&redundant_clone::REDUNDANT_CLONE), - LintId::of(&slow_vector_initialization::SLOW_VECTOR_INITIALIZATION), - LintId::of(&stable_sort_primitive::STABLE_SORT_PRIMITIVE), - LintId::of(&types::BOX_VEC), - LintId::of(&types::REDUNDANT_ALLOCATION), - LintId::of(&vec::USELESS_VEC), - LintId::of(&vec_init_then_push::VEC_INIT_THEN_PUSH), + LintId::of(entry::MAP_ENTRY), + LintId::of(escape::BOXED_LOCAL), + LintId::of(large_const_arrays::LARGE_CONST_ARRAYS), + LintId::of(large_enum_variant::LARGE_ENUM_VARIANT), + LintId::of(loops::MANUAL_MEMCPY), + LintId::of(loops::NEEDLESS_COLLECT), + LintId::of(methods::EXPECT_FUN_CALL), + LintId::of(methods::ITER_NTH), + LintId::of(methods::OR_FUN_CALL), + LintId::of(methods::SINGLE_CHAR_PATTERN), + LintId::of(misc::CMP_OWNED), + LintId::of(mutex_atomic::MUTEX_ATOMIC), + LintId::of(redundant_clone::REDUNDANT_CLONE), + LintId::of(slow_vector_initialization::SLOW_VECTOR_INITIALIZATION), + LintId::of(stable_sort_primitive::STABLE_SORT_PRIMITIVE), + LintId::of(types::BOX_VEC), + LintId::of(types::REDUNDANT_ALLOCATION), + LintId::of(vec::USELESS_VEC), + LintId::of(vec_init_then_push::VEC_INIT_THEN_PUSH), ]); store.register_group(true, "clippy::cargo", Some("clippy_cargo"), vec![ - LintId::of(&cargo_common_metadata::CARGO_COMMON_METADATA), - LintId::of(&multiple_crate_versions::MULTIPLE_CRATE_VERSIONS), - LintId::of(&wildcard_dependencies::WILDCARD_DEPENDENCIES), + LintId::of(cargo_common_metadata::CARGO_COMMON_METADATA), + LintId::of(multiple_crate_versions::MULTIPLE_CRATE_VERSIONS), + LintId::of(wildcard_dependencies::WILDCARD_DEPENDENCIES), ]); store.register_group(true, "clippy::nursery", Some("clippy_nursery"), vec![ - LintId::of(&attrs::EMPTY_LINE_AFTER_OUTER_ATTR), - LintId::of(&cognitive_complexity::COGNITIVE_COMPLEXITY), - LintId::of(&disallowed_method::DISALLOWED_METHOD), - LintId::of(&fallible_impl_from::FALLIBLE_IMPL_FROM), - LintId::of(&floating_point_arithmetic::IMPRECISE_FLOPS), - LintId::of(&floating_point_arithmetic::SUBOPTIMAL_FLOPS), - LintId::of(&future_not_send::FUTURE_NOT_SEND), - LintId::of(&let_if_seq::USELESS_LET_IF_SEQ), - LintId::of(&missing_const_for_fn::MISSING_CONST_FOR_FN), - LintId::of(&mutable_debug_assertion::DEBUG_ASSERT_WITH_MUT_CALL), - LintId::of(&mutex_atomic::MUTEX_INTEGER), - LintId::of(&needless_borrow::NEEDLESS_BORROW), - LintId::of(&path_buf_push_overwrite::PATH_BUF_PUSH_OVERWRITE), - LintId::of(&redundant_pub_crate::REDUNDANT_PUB_CRATE), - LintId::of(®ex::TRIVIAL_REGEX), - LintId::of(&strings::STRING_LIT_AS_BYTES), - LintId::of(&transmute::USELESS_TRANSMUTE), - LintId::of(&use_self::USE_SELF), + LintId::of(attrs::EMPTY_LINE_AFTER_OUTER_ATTR), + LintId::of(cognitive_complexity::COGNITIVE_COMPLEXITY), + LintId::of(disallowed_method::DISALLOWED_METHOD), + LintId::of(fallible_impl_from::FALLIBLE_IMPL_FROM), + LintId::of(floating_point_arithmetic::IMPRECISE_FLOPS), + LintId::of(floating_point_arithmetic::SUBOPTIMAL_FLOPS), + LintId::of(future_not_send::FUTURE_NOT_SEND), + LintId::of(let_if_seq::USELESS_LET_IF_SEQ), + LintId::of(missing_const_for_fn::MISSING_CONST_FOR_FN), + LintId::of(mutable_debug_assertion::DEBUG_ASSERT_WITH_MUT_CALL), + LintId::of(mutex_atomic::MUTEX_INTEGER), + LintId::of(needless_borrow::NEEDLESS_BORROW), + LintId::of(path_buf_push_overwrite::PATH_BUF_PUSH_OVERWRITE), + LintId::of(redundant_pub_crate::REDUNDANT_PUB_CRATE), + LintId::of(regex::TRIVIAL_REGEX), + LintId::of(strings::STRING_LIT_AS_BYTES), + LintId::of(transmute::USELESS_TRANSMUTE), + LintId::of(use_self::USE_SELF), ]); } diff --git a/clippy_lints/src/lifetimes.rs b/clippy_lints/src/lifetimes.rs index e3b3fa21cab..116ad072837 100644 --- a/clippy_lints/src/lifetimes.rs +++ b/clippy_lints/src/lifetimes.rs @@ -81,7 +81,7 @@ declare_lint_pass!(Lifetimes => [NEEDLESS_LIFETIMES, EXTRA_UNUSED_LIFETIMES]); impl<'tcx> LateLintPass<'tcx> for Lifetimes { fn check_item(&mut self, cx: &LateContext<'tcx>, item: &'tcx Item<'_>) { if let ItemKind::Fn(ref sig, ref generics, id) = item.kind { - check_fn_inner(cx, &sig.decl, Some(id), generics, item.span, true); + check_fn_inner(cx, sig.decl, Some(id), generics, item.span, true); } } @@ -90,7 +90,7 @@ impl<'tcx> LateLintPass<'tcx> for Lifetimes { let report_extra_lifetimes = trait_ref_of_method(cx, item.hir_id()).is_none(); check_fn_inner( cx, - &sig.decl, + sig.decl, Some(id), &item.generics, item.span, @@ -105,7 +105,7 @@ impl<'tcx> LateLintPass<'tcx> for Lifetimes { TraitFn::Required(_) => None, TraitFn::Provided(id) => Some(id), }; - check_fn_inner(cx, &sig.decl, body, &item.generics, item.span, true); + check_fn_inner(cx, sig.decl, body, &item.generics, item.span, true); } } } @@ -149,7 +149,7 @@ fn check_fn_inner<'tcx>( .last() .expect("a path must have at least one segment") .args; - if let Some(ref params) = *params { + if let Some(params) = *params { let lifetimes = params.args.iter().filter_map(|arg| match arg { GenericArg::Lifetime(lt) => Some(lt), _ => None, @@ -163,7 +163,7 @@ fn check_fn_inner<'tcx>( } } } - if could_use_elision(cx, decl, body, &generics.params) { + if could_use_elision(cx, decl, body, generics.params) { span_lint( cx, NEEDLESS_LIFETIMES, @@ -201,7 +201,7 @@ fn could_use_elision<'tcx>( input_visitor.visit_ty(arg); } // extract lifetimes in output type - if let Return(ref ty) = func.output { + if let Return(ty) = func.output { output_visitor.visit_ty(ty); } for lt in named_generics { @@ -416,12 +416,12 @@ fn has_where_lifetimes<'tcx>(cx: &LateContext<'tcx>, where_clause: &'tcx WhereCl // a predicate like F: Trait or F: for<'a> Trait<'a> let mut visitor = RefVisitor::new(cx); // walk the type F, it may not contain LT refs - walk_ty(&mut visitor, &pred.bounded_ty); + walk_ty(&mut visitor, pred.bounded_ty); if !visitor.all_lts().is_empty() { return true; } // if the bounds define new lifetimes, they are fine to occur - let allowed_lts = allowed_lts_from(&pred.bound_generic_params); + let allowed_lts = allowed_lts_from(pred.bound_generic_params); // now walk the bounds for bound in pred.bounds.iter() { walk_param_bound(&mut visitor, bound); @@ -433,8 +433,8 @@ fn has_where_lifetimes<'tcx>(cx: &LateContext<'tcx>, where_clause: &'tcx WhereCl }, WherePredicate::EqPredicate(ref pred) => { let mut visitor = RefVisitor::new(cx); - walk_ty(&mut visitor, &pred.lhs_ty); - walk_ty(&mut visitor, &pred.rhs_ty); + walk_ty(&mut visitor, pred.lhs_ty); + walk_ty(&mut visitor, pred.rhs_ty); if !visitor.lts.is_empty() { return true; } diff --git a/clippy_lints/src/literal_representation.rs b/clippy_lints/src/literal_representation.rs index 7fd55151226..1d63af25803 100644 --- a/clippy_lints/src/literal_representation.rs +++ b/clippy_lints/src/literal_representation.rs @@ -248,7 +248,7 @@ impl LiteralDigitGrouping { fn check_lit(self, cx: &EarlyContext<'_>, lit: &Lit) { if_chain! { if let Some(src) = snippet_opt(cx, lit.span); - if let Some(mut num_lit) = NumericLiteral::from_lit(&src, &lit); + if let Some(mut num_lit) = NumericLiteral::from_lit(&src, lit); then { if !Self::check_for_mistyped_suffix(cx, lit.span, &mut num_lit) { return; @@ -438,7 +438,7 @@ impl DecimalLiteralRepresentation { if_chain! { if let LitKind::Int(val, _) = lit.kind; if let Some(src) = snippet_opt(cx, lit.span); - if let Some(num_lit) = NumericLiteral::from_lit(&src, &lit); + if let Some(num_lit) = NumericLiteral::from_lit(&src, lit); if num_lit.radix == Radix::Decimal; if val >= u128::from(self.threshold); then { diff --git a/clippy_lints/src/loops/explicit_counter_loop.rs b/clippy_lints/src/loops/explicit_counter_loop.rs index f14dbb1d642..98e60f7ed85 100644 --- a/clippy_lints/src/loops/explicit_counter_loop.rs +++ b/clippy_lints/src/loops/explicit_counter_loop.rs @@ -26,7 +26,7 @@ pub(super) fn check<'tcx>( // For each candidate, check the parent block to see if // it's initialized to zero at the start of the loop. - if let Some(block) = get_enclosing_block(&cx, expr.hir_id) { + if let Some(block) = get_enclosing_block(cx, expr.hir_id) { for id in increment_visitor.into_results() { let mut initialize_visitor = InitializeVisitor::new(cx, expr, id); walk_block(&mut initialize_visitor, block); diff --git a/clippy_lints/src/loops/for_kv_map.rs b/clippy_lints/src/loops/for_kv_map.rs index 8f18f54119b..666b8c58728 100644 --- a/clippy_lints/src/loops/for_kv_map.rs +++ b/clippy_lints/src/loops/for_kv_map.rs @@ -19,7 +19,7 @@ pub(super) fn check<'tcx>( ) { let pat_span = pat.span; - if let PatKind::Tuple(ref pat, _) = pat.kind { + if let PatKind::Tuple(pat, _) = pat.kind { if pat.len() == 2 { let arg_span = arg.span; let (new_pat_span, kind, ty, mutbl) = match *cx.typeck_results().expr_ty(arg).kind() { @@ -35,7 +35,7 @@ pub(super) fn check<'tcx>( Mutability::Mut => "_mut", }; let arg = match arg.kind { - ExprKind::AddrOf(BorrowKind::Ref, _, ref expr) => &**expr, + ExprKind::AddrOf(BorrowKind::Ref, _, expr) => expr, _ => arg, }; diff --git a/clippy_lints/src/loops/manual_flatten.rs b/clippy_lints/src/loops/manual_flatten.rs index 574ad8c0f29..94743cfcf46 100644 --- a/clippy_lints/src/loops/manual_flatten.rs +++ b/clippy_lints/src/loops/manual_flatten.rs @@ -18,7 +18,7 @@ pub(super) fn check<'tcx>( body: &'tcx Expr<'_>, span: Span, ) { - if let ExprKind::Block(ref block, _) = body.kind { + if let ExprKind::Block(block, _) = body.kind { // Ensure the `if let` statement is the only expression or statement in the for-loop let inner_expr = if block.stmts.len() == 1 && block.expr.is_none() { let match_stmt = &block.stmts[0]; @@ -36,7 +36,7 @@ pub(super) fn check<'tcx>( if_chain! { if let Some(inner_expr) = inner_expr; if let ExprKind::Match( - ref match_expr, ref match_arms, MatchSource::IfLetDesugar{ contains_else_clause: false } + match_expr, match_arms, MatchSource::IfLetDesugar{ contains_else_clause: false } ) = inner_expr.kind; // Ensure match_expr in `if let` statement is the same as the pat from the for-loop if let PatKind::Binding(_, pat_hir_id, _, _) = pat.kind; diff --git a/clippy_lints/src/loops/manual_memcpy.rs b/clippy_lints/src/loops/manual_memcpy.rs index 3c5abb7a3c4..47005aba388 100644 --- a/clippy_lints/src/loops/manual_memcpy.rs +++ b/clippy_lints/src/loops/manual_memcpy.rs @@ -63,8 +63,8 @@ pub(super) fn check<'tcx>( if let ExprKind::Index(base_right, idx_right) = rhs.kind; if is_slice_like(cx, cx.typeck_results().expr_ty(base_left)); if is_slice_like(cx, cx.typeck_results().expr_ty(base_right)); - if let Some((start_left, offset_left)) = get_details_from_idx(cx, &idx_left, &starts); - if let Some((start_right, offset_right)) = get_details_from_idx(cx, &idx_right, &starts); + if let Some((start_left, offset_left)) = get_details_from_idx(cx, idx_left, &starts); + if let Some((start_right, offset_right)) = get_details_from_idx(cx, idx_right, &starts); // Source and destination must be different if path_to_local(base_left) != path_to_local(base_right); @@ -168,8 +168,8 @@ fn build_manual_memcpy_suggestion<'tcx>( }, }; - let (dst_offset, dst_limit) = print_offset_and_limit(&dst); - let (src_offset, src_limit) = print_offset_and_limit(&src); + let (dst_offset, dst_limit) = print_offset_and_limit(dst); + let (src_offset, src_limit) = print_offset_and_limit(src); let dst_base_str = snippet(cx, dst.base.span, "???"); let src_base_str = snippet(cx, src.base.span, "???"); @@ -435,7 +435,7 @@ fn get_loop_counters<'a, 'tcx>( // For each candidate, check the parent block to see if // it's initialized to zero at the start of the loop. - get_enclosing_block(&cx, expr.hir_id).and_then(|block| { + get_enclosing_block(cx, expr.hir_id).and_then(|block| { increment_visitor .into_results() .filter_map(move |var_id| { diff --git a/clippy_lints/src/loops/mod.rs b/clippy_lints/src/loops/mod.rs index 20291491998..28acefd51fe 100644 --- a/clippy_lints/src/loops/mod.rs +++ b/clippy_lints/src/loops/mod.rs @@ -562,7 +562,7 @@ impl<'tcx> LateLintPass<'tcx> for Loops { // check for `loop { if let {} else break }` that could be `while let` // (also matches an explicit "match" instead of "if let") // (even if the "match" or "if let" is used for declaration) - if let ExprKind::Loop(ref block, _, LoopSource::Loop, _) = expr.kind { + if let ExprKind::Loop(block, _, LoopSource::Loop, _) = expr.kind { // also check for empty `loop {}` statements, skipping those in #[panic_handler] empty_loop::check(cx, expr, block); while_let_loop::check(cx, expr, block); @@ -570,7 +570,7 @@ impl<'tcx> LateLintPass<'tcx> for Loops { while_let_on_iterator::check(cx, expr); - if let Some((cond, body)) = higher::while_loop(&expr) { + if let Some((cond, body)) = higher::while_loop(expr) { while_immutable_condition::check(cx, cond, body); } @@ -602,7 +602,7 @@ fn check_for_loop<'tcx>( fn check_for_loop_arg(cx: &LateContext<'_>, pat: &Pat<'_>, arg: &Expr<'_>, expr: &Expr<'_>) { let mut next_loop_linted = false; // whether or not ITER_NEXT_LOOP lint was used - if let ExprKind::MethodCall(ref method, _, ref args, _) = arg.kind { + if let ExprKind::MethodCall(method, _, args, _) = arg.kind { // just the receiver, no arguments if args.len() == 1 { let method_name = &*method.ident.as_str(); diff --git a/clippy_lints/src/loops/needless_collect.rs b/clippy_lints/src/loops/needless_collect.rs index e0c5caf5136..4d73aef76e8 100644 --- a/clippy_lints/src/loops/needless_collect.rs +++ b/clippy_lints/src/loops/needless_collect.rs @@ -21,10 +21,10 @@ pub(super) fn check<'tcx>(expr: &'tcx Expr<'_>, cx: &LateContext<'tcx>) { } fn check_needless_collect_direct_usage<'tcx>(expr: &'tcx Expr<'_>, cx: &LateContext<'tcx>) { if_chain! { - if let ExprKind::MethodCall(ref method, _, ref args, _) = expr.kind; - if let ExprKind::MethodCall(ref chain_method, method0_span, _, _) = args[0].kind; + if let ExprKind::MethodCall(method, _, args, _) = expr.kind; + if let ExprKind::MethodCall(chain_method, method0_span, _, _) = args[0].kind; if chain_method.ident.name == sym!(collect) && is_trait_method(cx, &args[0], sym::Iterator); - if let Some(ref generic_args) = chain_method.args; + if let Some(generic_args) = chain_method.args; if let Some(GenericArg::Type(ref ty)) = generic_args.args.get(0); let ty = cx.typeck_results().node_type(ty.hir_id); if is_type_diagnostic_item(cx, ty, sym::vec_type) @@ -58,16 +58,16 @@ fn check_needless_collect_direct_usage<'tcx>(expr: &'tcx Expr<'_>, cx: &LateCont } fn check_needless_collect_indirect_usage<'tcx>(expr: &'tcx Expr<'_>, cx: &LateContext<'tcx>) { - if let ExprKind::Block(ref block, _) = expr.kind { - for ref stmt in block.stmts { + if let ExprKind::Block(block, _) = expr.kind { + for stmt in block.stmts { if_chain! { if let StmtKind::Local( Local { pat: Pat { hir_id: pat_id, kind: PatKind::Binding(_, _, ident, .. ), .. }, - init: Some(ref init_expr), .. } + init: Some(init_expr), .. } ) = stmt.kind; - if let ExprKind::MethodCall(ref method_name, collect_span, &[ref iter_source], ..) = init_expr.kind; - if method_name.ident.name == sym!(collect) && is_trait_method(cx, &init_expr, sym::Iterator); - if let Some(ref generic_args) = method_name.args; + if let ExprKind::MethodCall(method_name, collect_span, &[ref iter_source], ..) = init_expr.kind; + if method_name.ident.name == sym!(collect) && is_trait_method(cx, init_expr, sym::Iterator); + if let Some(generic_args) = method_name.args; if let Some(GenericArg::Type(ref ty)) = generic_args.args.get(0); if let ty = cx.typeck_results().node_type(ty.hir_id); if is_type_diagnostic_item(cx, ty, sym::vec_type) || @@ -165,8 +165,8 @@ impl<'tcx> Visitor<'tcx> for IterFunctionVisitor { fn visit_expr(&mut self, expr: &'tcx Expr<'tcx>) { // Check function calls on our collection if_chain! { - if let ExprKind::MethodCall(method_name, _, ref args, _) = &expr.kind; - if let Some(Expr { kind: ExprKind::Path(QPath::Resolved(_, ref path)), .. }) = args.get(0); + if let ExprKind::MethodCall(method_name, _, args, _) = &expr.kind; + if let Some(Expr { kind: ExprKind::Path(QPath::Resolved(_, path)), .. }) = args.get(0); if let &[name] = &path.segments; if name.ident == self.target; then { @@ -193,7 +193,7 @@ impl<'tcx> Visitor<'tcx> for IterFunctionVisitor { } // Check if the collection is used for anything else if_chain! { - if let Expr { kind: ExprKind::Path(QPath::Resolved(_, ref path)), .. } = expr; + if let Expr { kind: ExprKind::Path(QPath::Resolved(_, path)), .. } = expr; if let &[name] = &path.segments; if name.ident == self.target; then { diff --git a/clippy_lints/src/loops/needless_range_loop.rs b/clippy_lints/src/loops/needless_range_loop.rs index 60afa449a45..56141fb3837 100644 --- a/clippy_lints/src/loops/needless_range_loop.rs +++ b/clippy_lints/src/loops/needless_range_loop.rs @@ -96,7 +96,7 @@ pub(super) fn check<'tcx>( let take = if let Some(end) = *end { let mut take_expr = end; - if let ExprKind::Binary(ref op, ref left, ref right) = end.kind { + if let ExprKind::Binary(ref op, left, right) = end.kind { if let BinOpKind::Add = op.node { let start_equal_left = SpanlessEq::new(cx).eq_expr(start, left); let start_equal_right = SpanlessEq::new(cx).eq_expr(start, right); @@ -190,10 +190,10 @@ pub(super) fn check<'tcx>( fn is_len_call(expr: &Expr<'_>, var: Symbol) -> bool { if_chain! { - if let ExprKind::MethodCall(ref method, _, ref len_args, _) = expr.kind; + if let ExprKind::MethodCall(method, _, len_args, _) = expr.kind; if len_args.len() == 1; if method.ident.name == sym!(len); - if let ExprKind::Path(QPath::Resolved(_, ref path)) = len_args[0].kind; + if let ExprKind::Path(QPath::Resolved(_, path)) = len_args[0].kind; if path.segments.len() == 1; if path.segments[0].ident.name == var; then { @@ -254,7 +254,7 @@ impl<'a, 'tcx> VarVisitor<'a, 'tcx> { if_chain! { // the indexed container is referenced by a name if let ExprKind::Path(ref seqpath) = seqexpr.kind; - if let QPath::Resolved(None, ref seqvar) = *seqpath; + if let QPath::Resolved(None, seqvar) = *seqpath; if seqvar.segments.len() == 1; let index_used_directly = path_to_local_id(idx, self.var); let indexed_indirectly = { @@ -310,7 +310,7 @@ impl<'a, 'tcx> Visitor<'tcx> for VarVisitor<'a, 'tcx> { fn visit_expr(&mut self, expr: &'tcx Expr<'_>) { if_chain! { // a range index op - if let ExprKind::MethodCall(ref meth, _, ref args, _) = expr.kind; + if let ExprKind::MethodCall(meth, _, args, _) = expr.kind; if (meth.ident.name == sym::index && match_trait_method(self.cx, expr, &paths::INDEX)) || (meth.ident.name == sym::index_mut && match_trait_method(self.cx, expr, &paths::INDEX_MUT)); if !self.check(&args[1], &args[0], expr); @@ -319,7 +319,7 @@ impl<'a, 'tcx> Visitor<'tcx> for VarVisitor<'a, 'tcx> { if_chain! { // an index op - if let ExprKind::Index(ref seqexpr, ref idx) = expr.kind; + if let ExprKind::Index(seqexpr, idx) = expr.kind; if !self.check(idx, seqexpr, expr); then { return } } @@ -340,19 +340,19 @@ impl<'a, 'tcx> Visitor<'tcx> for VarVisitor<'a, 'tcx> { let old = self.prefer_mutable; match expr.kind { - ExprKind::AssignOp(_, ref lhs, ref rhs) | ExprKind::Assign(ref lhs, ref rhs, _) => { + ExprKind::AssignOp(_, lhs, rhs) | ExprKind::Assign(lhs, rhs, _) => { self.prefer_mutable = true; self.visit_expr(lhs); self.prefer_mutable = false; self.visit_expr(rhs); }, - ExprKind::AddrOf(BorrowKind::Ref, mutbl, ref expr) => { + ExprKind::AddrOf(BorrowKind::Ref, mutbl, expr) => { if mutbl == Mutability::Mut { self.prefer_mutable = true; } self.visit_expr(expr); }, - ExprKind::Call(ref f, args) => { + ExprKind::Call(f, args) => { self.visit_expr(f); for expr in args { let ty = self.cx.typeck_results().expr_ty_adjusted(expr); diff --git a/clippy_lints/src/loops/never_loop.rs b/clippy_lints/src/loops/never_loop.rs index f63a3761a0d..e2cb4638018 100644 --- a/clippy_lints/src/loops/never_loop.rs +++ b/clippy_lints/src/loops/never_loop.rs @@ -5,7 +5,7 @@ use rustc_lint::LateContext; use std::iter::{once, Iterator}; pub(super) fn check(cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) { - if let ExprKind::Loop(ref block, _, _, _) = expr.kind { + if let ExprKind::Loop(block, _, _, _) = expr.kind { match never_loop_block(block, expr.hir_id) { NeverLoopResult::AlwaysBreak => span_lint(cx, NEVER_LOOP, expr.span, "this loop never actually loops"), NeverLoopResult::MayContinueMainLoop | NeverLoopResult::Otherwise => (), @@ -76,36 +76,36 @@ fn never_loop_expr_seq<'a, T: Iterator>>(es: &mut T, main_lo fn stmt_to_expr<'tcx>(stmt: &Stmt<'tcx>) -> Option<&'tcx Expr<'tcx>> { match stmt.kind { - StmtKind::Semi(ref e, ..) | StmtKind::Expr(ref e, ..) => Some(e), - StmtKind::Local(ref local) => local.init.as_deref(), + StmtKind::Semi(e, ..) | StmtKind::Expr(e, ..) => Some(e), + StmtKind::Local(local) => local.init.as_deref(), StmtKind::Item(..) => None, } } fn never_loop_expr(expr: &Expr<'_>, main_loop_id: HirId) -> NeverLoopResult { match expr.kind { - ExprKind::Box(ref e) - | ExprKind::Unary(_, ref e) - | ExprKind::Cast(ref e, _) - | ExprKind::Type(ref e, _) - | ExprKind::Field(ref e, _) - | ExprKind::AddrOf(_, _, ref e) - | ExprKind::Struct(_, _, Some(ref e)) - | ExprKind::Repeat(ref e, _) - | ExprKind::DropTemps(ref e) => never_loop_expr(e, main_loop_id), - ExprKind::Array(ref es) | ExprKind::MethodCall(_, _, ref es, _) | ExprKind::Tup(ref es) => { + ExprKind::Box(e) + | ExprKind::Unary(_, e) + | ExprKind::Cast(e, _) + | ExprKind::Type(e, _) + | ExprKind::Field(e, _) + | ExprKind::AddrOf(_, _, e) + | ExprKind::Struct(_, _, Some(e)) + | ExprKind::Repeat(e, _) + | ExprKind::DropTemps(e) => never_loop_expr(e, main_loop_id), + ExprKind::Array(es) | ExprKind::MethodCall(_, _, es, _) | ExprKind::Tup(es) => { never_loop_expr_all(&mut es.iter(), main_loop_id) }, - ExprKind::Call(ref e, ref es) => never_loop_expr_all(&mut once(&**e).chain(es.iter()), main_loop_id), - ExprKind::Binary(_, ref e1, ref e2) - | ExprKind::Assign(ref e1, ref e2, _) - | ExprKind::AssignOp(_, ref e1, ref e2) - | ExprKind::Index(ref e1, ref e2) => never_loop_expr_all(&mut [&**e1, &**e2].iter().cloned(), main_loop_id), - ExprKind::Loop(ref b, _, _, _) => { + ExprKind::Call(e, es) => never_loop_expr_all(&mut once(e).chain(es.iter()), main_loop_id), + ExprKind::Binary(_, e1, e2) + | ExprKind::Assign(e1, e2, _) + | ExprKind::AssignOp(_, e1, e2) + | ExprKind::Index(e1, e2) => never_loop_expr_all(&mut [e1, e2].iter().cloned(), main_loop_id), + ExprKind::Loop(b, _, _, _) => { // Break can come from the inner loop so remove them. absorb_break(&never_loop_block(b, main_loop_id)) }, - ExprKind::If(ref e, ref e2, ref e3) => { + ExprKind::If(e, e2, ref e3) => { let e1 = never_loop_expr(e, main_loop_id); let e2 = never_loop_expr(e2, main_loop_id); let e3 = e3 @@ -113,7 +113,7 @@ fn never_loop_expr(expr: &Expr<'_>, main_loop_id: HirId) -> NeverLoopResult { .map_or(NeverLoopResult::Otherwise, |e| never_loop_expr(e, main_loop_id)); combine_seq(e1, combine_branches(e2, e3)) }, - ExprKind::Match(ref e, ref arms, _) => { + ExprKind::Match(e, arms, _) => { let e = never_loop_expr(e, main_loop_id); if arms.is_empty() { e @@ -122,7 +122,7 @@ fn never_loop_expr(expr: &Expr<'_>, main_loop_id: HirId) -> NeverLoopResult { combine_seq(e, arms) } }, - ExprKind::Block(ref b, _) => never_loop_block(b, main_loop_id), + ExprKind::Block(b, _) => never_loop_block(b, main_loop_id), ExprKind::Continue(d) => { let id = d .target_id @@ -136,7 +136,7 @@ fn never_loop_expr(expr: &Expr<'_>, main_loop_id: HirId) -> NeverLoopResult { ExprKind::Break(_, ref e) | ExprKind::Ret(ref e) => e.as_ref().map_or(NeverLoopResult::AlwaysBreak, |e| { combine_seq(never_loop_expr(e, main_loop_id), NeverLoopResult::AlwaysBreak) }), - ExprKind::InlineAsm(ref asm) => asm + ExprKind::InlineAsm(asm) => asm .operands .iter() .map(|(o, _)| match o { diff --git a/clippy_lints/src/loops/same_item_push.rs b/clippy_lints/src/loops/same_item_push.rs index b3d784474c8..cb2c83e9029 100644 --- a/clippy_lints/src/loops/same_item_push.rs +++ b/clippy_lints/src/loops/same_item_push.rs @@ -161,7 +161,7 @@ impl<'a, 'tcx> Visitor<'tcx> for SameItemPushVisitor<'a, 'tcx> { if vec_push_option.is_none() { // Current statement is not a push so visit inside match &s.kind { - StmtKind::Expr(expr) | StmtKind::Semi(expr) => self.visit_expr(&expr), + StmtKind::Expr(expr) | StmtKind::Semi(expr) => self.visit_expr(expr), _ => {}, } } else { diff --git a/clippy_lints/src/loops/single_element_loop.rs b/clippy_lints/src/loops/single_element_loop.rs index 8451c1c6130..fc067e81bca 100644 --- a/clippy_lints/src/loops/single_element_loop.rs +++ b/clippy_lints/src/loops/single_element_loop.rs @@ -15,12 +15,12 @@ pub(super) fn check<'tcx>( expr: &'tcx Expr<'_>, ) { if_chain! { - if let ExprKind::AddrOf(BorrowKind::Ref, _, ref arg_expr) = arg.kind; + if let ExprKind::AddrOf(BorrowKind::Ref, _, arg_expr) = arg.kind; if let PatKind::Binding(.., target, _) = pat.kind; if let ExprKind::Array([arg_expression]) = arg_expr.kind; if let ExprKind::Path(ref list_item) = arg_expression.kind; if let Some(list_item_name) = single_segment_path(list_item).map(|ps| ps.ident.name); - if let ExprKind::Block(ref block, _) = body.kind; + if let ExprKind::Block(block, _) = body.kind; if !block.stmts.is_empty(); then { diff --git a/clippy_lints/src/loops/utils.rs b/clippy_lints/src/loops/utils.rs index fc287d51249..4db6644b9d7 100644 --- a/clippy_lints/src/loops/utils.rs +++ b/clippy_lints/src/loops/utils.rs @@ -65,7 +65,7 @@ impl<'a, 'tcx> Visitor<'tcx> for IncrementVisitor<'a, 'tcx> { } match parent.kind { - ExprKind::AssignOp(op, ref lhs, ref rhs) => { + ExprKind::AssignOp(op, lhs, rhs) => { if lhs.hir_id == expr.hir_id { *state = if op.node == BinOpKind::Add && is_integer_const(self.cx, rhs, 1) @@ -79,7 +79,7 @@ impl<'a, 'tcx> Visitor<'tcx> for IncrementVisitor<'a, 'tcx> { }; } }, - ExprKind::Assign(ref lhs, _, _) if lhs.hir_id == expr.hir_id => { + ExprKind::Assign(lhs, _, _) if lhs.hir_id == expr.hir_id => { *state = IncrementVisitorVarState::DontWarn }, ExprKind::AddrOf(BorrowKind::Ref, mutability, _) if mutability == Mutability::Mut => { @@ -153,7 +153,7 @@ impl<'a, 'tcx> Visitor<'tcx> for InitializeVisitor<'a, 'tcx> { fn visit_stmt(&mut self, stmt: &'tcx Stmt<'_>) { // Look for declarations of the variable if_chain! { - if let StmtKind::Local(ref local) = stmt.kind; + if let StmtKind::Local(local) = stmt.kind; if local.pat.hir_id == self.var_id; if let PatKind::Binding(.., ident, _) = local.pat.kind; then { @@ -191,10 +191,10 @@ impl<'a, 'tcx> Visitor<'tcx> for InitializeVisitor<'a, 'tcx> { if let Some(parent) = get_parent_expr(self.cx, expr) { match parent.kind { - ExprKind::AssignOp(_, ref lhs, _) if lhs.hir_id == expr.hir_id => { + ExprKind::AssignOp(_, lhs, _) if lhs.hir_id == expr.hir_id => { self.state = InitializeVisitorState::DontWarn; }, - ExprKind::Assign(ref lhs, ref rhs, _) if lhs.hir_id == expr.hir_id => { + ExprKind::Assign(lhs, rhs, _) if lhs.hir_id == expr.hir_id => { self.state = if_chain! { if self.depth == 0; if let InitializeVisitorState::Declared(name) @@ -273,7 +273,7 @@ impl<'tcx> Visitor<'tcx> for LoopNestVisitor { return; } match expr.kind { - ExprKind::Assign(ref path, _, _) | ExprKind::AssignOp(_, ref path, _) => { + ExprKind::Assign(path, _, _) | ExprKind::AssignOp(_, path, _) => { if path_to_local_id(path, self.iterator) { self.nesting = RuledOut; } @@ -327,7 +327,7 @@ pub(super) fn make_iterator_snippet(cx: &LateContext<'_>, arg: &Expr<'_>, applic // (&mut x).into_iter() ==> x.iter_mut() match &arg.kind { ExprKind::AddrOf(BorrowKind::Ref, mutability, arg_inner) - if has_iter_method(cx, cx.typeck_results().expr_ty(&arg_inner)).is_some() => + if has_iter_method(cx, cx.typeck_results().expr_ty(arg_inner)).is_some() => { let meth_name = match mutability { Mutability::Mut => "iter_mut", @@ -335,7 +335,7 @@ pub(super) fn make_iterator_snippet(cx: &LateContext<'_>, arg: &Expr<'_>, applic }; format!( "{}.{}()", - sugg::Sugg::hir_with_applicability(cx, &arg_inner, "_", applic_ref).maybe_par(), + sugg::Sugg::hir_with_applicability(cx, arg_inner, "_", applic_ref).maybe_par(), meth_name, ) } diff --git a/clippy_lints/src/loops/while_let_loop.rs b/clippy_lints/src/loops/while_let_loop.rs index ffe8c0c5494..9c172079852 100644 --- a/clippy_lints/src/loops/while_let_loop.rs +++ b/clippy_lints/src/loops/while_let_loop.rs @@ -11,14 +11,14 @@ pub(super) fn check(cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>, loop_block: &' let inner_stmt_expr = extract_expr_from_first_stmt(loop_block); // or extract the first expression (if any) from the block if let Some(inner) = inner_stmt_expr.or_else(|| extract_first_expr(loop_block)) { - if let ExprKind::Match(ref matchexpr, ref arms, ref source) = inner.kind { + if let ExprKind::Match(matchexpr, arms, ref source) = inner.kind { // ensure "if let" compatible match structure match *source { MatchSource::Normal | MatchSource::IfLetDesugar { .. } => { if arms.len() == 2 && arms[0].guard.is_none() && arms[1].guard.is_none() - && is_simple_break_expr(&arms[1].body) + && is_simple_break_expr(arms[1].body) { if in_external_macro(cx.sess(), expr.span) { return; @@ -57,7 +57,7 @@ fn extract_expr_from_first_stmt<'tcx>(block: &Block<'tcx>) -> Option<&'tcx Expr< if block.stmts.is_empty() { return None; } - if let StmtKind::Local(ref local) = block.stmts[0].kind { + if let StmtKind::Local(local) = block.stmts[0].kind { local.init //.map(|expr| expr) } else { None @@ -67,9 +67,9 @@ fn extract_expr_from_first_stmt<'tcx>(block: &Block<'tcx>) -> Option<&'tcx Expr< /// If a block begins with an expression (with or without semicolon), return it. fn extract_first_expr<'tcx>(block: &Block<'tcx>) -> Option<&'tcx Expr<'tcx>> { match block.expr { - Some(ref expr) if block.stmts.is_empty() => Some(expr), + Some(expr) if block.stmts.is_empty() => Some(expr), None if !block.stmts.is_empty() => match block.stmts[0].kind { - StmtKind::Expr(ref expr) | StmtKind::Semi(ref expr) => Some(expr), + StmtKind::Expr(expr) | StmtKind::Semi(expr) => Some(expr), StmtKind::Local(..) | StmtKind::Item(..) => None, }, _ => None, @@ -82,7 +82,7 @@ fn extract_first_expr<'tcx>(block: &Block<'tcx>) -> Option<&'tcx Expr<'tcx>> { fn is_simple_break_expr(expr: &Expr<'_>) -> bool { match expr.kind { ExprKind::Break(dest, ref passed_expr) if dest.label.is_none() && passed_expr.is_none() => true, - ExprKind::Block(ref b, _) => extract_first_expr(b).map_or(false, |subexpr| is_simple_break_expr(subexpr)), + ExprKind::Block(b, _) => extract_first_expr(b).map_or(false, |subexpr| is_simple_break_expr(subexpr)), _ => false, } } diff --git a/clippy_lints/src/loops/while_let_on_iterator.rs b/clippy_lints/src/loops/while_let_on_iterator.rs index 57fc6250a9a..82715d9bafa 100644 --- a/clippy_lints/src/loops/while_let_on_iterator.rs +++ b/clippy_lints/src/loops/while_let_on_iterator.rs @@ -16,12 +16,10 @@ use rustc_middle::hir::map::Map; use rustc_span::symbol::sym; pub(super) fn check(cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) { - if let ExprKind::Match(ref match_expr, ref arms, MatchSource::WhileLetDesugar) = expr.kind { + if let ExprKind::Match(match_expr, arms, MatchSource::WhileLetDesugar) = expr.kind { let pat = &arms[0].pat.kind; - if let ( - &PatKind::TupleStruct(ref qpath, ref pat_args, _), - &ExprKind::MethodCall(ref method_path, _, ref method_args, _), - ) = (pat, &match_expr.kind) + if let (&PatKind::TupleStruct(ref qpath, pat_args, _), &ExprKind::MethodCall(method_path, _, method_args, _)) = + (pat, &match_expr.kind) { let iter_expr = &method_args[0]; @@ -40,8 +38,8 @@ pub(super) fn check(cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) { && is_trait_method(cx, match_expr, sym::Iterator) && lhs_constructor.ident.name == sym::Some && (pat_args.is_empty() - || !is_refutable(cx, &pat_args[0]) - && !is_used_inside(cx, iter_expr, &arms[0].body) + || !is_refutable(cx, pat_args[0]) + && !is_used_inside(cx, iter_expr, arms[0].body) && !is_iterator_used_after_while_let(cx, iter_expr) && !is_nested(cx, expr, &method_args[0])) { diff --git a/clippy_lints/src/manual_strip.rs b/clippy_lints/src/manual_strip.rs index 9da37efddac..dfa464ddb81 100644 --- a/clippy_lints/src/manual_strip.rs +++ b/clippy_lints/src/manual_strip.rs @@ -91,7 +91,7 @@ impl<'tcx> LateLintPass<'tcx> for ManualStrip { } else { return; }; - let target_res = cx.qpath_res(&target_path, target_arg.hir_id); + let target_res = cx.qpath_res(target_path, target_arg.hir_id); if target_res == Res::Err { return; }; @@ -174,7 +174,7 @@ fn eq_pattern_length<'tcx>(cx: &LateContext<'tcx>, pattern: &Expr<'_>, expr: &'t // Tests if `expr` is a `&str`. fn is_ref_str(cx: &LateContext<'_>, expr: &Expr<'_>) -> bool { - match cx.typeck_results().expr_ty_adjusted(&expr).kind() { + match cx.typeck_results().expr_ty_adjusted(expr).kind() { ty::Ref(_, ty, _) => ty.is_str(), _ => false, } diff --git a/clippy_lints/src/map_clone.rs b/clippy_lints/src/map_clone.rs index 9f1ab1f695d..99c35ae3bbf 100644 --- a/clippy_lints/src/map_clone.rs +++ b/clippy_lints/src/map_clone.rs @@ -52,7 +52,7 @@ impl<'tcx> LateLintPass<'tcx> for MapClone { } if_chain! { - if let hir::ExprKind::MethodCall(ref method, _, ref args, _) = e.kind; + if let hir::ExprKind::MethodCall(method, _, args, _) = e.kind; if args.len() == 2; if method.ident.name == sym::map; let ty = cx.typeck_results().expr_ty(&args[0]); @@ -62,7 +62,7 @@ impl<'tcx> LateLintPass<'tcx> for MapClone { let closure_body = cx.tcx.hir().body(body_id); let closure_expr = remove_blocks(&closure_body.value); match closure_body.params[0].pat.kind { - hir::PatKind::Ref(ref inner, hir::Mutability::Not) => if let hir::PatKind::Binding( + hir::PatKind::Ref(inner, hir::Mutability::Not) => if let hir::PatKind::Binding( hir::BindingAnnotation::Unannotated, .., name, None ) = inner.kind { if ident_eq(name, closure_expr) { @@ -71,14 +71,14 @@ impl<'tcx> LateLintPass<'tcx> for MapClone { }, hir::PatKind::Binding(hir::BindingAnnotation::Unannotated, .., name, None) => { match closure_expr.kind { - hir::ExprKind::Unary(hir::UnOp::Deref, ref inner) => { + hir::ExprKind::Unary(hir::UnOp::Deref, inner) => { if ident_eq(name, inner) { if let ty::Ref(.., Mutability::Not) = cx.typeck_results().expr_ty(inner).kind() { lint(cx, e.span, args[0].span, true); } } }, - hir::ExprKind::MethodCall(ref method, _, [obj], _) => if_chain! { + hir::ExprKind::MethodCall(method, _, [obj], _) => if_chain! { if ident_eq(name, obj) && method.ident.name == sym::clone; if let Some(fn_id) = cx.typeck_results().type_dependent_def_id(closure_expr.hir_id); if let Some(trait_id) = cx.tcx.trait_of_item(fn_id); @@ -109,7 +109,7 @@ impl<'tcx> LateLintPass<'tcx> for MapClone { } fn ident_eq(name: Ident, path: &hir::Expr<'_>) -> bool { - if let hir::ExprKind::Path(hir::QPath::Resolved(None, ref path)) = path.kind { + if let hir::ExprKind::Path(hir::QPath::Resolved(None, path)) = path.kind { path.segments.len() == 1 && path.segments[0].ident == name } else { false diff --git a/clippy_lints/src/map_err_ignore.rs b/clippy_lints/src/map_err_ignore.rs index a6a63961be5..425a9734e5f 100644 --- a/clippy_lints/src/map_err_ignore.rs +++ b/clippy_lints/src/map_err_ignore.rs @@ -112,7 +112,7 @@ impl<'tcx> LateLintPass<'tcx> for MapErrIgnore { } // check if this is a method call (e.g. x.foo()) - if let ExprKind::MethodCall(ref method, _t_span, ref args, _) = e.kind { + if let ExprKind::MethodCall(method, _t_span, args, _) = e.kind { // only work if the method name is `map_err` and there are only 2 arguments (e.g. x.map_err(|_|[1] // Enum::Variant[2])) if method.ident.as_str() == "map_err" && args.len() == 2 { diff --git a/clippy_lints/src/map_identity.rs b/clippy_lints/src/map_identity.rs index 75191e1f9ee..e7719e7663d 100644 --- a/clippy_lints/src/map_identity.rs +++ b/clippy_lints/src/map_identity.rs @@ -61,7 +61,7 @@ impl<'tcx> LateLintPass<'tcx> for MapIdentity { /// map(). Otherwise, returns None. fn get_map_argument<'a>(cx: &LateContext<'_>, expr: &'a Expr<'a>) -> Option<&'a [Expr<'a>]> { if_chain! { - if let ExprKind::MethodCall(ref method, _, ref args, _) = expr.kind; + if let ExprKind::MethodCall(method, _, args, _) = expr.kind; if args.len() == 2 && method.ident.name == sym::map; let caller_ty = cx.typeck_results().expr_ty(&args[0]); if is_trait_method(cx, expr, sym::Iterator) @@ -80,7 +80,7 @@ fn get_map_argument<'a>(cx: &LateContext<'_>, expr: &'a Expr<'a>) -> Option<&'a fn is_expr_identity_function(cx: &LateContext<'_>, expr: &Expr<'_>) -> bool { match expr.kind { ExprKind::Closure(_, _, body_id, _, _) => is_body_identity_function(cx, cx.tcx.hir().body(body_id)), - ExprKind::Path(QPath::Resolved(_, ref path)) => match_path(path, &paths::STD_CONVERT_IDENTITY), + ExprKind::Path(QPath::Resolved(_, path)) => match_path(path, &paths::STD_CONVERT_IDENTITY), _ => false, } } @@ -99,12 +99,12 @@ fn is_body_identity_function(cx: &LateContext<'_>, func: &Body<'_>) -> bool { match body.kind { ExprKind::Path(QPath::Resolved(None, _)) => match_expr_param(cx, body, params[0].pat), - ExprKind::Ret(Some(ref ret_val)) => match_expr_param(cx, ret_val, params[0].pat), - ExprKind::Block(ref block, _) => { + ExprKind::Ret(Some(ret_val)) => match_expr_param(cx, ret_val, params[0].pat), + ExprKind::Block(block, _) => { if_chain! { if block.stmts.len() == 1; - if let StmtKind::Semi(ref expr) | StmtKind::Expr(ref expr) = block.stmts[0].kind; - if let ExprKind::Ret(Some(ref ret_val)) = expr.kind; + if let StmtKind::Semi(expr) | StmtKind::Expr(expr) = block.stmts[0].kind; + if let ExprKind::Ret(Some(ret_val)) = expr.kind; then { match_expr_param(cx, ret_val, params[0].pat) } else { diff --git a/clippy_lints/src/map_unit_fn.rs b/clippy_lints/src/map_unit_fn.rs index 5cc16244a0d..57cd907e77e 100644 --- a/clippy_lints/src/map_unit_fn.rs +++ b/clippy_lints/src/map_unit_fn.rs @@ -133,7 +133,7 @@ fn reduce_unit_expression<'a>(cx: &LateContext<'_>, expr: &'a hir::Expr<'_>) -> // Calls can't be reduced any more Some(expr.span) }, - hir::ExprKind::Block(ref block, _) => { + hir::ExprKind::Block(block, _) => { match (block.stmts, block.expr.as_ref()) { (&[], Some(inner_expr)) => { // If block only contains an expression, @@ -144,8 +144,8 @@ fn reduce_unit_expression<'a>(cx: &LateContext<'_>, expr: &'a hir::Expr<'_>) -> // If block only contains statements, // reduce `{ X; }` to `X` or `X;` match inner_stmt.kind { - hir::StmtKind::Local(ref local) => Some(local.span), - hir::StmtKind::Expr(ref e) => Some(e.span), + hir::StmtKind::Local(local) => Some(local.span), + hir::StmtKind::Expr(e) => Some(e.span), hir::StmtKind::Semi(..) => Some(inner_stmt.span), hir::StmtKind::Item(..) => None, } @@ -169,12 +169,12 @@ fn unit_closure<'tcx>( expr: &hir::Expr<'_>, ) -> Option<(&'tcx hir::Param<'tcx>, &'tcx hir::Expr<'tcx>)> { if_chain! { - if let hir::ExprKind::Closure(_, ref decl, inner_expr_id, _, _) = expr.kind; + if let hir::ExprKind::Closure(_, decl, inner_expr_id, _, _) = expr.kind; let body = cx.tcx.hir().body(inner_expr_id); let body_expr = &body.value; if decl.inputs.len() == 1; if is_unit_expression(cx, body_expr); - if let Some(binding) = iter_input_pats(&decl, body).next(); + if let Some(binding) = iter_input_pats(decl, body).next(); then { return Some((binding, body_expr)); } @@ -267,7 +267,7 @@ impl<'tcx> LateLintPass<'tcx> for MapUnit { return; } - if let hir::StmtKind::Semi(ref expr) = stmt.kind { + if let hir::StmtKind::Semi(expr) = stmt.kind { if let Some(arglists) = method_chain_args(expr, &["map"]) { lint_map_unit_fn(cx, stmt, expr, arglists[0]); } diff --git a/clippy_lints/src/match_on_vec_items.rs b/clippy_lints/src/match_on_vec_items.rs index ccaa5e98c83..ca6fb0831fe 100644 --- a/clippy_lints/src/match_on_vec_items.rs +++ b/clippy_lints/src/match_on_vec_items.rs @@ -51,7 +51,7 @@ impl<'tcx> LateLintPass<'tcx> for MatchOnVecItems { fn check_expr(&mut self, cx: &LateContext<'tcx>, expr: &'tcx Expr<'tcx>) { if_chain! { if !in_external_macro(cx.sess(), expr.span); - if let ExprKind::Match(ref match_expr, _, MatchSource::Normal) = expr.kind; + if let ExprKind::Match(match_expr, _, MatchSource::Normal) = expr.kind; if let Some(idx_expr) = is_vec_indexing(cx, match_expr); if let ExprKind::Index(vec, idx) = idx_expr.kind; @@ -78,7 +78,7 @@ impl<'tcx> LateLintPass<'tcx> for MatchOnVecItems { fn is_vec_indexing<'tcx>(cx: &LateContext<'tcx>, expr: &'tcx Expr<'tcx>) -> Option<&'tcx Expr<'tcx>> { if_chain! { - if let ExprKind::Index(ref array, ref index) = expr.kind; + if let ExprKind::Index(array, index) = expr.kind; if is_vector(cx, array); if !is_full_range(cx, index); diff --git a/clippy_lints/src/matches.rs b/clippy_lints/src/matches.rs index c68ae00be01..a892e24482b 100644 --- a/clippy_lints/src/matches.rs +++ b/clippy_lints/src/matches.rs @@ -589,7 +589,7 @@ impl<'tcx> LateLintPass<'tcx> for Matches { lint_match_arms(cx, expr); } - if let ExprKind::Match(ref ex, ref arms, MatchSource::Normal) = expr.kind { + if let ExprKind::Match(ex, arms, MatchSource::Normal) = expr.kind { check_single_match(cx, ex, arms, expr); check_match_bool(cx, ex, arms, expr); check_overlapping_arms(cx, ex, arms); @@ -604,7 +604,7 @@ impl<'tcx> LateLintPass<'tcx> for Matches { check_match_single_binding(cx, ex, arms, expr); } } - if let ExprKind::Match(ref ex, ref arms, _) = expr.kind { + if let ExprKind::Match(ex, arms, _) = expr.kind { check_match_ref_pats(cx, ex, arms, expr); } } @@ -613,14 +613,14 @@ impl<'tcx> LateLintPass<'tcx> for Matches { if_chain! { if !in_external_macro(cx.sess(), local.span); if !in_macro(local.span); - if let Some(ref expr) = local.init; - if let ExprKind::Match(ref target, ref arms, MatchSource::Normal) = expr.kind; + if let Some(expr) = local.init; + if let ExprKind::Match(target, arms, MatchSource::Normal) = expr.kind; if arms.len() == 1 && arms[0].guard.is_none(); if let PatKind::TupleStruct( - QPath::Resolved(None, ref variant_name), ref args, _) = arms[0].pat.kind; + QPath::Resolved(None, variant_name), args, _) = arms[0].pat.kind; if args.len() == 1; - if let PatKind::Binding(_, arg, ..) = strip_pat_refs(&args[0]).kind; - let body = remove_blocks(&arms[0].body); + if let PatKind::Binding(_, arg, ..) = strip_pat_refs(args[0]).kind; + let body = remove_blocks(arms[0].body); if path_to_local_id(body, arg); then { @@ -649,7 +649,7 @@ impl<'tcx> LateLintPass<'tcx> for Matches { if_chain! { if !in_external_macro(cx.sess(), pat.span); if !in_macro(pat.span); - if let PatKind::Struct(QPath::Resolved(_, ref path), fields, true) = pat.kind; + if let PatKind::Struct(QPath::Resolved(_, path), fields, true) = pat.kind; if let Some(def_id) = path.res.opt_def_id(); let ty = cx.tcx.type_of(def_id); if let ty::Adt(def, _) = ty.kind(); @@ -761,7 +761,7 @@ fn report_single_match_single_pattern( // PartialEq for different reference counts may not exist. "&".repeat(ref_count_diff), snippet(cx, arms[0].pat.span, ".."), - expr_block(cx, &arms[0].body, None, "..", Some(expr.span)), + expr_block(cx, arms[0].body, None, "..", Some(expr.span)), els_str, ); (msg, sugg) @@ -771,7 +771,7 @@ fn report_single_match_single_pattern( "if let {} = {} {}{}", snippet(cx, arms[0].pat.span, ".."), snippet(cx, ex.span, ".."), - expr_block(cx, &arms[0].body, None, "..", Some(expr.span)), + expr_block(cx, arms[0].body, None, "..", Some(expr.span)), els_str, ); (msg, sugg) @@ -809,7 +809,7 @@ fn check_single_match_opt_like( ]; let path = match arms[1].pat.kind { - PatKind::TupleStruct(ref path, ref inner, _) => { + PatKind::TupleStruct(ref path, inner, _) => { // Contains any non wildcard patterns (e.g., `Err(err)`)? if !inner.iter().all(is_wild) { return; @@ -841,7 +841,7 @@ fn check_match_bool(cx: &LateContext<'_>, ex: &Expr<'_>, arms: &[Arm<'_>], expr: move |diag| { if arms.len() == 2 { // no guards - let exprs = if let PatKind::Lit(ref arm_bool) = arms[0].pat.kind { + let exprs = if let PatKind::Lit(arm_bool) = arms[0].pat.kind { if let ExprKind::Lit(ref lit) = arm_bool.kind { match lit.node { LitKind::Bool(true) => Some((&*arms[0].body, &*arms[1].body)), @@ -917,7 +917,7 @@ fn check_wild_err_arm<'tcx>(cx: &LateContext<'tcx>, ex: &Expr<'tcx>, arms: &[Arm let ex_ty = cx.typeck_results().expr_ty(ex).peel_refs(); if is_type_diagnostic_item(cx, ex_ty, sym::result_type) { for arm in arms { - if let PatKind::TupleStruct(ref path, ref inner, _) = arm.pat.kind { + if let PatKind::TupleStruct(ref path, inner, _) = arm.pat.kind { let path_str = rustc_hir_pretty::to_string(rustc_hir_pretty::NO_ANN, |s| s.print_qpath(path, false)); if path_str == "Err" { let mut matching_wild = inner.iter().any(is_wild); @@ -937,7 +937,7 @@ fn check_wild_err_arm<'tcx>(cx: &LateContext<'tcx>, ex: &Expr<'tcx>, arms: &[Arm } if_chain! { if matching_wild; - if let ExprKind::Block(ref block, _) = arm.body.kind; + if let ExprKind::Block(block, _) = arm.body.kind; if is_panic_block(block); then { // `Err(_)` or `Err(_e)` arm with `panic!` found @@ -1143,9 +1143,7 @@ fn check_wild_enum_match(cx: &LateContext<'_>, ex: &Expr<'_>, arms: &[Arm<'_>]) // If the block contains only a `panic!` macro (as expression or statement) fn is_panic_block(block: &Block<'_>) -> bool { match (&block.expr, block.stmts.len(), block.stmts.first()) { - (&Some(ref exp), 0, _) => { - is_expn_of(exp.span, "panic").is_some() && is_expn_of(exp.span, "unreachable").is_none() - }, + (&Some(exp), 0, _) => is_expn_of(exp.span, "panic").is_some() && is_expn_of(exp.span, "unreachable").is_none(), (&None, 1, Some(stmt)) => { is_expn_of(stmt.span, "panic").is_some() && is_expn_of(stmt.span, "unreachable").is_none() }, @@ -1156,7 +1154,7 @@ fn is_panic_block(block: &Block<'_>) -> bool { fn check_match_ref_pats(cx: &LateContext<'_>, ex: &Expr<'_>, arms: &[Arm<'_>], expr: &Expr<'_>) { if has_only_ref_pats(arms) { let mut suggs = Vec::with_capacity(arms.len() + 1); - let (title, msg) = if let ExprKind::AddrOf(BorrowKind::Ref, Mutability::Not, ref inner) = ex.kind { + let (title, msg) = if let ExprKind::AddrOf(BorrowKind::Ref, Mutability::Not, inner) = ex.kind { let span = ex.span.source_callsite(); suggs.push((span, Sugg::hir_with_macro_callsite(cx, inner, "..").to_string())); ( @@ -1173,7 +1171,7 @@ fn check_match_ref_pats(cx: &LateContext<'_>, ex: &Expr<'_>, arms: &[Arm<'_>], e }; suggs.extend(arms.iter().filter_map(|a| { - if let PatKind::Ref(ref refp, _) = a.pat.kind { + if let PatKind::Ref(refp, _) = a.pat.kind { Some((a.pat.span, snippet(cx, refp.span, "..").to_string())) } else { None @@ -1242,7 +1240,7 @@ fn check_match_as_ref(cx: &LateContext<'_>, ex: &Expr<'_>, arms: &[Arm<'_>], exp fn check_wild_in_or_pats(cx: &LateContext<'_>, arms: &[Arm<'_>]) { for arm in arms { - if let PatKind::Or(ref fields) = arm.pat.kind { + if let PatKind::Or(fields) = arm.pat.kind { // look for multiple fields in this arm that contains at least one Wild pattern if fields.len() > 1 && fields.iter().any(is_wild) { span_lint_and_help( @@ -1308,7 +1306,7 @@ fn find_matches_sugg(cx: &LateContext<'_>, ex: &Expr<'_>, arms: &[Arm<'_>], expr // strip potential borrows (#6503), but only if the type is a reference let mut ex_new = ex; if let ExprKind::AddrOf(BorrowKind::Ref, .., ex_inner) = ex.kind { - if let ty::Ref(..) = cx.typeck_results().expr_ty(&ex_inner).kind() { + if let ty::Ref(..) = cx.typeck_results().expr_ty(ex_inner).kind() { ex_new = ex_inner; } }; @@ -1385,7 +1383,7 @@ fn check_match_single_binding<'a>(cx: &LateContext<'a>, ex: &Expr<'a>, arms: &[A let matched_vars = ex.span; let bind_names = arms[0].pat.span; - let match_body = remove_blocks(&arms[0].body); + let match_body = remove_blocks(arms[0].body); let mut snippet_body = if match_body.span.from_expansion() { Sugg::hir_with_macro_callsite(cx, match_body, "..").to_string() } else { @@ -1396,13 +1394,13 @@ fn check_match_single_binding<'a>(cx: &LateContext<'a>, ex: &Expr<'a>, arms: &[A match match_body.kind { ExprKind::Block(block, _) => { // macro + expr_ty(body) == () - if block.span.from_expansion() && cx.typeck_results().expr_ty(&match_body).is_unit() { + if block.span.from_expansion() && cx.typeck_results().expr_ty(match_body).is_unit() { snippet_body.push(';'); } }, _ => { // expr_ty(body) == () - if cx.typeck_results().expr_ty(&match_body).is_unit() { + if cx.typeck_results().expr_ty(match_body).is_unit() { snippet_body.push(';'); } }, @@ -1502,10 +1500,7 @@ fn opt_parent_let<'a>(cx: &LateContext<'a>, ex: &Expr<'a>) -> Option<&'a Local<' fn all_ranges<'tcx>(cx: &LateContext<'tcx>, arms: &'tcx [Arm<'_>], ty: Ty<'tcx>) -> Vec> { arms.iter() .flat_map(|arm| { - if let Arm { - ref pat, guard: None, .. - } = *arm - { + if let Arm { pat, guard: None, .. } = *arm { if let PatKind::Range(ref lhs, ref rhs, range_end) = pat.kind { let lhs = match lhs { Some(lhs) => constant(cx, cx.typeck_results(), lhs)?.0, @@ -1525,7 +1520,7 @@ fn all_ranges<'tcx>(cx: &LateContext<'tcx>, arms: &'tcx [Arm<'_>], ty: Ty<'tcx>) }); } - if let PatKind::Lit(ref value) = pat.kind { + if let PatKind::Lit(value) = pat.kind { let value = constant(cx, cx.typeck_results(), value)?.0; return Some(SpannedRange { span: pat.span, @@ -1572,8 +1567,8 @@ fn type_ranges(ranges: &[SpannedRange]) -> TypedRanges { fn is_unit_expr(expr: &Expr<'_>) -> bool { match expr.kind { - ExprKind::Tup(ref v) if v.is_empty() => true, - ExprKind::Block(ref b, _) if b.stmts.is_empty() && b.expr.is_none() => true, + ExprKind::Tup(v) if v.is_empty() => true, + ExprKind::Block(b, _) if b.stmts.is_empty() && b.expr.is_none() => true, _ => false, } } @@ -1586,14 +1581,14 @@ fn is_none_arm(arm: &Arm<'_>) -> bool { // Checks if arm has the form `Some(ref v) => Some(v)` (checks for `ref` and `ref mut`) fn is_ref_some_arm(arm: &Arm<'_>) -> Option { if_chain! { - if let PatKind::TupleStruct(ref path, ref pats, _) = arm.pat.kind; + if let PatKind::TupleStruct(ref path, pats, _) = arm.pat.kind; if pats.len() == 1 && match_qpath(path, &paths::OPTION_SOME); if let PatKind::Binding(rb, .., ident, _) = pats[0].kind; if rb == BindingAnnotation::Ref || rb == BindingAnnotation::RefMut; - if let ExprKind::Call(ref e, ref args) = remove_blocks(&arm.body).kind; + if let ExprKind::Call(e, args) = remove_blocks(arm.body).kind; if let ExprKind::Path(ref some_path) = e.kind; if match_qpath(some_path, &paths::OPTION_SOME) && args.len() == 1; - if let ExprKind::Path(QPath::Resolved(_, ref path2)) = args[0].kind; + if let ExprKind::Path(QPath::Resolved(_, path2)) = args[0].kind; if path2.segments.len() == 1 && ident.name == path2.segments[0].ident.name; then { return Some(rb) @@ -1685,7 +1680,7 @@ where (&Kind::End(a, _), &Kind::Start(b, _)) if a != Bound::Included(b) => (), _ => { // skip if the range `a` is completely included into the range `b` - if let Ordering::Equal | Ordering::Less = a.cmp(&b) { + if let Ordering::Equal | Ordering::Less = a.cmp(b) { let kind_a = Kind::End(a.range().node.1, a.range()); let kind_b = Kind::End(b.range().node.1, b.range()); if let Ordering::Equal | Ordering::Greater = kind_a.cmp(&kind_b) { @@ -1737,7 +1732,7 @@ mod redundant_pattern_match { kind = &inner.kind; } let good_method = match kind { - PatKind::TupleStruct(ref path, ref patterns, _) if patterns.len() == 1 => { + PatKind::TupleStruct(ref path, patterns, _) if patterns.len() == 1 => { if let PatKind::Wild = patterns[0].kind { if match_qpath(path, &paths::RESULT_OK) { "is_ok()" @@ -1818,8 +1813,8 @@ mod redundant_pattern_match { let found_good_method = match node_pair { ( - PatKind::TupleStruct(ref path_left, ref patterns_left, _), - PatKind::TupleStruct(ref path_right, ref patterns_right, _), + PatKind::TupleStruct(ref path_left, patterns_left, _), + PatKind::TupleStruct(ref path_right, patterns_right, _), ) if patterns_left.len() == 1 && patterns_right.len() == 1 => { if let (PatKind::Wild, PatKind::Wild) = (&patterns_left[0].kind, &patterns_right[0].kind) { find_good_method_for_match( @@ -1846,8 +1841,8 @@ mod redundant_pattern_match { None } }, - (PatKind::TupleStruct(ref path_left, ref patterns, _), PatKind::Path(ref path_right)) - | (PatKind::Path(ref path_left), PatKind::TupleStruct(ref path_right, ref patterns, _)) + (PatKind::TupleStruct(ref path_left, patterns, _), PatKind::Path(ref path_right)) + | (PatKind::Path(ref path_left), PatKind::TupleStruct(ref path_right, patterns, _)) if patterns.len() == 1 => { if let PatKind::Wild = patterns[0].kind { @@ -1969,10 +1964,10 @@ fn test_overlapping() { /// Implementation of `MATCH_SAME_ARMS`. fn lint_match_arms<'tcx>(cx: &LateContext<'tcx>, expr: &Expr<'_>) { - if let ExprKind::Match(_, ref arms, MatchSource::Normal) = expr.kind { + if let ExprKind::Match(_, arms, MatchSource::Normal) = expr.kind { let hash = |&(_, arm): &(usize, &Arm<'_>)| -> u64 { let mut h = SpanlessHash::new(cx); - h.hash_expr(&arm.body); + h.hash_expr(arm.body); h.finish() }; @@ -2008,7 +2003,7 @@ fn lint_match_arms<'tcx>(cx: &LateContext<'tcx>, expr: &Expr<'_>) { (min_index..=max_index).all(|index| arms[index].guard.is_none()) && SpanlessEq::new(cx) .expr_fallback(eq_fallback) - .eq_expr(&lhs.body, &rhs.body) + .eq_expr(lhs.body, rhs.body) // these checks could be removed to allow unused bindings && bindings_eq(lhs.pat, local_map.keys().copied().collect()) && bindings_eq(rhs.pat, local_map.values().copied().collect()) diff --git a/clippy_lints/src/mem_discriminant.rs b/clippy_lints/src/mem_discriminant.rs index 7895ba9f1e0..a735c616f6e 100644 --- a/clippy_lints/src/mem_discriminant.rs +++ b/clippy_lints/src/mem_discriminant.rs @@ -34,7 +34,7 @@ declare_lint_pass!(MemDiscriminant => [MEM_DISCRIMINANT_NON_ENUM]); impl<'tcx> LateLintPass<'tcx> for MemDiscriminant { fn check_expr(&mut self, cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) { if_chain! { - if let ExprKind::Call(ref func, ref func_args) = expr.kind; + if let ExprKind::Call(func, func_args) = expr.kind; // is `mem::discriminant` if let ExprKind::Path(ref func_qpath) = func.kind; if let Some(def_id) = cx.qpath_res(func_qpath, func.hir_id).opt_def_id(); @@ -59,7 +59,7 @@ impl<'tcx> LateLintPass<'tcx> for MemDiscriminant { let mut derefs_needed = ptr_depth; let mut cur_expr = param; while derefs_needed > 0 { - if let ExprKind::AddrOf(BorrowKind::Ref, _, ref inner_expr) = cur_expr.kind { + if let ExprKind::AddrOf(BorrowKind::Ref, _, inner_expr) = cur_expr.kind { derefs_needed -= 1; cur_expr = inner_expr; } else { diff --git a/clippy_lints/src/mem_forget.rs b/clippy_lints/src/mem_forget.rs index c13802e3953..a28cb5f32fe 100644 --- a/clippy_lints/src/mem_forget.rs +++ b/clippy_lints/src/mem_forget.rs @@ -28,7 +28,7 @@ declare_lint_pass!(MemForget => [MEM_FORGET]); impl<'tcx> LateLintPass<'tcx> for MemForget { fn check_expr(&mut self, cx: &LateContext<'tcx>, e: &'tcx Expr<'_>) { - if let ExprKind::Call(ref path_expr, ref args) = e.kind { + if let ExprKind::Call(path_expr, args) = e.kind { if let ExprKind::Path(ref qpath) = path_expr.kind { if let Some(def_id) = cx.qpath_res(qpath, path_expr.hir_id).opt_def_id() { if match_def_path(cx, def_id, &paths::MEM_FORGET) { diff --git a/clippy_lints/src/mem_replace.rs b/clippy_lints/src/mem_replace.rs index 0418c616efa..e1d351aee45 100644 --- a/clippy_lints/src/mem_replace.rs +++ b/clippy_lints/src/mem_replace.rs @@ -109,14 +109,14 @@ fn check_replace_option_with_none(cx: &LateContext<'_>, src: &Expr<'_>, dest: &E // argument's type. All that's left is to get // replacee's path. let replaced_path = match dest.kind { - ExprKind::AddrOf(BorrowKind::Ref, Mutability::Mut, ref replaced) => { - if let ExprKind::Path(QPath::Resolved(None, ref replaced_path)) = replaced.kind { + ExprKind::AddrOf(BorrowKind::Ref, Mutability::Mut, replaced) => { + if let ExprKind::Path(QPath::Resolved(None, replaced_path)) = replaced.kind { replaced_path } else { return; } }, - ExprKind::Path(QPath::Resolved(None, ref replaced_path)) => replaced_path, + ExprKind::Path(QPath::Resolved(None, replaced_path)) => replaced_path, _ => return, }; @@ -161,7 +161,7 @@ fn check_replace_with_uninit(cx: &LateContext<'_>, src: &Expr<'_>, dest: &Expr<' } if_chain! { - if let ExprKind::Call(ref repl_func, ref repl_args) = src.kind; + if let ExprKind::Call(repl_func, repl_args) = src.kind; if repl_args.is_empty(); if let ExprKind::Path(ref repl_func_qpath) = repl_func.kind; if let Some(repl_def_id) = cx.qpath_res(repl_func_qpath, repl_func.hir_id).opt_def_id(); @@ -214,7 +214,7 @@ fn is_default_equivalent_ctor(cx: &LateContext<'_>, def_id: DefId, path: &QPath< .iter() .any(|symbol| is_diagnostic_assoc_item(cx, def_id, *symbol)) { - if let QPath::TypeRelative(_, ref method) = path { + if let QPath::TypeRelative(_, method) = path { if method.ident.name == sym::new { return true; } @@ -226,7 +226,7 @@ fn is_default_equivalent_ctor(cx: &LateContext<'_>, def_id: DefId, path: &QPath< fn check_replace_with_default(cx: &LateContext<'_>, src: &Expr<'_>, dest: &Expr<'_>, expr_span: Span) { if_chain! { - if let ExprKind::Call(ref repl_func, _) = src.kind; + if let ExprKind::Call(repl_func, _) = src.kind; if !in_external_macro(cx.tcx.sess, expr_span); if let ExprKind::Path(ref repl_func_qpath) = repl_func.kind; if let Some(repl_def_id) = cx.qpath_res(repl_func_qpath, repl_func.hir_id).opt_def_id(); @@ -273,11 +273,11 @@ impl<'tcx> LateLintPass<'tcx> for MemReplace { fn check_expr(&mut self, cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) { if_chain! { // Check that `expr` is a call to `mem::replace()` - if let ExprKind::Call(ref func, ref func_args) = expr.kind; + if let ExprKind::Call(func, func_args) = expr.kind; if let ExprKind::Path(ref func_qpath) = func.kind; if let Some(def_id) = cx.qpath_res(func_qpath, func.hir_id).opt_def_id(); if match_def_path(cx, def_id, &paths::MEM_REPLACE); - if let [dest, src] = &**func_args; + if let [dest, src] = func_args; then { check_replace_option_with_none(cx, src, dest, expr.span); check_replace_with_uninit(cx, src, dest, expr.span); diff --git a/clippy_lints/src/methods/bind_instead_of_map.rs b/clippy_lints/src/methods/bind_instead_of_map.rs index 46d4c674648..287bff886bf 100644 --- a/clippy_lints/src/methods/bind_instead_of_map.rs +++ b/clippy_lints/src/methods/bind_instead_of_map.rs @@ -71,7 +71,7 @@ pub(crate) trait BindInsteadOfMap { closure_args_span: Span, ) -> bool { if_chain! { - if let hir::ExprKind::Call(ref some_expr, [inner_expr]) = closure_expr.kind; + if let hir::ExprKind::Call(some_expr, [inner_expr]) = closure_expr.kind; if let hir::ExprKind::Path(QPath::Resolved(_, path)) = some_expr.kind; if Self::is_variant(cx, path.res); if !contains_return(inner_expr); @@ -107,7 +107,7 @@ pub(crate) trait BindInsteadOfMap { let can_sugg: bool = find_all_ret_expressions(cx, closure_expr, |ret_expr| { if_chain! { if !in_macro(ret_expr.span); - if let hir::ExprKind::Call(ref func_path, [arg]) = ret_expr.kind; + if let hir::ExprKind::Call(func_path, [arg]) = ret_expr.kind; if let hir::ExprKind::Path(QPath::Resolved(_, path)) = func_path.kind; if Self::is_variant(cx, path.res); if !contains_return(arg); diff --git a/clippy_lints/src/methods/chars_cmp.rs b/clippy_lints/src/methods/chars_cmp.rs index c668fe52781..514c4118765 100644 --- a/clippy_lints/src/methods/chars_cmp.rs +++ b/clippy_lints/src/methods/chars_cmp.rs @@ -19,7 +19,7 @@ pub(super) fn check( ) -> bool { if_chain! { if let Some(args) = method_chain_args(info.chain, chain_methods); - if let hir::ExprKind::Call(ref fun, ref arg_char) = info.other.kind; + if let hir::ExprKind::Call(fun, arg_char) = info.other.kind; if arg_char.len() == 1; if let hir::ExprKind::Path(ref qpath) = fun.kind; if let Some(segment) = single_segment_path(qpath); diff --git a/clippy_lints/src/methods/expect_fun_call.rs b/clippy_lints/src/methods/expect_fun_call.rs index e7bffa66b3f..03cb41697d5 100644 --- a/clippy_lints/src/methods/expect_fun_call.rs +++ b/clippy_lints/src/methods/expect_fun_call.rs @@ -100,9 +100,9 @@ pub(super) fn check(cx: &LateContext<'_>, expr: &hir::Expr<'_>, method_span: Spa applicability: &mut Applicability, ) -> Vec { if_chain! { - if let hir::ExprKind::AddrOf(hir::BorrowKind::Ref, _, ref format_arg) = a.kind; - if let hir::ExprKind::Match(ref format_arg_expr, _, _) = format_arg.kind; - if let hir::ExprKind::Tup(ref format_arg_expr_tup) = format_arg_expr.kind; + if let hir::ExprKind::AddrOf(hir::BorrowKind::Ref, _, format_arg) = a.kind; + if let hir::ExprKind::Match(format_arg_expr, _, _) = format_arg.kind; + if let hir::ExprKind::Tup(format_arg_expr_tup) = format_arg_expr.kind; then { format_arg_expr_tup @@ -155,7 +155,7 @@ pub(super) fn check(cx: &LateContext<'_>, expr: &hir::Expr<'_>, method_span: Spa if block.stmts.len() == 1; if let hir::StmtKind::Local(local) = &block.stmts[0].kind; if let Some(arg_root) = &local.init; - if let hir::ExprKind::Call(ref inner_fun, ref inner_args) = arg_root.kind; + if let hir::ExprKind::Call(inner_fun, inner_args) = arg_root.kind; if is_expn_of(inner_fun.span, "format").is_some() && inner_args.len() == 1; if let hir::ExprKind::Call(_, format_args) = &inner_args[0].kind; then { diff --git a/clippy_lints/src/methods/filter_map.rs b/clippy_lints/src/methods/filter_map.rs index 45d1ed953b4..35fae450eeb 100644 --- a/clippy_lints/src/methods/filter_map.rs +++ b/clippy_lints/src/methods/filter_map.rs @@ -19,7 +19,7 @@ use super::OPTION_FILTER_MAP; fn is_method<'tcx>(cx: &LateContext<'tcx>, expr: &hir::Expr<'_>, method_name: Symbol) -> bool { match &expr.kind { - hir::ExprKind::Path(QPath::TypeRelative(_, ref mname)) => mname.ident.name == method_name, + hir::ExprKind::Path(QPath::TypeRelative(_, mname)) => mname.ident.name == method_name, hir::ExprKind::Path(QPath::Resolved(_, segments)) => { segments.segments.last().unwrap().ident.name == method_name }, @@ -28,7 +28,7 @@ fn is_method<'tcx>(cx: &LateContext<'tcx>, expr: &hir::Expr<'_>, method_name: Sy let closure_expr = remove_blocks(&body.value); let arg_id = body.params[0].pat.hir_id; match closure_expr.kind { - hir::ExprKind::MethodCall(hir::PathSegment { ident, .. }, _, ref args, _) => { + hir::ExprKind::MethodCall(hir::PathSegment { ident, .. }, _, args, _) => { if_chain! { if ident.name == method_name; if let hir::ExprKind::Path(path) = &args[0].kind; @@ -61,7 +61,7 @@ fn lint_filter_some_map_unwrap( methods_span: Span, ) { let iterator = is_trait_method(cx, expr, sym::Iterator); - let option = is_type_diagnostic_item(cx, cx.typeck_results().expr_ty(&filter_recv), sym::option_type); + let option = is_type_diagnostic_item(cx, cx.typeck_results().expr_ty(filter_recv), sym::option_type); if (iterator || option) && is_option_filter_map(cx, filter_arg, map_arg) { let msg = "`filter` for `Some` followed by `unwrap`"; let help = "consider using `flatten` instead"; diff --git a/clippy_lints/src/methods/flat_map_identity.rs b/clippy_lints/src/methods/flat_map_identity.rs index 664885a2f0e..dd613d0cd63 100644 --- a/clippy_lints/src/methods/flat_map_identity.rs +++ b/clippy_lints/src/methods/flat_map_identity.rs @@ -35,7 +35,7 @@ pub(super) fn check<'tcx>( let body = cx.tcx.hir().body(*body_id); if let hir::PatKind::Binding(_, _, binding_ident, _) = body.params[0].pat.kind; - if let hir::ExprKind::Path(hir::QPath::Resolved(_, ref path)) = body.value.kind; + if let hir::ExprKind::Path(hir::QPath::Resolved(_, path)) = body.value.kind; if path.segments.len() == 1; if path.segments[0].ident.name == binding_ident.name; diff --git a/clippy_lints/src/methods/implicit_clone.rs b/clippy_lints/src/methods/implicit_clone.rs index 04461ad5c3a..1211e2f2bf7 100644 --- a/clippy_lints/src/methods/implicit_clone.rs +++ b/clippy_lints/src/methods/implicit_clone.rs @@ -13,7 +13,7 @@ use clippy_utils::is_diagnostic_assoc_item; pub fn check(cx: &LateContext<'_>, expr: &hir::Expr<'_>, trait_diagnostic: Symbol) { if_chain! { if let ExprKind::MethodCall(method_path, _, [arg], _) = &expr.kind; - let return_type = cx.typeck_results().expr_ty(&expr); + let return_type = cx.typeck_results().expr_ty(expr); let input_type = cx.typeck_results().expr_ty(arg).peel_refs(); if let Some(expr_def_id) = cx.typeck_results().type_dependent_def_id(expr.hir_id); if let Some(ty_name) = input_type.ty_adt_def().map(|adt_def| cx.tcx.item_name(adt_def.did)); diff --git a/clippy_lints/src/methods/iter_next_slice.rs b/clippy_lints/src/methods/iter_next_slice.rs index dab0a43a096..a49851de38e 100644 --- a/clippy_lints/src/methods/iter_next_slice.rs +++ b/clippy_lints/src/methods/iter_next_slice.rs @@ -27,7 +27,7 @@ pub(super) fn check<'tcx>(cx: &LateContext<'tcx>, expr: &'tcx hir::Expr<'_>, cal if derefs_to_slice(cx, caller_expr, cx.typeck_results().expr_ty(caller_expr)).is_some() { // caller is a Slice if_chain! { - if let hir::ExprKind::Index(ref caller_var, ref index_expr) = &caller_expr.kind; + if let hir::ExprKind::Index(caller_var, index_expr) = &caller_expr.kind; if let Some(higher::Range { start: Some(start_expr), end: None, limits: ast::RangeLimits::HalfOpen }) = higher::range(index_expr); if let hir::ExprKind::Lit(ref start_lit) = &start_expr.kind; diff --git a/clippy_lints/src/methods/mod.rs b/clippy_lints/src/methods/mod.rs index fa6323b56e1..b1ade5addd6 100644 --- a/clippy_lints/src/methods/mod.rs +++ b/clippy_lints/src/methods/mod.rs @@ -1740,10 +1740,10 @@ impl<'tcx> LateLintPass<'tcx> for Methods { check_methods(cx, expr, self.msrv.as_ref()); match expr.kind { - hir::ExprKind::Call(ref func, ref args) => { + hir::ExprKind::Call(func, args) => { from_iter_instead_of_collect::check(cx, expr, args, &func.kind); }, - hir::ExprKind::MethodCall(ref method_call, ref method_span, ref args, _) => { + hir::ExprKind::MethodCall(method_call, ref method_span, args, _) => { or_fun_call::check(cx, expr, *method_span, &method_call.ident.as_str(), args); expect_fun_call::check(cx, expr, *method_span, &method_call.ident.as_str(), args); clone_on_copy::check(cx, expr, method_call.ident.name, args); @@ -1753,9 +1753,7 @@ impl<'tcx> LateLintPass<'tcx> for Methods { into_iter_on_ref::check(cx, expr, *method_span, method_call.ident.name, args); single_char_pattern::check(cx, expr, method_call.ident.name, args); }, - hir::ExprKind::Binary(op, ref lhs, ref rhs) - if op.node == hir::BinOpKind::Eq || op.node == hir::BinOpKind::Ne => - { + hir::ExprKind::Binary(op, lhs, rhs) if op.node == hir::BinOpKind::Eq || op.node == hir::BinOpKind::Ne => { let mut info = BinaryExprInfo { expr, chain: lhs, @@ -1763,7 +1761,7 @@ impl<'tcx> LateLintPass<'tcx> for Methods { eq: op.node == hir::BinOpKind::Eq, }; lint_binary_expr_with_method_call(cx, &mut info); - } + }, _ => (), } } @@ -1781,7 +1779,7 @@ impl<'tcx> LateLintPass<'tcx> for Methods { let implements_trait = matches!(item.kind, hir::ItemKind::Impl(hir::Impl { of_trait: Some(_), .. })); if_chain! { if let hir::ImplItemKind::Fn(ref sig, id) = impl_item.kind; - if let Some(first_arg) = iter_input_pats(&sig.decl, cx.tcx.hir().body(id)).next(); + if let Some(first_arg) = iter_input_pats(sig.decl, cx.tcx.hir().body(id)).next(); let method_sig = cx.tcx.fn_sig(impl_item.def_id); let method_sig = cx.tcx.erase_late_bound_regions(method_sig); @@ -1801,7 +1799,7 @@ impl<'tcx> LateLintPass<'tcx> for Methods { method_config.output_type.matches(&sig.decl.output) && method_config.self_kind.matches(cx, self_ty, first_arg_ty) && fn_header_equals(method_config.fn_header, sig.header) && - method_config.lifetime_param_cond(&impl_item) + method_config.lifetime_param_cond(impl_item) { span_lint_and_help( cx, @@ -2272,10 +2270,10 @@ impl OutType { let is_unit = |ty: &hir::Ty<'_>| matches!(ty.kind, hir::TyKind::Tup(&[])); match (self, ty) { (Self::Unit, &hir::FnRetTy::DefaultReturn(_)) => true, - (Self::Unit, &hir::FnRetTy::Return(ref ty)) if is_unit(ty) => true, - (Self::Bool, &hir::FnRetTy::Return(ref ty)) if is_bool(ty) => true, - (Self::Any, &hir::FnRetTy::Return(ref ty)) if !is_unit(ty) => true, - (Self::Ref, &hir::FnRetTy::Return(ref ty)) => matches!(ty.kind, hir::TyKind::Rptr(_, _)), + (Self::Unit, &hir::FnRetTy::Return(ty)) if is_unit(ty) => true, + (Self::Bool, &hir::FnRetTy::Return(ty)) if is_bool(ty) => true, + (Self::Any, &hir::FnRetTy::Return(ty)) if !is_unit(ty) => true, + (Self::Ref, &hir::FnRetTy::Return(ty)) => matches!(ty.kind, hir::TyKind::Rptr(_, _)), _ => false, } } diff --git a/clippy_lints/src/methods/option_as_ref_deref.rs b/clippy_lints/src/methods/option_as_ref_deref.rs index 1367a0c21d8..7e9c8fa829d 100644 --- a/clippy_lints/src/methods/option_as_ref_deref.rs +++ b/clippy_lints/src/methods/option_as_ref_deref.rs @@ -77,10 +77,10 @@ pub(super) fn check<'tcx>( } } }, - hir::ExprKind::AddrOf(hir::BorrowKind::Ref, m, ref inner) if same_mutability(m) => { + hir::ExprKind::AddrOf(hir::BorrowKind::Ref, m, inner) if same_mutability(m) => { if_chain! { - if let hir::ExprKind::Unary(hir::UnOp::Deref, ref inner1) = inner.kind; - if let hir::ExprKind::Unary(hir::UnOp::Deref, ref inner2) = inner1.kind; + if let hir::ExprKind::Unary(hir::UnOp::Deref, inner1) = inner.kind; + if let hir::ExprKind::Unary(hir::UnOp::Deref, inner2) = inner1.kind; then { path_to_local_id(inner2, closure_body.params[0].pat.hir_id) } else { diff --git a/clippy_lints/src/methods/or_fun_call.rs b/clippy_lints/src/methods/or_fun_call.rs index 89dedc5f0d8..df89da5d3e0 100644 --- a/clippy_lints/src/methods/or_fun_call.rs +++ b/clippy_lints/src/methods/or_fun_call.rs @@ -86,7 +86,7 @@ pub(super) fn check<'tcx>( (&paths::RESULT, true, &["or", "unwrap_or"], "else"), ]; - if let hir::ExprKind::MethodCall(ref path, _, ref args, _) = &arg.kind { + if let hir::ExprKind::MethodCall(path, _, args, _) = &arg.kind { if path.ident.as_str() == "len" { let ty = cx.typeck_results().expr_ty(&args[0]).peel_refs(); @@ -105,7 +105,7 @@ pub(super) fn check<'tcx>( if KNOW_TYPES.iter().any(|k| k.2.contains(&name)); if is_lazyness_candidate(cx, arg); - if !contains_return(&arg); + if !contains_return(arg); let self_ty = cx.typeck_results().expr_ty(self_expr); @@ -158,7 +158,7 @@ pub(super) fn check<'tcx>( if args.len() == 2 { match args[1].kind { - hir::ExprKind::Call(ref fun, ref or_args) => { + hir::ExprKind::Call(fun, or_args) => { let or_has_args = !or_args.is_empty(); if !check_unwrap_or_default(cx, name, fun, &args[0], &args[1], or_has_args, expr.span) { let fun_span = if or_has_args { None } else { Some(fun.span) }; diff --git a/clippy_lints/src/methods/search_is_some.rs b/clippy_lints/src/methods/search_is_some.rs index 8a94d7f4155..ecec6fc3bb7 100644 --- a/clippy_lints/src/methods/search_is_some.rs +++ b/clippy_lints/src/methods/search_is_some.rs @@ -45,7 +45,7 @@ pub(super) fn check<'tcx>( then { if let hir::PatKind::Ref(..) = closure_arg.pat.kind { Some(search_snippet.replacen('&', "", 1)) - } else if let PatKind::Binding(_, _, ident, _) = strip_pat_refs(&closure_arg.pat).kind { + } else if let PatKind::Binding(_, _, ident, _) = strip_pat_refs(closure_arg.pat).kind { let name = &*ident.name.as_str(); Some(search_snippet.replace(&format!("*{}", name), name)) } else { @@ -108,8 +108,8 @@ pub(super) fn check<'tcx>( } }; if_chain! { - if is_string_or_str_slice(&search_recv); - if is_string_or_str_slice(&search_arg); + if is_string_or_str_slice(search_recv); + if is_string_or_str_slice(search_arg); then { let msg = format!("called `{}()` after calling `find()` on a string", option_check_method); match option_check_method { diff --git a/clippy_lints/src/methods/uninit_assumed_init.rs b/clippy_lints/src/methods/uninit_assumed_init.rs index 3cc1912b15a..0ae65c0c01d 100644 --- a/clippy_lints/src/methods/uninit_assumed_init.rs +++ b/clippy_lints/src/methods/uninit_assumed_init.rs @@ -10,7 +10,7 @@ use super::UNINIT_ASSUMED_INIT; /// lint for `MaybeUninit::uninit().assume_init()` (we already have the latter) pub(super) fn check(cx: &LateContext<'_>, expr: &hir::Expr<'_>, recv: &hir::Expr<'_>) { if_chain! { - if let hir::ExprKind::Call(ref callee, ref args) = recv.kind; + if let hir::ExprKind::Call(callee, args) = recv.kind; if args.is_empty(); if let hir::ExprKind::Path(ref path) = callee.kind; if match_qpath(path, &paths::MEM_MAYBEUNINIT_UNINIT); @@ -28,9 +28,9 @@ pub(super) fn check(cx: &LateContext<'_>, expr: &hir::Expr<'_>, recv: &hir::Expr fn is_maybe_uninit_ty_valid(cx: &LateContext<'_>, ty: Ty<'_>) -> bool { match ty.kind() { - ty::Array(ref component, _) => is_maybe_uninit_ty_valid(cx, component), - ty::Tuple(ref types) => types.types().all(|ty| is_maybe_uninit_ty_valid(cx, ty)), - ty::Adt(ref adt, _) => match_def_path(cx, adt.did, &paths::MEM_MAYBEUNINIT), + ty::Array(component, _) => is_maybe_uninit_ty_valid(cx, component), + ty::Tuple(types) => types.types().all(|ty| is_maybe_uninit_ty_valid(cx, ty)), + ty::Adt(adt, _) => match_def_path(cx, adt.did, &paths::MEM_MAYBEUNINIT), _ => false, } } diff --git a/clippy_lints/src/methods/unnecessary_filter_map.rs b/clippy_lints/src/methods/unnecessary_filter_map.rs index 8e637e12393..0f28bfdf09e 100644 --- a/clippy_lints/src/methods/unnecessary_filter_map.rs +++ b/clippy_lints/src/methods/unnecessary_filter_map.rs @@ -20,9 +20,9 @@ pub(super) fn check(cx: &LateContext<'_>, expr: &hir::Expr<'_>, arg: &hir::Expr< let mutates_arg = mutated_variables(&body.value, cx).map_or(true, |used_mutably| used_mutably.contains(&arg_id)); - let (mut found_mapping, mut found_filtering) = check_expression(&cx, arg_id, &body.value); + let (mut found_mapping, mut found_filtering) = check_expression(cx, arg_id, &body.value); - let mut return_visitor = ReturnVisitor::new(&cx, arg_id); + let mut return_visitor = ReturnVisitor::new(cx, arg_id); return_visitor.visit_expr(&body.value); found_mapping |= return_visitor.found_mapping; found_filtering |= return_visitor.found_filtering; @@ -52,7 +52,7 @@ pub(super) fn check(cx: &LateContext<'_>, expr: &hir::Expr<'_>, arg: &hir::Expr< // returns (found_mapping, found_filtering) fn check_expression<'tcx>(cx: &LateContext<'tcx>, arg_id: hir::HirId, expr: &'tcx hir::Expr<'_>) -> (bool, bool) { match &expr.kind { - hir::ExprKind::Call(ref func, ref args) => { + hir::ExprKind::Call(func, args) => { if let hir::ExprKind::Path(ref path) = func.kind { if match_qpath(path, &paths::OPTION_SOME) { if path_to_local_id(&args[0], arg_id) { @@ -65,22 +65,22 @@ fn check_expression<'tcx>(cx: &LateContext<'tcx>, arg_id: hir::HirId, expr: &'tc } (true, true) }, - hir::ExprKind::Block(ref block, _) => block + hir::ExprKind::Block(block, _) => block .expr .as_ref() - .map_or((false, false), |expr| check_expression(cx, arg_id, &expr)), + .map_or((false, false), |expr| check_expression(cx, arg_id, expr)), hir::ExprKind::Match(_, arms, _) => { let mut found_mapping = false; let mut found_filtering = false; for arm in *arms { - let (m, f) = check_expression(cx, arg_id, &arm.body); + let (m, f) = check_expression(cx, arg_id, arm.body); found_mapping |= m; found_filtering |= f; } (found_mapping, found_filtering) }, // There must be an else_arm or there will be a type error - hir::ExprKind::If(_, ref if_arm, Some(ref else_arm)) => { + hir::ExprKind::If(_, if_arm, Some(else_arm)) => { let if_check = check_expression(cx, arg_id, if_arm); let else_check = check_expression(cx, arg_id, else_arm); (if_check.0 | else_check.0, if_check.1 | else_check.1) diff --git a/clippy_lints/src/methods/unnecessary_fold.rs b/clippy_lints/src/methods/unnecessary_fold.rs index 7c16470348f..75517c48a21 100644 --- a/clippy_lints/src/methods/unnecessary_fold.rs +++ b/clippy_lints/src/methods/unnecessary_fold.rs @@ -34,13 +34,13 @@ pub(super) fn check( let closure_expr = remove_blocks(&closure_body.value); // Check if the closure body is of the form `acc some_expr(x)` - if let hir::ExprKind::Binary(ref bin_op, ref left_expr, ref right_expr) = closure_expr.kind; + if let hir::ExprKind::Binary(ref bin_op, left_expr, right_expr) = closure_expr.kind; if bin_op.node == op; // Extract the names of the two arguments to the closure if let [param_a, param_b] = closure_body.params; - if let PatKind::Binding(_, first_arg_id, ..) = strip_pat_refs(¶m_a.pat).kind; - if let PatKind::Binding(_, second_arg_id, second_arg_ident, _) = strip_pat_refs(¶m_b.pat).kind; + if let PatKind::Binding(_, first_arg_id, ..) = strip_pat_refs(param_a.pat).kind; + if let PatKind::Binding(_, second_arg_id, second_arg_ident, _) = strip_pat_refs(param_b.pat).kind; if path_to_local_id(left_expr, first_arg_id); if replacement_has_args || path_to_local_id(right_expr, second_arg_id); diff --git a/clippy_lints/src/methods/utils.rs b/clippy_lints/src/methods/utils.rs index ac6b55396da..f6bf37e08b9 100644 --- a/clippy_lints/src/methods/utils.rs +++ b/clippy_lints/src/methods/utils.rs @@ -26,7 +26,7 @@ pub(super) fn derefs_to_slice<'tcx>( } } - if let hir::ExprKind::MethodCall(ref path, _, ref args, _) = expr.kind { + if let hir::ExprKind::MethodCall(path, _, args, _) = expr.kind { if path.ident.name == sym::iter && may_slice(cx, cx.typeck_results().expr_ty(&args[0])) { Some(&args[0]) } else { diff --git a/clippy_lints/src/methods/zst_offset.rs b/clippy_lints/src/methods/zst_offset.rs index 0489d0f6fcf..866cf616679 100644 --- a/clippy_lints/src/methods/zst_offset.rs +++ b/clippy_lints/src/methods/zst_offset.rs @@ -8,7 +8,7 @@ use super::ZST_OFFSET; pub(super) fn check(cx: &LateContext<'_>, expr: &hir::Expr<'_>, recv: &hir::Expr<'_>) { if_chain! { - if let ty::RawPtr(ty::TypeAndMut { ref ty, .. }) = cx.typeck_results().expr_ty(recv).kind(); + if let ty::RawPtr(ty::TypeAndMut { ty, .. }) = cx.typeck_results().expr_ty(recv).kind(); if let Ok(layout) = cx.tcx.layout_of(cx.param_env.and(ty)); if layout.is_zst(); then { diff --git a/clippy_lints/src/minmax.rs b/clippy_lints/src/minmax.rs index 776f4c7b741..45948f4d926 100644 --- a/clippy_lints/src/minmax.rs +++ b/clippy_lints/src/minmax.rs @@ -67,7 +67,7 @@ enum MinMax { fn min_max<'a>(cx: &LateContext<'_>, expr: &'a Expr<'a>) -> Option<(MinMax, Constant, &'a Expr<'a>)> { match expr.kind { - ExprKind::Call(ref path, ref args) => { + ExprKind::Call(path, args) => { if let ExprKind::Path(ref qpath) = path.kind { cx.typeck_results() .qpath_res(qpath, path.hir_id) @@ -85,7 +85,7 @@ fn min_max<'a>(cx: &LateContext<'_>, expr: &'a Expr<'a>) -> Option<(MinMax, Cons None } }, - ExprKind::MethodCall(ref path, _, ref args, _) => { + ExprKind::MethodCall(path, _, args, _) => { if_chain! { if let [obj, _] = args; if cx.typeck_results().expr_ty(obj).is_floating_point() || match_trait_method(cx, expr, &paths::ORD); diff --git a/clippy_lints/src/misc.rs b/clippy_lints/src/misc.rs index c23643cb2f5..afced5a5ce5 100644 --- a/clippy_lints/src/misc.rs +++ b/clippy_lints/src/misc.rs @@ -304,9 +304,9 @@ impl<'tcx> LateLintPass<'tcx> for MiscLints { fn check_stmt(&mut self, cx: &LateContext<'tcx>, stmt: &'tcx Stmt<'_>) { if_chain! { if !in_external_macro(cx.tcx.sess, stmt.span); - if let StmtKind::Local(ref local) = stmt.kind; + if let StmtKind::Local(local) = stmt.kind; if let PatKind::Binding(an, .., name, None) = local.pat.kind; - if let Some(ref init) = local.init; + if let Some(init) = local.init; if !higher::is_from_for_desugar(local); if an == BindingAnnotation::Ref || an == BindingAnnotation::RefMut; then { @@ -322,7 +322,7 @@ impl<'tcx> LateLintPass<'tcx> for MiscLints { } else { ("", sugg_init.addr()) }; - let tyopt = if let Some(ref ty) = local.ty { + let tyopt = if let Some(ty) = local.ty { format!(": &{mutopt}{ty}", mutopt=mutopt, ty=snippet(cx, ty.span, "..")) } else { String::new() @@ -350,8 +350,8 @@ impl<'tcx> LateLintPass<'tcx> for MiscLints { } }; if_chain! { - if let StmtKind::Semi(ref expr) = stmt.kind; - if let ExprKind::Binary(ref binop, ref a, ref b) = expr.kind; + if let StmtKind::Semi(expr) = stmt.kind; + if let ExprKind::Binary(ref binop, a, b) = expr.kind; if binop.node == BinOpKind::And || binop.node == BinOpKind::Or; if let Some(sugg) = Sugg::hir_opt(cx, a); then { @@ -378,11 +378,11 @@ impl<'tcx> LateLintPass<'tcx> for MiscLints { fn check_expr(&mut self, cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) { match expr.kind { - ExprKind::Cast(ref e, ref ty) => { + ExprKind::Cast(e, ty) => { check_cast(cx, expr.span, e, ty); return; }, - ExprKind::Binary(ref cmp, ref left, ref right) => { + ExprKind::Binary(ref cmp, left, right) => { check_binary(cx, expr, cmp, left, right); return; }, @@ -501,12 +501,12 @@ fn is_allowed<'tcx>(cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) -> bool { // Return true if `expr` is the result of `signum()` invoked on a float value. fn is_signum(cx: &LateContext<'_>, expr: &Expr<'_>) -> bool { // The negation of a signum is still a signum - if let ExprKind::Unary(UnOp::Neg, ref child_expr) = expr.kind { - return is_signum(cx, &child_expr); + if let ExprKind::Unary(UnOp::Neg, child_expr) = expr.kind { + return is_signum(cx, child_expr); } if_chain! { - if let ExprKind::MethodCall(ref method_name, _, ref expressions, _) = expr.kind; + if let ExprKind::MethodCall(method_name, _, expressions, _) = expr.kind; if sym!(signum) == method_name.ident.name; // Check that the receiver of the signum() is a float (expressions[0] is the receiver of // the method call) @@ -552,7 +552,7 @@ fn check_to_owned(cx: &LateContext<'_>, expr: &Expr<'_>, other: &Expr<'_>, left: } let (arg_ty, snip) = match expr.kind { - ExprKind::MethodCall(.., ref args, _) if args.len() == 1 => { + ExprKind::MethodCall(.., args, _) if args.len() == 1 => { if_chain!( if let Some(expr_def_id) = cx.typeck_results().type_dependent_def_id(expr.hir_id); if is_diagnostic_assoc_item(cx, expr_def_id, sym::ToString) @@ -564,7 +564,7 @@ fn check_to_owned(cx: &LateContext<'_>, expr: &Expr<'_>, other: &Expr<'_>, left: } ) }, - ExprKind::Call(ref path, ref v) if v.len() == 1 => { + ExprKind::Call(path, v) if v.len() == 1 => { if let ExprKind::Path(ref path) = path.kind { if match_qpath(path, &["String", "from_str"]) || match_qpath(path, &["String", "from"]) { (cx.typeck_results().expr_ty(&v[0]), snippet(cx, v[0].span, "..")) @@ -649,7 +649,7 @@ fn check_to_owned(cx: &LateContext<'_>, expr: &Expr<'_>, other: &Expr<'_>, left: /// of what it means for an expression to be "used". fn is_used(cx: &LateContext<'_>, expr: &Expr<'_>) -> bool { get_parent_expr(cx, expr).map_or(true, |parent| match parent.kind { - ExprKind::Assign(_, ref rhs, _) | ExprKind::AssignOp(_, _, ref rhs) => SpanlessEq::new(cx).eq_expr(rhs, expr), + ExprKind::Assign(_, rhs, _) | ExprKind::AssignOp(_, _, rhs) => SpanlessEq::new(cx).eq_expr(rhs, expr), _ => is_used(cx, parent), }) } diff --git a/clippy_lints/src/missing_const_for_fn.rs b/clippy_lints/src/missing_const_for_fn.rs index 23554669d97..0dc02431ad5 100644 --- a/clippy_lints/src/missing_const_for_fn.rs +++ b/clippy_lints/src/missing_const_for_fn.rs @@ -138,7 +138,7 @@ impl<'tcx> LateLintPass<'tcx> for MissingConstForFn { let mir = cx.tcx.optimized_mir(def_id); - if let Err((span, err)) = is_min_const_fn(cx.tcx, &mir) { + if let Err((span, err)) = is_min_const_fn(cx.tcx, mir) { if rustc_mir::const_eval::is_min_const_fn(cx.tcx, def_id.to_def_id()) { cx.tcx.sess.span_err(span, &err); } diff --git a/clippy_lints/src/missing_inline.rs b/clippy_lints/src/missing_inline.rs index dd4488f3f02..041fe64a1a9 100644 --- a/clippy_lints/src/missing_inline.rs +++ b/clippy_lints/src/missing_inline.rs @@ -96,7 +96,7 @@ impl<'tcx> LateLintPass<'tcx> for MissingInline { let attrs = cx.tcx.hir().attrs(it.hir_id()); check_missing_inline_attrs(cx, attrs, it.span, desc); }, - hir::ItemKind::Trait(ref _is_auto, ref _unsafe, ref _generics, ref _bounds, trait_items) => { + hir::ItemKind::Trait(ref _is_auto, ref _unsafe, ref _generics, _bounds, trait_items) => { // note: we need to check if the trait is exported so we can't use // `LateLintPass::check_trait_item` here. for tit in trait_items { diff --git a/clippy_lints/src/mut_key.rs b/clippy_lints/src/mut_key.rs index 41bd07bcf1e..ed7b9cd62dc 100644 --- a/clippy_lints/src/mut_key.rs +++ b/clippy_lints/src/mut_key.rs @@ -58,21 +58,21 @@ declare_lint_pass!(MutableKeyType => [ MUTABLE_KEY_TYPE ]); impl<'tcx> LateLintPass<'tcx> for MutableKeyType { fn check_item(&mut self, cx: &LateContext<'tcx>, item: &'tcx hir::Item<'tcx>) { if let hir::ItemKind::Fn(ref sig, ..) = item.kind { - check_sig(cx, item.hir_id(), &sig.decl); + check_sig(cx, item.hir_id(), sig.decl); } } fn check_impl_item(&mut self, cx: &LateContext<'tcx>, item: &'tcx hir::ImplItem<'tcx>) { if let hir::ImplItemKind::Fn(ref sig, ..) = item.kind { if trait_ref_of_method(cx, item.hir_id()).is_none() { - check_sig(cx, item.hir_id(), &sig.decl); + check_sig(cx, item.hir_id(), sig.decl); } } } fn check_trait_item(&mut self, cx: &LateContext<'tcx>, item: &'tcx hir::TraitItem<'tcx>) { if let hir::TraitItemKind::Fn(ref sig, ..) = item.kind { - check_sig(cx, item.hir_id(), &sig.decl); + check_sig(cx, item.hir_id(), sig.decl); } } diff --git a/clippy_lints/src/mut_mut.rs b/clippy_lints/src/mut_mut.rs index ef33e41a5fa..4b9c51d0c16 100644 --- a/clippy_lints/src/mut_mut.rs +++ b/clippy_lints/src/mut_mut.rs @@ -62,7 +62,7 @@ impl<'a, 'tcx> intravisit::Visitor<'tcx> for MutVisitor<'a, 'tcx> { // Let's ignore the generated code. intravisit::walk_expr(self, arg); intravisit::walk_expr(self, body); - } else if let hir::ExprKind::AddrOf(hir::BorrowKind::Ref, hir::Mutability::Mut, ref e) = expr.kind { + } else if let hir::ExprKind::AddrOf(hir::BorrowKind::Ref, hir::Mutability::Mut, e) = expr.kind { if let hir::ExprKind::AddrOf(hir::BorrowKind::Ref, hir::Mutability::Mut, _) = e.kind { span_lint( self.cx, @@ -85,7 +85,7 @@ impl<'a, 'tcx> intravisit::Visitor<'tcx> for MutVisitor<'a, 'tcx> { if let hir::TyKind::Rptr( _, hir::MutTy { - ty: ref pty, + ty: pty, mutbl: hir::Mutability::Mut, }, ) = ty.kind diff --git a/clippy_lints/src/mut_reference.rs b/clippy_lints/src/mut_reference.rs index 0c09ddb8073..b85cc4b9548 100644 --- a/clippy_lints/src/mut_reference.rs +++ b/clippy_lints/src/mut_reference.rs @@ -32,7 +32,7 @@ declare_lint_pass!(UnnecessaryMutPassed => [UNNECESSARY_MUT_PASSED]); impl<'tcx> LateLintPass<'tcx> for UnnecessaryMutPassed { fn check_expr(&mut self, cx: &LateContext<'tcx>, e: &'tcx Expr<'_>) { match e.kind { - ExprKind::Call(ref fn_expr, ref arguments) => { + ExprKind::Call(fn_expr, arguments) => { if let ExprKind::Path(ref path) = fn_expr.kind { check_arguments( cx, @@ -43,7 +43,7 @@ impl<'tcx> LateLintPass<'tcx> for UnnecessaryMutPassed { ); } }, - ExprKind::MethodCall(ref path, _, ref arguments, _) => { + ExprKind::MethodCall(path, _, arguments, _) => { let def_id = cx.typeck_results().type_dependent_def_id(e.hir_id).unwrap(); let substs = cx.typeck_results().node_substs(e.hir_id); let method_type = cx.tcx.type_of(def_id).subst(cx.tcx, substs); diff --git a/clippy_lints/src/needless_bool.rs b/clippy_lints/src/needless_bool.rs index db7b3423ad9..96a58d1410f 100644 --- a/clippy_lints/src/needless_bool.rs +++ b/clippy_lints/src/needless_bool.rs @@ -71,7 +71,7 @@ declare_lint_pass!(NeedlessBool => [NEEDLESS_BOOL]); impl<'tcx> LateLintPass<'tcx> for NeedlessBool { fn check_expr(&mut self, cx: &LateContext<'tcx>, e: &'tcx Expr<'_>) { use self::Expression::{Bool, RetBool}; - if let ExprKind::If(ref pred, ref then_block, Some(ref else_expr)) = e.kind { + if let ExprKind::If(pred, then_block, Some(else_expr)) = e.kind { let reduce = |ret, not| { let mut applicability = Applicability::MachineApplicable; let snip = Sugg::hir_with_applicability(cx, pred, "", &mut applicability); @@ -81,7 +81,7 @@ impl<'tcx> LateLintPass<'tcx> for NeedlessBool { snip = snip.make_return(); } - if parent_node_is_if_expr(&e, &cx) { + if parent_node_is_if_expr(e, cx) { snip = snip.blockify() } @@ -95,7 +95,7 @@ impl<'tcx> LateLintPass<'tcx> for NeedlessBool { applicability, ); }; - if let ExprKind::Block(ref then_block, _) = then_block.kind { + if let ExprKind::Block(then_block, _) = then_block.kind { match (fetch_bool_block(then_block), fetch_bool_expr(else_expr)) { (RetBool(true), RetBool(true)) | (Bool(true), Bool(true)) => { span_lint( @@ -225,7 +225,7 @@ fn check_comparison<'a, 'tcx>( ) { use self::Expression::{Bool, Other}; - if let ExprKind::Binary(op, ref left_side, ref right_side) = e.kind { + if let ExprKind::Binary(op, left_side, right_side) = e.kind { let (l_ty, r_ty) = ( cx.typeck_results().expr_ty(left_side), cx.typeck_results().expr_ty(right_side), @@ -237,7 +237,7 @@ fn check_comparison<'a, 'tcx>( let mut applicability = Applicability::MachineApplicable; if let BinOpKind::Eq = op.node { - let expression_info = one_side_is_unary_not(&left_side, &right_side); + let expression_info = one_side_is_unary_not(left_side, right_side); if expression_info.one_side_is_unary_not { span_lint_and_sugg( cx, @@ -324,9 +324,9 @@ fn fetch_bool_block(block: &Block<'_>) -> Expression { match (&*block.stmts, block.expr.as_ref()) { (&[], Some(e)) => fetch_bool_expr(&**e), (&[ref e], None) => { - if let StmtKind::Semi(ref e) = e.kind { + if let StmtKind::Semi(e) = e.kind { if let ExprKind::Ret(_) = e.kind { - fetch_bool_expr(&**e) + fetch_bool_expr(e) } else { Expression::Other } @@ -340,7 +340,7 @@ fn fetch_bool_block(block: &Block<'_>) -> Expression { fn fetch_bool_expr(expr: &Expr<'_>) -> Expression { match expr.kind { - ExprKind::Block(ref block, _) => fetch_bool_block(block), + ExprKind::Block(block, _) => fetch_bool_block(block), ExprKind::Lit(ref lit_ptr) => { if let LitKind::Bool(value) = lit_ptr.node { Expression::Bool(value) @@ -348,7 +348,7 @@ fn fetch_bool_expr(expr: &Expr<'_>) -> Expression { Expression::Other } }, - ExprKind::Ret(Some(ref expr)) => match fetch_bool_expr(expr) { + ExprKind::Ret(Some(expr)) => match fetch_bool_expr(expr) { Expression::Bool(value) => Expression::RetBool(value), _ => Expression::Other, }, diff --git a/clippy_lints/src/needless_borrow.rs b/clippy_lints/src/needless_borrow.rs index 79d84da2dfc..eef3c16730b 100644 --- a/clippy_lints/src/needless_borrow.rs +++ b/clippy_lints/src/needless_borrow.rs @@ -48,7 +48,7 @@ impl<'tcx> LateLintPass<'tcx> for NeedlessBorrow { if e.span.from_expansion() || self.derived_item.is_some() { return; } - if let ExprKind::AddrOf(BorrowKind::Ref, Mutability::Not, ref inner) = e.kind { + if let ExprKind::AddrOf(BorrowKind::Ref, Mutability::Not, inner) = e.kind { if let ty::Ref(_, ty, _) = cx.typeck_results().expr_ty(inner).kind() { for adj3 in cx.typeck_results().expr_adjustments(e).windows(3) { if let [Adjustment { diff --git a/clippy_lints/src/needless_borrowed_ref.rs b/clippy_lints/src/needless_borrowed_ref.rs index 7fbffe04a3f..0e976b130eb 100644 --- a/clippy_lints/src/needless_borrowed_ref.rs +++ b/clippy_lints/src/needless_borrowed_ref.rs @@ -51,7 +51,7 @@ impl<'tcx> LateLintPass<'tcx> for NeedlessBorrowedRef { if_chain! { // Only lint immutable refs, because `&mut ref T` may be useful. - if let PatKind::Ref(ref sub_pat, Mutability::Not) = pat.kind; + if let PatKind::Ref(sub_pat, Mutability::Not) = pat.kind; // Check sub_pat got a `ref` keyword (excluding `ref mut`). if let PatKind::Binding(BindingAnnotation::Ref, .., spanned_name, _) = sub_pat.kind; diff --git a/clippy_lints/src/needless_for_each.rs b/clippy_lints/src/needless_for_each.rs index 2ea871990f1..079b6642d58 100644 --- a/clippy_lints/src/needless_for_each.rs +++ b/clippy_lints/src/needless_for_each.rs @@ -70,7 +70,7 @@ impl LateLintPass<'_> for NeedlessForEach { ExprKind::Array(..) | ExprKind::Call(..) | ExprKind::Path(..) ); // Checks the type of the `iter` method receiver is NOT a user defined type. - if has_iter_method(cx, cx.typeck_results().expr_ty(&iter_recv)).is_some(); + if has_iter_method(cx, cx.typeck_results().expr_ty(iter_recv)).is_some(); // Skip the lint if the body is not block because this is simpler than `for` loop. // e.g. `v.iter().for_each(f)` is simpler and clearer than using `for` loop. if let ExprKind::Closure(_, _, body_id, ..) = for_each_arg.kind; diff --git a/clippy_lints/src/needless_pass_by_value.rs b/clippy_lints/src/needless_pass_by_value.rs index 7370ba39922..780e2241293 100644 --- a/clippy_lints/src/needless_pass_by_value.rs +++ b/clippy_lints/src/needless_pass_by_value.rs @@ -208,7 +208,7 @@ impl<'tcx> LateLintPass<'tcx> for NeedlessPassByValue { if is_type_diagnostic_item(cx, ty, sym::vec_type); if let Some(clone_spans) = get_spans(cx, Some(body.id()), idx, &[("clone", ".to_owned()")]); - if let TyKind::Path(QPath::Resolved(_, ref path)) = input.kind; + if let TyKind::Path(QPath::Resolved(_, path)) = input.kind; if let Some(elem_ty) = path.segments.iter() .find(|seg| seg.ident.name == sym::Vec) .and_then(|ps| ps.args.as_ref()) diff --git a/clippy_lints/src/needless_update.rs b/clippy_lints/src/needless_update.rs index e93de8a252a..8f325404deb 100644 --- a/clippy_lints/src/needless_update.rs +++ b/clippy_lints/src/needless_update.rs @@ -49,7 +49,7 @@ declare_lint_pass!(NeedlessUpdate => [NEEDLESS_UPDATE]); impl<'tcx> LateLintPass<'tcx> for NeedlessUpdate { fn check_expr(&mut self, cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) { - if let ExprKind::Struct(_, ref fields, Some(ref base)) = expr.kind { + if let ExprKind::Struct(_, fields, Some(base)) = expr.kind { let ty = cx.typeck_results().expr_ty(expr); if let ty::Adt(def, _) = ty.kind() { if fields.len() == def.non_enum_variant().fields.len() diff --git a/clippy_lints/src/neg_cmp_op_on_partial_ord.rs b/clippy_lints/src/neg_cmp_op_on_partial_ord.rs index 4b935c7b906..0704173a011 100644 --- a/clippy_lints/src/neg_cmp_op_on_partial_ord.rs +++ b/clippy_lints/src/neg_cmp_op_on_partial_ord.rs @@ -51,8 +51,8 @@ impl<'tcx> LateLintPass<'tcx> for NoNegCompOpForPartialOrd { if_chain! { if !in_external_macro(cx.sess(), expr.span); - if let ExprKind::Unary(UnOp::Not, ref inner) = expr.kind; - if let ExprKind::Binary(ref op, ref left, _) = inner.kind; + if let ExprKind::Unary(UnOp::Not, inner) = expr.kind; + if let ExprKind::Binary(ref op, left, _) = inner.kind; if let BinOpKind::Le | BinOpKind::Ge | BinOpKind::Lt | BinOpKind::Gt = op.node; then { diff --git a/clippy_lints/src/neg_multiply.rs b/clippy_lints/src/neg_multiply.rs index 7b00879251f..34fd012572f 100644 --- a/clippy_lints/src/neg_multiply.rs +++ b/clippy_lints/src/neg_multiply.rs @@ -28,12 +28,12 @@ declare_lint_pass!(NegMultiply => [NEG_MULTIPLY]); #[allow(clippy::match_same_arms)] impl<'tcx> LateLintPass<'tcx> for NegMultiply { fn check_expr(&mut self, cx: &LateContext<'tcx>, e: &'tcx Expr<'_>) { - if let ExprKind::Binary(ref op, ref left, ref right) = e.kind { + if let ExprKind::Binary(ref op, left, right) = e.kind { if BinOpKind::Mul == op.node { match (&left.kind, &right.kind) { (&ExprKind::Unary(..), &ExprKind::Unary(..)) => {}, - (&ExprKind::Unary(UnOp::Neg, ref lit), _) => check_mul(cx, e.span, lit, right), - (_, &ExprKind::Unary(UnOp::Neg, ref lit)) => check_mul(cx, e.span, lit, left), + (&ExprKind::Unary(UnOp::Neg, lit), _) => check_mul(cx, e.span, lit, right), + (_, &ExprKind::Unary(UnOp::Neg, lit)) => check_mul(cx, e.span, lit, left), _ => {}, } } diff --git a/clippy_lints/src/no_effect.rs b/clippy_lints/src/no_effect.rs index 83953a16bc8..cfcaf509471 100644 --- a/clippy_lints/src/no_effect.rs +++ b/clippy_lints/src/no_effect.rs @@ -51,23 +51,21 @@ fn has_no_effect(cx: &LateContext<'_>, expr: &Expr<'_>) -> bool { match expr.kind { ExprKind::Lit(..) | ExprKind::Closure(..) => true, ExprKind::Path(..) => !has_drop(cx, cx.typeck_results().expr_ty(expr)), - ExprKind::Index(ref a, ref b) | ExprKind::Binary(_, ref a, ref b) => { - has_no_effect(cx, a) && has_no_effect(cx, b) - }, - ExprKind::Array(ref v) | ExprKind::Tup(ref v) => v.iter().all(|val| has_no_effect(cx, val)), - ExprKind::Repeat(ref inner, _) - | ExprKind::Cast(ref inner, _) - | ExprKind::Type(ref inner, _) - | ExprKind::Unary(_, ref inner) - | ExprKind::Field(ref inner, _) - | ExprKind::AddrOf(_, _, ref inner) - | ExprKind::Box(ref inner) => has_no_effect(cx, inner), - ExprKind::Struct(_, ref fields, ref base) => { + ExprKind::Index(a, b) | ExprKind::Binary(_, a, b) => has_no_effect(cx, a) && has_no_effect(cx, b), + ExprKind::Array(v) | ExprKind::Tup(v) => v.iter().all(|val| has_no_effect(cx, val)), + ExprKind::Repeat(inner, _) + | ExprKind::Cast(inner, _) + | ExprKind::Type(inner, _) + | ExprKind::Unary(_, inner) + | ExprKind::Field(inner, _) + | ExprKind::AddrOf(_, _, inner) + | ExprKind::Box(inner) => has_no_effect(cx, inner), + ExprKind::Struct(_, fields, ref base) => { !has_drop(cx, cx.typeck_results().expr_ty(expr)) - && fields.iter().all(|field| has_no_effect(cx, &field.expr)) + && fields.iter().all(|field| has_no_effect(cx, field.expr)) && base.as_ref().map_or(true, |base| has_no_effect(cx, base)) }, - ExprKind::Call(ref callee, ref args) => { + ExprKind::Call(callee, args) => { if let ExprKind::Path(ref qpath) = callee.kind { let res = cx.qpath_res(qpath, callee.hir_id); match res { @@ -81,7 +79,7 @@ fn has_no_effect(cx: &LateContext<'_>, expr: &Expr<'_>) -> bool { false } }, - ExprKind::Block(ref block, _) => { + ExprKind::Block(block, _) => { block.stmts.is_empty() && block.expr.as_ref().map_or(false, |expr| has_no_effect(cx, expr)) }, _ => false, @@ -92,7 +90,7 @@ declare_lint_pass!(NoEffect => [NO_EFFECT, UNNECESSARY_OPERATION]); impl<'tcx> LateLintPass<'tcx> for NoEffect { fn check_stmt(&mut self, cx: &LateContext<'tcx>, stmt: &'tcx Stmt<'_>) { - if let StmtKind::Semi(ref expr) = stmt.kind { + if let StmtKind::Semi(expr) = stmt.kind { if has_no_effect(cx, expr) { span_lint(cx, NO_EFFECT, stmt.span, "statement with no effect"); } else if let Some(reduced) = reduce_expression(cx, expr) { @@ -127,26 +125,26 @@ fn reduce_expression<'a>(cx: &LateContext<'_>, expr: &'a Expr<'a>) -> Option Some(vec![&**a, &**b]), - ExprKind::Binary(ref binop, ref a, ref b) if binop.node != BinOpKind::And && binop.node != BinOpKind::Or => { - Some(vec![&**a, &**b]) + ExprKind::Index(a, b) => Some(vec![a, b]), + ExprKind::Binary(ref binop, a, b) if binop.node != BinOpKind::And && binop.node != BinOpKind::Or => { + Some(vec![a, b]) }, - ExprKind::Array(ref v) | ExprKind::Tup(ref v) => Some(v.iter().collect()), - ExprKind::Repeat(ref inner, _) - | ExprKind::Cast(ref inner, _) - | ExprKind::Type(ref inner, _) - | ExprKind::Unary(_, ref inner) - | ExprKind::Field(ref inner, _) - | ExprKind::AddrOf(_, _, ref inner) - | ExprKind::Box(ref inner) => reduce_expression(cx, inner).or_else(|| Some(vec![inner])), - ExprKind::Struct(_, ref fields, ref base) => { + ExprKind::Array(v) | ExprKind::Tup(v) => Some(v.iter().collect()), + ExprKind::Repeat(inner, _) + | ExprKind::Cast(inner, _) + | ExprKind::Type(inner, _) + | ExprKind::Unary(_, inner) + | ExprKind::Field(inner, _) + | ExprKind::AddrOf(_, _, inner) + | ExprKind::Box(inner) => reduce_expression(cx, inner).or_else(|| Some(vec![inner])), + ExprKind::Struct(_, fields, ref base) => { if has_drop(cx, cx.typeck_results().expr_ty(expr)) { None } else { Some(fields.iter().map(|f| &f.expr).chain(base).map(Deref::deref).collect()) } }, - ExprKind::Call(ref callee, ref args) => { + ExprKind::Call(callee, args) => { if let ExprKind::Path(ref qpath) = callee.kind { let res = cx.qpath_res(qpath, callee.hir_id); match res { @@ -161,7 +159,7 @@ fn reduce_expression<'a>(cx: &LateContext<'_>, expr: &'a Expr<'a>) -> Option { + ExprKind::Block(block, _) => { if block.stmts.is_empty() { block.expr.as_ref().and_then(|e| { match block.rules { diff --git a/clippy_lints/src/non_octal_unix_permissions.rs b/clippy_lints/src/non_octal_unix_permissions.rs index 6d45e7bc6cf..a83daea97bf 100644 --- a/clippy_lints/src/non_octal_unix_permissions.rs +++ b/clippy_lints/src/non_octal_unix_permissions.rs @@ -44,7 +44,7 @@ impl LateLintPass<'_> for NonOctalUnixPermissions { fn check_expr(&mut self, cx: &LateContext<'tcx>, expr: &'tcx Expr<'tcx>) { match &expr.kind { ExprKind::MethodCall(path, _, [func, param], _) => { - let obj_ty = cx.typeck_results().expr_ty(&func).peel_refs(); + let obj_ty = cx.typeck_results().expr_ty(func).peel_refs(); if_chain! { if (path.ident.name == sym!(mode) @@ -65,7 +65,7 @@ impl LateLintPass<'_> for NonOctalUnixPermissions { } } }, - ExprKind::Call(ref func, [param]) => { + ExprKind::Call(func, [param]) => { if_chain! { if let ExprKind::Path(ref path) = func.kind; if let Some(def_id) = cx.qpath_res(path, func.hir_id).opt_def_id(); diff --git a/clippy_lints/src/open_options.rs b/clippy_lints/src/open_options.rs index c61dff4b8e0..9efe45336bf 100644 --- a/clippy_lints/src/open_options.rs +++ b/clippy_lints/src/open_options.rs @@ -31,7 +31,7 @@ declare_lint_pass!(OpenOptions => [NONSENSICAL_OPEN_OPTIONS]); impl<'tcx> LateLintPass<'tcx> for OpenOptions { fn check_expr(&mut self, cx: &LateContext<'tcx>, e: &'tcx Expr<'_>) { - if let ExprKind::MethodCall(ref path, _, ref arguments, _) = e.kind { + if let ExprKind::MethodCall(path, _, arguments, _) = e.kind { let obj_ty = cx.typeck_results().expr_ty(&arguments[0]).peel_refs(); if path.ident.name == sym!(open) && match_type(cx, obj_ty, &paths::OPEN_OPTIONS) { let mut options = Vec::new(); @@ -59,7 +59,7 @@ enum OpenOption { } fn get_open_options(cx: &LateContext<'_>, argument: &Expr<'_>, options: &mut Vec<(OpenOption, Argument)>) { - if let ExprKind::MethodCall(ref path, _, ref arguments, _) = argument.kind { + if let ExprKind::MethodCall(path, _, arguments, _) = argument.kind { let obj_ty = cx.typeck_results().expr_ty(&arguments[0]).peel_refs(); // Only proceed if this is a call on some object of type std::fs::OpenOptions diff --git a/clippy_lints/src/option_if_let_else.rs b/clippy_lints/src/option_if_let_else.rs index a76a4a33f1f..1b9120ae45f 100644 --- a/clippy_lints/src/option_if_let_else.rs +++ b/clippy_lints/src/option_if_let_else.rs @@ -66,9 +66,9 @@ declare_lint_pass!(OptionIfLetElse => [OPTION_IF_LET_ELSE]); /// Returns true iff the given expression is the result of calling `Result::ok` fn is_result_ok(cx: &LateContext<'_>, expr: &'_ Expr<'_>) -> bool { - if let ExprKind::MethodCall(ref path, _, &[ref receiver], _) = &expr.kind { + if let ExprKind::MethodCall(path, _, &[ref receiver], _) = &expr.kind { path.ident.name.as_str() == "ok" - && is_type_diagnostic_item(cx, &cx.typeck_results().expr_ty(&receiver), sym::result_type) + && is_type_diagnostic_item(cx, cx.typeck_results().expr_ty(receiver), sym::result_type) } else { false } @@ -97,9 +97,9 @@ fn extract_body_from_arm<'a>(arm: &'a Arm<'a>) -> Option<&'a Expr<'a>> { ) = &arm.body.kind { if let [] = statements { - Some(&expr) + Some(expr) } else { - Some(&arm.body) + Some(arm.body) } } else { None diff --git a/clippy_lints/src/overflow_check_conditional.rs b/clippy_lints/src/overflow_check_conditional.rs index cf667c6e805..e222782c2cc 100644 --- a/clippy_lints/src/overflow_check_conditional.rs +++ b/clippy_lints/src/overflow_check_conditional.rs @@ -31,11 +31,11 @@ impl<'tcx> LateLintPass<'tcx> for OverflowCheckConditional { fn check_expr(&mut self, cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) { let eq = |l, r| SpanlessEq::new(cx).eq_path_segment(l, r); if_chain! { - if let ExprKind::Binary(ref op, ref first, ref second) = expr.kind; - if let ExprKind::Binary(ref op2, ref ident1, ref ident2) = first.kind; - if let ExprKind::Path(QPath::Resolved(_, ref path1)) = ident1.kind; - if let ExprKind::Path(QPath::Resolved(_, ref path2)) = ident2.kind; - if let ExprKind::Path(QPath::Resolved(_, ref path3)) = second.kind; + if let ExprKind::Binary(ref op, first, second) = expr.kind; + if let ExprKind::Binary(ref op2, ident1, ident2) = first.kind; + if let ExprKind::Path(QPath::Resolved(_, path1)) = ident1.kind; + if let ExprKind::Path(QPath::Resolved(_, path2)) = ident2.kind; + if let ExprKind::Path(QPath::Resolved(_, path3)) = second.kind; if eq(&path1.segments[0], &path3.segments[0]) || eq(&path2.segments[0], &path3.segments[0]); if cx.typeck_results().expr_ty(ident1).is_integral(); if cx.typeck_results().expr_ty(ident2).is_integral(); @@ -56,11 +56,11 @@ impl<'tcx> LateLintPass<'tcx> for OverflowCheckConditional { } if_chain! { - if let ExprKind::Binary(ref op, ref first, ref second) = expr.kind; - if let ExprKind::Binary(ref op2, ref ident1, ref ident2) = second.kind; - if let ExprKind::Path(QPath::Resolved(_, ref path1)) = ident1.kind; - if let ExprKind::Path(QPath::Resolved(_, ref path2)) = ident2.kind; - if let ExprKind::Path(QPath::Resolved(_, ref path3)) = first.kind; + if let ExprKind::Binary(ref op, first, second) = expr.kind; + if let ExprKind::Binary(ref op2, ident1, ident2) = second.kind; + if let ExprKind::Path(QPath::Resolved(_, path1)) = ident1.kind; + if let ExprKind::Path(QPath::Resolved(_, path2)) = ident2.kind; + if let ExprKind::Path(QPath::Resolved(_, path3)) = first.kind; if eq(&path1.segments[0], &path3.segments[0]) || eq(&path2.segments[0], &path3.segments[0]); if cx.typeck_results().expr_ty(ident1).is_integral(); if cx.typeck_results().expr_ty(ident2).is_integral(); diff --git a/clippy_lints/src/pass_by_ref_or_value.rs b/clippy_lints/src/pass_by_ref_or_value.rs index 9a5b1c3b944..c86a847b2ee 100644 --- a/clippy_lints/src/pass_by_ref_or_value.rs +++ b/clippy_lints/src/pass_by_ref_or_value.rs @@ -141,11 +141,11 @@ impl<'tcx> PassByRefOrValue { }; if_chain! { - if !output_lts.contains(&input_lt); + if !output_lts.contains(input_lt); if is_copy(cx, ty); if let Some(size) = cx.layout_of(ty).ok().map(|l| l.size.bytes()); if size <= self.ref_min_size; - if let hir::TyKind::Rptr(_, MutTy { ty: ref decl_ty, .. }) = input.kind; + if let hir::TyKind::Rptr(_, MutTy { ty: decl_ty, .. }) = input.kind; then { let value_type = if is_self_ty(decl_ty) { "self".into() diff --git a/clippy_lints/src/path_buf_push_overwrite.rs b/clippy_lints/src/path_buf_push_overwrite.rs index 95ffae28d8c..00245926381 100644 --- a/clippy_lints/src/path_buf_push_overwrite.rs +++ b/clippy_lints/src/path_buf_push_overwrite.rs @@ -45,7 +45,7 @@ declare_lint_pass!(PathBufPushOverwrite => [PATH_BUF_PUSH_OVERWRITE]); impl<'tcx> LateLintPass<'tcx> for PathBufPushOverwrite { fn check_expr(&mut self, cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) { if_chain! { - if let ExprKind::MethodCall(ref path, _, ref args, _) = expr.kind; + if let ExprKind::MethodCall(path, _, args, _) = expr.kind; if path.ident.name == sym!(push); if args.len() == 2; if is_type_diagnostic_item(cx, cx.typeck_results().expr_ty(&args[0]).peel_refs(), sym::PathBuf); diff --git a/clippy_lints/src/pattern_type_mismatch.rs b/clippy_lints/src/pattern_type_mismatch.rs index 4550b367da4..8c198cecd6a 100644 --- a/clippy_lints/src/pattern_type_mismatch.rs +++ b/clippy_lints/src/pattern_type_mismatch.rs @@ -86,7 +86,7 @@ declare_lint_pass!(PatternTypeMismatch => [PATTERN_TYPE_MISMATCH]); impl<'tcx> LateLintPass<'tcx> for PatternTypeMismatch { fn check_stmt(&mut self, cx: &LateContext<'tcx>, stmt: &'tcx Stmt<'_>) { - if let StmtKind::Local(ref local) = stmt.kind { + if let StmtKind::Local(local) = stmt.kind { if let Some(init) = &local.init { if let Some(init_ty) = cx.typeck_results().node_type_opt(init.hir_id) { let pat = &local.pat; @@ -104,7 +104,7 @@ impl<'tcx> LateLintPass<'tcx> for PatternTypeMismatch { } fn check_expr(&mut self, cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) { - if let ExprKind::Match(ref expr, arms, source) = expr.kind { + if let ExprKind::Match(expr, arms, source) = expr.kind { match source { MatchSource::Normal | MatchSource::IfLetDesugar { .. } | MatchSource::WhileLetDesugar => { if let Some(expr_ty) = cx.typeck_results().node_type_opt(expr.hir_id) { @@ -135,7 +135,7 @@ impl<'tcx> LateLintPass<'tcx> for PatternTypeMismatch { ) { if let Some(fn_sig) = cx.typeck_results().liberated_fn_sigs().get(hir_id) { for (param, ty) in body.params.iter().zip(fn_sig.inputs().iter()) { - apply_lint(cx, ¶m.pat, ty, DerefPossible::Impossible); + apply_lint(cx, param.pat, ty, DerefPossible::Impossible); } } } @@ -187,7 +187,7 @@ fn find_first_mismatch<'tcx>( ty: Ty<'tcx>, level: Level, ) -> Option<(Span, Mutability, Level)> { - if let PatKind::Ref(ref sub_pat, _) = pat.kind { + if let PatKind::Ref(sub_pat, _) = pat.kind { if let TyKind::Ref(_, sub_ty, _) = ty.kind() { return find_first_mismatch(cx, sub_pat, sub_ty, Level::Lower); } @@ -199,8 +199,8 @@ fn find_first_mismatch<'tcx>( } } - if let PatKind::Struct(ref qpath, ref field_pats, _) = pat.kind { - if let TyKind::Adt(ref adt_def, ref substs_ref) = ty.kind() { + if let PatKind::Struct(ref qpath, field_pats, _) = pat.kind { + if let TyKind::Adt(adt_def, substs_ref) = ty.kind() { if let Some(variant) = get_variant(adt_def, qpath) { let field_defs = &variant.fields; return find_first_mismatch_in_struct(cx, field_pats, field_defs, substs_ref); @@ -208,8 +208,8 @@ fn find_first_mismatch<'tcx>( } } - if let PatKind::TupleStruct(ref qpath, ref pats, _) = pat.kind { - if let TyKind::Adt(ref adt_def, ref substs_ref) = ty.kind() { + if let PatKind::TupleStruct(ref qpath, pats, _) = pat.kind { + if let TyKind::Adt(adt_def, substs_ref) = ty.kind() { if let Some(variant) = get_variant(adt_def, qpath) { let field_defs = &variant.fields; let ty_iter = field_defs.iter().map(|field_def| field_def.ty(cx.tcx, substs_ref)); @@ -218,7 +218,7 @@ fn find_first_mismatch<'tcx>( } } - if let PatKind::Tuple(ref pats, _) = pat.kind { + if let PatKind::Tuple(pats, _) = pat.kind { if let TyKind::Tuple(..) = ty.kind() { return find_first_mismatch_in_tuple(cx, pats, ty.tuple_fields()); } diff --git a/clippy_lints/src/ptr.rs b/clippy_lints/src/ptr.rs index 6e530d0ffb0..09fcdb5faf8 100644 --- a/clippy_lints/src/ptr.rs +++ b/clippy_lints/src/ptr.rs @@ -124,7 +124,7 @@ declare_lint_pass!(Ptr => [PTR_ARG, CMP_NULL, MUT_FROM_REF]); impl<'tcx> LateLintPass<'tcx> for Ptr { fn check_item(&mut self, cx: &LateContext<'tcx>, item: &'tcx Item<'_>) { if let ItemKind::Fn(ref sig, _, body_id) = item.kind { - check_fn(cx, &sig.decl, item.hir_id(), Some(body_id)); + check_fn(cx, sig.decl, item.hir_id(), Some(body_id)); } } @@ -136,7 +136,7 @@ impl<'tcx> LateLintPass<'tcx> for Ptr { return; // ignore trait impls } } - check_fn(cx, &sig.decl, item.hir_id(), Some(body_id)); + check_fn(cx, sig.decl, item.hir_id(), Some(body_id)); } } @@ -147,12 +147,12 @@ impl<'tcx> LateLintPass<'tcx> for Ptr { } else { None }; - check_fn(cx, &sig.decl, item.hir_id(), body_id); + check_fn(cx, sig.decl, item.hir_id(), body_id); } } fn check_expr(&mut self, cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) { - if let ExprKind::Binary(ref op, ref l, ref r) = expr.kind { + if let ExprKind::Binary(ref op, l, r) = expr.kind { if (op.node == BinOpKind::Eq || op.node == BinOpKind::Ne) && (is_null_path(l) || is_null_path(r)) { span_lint( cx, @@ -262,10 +262,10 @@ fn check_fn(cx: &LateContext<'_>, decl: &FnDecl<'_>, fn_id: HirId, opt_body_id: } } else if match_type(cx, ty, &paths::COW) { if_chain! { - if let TyKind::Rptr(_, MutTy { ref ty, ..} ) = arg.kind; - if let TyKind::Path(QPath::Resolved(None, ref pp)) = ty.kind; + if let TyKind::Rptr(_, MutTy { ty, ..} ) = arg.kind; + if let TyKind::Path(QPath::Resolved(None, pp)) = ty.kind; if let [ref bx] = *pp.segments; - if let Some(ref params) = bx.args; + if let Some(params) = bx.args; if !params.parenthesized; if let Some(inner) = params.args.iter().find_map(|arg| match arg { GenericArg::Type(ty) => Some(ty), @@ -289,7 +289,7 @@ fn check_fn(cx: &LateContext<'_>, decl: &FnDecl<'_>, fn_id: HirId, opt_body_id: } } - if let FnRetTy::Return(ref ty) = decl.output { + if let FnRetTy::Return(ty) = decl.output { if let Some((out, Mutability::Mut, _)) = get_rptr_lm(ty) { let mut immutables = vec![]; for (_, ref mutbl, ref argspan) in decl @@ -322,8 +322,8 @@ fn check_fn(cx: &LateContext<'_>, decl: &FnDecl<'_>, fn_id: HirId, opt_body_id: fn get_only_generic_arg_snippet(cx: &LateContext<'_>, arg: &Ty<'_>) -> Option { if_chain! { - if let TyKind::Path(QPath::Resolved(_, ref path)) = walk_ptrs_hir_ty(arg).kind; - if let Some(&PathSegment{args: Some(ref parameters), ..}) = path.segments.last(); + if let TyKind::Path(QPath::Resolved(_, path)) = walk_ptrs_hir_ty(arg).kind; + if let Some(&PathSegment{args: Some(parameters), ..}) = path.segments.last(); let types: Vec<_> = parameters.args.iter().filter_map(|arg| match arg { GenericArg::Type(ty) => Some(ty), _ => None, @@ -346,7 +346,7 @@ fn get_rptr_lm<'tcx>(ty: &'tcx Ty<'tcx>) -> Option<(&'tcx Lifetime, Mutability, } fn is_null_path(expr: &Expr<'_>) -> bool { - if let ExprKind::Call(ref pathexp, ref args) = expr.kind { + if let ExprKind::Call(pathexp, args) = expr.kind { if args.is_empty() { if let ExprKind::Path(ref path) = pathexp.kind { return match_qpath(path, &paths::PTR_NULL) || match_qpath(path, &paths::PTR_NULL_MUT); diff --git a/clippy_lints/src/ptr_eq.rs b/clippy_lints/src/ptr_eq.rs index 5796c59c8b3..77cfa3f6b17 100644 --- a/clippy_lints/src/ptr_eq.rs +++ b/clippy_lints/src/ptr_eq.rs @@ -46,11 +46,11 @@ impl LateLintPass<'_> for PtrEq { return; } - if let ExprKind::Binary(ref op, ref left, ref right) = expr.kind { + if let ExprKind::Binary(ref op, left, right) = expr.kind { if BinOpKind::Eq == op.node { let (left, right) = match (expr_as_cast_to_usize(cx, left), expr_as_cast_to_usize(cx, right)) { (Some(lhs), Some(rhs)) => (lhs, rhs), - _ => (&**left, &**right), + _ => (left, right), }; if_chain! { @@ -79,7 +79,7 @@ impl LateLintPass<'_> for PtrEq { // E.g., `foo as *const _ as usize` returns `foo as *const _`. fn expr_as_cast_to_usize<'tcx>(cx: &LateContext<'tcx>, cast_expr: &'tcx Expr<'_>) -> Option<&'tcx Expr<'tcx>> { if cx.typeck_results().expr_ty(cast_expr) == cx.tcx.types.usize { - if let ExprKind::Cast(ref expr, _) = cast_expr.kind { + if let ExprKind::Cast(expr, _) = cast_expr.kind { return Some(expr); } } @@ -90,7 +90,7 @@ fn expr_as_cast_to_usize<'tcx>(cx: &LateContext<'tcx>, cast_expr: &'tcx Expr<'_> // E.g., `foo as *const _` returns `foo`. fn expr_as_cast_to_raw_pointer<'tcx>(cx: &LateContext<'tcx>, cast_expr: &'tcx Expr<'_>) -> Option<&'tcx Expr<'tcx>> { if cx.typeck_results().expr_ty(cast_expr).is_unsafe_ptr() { - if let ExprKind::Cast(ref expr, _) = cast_expr.kind { + if let ExprKind::Cast(expr, _) = cast_expr.kind { return Some(expr); } } diff --git a/clippy_lints/src/ptr_offset_with_cast.rs b/clippy_lints/src/ptr_offset_with_cast.rs index c04b4255256..afb198f4955 100644 --- a/clippy_lints/src/ptr_offset_with_cast.rs +++ b/clippy_lints/src/ptr_offset_with_cast.rs @@ -78,8 +78,8 @@ impl<'tcx> LateLintPass<'tcx> for PtrOffsetWithCast { // If the given expression is a cast from a usize, return the lhs of the cast fn expr_as_cast_from_usize<'tcx>(cx: &LateContext<'tcx>, expr: &'tcx Expr<'tcx>) -> Option<&'tcx Expr<'tcx>> { - if let ExprKind::Cast(ref cast_lhs_expr, _) = expr.kind { - if is_expr_ty_usize(cx, &cast_lhs_expr) { + if let ExprKind::Cast(cast_lhs_expr, _) = expr.kind { + if is_expr_ty_usize(cx, cast_lhs_expr) { return Some(cast_lhs_expr); } } @@ -92,7 +92,7 @@ fn expr_as_ptr_offset_call<'tcx>( cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>, ) -> Option<(&'tcx Expr<'tcx>, &'tcx Expr<'tcx>, Method)> { - if let ExprKind::MethodCall(ref path_segment, _, ref args, _) = expr.kind { + if let ExprKind::MethodCall(path_segment, _, args, _) = expr.kind { if is_expr_ty_raw_ptr(cx, &args[0]) { if path_segment.ident.name == sym::offset { return Some((&args[0], &args[1], Method::Offset)); diff --git a/clippy_lints/src/question_mark.rs b/clippy_lints/src/question_mark.rs index 2054255a7c9..6d720f43851 100644 --- a/clippy_lints/src/question_mark.rs +++ b/clippy_lints/src/question_mark.rs @@ -148,14 +148,14 @@ impl QuestionMark { fn expression_returns_none(cx: &LateContext<'_>, expression: &Expr<'_>) -> bool { match expression.kind { - ExprKind::Block(ref block, _) => { + ExprKind::Block(block, _) => { if let Some(return_expression) = Self::return_expression(block) { - return Self::expression_returns_none(cx, &return_expression); + return Self::expression_returns_none(cx, return_expression); } false }, - ExprKind::Ret(Some(ref expr)) => Self::expression_returns_none(cx, expr), + ExprKind::Ret(Some(expr)) => Self::expression_returns_none(cx, expr), ExprKind::Path(ref qp) => { if let Res::Def(DefKind::Ctor(def::CtorOf::Variant, def::CtorKind::Const), def_id) = cx.qpath_res(qp, expression.hir_id) @@ -174,7 +174,7 @@ impl QuestionMark { if_chain! { if block.stmts.len() == 1; if let Some(expr) = block.stmts.iter().last(); - if let StmtKind::Semi(ref expr) = expr.kind; + if let StmtKind::Semi(expr) = expr.kind; if let ExprKind::Ret(Some(ret_expr)) = expr.kind; then { diff --git a/clippy_lints/src/ranges.rs b/clippy_lints/src/ranges.rs index 79692abb6ac..1c3c125e579 100644 --- a/clippy_lints/src/ranges.rs +++ b/clippy_lints/src/ranges.rs @@ -183,10 +183,10 @@ impl_lint_pass!(Ranges => [ impl<'tcx> LateLintPass<'tcx> for Ranges { fn check_expr(&mut self, cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) { match expr.kind { - ExprKind::MethodCall(ref path, _, ref args, _) => { + ExprKind::MethodCall(path, _, args, _) => { check_range_zip_with_len(cx, path, args, expr.span); }, - ExprKind::Binary(ref op, ref l, ref r) => { + ExprKind::Binary(ref op, l, r) => { if meets_msrv(self.msrv.as_ref(), &MANUAL_RANGE_CONTAINS_MSRV) { check_possible_range_contains(cx, op.node, l, r, expr); } @@ -287,7 +287,7 @@ fn check_possible_range_contains(cx: &LateContext<'_>, op: BinOpKind, l: &Expr<' } fn check_range_bounds(cx: &LateContext<'_>, ex: &Expr<'_>) -> Option<(Constant, Ident, Span, Span, Ordering, bool)> { - if let ExprKind::Binary(ref op, ref l, ref r) = ex.kind { + if let ExprKind::Binary(ref op, l, r) = ex.kind { let (inclusive, ordering) = match op.node { BinOpKind::Gt => (false, Ordering::Greater), BinOpKind::Ge => (true, Ordering::Greater), @@ -324,18 +324,18 @@ fn check_range_zip_with_len(cx: &LateContext<'_>, path: &PathSegment<'_>, args: if path.ident.as_str() == "zip"; if let [iter, zip_arg] = args; // `.iter()` call - if let ExprKind::MethodCall(ref iter_path, _, ref iter_args, _) = iter.kind; + if let ExprKind::MethodCall(iter_path, _, iter_args, _) = iter.kind; if iter_path.ident.name == sym::iter; // range expression in `.zip()` call: `0..x.len()` if let Some(higher::Range { start: Some(start), end: Some(end), .. }) = higher::range(zip_arg); if is_integer_const(cx, start, 0); // `.len()` call - if let ExprKind::MethodCall(ref len_path, _, ref len_args, _) = end.kind; + if let ExprKind::MethodCall(len_path, _, len_args, _) = end.kind; if len_path.ident.name == sym!(len) && len_args.len() == 1; // `.iter()` and `.len()` called on same `Path` - if let ExprKind::Path(QPath::Resolved(_, ref iter_path)) = iter_args[0].kind; - if let ExprKind::Path(QPath::Resolved(_, ref len_path)) = len_args[0].kind; - if SpanlessEq::new(cx).eq_path_segments(&iter_path.segments, &len_path.segments); + if let ExprKind::Path(QPath::Resolved(_, iter_path)) = iter_args[0].kind; + if let ExprKind::Path(QPath::Resolved(_, len_path)) = len_args[0].kind; + if SpanlessEq::new(cx).eq_path_segments(iter_path.segments, len_path.segments); then { span_lint(cx, RANGE_ZIP_WITH_LEN, @@ -508,8 +508,8 @@ fn y_plus_one<'t>(cx: &LateContext<'_>, expr: &'t Expr<'_>) -> Option<&'t Expr<' Spanned { node: BinOpKind::Add, .. }, - ref lhs, - ref rhs, + lhs, + rhs, ) => { if is_integer_const(cx, lhs, 1) { Some(rhs) @@ -529,8 +529,8 @@ fn y_minus_one<'t>(cx: &LateContext<'_>, expr: &'t Expr<'_>) -> Option<&'t Expr< Spanned { node: BinOpKind::Sub, .. }, - ref lhs, - ref rhs, + lhs, + rhs, ) if is_integer_const(cx, rhs, 1) => Some(lhs), _ => None, } diff --git a/clippy_lints/src/redundant_clone.rs b/clippy_lints/src/redundant_clone.rs index 9656ee64c81..19650c41b84 100644 --- a/clippy_lints/src/redundant_clone.rs +++ b/clippy_lints/src/redundant_clone.rs @@ -94,7 +94,7 @@ impl<'tcx> LateLintPass<'tcx> for RedundantClone { .into_results_cursor(mir); let mut possible_borrower = { let mut vis = PossibleBorrowerVisitor::new(cx, mir); - vis.visit_body(&mir); + vis.visit_body(mir); vis.into_map(cx, maybe_storage_live_result) }; @@ -126,7 +126,7 @@ impl<'tcx> LateLintPass<'tcx> for RedundantClone { continue; } - if let ty::Adt(ref def, _) = arg_ty.kind() { + if let ty::Adt(def, _) = arg_ty.kind() { if match_def_path(cx, def.did, &paths::MEM_MANUALLY_DROP) { continue; } @@ -206,7 +206,7 @@ impl<'tcx> LateLintPass<'tcx> for RedundantClone { clone_consumed_or_mutated: true, } } else { - let clone_usage = visit_clone_usage(local, ret_local, &mir, bb); + let clone_usage = visit_clone_usage(local, ret_local, mir, bb); if clone_usage.cloned_used && clone_usage.clone_consumed_or_mutated { // cloned value is used, and the clone is modified or moved continue; @@ -426,7 +426,7 @@ fn visit_clone_usage(cloned: mir::Local, clone: mir::Local, mir: &mir::Body<'_>, // TODO: Actually check for mutation of non-temporaries. clone_consumed_or_mutated: mir.local_kind(clone) != mir::LocalKind::Temp, }; - traversal::ReversePostorder::new(&mir, bb) + traversal::ReversePostorder::new(mir, bb) .skip(1) .fold(init, |usage, (tbb, tdata)| { // Short-circuit @@ -588,7 +588,7 @@ impl<'a, 'tcx> mir::visit::Visitor<'tcx> for PossibleBorrowerVisitor<'a, 'tcx> { // If the call returns something with lifetimes, // let's conservatively assume the returned value contains lifetime of all the arguments. // For example, given `let y: Foo<'a> = foo(x)`, `y` is considered to be a possible borrower of `x`. - if ContainsRegion.visit_ty(&self.body.local_decls[*dest].ty).is_continue() { + if ContainsRegion.visit_ty(self.body.local_decls[*dest].ty).is_continue() { return; } diff --git a/clippy_lints/src/redundant_closure_call.rs b/clippy_lints/src/redundant_closure_call.rs index 5429d389610..92921bedf4d 100644 --- a/clippy_lints/src/redundant_closure_call.rs +++ b/clippy_lints/src/redundant_closure_call.rs @@ -111,8 +111,8 @@ impl<'tcx> LateLintPass<'tcx> for RedundantClosureCall { fn visit_expr(&mut self, expr: &'tcx hir::Expr<'tcx>) { if_chain! { - if let hir::ExprKind::Call(ref closure, _) = expr.kind; - if let hir::ExprKind::Path(hir::QPath::Resolved(_, ref path)) = closure.kind; + if let hir::ExprKind::Call(closure, _) = expr.kind; + if let hir::ExprKind::Path(hir::QPath::Resolved(_, path)) = closure.kind; if self.path.segments[0].ident == path.segments[0].ident; if self.path.res == path.res; then { @@ -133,14 +133,14 @@ impl<'tcx> LateLintPass<'tcx> for RedundantClosureCall { for w in block.stmts.windows(2) { if_chain! { - if let hir::StmtKind::Local(ref local) = w[0].kind; - if let Option::Some(ref t) = local.init; + if let hir::StmtKind::Local(local) = w[0].kind; + if let Option::Some(t) = local.init; if let hir::ExprKind::Closure(..) = t.kind; if let hir::PatKind::Binding(_, _, ident, _) = local.pat.kind; - if let hir::StmtKind::Semi(ref second) = w[1].kind; - if let hir::ExprKind::Assign(_, ref call, _) = second.kind; - if let hir::ExprKind::Call(ref closure, _) = call.kind; - if let hir::ExprKind::Path(hir::QPath::Resolved(_, ref path)) = closure.kind; + if let hir::StmtKind::Semi(second) = w[1].kind; + if let hir::ExprKind::Assign(_, call, _) = second.kind; + if let hir::ExprKind::Call(closure, _) = call.kind; + if let hir::ExprKind::Path(hir::QPath::Resolved(_, path)) = closure.kind; if ident == path.segments[0].ident; if count_closure_usage(cx, block, path) == 1; then { diff --git a/clippy_lints/src/ref_option_ref.rs b/clippy_lints/src/ref_option_ref.rs index 0922cfa494e..0cf4e0ce7fe 100644 --- a/clippy_lints/src/ref_option_ref.rs +++ b/clippy_lints/src/ref_option_ref.rs @@ -44,7 +44,7 @@ impl<'tcx> LateLintPass<'tcx> for RefOptionRef { if let Some(def_id) = res.opt_def_id(); if cx.tcx.is_diagnostic_item(sym::option_type, def_id); - if let Some(ref params) = last_path_segment(qpath).args ; + if let Some(params) = last_path_segment(qpath).args ; if !params.parenthesized; if let Some(inner_ty) = params.args.iter().find_map(|arg| match arg { GenericArg::Type(inner_ty) => Some(inner_ty), diff --git a/clippy_lints/src/regex.rs b/clippy_lints/src/regex.rs index 1cc332de894..4b5306de58e 100644 --- a/clippy_lints/src/regex.rs +++ b/clippy_lints/src/regex.rs @@ -60,7 +60,7 @@ impl_lint_pass!(Regex => [INVALID_REGEX, TRIVIAL_REGEX]); impl<'tcx> LateLintPass<'tcx> for Regex { fn check_expr(&mut self, cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) { if_chain! { - if let ExprKind::Call(ref fun, ref args) = expr.kind; + if let ExprKind::Call(fun, args) = expr.kind; if let ExprKind::Path(ref qpath) = fun.kind; if args.len() == 1; if let Some(def_id) = cx.qpath_res(qpath, fun.hir_id).opt_def_id(); @@ -134,7 +134,7 @@ fn is_trivial_regex(s: ®ex_syntax::hir::Hir) -> Option<&'static str> { fn check_set<'tcx>(cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>, utf8: bool) { if_chain! { - if let ExprKind::AddrOf(BorrowKind::Ref, _, ref expr) = expr.kind; + if let ExprKind::AddrOf(BorrowKind::Ref, _, expr) = expr.kind; if let ExprKind::Array(exprs) = expr.kind; then { for expr in exprs { diff --git a/clippy_lints/src/repeat_once.rs b/clippy_lints/src/repeat_once.rs index 63e5ec69e66..560a5e7c920 100644 --- a/clippy_lints/src/repeat_once.rs +++ b/clippy_lints/src/repeat_once.rs @@ -45,10 +45,10 @@ impl<'tcx> LateLintPass<'tcx> for RepeatOnce { if_chain! { if let ExprKind::MethodCall(path, _, [receiver, count], _) = &expr.kind; if path.ident.name == sym!(repeat); - if let Some(Constant::Int(1)) = constant_context(cx, cx.typeck_results()).expr(&count); + if let Some(Constant::Int(1)) = constant_context(cx, cx.typeck_results()).expr(count); if !in_macro(receiver.span); then { - let ty = cx.typeck_results().expr_ty(&receiver).peel_refs(); + let ty = cx.typeck_results().expr_ty(receiver).peel_refs(); if ty.is_str() { span_lint_and_sugg( cx, diff --git a/clippy_lints/src/returns.rs b/clippy_lints/src/returns.rs index 8995ae431ad..af772cf4a14 100644 --- a/clippy_lints/src/returns.rs +++ b/clippy_lints/src/returns.rs @@ -102,7 +102,7 @@ impl<'tcx> LateLintPass<'tcx> for Return { err.span_label(local.span, "unnecessary `let` binding"); if let Some(mut snippet) = snippet_opt(cx, initexpr.span) { - if !cx.typeck_results().expr_adjustments(&retexpr).is_empty() { + if !cx.typeck_results().expr_adjustments(retexpr).is_empty() { snippet.push_str(" as _"); } err.multipart_suggestion( @@ -143,7 +143,7 @@ impl<'tcx> LateLintPass<'tcx> for Return { check_final_expr(cx, &body.value, Some(body.value.span), replacement) }, FnKind::ItemFn(..) | FnKind::Method(..) => { - if let ExprKind::Block(ref block, _) = body.value.kind { + if let ExprKind::Block(block, _) = body.value.kind { check_block_return(cx, block); } }, @@ -160,7 +160,7 @@ fn check_block_return<'tcx>(cx: &LateContext<'tcx>, block: &Block<'tcx>) { check_final_expr(cx, expr, Some(expr.span), RetReplacement::Empty); } else if let Some(stmt) = block.stmts.iter().last() { match stmt.kind { - StmtKind::Expr(ref expr) | StmtKind::Semi(ref expr) => { + StmtKind::Expr(expr) | StmtKind::Semi(expr) => { check_final_expr(cx, expr, Some(stmt.span), RetReplacement::Empty); }, _ => (), @@ -192,11 +192,11 @@ fn check_final_expr<'tcx>( } }, // a whole block? check it! - ExprKind::Block(ref block, _) => { + ExprKind::Block(block, _) => { check_block_return(cx, block); }, ExprKind::If(_, then, else_clause_opt) => { - if let ExprKind::Block(ref ifblock, _) = then.kind { + if let ExprKind::Block(ifblock, _) = then.kind { check_block_return(cx, ifblock); } if let Some(else_clause) = else_clause_opt { @@ -207,16 +207,16 @@ fn check_final_expr<'tcx>( // an if/if let expr, check both exprs // note, if without else is going to be a type checking error anyways // (except for unit type functions) so we don't match it - ExprKind::Match(_, ref arms, source) => match source { + ExprKind::Match(_, arms, source) => match source { MatchSource::Normal => { for arm in arms.iter() { - check_final_expr(cx, &arm.body, Some(arm.body.span), RetReplacement::Block); + check_final_expr(cx, arm.body, Some(arm.body.span), RetReplacement::Block); } }, MatchSource::IfLetDesugar { contains_else_clause: true, } => { - if let ExprKind::Block(ref ifblock, _) = arms[0].body.kind { + if let ExprKind::Block(ifblock, _) = arms[0].body.kind { check_block_return(cx, ifblock); } check_final_expr(cx, arms[1].body, None, RetReplacement::Empty); diff --git a/clippy_lints/src/semicolon_if_nothing_returned.rs b/clippy_lints/src/semicolon_if_nothing_returned.rs index f61af15fbed..553987a426b 100644 --- a/clippy_lints/src/semicolon_if_nothing_returned.rs +++ b/clippy_lints/src/semicolon_if_nothing_returned.rs @@ -51,7 +51,7 @@ impl LateLintPass<'_> for SemicolonIfNothingReturned { return; } - let sugg = sugg::Sugg::hir_with_macro_callsite(cx, &expr, ".."); + let sugg = sugg::Sugg::hir_with_macro_callsite(cx, expr, ".."); let suggestion = format!("{0};", sugg); span_lint_and_sugg( cx, diff --git a/clippy_lints/src/shadow.rs b/clippy_lints/src/shadow.rs index 612d2fd84cb..d6101bd5e36 100644 --- a/clippy_lints/src/shadow.rs +++ b/clippy_lints/src/shadow.rs @@ -130,12 +130,12 @@ fn check_block<'tcx>(cx: &LateContext<'tcx>, block: &'tcx Block<'_>, bindings: & let len = bindings.len(); for stmt in block.stmts { match stmt.kind { - StmtKind::Local(ref local) => check_local(cx, local, bindings), - StmtKind::Expr(ref e) | StmtKind::Semi(ref e) => check_expr(cx, e, bindings), + StmtKind::Local(local) => check_local(cx, local, bindings), + StmtKind::Expr(e) | StmtKind::Semi(e) => check_expr(cx, e, bindings), StmtKind::Item(..) => {}, } } - if let Some(ref o) = block.expr { + if let Some(o) = block.expr { check_expr(cx, o, bindings); } bindings.truncate(len); @@ -149,16 +149,16 @@ fn check_local<'tcx>(cx: &LateContext<'tcx>, local: &'tcx Local<'_>, bindings: & return; } let Local { - ref pat, + pat, ref ty, ref init, span, .. } = *local; - if let Some(ref t) = *ty { + if let Some(t) = *ty { check_ty(cx, t, bindings) } - if let Some(ref o) = *init { + if let Some(o) = *init { check_expr(cx, o, bindings); check_pat(cx, pat, Some(o), span, bindings); } else { @@ -196,34 +196,34 @@ fn check_pat<'tcx>( bindings.push((name, ident.span)); } } - if let Some(ref p) = *inner { + if let Some(p) = *inner { check_pat(cx, p, init, span, bindings); } }, PatKind::Struct(_, pfields, _) => { if let Some(init_struct) = init { - if let ExprKind::Struct(_, ref efields, _) = init_struct.kind { + if let ExprKind::Struct(_, efields, _) = init_struct.kind { for field in pfields { let name = field.ident.name; let efield = efields .iter() .find_map(|f| if f.ident.name == name { Some(&*f.expr) } else { None }); - check_pat(cx, &field.pat, efield, span, bindings); + check_pat(cx, field.pat, efield, span, bindings); } } else { for field in pfields { - check_pat(cx, &field.pat, init, span, bindings); + check_pat(cx, field.pat, init, span, bindings); } } } else { for field in pfields { - check_pat(cx, &field.pat, None, span, bindings); + check_pat(cx, field.pat, None, span, bindings); } } }, PatKind::Tuple(inner, _) => { if let Some(init_tup) = init { - if let ExprKind::Tup(ref tup) = init_tup.kind { + if let ExprKind::Tup(tup) = init_tup.kind { for (i, p) in inner.iter().enumerate() { check_pat(cx, p, Some(&tup[i]), p.span, bindings); } @@ -238,10 +238,10 @@ fn check_pat<'tcx>( } } }, - PatKind::Box(ref inner) => { + PatKind::Box(inner) => { if let Some(initp) = init { - if let ExprKind::Box(ref inner_init) = initp.kind { - check_pat(cx, inner, Some(&**inner_init), span, bindings); + if let ExprKind::Box(inner_init) = initp.kind { + check_pat(cx, inner, Some(inner_init), span, bindings); } else { check_pat(cx, inner, init, span, bindings); } @@ -249,7 +249,7 @@ fn check_pat<'tcx>( check_pat(cx, inner, init, span, bindings); } }, - PatKind::Ref(ref inner, _) => check_pat(cx, inner, init, span, bindings), + PatKind::Ref(inner, _) => check_pat(cx, inner, init, span, bindings), // PatVec(Vec>, Option>, Vec>), _ => (), } @@ -323,11 +323,10 @@ fn check_expr<'tcx>(cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>, bindings: &mut return; } match expr.kind { - ExprKind::Unary(_, ref e) - | ExprKind::Field(ref e, _) - | ExprKind::AddrOf(_, _, ref e) - | ExprKind::Box(ref e) => check_expr(cx, e, bindings), - ExprKind::Block(ref block, _) | ExprKind::Loop(ref block, ..) => check_block(cx, block, bindings), + ExprKind::Unary(_, e) | ExprKind::Field(e, _) | ExprKind::AddrOf(_, _, e) | ExprKind::Box(e) => { + check_expr(cx, e, bindings) + }, + ExprKind::Block(block, _) | ExprKind::Loop(block, ..) => check_block(cx, block, bindings), // ExprKind::Call // ExprKind::MethodCall ExprKind::Array(v) | ExprKind::Tup(v) => { @@ -335,18 +334,18 @@ fn check_expr<'tcx>(cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>, bindings: &mut check_expr(cx, e, bindings) } }, - ExprKind::If(ref cond, ref then, ref otherwise) => { + ExprKind::If(cond, then, ref otherwise) => { check_expr(cx, cond, bindings); - check_expr(cx, &**then, bindings); - if let Some(ref o) = *otherwise { + check_expr(cx, then, bindings); + if let Some(o) = *otherwise { check_expr(cx, o, bindings); } }, - ExprKind::Match(ref init, arms, _) => { + ExprKind::Match(init, arms, _) => { check_expr(cx, init, bindings); let len = bindings.len(); for arm in arms { - check_pat(cx, &arm.pat, Some(&**init), arm.pat.span, bindings); + check_pat(cx, arm.pat, Some(init), arm.pat.span, bindings); // This is ugly, but needed to get the right type if let Some(ref guard) = arm.guard { match guard { @@ -357,7 +356,7 @@ fn check_expr<'tcx>(cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>, bindings: &mut }, } } - check_expr(cx, &arm.body, bindings); + check_expr(cx, arm.body, bindings); bindings.truncate(len); } }, @@ -367,14 +366,12 @@ fn check_expr<'tcx>(cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>, bindings: &mut fn check_ty<'tcx>(cx: &LateContext<'tcx>, ty: &'tcx Ty<'_>, bindings: &mut Vec<(Symbol, Span)>) { match ty.kind { - TyKind::Slice(ref sty) => check_ty(cx, sty, bindings), - TyKind::Array(ref fty, ref anon_const) => { + TyKind::Slice(sty) => check_ty(cx, sty, bindings), + TyKind::Array(fty, ref anon_const) => { check_ty(cx, fty, bindings); check_expr(cx, &cx.tcx.hir().body(anon_const.body).value, bindings); }, - TyKind::Ptr(MutTy { ty: ref mty, .. }) | TyKind::Rptr(_, MutTy { ty: ref mty, .. }) => { - check_ty(cx, mty, bindings) - }, + TyKind::Ptr(MutTy { ty: mty, .. }) | TyKind::Rptr(_, MutTy { ty: mty, .. }) => check_ty(cx, mty, bindings), TyKind::Tup(tup) => { for t in tup { check_ty(cx, t, bindings) @@ -387,12 +384,12 @@ fn check_ty<'tcx>(cx: &LateContext<'tcx>, ty: &'tcx Ty<'_>, bindings: &mut Vec<( fn is_self_shadow(name: Symbol, expr: &Expr<'_>) -> bool { match expr.kind { - ExprKind::Box(ref inner) | ExprKind::AddrOf(_, _, ref inner) => is_self_shadow(name, inner), - ExprKind::Block(ref block, _) => { + ExprKind::Box(inner) | ExprKind::AddrOf(_, _, inner) => is_self_shadow(name, inner), + ExprKind::Block(block, _) => { block.stmts.is_empty() && block.expr.as_ref().map_or(false, |e| is_self_shadow(name, e)) }, - ExprKind::Unary(op, ref inner) => (UnOp::Deref == op) && is_self_shadow(name, inner), - ExprKind::Path(QPath::Resolved(_, ref path)) => path_eq_name(name, path), + ExprKind::Unary(op, inner) => (UnOp::Deref == op) && is_self_shadow(name, inner), + ExprKind::Path(QPath::Resolved(_, path)) => path_eq_name(name, path), _ => false, } } diff --git a/clippy_lints/src/slow_vector_initialization.rs b/clippy_lints/src/slow_vector_initialization.rs index d55a83f1613..8cf89ae456e 100644 --- a/clippy_lints/src/slow_vector_initialization.rs +++ b/clippy_lints/src/slow_vector_initialization.rs @@ -70,14 +70,14 @@ impl<'tcx> LateLintPass<'tcx> for SlowVectorInit { fn check_expr(&mut self, cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) { // Matches initialization on reassignements. For example: `vec = Vec::with_capacity(100)` if_chain! { - if let ExprKind::Assign(ref left, ref right, _) = expr.kind; + if let ExprKind::Assign(left, right, _) = expr.kind; // Extract variable name - if let ExprKind::Path(QPath::Resolved(_, ref path)) = left.kind; + if let ExprKind::Path(QPath::Resolved(_, path)) = left.kind; if let Some(variable_name) = path.segments.get(0); // Extract len argument - if let Some(ref len_arg) = Self::is_vec_with_capacity(right); + if let Some(len_arg) = Self::is_vec_with_capacity(right); then { let vi = VecAllocation { @@ -94,10 +94,10 @@ impl<'tcx> LateLintPass<'tcx> for SlowVectorInit { fn check_stmt(&mut self, cx: &LateContext<'tcx>, stmt: &'tcx Stmt<'_>) { // Matches statements which initializes vectors. For example: `let mut vec = Vec::with_capacity(10)` if_chain! { - if let StmtKind::Local(ref local) = stmt.kind; + if let StmtKind::Local(local) = stmt.kind; if let PatKind::Binding(BindingAnnotation::Mutable, .., variable_name, None) = local.pat.kind; - if let Some(ref init) = local.init; - if let Some(ref len_arg) = Self::is_vec_with_capacity(init); + if let Some(init) = local.init; + if let Some(len_arg) = Self::is_vec_with_capacity(init); then { let vi = VecAllocation { @@ -117,7 +117,7 @@ impl SlowVectorInit { /// of the first argument of `with_capacity` call if it matches or `None` if it does not. fn is_vec_with_capacity<'tcx>(expr: &Expr<'tcx>) -> Option<&'tcx Expr<'tcx>> { if_chain! { - if let ExprKind::Call(ref func, ref args) = expr.kind; + if let ExprKind::Call(func, args) = expr.kind; if let ExprKind::Path(ref path) = func.kind; if match_qpath(path, &["Vec", "with_capacity"]); if args.len() == 1; @@ -208,11 +208,11 @@ impl<'a, 'tcx> VectorInitializationVisitor<'a, 'tcx> { fn search_slow_extend_filling(&mut self, expr: &'tcx Expr<'_>) { if_chain! { if self.initialization_found; - if let ExprKind::MethodCall(ref path, _, ref args, _) = expr.kind; + if let ExprKind::MethodCall(path, _, args, _) = expr.kind; if let ExprKind::Path(ref qpath_subj) = args[0].kind; - if match_qpath(&qpath_subj, &[&*self.vec_alloc.variable_name.as_str()]); + if match_qpath(qpath_subj, &[&*self.vec_alloc.variable_name.as_str()]); if path.ident.name == sym!(extend); - if let Some(ref extend_arg) = args.get(1); + if let Some(extend_arg) = args.get(1); if self.is_repeat_take(extend_arg); then { @@ -225,11 +225,11 @@ impl<'a, 'tcx> VectorInitializationVisitor<'a, 'tcx> { fn search_slow_resize_filling(&mut self, expr: &'tcx Expr<'_>) { if_chain! { if self.initialization_found; - if let ExprKind::MethodCall(ref path, _, ref args, _) = expr.kind; + if let ExprKind::MethodCall(path, _, args, _) = expr.kind; if let ExprKind::Path(ref qpath_subj) = args[0].kind; - if match_qpath(&qpath_subj, &[&*self.vec_alloc.variable_name.as_str()]); + if match_qpath(qpath_subj, &[&*self.vec_alloc.variable_name.as_str()]); if path.ident.name == sym!(resize); - if let (Some(ref len_arg), Some(fill_arg)) = (args.get(1), args.get(2)); + if let (Some(len_arg), Some(fill_arg)) = (args.get(1), args.get(2)); // Check that is filled with 0 if let ExprKind::Lit(ref lit) = fill_arg.kind; @@ -247,15 +247,15 @@ impl<'a, 'tcx> VectorInitializationVisitor<'a, 'tcx> { /// Returns `true` if give expression is `repeat(0).take(...)` fn is_repeat_take(&self, expr: &Expr<'_>) -> bool { if_chain! { - if let ExprKind::MethodCall(ref take_path, _, ref take_args, _) = expr.kind; + if let ExprKind::MethodCall(take_path, _, take_args, _) = expr.kind; if take_path.ident.name == sym!(take); // Check that take is applied to `repeat(0)` - if let Some(ref repeat_expr) = take_args.get(0); + if let Some(repeat_expr) = take_args.get(0); if Self::is_repeat_zero(repeat_expr); // Check that len expression is equals to `with_capacity` expression - if let Some(ref len_arg) = take_args.get(1); + if let Some(len_arg) = take_args.get(1); if SpanlessEq::new(self.cx).eq_expr(len_arg, self.vec_alloc.len_expr); then { @@ -269,10 +269,10 @@ impl<'a, 'tcx> VectorInitializationVisitor<'a, 'tcx> { /// Returns `true` if given expression is `repeat(0)` fn is_repeat_zero(expr: &Expr<'_>) -> bool { if_chain! { - if let ExprKind::Call(ref fn_expr, ref repeat_args) = expr.kind; + if let ExprKind::Call(fn_expr, repeat_args) = expr.kind; if let ExprKind::Path(ref qpath_repeat) = fn_expr.kind; - if match_qpath(&qpath_repeat, &["repeat"]); - if let Some(ref repeat_arg) = repeat_args.get(0); + if match_qpath(qpath_repeat, &["repeat"]); + if let Some(repeat_arg) = repeat_args.get(0); if let ExprKind::Lit(ref lit) = repeat_arg.kind; if let LitKind::Int(0, _) = lit.node; @@ -291,7 +291,7 @@ impl<'a, 'tcx> Visitor<'tcx> for VectorInitializationVisitor<'a, 'tcx> { fn visit_stmt(&mut self, stmt: &'tcx Stmt<'_>) { if self.initialization_found { match stmt.kind { - StmtKind::Expr(ref expr) | StmtKind::Semi(ref expr) => { + StmtKind::Expr(expr) | StmtKind::Semi(expr) => { self.search_slow_extend_filling(expr); self.search_slow_resize_filling(expr); }, @@ -306,7 +306,7 @@ impl<'a, 'tcx> Visitor<'tcx> for VectorInitializationVisitor<'a, 'tcx> { fn visit_block(&mut self, block: &'tcx Block<'_>) { if self.initialization_found { - if let Some(ref s) = block.stmts.get(0) { + if let Some(s) = block.stmts.get(0) { self.visit_stmt(s) } diff --git a/clippy_lints/src/strings.rs b/clippy_lints/src/strings.rs index 99ca7ef77a5..9d91b53e1bb 100644 --- a/clippy_lints/src/strings.rs +++ b/clippy_lints/src/strings.rs @@ -119,7 +119,7 @@ impl<'tcx> LateLintPass<'tcx> for StringAdd { Spanned { node: BinOpKind::Add, .. }, - ref left, + left, _, ) = e.kind { @@ -127,7 +127,7 @@ impl<'tcx> LateLintPass<'tcx> for StringAdd { if !is_allowed(cx, STRING_ADD_ASSIGN, e.hir_id) { let parent = get_parent_expr(cx, e); if let Some(p) = parent { - if let ExprKind::Assign(ref target, _, _) = p.kind { + if let ExprKind::Assign(target, _, _) = p.kind { // avoid duplicate matches if SpanlessEq::new(cx).eq_expr(target, left) { return; @@ -142,7 +142,7 @@ impl<'tcx> LateLintPass<'tcx> for StringAdd { "you added something to a string. Consider using `String::push_str()` instead", ); } - } else if let ExprKind::Assign(ref target, ref src, _) = e.kind { + } else if let ExprKind::Assign(target, src, _) = e.kind { if is_string(cx, target) && is_add(cx, src, target) { span_lint( cx, @@ -166,10 +166,10 @@ fn is_add(cx: &LateContext<'_>, src: &Expr<'_>, target: &Expr<'_>) -> bool { Spanned { node: BinOpKind::Add, .. }, - ref left, + left, _, ) => SpanlessEq::new(cx).eq_expr(target, left), - ExprKind::Block(ref block, _) => { + ExprKind::Block(block, _) => { block.stmts.is_empty() && block.expr.as_ref().map_or(false, |expr| is_add(cx, expr, target)) }, _ => false, @@ -210,8 +210,8 @@ impl<'tcx> LateLintPass<'tcx> for StringLitAsBytes { if let Some(args) = match_function_call(cx, e, &paths::STR_FROM_UTF8); // Find string::as_bytes - if let ExprKind::AddrOf(BorrowKind::Ref, _, ref args) = args[0].kind; - if let ExprKind::Index(ref left, ref right) = args.kind; + if let ExprKind::AddrOf(BorrowKind::Ref, _, args) = args[0].kind; + if let ExprKind::Index(left, right) = args.kind; let (method_names, expressions, _) = method_calls(left, 1); if method_names.len() == 1; if expressions.len() == 1; diff --git a/clippy_lints/src/suspicious_operation_groupings.rs b/clippy_lints/src/suspicious_operation_groupings.rs index 46f423204a2..cb2237e5312 100644 --- a/clippy_lints/src/suspicious_operation_groupings.rs +++ b/clippy_lints/src/suspicious_operation_groupings.rs @@ -225,7 +225,7 @@ fn attempt_to_emit_no_difference_lint( emit_suggestion( cx, binop.span, - replace_left_sugg(cx, &binop, &sugg, &mut applicability), + replace_left_sugg(cx, binop, &sugg, &mut applicability), applicability, ); return; @@ -247,7 +247,7 @@ fn attempt_to_emit_no_difference_lint( emit_suggestion( cx, binop.span, - replace_right_sugg(cx, &binop, &sugg, &mut applicability), + replace_right_sugg(cx, binop, &sugg, &mut applicability), applicability, ); return; @@ -276,8 +276,8 @@ fn ident_swap_sugg( location: IdentLocation, applicability: &mut Applicability, ) -> Option { - let left_ident = get_ident(&binop.left, location)?; - let right_ident = get_ident(&binop.right, location)?; + let left_ident = get_ident(binop.left, location)?; + let right_ident = get_ident(binop.right, location)?; let sugg = match ( paired_identifiers.contains(&left_ident), @@ -293,8 +293,7 @@ fn ident_swap_sugg( // ends up duplicating a clause, the `logic_bug` lint // should catch it. - let right_suggestion = - suggestion_with_swapped_ident(cx, &binop.right, location, left_ident, applicability)?; + let right_suggestion = suggestion_with_swapped_ident(cx, binop.right, location, left_ident, applicability)?; replace_right_sugg(cx, binop, &right_suggestion, applicability) }, @@ -302,15 +301,14 @@ fn ident_swap_sugg( // We haven't seen a pair involving the left one, so // it's probably what is wanted. - let right_suggestion = - suggestion_with_swapped_ident(cx, &binop.right, location, left_ident, applicability)?; + let right_suggestion = suggestion_with_swapped_ident(cx, binop.right, location, left_ident, applicability)?; replace_right_sugg(cx, binop, &right_suggestion, applicability) }, (true, false) => { // We haven't seen a pair involving the right one, so // it's probably what is wanted. - let left_suggestion = suggestion_with_swapped_ident(cx, &binop.left, location, right_ident, applicability)?; + let left_suggestion = suggestion_with_swapped_ident(cx, binop.left, location, right_ident, applicability)?; replace_left_sugg(cx, binop, &left_suggestion, applicability) }, diff --git a/clippy_lints/src/swap.rs b/clippy_lints/src/swap.rs index 14519eaa962..19967e2c970 100644 --- a/clippy_lints/src/swap.rs +++ b/clippy_lints/src/swap.rs @@ -78,26 +78,26 @@ fn check_manual_swap(cx: &LateContext<'_>, block: &Block<'_>) { for w in block.stmts.windows(3) { if_chain! { // let t = foo(); - if let StmtKind::Local(ref tmp) = w[0].kind; - if let Some(ref tmp_init) = tmp.init; + if let StmtKind::Local(tmp) = w[0].kind; + if let Some(tmp_init) = tmp.init; if let PatKind::Binding(.., ident, None) = tmp.pat.kind; // foo() = bar(); - if let StmtKind::Semi(ref first) = w[1].kind; - if let ExprKind::Assign(ref lhs1, ref rhs1, _) = first.kind; + if let StmtKind::Semi(first) = w[1].kind; + if let ExprKind::Assign(lhs1, rhs1, _) = first.kind; // bar() = t; - if let StmtKind::Semi(ref second) = w[2].kind; - if let ExprKind::Assign(ref lhs2, ref rhs2, _) = second.kind; - if let ExprKind::Path(QPath::Resolved(None, ref rhs2)) = rhs2.kind; + if let StmtKind::Semi(second) = w[2].kind; + if let ExprKind::Assign(lhs2, rhs2, _) = second.kind; + if let ExprKind::Path(QPath::Resolved(None, rhs2)) = rhs2.kind; if rhs2.segments.len() == 1; if ident.name == rhs2.segments[0].ident.name; if eq_expr_value(cx, tmp_init, lhs1); if eq_expr_value(cx, rhs1, lhs2); then { - if let ExprKind::Field(ref lhs1, _) = lhs1.kind { - if let ExprKind::Field(ref lhs2, _) = lhs2.kind { + if let ExprKind::Field(lhs1, _) = lhs1.kind { + if let ExprKind::Field(lhs2, _) = lhs2.kind { if lhs1.hir_id.owner == lhs2.hir_id.owner { return; } @@ -192,8 +192,8 @@ enum Slice<'a> { /// Checks if both expressions are index operations into "slice-like" types. fn check_for_slice<'a>(cx: &LateContext<'_>, lhs1: &'a Expr<'_>, lhs2: &'a Expr<'_>) -> Slice<'a> { - if let ExprKind::Index(ref lhs1, ref idx1) = lhs1.kind { - if let ExprKind::Index(ref lhs2, ref idx2) = lhs2.kind { + if let ExprKind::Index(lhs1, idx1) = lhs1.kind { + if let ExprKind::Index(lhs2, idx2) = lhs2.kind { if eq_expr_value(cx, lhs1, lhs2) { let ty = cx.typeck_results().expr_ty(lhs1).peel_refs(); @@ -217,11 +217,11 @@ fn check_for_slice<'a>(cx: &LateContext<'_>, lhs1: &'a Expr<'_>, lhs2: &'a Expr< fn check_suspicious_swap(cx: &LateContext<'_>, block: &Block<'_>) { for w in block.stmts.windows(2) { if_chain! { - if let StmtKind::Semi(ref first) = w[0].kind; - if let StmtKind::Semi(ref second) = w[1].kind; + if let StmtKind::Semi(first) = w[0].kind; + if let StmtKind::Semi(second) = w[1].kind; if !differing_macro_contexts(first.span, second.span); - if let ExprKind::Assign(ref lhs0, ref rhs0, _) = first.kind; - if let ExprKind::Assign(ref lhs1, ref rhs1, _) = second.kind; + if let ExprKind::Assign(lhs0, rhs0, _) = first.kind; + if let ExprKind::Assign(lhs1, rhs1, _) = second.kind; if eq_expr_value(cx, lhs0, rhs1); if eq_expr_value(cx, lhs1, rhs0); then { diff --git a/clippy_lints/src/tabs_in_doc_comments.rs b/clippy_lints/src/tabs_in_doc_comments.rs index 88bd2feaadd..a0492a88f91 100644 --- a/clippy_lints/src/tabs_in_doc_comments.rs +++ b/clippy_lints/src/tabs_in_doc_comments.rs @@ -86,7 +86,7 @@ impl TabsInDocComments { impl EarlyLintPass for TabsInDocComments { fn check_attribute(&mut self, cx: &EarlyContext<'_>, attribute: &ast::Attribute) { - Self::warn_if_tabs_in_doc(cx, &attribute); + Self::warn_if_tabs_in_doc(cx, attribute); } } diff --git a/clippy_lints/src/to_string_in_display.rs b/clippy_lints/src/to_string_in_display.rs index 42ec14c31b5..ae05a8da37b 100644 --- a/clippy_lints/src/to_string_in_display.rs +++ b/clippy_lints/src/to_string_in_display.rs @@ -92,7 +92,7 @@ impl LateLintPass<'_> for ToStringInDisplay { if_chain! { if self.in_display_impl; if let Some(self_hir_id) = self.self_hir_id; - if let ExprKind::MethodCall(ref path, _, args, _) = expr.kind; + if let ExprKind::MethodCall(path, _, args, _) = expr.kind; if path.ident.name == sym!(to_string); if let Some(expr_def_id) = cx.typeck_results().type_dependent_def_id(expr.hir_id); if is_diagnostic_assoc_item(cx, expr_def_id, sym::ToString); diff --git a/clippy_lints/src/trait_bounds.rs b/clippy_lints/src/trait_bounds.rs index 3ff27c3bcf4..b0589b0512e 100644 --- a/clippy_lints/src/trait_bounds.rs +++ b/clippy_lints/src/trait_bounds.rs @@ -107,7 +107,7 @@ impl TraitBounds { if let WherePredicate::BoundPredicate(ref p) = bound; if p.bounds.len() as u64 <= self.max_trait_bounds; if !in_macro(p.span); - let h = hash(&p.bounded_ty); + let h = hash(p.bounded_ty); if let Some(ref v) = map.insert(h, p.bounds.iter().collect::>()); then { @@ -170,7 +170,7 @@ fn check_trait_bound_duplication(cx: &LateContext<'_>, gen: &'_ Generics<'_>) { if_chain! { if let WherePredicate::BoundPredicate(ref bound_predicate) = predicate; if !in_macro(bound_predicate.span); - if let TyKind::Path(QPath::Resolved(_, Path { ref segments, .. })) = bound_predicate.bounded_ty.kind; + if let TyKind::Path(QPath::Resolved(_, Path { segments, .. })) = bound_predicate.bounded_ty.kind; if let Some(segment) = segments.first(); if let Some(trait_resolutions_direct) = map.get(&segment.ident); then { diff --git a/clippy_lints/src/transmute/mod.rs b/clippy_lints/src/transmute/mod.rs index 47d58bd30db..86ac916df6c 100644 --- a/clippy_lints/src/transmute/mod.rs +++ b/clippy_lints/src/transmute/mod.rs @@ -325,7 +325,7 @@ impl<'tcx> LateLintPass<'tcx> for Transmute { #[allow(clippy::similar_names, clippy::too_many_lines)] fn check_expr(&mut self, cx: &LateContext<'tcx>, e: &'tcx Expr<'_>) { if_chain! { - if let ExprKind::Call(ref path_expr, ref args) = e.kind; + if let ExprKind::Call(path_expr, args) = e.kind; if let ExprKind::Path(ref qpath) = path_expr.kind; if let Some(def_id) = cx.qpath_res(qpath, path_expr.hir_id).opt_def_id(); if match_def_path(cx, def_id, &paths::TRANSMUTE); diff --git a/clippy_lints/src/transmute/transmute_float_to_int.rs b/clippy_lints/src/transmute/transmute_float_to_int.rs index 1a6124e9ddb..3aa3c393ba5 100644 --- a/clippy_lints/src/transmute/transmute_float_to_int.rs +++ b/clippy_lints/src/transmute/transmute_float_to_int.rs @@ -30,7 +30,7 @@ pub(super) fn check<'tcx>( let mut arg = sugg::Sugg::hir(cx, expr, ".."); if let ExprKind::Unary(UnOp::Neg, inner_expr) = &expr.kind { - expr = &inner_expr; + expr = inner_expr; } if_chain! { diff --git a/clippy_lints/src/transmute/utils.rs b/clippy_lints/src/transmute/utils.rs index c6d0d63b0b5..f359b606e45 100644 --- a/clippy_lints/src/transmute/utils.rs +++ b/clippy_lints/src/transmute/utils.rs @@ -16,7 +16,7 @@ use rustc_typeck::check::{cast::CastCheck, FnCtxt, Inherited}; pub(super) fn get_type_snippet(cx: &LateContext<'_>, path: &QPath<'_>, to_ref_ty: Ty<'_>) -> String { let seg = last_path_segment(path); if_chain! { - if let Some(ref params) = seg.args; + if let Some(params) = seg.args; if !params.parenthesized; if let Some(to_ty) = params.args.iter().filter_map(|arg| match arg { GenericArg::Type(ty) => Some(ty), diff --git a/clippy_lints/src/transmuting_null.rs b/clippy_lints/src/transmuting_null.rs index d42cdde110e..0be05d3e0cf 100644 --- a/clippy_lints/src/transmuting_null.rs +++ b/clippy_lints/src/transmuting_null.rs @@ -37,7 +37,7 @@ impl<'tcx> LateLintPass<'tcx> for TransmutingNull { } if_chain! { - if let ExprKind::Call(ref func, ref args) = expr.kind; + if let ExprKind::Call(func, args) = expr.kind; if let ExprKind::Path(ref path) = func.kind; if match_qpath(path, &paths::STD_MEM_TRANSMUTE); if args.len() == 1; @@ -58,7 +58,7 @@ impl<'tcx> LateLintPass<'tcx> for TransmutingNull { // Catching: // `std::mem::transmute(0 as *const i32)` if_chain! { - if let ExprKind::Cast(ref inner_expr, ref _cast_ty) = args[0].kind; + if let ExprKind::Cast(inner_expr, _cast_ty) = args[0].kind; if let ExprKind::Lit(ref lit) = inner_expr.kind; if let LitKind::Int(0, _) = lit.node; then { @@ -69,7 +69,7 @@ impl<'tcx> LateLintPass<'tcx> for TransmutingNull { // Catching: // `std::mem::transmute(std::ptr::null::())` if_chain! { - if let ExprKind::Call(ref func1, ref args1) = args[0].kind; + if let ExprKind::Call(func1, args1) = args[0].kind; if let ExprKind::Path(ref path1) = func1.kind; if match_qpath(path1, &paths::STD_PTR_NULL); if args1.is_empty(); diff --git a/clippy_lints/src/try_err.rs b/clippy_lints/src/try_err.rs index e4799790d35..23a1953ffac 100644 --- a/clippy_lints/src/try_err.rs +++ b/clippy_lints/src/try_err.rs @@ -60,13 +60,13 @@ impl<'tcx> LateLintPass<'tcx> for TryErr { // }; if_chain! { if !in_external_macro(cx.tcx.sess, expr.span); - if let ExprKind::Match(ref match_arg, _, MatchSource::TryDesugar) = expr.kind; - if let ExprKind::Call(ref match_fun, ref try_args) = match_arg.kind; + if let ExprKind::Match(match_arg, _, MatchSource::TryDesugar) = expr.kind; + if let ExprKind::Call(match_fun, try_args) = match_arg.kind; if let ExprKind::Path(ref match_fun_path) = match_fun.kind; if matches!(match_fun_path, QPath::LangItem(LangItem::TryIntoResult, _)); - if let Some(ref try_arg) = try_args.get(0); - if let ExprKind::Call(ref err_fun, ref err_args) = try_arg.kind; - if let Some(ref err_arg) = err_args.get(0); + if let Some(try_arg) = try_args.get(0); + if let ExprKind::Call(err_fun, err_args) = try_arg.kind; + if let Some(err_arg) = err_args.get(0); if let ExprKind::Path(ref err_fun_path) = err_fun.kind; if match_qpath(err_fun_path, &paths::RESULT_ERR); if let Some(return_ty) = find_return_type(cx, &expr.kind); @@ -123,9 +123,9 @@ impl<'tcx> LateLintPass<'tcx> for TryErr { /// Finds function return type by examining return expressions in match arms. fn find_return_type<'tcx>(cx: &LateContext<'tcx>, expr: &'tcx ExprKind<'_>) -> Option> { - if let ExprKind::Match(_, ref arms, MatchSource::TryDesugar) = expr { + if let ExprKind::Match(_, arms, MatchSource::TryDesugar) = expr { for arm in arms.iter() { - if let ExprKind::Ret(Some(ref ret)) = arm.body.kind { + if let ExprKind::Ret(Some(ret)) = arm.body.kind { return Some(cx.typeck_results().expr_ty(ret)); } } diff --git a/clippy_lints/src/types/borrowed_box.rs b/clippy_lints/src/types/borrowed_box.rs index d68c6db4e23..1425d8f3f37 100644 --- a/clippy_lints/src/types/borrowed_box.rs +++ b/clippy_lints/src/types/borrowed_box.rs @@ -19,9 +19,9 @@ pub(super) fn check(cx: &LateContext<'_>, hir_ty: &hir::Ty<'_>, lt: &Lifetime, m if_chain! { if let Some(def_id) = def.opt_def_id(); if Some(def_id) == cx.tcx.lang_items().owned_box(); - if let QPath::Resolved(None, ref path) = *qpath; + if let QPath::Resolved(None, path) = *qpath; if let [ref bx] = *path.segments; - if let Some(ref params) = bx.args; + if let Some(params) = bx.args; if !params.parenthesized; if let Some(inner) = params.args.iter().find_map(|arg| match arg { GenericArg::Type(ty) => Some(ty), @@ -86,11 +86,11 @@ pub(super) fn check(cx: &LateContext<'_>, hir_ty: &hir::Ty<'_>, lt: &Lifetime, m // Returns true if given type is `Any` trait. fn is_any_trait(t: &hir::Ty<'_>) -> bool { if_chain! { - if let TyKind::TraitObject(ref traits, ..) = t.kind; + if let TyKind::TraitObject(traits, ..) = t.kind; if !traits.is_empty(); // Only Send/Sync can be used as additional traits, so it is enough to // check only the first trait. - if match_path(&traits[0].trait_ref.path, &paths::ANY_TRAIT); + if match_path(traits[0].trait_ref.path, &paths::ANY_TRAIT); then { return true; } diff --git a/clippy_lints/src/types/mod.rs b/clippy_lints/src/types/mod.rs index 12e1eba2ca6..d9b47a699dc 100644 --- a/clippy_lints/src/types/mod.rs +++ b/clippy_lints/src/types/mod.rs @@ -278,9 +278,7 @@ impl<'tcx> LateLintPass<'tcx> for Types { fn check_item(&mut self, cx: &LateContext<'tcx>, item: &'tcx Item<'_>) { match item.kind { - ItemKind::Static(ref ty, _, _) | ItemKind::Const(ref ty, _) => { - self.check_ty(cx, ty, CheckTyContext::default()) - }, + ItemKind::Static(ty, _, _) | ItemKind::Const(ty, _) => self.check_ty(cx, ty, CheckTyContext::default()), // functions, enums, structs, impls and traits are covered _ => (), } @@ -288,7 +286,7 @@ impl<'tcx> LateLintPass<'tcx> for Types { fn check_impl_item(&mut self, cx: &LateContext<'tcx>, item: &'tcx ImplItem<'_>) { match item.kind { - ImplItemKind::Const(ref ty, _) | ImplItemKind::TyAlias(ref ty) => self.check_ty( + ImplItemKind::Const(ty, _) | ImplItemKind::TyAlias(ty) => self.check_ty( cx, ty, CheckTyContext { @@ -302,21 +300,21 @@ impl<'tcx> LateLintPass<'tcx> for Types { } fn check_field_def(&mut self, cx: &LateContext<'_>, field: &hir::FieldDef<'_>) { - self.check_ty(cx, &field.ty, CheckTyContext::default()); + self.check_ty(cx, field.ty, CheckTyContext::default()); } fn check_trait_item(&mut self, cx: &LateContext<'_>, item: &TraitItem<'_>) { match item.kind { - TraitItemKind::Const(ref ty, _) | TraitItemKind::Type(_, Some(ref ty)) => { + TraitItemKind::Const(ty, _) | TraitItemKind::Type(_, Some(ty)) => { self.check_ty(cx, ty, CheckTyContext::default()) }, - TraitItemKind::Fn(ref sig, _) => self.check_fn_decl(cx, &sig.decl, CheckTyContext::default()), + TraitItemKind::Fn(ref sig, _) => self.check_fn_decl(cx, sig.decl, CheckTyContext::default()), TraitItemKind::Type(..) => (), } } fn check_local(&mut self, cx: &LateContext<'_>, local: &Local<'_>) { - if let Some(ref ty) = local.ty { + if let Some(ty) = local.ty { self.check_ty( cx, ty, @@ -342,7 +340,7 @@ impl Types { self.check_ty(cx, input, context); } - if let FnRetTy::Return(ref ty) = decl.output { + if let FnRetTy::Return(ty) = decl.output { self.check_ty(cx, ty, context); } } @@ -383,7 +381,7 @@ impl Types { } } match *qpath { - QPath::Resolved(Some(ref ty), ref p) => { + QPath::Resolved(Some(ty), p) => { context.is_nested_call = true; self.check_ty(cx, ty, context); for ty in p.segments.iter().flat_map(|seg| { @@ -398,7 +396,7 @@ impl Types { self.check_ty(cx, ty, context); } }, - QPath::Resolved(None, ref p) => { + QPath::Resolved(None, p) => { context.is_nested_call = true; for ty in p.segments.iter().flat_map(|seg| { seg.args @@ -412,10 +410,10 @@ impl Types { self.check_ty(cx, ty, context); } }, - QPath::TypeRelative(ref ty, ref seg) => { + QPath::TypeRelative(ty, seg) => { context.is_nested_call = true; self.check_ty(cx, ty, context); - if let Some(ref params) = seg.args { + if let Some(params) = seg.args { for ty in params.args.iter().filter_map(|arg| match arg { GenericArg::Type(ty) => Some(ty), _ => None, @@ -430,10 +428,10 @@ impl Types { TyKind::Rptr(ref lt, ref mut_ty) => { context.is_nested_call = true; if !borrowed_box::check(cx, hir_ty, lt, mut_ty) { - self.check_ty(cx, &mut_ty.ty, context); + self.check_ty(cx, mut_ty.ty, context); } }, - TyKind::Slice(ref ty) | TyKind::Array(ref ty, _) | TyKind::Ptr(MutTy { ref ty, .. }) => { + TyKind::Slice(ty) | TyKind::Array(ty, _) | TyKind::Ptr(MutTy { ty, .. }) => { context.is_nested_call = true; self.check_ty(cx, ty, context) }, diff --git a/clippy_lints/src/types/type_complexity.rs b/clippy_lints/src/types/type_complexity.rs index 9a4e9da3e2b..d8c4b67520d 100644 --- a/clippy_lints/src/types/type_complexity.rs +++ b/clippy_lints/src/types/type_complexity.rs @@ -48,9 +48,9 @@ impl<'tcx> Visitor<'tcx> for TypeComplexityVisitor { TyKind::Path(..) | TyKind::Slice(..) | TyKind::Tup(..) | TyKind::Array(..) => (10 * self.nest, 1), // function types bring a lot of overhead - TyKind::BareFn(ref bare) if bare.abi == Abi::Rust => (50 * self.nest, 1), + TyKind::BareFn(bare) if bare.abi == Abi::Rust => (50 * self.nest, 1), - TyKind::TraitObject(ref param_bounds, _, _) => { + TyKind::TraitObject(param_bounds, _, _) => { let has_lifetime_parameters = param_bounds.iter().any(|bound| { bound .bound_generic_params diff --git a/clippy_lints/src/types/utils.rs b/clippy_lints/src/types/utils.rs index 45f891ed718..0fa75f8f0a9 100644 --- a/clippy_lints/src/types/utils.rs +++ b/clippy_lints/src/types/utils.rs @@ -7,7 +7,7 @@ use rustc_span::source_map::Span; pub(super) fn match_borrows_parameter(_cx: &LateContext<'_>, qpath: &QPath<'_>) -> Option { let last = last_path_segment(qpath); if_chain! { - if let Some(ref params) = last.args; + if let Some(params) = last.args; if !params.parenthesized; if let Some(ty) = params.args.iter().find_map(|arg| match arg { GenericArg::Type(ty) => Some(ty), diff --git a/clippy_lints/src/types/vec_box.rs b/clippy_lints/src/types/vec_box.rs index d2c373db261..7a444174626 100644 --- a/clippy_lints/src/types/vec_box.rs +++ b/clippy_lints/src/types/vec_box.rs @@ -22,7 +22,7 @@ pub(super) fn check( if cx.tcx.is_diagnostic_item(sym::vec_type, def_id) { if_chain! { // Get the _ part of Vec<_> - if let Some(ref last) = last_path_segment(qpath).args; + if let Some(last) = last_path_segment(qpath).args; if let Some(ty) = last.args.iter().find_map(|arg| match arg { GenericArg::Type(ty) => Some(ty), _ => None, @@ -33,7 +33,7 @@ pub(super) fn check( if let Some(def_id) = res.opt_def_id(); if Some(def_id) == cx.tcx.lang_items().owned_box(); // At this point, we know ty is Box, now get T - if let Some(ref last) = last_path_segment(ty_qpath).args; + if let Some(last) = last_path_segment(ty_qpath).args; if let Some(boxed_ty) = last.args.iter().find_map(|arg| match arg { GenericArg::Type(ty) => Some(ty), _ => None, diff --git a/clippy_lints/src/undropped_manually_drops.rs b/clippy_lints/src/undropped_manually_drops.rs index b6749069176..f4f5e1233e3 100644 --- a/clippy_lints/src/undropped_manually_drops.rs +++ b/clippy_lints/src/undropped_manually_drops.rs @@ -35,7 +35,7 @@ declare_lint_pass!(UndroppedManuallyDrops => [UNDROPPED_MANUALLY_DROPS]); impl LateLintPass<'tcx> for UndroppedManuallyDrops { fn check_expr(&mut self, cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) { - if let Some(ref args) = match_function_call(cx, expr, &paths::DROP) { + if let Some(args) = match_function_call(cx, expr, &paths::DROP) { let ty = cx.typeck_results().expr_ty(&args[0]); if is_type_lang_item(cx, ty, lang_items::LangItem::ManuallyDrop) { span_lint_and_help( diff --git a/clippy_lints/src/unit_return_expecting_ord.rs b/clippy_lints/src/unit_return_expecting_ord.rs index cdc65abe47c..47b95b18ffb 100644 --- a/clippy_lints/src/unit_return_expecting_ord.rs +++ b/clippy_lints/src/unit_return_expecting_ord.rs @@ -138,7 +138,7 @@ fn check_arg<'tcx>(cx: &LateContext<'tcx>, arg: &'tcx Expr<'tcx>) -> Option<(Spa impl<'tcx> LateLintPass<'tcx> for UnitReturnExpectingOrd { fn check_expr(&mut self, cx: &LateContext<'tcx>, expr: &'tcx Expr<'tcx>) { - if let ExprKind::MethodCall(_, _, ref args, _) = expr.kind { + if let ExprKind::MethodCall(_, _, args, _) = expr.kind { let arg_indices = get_args_to_check(cx, expr); for (i, trait_name) in arg_indices { if i < args.len() { diff --git a/clippy_lints/src/unit_types/let_unit_value.rs b/clippy_lints/src/unit_types/let_unit_value.rs index 8698a718bbd..fad647dfb26 100644 --- a/clippy_lints/src/unit_types/let_unit_value.rs +++ b/clippy_lints/src/unit_types/let_unit_value.rs @@ -9,8 +9,8 @@ use rustc_middle::lint::in_external_macro; use super::LET_UNIT_VALUE; pub(super) fn check(cx: &LateContext<'_>, stmt: &Stmt<'_>) { - if let StmtKind::Local(ref local) = stmt.kind { - if cx.typeck_results().pat_ty(&local.pat).is_unit() { + if let StmtKind::Local(local) = stmt.kind { + if cx.typeck_results().pat_ty(local.pat).is_unit() { if in_external_macro(cx.sess(), stmt.span) || local.pat.span.from_expansion() { return; } diff --git a/clippy_lints/src/unit_types/unit_arg.rs b/clippy_lints/src/unit_types/unit_arg.rs index f77d811c283..57be2d2f674 100644 --- a/clippy_lints/src/unit_types/unit_arg.rs +++ b/clippy_lints/src/unit_types/unit_arg.rs @@ -54,7 +54,7 @@ pub(super) fn check(cx: &LateContext<'_>, expr: &Expr<'_>) { fn is_questionmark_desugar_marked_call(expr: &Expr<'_>) -> bool { use rustc_span::hygiene::DesugaringKind; - if let ExprKind::Call(ref callee, _) = expr.kind { + if let ExprKind::Call(callee, _) = expr.kind { callee.span.is_desugaring(DesugaringKind::QuestionMark) } else { false diff --git a/clippy_lints/src/unit_types/unit_cmp.rs b/clippy_lints/src/unit_types/unit_cmp.rs index b3077dec5d8..85257f3113c 100644 --- a/clippy_lints/src/unit_types/unit_cmp.rs +++ b/clippy_lints/src/unit_types/unit_cmp.rs @@ -9,7 +9,7 @@ pub(super) fn check(cx: &LateContext<'_>, expr: &Expr<'_>) { if expr.span.from_expansion() { if let Some(callee) = expr.span.source_callee() { if let ExpnKind::Macro(MacroKind::Bang, symbol) = callee.kind { - if let ExprKind::Binary(ref cmp, ref left, _) = expr.kind { + if let ExprKind::Binary(ref cmp, left, _) = expr.kind { let op = cmp.node; if op.is_comparison() && cx.typeck_results().expr_ty(left).is_unit() { let result = match &*symbol.as_str() { @@ -34,7 +34,7 @@ pub(super) fn check(cx: &LateContext<'_>, expr: &Expr<'_>) { return; } - if let ExprKind::Binary(ref cmp, ref left, _) = expr.kind { + if let ExprKind::Binary(ref cmp, left, _) = expr.kind { let op = cmp.node; if op.is_comparison() && cx.typeck_results().expr_ty(left).is_unit() { let result = match op { diff --git a/clippy_lints/src/unit_types/utils.rs b/clippy_lints/src/unit_types/utils.rs index 4e194a05e8d..9a3750b2356 100644 --- a/clippy_lints/src/unit_types/utils.rs +++ b/clippy_lints/src/unit_types/utils.rs @@ -1,5 +1,5 @@ use rustc_hir::{Expr, ExprKind}; pub(super) fn is_unit_literal(expr: &Expr<'_>) -> bool { - matches!(expr.kind, ExprKind::Tup(ref slice) if slice.is_empty()) + matches!(expr.kind, ExprKind::Tup(slice) if slice.is_empty()) } diff --git a/clippy_lints/src/unnamed_address.rs b/clippy_lints/src/unnamed_address.rs index 9ceb2c3ffe2..9cca05b1f1a 100644 --- a/clippy_lints/src/unnamed_address.rs +++ b/clippy_lints/src/unnamed_address.rs @@ -77,7 +77,7 @@ impl LateLintPass<'_> for UnnamedAddress { } if_chain! { - if let ExprKind::Binary(binop, ref left, ref right) = expr.kind; + if let ExprKind::Binary(binop, left, right) = expr.kind; if is_comparison(binop.node); if is_trait_ptr(cx, left) && is_trait_ptr(cx, right); then { @@ -93,7 +93,7 @@ impl LateLintPass<'_> for UnnamedAddress { } if_chain! { - if let ExprKind::Call(ref func, [ref _left, ref _right]) = expr.kind; + if let ExprKind::Call(func, [ref _left, ref _right]) = expr.kind; if let ExprKind::Path(ref func_qpath) = func.kind; if let Some(def_id) = cx.qpath_res(func_qpath, func.hir_id).opt_def_id(); if match_def_path(cx, def_id, &paths::PTR_EQ) || @@ -114,7 +114,7 @@ impl LateLintPass<'_> for UnnamedAddress { } if_chain! { - if let ExprKind::Binary(binop, ref left, ref right) = expr.kind; + if let ExprKind::Binary(binop, left, right) = expr.kind; if is_comparison(binop.node); if cx.typeck_results().expr_ty_adjusted(left).is_fn_ptr(); if cx.typeck_results().expr_ty_adjusted(right).is_fn_ptr(); diff --git a/clippy_lints/src/unnecessary_sort_by.rs b/clippy_lints/src/unnecessary_sort_by.rs index e23bab5eba0..03711eb5b65 100644 --- a/clippy_lints/src/unnecessary_sort_by.rs +++ b/clippy_lints/src/unnecessary_sort_by.rs @@ -187,15 +187,15 @@ fn detect_lint(cx: &LateContext<'_>, expr: &Expr<'_>) -> Option { if method_path.ident.name == sym::cmp; then { let (closure_body, closure_arg, reverse) = if mirrored_exprs( - &cx, - &left_expr, - &left_ident, - &right_expr, - &right_ident + cx, + left_expr, + left_ident, + right_expr, + right_ident ) { - (Sugg::hir(cx, &left_expr, "..").to_string(), left_ident.name.to_string(), false) - } else if mirrored_exprs(&cx, &left_expr, &right_ident, &right_expr, &left_ident) { - (Sugg::hir(cx, &left_expr, "..").to_string(), right_ident.name.to_string(), true) + (Sugg::hir(cx, left_expr, "..").to_string(), left_ident.name.to_string(), false) + } else if mirrored_exprs(cx, left_expr, right_ident, right_expr, left_ident) { + (Sugg::hir(cx, left_expr, "..").to_string(), right_ident.name.to_string(), true) } else { return None; }; diff --git a/clippy_lints/src/unnecessary_wraps.rs b/clippy_lints/src/unnecessary_wraps.rs index c2be457e9dc..5bb417cb1be 100644 --- a/clippy_lints/src/unnecessary_wraps.rs +++ b/clippy_lints/src/unnecessary_wraps.rs @@ -103,7 +103,7 @@ impl<'tcx> LateLintPass<'tcx> for UnnecessaryWraps { if_chain! { if !in_macro(ret_expr.span); // Check if a function call. - if let ExprKind::Call(ref func, ref args) = ret_expr.kind; + if let ExprKind::Call(func, args) = ret_expr.kind; // Get the Path of the function call. if let ExprKind::Path(ref qpath) = func.kind; // Check if OPTION_SOME or RESULT_OK, depending on return type. diff --git a/clippy_lints/src/unused_io_amount.rs b/clippy_lints/src/unused_io_amount.rs index 9990052e114..024ab03fd41 100644 --- a/clippy_lints/src/unused_io_amount.rs +++ b/clippy_lints/src/unused_io_amount.rs @@ -36,13 +36,13 @@ declare_lint_pass!(UnusedIoAmount => [UNUSED_IO_AMOUNT]); impl<'tcx> LateLintPass<'tcx> for UnusedIoAmount { fn check_stmt(&mut self, cx: &LateContext<'_>, s: &hir::Stmt<'_>) { let expr = match s.kind { - hir::StmtKind::Semi(ref expr) | hir::StmtKind::Expr(ref expr) => &**expr, + hir::StmtKind::Semi(expr) | hir::StmtKind::Expr(expr) => expr, _ => return, }; match expr.kind { - hir::ExprKind::Match(ref res, _, _) if is_try(expr).is_some() => { - if let hir::ExprKind::Call(ref func, ref args) = res.kind { + hir::ExprKind::Match(res, _, _) if is_try(expr).is_some() => { + if let hir::ExprKind::Call(func, args) = res.kind { if matches!( func.kind, hir::ExprKind::Path(hir::QPath::LangItem(hir::LangItem::TryIntoResult, _)) @@ -54,7 +54,7 @@ impl<'tcx> LateLintPass<'tcx> for UnusedIoAmount { } }, - hir::ExprKind::MethodCall(ref path, _, ref args, _) => match &*path.ident.as_str() { + hir::ExprKind::MethodCall(path, _, args, _) => match &*path.ident.as_str() { "expect" | "unwrap" | "unwrap_or" | "unwrap_or_else" => { check_method_call(cx, &args[0], expr); }, @@ -67,7 +67,7 @@ impl<'tcx> LateLintPass<'tcx> for UnusedIoAmount { } fn check_method_call(cx: &LateContext<'_>, call: &hir::Expr<'_>, expr: &hir::Expr<'_>) { - if let hir::ExprKind::MethodCall(ref path, _, _, _) = call.kind { + if let hir::ExprKind::MethodCall(path, _, _, _) = call.kind { let symbol = &*path.ident.as_str(); let read_trait = match_trait_method(cx, call, &paths::IO_READ); let write_trait = match_trait_method(cx, call, &paths::IO_WRITE); diff --git a/clippy_lints/src/unused_unit.rs b/clippy_lints/src/unused_unit.rs index 329ea49024b..ce2d0b3ab2f 100644 --- a/clippy_lints/src/unused_unit.rs +++ b/clippy_lints/src/unused_unit.rs @@ -45,7 +45,7 @@ impl EarlyLintPass for UnusedUnit { fn check_block(&mut self, cx: &EarlyContext<'_>, block: &ast::Block) { if_chain! { - if let Some(ref stmt) = block.stmts.last(); + if let Some(stmt) = block.stmts.last(); if let ast::StmtKind::Expr(ref expr) = stmt.kind; if is_unit_expr(expr) && !stmt.span.from_expansion(); then { diff --git a/clippy_lints/src/unwrap.rs b/clippy_lints/src/unwrap.rs index fb29acca18a..d4efee56eff 100644 --- a/clippy_lints/src/unwrap.rs +++ b/clippy_lints/src/unwrap.rs @@ -166,8 +166,8 @@ impl<'a, 'tcx> Visitor<'tcx> for UnwrappableVariablesVisitor<'a, 'tcx> { } else { // find `unwrap[_err]()` calls: if_chain! { - if let ExprKind::MethodCall(ref method_name, _, ref args, _) = expr.kind; - if let ExprKind::Path(QPath::Resolved(None, ref path)) = args[0].kind; + if let ExprKind::MethodCall(method_name, _, args, _) = expr.kind; + if let ExprKind::Path(QPath::Resolved(None, path)) = args[0].kind; if [sym::unwrap, sym!(unwrap_err)].contains(&method_name.ident.name); let call_to_unwrap = method_name.ident.name == sym::unwrap; if let Some(unwrappable) = self.unwrappables.iter() diff --git a/clippy_lints/src/use_self.rs b/clippy_lints/src/use_self.rs index 116cb8b1e1c..c6a3c58a9a2 100644 --- a/clippy_lints/src/use_self.rs +++ b/clippy_lints/src/use_self.rs @@ -104,7 +104,7 @@ impl<'tcx> LateLintPass<'tcx> for UseSelf { of_trait, .. }) => { - let should_check = if let TyKind::Path(QPath::Resolved(_, ref item_path)) = hir_self_ty.kind { + let should_check = if let TyKind::Path(QPath::Resolved(_, item_path)) = hir_self_ty.kind { let parameters = &item_path.segments.last().expect(SEGMENTS_MSG).args; parameters.as_ref().map_or(true, |params| { !params.parenthesized && !params.args.iter().any(|arg| matches!(arg, GenericArg::Lifetime(_))) @@ -197,7 +197,7 @@ impl<'tcx> LateLintPass<'tcx> for UseSelf { for (impl_hir_ty, trait_sem_ty) in impl_inputs_outputs.zip(trait_method_sig.inputs_and_output) { if trait_sem_ty.walk().any(|inner| inner == self_ty.into()) { let mut visitor = SkipTyCollector::default(); - visitor.visit_ty(&impl_hir_ty); + visitor.visit_ty(impl_hir_ty); types_to_skip.extend(visitor.types_to_skip); } } @@ -333,7 +333,7 @@ impl<'tcx> LateLintPass<'tcx> for UseSelf { // unit enum variants (`Enum::A`) ExprKind::Path(qpath) => { if expr_ty_matches(cx, expr, self_ty) { - span_lint_on_qpath_resolved(cx, &qpath, true); + span_lint_on_qpath_resolved(cx, qpath, true); } }, _ => (), diff --git a/clippy_lints/src/useless_conversion.rs b/clippy_lints/src/useless_conversion.rs index d893b271a20..7edb280be73 100644 --- a/clippy_lints/src/useless_conversion.rs +++ b/clippy_lints/src/useless_conversion.rs @@ -53,17 +53,17 @@ impl<'tcx> LateLintPass<'tcx> for UselessConversion { } match e.kind { - ExprKind::Match(_, ref arms, MatchSource::TryDesugar) => { + ExprKind::Match(_, arms, MatchSource::TryDesugar) => { let e = match arms[0].body.kind { - ExprKind::Ret(Some(ref e)) | ExprKind::Break(_, Some(ref e)) => e, + ExprKind::Ret(Some(e)) | ExprKind::Break(_, Some(e)) => e, _ => return, }; - if let ExprKind::Call(_, ref args) = e.kind { + if let ExprKind::Call(_, args) = e.kind { self.try_desugar_arm.push(args[0].hir_id); } }, - ExprKind::MethodCall(ref name, .., ref args, _) => { + ExprKind::MethodCall(name, .., args, _) => { if match_trait_method(cx, e, &paths::INTO) && &*name.ident.as_str() == "into" { let a = cx.typeck_results().expr_ty(e); let b = cx.typeck_results().expr_ty(&args[0]); @@ -82,7 +82,7 @@ impl<'tcx> LateLintPass<'tcx> for UselessConversion { } if match_trait_method(cx, e, &paths::INTO_ITERATOR) && name.ident.name == sym::into_iter { if let Some(parent_expr) = get_parent_expr(cx, e) { - if let ExprKind::MethodCall(ref parent_name, ..) = parent_expr.kind { + if let ExprKind::MethodCall(parent_name, ..) = parent_expr.kind { if parent_name.ident.name != sym::into_iter { return; } @@ -124,7 +124,7 @@ impl<'tcx> LateLintPass<'tcx> for UselessConversion { } }, - ExprKind::Call(ref path, ref args) => { + ExprKind::Call(path, args) => { if_chain! { if args.len() == 1; if let ExprKind::Path(ref qpath) = path.kind; diff --git a/clippy_lints/src/utils/author.rs b/clippy_lints/src/utils/author.rs index a92c987014f..e70f8a09ebe 100644 --- a/clippy_lints/src/utils/author.rs +++ b/clippy_lints/src/utils/author.rs @@ -203,13 +203,13 @@ impl<'tcx> Visitor<'tcx> for PrintVisitor { print!(" if let ExprKind::"); let current = format!("{}.kind", self.current); match expr.kind { - ExprKind::Box(ref inner) => { + ExprKind::Box(inner) => { let inner_pat = self.next("inner"); println!("Box(ref {}) = {};", inner_pat, current); self.current = inner_pat; self.visit_expr(inner); }, - ExprKind::Array(ref elements) => { + ExprKind::Array(elements) => { let elements_pat = self.next("elements"); println!("Array(ref {}) = {};", elements_pat, current); println!(" if {}.len() == {};", elements_pat, elements.len()); @@ -218,7 +218,7 @@ impl<'tcx> Visitor<'tcx> for PrintVisitor { self.visit_expr(element); } }, - ExprKind::Call(ref func, ref args) => { + ExprKind::Call(func, args) => { let func_pat = self.next("func"); let args_pat = self.next("args"); println!("Call(ref {}, ref {}) = {};", func_pat, args_pat, current); @@ -230,14 +230,14 @@ impl<'tcx> Visitor<'tcx> for PrintVisitor { self.visit_expr(arg); } }, - ExprKind::MethodCall(ref _method_name, ref _generics, ref _args, ref _fn_span) => { + ExprKind::MethodCall(_method_name, ref _generics, _args, ref _fn_span) => { println!( "MethodCall(ref method_name, ref generics, ref args, ref fn_span) = {};", current ); println!(" // unimplemented: `ExprKind::MethodCall` is not further destructured at the moment"); }, - ExprKind::Tup(ref elements) => { + ExprKind::Tup(elements) => { let elements_pat = self.next("elements"); println!("Tup(ref {}) = {};", elements_pat, current); println!(" if {}.len() == {};", elements_pat, elements.len()); @@ -246,7 +246,7 @@ impl<'tcx> Visitor<'tcx> for PrintVisitor { self.visit_expr(element); } }, - ExprKind::Binary(ref op, ref left, ref right) => { + ExprKind::Binary(ref op, left, right) => { let op_pat = self.next("op"); let left_pat = self.next("left"); let right_pat = self.next("right"); @@ -260,7 +260,7 @@ impl<'tcx> Visitor<'tcx> for PrintVisitor { self.current = right_pat; self.visit_expr(right); }, - ExprKind::Unary(ref op, ref inner) => { + ExprKind::Unary(ref op, inner) => { let inner_pat = self.next("inner"); println!("Unary(UnOp::{:?}, ref {}) = {};", op, inner_pat, current); self.current = inner_pat; @@ -296,7 +296,7 @@ impl<'tcx> Visitor<'tcx> for PrintVisitor { }, } }, - ExprKind::Cast(ref expr, ref ty) => { + ExprKind::Cast(expr, ty) => { let cast_pat = self.next("expr"); let cast_ty = self.next("cast_ty"); let qp_label = self.next("qp"); @@ -310,13 +310,13 @@ impl<'tcx> Visitor<'tcx> for PrintVisitor { self.current = cast_pat; self.visit_expr(expr); }, - ExprKind::Type(ref expr, ref _ty) => { + ExprKind::Type(expr, _ty) => { let cast_pat = self.next("expr"); println!("Type(ref {}, _) = {};", cast_pat, current); self.current = cast_pat; self.visit_expr(expr); }, - ExprKind::Loop(ref body, _, desugaring, _) => { + ExprKind::Loop(body, _, desugaring, _) => { let body_pat = self.next("body"); let des = loop_desugaring_name(desugaring); let label_pat = self.next("label"); @@ -324,10 +324,10 @@ impl<'tcx> Visitor<'tcx> for PrintVisitor { self.current = body_pat; self.visit_block(body); }, - ExprKind::If(ref cond, ref then, ref opt_else) => { + ExprKind::If(cond, then, ref opt_else) => { let cond_pat = self.next("cond"); let then_pat = self.next("then"); - if let Some(ref else_) = *opt_else { + if let Some(else_) = *opt_else { let else_pat = self.next("else_"); println!( "If(ref {}, ref {}, Some(ref {})) = {};", @@ -343,7 +343,7 @@ impl<'tcx> Visitor<'tcx> for PrintVisitor { self.current = then_pat; self.visit_expr(then); }, - ExprKind::Match(ref expr, ref arms, desugaring) => { + ExprKind::Match(expr, arms, desugaring) => { let des = desugaring_name(desugaring); let expr_pat = self.next("expr"); let arms_pat = self.next("arms"); @@ -353,18 +353,18 @@ impl<'tcx> Visitor<'tcx> for PrintVisitor { println!(" if {}.len() == {};", arms_pat, arms.len()); for (i, arm) in arms.iter().enumerate() { self.current = format!("{}[{}].body", arms_pat, i); - self.visit_expr(&arm.body); + self.visit_expr(arm.body); if let Some(ref guard) = arm.guard { let guard_pat = self.next("guard"); println!(" if let Some(ref {}) = {}[{}].guard;", guard_pat, arms_pat, i); match guard { - hir::Guard::If(ref if_expr) => { + hir::Guard::If(if_expr) => { let if_expr_pat = self.next("expr"); println!(" if let Guard::If(ref {}) = {};", if_expr_pat, guard_pat); self.current = if_expr_pat; self.visit_expr(if_expr); }, - hir::Guard::IfLet(ref if_let_pat, ref if_let_expr) => { + hir::Guard::IfLet(if_let_pat, if_let_expr) => { let if_let_pat_pat = self.next("pat"); let if_let_expr_pat = self.next("expr"); println!( @@ -379,26 +379,26 @@ impl<'tcx> Visitor<'tcx> for PrintVisitor { } } self.current = format!("{}[{}].pat", arms_pat, i); - self.visit_pat(&arm.pat); + self.visit_pat(arm.pat); } }, - ExprKind::Closure(ref _capture_clause, ref _func, _, _, _) => { + ExprKind::Closure(ref _capture_clause, _func, _, _, _) => { println!("Closure(ref capture_clause, ref func, _, _, _) = {};", current); println!(" // unimplemented: `ExprKind::Closure` is not further destructured at the moment"); }, - ExprKind::Yield(ref sub, _) => { + ExprKind::Yield(sub, _) => { let sub_pat = self.next("sub"); println!("Yield(ref sub) = {};", current); self.current = sub_pat; self.visit_expr(sub); }, - ExprKind::Block(ref block, _) => { + ExprKind::Block(block, _) => { let block_pat = self.next("block"); println!("Block(ref {}) = {};", block_pat, current); self.current = block_pat; self.visit_block(block); }, - ExprKind::Assign(ref target, ref value, _) => { + ExprKind::Assign(target, value, _) => { let target_pat = self.next("target"); let value_pat = self.next("value"); println!( @@ -410,7 +410,7 @@ impl<'tcx> Visitor<'tcx> for PrintVisitor { self.current = value_pat; self.visit_expr(value); }, - ExprKind::AssignOp(ref op, ref target, ref value) => { + ExprKind::AssignOp(ref op, target, value) => { let op_pat = self.next("op"); let target_pat = self.next("target"); let value_pat = self.next("value"); @@ -424,7 +424,7 @@ impl<'tcx> Visitor<'tcx> for PrintVisitor { self.current = value_pat; self.visit_expr(value); }, - ExprKind::Field(ref object, ref field_ident) => { + ExprKind::Field(object, ref field_ident) => { let obj_pat = self.next("object"); let field_name_pat = self.next("field_name"); println!("Field(ref {}, ref {}) = {};", obj_pat, field_name_pat, current); @@ -432,7 +432,7 @@ impl<'tcx> Visitor<'tcx> for PrintVisitor { self.current = obj_pat; self.visit_expr(object); }, - ExprKind::Index(ref object, ref index) => { + ExprKind::Index(object, index) => { let object_pat = self.next("object"); let index_pat = self.next("index"); println!("Index(ref {}, ref {}) = {};", object_pat, index_pat, current); @@ -447,7 +447,7 @@ impl<'tcx> Visitor<'tcx> for PrintVisitor { self.current = path_pat; self.print_qpath(path); }, - ExprKind::AddrOf(kind, mutability, ref inner) => { + ExprKind::AddrOf(kind, mutability, inner) => { let inner_pat = self.next("inner"); println!( "AddrOf(BorrowKind::{:?}, Mutability::{:?}, ref {}) = {};", @@ -458,7 +458,7 @@ impl<'tcx> Visitor<'tcx> for PrintVisitor { }, ExprKind::Break(ref _destination, ref opt_value) => { let destination_pat = self.next("destination"); - if let Some(ref value) = *opt_value { + if let Some(value) = *opt_value { let value_pat = self.next("value"); println!("Break(ref {}, Some(ref {})) = {};", destination_pat, value_pat, current); self.current = value_pat; @@ -474,7 +474,7 @@ impl<'tcx> Visitor<'tcx> for PrintVisitor { // FIXME: implement label printing }, ExprKind::Ret(ref opt_value) => { - if let Some(ref value) = *opt_value { + if let Some(value) = *opt_value { let value_pat = self.next("value"); println!("Ret(Some(ref {})) = {};", value_pat, current); self.current = value_pat; @@ -491,10 +491,10 @@ impl<'tcx> Visitor<'tcx> for PrintVisitor { println!("LlvmInlineAsm(_) = {};", current); println!(" // unimplemented: `ExprKind::LlvmInlineAsm` is not further destructured at the moment"); }, - ExprKind::Struct(ref path, ref fields, ref opt_base) => { + ExprKind::Struct(path, fields, ref opt_base) => { let path_pat = self.next("path"); let fields_pat = self.next("fields"); - if let Some(ref base) = *opt_base { + if let Some(base) = *opt_base { let base_pat = self.next("base"); println!( "Struct(ref {}, ref {}, Some(ref {})) = {};", @@ -516,7 +516,7 @@ impl<'tcx> Visitor<'tcx> for PrintVisitor { self.current = value_pat; }, // FIXME: compute length (needs type info) - ExprKind::Repeat(ref value, _) => { + ExprKind::Repeat(value, _) => { let value_pat = self.next("value"); println!("Repeat(ref {}, _) = {};", value_pat, current); println!("// unimplemented: repeat count check"); @@ -526,7 +526,7 @@ impl<'tcx> Visitor<'tcx> for PrintVisitor { ExprKind::Err => { println!("Err = {}", current); }, - ExprKind::DropTemps(ref expr) => { + ExprKind::DropTemps(expr) => { let expr_pat = self.next("expr"); println!("DropTemps(ref {}) = {};", expr_pat, current); self.current = expr_pat; @@ -560,7 +560,7 @@ impl<'tcx> Visitor<'tcx> for PrintVisitor { BindingAnnotation::RefMut => "BindingAnnotation::RefMut", }; let name_pat = self.next("name"); - if let Some(ref sub) = *sub { + if let Some(sub) = *sub { let sub_pat = self.next("sub"); println!( "Binding({}, _, {}, Some(ref {})) = {};", @@ -573,7 +573,7 @@ impl<'tcx> Visitor<'tcx> for PrintVisitor { } println!(" if {}.as_str() == \"{}\";", name_pat, ident.as_str()); }, - PatKind::Struct(ref path, ref fields, ignore) => { + PatKind::Struct(ref path, fields, ignore) => { let path_pat = self.next("path"); let fields_pat = self.next("fields"); println!( @@ -585,13 +585,13 @@ impl<'tcx> Visitor<'tcx> for PrintVisitor { println!(" if {}.len() == {};", fields_pat, fields.len()); println!(" // unimplemented: field checks"); }, - PatKind::Or(ref fields) => { + PatKind::Or(fields) => { let fields_pat = self.next("fields"); println!("Or(ref {}) = {};", fields_pat, current); println!(" if {}.len() == {};", fields_pat, fields.len()); println!(" // unimplemented: field checks"); }, - PatKind::TupleStruct(ref path, ref fields, skip_pos) => { + PatKind::TupleStruct(ref path, fields, skip_pos) => { let path_pat = self.next("path"); let fields_pat = self.next("fields"); println!( @@ -609,25 +609,25 @@ impl<'tcx> Visitor<'tcx> for PrintVisitor { self.current = path_pat; self.print_qpath(path); }, - PatKind::Tuple(ref fields, skip_pos) => { + PatKind::Tuple(fields, skip_pos) => { let fields_pat = self.next("fields"); println!("Tuple(ref {}, {:?}) = {};", fields_pat, skip_pos, current); println!(" if {}.len() == {};", fields_pat, fields.len()); println!(" // unimplemented: field checks"); }, - PatKind::Box(ref pat) => { + PatKind::Box(pat) => { let pat_pat = self.next("pat"); println!("Box(ref {}) = {};", pat_pat, current); self.current = pat_pat; self.visit_pat(pat); }, - PatKind::Ref(ref pat, muta) => { + PatKind::Ref(pat, muta) => { let pat_pat = self.next("pat"); println!("Ref(ref {}, Mutability::{:?}) = {};", pat_pat, muta, current); self.current = pat_pat; self.visit_pat(pat); }, - PatKind::Lit(ref lit_expr) => { + PatKind::Lit(lit_expr) => { let lit_expr_pat = self.next("lit_expr"); println!("Lit(ref {}) = {}", lit_expr_pat, current); self.current = lit_expr_pat; @@ -645,10 +645,10 @@ impl<'tcx> Visitor<'tcx> for PrintVisitor { self.current = end_pat; walk_list!(self, visit_expr, end); }, - PatKind::Slice(ref start, ref middle, ref end) => { + PatKind::Slice(start, ref middle, end) => { let start_pat = self.next("start"); let end_pat = self.next("end"); - if let Some(ref middle) = middle { + if let Some(middle) = middle { let middle_pat = self.next("middle"); println!( "Slice(ref {}, Some(ref {}), ref {}) = {};", @@ -678,17 +678,17 @@ impl<'tcx> Visitor<'tcx> for PrintVisitor { let current = format!("{}.kind", self.current); match s.kind { // A local (let) binding: - StmtKind::Local(ref local) => { + StmtKind::Local(local) => { let local_pat = self.next("local"); println!("Local(ref {}) = {};", local_pat, current); - if let Some(ref init) = local.init { + if let Some(init) = local.init { let init_pat = self.next("init"); println!(" if let Some(ref {}) = {}.init;", init_pat, local_pat); self.current = init_pat; self.visit_expr(init); } self.current = format!("{}.pat", local_pat); - self.visit_pat(&local.pat); + self.visit_pat(local.pat); }, // An item binding: StmtKind::Item(_) => { @@ -696,7 +696,7 @@ impl<'tcx> Visitor<'tcx> for PrintVisitor { }, // Expr without trailing semi-colon (must have unit type): - StmtKind::Expr(ref e) => { + StmtKind::Expr(e) => { let e_pat = self.next("e"); println!("Expr(ref {}, _) = {}", e_pat, current); self.current = e_pat; @@ -704,7 +704,7 @@ impl<'tcx> Visitor<'tcx> for PrintVisitor { }, // Expr with trailing semi-colon (may have any type): - StmtKind::Semi(ref e) => { + StmtKind::Semi(e) => { let e_pat = self.next("e"); println!("Semi(ref {}, _) = {}", e_pat, current); self.current = e_pat; @@ -752,7 +752,7 @@ fn loop_desugaring_name(des: hir::LoopSource) -> &'static str { fn print_path(path: &QPath<'_>, first: &mut bool) { match *path { - QPath::Resolved(_, ref path) => { + QPath::Resolved(_, path) => { for segment in path.segments { if *first { *first = false; @@ -762,7 +762,7 @@ fn print_path(path: &QPath<'_>, first: &mut bool) { print!("{:?}", segment.ident.as_str()); } }, - QPath::TypeRelative(ref ty, ref segment) => match ty.kind { + QPath::TypeRelative(ty, segment) => match ty.kind { hir::TyKind::Path(ref inner_path) => { print_path(inner_path, first); if *first { diff --git a/clippy_lints/src/utils/inspector.rs b/clippy_lints/src/utils/inspector.rs index 6fd3c9d7dec..32d34e8d31e 100644 --- a/clippy_lints/src/utils/inspector.rs +++ b/clippy_lints/src/utils/inspector.rs @@ -47,7 +47,7 @@ impl<'tcx> LateLintPass<'tcx> for DeepCodeInspector { match item.vis.node { hir::VisibilityKind::Public => println!("public"), hir::VisibilityKind::Crate(_) => println!("visible crate wide"), - hir::VisibilityKind::Restricted { ref path, .. } => println!( + hir::VisibilityKind::Restricted { path, .. } => println!( "visible in module `{}`", rustc_hir_pretty::to_string(rustc_hir_pretty::NO_ANN, |s| s.print_path(path, false)) ), @@ -99,13 +99,13 @@ impl<'tcx> LateLintPass<'tcx> for DeepCodeInspector { if !has_attr(cx.sess(), cx.tcx.hir().attrs(arm.hir_id)) { return; } - print_pat(cx, &arm.pat, 1); + print_pat(cx, arm.pat, 1); if let Some(ref guard) = arm.guard { println!("guard:"); print_guard(cx, guard, 1); } println!("body:"); - print_expr(cx, &arm.body, 1); + print_expr(cx, arm.body, 1); } fn check_stmt(&mut self, cx: &LateContext<'tcx>, stmt: &'tcx hir::Stmt<'_>) { @@ -113,17 +113,17 @@ impl<'tcx> LateLintPass<'tcx> for DeepCodeInspector { return; } match stmt.kind { - hir::StmtKind::Local(ref local) => { + hir::StmtKind::Local(local) => { println!("local variable of type {}", cx.typeck_results().node_type(local.hir_id)); println!("pattern:"); - print_pat(cx, &local.pat, 0); - if let Some(ref e) = local.init { + print_pat(cx, local.pat, 0); + if let Some(e) = local.init { println!("init expression:"); print_expr(cx, e, 0); } }, hir::StmtKind::Item(_) => println!("item decl"), - hir::StmtKind::Expr(ref e) | hir::StmtKind::Semi(ref e) => print_expr(cx, e, 0), + hir::StmtKind::Expr(e) | hir::StmtKind::Semi(e) => print_expr(cx, e, 0), } } // fn check_foreign_item(&mut self, cx: &LateContext<'tcx>, item: &'tcx @@ -151,7 +151,7 @@ fn print_expr(cx: &LateContext<'_>, expr: &hir::Expr<'_>, indent: usize) { cx.typeck_results().adjustments().get(expr.hir_id) ); match expr.kind { - hir::ExprKind::Box(ref e) => { + hir::ExprKind::Box(e) => { println!("{}Box", ind); print_expr(cx, e, indent + 1); }, @@ -161,7 +161,7 @@ fn print_expr(cx: &LateContext<'_>, expr: &hir::Expr<'_>, indent: usize) { print_expr(cx, e, indent + 1); } }, - hir::ExprKind::Call(ref func, args) => { + hir::ExprKind::Call(func, args) => { println!("{}Call", ind); println!("{}function:", ind); print_expr(cx, func, indent + 1); @@ -170,7 +170,7 @@ fn print_expr(cx: &LateContext<'_>, expr: &hir::Expr<'_>, indent: usize) { print_expr(cx, arg, indent + 1); } }, - hir::ExprKind::MethodCall(ref path, _, args, _) => { + hir::ExprKind::MethodCall(path, _, args, _) => { println!("{}MethodCall", ind); println!("{}method name: {}", ind, path.ident.name); for arg in args { @@ -183,7 +183,7 @@ fn print_expr(cx: &LateContext<'_>, expr: &hir::Expr<'_>, indent: usize) { print_expr(cx, e, indent + 1); } }, - hir::ExprKind::Binary(op, ref lhs, ref rhs) => { + hir::ExprKind::Binary(op, lhs, rhs) => { println!("{}Binary", ind); println!("{}op: {:?}", ind, op.node); println!("{}lhs:", ind); @@ -191,7 +191,7 @@ fn print_expr(cx: &LateContext<'_>, expr: &hir::Expr<'_>, indent: usize) { println!("{}rhs:", ind); print_expr(cx, rhs, indent + 1); }, - hir::ExprKind::Unary(op, ref inner) => { + hir::ExprKind::Unary(op, inner) => { println!("{}Unary", ind); println!("{}op: {:?}", ind, op); print_expr(cx, inner, indent + 1); @@ -200,12 +200,12 @@ fn print_expr(cx: &LateContext<'_>, expr: &hir::Expr<'_>, indent: usize) { println!("{}Lit", ind); println!("{}{:?}", ind, lit); }, - hir::ExprKind::Cast(ref e, ref target) => { + hir::ExprKind::Cast(e, target) => { println!("{}Cast", ind); print_expr(cx, e, indent + 1); println!("{}target type: {:?}", ind, target); }, - hir::ExprKind::Type(ref e, ref target) => { + hir::ExprKind::Type(e, target) => { println!("{}Type", ind); print_expr(cx, e, indent + 1); println!("{}target type: {:?}", ind, target); @@ -213,16 +213,16 @@ fn print_expr(cx: &LateContext<'_>, expr: &hir::Expr<'_>, indent: usize) { hir::ExprKind::Loop(..) => { println!("{}Loop", ind); }, - hir::ExprKind::If(ref cond, _, ref else_opt) => { + hir::ExprKind::If(cond, _, ref else_opt) => { println!("{}If", ind); println!("{}condition:", ind); print_expr(cx, cond, indent + 1); - if let Some(ref els) = *else_opt { + if let Some(els) = *else_opt { println!("{}else:", ind); print_expr(cx, els, indent + 1); } }, - hir::ExprKind::Match(ref cond, _, ref source) => { + hir::ExprKind::Match(cond, _, ref source) => { println!("{}Match", ind); println!("{}condition:", ind); print_expr(cx, cond, indent + 1); @@ -232,21 +232,21 @@ fn print_expr(cx: &LateContext<'_>, expr: &hir::Expr<'_>, indent: usize) { println!("{}Closure", ind); println!("{}clause: {:?}", ind, clause); }, - hir::ExprKind::Yield(ref sub, _) => { + hir::ExprKind::Yield(sub, _) => { println!("{}Yield", ind); print_expr(cx, sub, indent + 1); }, hir::ExprKind::Block(_, _) => { println!("{}Block", ind); }, - hir::ExprKind::Assign(ref lhs, ref rhs, _) => { + hir::ExprKind::Assign(lhs, rhs, _) => { println!("{}Assign", ind); println!("{}lhs:", ind); print_expr(cx, lhs, indent + 1); println!("{}rhs:", ind); print_expr(cx, rhs, indent + 1); }, - hir::ExprKind::AssignOp(ref binop, ref lhs, ref rhs) => { + hir::ExprKind::AssignOp(ref binop, lhs, rhs) => { println!("{}AssignOp", ind); println!("{}op: {:?}", ind, binop.node); println!("{}lhs:", ind); @@ -254,31 +254,31 @@ fn print_expr(cx: &LateContext<'_>, expr: &hir::Expr<'_>, indent: usize) { println!("{}rhs:", ind); print_expr(cx, rhs, indent + 1); }, - hir::ExprKind::Field(ref e, ident) => { + hir::ExprKind::Field(e, ident) => { println!("{}Field", ind); println!("{}field name: {}", ind, ident.name); println!("{}struct expr:", ind); print_expr(cx, e, indent + 1); }, - hir::ExprKind::Index(ref arr, ref idx) => { + hir::ExprKind::Index(arr, idx) => { println!("{}Index", ind); println!("{}array expr:", ind); print_expr(cx, arr, indent + 1); println!("{}index expr:", ind); print_expr(cx, idx, indent + 1); }, - hir::ExprKind::Path(hir::QPath::Resolved(ref ty, ref path)) => { + hir::ExprKind::Path(hir::QPath::Resolved(ref ty, path)) => { println!("{}Resolved Path, {:?}", ind, ty); println!("{}path: {:?}", ind, path); }, - hir::ExprKind::Path(hir::QPath::TypeRelative(ref ty, ref seg)) => { + hir::ExprKind::Path(hir::QPath::TypeRelative(ty, seg)) => { println!("{}Relative Path, {:?}", ind, ty); println!("{}seg: {:?}", ind, seg); }, hir::ExprKind::Path(hir::QPath::LangItem(lang_item, ..)) => { println!("{}Lang Item Path, {:?}", ind, lang_item.name()); }, - hir::ExprKind::AddrOf(kind, ref muta, ref e) => { + hir::ExprKind::AddrOf(kind, ref muta, e) => { println!("{}AddrOf", ind); println!("kind: {:?}", kind); println!("mutability: {:?}", muta); @@ -286,18 +286,18 @@ fn print_expr(cx: &LateContext<'_>, expr: &hir::Expr<'_>, indent: usize) { }, hir::ExprKind::Break(_, ref e) => { println!("{}Break", ind); - if let Some(ref e) = *e { + if let Some(e) = *e { print_expr(cx, e, indent + 1); } }, hir::ExprKind::Continue(_) => println!("{}Again", ind), hir::ExprKind::Ret(ref e) => { println!("{}Ret", ind); - if let Some(ref e) = *e { + if let Some(e) = *e { print_expr(cx, e, indent + 1); } }, - hir::ExprKind::InlineAsm(ref asm) => { + hir::ExprKind::InlineAsm(asm) => { println!("{}InlineAsm", ind); println!("{}template: {}", ind, InlineAsmTemplatePiece::to_string(asm.template)); println!("{}options: {:?}", ind, asm.options); @@ -322,7 +322,7 @@ fn print_expr(cx: &LateContext<'_>, expr: &hir::Expr<'_>, indent: usize) { } } }, - hir::ExprKind::LlvmInlineAsm(ref asm) => { + hir::ExprKind::LlvmInlineAsm(asm) => { let inputs = &asm.inputs_exprs; let outputs = &asm.outputs_exprs; println!("{}LlvmInlineAsm", ind); @@ -335,14 +335,14 @@ fn print_expr(cx: &LateContext<'_>, expr: &hir::Expr<'_>, indent: usize) { print_expr(cx, e, indent + 1); } }, - hir::ExprKind::Struct(ref path, fields, ref base) => { + hir::ExprKind::Struct(path, fields, ref base) => { println!("{}Struct", ind); println!("{}path: {:?}", ind, path); for field in fields { println!("{}field \"{}\":", ind, field.ident.name); - print_expr(cx, &field.expr, indent + 1); + print_expr(cx, field.expr, indent + 1); } - if let Some(ref base) = *base { + if let Some(base) = *base { println!("{}base:", ind); print_expr(cx, base, indent + 1); } @@ -352,7 +352,7 @@ fn print_expr(cx: &LateContext<'_>, expr: &hir::Expr<'_>, indent: usize) { println!("{}anon_const:", ind); print_expr(cx, &cx.tcx.hir().body(anon_const.body).value, indent + 1); }, - hir::ExprKind::Repeat(ref val, ref anon_const) => { + hir::ExprKind::Repeat(val, ref anon_const) => { println!("{}Repeat", ind); println!("{}value:", ind); print_expr(cx, val, indent + 1); @@ -362,7 +362,7 @@ fn print_expr(cx: &LateContext<'_>, expr: &hir::Expr<'_>, indent: usize) { hir::ExprKind::Err => { println!("{}Err", ind); }, - hir::ExprKind::DropTemps(ref e) => { + hir::ExprKind::DropTemps(e) => { println!("{}DropTemps", ind); print_expr(cx, e, indent + 1); }, @@ -375,7 +375,7 @@ fn print_item(cx: &LateContext<'_>, item: &hir::Item<'_>) { match item.vis.node { hir::VisibilityKind::Public => println!("public"), hir::VisibilityKind::Crate(_) => println!("visible crate wide"), - hir::VisibilityKind::Restricted { ref path, .. } => println!( + hir::VisibilityKind::Restricted { path, .. } => println!( "visible in module `{}`", rustc_hir_pretty::to_string(rustc_hir_pretty::NO_ANN, |s| s.print_path(path, false)) ), @@ -395,7 +395,7 @@ fn print_item(cx: &LateContext<'_>, item: &hir::Item<'_>) { println!("weird extern crate without a crate id"); } }, - hir::ItemKind::Use(ref path, ref kind) => println!("{:?}, {:?}", path, kind), + hir::ItemKind::Use(path, ref kind) => println!("{:?}, {:?}", path, kind), hir::ItemKind::Static(..) => println!("static item of type {:#?}", cx.tcx.type_of(did)), hir::ItemKind::Const(..) => println!("const item of type {:#?}", cx.tcx.type_of(did)), hir::ItemKind::Fn(..) => { @@ -404,7 +404,7 @@ fn print_item(cx: &LateContext<'_>, item: &hir::Item<'_>) { }, hir::ItemKind::Mod(..) => println!("module"), hir::ItemKind::ForeignMod { abi, .. } => println!("foreign module with abi: {}", abi), - hir::ItemKind::GlobalAsm(ref asm) => println!("global asm: {:?}", asm), + hir::ItemKind::GlobalAsm(asm) => println!("global asm: {:?}", asm), hir::ItemKind::TyAlias(..) => { println!("type alias for {:?}", cx.tcx.type_of(did)); }, @@ -454,7 +454,7 @@ fn print_pat(cx: &LateContext<'_>, pat: &hir::Pat<'_>, indent: usize) { println!("{}Binding", ind); println!("{}mode: {:?}", ind, mode); println!("{}name: {}", ind, ident.name); - if let Some(ref inner) = *inner { + if let Some(inner) = *inner { println!("{}inner:", ind); print_pat(cx, inner, indent + 1); } @@ -479,7 +479,7 @@ fn print_pat(cx: &LateContext<'_>, pat: &hir::Pat<'_>, indent: usize) { if field.is_shorthand { println!("{} in shorthand notation", ind); } - print_pat(cx, &field.pat, indent + 1); + print_pat(cx, field.pat, indent + 1); } }, hir::PatKind::TupleStruct(ref path, fields, opt_dots_position) => { @@ -496,11 +496,11 @@ fn print_pat(cx: &LateContext<'_>, pat: &hir::Pat<'_>, indent: usize) { print_pat(cx, field, indent + 1); } }, - hir::PatKind::Path(hir::QPath::Resolved(ref ty, ref path)) => { + hir::PatKind::Path(hir::QPath::Resolved(ref ty, path)) => { println!("{}Resolved Path, {:?}", ind, ty); println!("{}path: {:?}", ind, path); }, - hir::PatKind::Path(hir::QPath::TypeRelative(ref ty, ref seg)) => { + hir::PatKind::Path(hir::QPath::TypeRelative(ty, seg)) => { println!("{}Relative Path, {:?}", ind, ty); println!("{}seg: {:?}", ind, seg); }, @@ -516,16 +516,16 @@ fn print_pat(cx: &LateContext<'_>, pat: &hir::Pat<'_>, indent: usize) { print_pat(cx, field, indent + 1); } }, - hir::PatKind::Box(ref inner) => { + hir::PatKind::Box(inner) => { println!("{}Box", ind); print_pat(cx, inner, indent + 1); }, - hir::PatKind::Ref(ref inner, ref muta) => { + hir::PatKind::Ref(inner, ref muta) => { println!("{}Ref", ind); println!("{}mutability: {:?}", ind, muta); print_pat(cx, inner, indent + 1); }, - hir::PatKind::Lit(ref e) => { + hir::PatKind::Lit(e) => { println!("{}Lit", ind); print_expr(cx, e, indent + 1); }, @@ -549,7 +549,7 @@ fn print_pat(cx: &LateContext<'_>, pat: &hir::Pat<'_>, indent: usize) { print_pat(cx, pat, indent + 1); } println!("i:"); - if let Some(ref pat) = *range { + if let Some(pat) = *range { print_pat(cx, pat, indent + 1); } println!("[y, z]:"); diff --git a/clippy_lints/src/utils/internal_lints.rs b/clippy_lints/src/utils/internal_lints.rs index d5a13c135b1..cf8039d6059 100644 --- a/clippy_lints/src/utils/internal_lints.rs +++ b/clippy_lints/src/utils/internal_lints.rs @@ -353,12 +353,12 @@ impl<'tcx> LateLintPass<'tcx> for LintWithoutLintPass { return; } - if let hir::ItemKind::Static(ref ty, Mutability::Not, body_id) = item.kind { + if let hir::ItemKind::Static(ty, Mutability::Not, body_id) = item.kind { if is_lint_ref_type(cx, ty) { let expr = &cx.tcx.hir().body(body_id).value; if_chain! { - if let ExprKind::AddrOf(_, _, ref inner_exp) = expr.kind; - if let ExprKind::Struct(_, ref fields, _) = inner_exp.kind; + if let ExprKind::AddrOf(_, _, inner_exp) = expr.kind; + if let ExprKind::Struct(_, fields, _) = inner_exp.kind; let field = fields .iter() .find(|f| f.ident.as_str() == "desc") @@ -385,7 +385,7 @@ impl<'tcx> LateLintPass<'tcx> for LintWithoutLintPass { { if let hir::ItemKind::Impl(hir::Impl { of_trait: None, - items: ref impl_item_refs, + items: impl_item_refs, .. }) = item.kind { @@ -437,7 +437,7 @@ fn is_lint_ref_type<'tcx>(cx: &LateContext<'tcx>, ty: &Ty<'_>) -> bool { if let TyKind::Rptr( _, MutTy { - ty: ref inner, + ty: inner, mutbl: Mutability::Not, }, ) = ty.kind @@ -498,7 +498,7 @@ impl<'tcx> LateLintPass<'tcx> for CompilerLintFunctions { } if_chain! { - if let ExprKind::MethodCall(ref path, _, ref args, _) = expr.kind; + if let ExprKind::MethodCall(path, _, args, _) = expr.kind; let fn_name = path.ident; if let Some(sugg) = self.map.get(&*fn_name.as_str()); let ty = cx.typeck_results().expr_ty(&args[0]).peel_refs(); @@ -577,7 +577,7 @@ impl<'tcx> LateLintPass<'tcx> for CollapsibleCalls { } if_chain! { - if let ExprKind::Call(ref func, ref and_then_args) = expr.kind; + if let ExprKind::Call(func, and_then_args) = expr.kind; if let ExprKind::Path(ref path) = func.kind; if match_qpath(path, &["span_lint_and_then"]); if and_then_args.len() == 5; @@ -587,7 +587,7 @@ impl<'tcx> LateLintPass<'tcx> for CollapsibleCalls { let stmts = &block.stmts; if stmts.len() == 1 && block.expr.is_none(); if let StmtKind::Semi(only_expr) = &stmts[0].kind; - if let ExprKind::MethodCall(ref ps, _, ref span_call_args, _) = &only_expr.kind; + if let ExprKind::MethodCall(ps, _, span_call_args, _) = &only_expr.kind; then { let and_then_snippets = get_and_then_snippets(cx, and_then_args); let mut sle = SpanlessEq::new(cx).deny_side_effects(); @@ -762,7 +762,7 @@ impl<'tcx> LateLintPass<'tcx> for MatchTypeOnDiagItem { // Check if this is a call to utils::match_type() if let ExprKind::Call(fn_path, [context, ty, ty_path]) = expr.kind; if let ExprKind::Path(fn_qpath) = &fn_path.kind; - if match_qpath(&fn_qpath, &["utils", "match_type"]); + if match_qpath(fn_qpath, &["utils", "match_type"]); // Extract the path to the matched type if let Some(segments) = path_to_matched_type(cx, ty_path); let segments: Vec<&str> = segments.iter().map(|sym| &**sym).collect(); diff --git a/clippy_lints/src/vec.rs b/clippy_lints/src/vec.rs index bc2eb88114e..febd4b6ff7b 100644 --- a/clippy_lints/src/vec.rs +++ b/clippy_lints/src/vec.rs @@ -49,7 +49,7 @@ impl<'tcx> LateLintPass<'tcx> for UselessVec { if_chain! { if let ty::Ref(_, ty, _) = cx.typeck_results().expr_ty_adjusted(expr).kind(); if let ty::Slice(..) = ty.kind(); - if let ExprKind::AddrOf(BorrowKind::Ref, mutability, ref addressee) = expr.kind; + if let ExprKind::AddrOf(BorrowKind::Ref, mutability, addressee) = expr.kind; if let Some(vec_args) = higher::vec_macro(cx, addressee); then { self.check_vec_macro(cx, &vec_args, mutability, expr.span); diff --git a/clippy_lints/src/vec_resize_to_zero.rs b/clippy_lints/src/vec_resize_to_zero.rs index e035d3c5cad..5540e87405f 100644 --- a/clippy_lints/src/vec_resize_to_zero.rs +++ b/clippy_lints/src/vec_resize_to_zero.rs @@ -30,7 +30,7 @@ declare_lint_pass!(VecResizeToZero => [VEC_RESIZE_TO_ZERO]); impl<'tcx> LateLintPass<'tcx> for VecResizeToZero { fn check_expr(&mut self, cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) { if_chain! { - if let hir::ExprKind::MethodCall(path_segment, _, ref args, _) = expr.kind; + if let hir::ExprKind::MethodCall(path_segment, _, args, _) = expr.kind; if let Some(method_def_id) = cx.typeck_results().type_dependent_def_id(expr.hir_id); if match_def_path(cx, method_def_id, &paths::VEC_RESIZE) && args.len() == 3; if let ExprKind::Lit(Spanned { node: LitKind::Int(0, _), .. }) = args[1].kind; diff --git a/clippy_lints/src/zero_div_zero.rs b/clippy_lints/src/zero_div_zero.rs index 3b4890ad560..350b1cf25ff 100644 --- a/clippy_lints/src/zero_div_zero.rs +++ b/clippy_lints/src/zero_div_zero.rs @@ -31,7 +31,7 @@ impl<'tcx> LateLintPass<'tcx> for ZeroDiv { fn check_expr(&mut self, cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) { // check for instances of 0.0/0.0 if_chain! { - if let ExprKind::Binary(ref op, ref left, ref right) = expr.kind; + if let ExprKind::Binary(ref op, left, right) = expr.kind; if let BinOpKind::Div = op.node; // TODO - constant_simple does not fold many operations involving floats. // That's probably fine for this lint - it's pretty unlikely that someone would diff --git a/clippy_lints/src/zero_sized_map_values.rs b/clippy_lints/src/zero_sized_map_values.rs index 2abd033e2a0..f93f0047f51 100644 --- a/clippy_lints/src/zero_sized_map_values.rs +++ b/clippy_lints/src/zero_sized_map_values.rs @@ -50,7 +50,7 @@ impl LateLintPass<'_> for ZeroSizedMapValues { if !in_trait_impl(cx, hir_ty.hir_id); let ty = ty_from_hir_ty(cx, hir_ty); if is_type_diagnostic_item(cx, ty, sym::hashmap_type) || match_type(cx, ty, &paths::BTREEMAP); - if let Adt(_, ref substs) = ty.kind(); + if let Adt(_, substs) = ty.kind(); let ty = substs.type_at(1); // Do this to prevent `layout_of` crashing, being unable to fully normalize `ty`. if is_normalizable(cx, cx.param_env, ty); diff --git a/src/driver.rs b/src/driver.rs index b6aed862e89..fa0c5f01430 100644 --- a/src/driver.rs +++ b/src/driver.rs @@ -99,17 +99,17 @@ impl rustc_driver::Callbacks for ClippyCallbacks { config.parse_sess_created = Some(Box::new(move |parse_sess| { track_clippy_args(parse_sess, &clippy_args_var); })); - config.register_lints = Some(Box::new(move |sess, mut lint_store| { + config.register_lints = Some(Box::new(move |sess, lint_store| { // technically we're ~guaranteed that this is none but might as well call anything that // is there already. Certainly it can't hurt. if let Some(previous) = &previous { (previous)(sess, lint_store); } - let conf = clippy_lints::read_conf(&[], &sess); - clippy_lints::register_plugins(&mut lint_store, &sess, &conf); - clippy_lints::register_pre_expansion_lints(&mut lint_store); - clippy_lints::register_renamed(&mut lint_store); + let conf = clippy_lints::read_conf(&[], sess); + clippy_lints::register_plugins(lint_store, sess, &conf); + clippy_lints::register_pre_expansion_lints(lint_store); + clippy_lints::register_renamed(lint_store); })); // FIXME: #4825; This is required, because Clippy lints that are based on MIR have to be @@ -191,7 +191,7 @@ fn report_clippy_ice(info: &panic::PanicInfo<'_>, bug_report_url: &str) { ]; for note in &xs { - handler.note_without_error(¬e); + handler.note_without_error(note); } // If backtraces are enabled, also print the query stack diff --git a/tests/compile-test.rs b/tests/compile-test.rs index 0594663786c..f4d354f0bf9 100644 --- a/tests/compile-test.rs +++ b/tests/compile-test.rs @@ -98,7 +98,7 @@ fn default_config() -> compiletest::Config { fn run_mode(cfg: &mut compiletest::Config) { cfg.mode = TestMode::Ui; cfg.src_base = Path::new("tests").join("ui"); - compiletest::run_tests(&cfg); + compiletest::run_tests(cfg); } fn run_internal_tests(cfg: &mut compiletest::Config) { @@ -108,7 +108,7 @@ fn run_internal_tests(cfg: &mut compiletest::Config) { } cfg.mode = TestMode::Ui; cfg.src_base = Path::new("tests").join("ui-internal"); - compiletest::run_tests(&cfg); + compiletest::run_tests(cfg); } fn run_ui_toml(config: &mut compiletest::Config) { @@ -136,7 +136,7 @@ fn run_ui_toml(config: &mut compiletest::Config) { base: config.src_base.clone(), relative_dir: dir_path.file_name().unwrap().into(), }; - let test_name = compiletest::make_test_name(&config, &paths); + let test_name = compiletest::make_test_name(config, &paths); let index = tests .iter() .position(|test| test.desc.name == test_name) @@ -150,10 +150,10 @@ fn run_ui_toml(config: &mut compiletest::Config) { config.mode = TestMode::Ui; config.src_base = Path::new("tests").join("ui-toml").canonicalize().unwrap(); - let tests = compiletest::make_tests(&config); + let tests = compiletest::make_tests(config); let manifest_dir = var("CARGO_MANIFEST_DIR").unwrap_or_default(); - let res = run_tests(&config, tests); + let res = run_tests(config, tests); set_var("CARGO_MANIFEST_DIR", &manifest_dir); match res { Ok(true) => {}, @@ -221,7 +221,7 @@ fn run_ui_cargo(config: &mut compiletest::Config) { base: config.src_base.clone(), relative_dir: src_path.strip_prefix(&config.src_base).unwrap().into(), }; - let test_name = compiletest::make_test_name(&config, &paths); + let test_name = compiletest::make_test_name(config, &paths); let index = tests .iter() .position(|test| test.desc.name == test_name) @@ -240,11 +240,11 @@ fn run_ui_cargo(config: &mut compiletest::Config) { config.mode = TestMode::Ui; config.src_base = Path::new("tests").join("ui-cargo").canonicalize().unwrap(); - let tests = compiletest::make_tests(&config); + let tests = compiletest::make_tests(config); let current_dir = env::current_dir().unwrap(); let conf_dir = var("CLIPPY_CONF_DIR").unwrap_or_default(); - let res = run_tests(&config, &config.filters, tests); + let res = run_tests(config, &config.filters, tests); env::set_current_dir(current_dir).unwrap(); set_var("CLIPPY_CONF_DIR", conf_dir); diff --git a/tests/ui/borrow_interior_mutable_const/others.rs b/tests/ui/borrow_interior_mutable_const/others.rs index ea25729d11d..4327f12c37c 100644 --- a/tests/ui/borrow_interior_mutable_const/others.rs +++ b/tests/ui/borrow_interior_mutable_const/others.rs @@ -1,5 +1,9 @@ #![warn(clippy::borrow_interior_mutable_const)] -#![allow(clippy::declare_interior_mutable_const, clippy::ref_in_deref)] +#![allow( + clippy::declare_interior_mutable_const, + clippy::ref_in_deref, + clippy::needless_borrow +)] #![allow(const_item_mutation)] use std::borrow::Cow; diff --git a/tests/ui/borrow_interior_mutable_const/others.stderr b/tests/ui/borrow_interior_mutable_const/others.stderr index 9a908cf30e9..f146b97cf61 100644 --- a/tests/ui/borrow_interior_mutable_const/others.stderr +++ b/tests/ui/borrow_interior_mutable_const/others.stderr @@ -1,5 +1,5 @@ error: a `const` item with interior mutability should not be borrowed - --> $DIR/others.rs:54:5 + --> $DIR/others.rs:58:5 | LL | ATOMIC.store(1, Ordering::SeqCst); //~ ERROR interior mutability | ^^^^^^ @@ -8,7 +8,7 @@ LL | ATOMIC.store(1, Ordering::SeqCst); //~ ERROR interior mutability = help: assign this const to a local or static variable, and use the variable here error: a `const` item with interior mutability should not be borrowed - --> $DIR/others.rs:55:16 + --> $DIR/others.rs:59:16 | LL | assert_eq!(ATOMIC.load(Ordering::SeqCst), 5); //~ ERROR interior mutability | ^^^^^^ @@ -16,7 +16,7 @@ LL | assert_eq!(ATOMIC.load(Ordering::SeqCst), 5); //~ ERROR interior mutabi = help: assign this const to a local or static variable, and use the variable here error: a `const` item with interior mutability should not be borrowed - --> $DIR/others.rs:58:22 + --> $DIR/others.rs:62:22 | LL | let _once_ref = &ONCE_INIT; //~ ERROR interior mutability | ^^^^^^^^^ @@ -24,7 +24,7 @@ LL | let _once_ref = &ONCE_INIT; //~ ERROR interior mutability = help: assign this const to a local or static variable, and use the variable here error: a `const` item with interior mutability should not be borrowed - --> $DIR/others.rs:59:25 + --> $DIR/others.rs:63:25 | LL | let _once_ref_2 = &&ONCE_INIT; //~ ERROR interior mutability | ^^^^^^^^^ @@ -32,7 +32,7 @@ LL | let _once_ref_2 = &&ONCE_INIT; //~ ERROR interior mutability = help: assign this const to a local or static variable, and use the variable here error: a `const` item with interior mutability should not be borrowed - --> $DIR/others.rs:60:27 + --> $DIR/others.rs:64:27 | LL | let _once_ref_4 = &&&&ONCE_INIT; //~ ERROR interior mutability | ^^^^^^^^^ @@ -40,7 +40,7 @@ LL | let _once_ref_4 = &&&&ONCE_INIT; //~ ERROR interior mutability = help: assign this const to a local or static variable, and use the variable here error: a `const` item with interior mutability should not be borrowed - --> $DIR/others.rs:61:26 + --> $DIR/others.rs:65:26 | LL | let _once_mut = &mut ONCE_INIT; //~ ERROR interior mutability | ^^^^^^^^^ @@ -48,7 +48,7 @@ LL | let _once_mut = &mut ONCE_INIT; //~ ERROR interior mutability = help: assign this const to a local or static variable, and use the variable here error: a `const` item with interior mutability should not be borrowed - --> $DIR/others.rs:72:14 + --> $DIR/others.rs:76:14 | LL | let _ = &ATOMIC_TUPLE; //~ ERROR interior mutability | ^^^^^^^^^^^^ @@ -56,7 +56,7 @@ LL | let _ = &ATOMIC_TUPLE; //~ ERROR interior mutability = help: assign this const to a local or static variable, and use the variable here error: a `const` item with interior mutability should not be borrowed - --> $DIR/others.rs:73:14 + --> $DIR/others.rs:77:14 | LL | let _ = &ATOMIC_TUPLE.0; //~ ERROR interior mutability | ^^^^^^^^^^^^ @@ -64,7 +64,7 @@ LL | let _ = &ATOMIC_TUPLE.0; //~ ERROR interior mutability = help: assign this const to a local or static variable, and use the variable here error: a `const` item with interior mutability should not be borrowed - --> $DIR/others.rs:74:19 + --> $DIR/others.rs:78:19 | LL | let _ = &(&&&&ATOMIC_TUPLE).0; //~ ERROR interior mutability | ^^^^^^^^^^^^ @@ -72,7 +72,7 @@ LL | let _ = &(&&&&ATOMIC_TUPLE).0; //~ ERROR interior mutability = help: assign this const to a local or static variable, and use the variable here error: a `const` item with interior mutability should not be borrowed - --> $DIR/others.rs:75:14 + --> $DIR/others.rs:79:14 | LL | let _ = &ATOMIC_TUPLE.0[0]; //~ ERROR interior mutability | ^^^^^^^^^^^^ @@ -80,7 +80,7 @@ LL | let _ = &ATOMIC_TUPLE.0[0]; //~ ERROR interior mutability = help: assign this const to a local or static variable, and use the variable here error: a `const` item with interior mutability should not be borrowed - --> $DIR/others.rs:76:13 + --> $DIR/others.rs:80:13 | LL | let _ = ATOMIC_TUPLE.0[0].load(Ordering::SeqCst); //~ ERROR interior mutability | ^^^^^^^^^^^^ @@ -88,7 +88,7 @@ LL | let _ = ATOMIC_TUPLE.0[0].load(Ordering::SeqCst); //~ ERROR interior mu = help: assign this const to a local or static variable, and use the variable here error: a `const` item with interior mutability should not be borrowed - --> $DIR/others.rs:82:13 + --> $DIR/others.rs:86:13 | LL | let _ = ATOMIC_TUPLE.0[0]; //~ ERROR interior mutability | ^^^^^^^^^^^^ @@ -96,7 +96,7 @@ LL | let _ = ATOMIC_TUPLE.0[0]; //~ ERROR interior mutability = help: assign this const to a local or static variable, and use the variable here error: a `const` item with interior mutability should not be borrowed - --> $DIR/others.rs:87:5 + --> $DIR/others.rs:91:5 | LL | CELL.set(2); //~ ERROR interior mutability | ^^^^ @@ -104,7 +104,7 @@ LL | CELL.set(2); //~ ERROR interior mutability = help: assign this const to a local or static variable, and use the variable here error: a `const` item with interior mutability should not be borrowed - --> $DIR/others.rs:88:16 + --> $DIR/others.rs:92:16 | LL | assert_eq!(CELL.get(), 6); //~ ERROR interior mutability | ^^^^ diff --git a/tests/ui/collapsible_match2.rs b/tests/ui/collapsible_match2.rs index 8372a212477..542e6948427 100644 --- a/tests/ui/collapsible_match2.rs +++ b/tests/ui/collapsible_match2.rs @@ -1,5 +1,10 @@ #![warn(clippy::collapsible_match)] -#![allow(clippy::needless_return, clippy::no_effect, clippy::single_match)] +#![allow( + clippy::needless_return, + clippy::no_effect, + clippy::single_match, + clippy::needless_borrow +)] fn lint_cases(opt_opt: Option>, res_opt: Result, String>) { // if guards on outer match diff --git a/tests/ui/collapsible_match2.stderr b/tests/ui/collapsible_match2.stderr index c8a445ef369..ffef32d1fde 100644 --- a/tests/ui/collapsible_match2.stderr +++ b/tests/ui/collapsible_match2.stderr @@ -1,5 +1,5 @@ error: unnecessary nested match - --> $DIR/collapsible_match2.rs:8:34 + --> $DIR/collapsible_match2.rs:13:34 | LL | Ok(val) if make() => match val { | __________________________________^ @@ -10,7 +10,7 @@ LL | | }, | = note: `-D clippy::collapsible-match` implied by `-D warnings` help: the outer pattern can be modified to include the inner pattern - --> $DIR/collapsible_match2.rs:8:16 + --> $DIR/collapsible_match2.rs:13:16 | LL | Ok(val) if make() => match val { | ^^^ replace this binding @@ -18,7 +18,7 @@ LL | Some(n) => foo(n), | ^^^^^^^ with this pattern error: unnecessary nested match - --> $DIR/collapsible_match2.rs:15:24 + --> $DIR/collapsible_match2.rs:20:24 | LL | Ok(val) => match val { | ________________________^ @@ -28,7 +28,7 @@ LL | | }, | |_____________^ | help: the outer pattern can be modified to include the inner pattern - --> $DIR/collapsible_match2.rs:15:16 + --> $DIR/collapsible_match2.rs:20:16 | LL | Ok(val) => match val { | ^^^ replace this binding @@ -36,7 +36,7 @@ LL | Some(n) => foo(n), | ^^^^^^^ with this pattern error: unnecessary nested match - --> $DIR/collapsible_match2.rs:29:29 + --> $DIR/collapsible_match2.rs:34:29 | LL | $pat => match $e { | _____________________________^ @@ -49,7 +49,7 @@ LL | mac!(res_opt => Ok(val), val => Some(n), foo(n)); | ------------------------------------------------- in this macro invocation | help: the outer pattern can be modified to include the inner pattern - --> $DIR/collapsible_match2.rs:41:28 + --> $DIR/collapsible_match2.rs:46:28 | LL | mac!(res_opt => Ok(val), val => Some(n), foo(n)); | ^^^ ^^^^^^^ with this pattern @@ -58,7 +58,7 @@ LL | mac!(res_opt => Ok(val), val => Some(n), foo(n)); = note: this error originates in a macro (in Nightly builds, run with -Z macro-backtrace for more info) error: unnecessary nested match - --> $DIR/collapsible_match2.rs:46:20 + --> $DIR/collapsible_match2.rs:51:20 | LL | Some(s) => match *s { | ____________________^ @@ -68,7 +68,7 @@ LL | | }, | |_________^ | help: the outer pattern can be modified to include the inner pattern - --> $DIR/collapsible_match2.rs:46:14 + --> $DIR/collapsible_match2.rs:51:14 | LL | Some(s) => match *s { | ^ replace this binding @@ -76,7 +76,7 @@ LL | [n] => foo(n), | ^^^ with this pattern error: unnecessary nested match - --> $DIR/collapsible_match2.rs:55:24 + --> $DIR/collapsible_match2.rs:60:24 | LL | Some(ref s) => match &*s { | ________________________^ @@ -86,7 +86,7 @@ LL | | }, | |_________^ | help: the outer pattern can be modified to include the inner pattern - --> $DIR/collapsible_match2.rs:55:14 + --> $DIR/collapsible_match2.rs:60:14 | LL | Some(ref s) => match &*s { | ^^^^^ replace this binding diff --git a/tests/ui/escape_analysis.rs b/tests/ui/escape_analysis.rs index d26f48fc68f..13e2b6c7a2e 100644 --- a/tests/ui/escape_analysis.rs +++ b/tests/ui/escape_analysis.rs @@ -101,7 +101,7 @@ fn warn_match() { let x = box A; match &x { // not moved - ref y => (), + y => (), } } @@ -111,7 +111,7 @@ fn nowarn_large_array() { let x = box [1; 10000]; match &x { // not moved - ref y => (), + y => (), } } diff --git a/tests/ui/implicit_clone.rs b/tests/ui/implicit_clone.rs index 19101522163..cef71cf79d7 100644 --- a/tests/ui/implicit_clone.rs +++ b/tests/ui/implicit_clone.rs @@ -66,7 +66,7 @@ fn main() { let _ = vec.to_vec(); let vec_ref = &vec; - let _ = return_owned_from_slice(&vec_ref); + let _ = return_owned_from_slice(vec_ref); let _ = vec_ref.to_owned(); let _ = vec_ref.to_vec(); diff --git a/tests/ui/into_iter_on_ref.fixed b/tests/ui/into_iter_on_ref.fixed index 7f92d0dbdc9..b77f17944d8 100644 --- a/tests/ui/into_iter_on_ref.fixed +++ b/tests/ui/into_iter_on_ref.fixed @@ -1,5 +1,5 @@ // run-rustfix -#![allow(clippy::useless_vec)] +#![allow(clippy::useless_vec, clippy::needless_borrow)] #![warn(clippy::into_iter_on_ref)] struct X; diff --git a/tests/ui/into_iter_on_ref.rs b/tests/ui/into_iter_on_ref.rs index 416056d3fdb..3854bb05af8 100644 --- a/tests/ui/into_iter_on_ref.rs +++ b/tests/ui/into_iter_on_ref.rs @@ -1,5 +1,5 @@ // run-rustfix -#![allow(clippy::useless_vec)] +#![allow(clippy::useless_vec, clippy::needless_borrow)] #![warn(clippy::into_iter_on_ref)] struct X; diff --git a/tests/ui/ref_option_ref.rs b/tests/ui/ref_option_ref.rs index b2c275d68af..2df45c927d7 100644 --- a/tests/ui/ref_option_ref.rs +++ b/tests/ui/ref_option_ref.rs @@ -9,7 +9,7 @@ static THRESHOLD: i32 = 10; static REF_THRESHOLD: &Option<&i32> = &Some(&THRESHOLD); const CONST_THRESHOLD: &i32 = &10; -const REF_CONST: &Option<&i32> = &Some(&CONST_THRESHOLD); +const REF_CONST: &Option<&i32> = &Some(CONST_THRESHOLD); type RefOptRefU32<'a> = &'a Option<&'a u32>; type RefOptRef<'a, T> = &'a Option<&'a T>; diff --git a/tests/ui/ref_option_ref.stderr b/tests/ui/ref_option_ref.stderr index 4e7fc800061..b61334758e8 100644 --- a/tests/ui/ref_option_ref.stderr +++ b/tests/ui/ref_option_ref.stderr @@ -9,7 +9,7 @@ LL | static REF_THRESHOLD: &Option<&i32> = &Some(&THRESHOLD); error: since `&` implements the `Copy` trait, `&Option<&T>` can be simplified to `Option<&T>` --> $DIR/ref_option_ref.rs:12:18 | -LL | const REF_CONST: &Option<&i32> = &Some(&CONST_THRESHOLD); +LL | const REF_CONST: &Option<&i32> = &Some(CONST_THRESHOLD); | ^^^^^^^^^^^^^ help: try: `Option<&i32>` error: since `&` implements the `Copy` trait, `&Option<&T>` can be simplified to `Option<&T>` diff --git a/tests/ui/stable_sort_primitive.fixed b/tests/ui/stable_sort_primitive.fixed index 8f8f5665931..f5f18169df2 100644 --- a/tests/ui/stable_sort_primitive.fixed +++ b/tests/ui/stable_sort_primitive.fixed @@ -20,7 +20,7 @@ fn main() { // Negative examples: behavior changes if made unstable let mut vec = vec![1, 3, 2]; vec.sort_by_key(|i| i / 2); - vec.sort_by(|a, b| (a + b).cmp(&b)); + vec.sort_by(|&a, &b| (a + b).cmp(&b)); // negative examples - Not of a primitive type let mut vec_of_complex = vec![String::from("hello"), String::from("world!")]; vec_of_complex.sort(); diff --git a/tests/ui/stable_sort_primitive.rs b/tests/ui/stable_sort_primitive.rs index f9bd9779067..8149c5638e0 100644 --- a/tests/ui/stable_sort_primitive.rs +++ b/tests/ui/stable_sort_primitive.rs @@ -20,7 +20,7 @@ fn main() { // Negative examples: behavior changes if made unstable let mut vec = vec![1, 3, 2]; vec.sort_by_key(|i| i / 2); - vec.sort_by(|a, b| (a + b).cmp(&b)); + vec.sort_by(|&a, &b| (a + b).cmp(&b)); // negative examples - Not of a primitive type let mut vec_of_complex = vec![String::from("hello"), String::from("world!")]; vec_of_complex.sort(); -- cgit 1.4.1-3-g733a5 From ff452d5ba68e4d8b8d8c3b2977f0c8635c6380e9 Mon Sep 17 00:00:00 2001 From: flip1995 Date: Tue, 18 May 2021 11:01:00 +0200 Subject: Deny warning in every main sub-crate This enables the same warnings that are enabled in `clippy_lints` also in `clippy_utils` and `clippy_dev`. Then it makes sure, that the `deny-warnings` feature is passed down to `clippy_lints` and `clippy_utils` when compiling Clippy. --- Cargo.toml | 2 +- clippy_dev/src/lib.rs | 4 +++- clippy_dev/src/main.rs | 2 ++ clippy_lints/Cargo.toml | 2 +- clippy_utils/Cargo.toml | 1 + clippy_utils/src/lib.rs | 7 +++++++ 6 files changed, 15 insertions(+), 3 deletions(-) (limited to 'clippy_dev/src') diff --git a/Cargo.toml b/Cargo.toml index f010e609604..848476a9d05 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -49,7 +49,7 @@ rustc-workspace-hack = "1.0.0" rustc_tools_util = { version = "0.2.0", path = "rustc_tools_util" } [features] -deny-warnings = [] +deny-warnings = ["clippy_lints/deny-warnings"] integration = ["tempfile"] internal-lints = ["clippy_lints/internal-lints"] metadata-collector-lint = ["internal-lints", "clippy_lints/metadata-collector-lint"] diff --git a/clippy_dev/src/lib.rs b/clippy_dev/src/lib.rs index 1e5a140e964..69f42aca8b6 100644 --- a/clippy_dev/src/lib.rs +++ b/clippy_dev/src/lib.rs @@ -1,5 +1,7 @@ -#![cfg_attr(feature = "deny-warnings", deny(warnings))] #![feature(once_cell)] +#![cfg_attr(feature = "deny-warnings", deny(warnings))] +// warn on lints, that are included in `rust-lang/rust`s bootstrap +#![warn(rust_2018_idioms, unused_lifetimes)] use itertools::Itertools; use regex::Regex; diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index f4da783502c..7040c257c83 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -1,4 +1,6 @@ #![cfg_attr(feature = "deny-warnings", deny(warnings))] +// warn on lints, that are included in `rust-lang/rust`s bootstrap +#![warn(rust_2018_idioms, unused_lifetimes)] use clap::{App, Arg, ArgMatches, SubCommand}; use clippy_dev::{bless, fmt, ide_setup, new_lint, serve, stderr_length_check, update_lints}; diff --git a/clippy_lints/Cargo.toml b/clippy_lints/Cargo.toml index 7ceb1da6a6e..48f2972ec58 100644 --- a/clippy_lints/Cargo.toml +++ b/clippy_lints/Cargo.toml @@ -30,7 +30,7 @@ rustc-semver = "1.1.0" url = { version = "2.1.0", features = ["serde"] } [features] -deny-warnings = [] +deny-warnings = ["clippy_utils/deny-warnings"] # build clippy with internal lints enabled, off by default internal-lints = ["clippy_utils/internal-lints"] metadata-collector-lint = ["serde_json", "clippy_utils/metadata-collector-lint"] diff --git a/clippy_utils/Cargo.toml b/clippy_utils/Cargo.toml index 0a1d4e11142..93ed3b18400 100644 --- a/clippy_utils/Cargo.toml +++ b/clippy_utils/Cargo.toml @@ -14,6 +14,7 @@ unicode-normalization = "0.1" rustc-semver="1.1.0" [features] +deny-warnings = [] internal-lints = [] metadata-collector-lint = [] diff --git a/clippy_utils/src/lib.rs b/clippy_utils/src/lib.rs index 371fe23bedc..886dde4b977 100644 --- a/clippy_utils/src/lib.rs +++ b/clippy_utils/src/lib.rs @@ -3,7 +3,14 @@ #![feature(iter_zip)] #![feature(rustc_private)] #![recursion_limit = "512"] +#![cfg_attr(feature = "deny-warnings", deny(warnings))] #![allow(clippy::missing_errors_doc, clippy::missing_panics_doc, clippy::must_use_candidate)] +// warn on the same lints as `clippy_lints` +#![warn(trivial_casts, trivial_numeric_casts)] +// warn on lints, that are included in `rust-lang/rust`s bootstrap +#![warn(rust_2018_idioms, unused_lifetimes)] +// warn on rustc internal lints +#![warn(rustc::internal)] // FIXME: switch to something more ergonomic here, once available. // (Currently there is no way to opt into sysroot crates without `extern crate`.) -- cgit 1.4.1-3-g733a5 From 206bb08d10a7c4813f8bc087bc26c6dc0e8eacff Mon Sep 17 00:00:00 2001 From: Cameron Steffen Date: Mon, 21 Jun 2021 10:50:36 -0500 Subject: Remove rustfmt workaround --- clippy_dev/src/fmt.rs | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/fmt.rs b/clippy_dev/src/fmt.rs index 1517cdc9419..edc8e6a629c 100644 --- a/clippy_dev/src/fmt.rs +++ b/clippy_dev/src/fmt.rs @@ -60,11 +60,7 @@ pub fn run(check: bool, verbose: bool) { let entry = entry?; let path = entry.path(); - if path.extension() != Some("rs".as_ref()) - || entry.file_name() == "ice-3891.rs" - // Avoid rustfmt bug rust-lang/rustfmt#1873 - || cfg!(windows) && entry.file_name() == "implicit_hasher.rs" - { + if path.extension() != Some("rs".as_ref()) || entry.file_name() == "ice-3891.rs" { continue; } -- cgit 1.4.1-3-g733a5 From 0941d9f14d9c446f9d7a465485652a3dc131de1e Mon Sep 17 00:00:00 2001 From: xFrednet Date: Thu, 10 Jun 2021 20:45:03 +0200 Subject: Moved dev `ide_setup` to `setup/intellij.rs` --- clippy_dev/src/ide_setup.rs | 103 --------------------------------------- clippy_dev/src/lib.rs | 2 +- clippy_dev/src/main.rs | 4 +- clippy_dev/src/setup/intellij.rs | 103 +++++++++++++++++++++++++++++++++++++++ clippy_dev/src/setup/mod.rs | 1 + 5 files changed, 107 insertions(+), 106 deletions(-) delete mode 100644 clippy_dev/src/ide_setup.rs create mode 100644 clippy_dev/src/setup/intellij.rs create mode 100644 clippy_dev/src/setup/mod.rs (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/ide_setup.rs b/clippy_dev/src/ide_setup.rs deleted file mode 100644 index defb1133e44..00000000000 --- a/clippy_dev/src/ide_setup.rs +++ /dev/null @@ -1,103 +0,0 @@ -use std::fs; -use std::fs::File; -use std::io::prelude::*; -use std::path::{Path, PathBuf}; - -// This module takes an absolute path to a rustc repo and alters the dependencies to point towards -// the respective rustc subcrates instead of using extern crate xyz. -// This allows rust analyzer to analyze rustc internals and show proper information inside clippy -// code. See https://github.com/rust-analyzer/rust-analyzer/issues/3517 and https://github.com/rust-lang/rust-clippy/issues/5514 for details - -/// # Panics -/// -/// Panics if `rustc_path` does not lead to a rustc repo or the files could not be read -pub fn run(rustc_path: Option<&str>) { - // we can unwrap here because the arg is required by clap - let rustc_path = PathBuf::from(rustc_path.unwrap()) - .canonicalize() - .expect("failed to get the absolute repo path"); - assert!(rustc_path.is_dir(), "path is not a directory"); - let rustc_source_basedir = rustc_path.join("compiler"); - assert!( - rustc_source_basedir.is_dir(), - "are you sure the path leads to a rustc repo?" - ); - - let clippy_root_manifest = fs::read_to_string("Cargo.toml").expect("failed to read ./Cargo.toml"); - let clippy_root_lib_rs = fs::read_to_string("src/driver.rs").expect("failed to read ./src/driver.rs"); - inject_deps_into_manifest( - &rustc_source_basedir, - "Cargo.toml", - &clippy_root_manifest, - &clippy_root_lib_rs, - ) - .expect("Failed to inject deps into ./Cargo.toml"); - - let clippy_lints_manifest = - fs::read_to_string("clippy_lints/Cargo.toml").expect("failed to read ./clippy_lints/Cargo.toml"); - let clippy_lints_lib_rs = - fs::read_to_string("clippy_lints/src/lib.rs").expect("failed to read ./clippy_lints/src/lib.rs"); - inject_deps_into_manifest( - &rustc_source_basedir, - "clippy_lints/Cargo.toml", - &clippy_lints_manifest, - &clippy_lints_lib_rs, - ) - .expect("Failed to inject deps into ./clippy_lints/Cargo.toml"); -} - -fn inject_deps_into_manifest( - rustc_source_dir: &Path, - manifest_path: &str, - cargo_toml: &str, - lib_rs: &str, -) -> std::io::Result<()> { - // do not inject deps if we have aleady done so - if cargo_toml.contains("[target.'cfg(NOT_A_PLATFORM)'.dependencies]") { - eprintln!( - "cargo dev ide_setup: warning: deps already found inside {}, doing nothing.", - manifest_path - ); - return Ok(()); - } - - let extern_crates = lib_rs - .lines() - // get the deps - .filter(|line| line.starts_with("extern crate")) - // we have something like "extern crate foo;", we only care about the "foo" - // ↓ ↓ - // extern crate rustc_middle; - .map(|s| &s[13..(s.len() - 1)]); - - let new_deps = extern_crates.map(|dep| { - // format the dependencies that are going to be put inside the Cargo.toml - format!( - "{dep} = {{ path = \"{source_path}/{dep}\" }}\n", - dep = dep, - source_path = rustc_source_dir.display() - ) - }); - - // format a new [dependencies]-block with the new deps we need to inject - let mut all_deps = String::from("[target.'cfg(NOT_A_PLATFORM)'.dependencies]\n"); - new_deps.for_each(|dep_line| { - all_deps.push_str(&dep_line); - }); - all_deps.push_str("\n[dependencies]\n"); - - // replace "[dependencies]" with - // [dependencies] - // dep1 = { path = ... } - // dep2 = { path = ... } - // etc - let new_manifest = cargo_toml.replacen("[dependencies]\n", &all_deps, 1); - - // println!("{}", new_manifest); - let mut file = File::create(manifest_path)?; - file.write_all(new_manifest.as_bytes())?; - - println!("Dependency paths injected: {}", manifest_path); - - Ok(()) -} diff --git a/clippy_dev/src/lib.rs b/clippy_dev/src/lib.rs index 69f42aca8b6..a9098695df9 100644 --- a/clippy_dev/src/lib.rs +++ b/clippy_dev/src/lib.rs @@ -14,7 +14,7 @@ use walkdir::WalkDir; pub mod bless; pub mod fmt; -pub mod ide_setup; +pub mod setup; pub mod new_lint; pub mod serve; pub mod stderr_length_check; diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index 7040c257c83..bd4c137ec6d 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -3,7 +3,7 @@ #![warn(rust_2018_idioms, unused_lifetimes)] use clap::{App, Arg, ArgMatches, SubCommand}; -use clippy_dev::{bless, fmt, ide_setup, new_lint, serve, stderr_length_check, update_lints}; +use clippy_dev::{bless, fmt, setup, new_lint, serve, stderr_length_check, update_lints}; fn main() { let matches = get_clap_config(); @@ -36,7 +36,7 @@ fn main() { ("limit_stderr_length", _) => { stderr_length_check::check(); }, - ("ide_setup", Some(matches)) => ide_setup::run(matches.value_of("rustc-repo-path")), + ("ide_setup", Some(matches)) => setup::intellij::run(matches.value_of("rustc-repo-path")), ("serve", Some(matches)) => { let port = matches.value_of("port").unwrap().parse().unwrap(); let lint = matches.value_of("lint"); diff --git a/clippy_dev/src/setup/intellij.rs b/clippy_dev/src/setup/intellij.rs new file mode 100644 index 00000000000..defb1133e44 --- /dev/null +++ b/clippy_dev/src/setup/intellij.rs @@ -0,0 +1,103 @@ +use std::fs; +use std::fs::File; +use std::io::prelude::*; +use std::path::{Path, PathBuf}; + +// This module takes an absolute path to a rustc repo and alters the dependencies to point towards +// the respective rustc subcrates instead of using extern crate xyz. +// This allows rust analyzer to analyze rustc internals and show proper information inside clippy +// code. See https://github.com/rust-analyzer/rust-analyzer/issues/3517 and https://github.com/rust-lang/rust-clippy/issues/5514 for details + +/// # Panics +/// +/// Panics if `rustc_path` does not lead to a rustc repo or the files could not be read +pub fn run(rustc_path: Option<&str>) { + // we can unwrap here because the arg is required by clap + let rustc_path = PathBuf::from(rustc_path.unwrap()) + .canonicalize() + .expect("failed to get the absolute repo path"); + assert!(rustc_path.is_dir(), "path is not a directory"); + let rustc_source_basedir = rustc_path.join("compiler"); + assert!( + rustc_source_basedir.is_dir(), + "are you sure the path leads to a rustc repo?" + ); + + let clippy_root_manifest = fs::read_to_string("Cargo.toml").expect("failed to read ./Cargo.toml"); + let clippy_root_lib_rs = fs::read_to_string("src/driver.rs").expect("failed to read ./src/driver.rs"); + inject_deps_into_manifest( + &rustc_source_basedir, + "Cargo.toml", + &clippy_root_manifest, + &clippy_root_lib_rs, + ) + .expect("Failed to inject deps into ./Cargo.toml"); + + let clippy_lints_manifest = + fs::read_to_string("clippy_lints/Cargo.toml").expect("failed to read ./clippy_lints/Cargo.toml"); + let clippy_lints_lib_rs = + fs::read_to_string("clippy_lints/src/lib.rs").expect("failed to read ./clippy_lints/src/lib.rs"); + inject_deps_into_manifest( + &rustc_source_basedir, + "clippy_lints/Cargo.toml", + &clippy_lints_manifest, + &clippy_lints_lib_rs, + ) + .expect("Failed to inject deps into ./clippy_lints/Cargo.toml"); +} + +fn inject_deps_into_manifest( + rustc_source_dir: &Path, + manifest_path: &str, + cargo_toml: &str, + lib_rs: &str, +) -> std::io::Result<()> { + // do not inject deps if we have aleady done so + if cargo_toml.contains("[target.'cfg(NOT_A_PLATFORM)'.dependencies]") { + eprintln!( + "cargo dev ide_setup: warning: deps already found inside {}, doing nothing.", + manifest_path + ); + return Ok(()); + } + + let extern_crates = lib_rs + .lines() + // get the deps + .filter(|line| line.starts_with("extern crate")) + // we have something like "extern crate foo;", we only care about the "foo" + // ↓ ↓ + // extern crate rustc_middle; + .map(|s| &s[13..(s.len() - 1)]); + + let new_deps = extern_crates.map(|dep| { + // format the dependencies that are going to be put inside the Cargo.toml + format!( + "{dep} = {{ path = \"{source_path}/{dep}\" }}\n", + dep = dep, + source_path = rustc_source_dir.display() + ) + }); + + // format a new [dependencies]-block with the new deps we need to inject + let mut all_deps = String::from("[target.'cfg(NOT_A_PLATFORM)'.dependencies]\n"); + new_deps.for_each(|dep_line| { + all_deps.push_str(&dep_line); + }); + all_deps.push_str("\n[dependencies]\n"); + + // replace "[dependencies]" with + // [dependencies] + // dep1 = { path = ... } + // dep2 = { path = ... } + // etc + let new_manifest = cargo_toml.replacen("[dependencies]\n", &all_deps, 1); + + // println!("{}", new_manifest); + let mut file = File::create(manifest_path)?; + file.write_all(new_manifest.as_bytes())?; + + println!("Dependency paths injected: {}", manifest_path); + + Ok(()) +} diff --git a/clippy_dev/src/setup/mod.rs b/clippy_dev/src/setup/mod.rs new file mode 100644 index 00000000000..cab4e386fc2 --- /dev/null +++ b/clippy_dev/src/setup/mod.rs @@ -0,0 +1 @@ +pub mod intellij; \ No newline at end of file -- cgit 1.4.1-3-g733a5 From 0a5f28c4b0c78c030956afe77b7a5c0c3e33ef5b Mon Sep 17 00:00:00 2001 From: xFrednet Date: Fri, 11 Jun 2021 01:05:51 +0200 Subject: Added `cargo dev setup git-hook` --- clippy_dev/src/lib.rs | 2 +- clippy_dev/src/main.rs | 43 ++++++++++++++++++++-------- clippy_dev/src/setup/git_hook.rs | 61 ++++++++++++++++++++++++++++++++++++++++ clippy_dev/src/setup/mod.rs | 31 +++++++++++++++++++- util/etc/pre-commit.sh | 3 ++ 5 files changed, 126 insertions(+), 14 deletions(-) create mode 100644 clippy_dev/src/setup/git_hook.rs create mode 100755 util/etc/pre-commit.sh (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lib.rs b/clippy_dev/src/lib.rs index a9098695df9..72bdaf8d592 100644 --- a/clippy_dev/src/lib.rs +++ b/clippy_dev/src/lib.rs @@ -14,9 +14,9 @@ use walkdir::WalkDir; pub mod bless; pub mod fmt; -pub mod setup; pub mod new_lint; pub mod serve; +pub mod setup; pub mod stderr_length_check; pub mod update_lints; diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index bd4c137ec6d..b20c40bc556 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -3,7 +3,7 @@ #![warn(rust_2018_idioms, unused_lifetimes)] use clap::{App, Arg, ArgMatches, SubCommand}; -use clippy_dev::{bless, fmt, setup, new_lint, serve, stderr_length_check, update_lints}; +use clippy_dev::{bless, fmt, new_lint, serve, setup, stderr_length_check, update_lints}; fn main() { let matches = get_clap_config(); @@ -36,7 +36,11 @@ fn main() { ("limit_stderr_length", _) => { stderr_length_check::check(); }, - ("ide_setup", Some(matches)) => setup::intellij::run(matches.value_of("rustc-repo-path")), + ("setup", Some(sub_command)) => match sub_command.subcommand() { + ("intellij", Some(matches)) => setup::intellij::run(matches.value_of("rustc-repo-path")), + ("git-hook", Some(matches)) => setup::git_hook::run(matches.is_present("force-override")), + _ => {}, + }, ("serve", Some(matches)) => { let port = matches.value_of("port").unwrap().parse().unwrap(); let lint = matches.value_of("lint"); @@ -140,16 +144,31 @@ fn get_clap_config<'a>() -> ArgMatches<'a> { .about("Ensures that stderr files do not grow longer than a certain amount of lines."), ) .subcommand( - SubCommand::with_name("ide_setup") - .about("Alter dependencies so Intellij Rust can find rustc internals") - .arg( - Arg::with_name("rustc-repo-path") - .long("repo-path") - .short("r") - .help("The path to a rustc repo that will be used for setting the dependencies") - .takes_value(true) - .value_name("path") - .required(true), + SubCommand::with_name("setup") + .about("Support for setting up your personal development environment") + .subcommand( + SubCommand::with_name("intellij") + .about("Alter dependencies so Intellij Rust can find rustc internals") + .arg( + Arg::with_name("rustc-repo-path") + .long("repo-path") + .short("r") + .help("The path to a rustc repo that will be used for setting the dependencies") + .takes_value(true) + .value_name("path") + .required(true), + ), + ) + .subcommand( + SubCommand::with_name("git-hook") + .about("Add a pre-commit git hook that formats your code to make it look pretty") + .arg( + Arg::with_name("force-override") + .long("force-override") + .short("f") + .help("Forces the override of an existing git pre-commit hook") + .required(false), + ), ), ) .subcommand( diff --git a/clippy_dev/src/setup/git_hook.rs b/clippy_dev/src/setup/git_hook.rs new file mode 100644 index 00000000000..741738e37fb --- /dev/null +++ b/clippy_dev/src/setup/git_hook.rs @@ -0,0 +1,61 @@ +use std::fs; +use std::path::Path; + +/// Rusts setup uses `git rev-parse --git-common-dir` to get the root directory of the repo. +/// I've decided against this for the sake of simplicity and to make sure that it doesn't install +/// the hook if `clippy_dev` would be used in the rust tree. The hook also references this tool +/// for formatting and should therefor only be used in a normal clone of clippy +const REPO_GIT_DIR: &str = ".git"; +const HOOK_SOURCE_PATH: &str = "util/etc/pre-commit.sh"; +const HOOK_TARGET_PATH: &str = ".git/hooks/pre-commit"; + +pub fn run(force_override: bool) { + if let Err(_) = check_precondition(force_override) { + return; + } + + // So a little bit of a funny story. Git on unix requires the pre-commit file + // to have the `execute` permission to be set. The Rust functions for modifying + // these flags doesn't seem to work when executed with normal user permissions. + // + // However, there is a little hack that is also being used by Rust itself in their + // setup script. Git saves the `execute` flag when syncing files. This means + // that we can check in a file with execution permissions and the sync it to create + // a file with the flag set. We then copy this file here. The copy function will also + // include the `execute` permission. + match fs::copy(HOOK_SOURCE_PATH, HOOK_TARGET_PATH) { + Ok(_) => println!("Git hook successfully installed :)"), + Err(err) => println!( + "error: unable to copy `{}` to `{}` ({})", + HOOK_SOURCE_PATH, HOOK_TARGET_PATH, err + ), + } +} + +fn check_precondition(force_override: bool) -> Result<(), ()> { + // Make sure that we can find the git repository + let git_path = Path::new(REPO_GIT_DIR); + if !git_path.exists() || !git_path.is_dir() { + println!("error: clippy_dev was unable to find the `.git` directory"); + return Err(()); + } + + // Make sure that we don't override an existing hook by accident + let path = Path::new(HOOK_TARGET_PATH); + if path.exists() { + if !force_override { + println!("warn: The found `.git` directory already has a commit hook"); + } + + if force_override || super::ask_yes_no_question("Do you want to override it?") { + if fs::remove_file(path).is_err() { + println!("error: unable to delete existing pre-commit git hook"); + return Err(()); + } + } else { + return Err(()); + } + } + + Ok(()) +} diff --git a/clippy_dev/src/setup/mod.rs b/clippy_dev/src/setup/mod.rs index cab4e386fc2..5db545c0ff1 100644 --- a/clippy_dev/src/setup/mod.rs +++ b/clippy_dev/src/setup/mod.rs @@ -1 +1,30 @@ -pub mod intellij; \ No newline at end of file +use std::io::{self, Write}; +pub mod git_hook; +pub mod intellij; + +/// This function will asked the user the given question and wait for user input +/// either `true` for yes and `false` for no. +fn ask_yes_no_question(question: &str) -> bool { + // This code was proudly stolen from rusts bootstrapping tool. + + fn ask_with_result(question: &str) -> io::Result { + let mut input = String::new(); + Ok(loop { + print!("{}: [y/N] ", question); + io::stdout().flush()?; + input.clear(); + io::stdin().read_line(&mut input)?; + break match input.trim().to_lowercase().as_str() { + "y" | "yes" => true, + "n" | "no" | "" => false, + _ => { + println!("error: unrecognized option '{}'", input.trim()); + println!("note: press Ctrl+C to exit"); + continue; + }, + }; + }) + } + + ask_with_result(question).unwrap_or_default() +} diff --git a/util/etc/pre-commit.sh b/util/etc/pre-commit.sh new file mode 100755 index 00000000000..3c76e924b34 --- /dev/null +++ b/util/etc/pre-commit.sh @@ -0,0 +1,3 @@ +#!/bin/sh + +cargo dev fmt -- cgit 1.4.1-3-g733a5 From 3d0984975e555e122499e58d3fbc20e99b7be589 Mon Sep 17 00:00:00 2001 From: xFrednet Date: Wed, 16 Jun 2021 00:21:13 +0200 Subject: Print cargo dev help on missing arg and updated setup documentation --- CONTRIBUTING.md | 2 +- clippy_dev/src/fmt.rs | 2 +- clippy_dev/src/main.rs | 4 +++- clippy_dev/src/setup/intellij.rs | 2 +- doc/basics.md | 4 +++- 5 files changed, 9 insertions(+), 5 deletions(-) (limited to 'clippy_dev/src') diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 7265d1b8323..b202fc4f281 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -115,7 +115,7 @@ To work around this, you need to have a copy of the [rustc-repo][rustc_repo] ava `git clone https://github.com/rust-lang/rust/`. Then you can run a `cargo dev` command to automatically make Clippy use the rustc-repo via path-dependencies which `IntelliJ Rust` will be able to understand. -Run `cargo dev ide_setup --repo-path ` where `` is a path to the rustc repo +Run `cargo dev setup intellij --repo-path ` where `` is a path to the rustc repo you just cloned. The command will add path-dependencies pointing towards rustc-crates inside the rustc repo to Clippys `Cargo.toml`s and should allow `IntelliJ Rust` to understand most of the types that Clippy uses. diff --git a/clippy_dev/src/fmt.rs b/clippy_dev/src/fmt.rs index edc8e6a629c..c81eb40d52f 100644 --- a/clippy_dev/src/fmt.rs +++ b/clippy_dev/src/fmt.rs @@ -86,7 +86,7 @@ pub fn run(check: bool, verbose: bool) { }, CliError::RaSetupActive => { eprintln!( - "error: a local rustc repo is enabled as path dependency via `cargo dev ide_setup`. + "error: a local rustc repo is enabled as path dependency via `cargo dev setup intellij`. Not formatting because that would format the local repo as well! Please revert the changes to Cargo.tomls first." ); diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index b20c40bc556..faf8700f55a 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -2,7 +2,7 @@ // warn on lints, that are included in `rust-lang/rust`s bootstrap #![warn(rust_2018_idioms, unused_lifetimes)] -use clap::{App, Arg, ArgMatches, SubCommand}; +use clap::{App, AppSettings, Arg, ArgMatches, SubCommand}; use clippy_dev::{bless, fmt, new_lint, serve, setup, stderr_length_check, update_lints}; fn main() { let matches = get_clap_config(); @@ -52,6 +52,7 @@ fn main() { fn get_clap_config<'a>() -> ArgMatches<'a> { App::new("Clippy developer tooling") + .setting(AppSettings::ArgRequiredElseHelp) .subcommand( SubCommand::with_name("bless") .about("bless the test output changes") @@ -146,6 +147,7 @@ fn get_clap_config<'a>() -> ArgMatches<'a> { .subcommand( SubCommand::with_name("setup") .about("Support for setting up your personal development environment") + .setting(AppSettings::ArgRequiredElseHelp) .subcommand( SubCommand::with_name("intellij") .about("Alter dependencies so Intellij Rust can find rustc internals") diff --git a/clippy_dev/src/setup/intellij.rs b/clippy_dev/src/setup/intellij.rs index defb1133e44..9b084f52466 100644 --- a/clippy_dev/src/setup/intellij.rs +++ b/clippy_dev/src/setup/intellij.rs @@ -55,7 +55,7 @@ fn inject_deps_into_manifest( // do not inject deps if we have aleady done so if cargo_toml.contains("[target.'cfg(NOT_A_PLATFORM)'.dependencies]") { eprintln!( - "cargo dev ide_setup: warning: deps already found inside {}, doing nothing.", + "cargo dev setup intellij: warning: deps already found inside {}, doing nothing.", manifest_path ); return Ok(()); diff --git a/doc/basics.md b/doc/basics.md index e2e307ce4f6..89d572ad931 100644 --- a/doc/basics.md +++ b/doc/basics.md @@ -90,8 +90,10 @@ cargo dev fmt cargo dev update_lints # create a new lint and register it cargo dev new_lint +# automatically formatting all code before each commit +cargo dev setup git-hook # (experimental) Setup Clippy to work with IntelliJ-Rust -cargo dev ide_setup +cargo dev setup intellij ``` ## lintcheck -- cgit 1.4.1-3-g733a5 From b48f041befdca6ad14acfda2db68c280ee3fbc85 Mon Sep 17 00:00:00 2001 From: xFrednet Date: Wed, 16 Jun 2021 18:59:28 +0200 Subject: Added the `cargo dev remove` command for convenience --- clippy_dev/src/main.rs | 13 +++++++++- clippy_dev/src/setup/git_hook.rs | 51 ++++++++++++++++++++++++++-------------- 2 files changed, 45 insertions(+), 19 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index faf8700f55a..70c3d93ed47 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -38,9 +38,14 @@ fn main() { }, ("setup", Some(sub_command)) => match sub_command.subcommand() { ("intellij", Some(matches)) => setup::intellij::run(matches.value_of("rustc-repo-path")), - ("git-hook", Some(matches)) => setup::git_hook::run(matches.is_present("force-override")), + ("git-hook", Some(matches)) => setup::git_hook::install_hook(matches.is_present("force-override")), _ => {}, }, + ("remove", Some(sub_command)) => { + if let ("git-hook", Some(_)) = sub_command.subcommand() { + setup::git_hook::remove_hook(); + } + }, ("serve", Some(matches)) => { let port = matches.value_of("port").unwrap().parse().unwrap(); let lint = matches.value_of("lint"); @@ -173,6 +178,12 @@ fn get_clap_config<'a>() -> ArgMatches<'a> { ), ), ) + .subcommand( + SubCommand::with_name("remove") + .about("Support for undoing changes done by the setup command") + .setting(AppSettings::ArgRequiredElseHelp) + .subcommand(SubCommand::with_name("git-hook").about("Remove any existing pre-commit git hook")), + ) .subcommand( SubCommand::with_name("serve") .about("Launch a local 'ALL the Clippy Lints' website in a browser") diff --git a/clippy_dev/src/setup/git_hook.rs b/clippy_dev/src/setup/git_hook.rs index 741738e37fb..beb07a073fe 100644 --- a/clippy_dev/src/setup/git_hook.rs +++ b/clippy_dev/src/setup/git_hook.rs @@ -6,11 +6,11 @@ use std::path::Path; /// the hook if `clippy_dev` would be used in the rust tree. The hook also references this tool /// for formatting and should therefor only be used in a normal clone of clippy const REPO_GIT_DIR: &str = ".git"; -const HOOK_SOURCE_PATH: &str = "util/etc/pre-commit.sh"; -const HOOK_TARGET_PATH: &str = ".git/hooks/pre-commit"; +const HOOK_SOURCE_FILE: &str = "util/etc/pre-commit.sh"; +const HOOK_TARGET_FILE: &str = ".git/hooks/pre-commit"; -pub fn run(force_override: bool) { - if let Err(_) = check_precondition(force_override) { +pub fn install_hook(force_override: bool) { + if check_precondition(force_override).is_err() { return; } @@ -23,11 +23,14 @@ pub fn run(force_override: bool) { // that we can check in a file with execution permissions and the sync it to create // a file with the flag set. We then copy this file here. The copy function will also // include the `execute` permission. - match fs::copy(HOOK_SOURCE_PATH, HOOK_TARGET_PATH) { - Ok(_) => println!("Git hook successfully installed :)"), + match fs::copy(HOOK_SOURCE_FILE, HOOK_TARGET_FILE) { + Ok(_) => { + println!("note: the hook can be removed with `cargo dev remove git-hook`"); + println!("Git hook successfully installed :)"); + }, Err(err) => println!( "error: unable to copy `{}` to `{}` ({})", - HOOK_SOURCE_PATH, HOOK_TARGET_PATH, err + HOOK_SOURCE_FILE, HOOK_TARGET_FILE, err ), } } @@ -41,21 +44,33 @@ fn check_precondition(force_override: bool) -> Result<(), ()> { } // Make sure that we don't override an existing hook by accident - let path = Path::new(HOOK_TARGET_PATH); + let path = Path::new(HOOK_TARGET_FILE); if path.exists() { - if !force_override { - println!("warn: The found `.git` directory already has a commit hook"); + if force_override || super::ask_yes_no_question("Do you want to override the existing pre-commit hook it?") { + return delete_git_hook_file(path); } + return Err(()); + } + + Ok(()) +} - if force_override || super::ask_yes_no_question("Do you want to override it?") { - if fs::remove_file(path).is_err() { - println!("error: unable to delete existing pre-commit git hook"); - return Err(()); - } - } else { - return Err(()); +pub fn remove_hook() { + let path = Path::new(HOOK_TARGET_FILE); + if path.exists() { + if delete_git_hook_file(path).is_ok() { + println!("Git hook successfully removed :)"); } + } else { + println!("No pre-commit hook was found. You're good to go :)"); } +} - Ok(()) +fn delete_git_hook_file(path: &Path) -> Result<(), ()> { + if fs::remove_file(path).is_err() { + println!("error: unable to delete existing pre-commit git hook"); + Err(()) + } else { + Ok(()) + } } -- cgit 1.4.1-3-g733a5 From 8fdf2897da4ba476018090f3fb8f637a0de00c73 Mon Sep 17 00:00:00 2001 From: xFrednet Date: Tue, 22 Jun 2021 00:25:10 +0200 Subject: Updated `cargo dev setup intellij` for cleaner user messages --- clippy_dev/src/main.rs | 6 +- clippy_dev/src/setup/intellij.rs | 147 +++++++++++++++++++++++++++++---------- 2 files changed, 114 insertions(+), 39 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index 70c3d93ed47..8b5c499cd5e 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -37,7 +37,11 @@ fn main() { stderr_length_check::check(); }, ("setup", Some(sub_command)) => match sub_command.subcommand() { - ("intellij", Some(matches)) => setup::intellij::run(matches.value_of("rustc-repo-path")), + ("intellij", Some(matches)) => setup::intellij::setup_rustc_src( + matches + .value_of("rustc-repo-path") + .expect("this field is mandatory and therefore always valid"), + ), ("git-hook", Some(matches)) => setup::git_hook::install_hook(matches.is_present("force-override")), _ => {}, }, diff --git a/clippy_dev/src/setup/intellij.rs b/clippy_dev/src/setup/intellij.rs index 9b084f52466..3685e1b6def 100644 --- a/clippy_dev/src/setup/intellij.rs +++ b/clippy_dev/src/setup/intellij.rs @@ -8,42 +8,113 @@ use std::path::{Path, PathBuf}; // This allows rust analyzer to analyze rustc internals and show proper information inside clippy // code. See https://github.com/rust-analyzer/rust-analyzer/issues/3517 and https://github.com/rust-lang/rust-clippy/issues/5514 for details -/// # Panics -/// -/// Panics if `rustc_path` does not lead to a rustc repo or the files could not be read -pub fn run(rustc_path: Option<&str>) { - // we can unwrap here because the arg is required by clap - let rustc_path = PathBuf::from(rustc_path.unwrap()) - .canonicalize() - .expect("failed to get the absolute repo path"); - assert!(rustc_path.is_dir(), "path is not a directory"); - let rustc_source_basedir = rustc_path.join("compiler"); - assert!( - rustc_source_basedir.is_dir(), - "are you sure the path leads to a rustc repo?" - ); - - let clippy_root_manifest = fs::read_to_string("Cargo.toml").expect("failed to read ./Cargo.toml"); - let clippy_root_lib_rs = fs::read_to_string("src/driver.rs").expect("failed to read ./src/driver.rs"); - inject_deps_into_manifest( - &rustc_source_basedir, - "Cargo.toml", - &clippy_root_manifest, - &clippy_root_lib_rs, - ) - .expect("Failed to inject deps into ./Cargo.toml"); - - let clippy_lints_manifest = - fs::read_to_string("clippy_lints/Cargo.toml").expect("failed to read ./clippy_lints/Cargo.toml"); - let clippy_lints_lib_rs = - fs::read_to_string("clippy_lints/src/lib.rs").expect("failed to read ./clippy_lints/src/lib.rs"); - inject_deps_into_manifest( - &rustc_source_basedir, - "clippy_lints/Cargo.toml", - &clippy_lints_manifest, - &clippy_lints_lib_rs, - ) - .expect("Failed to inject deps into ./clippy_lints/Cargo.toml"); +const CLIPPY_PROJECTS: &[ClippyProjectInfo] = &[ + ClippyProjectInfo::new("root", "Cargo.toml", "src/driver.rs"), + ClippyProjectInfo::new("clippy_lints", "clippy_lints/Cargo.toml", "clippy_lints/src/lib.rs"), + ClippyProjectInfo::new("clippy_utils", "clippy_utils/Cargo.toml", "clippy_utils/src/lib.rs"), +]; + +/// Used to store clippy project information to later inject the dependency into. +struct ClippyProjectInfo { + /// Only used to display information to the user + name: &'static str, + cargo_file: &'static str, + lib_rs_file: &'static str, +} + +impl ClippyProjectInfo { + const fn new(name: &'static str, cargo_file: &'static str, lib_rs_file: &'static str) -> Self { + Self { + name, + cargo_file, + lib_rs_file, + } + } +} + +pub fn setup_rustc_src(rustc_path: &str) { + let rustc_source_dir = match check_and_get_rustc_dir(rustc_path) { + Ok(path) => path, + Err(_) => return, + }; + + for project in CLIPPY_PROJECTS { + if inject_deps_into_project(&rustc_source_dir, project).is_err() { + return; + } + } +} + +fn check_and_get_rustc_dir(rustc_path: &str) -> Result { + let mut path = PathBuf::from(rustc_path); + + if path.is_relative() { + match path.canonicalize() { + Ok(absolute_path) => { + println!("note: the rustc path was resolved to: `{}`", absolute_path.display()); + path = absolute_path; + }, + Err(err) => { + println!("error: unable to get the absolute path of rustc ({})", err); + return Err(()); + }, + }; + } + + let path = path.join("compiler"); + println!("note: looking for compiler sources at: {}", path.display()); + + if !path.exists() { + println!("error: the given path does not exist"); + return Err(()); + } + + if !path.is_dir() { + println!("error: the given path is a file and not a directory"); + return Err(()); + } + + Ok(path) +} + +fn inject_deps_into_project(rustc_source_dir: &Path, project: &ClippyProjectInfo) -> Result<(), ()> { + let cargo_content = read_project_file(project.cargo_file, "Cargo.toml", project.name)?; + let lib_content = read_project_file(project.lib_rs_file, "lib.rs", project.name)?; + + if inject_deps_into_manifest(rustc_source_dir, project.cargo_file, &cargo_content, &lib_content).is_err() { + println!( + "error: unable to inject dependencies into {} with the Cargo file {}", + project.name, project.cargo_file + ); + Err(()) + } else { + Ok(()) + } +} + +/// `clippy_dev` expects to be executed in the root directory of Clippy. This function +/// loads the given file or returns an error. Having it in this extra function ensures +/// that the error message looks nice. +fn read_project_file(file_path: &str, file_name: &str, project: &str) -> Result { + let path = Path::new(file_path); + if !path.exists() { + println!( + "error: unable to find the `{}` file for the project {}", + file_name, project + ); + return Err(()); + } + + match fs::read_to_string(path) { + Ok(content) => Ok(content), + Err(err) => { + println!( + "error: the `{}` file for the project {} could not be read ({})", + file_name, project, err + ); + Err(()) + }, + } } fn inject_deps_into_manifest( @@ -55,7 +126,7 @@ fn inject_deps_into_manifest( // do not inject deps if we have aleady done so if cargo_toml.contains("[target.'cfg(NOT_A_PLATFORM)'.dependencies]") { eprintln!( - "cargo dev setup intellij: warning: deps already found inside {}, doing nothing.", + "warn: dependencies are already setup inside {}, skipping file.", manifest_path ); return Ok(()); @@ -97,7 +168,7 @@ fn inject_deps_into_manifest( let mut file = File::create(manifest_path)?; file.write_all(new_manifest.as_bytes())?; - println!("Dependency paths injected: {}", manifest_path); + println!("note: successfully setup dependencies inside {}", manifest_path); Ok(()) } -- cgit 1.4.1-3-g733a5 From f0fa3636536f3843fee2315fc062aa022479fdee Mon Sep 17 00:00:00 2001 From: xFrednet Date: Tue, 22 Jun 2021 20:13:05 +0200 Subject: Added `cargo dev remove intellij` --- clippy_dev/src/main.rs | 14 ++++--- clippy_dev/src/setup/intellij.rs | 80 +++++++++++++++++++++++++++++++++------- 2 files changed, 76 insertions(+), 18 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index 8b5c499cd5e..f5bd08657ea 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -45,10 +45,10 @@ fn main() { ("git-hook", Some(matches)) => setup::git_hook::install_hook(matches.is_present("force-override")), _ => {}, }, - ("remove", Some(sub_command)) => { - if let ("git-hook", Some(_)) = sub_command.subcommand() { - setup::git_hook::remove_hook(); - } + ("remove", Some(sub_command)) => match sub_command.subcommand() { + ("git-hook", Some(_)) => setup::git_hook::remove_hook(), + ("intellij", Some(_)) => setup::intellij::remove_rustc_src(), + _ => {}, }, ("serve", Some(matches)) => { let port = matches.value_of("port").unwrap().parse().unwrap(); @@ -186,7 +186,11 @@ fn get_clap_config<'a>() -> ArgMatches<'a> { SubCommand::with_name("remove") .about("Support for undoing changes done by the setup command") .setting(AppSettings::ArgRequiredElseHelp) - .subcommand(SubCommand::with_name("git-hook").about("Remove any existing pre-commit git hook")), + .subcommand(SubCommand::with_name("git-hook").about("Remove any existing pre-commit git hook")) + .subcommand( + SubCommand::with_name("intellij") + .about("Removes rustc source paths added via `cargo dev setup intellij`"), + ), ) .subcommand( SubCommand::with_name("serve") diff --git a/clippy_dev/src/setup/intellij.rs b/clippy_dev/src/setup/intellij.rs index 3685e1b6def..249804240df 100644 --- a/clippy_dev/src/setup/intellij.rs +++ b/clippy_dev/src/setup/intellij.rs @@ -8,6 +8,9 @@ use std::path::{Path, PathBuf}; // This allows rust analyzer to analyze rustc internals and show proper information inside clippy // code. See https://github.com/rust-analyzer/rust-analyzer/issues/3517 and https://github.com/rust-lang/rust-clippy/issues/5514 for details +const RUSTC_PATH_SECTION: &str = "[target.'cfg(NOT_A_PLATFORM)'.dependencies]"; +const DEPENDENCIES_SECTION: &str = "[dependencies]"; + const CLIPPY_PROJECTS: &[ClippyProjectInfo] = &[ ClippyProjectInfo::new("root", "Cargo.toml", "src/driver.rs"), ClippyProjectInfo::new("clippy_lints", "clippy_lints/Cargo.toml", "clippy_lints/src/lib.rs"), @@ -43,6 +46,8 @@ pub fn setup_rustc_src(rustc_path: &str) { return; } } + + println!("info: the source paths can be removed again with `cargo dev remove intellij`"); } fn check_and_get_rustc_dir(rustc_path: &str) -> Result { @@ -51,26 +56,26 @@ fn check_and_get_rustc_dir(rustc_path: &str) -> Result { if path.is_relative() { match path.canonicalize() { Ok(absolute_path) => { - println!("note: the rustc path was resolved to: `{}`", absolute_path.display()); + println!("info: the rustc path was resolved to: `{}`", absolute_path.display()); path = absolute_path; }, Err(err) => { - println!("error: unable to get the absolute path of rustc ({})", err); + eprintln!("error: unable to get the absolute path of rustc ({})", err); return Err(()); }, }; } let path = path.join("compiler"); - println!("note: looking for compiler sources at: {}", path.display()); + println!("info: looking for compiler sources at: {}", path.display()); if !path.exists() { - println!("error: the given path does not exist"); + eprintln!("error: the given path does not exist"); return Err(()); } if !path.is_dir() { - println!("error: the given path is a file and not a directory"); + eprintln!("error: the given path is a file and not a directory"); return Err(()); } @@ -82,7 +87,7 @@ fn inject_deps_into_project(rustc_source_dir: &Path, project: &ClippyProjectInfo let lib_content = read_project_file(project.lib_rs_file, "lib.rs", project.name)?; if inject_deps_into_manifest(rustc_source_dir, project.cargo_file, &cargo_content, &lib_content).is_err() { - println!( + eprintln!( "error: unable to inject dependencies into {} with the Cargo file {}", project.name, project.cargo_file ); @@ -98,7 +103,7 @@ fn inject_deps_into_project(rustc_source_dir: &Path, project: &ClippyProjectInfo fn read_project_file(file_path: &str, file_name: &str, project: &str) -> Result { let path = Path::new(file_path); if !path.exists() { - println!( + eprintln!( "error: unable to find the `{}` file for the project {}", file_name, project ); @@ -123,10 +128,10 @@ fn inject_deps_into_manifest( cargo_toml: &str, lib_rs: &str, ) -> std::io::Result<()> { - // do not inject deps if we have aleady done so - if cargo_toml.contains("[target.'cfg(NOT_A_PLATFORM)'.dependencies]") { + // do not inject deps if we have already done so + if cargo_toml.contains(RUSTC_PATH_SECTION) { eprintln!( - "warn: dependencies are already setup inside {}, skipping file.", + "warn: dependencies are already setup inside {}, skipping file", manifest_path ); return Ok(()); @@ -134,8 +139,8 @@ fn inject_deps_into_manifest( let extern_crates = lib_rs .lines() - // get the deps - .filter(|line| line.starts_with("extern crate")) + // only take dependencies starting with `rustc_` + .filter(|line| line.starts_with("extern crate rustc_")) // we have something like "extern crate foo;", we only care about the "foo" // ↓ ↓ // extern crate rustc_middle; @@ -168,7 +173,56 @@ fn inject_deps_into_manifest( let mut file = File::create(manifest_path)?; file.write_all(new_manifest.as_bytes())?; - println!("note: successfully setup dependencies inside {}", manifest_path); + println!("info: successfully setup dependencies inside {}", manifest_path); Ok(()) } + +pub fn remove_rustc_src() { + for project in CLIPPY_PROJECTS { + // We don't care about the result here as we want to go through all + // dependencies either way. Any info and error message will be issued by + // the removal code itself. + let _ = remove_rustc_src_from_project(project); + } +} + +fn remove_rustc_src_from_project(project: &ClippyProjectInfo) -> Result<(), ()> { + let mut cargo_content = read_project_file(project.cargo_file, "Cargo.toml", project.name)?; + let section_start = if let Some(section_start) = cargo_content.find(RUSTC_PATH_SECTION) { + section_start + } else { + println!( + "info: dependencies could not be found in `{}` for {}, skipping file", + project.cargo_file, project.name + ); + return Ok(()); + }; + + let end_point = if let Some(end_point) = cargo_content.find(DEPENDENCIES_SECTION) { + end_point + } else { + eprintln!( + "error: the end of the rustc dependencies section could not be found in `{}`", + project.cargo_file + ); + return Err(()); + }; + + cargo_content.replace_range(section_start..end_point, ""); + + match File::create(project.cargo_file) { + Ok(mut file) => { + file.write_all(cargo_content.as_bytes()).unwrap(); + println!("info: successfully removed dependencies inside {}", project.cargo_file); + Ok(()) + }, + Err(err) => { + eprintln!( + "error: unable to open file `{}` to remove rustc dependencies for {} ({})", + project.cargo_file, project.name, err + ); + Err(()) + }, + } +} -- cgit 1.4.1-3-g733a5 From 8e969cdcefefe6792537dac11855bc5f91904f0b Mon Sep 17 00:00:00 2001 From: xFrednet Date: Wed, 23 Jun 2021 19:04:09 +0200 Subject: Updated several clippy_dev messages and types (PR suggestions) Co-authored-by: Philipp Krones --- clippy_dev/src/setup/git_hook.rs | 39 ++++++++++++++++++---------------- clippy_dev/src/setup/intellij.rs | 45 ++++++++++++++++++---------------------- clippy_dev/src/setup/mod.rs | 28 ------------------------- 3 files changed, 41 insertions(+), 71 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/setup/git_hook.rs b/clippy_dev/src/setup/git_hook.rs index beb07a073fe..f27b69a195b 100644 --- a/clippy_dev/src/setup/git_hook.rs +++ b/clippy_dev/src/setup/git_hook.rs @@ -10,7 +10,7 @@ const HOOK_SOURCE_FILE: &str = "util/etc/pre-commit.sh"; const HOOK_TARGET_FILE: &str = ".git/hooks/pre-commit"; pub fn install_hook(force_override: bool) { - if check_precondition(force_override).is_err() { + if !check_precondition(force_override) { return; } @@ -25,52 +25,55 @@ pub fn install_hook(force_override: bool) { // include the `execute` permission. match fs::copy(HOOK_SOURCE_FILE, HOOK_TARGET_FILE) { Ok(_) => { - println!("note: the hook can be removed with `cargo dev remove git-hook`"); - println!("Git hook successfully installed :)"); + println!("info: the hook can be removed with `cargo dev remove git-hook`"); + println!("git hook successfully installed"); }, - Err(err) => println!( + Err(err) => eprintln!( "error: unable to copy `{}` to `{}` ({})", HOOK_SOURCE_FILE, HOOK_TARGET_FILE, err ), } } -fn check_precondition(force_override: bool) -> Result<(), ()> { +fn check_precondition(force_override: bool) -> bool { // Make sure that we can find the git repository let git_path = Path::new(REPO_GIT_DIR); if !git_path.exists() || !git_path.is_dir() { - println!("error: clippy_dev was unable to find the `.git` directory"); - return Err(()); + eprintln!("error: clippy_dev was unable to find the `.git` directory"); + return false; } // Make sure that we don't override an existing hook by accident let path = Path::new(HOOK_TARGET_FILE); if path.exists() { - if force_override || super::ask_yes_no_question("Do you want to override the existing pre-commit hook it?") { + if force_override { return delete_git_hook_file(path); } - return Err(()); + + eprintln!("error: there is already a pre-commit hook installed"); + println!("info: use the `--force-override` flag to override the existing hook"); + return false; } - Ok(()) + true } pub fn remove_hook() { let path = Path::new(HOOK_TARGET_FILE); if path.exists() { - if delete_git_hook_file(path).is_ok() { - println!("Git hook successfully removed :)"); + if delete_git_hook_file(path) { + println!("git hook successfully removed"); } } else { - println!("No pre-commit hook was found. You're good to go :)"); + println!("no pre-commit hook was found"); } } -fn delete_git_hook_file(path: &Path) -> Result<(), ()> { - if fs::remove_file(path).is_err() { - println!("error: unable to delete existing pre-commit git hook"); - Err(()) +fn delete_git_hook_file(path: &Path) -> bool { + if let Err(err) = fs::remove_file(path) { + eprintln!("error: unable to delete existing pre-commit git hook ({})", err); + false } else { - Ok(()) + true } } diff --git a/clippy_dev/src/setup/intellij.rs b/clippy_dev/src/setup/intellij.rs index 249804240df..bf741e6d121 100644 --- a/clippy_dev/src/setup/intellij.rs +++ b/clippy_dev/src/setup/intellij.rs @@ -5,8 +5,8 @@ use std::path::{Path, PathBuf}; // This module takes an absolute path to a rustc repo and alters the dependencies to point towards // the respective rustc subcrates instead of using extern crate xyz. -// This allows rust analyzer to analyze rustc internals and show proper information inside clippy -// code. See https://github.com/rust-analyzer/rust-analyzer/issues/3517 and https://github.com/rust-lang/rust-clippy/issues/5514 for details +// This allows IntelliJ to analyze rustc internals and show proper information inside Clippy +// code. See https://github.com/rust-lang/rust-clippy/issues/5514 for details const RUSTC_PATH_SECTION: &str = "[target.'cfg(NOT_A_PLATFORM)'.dependencies]"; const DEPENDENCIES_SECTION: &str = "[dependencies]"; @@ -75,7 +75,7 @@ fn check_and_get_rustc_dir(rustc_path: &str) -> Result { } if !path.is_dir() { - eprintln!("error: the given path is a file and not a directory"); + eprintln!("error: the given path is not a directory"); return Err(()); } @@ -83,8 +83,8 @@ fn check_and_get_rustc_dir(rustc_path: &str) -> Result { } fn inject_deps_into_project(rustc_source_dir: &Path, project: &ClippyProjectInfo) -> Result<(), ()> { - let cargo_content = read_project_file(project.cargo_file, "Cargo.toml", project.name)?; - let lib_content = read_project_file(project.lib_rs_file, "lib.rs", project.name)?; + let cargo_content = read_project_file(project.cargo_file)?; + let lib_content = read_project_file(project.lib_rs_file)?; if inject_deps_into_manifest(rustc_source_dir, project.cargo_file, &cargo_content, &lib_content).is_err() { eprintln!( @@ -100,23 +100,17 @@ fn inject_deps_into_project(rustc_source_dir: &Path, project: &ClippyProjectInfo /// `clippy_dev` expects to be executed in the root directory of Clippy. This function /// loads the given file or returns an error. Having it in this extra function ensures /// that the error message looks nice. -fn read_project_file(file_path: &str, file_name: &str, project: &str) -> Result { +fn read_project_file(file_path: &str) -> Result { let path = Path::new(file_path); if !path.exists() { - eprintln!( - "error: unable to find the `{}` file for the project {}", - file_name, project - ); + eprintln!("error: unable to find the file `{}`", file_path); return Err(()); } match fs::read_to_string(path) { Ok(content) => Ok(content), Err(err) => { - println!( - "error: the `{}` file for the project {} could not be read ({})", - file_name, project, err - ); + eprintln!("error: the file `{}` could not be read ({})", file_path, err); Err(()) }, } @@ -142,8 +136,8 @@ fn inject_deps_into_manifest( // only take dependencies starting with `rustc_` .filter(|line| line.starts_with("extern crate rustc_")) // we have something like "extern crate foo;", we only care about the "foo" - // ↓ ↓ // extern crate rustc_middle; + // ^^^^^^^^^^^^ .map(|s| &s[13..(s.len() - 1)]); let new_deps = extern_crates.map(|dep| { @@ -180,15 +174,16 @@ fn inject_deps_into_manifest( pub fn remove_rustc_src() { for project in CLIPPY_PROJECTS { - // We don't care about the result here as we want to go through all - // dependencies either way. Any info and error message will be issued by - // the removal code itself. - let _ = remove_rustc_src_from_project(project); + remove_rustc_src_from_project(project); } } -fn remove_rustc_src_from_project(project: &ClippyProjectInfo) -> Result<(), ()> { - let mut cargo_content = read_project_file(project.cargo_file, "Cargo.toml", project.name)?; +fn remove_rustc_src_from_project(project: &ClippyProjectInfo) -> bool { + let mut cargo_content = if let Ok(content) = read_project_file(project.cargo_file) { + content + } else { + return false; + }; let section_start = if let Some(section_start) = cargo_content.find(RUSTC_PATH_SECTION) { section_start } else { @@ -196,7 +191,7 @@ fn remove_rustc_src_from_project(project: &ClippyProjectInfo) -> Result<(), ()> "info: dependencies could not be found in `{}` for {}, skipping file", project.cargo_file, project.name ); - return Ok(()); + return true; }; let end_point = if let Some(end_point) = cargo_content.find(DEPENDENCIES_SECTION) { @@ -206,7 +201,7 @@ fn remove_rustc_src_from_project(project: &ClippyProjectInfo) -> Result<(), ()> "error: the end of the rustc dependencies section could not be found in `{}`", project.cargo_file ); - return Err(()); + return false; }; cargo_content.replace_range(section_start..end_point, ""); @@ -215,14 +210,14 @@ fn remove_rustc_src_from_project(project: &ClippyProjectInfo) -> Result<(), ()> Ok(mut file) => { file.write_all(cargo_content.as_bytes()).unwrap(); println!("info: successfully removed dependencies inside {}", project.cargo_file); - Ok(()) + true }, Err(err) => { eprintln!( "error: unable to open file `{}` to remove rustc dependencies for {} ({})", project.cargo_file, project.name, err ); - Err(()) + false }, } } diff --git a/clippy_dev/src/setup/mod.rs b/clippy_dev/src/setup/mod.rs index 5db545c0ff1..3834f5a1842 100644 --- a/clippy_dev/src/setup/mod.rs +++ b/clippy_dev/src/setup/mod.rs @@ -1,30 +1,2 @@ -use std::io::{self, Write}; pub mod git_hook; pub mod intellij; - -/// This function will asked the user the given question and wait for user input -/// either `true` for yes and `false` for no. -fn ask_yes_no_question(question: &str) -> bool { - // This code was proudly stolen from rusts bootstrapping tool. - - fn ask_with_result(question: &str) -> io::Result { - let mut input = String::new(); - Ok(loop { - print!("{}: [y/N] ", question); - io::stdout().flush()?; - input.clear(); - io::stdin().read_line(&mut input)?; - break match input.trim().to_lowercase().as_str() { - "y" | "yes" => true, - "n" | "no" | "" => false, - _ => { - println!("error: unrecognized option '{}'", input.trim()); - println!("note: press Ctrl+C to exit"); - continue; - }, - }; - }) - } - - ask_with_result(question).unwrap_or_default() -} -- cgit 1.4.1-3-g733a5 From 7e21db5b5c18f47a5f43e36f0bf34f1bbd1a1466 Mon Sep 17 00:00:00 2001 From: Cameron Steffen Date: Mon, 14 Jun 2021 10:01:43 -0500 Subject: Add suspicious group --- README.md | 21 +++++++++++---------- clippy_dev/src/main.rs | 1 + clippy_dev/src/update_lints.rs | 5 ++++- clippy_lints/src/lib.rs | 11 ++++++++--- .../src/utils/internal_lints/metadata_collector.rs | 3 ++- util/lintlib.py | 1 + 6 files changed, 27 insertions(+), 15 deletions(-) (limited to 'clippy_dev/src') diff --git a/README.md b/README.md index 6c556f579ca..29bfebe4583 100644 --- a/README.md +++ b/README.md @@ -10,16 +10,17 @@ A collection of lints to catch common mistakes and improve your [Rust](https://g Lints are divided into categories, each with a default [lint level](https://doc.rust-lang.org/rustc/lints/levels.html). You can choose how much Clippy is supposed to ~~annoy~~ help you by changing the lint level by category. -| Category | Description | Default level | -| --------------------- | ----------------------------------------------------------------------- | ------------- | -| `clippy::all` | all lints that are on by default (correctness, style, complexity, perf) | **warn/deny** | -| `clippy::correctness` | code that is outright wrong or very useless | **deny** | -| `clippy::style` | code that should be written in a more idiomatic way | **warn** | -| `clippy::complexity` | code that does something simple but in a complex way | **warn** | -| `clippy::perf` | code that can be written to run faster | **warn** | -| `clippy::pedantic` | lints which are rather strict or might have false positives | allow | -| `clippy::nursery` | new lints that are still under development | allow | -| `clippy::cargo` | lints for the cargo manifest | allow | +| Category | Description | Default level | +| --------------------- | ----------------------------------------------------------------------------------- | ------------- | +| `clippy::all` | all lints that are on by default (correctness, suspicious, style, complexity, perf) | **warn/deny** | +| `clippy::correctness` | code that is outright wrong or useless | **deny** | +| `clippy::suspicious` | code that is most likely wrong or useless | **warn** | +| `clippy::style` | code that should be written in a more idiomatic way | **warn** | +| `clippy::complexity` | code that does something simple but in a complex way | **warn** | +| `clippy::perf` | code that can be written to run faster | **warn** | +| `clippy::pedantic` | lints which are rather strict or might have false positives | allow | +| `clippy::nursery` | new lints that are still under development | allow | +| `clippy::cargo` | lints for the cargo manifest | allow | More to come, please [file an issue](https://github.com/rust-lang/rust-clippy/issues) if you have ideas! diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index f5bd08657ea..fbc530eb606 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -137,6 +137,7 @@ fn get_clap_config<'a>() -> ArgMatches<'a> { .possible_values(&[ "style", "correctness", + "suspicious", "complexity", "perf", "pedantic", diff --git a/clippy_dev/src/update_lints.rs b/clippy_dev/src/update_lints.rs index edf6c5f57a4..db467c26f15 100644 --- a/clippy_dev/src/update_lints.rs +++ b/clippy_dev/src/update_lints.rs @@ -92,7 +92,10 @@ pub fn run(update_mode: UpdateMode) { || { // clippy::all should only include the following lint groups: let all_group_lints = usable_lints.iter().filter(|l| { - l.group == "correctness" || l.group == "style" || l.group == "complexity" || l.group == "perf" + matches!( + &*l.group, + "correctness" | "suspicious" | "style" | "complexity" | "perf" + ) }); gen_lint_group_list(all_group_lints) diff --git a/clippy_lints/src/lib.rs b/clippy_lints/src/lib.rs index 9cffeeb0224..4ce1d511d27 100644 --- a/clippy_lints/src/lib.rs +++ b/clippy_lints/src/lib.rs @@ -60,9 +60,9 @@ use rustc_session::Session; /// 4. The `description` that contains a short explanation on what's wrong with code where the /// lint is triggered. /// -/// Currently the categories `style`, `correctness`, `complexity` and `perf` are enabled by default. -/// As said in the README.md of this repository, if the lint level mapping changes, please update -/// README.md. +/// Currently the categories `style`, `correctness`, `suspicious`, `complexity` and `perf` are +/// enabled by default. As said in the README.md of this repository, if the lint level mapping +/// changes, please update README.md. /// /// # Example /// @@ -106,6 +106,11 @@ macro_rules! declare_clippy_lint { $(#[$attr])* pub clippy::$name, Deny, $description, report_in_external_macro: true } }; + { $(#[$attr:meta])* pub $name:tt, suspicious, $description:tt } => { + declare_tool_lint! { + $(#[$attr])* pub clippy::$name, Warn, $description, report_in_external_macro: true + } + }; { $(#[$attr:meta])* pub $name:tt, complexity, $description:tt } => { declare_tool_lint! { $(#[$attr])* pub clippy::$name, Warn, $description, report_in_external_macro: true diff --git a/clippy_lints/src/utils/internal_lints/metadata_collector.rs b/clippy_lints/src/utils/internal_lints/metadata_collector.rs index c980a0246fd..e877af09e28 100644 --- a/clippy_lints/src/utils/internal_lints/metadata_collector.rs +++ b/clippy_lints/src/utils/internal_lints/metadata_collector.rs @@ -47,8 +47,9 @@ const DEPRECATED_LINT_GROUP_STR: &str = "deprecated"; const DEPRECATED_LINT_LEVEL: &str = "none"; /// This array holds Clippy's lint groups with their corresponding default lint level. The /// lint level for deprecated lints is set in `DEPRECATED_LINT_LEVEL`. -const DEFAULT_LINT_LEVELS: [(&str, &str); 8] = [ +const DEFAULT_LINT_LEVELS: &[(&str, &str)] = &[ ("correctness", "deny"), + ("suspicious", "warn"), ("restriction", "allow"), ("style", "warn"), ("pedantic", "allow"), diff --git a/util/lintlib.py b/util/lintlib.py index 3b6e8c372ed..9cefb2dbb19 100644 --- a/util/lintlib.py +++ b/util/lintlib.py @@ -19,6 +19,7 @@ comment_re = re.compile(r'''\s*/// ?(.*)''') lint_levels = { "correctness": 'Deny', + "suspicious": 'Warn', "style": 'Warn', "complexity": 'Warn', "perf": 'Warn', -- cgit 1.4.1-3-g733a5 From 2098b27a200152f949bf08946c639d632146fb9b Mon Sep 17 00:00:00 2001 From: xFrednet Date: Sun, 27 Jun 2021 16:59:17 +0200 Subject: Added `cargo dev setup vscode-tasks` for simplicity --- clippy_dev/src/main.rs | 14 ++++++ clippy_dev/src/setup/git_hook.rs | 6 +++ clippy_dev/src/setup/mod.rs | 21 ++++++++ clippy_dev/src/setup/vscode.rs | 104 +++++++++++++++++++++++++++++++++++++++ util/etc/vscode-tasks.json | 57 +++++++++++++++++++++ 5 files changed, 202 insertions(+) create mode 100644 clippy_dev/src/setup/vscode.rs create mode 100644 util/etc/vscode-tasks.json (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index f5bd08657ea..17c321d6c79 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -43,11 +43,13 @@ fn main() { .expect("this field is mandatory and therefore always valid"), ), ("git-hook", Some(matches)) => setup::git_hook::install_hook(matches.is_present("force-override")), + ("vscode-tasks", Some(matches)) => setup::vscode::install_tasks(matches.is_present("force-override")), _ => {}, }, ("remove", Some(sub_command)) => match sub_command.subcommand() { ("git-hook", Some(_)) => setup::git_hook::remove_hook(), ("intellij", Some(_)) => setup::intellij::remove_rustc_src(), + ("vscode-tasks", Some(_)) => setup::vscode::remove_tasks(), _ => {}, }, ("serve", Some(matches)) => { @@ -180,6 +182,17 @@ fn get_clap_config<'a>() -> ArgMatches<'a> { .help("Forces the override of an existing git pre-commit hook") .required(false), ), + ) + .subcommand( + SubCommand::with_name("vscode-tasks") + .about("Add several tasks to vscode for formatting, validation and testing") + .arg( + Arg::with_name("force-override") + .long("force-override") + .short("f") + .help("Forces the override of existing vs code tasks") + .required(false), + ), ), ) .subcommand( @@ -187,6 +200,7 @@ fn get_clap_config<'a>() -> ArgMatches<'a> { .about("Support for undoing changes done by the setup command") .setting(AppSettings::ArgRequiredElseHelp) .subcommand(SubCommand::with_name("git-hook").about("Remove any existing pre-commit git hook")) + .subcommand(SubCommand::with_name("vscode-tasks").about("Remove any existing vscode tasks")) .subcommand( SubCommand::with_name("intellij") .about("Removes rustc source paths added via `cargo dev setup intellij`"), diff --git a/clippy_dev/src/setup/git_hook.rs b/clippy_dev/src/setup/git_hook.rs index f27b69a195b..3fbb77d5923 100644 --- a/clippy_dev/src/setup/git_hook.rs +++ b/clippy_dev/src/setup/git_hook.rs @@ -1,6 +1,8 @@ use std::fs; use std::path::Path; +use super::verify_inside_clippy_dir; + /// Rusts setup uses `git rev-parse --git-common-dir` to get the root directory of the repo. /// I've decided against this for the sake of simplicity and to make sure that it doesn't install /// the hook if `clippy_dev` would be used in the rust tree. The hook also references this tool @@ -36,6 +38,10 @@ pub fn install_hook(force_override: bool) { } fn check_precondition(force_override: bool) -> bool { + if !verify_inside_clippy_dir() { + return false; + } + // Make sure that we can find the git repository let git_path = Path::new(REPO_GIT_DIR); if !git_path.exists() || !git_path.is_dir() { diff --git a/clippy_dev/src/setup/mod.rs b/clippy_dev/src/setup/mod.rs index 3834f5a1842..a1e4dd103b8 100644 --- a/clippy_dev/src/setup/mod.rs +++ b/clippy_dev/src/setup/mod.rs @@ -1,2 +1,23 @@ pub mod git_hook; pub mod intellij; +pub mod vscode; + +use std::path::Path; + +const CLIPPY_DEV_DIR: &str = "clippy_dev"; + +/// This function verifies that the tool is being executed in the clippy directory. +/// This is useful to ensure that setups only modify Clippys resources. The verification +/// is done by checking that `clippy_dev` is a sub directory of the current directory. +/// +/// It will print an error message and return `false` if the directory could not be +/// verified. +fn verify_inside_clippy_dir() -> bool { + let path = Path::new(CLIPPY_DEV_DIR); + if path.exists() && path.is_dir() { + true + } else { + eprintln!("error: unable to verify that the working directory is clippys directory"); + false + } +} diff --git a/clippy_dev/src/setup/vscode.rs b/clippy_dev/src/setup/vscode.rs new file mode 100644 index 00000000000..d59001b2c66 --- /dev/null +++ b/clippy_dev/src/setup/vscode.rs @@ -0,0 +1,104 @@ +use std::fs; +use std::path::Path; + +use super::verify_inside_clippy_dir; + +const VSCODE_DIR: &str = ".vscode"; +const TASK_SOURCE_FILE: &str = "util/etc/vscode-tasks.json"; +const TASK_TARGET_FILE: &str = ".vscode/tasks.json"; + +pub fn install_tasks(force_override: bool) { + if !check_install_precondition(force_override) { + return; + } + + match fs::copy(TASK_SOURCE_FILE, TASK_TARGET_FILE) { + Ok(_) => { + println!("info: the task file can be removed with `cargo dev remove vscode-tasks`"); + println!("vscode tasks successfully installed"); + }, + Err(err) => eprintln!( + "error: unable to copy `{}` to `{}` ({})", + TASK_SOURCE_FILE, TASK_TARGET_FILE, err + ), + } +} + +fn check_install_precondition(force_override: bool) -> bool { + if !verify_inside_clippy_dir() { + return false; + } + + let vs_dir_path = Path::new(VSCODE_DIR); + if vs_dir_path.exists() { + // verify the target will be valid + if !vs_dir_path.is_dir() { + eprintln!("error: the `.vscode` path exists but seems to be a file"); + return false; + } + + // make sure that we don't override any existing tasks by accident + let path = Path::new(TASK_TARGET_FILE); + if path.exists() { + if force_override { + return delete_vs_task_file(path); + } + + eprintln!( + "error: there is already a `task.json` file inside the `{}` directory", + VSCODE_DIR + ); + println!("info: use the `--force-override` flag to override the existing `task.json` file"); + return false; + } + } else { + match fs::create_dir(vs_dir_path) { + Ok(_) => { + println!("info: created `{}` directory for clippy", VSCODE_DIR); + }, + Err(err) => { + eprintln!( + "error: the task target directory `{}` could not be created ({})", + VSCODE_DIR, err + ); + }, + } + } + + true +} + +pub fn remove_tasks() { + let path = Path::new(TASK_TARGET_FILE); + if path.exists() { + if delete_vs_task_file(path) { + try_delete_vs_directory_if_empty(); + println!("vscode tasks successfully removed"); + } + } else { + println!("no vscode tasks were found"); + } +} + +fn delete_vs_task_file(path: &Path) -> bool { + if let Err(err) = fs::remove_file(path) { + eprintln!("error: unable to delete the existing `tasks.json` file ({})", err); + return false; + } + + true +} + +/// This function will try to delete the `.vscode` directory if it's empty. +/// It may fail silently. +fn try_delete_vs_directory_if_empty() { + let path = Path::new(VSCODE_DIR); + if path.read_dir().map_or(false, |mut iter| iter.next().is_none()) { + // The directory is empty. We just try to delete it but allow a silence + // fail as an empty `.vscode` directory is still valid + let _silence_result = fs::remove_dir(path); + } else { + // The directory is not empty or could not be read. Either way don't take + // any further actions + } +} diff --git a/util/etc/vscode-tasks.json b/util/etc/vscode-tasks.json new file mode 100644 index 00000000000..aee31b5aa27 --- /dev/null +++ b/util/etc/vscode-tasks.json @@ -0,0 +1,57 @@ +{ + "version": "2.0.0", + "tasks": [ + { + "label": "cargo check", + "type": "shell", + "command": "cargo check", + "problemMatcher": [], + "group": { + "kind": "build", + "isDefault": true, + }, + }, + { + "label": "cargo fmt", + "type": "shell", + "command": "cargo dev fmt", + "problemMatcher": [], + "group": "none", + }, + { + "label": "cargo uitest", + "type": "shell", + "command": "cargo uitest", + "options": { + "env": { + "RUST_BACKTRACE": "1", + // This task will usually execute all UI tests inside `tests/ui` you can + // optionally uncomment the line below and only run a specific test. + // + // See: https://github.com/rust-lang/rust-clippy/blob/master/doc/adding_lints.md#testing + // + // "TESTNAME": "", + }, + }, + "problemMatcher": [], + "group": { + "kind": "test", + "isDefault": true, + } + }, + { + "label": "cargo test", + "type": "shell", + "command": "cargo test", + "problemMatcher": [], + "group": "test", + }, + { + "label": "cargo dev bless", + "type": "shell", + "command": "cargo dev bless", + "problemMatcher": [], + "group": "none", + }, + ], +} -- cgit 1.4.1-3-g733a5 From e40019134be9762d31c1653f00385740e8e98d93 Mon Sep 17 00:00:00 2001 From: xFrednet Date: Mon, 28 Jun 2021 20:40:09 +0200 Subject: Updated `clippy_dev` ui message and vscode task name Co-authored-by: Takayuki Nakata --- clippy_dev/src/main.rs | 2 +- util/etc/vscode-tasks.json | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index 17c321d6c79..b5d416c18f3 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -190,7 +190,7 @@ fn get_clap_config<'a>() -> ArgMatches<'a> { Arg::with_name("force-override") .long("force-override") .short("f") - .help("Forces the override of existing vs code tasks") + .help("Forces the override of existing vscode tasks") .required(false), ), ), diff --git a/util/etc/vscode-tasks.json b/util/etc/vscode-tasks.json index aee31b5aa27..a4bb26b9f90 100644 --- a/util/etc/vscode-tasks.json +++ b/util/etc/vscode-tasks.json @@ -12,7 +12,7 @@ }, }, { - "label": "cargo fmt", + "label": "cargo dev fmt", "type": "shell", "command": "cargo dev fmt", "problemMatcher": [], -- cgit 1.4.1-3-g733a5 From 12c61612f7a91df64121dd9c991828c26d665325 Mon Sep 17 00:00:00 2001 From: xFrednet Date: Fri, 2 Jul 2021 20:37:11 +0200 Subject: Update lint documentation to use markdown headlines --- clippy_dev/src/new_lint.rs | 9 +- clippy_lints/src/absurd_extreme_comparisons.rs | 12 +- clippy_lints/src/approx_const.rs | 10 +- clippy_lints/src/arithmetic.rs | 20 +- clippy_lints/src/as_conversions.rs | 10 +- clippy_lints/src/asm_syntax.rs | 20 +- clippy_lints/src/assertions_on_constants.rs | 11 +- clippy_lints/src/assign_ops.rs | 22 +- clippy_lints/src/async_yields_async.rs | 11 +- clippy_lints/src/atomic_ordering.rs | 10 +- clippy_lints/src/attrs.rs | 74 +-- clippy_lints/src/await_holding_invalid.rs | 24 +- clippy_lints/src/bit_mask.rs | 32 +- clippy_lints/src/blacklisted_name.rs | 10 +- clippy_lints/src/blocks_in_if_conditions.rs | 10 +- clippy_lints/src/bool_assert_comparison.rs | 11 +- clippy_lints/src/booleans.rs | 22 +- clippy_lints/src/bytecount.rs | 12 +- clippy_lints/src/cargo_common_metadata.rs | 10 +- .../case_sensitive_file_extension_comparisons.rs | 9 +- clippy_lints/src/casts/mod.rs | 116 ++-- clippy_lints/src/checked_conversions.rs | 10 +- clippy_lints/src/cognitive_complexity.rs | 12 +- clippy_lints/src/collapsible_if.rs | 20 +- clippy_lints/src/collapsible_match.rs | 11 +- clippy_lints/src/comparison_chain.rs | 11 +- clippy_lints/src/copies.rs | 40 +- clippy_lints/src/copy_iterator.rs | 10 +- clippy_lints/src/create_dir.rs | 10 +- clippy_lints/src/dbg_macro.rs | 10 +- clippy_lints/src/default.rs | 21 +- clippy_lints/src/default_numeric_fallback.rs | 11 +- clippy_lints/src/deprecated_lints.rs | 96 ++-- clippy_lints/src/dereference.rs | 8 +- clippy_lints/src/derive.rs | 43 +- clippy_lints/src/disallowed_method.rs | 11 +- clippy_lints/src/disallowed_script_idents.rs | 10 +- clippy_lints/src/disallowed_type.rs | 11 +- clippy_lints/src/doc.rs | 53 +- clippy_lints/src/double_comparison.rs | 10 +- clippy_lints/src/double_parens.rs | 10 +- clippy_lints/src/drop_forget_ref.rs | 40 +- clippy_lints/src/duration_subsec.rs | 10 +- clippy_lints/src/else_if_without_else.rs | 10 +- clippy_lints/src/empty_enum.rs | 11 +- clippy_lints/src/entry.rs | 11 +- clippy_lints/src/enum_clike.rs | 10 +- clippy_lints/src/enum_variants.rs | 30 +- clippy_lints/src/eq_op.rs | 22 +- clippy_lints/src/erasing_op.rs | 10 +- clippy_lints/src/escape.rs | 10 +- clippy_lints/src/eta_reduction.rs | 22 +- clippy_lints/src/eval_order_dependence.rs | 22 +- clippy_lints/src/excessive_bools.rs | 20 +- clippy_lints/src/exhaustive_items.rs | 22 +- clippy_lints/src/exit.rs | 10 +- clippy_lints/src/explicit_write.rs | 10 +- clippy_lints/src/fallible_impl_from.rs | 10 +- clippy_lints/src/float_equality_without_abs.rs | 50 +- clippy_lints/src/float_literal.rs | 22 +- clippy_lints/src/floating_point_arithmetic.rs | 22 +- clippy_lints/src/format.rs | 10 +- clippy_lints/src/formatting.rs | 40 +- clippy_lints/src/from_over_into.rs | 11 +- clippy_lints/src/from_str_radix_10.rs | 12 +- clippy_lints/src/functions/mod.rs | 73 +-- clippy_lints/src/future_not_send.rs | 11 +- clippy_lints/src/get_last_with_len.rs | 11 +- clippy_lints/src/identity_op.rs | 10 +- clippy_lints/src/if_let_mutex.rs | 11 +- clippy_lints/src/if_let_some_result.rs | 10 +- clippy_lints/src/if_not_else.rs | 10 +- clippy_lints/src/if_then_some_else_none.rs | 11 +- clippy_lints/src/implicit_hasher.rs | 11 +- clippy_lints/src/implicit_return.rs | 10 +- clippy_lints/src/implicit_saturating_sub.rs | 11 +- .../src/inconsistent_struct_constructor.rs | 11 +- clippy_lints/src/indexing_slicing.rs | 22 +- clippy_lints/src/infinite_iter.rs | 21 +- clippy_lints/src/inherent_impl.rs | 10 +- clippy_lints/src/inherent_to_string.rs | 24 +- clippy_lints/src/inline_fn_without_body.rs | 10 +- clippy_lints/src/int_plus_one.rs | 10 +- clippy_lints/src/integer_division.rs | 10 +- clippy_lints/src/invalid_upcast_comparisons.rs | 10 +- clippy_lints/src/items_after_statements.rs | 10 +- clippy_lints/src/large_const_arrays.rs | 10 +- clippy_lints/src/large_enum_variant.rs | 12 +- clippy_lints/src/large_stack_arrays.rs | 10 +- clippy_lints/src/len_zero.rs | 30 +- clippy_lints/src/let_if_seq.rs | 10 +- clippy_lints/src/let_underscore.rs | 30 +- clippy_lints/src/lib.rs | 11 +- clippy_lints/src/lifetimes.rs | 20 +- clippy_lints/src/literal_representation.rs | 66 +-- clippy_lints/src/loops/mod.rs | 182 +++--- clippy_lints/src/macro_use.rs | 10 +- clippy_lints/src/main_recursion.rs | 10 +- clippy_lints/src/manual_async_fn.rs | 11 +- clippy_lints/src/manual_map.rs | 11 +- clippy_lints/src/manual_non_exhaustive.rs | 11 +- clippy_lints/src/manual_ok_or.rs | 10 +- clippy_lints/src/manual_strip.rs | 10 +- clippy_lints/src/manual_unwrap_or.rs | 8 +- clippy_lints/src/map_clone.rs | 11 +- clippy_lints/src/map_err_ignore.rs | 10 +- clippy_lints/src/map_unit_fn.rs | 22 +- clippy_lints/src/match_on_vec_items.rs | 10 +- clippy_lints/src/matches.rs | 170 +++--- clippy_lints/src/mem_discriminant.rs | 10 +- clippy_lints/src/mem_forget.rs | 10 +- clippy_lints/src/mem_replace.rs | 31 +- clippy_lints/src/methods/mod.rs | 636 +++++++++++---------- clippy_lints/src/minmax.rs | 10 +- clippy_lints/src/misc.rs | 93 +-- clippy_lints/src/misc_early/mod.rs | 90 +-- clippy_lints/src/missing_const_for_fn.rs | 12 +- clippy_lints/src/missing_doc.rs | 8 +- clippy_lints/src/missing_enforced_import_rename.rs | 11 +- clippy_lints/src/missing_inline.rs | 10 +- clippy_lints/src/modulo_arithmetic.rs | 10 +- clippy_lints/src/multiple_crate_versions.rs | 11 +- clippy_lints/src/mut_key.rs | 11 +- clippy_lints/src/mut_mut.rs | 10 +- clippy_lints/src/mut_mutex_lock.rs | 11 +- clippy_lints/src/mut_reference.rs | 10 +- clippy_lints/src/mutable_debug_assertion.rs | 10 +- clippy_lints/src/mutex_atomic.rs | 22 +- clippy_lints/src/needless_arbitrary_self_type.rs | 10 +- clippy_lints/src/needless_bitwise_bool.rs | 9 +- clippy_lints/src/needless_bool.rs | 21 +- clippy_lints/src/needless_borrow.rs | 20 +- clippy_lints/src/needless_borrowed_ref.rs | 11 +- clippy_lints/src/needless_continue.rs | 10 +- clippy_lints/src/needless_for_each.rs | 11 +- clippy_lints/src/needless_pass_by_value.rs | 10 +- clippy_lints/src/needless_question_mark.rs | 10 +- clippy_lints/src/needless_update.rs | 10 +- clippy_lints/src/neg_cmp_op_on_partial_ord.rs | 9 +- clippy_lints/src/neg_multiply.rs | 11 +- clippy_lints/src/new_without_default.rs | 11 +- clippy_lints/src/no_effect.rs | 20 +- clippy_lints/src/non_copy_const.rs | 22 +- clippy_lints/src/non_expressive_names.rs | 30 +- clippy_lints/src/non_octal_unix_permissions.rs | 11 +- clippy_lints/src/nonstandard_macro_braces.rs | 12 +- clippy_lints/src/open_options.rs | 10 +- clippy_lints/src/option_env_unwrap.rs | 11 +- clippy_lints/src/option_if_let_else.rs | 9 +- clippy_lints/src/overflow_check_conditional.rs | 10 +- clippy_lints/src/panic_in_result_fn.rs | 12 +- clippy_lints/src/panic_unimplemented.rs | 40 +- clippy_lints/src/partialeq_ne_impl.rs | 10 +- clippy_lints/src/pass_by_ref_or_value.rs | 20 +- clippy_lints/src/path_buf_push_overwrite.rs | 10 +- clippy_lints/src/pattern_type_mismatch.rs | 11 +- clippy_lints/src/precedence.rs | 10 +- clippy_lints/src/ptr.rs | 42 +- clippy_lints/src/ptr_eq.rs | 11 +- clippy_lints/src/ptr_offset_with_cast.rs | 10 +- clippy_lints/src/question_mark.rs | 10 +- clippy_lints/src/ranges.rs | 54 +- clippy_lints/src/redundant_clone.rs | 11 +- clippy_lints/src/redundant_closure_call.rs | 10 +- clippy_lints/src/redundant_else.rs | 12 +- clippy_lints/src/redundant_field_names.rs | 10 +- clippy_lints/src/redundant_pub_crate.rs | 11 +- clippy_lints/src/redundant_slicing.rs | 12 +- clippy_lints/src/redundant_static_lifetimes.rs | 10 +- clippy_lints/src/ref_option_ref.rs | 12 +- clippy_lints/src/reference.rs | 19 +- clippy_lints/src/regex.rs | 21 +- clippy_lints/src/repeat_once.rs | 11 +- clippy_lints/src/returns.rs | 20 +- clippy_lints/src/self_assignment.rs | 12 +- clippy_lints/src/self_named_constructor.rs | 11 +- clippy_lints/src/semicolon_if_nothing_returned.rs | 11 +- clippy_lints/src/serde_api.rs | 11 +- clippy_lints/src/shadow.rs | 33 +- clippy_lints/src/single_component_path_imports.rs | 11 +- clippy_lints/src/size_of_in_element_count.rs | 10 +- clippy_lints/src/slow_vector_initialization.rs | 10 +- clippy_lints/src/stable_sort_primitive.rs | 10 +- clippy_lints/src/strings.rs | 63 +- clippy_lints/src/strlen_on_c_strings.rs | 11 +- clippy_lints/src/suspicious_operation_groupings.rs | 11 +- clippy_lints/src/suspicious_trait_impl.rs | 20 +- clippy_lints/src/swap.rs | 20 +- clippy_lints/src/tabs_in_doc_comments.rs | 10 +- clippy_lints/src/temporary_assignment.rs | 10 +- clippy_lints/src/to_digit_is_some.rs | 8 +- clippy_lints/src/to_string_in_display.rs | 10 +- clippy_lints/src/trait_bounds.rs | 20 +- clippy_lints/src/transmute/mod.rs | 122 ++-- clippy_lints/src/transmuting_null.rs | 11 +- clippy_lints/src/try_err.rs | 10 +- clippy_lints/src/types/mod.rs | 94 +-- clippy_lints/src/undropped_manually_drops.rs | 12 +- clippy_lints/src/unicode.rs | 32 +- clippy_lints/src/unit_return_expecting_ord.rs | 12 +- clippy_lints/src/unit_types/mod.rs | 30 +- clippy_lints/src/unnamed_address.rs | 22 +- clippy_lints/src/unnecessary_self_imports.rs | 12 +- clippy_lints/src/unnecessary_sort_by.rs | 9 +- clippy_lints/src/unnecessary_wraps.rs | 12 +- clippy_lints/src/unnested_or_patterns.rs | 11 +- clippy_lints/src/unsafe_removed_from_name.rs | 10 +- clippy_lints/src/unused_async.rs | 11 +- clippy_lints/src/unused_io_amount.rs | 11 +- clippy_lints/src/unused_self.rs | 10 +- clippy_lints/src/unused_unit.rs | 10 +- clippy_lints/src/unwrap.rs | 21 +- clippy_lints/src/unwrap_in_result.rs | 11 +- clippy_lints/src/upper_case_acronyms.rs | 12 +- clippy_lints/src/use_self.rs | 11 +- clippy_lints/src/useless_conversion.rs | 11 +- clippy_lints/src/utils/author.rs | 5 +- clippy_lints/src/utils/inspector.rs | 5 +- clippy_lints/src/utils/internal_lints.rs | 109 ++-- .../src/utils/internal_lints/metadata_collector.rs | 16 +- clippy_lints/src/vec.rs | 10 +- clippy_lints/src/vec_init_then_push.rs | 11 +- clippy_lints/src/vec_resize_to_zero.rs | 10 +- clippy_lints/src/verbose_file_reads.rs | 11 +- clippy_lints/src/wildcard_dependencies.rs | 11 +- clippy_lints/src/wildcard_imports.rs | 26 +- clippy_lints/src/write.rs | 92 +-- clippy_lints/src/zero_div_zero.rs | 10 +- clippy_lints/src/zero_sized_map_values.rs | 11 +- doc/adding_lints.md | 20 +- 230 files changed, 2717 insertions(+), 2474 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/new_lint.rs b/clippy_dev/src/new_lint.rs index 4676c2affad..3a81aaba6de 100644 --- a/clippy_dev/src/new_lint.rs +++ b/clippy_dev/src/new_lint.rs @@ -169,14 +169,11 @@ use rustc_session::{{declare_lint_pass, declare_tool_lint}}; {pass_import} declare_clippy_lint! {{ - /// **What it does:** + /// ### What it does /// - /// **Why is this bad?** - /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Why is this bad? /// + /// ### Example /// ```rust /// // example code where clippy issues a warning /// ``` diff --git a/clippy_lints/src/absurd_extreme_comparisons.rs b/clippy_lints/src/absurd_extreme_comparisons.rs index 49d4350123f..1483f3f9185 100644 --- a/clippy_lints/src/absurd_extreme_comparisons.rs +++ b/clippy_lints/src/absurd_extreme_comparisons.rs @@ -11,24 +11,26 @@ use clippy_utils::ty::is_isize_or_usize; use clippy_utils::{clip, int_bits, unsext}; declare_clippy_lint! { - /// **What it does:** Checks for comparisons where one side of the relation is + /// ### What it does + /// Checks for comparisons where one side of the relation is /// either the minimum or maximum value for its type and warns if it involves a /// case that is always true or always false. Only integer and boolean types are /// checked. /// - /// **Why is this bad?** An expression like `min <= x` may misleadingly imply + /// ### Why is this bad? + /// An expression like `min <= x` may misleadingly imply /// that it is possible for `x` to be less than the minimum. Expressions like /// `max < x` are probably mistakes. /// - /// **Known problems:** For `usize` the size of the current compile target will + /// ### Known problems + /// For `usize` the size of the current compile target will /// be assumed (e.g., 64 bits on 64 bit systems). This means code that uses such /// a comparison to detect target pointer width will trigger this lint. One can /// use `mem::sizeof` and compare its value or conditional compilation /// attributes /// like `#[cfg(target_pointer_width = "64")] ..` instead. /// - /// **Example:** - /// + /// ### Example /// ```rust /// let vec: Vec = Vec::new(); /// if vec.len() <= 0 {} diff --git a/clippy_lints/src/approx_const.rs b/clippy_lints/src/approx_const.rs index 3d04abe094d..6100f4e435a 100644 --- a/clippy_lints/src/approx_const.rs +++ b/clippy_lints/src/approx_const.rs @@ -7,21 +7,21 @@ use rustc_span::symbol; use std::f64::consts as f64; declare_clippy_lint! { - /// **What it does:** Checks for floating point literals that approximate + /// ### What it does + /// Checks for floating point literals that approximate /// constants which are defined in /// [`std::f32::consts`](https://doc.rust-lang.org/stable/std/f32/consts/#constants) /// or /// [`std::f64::consts`](https://doc.rust-lang.org/stable/std/f64/consts/#constants), /// respectively, suggesting to use the predefined constant. /// - /// **Why is this bad?** Usually, the definition in the standard library is more + /// ### Why is this bad? + /// Usually, the definition in the standard library is more /// precise than what people come up with. If you find that your definition is /// actually more precise, please [file a Rust /// issue](https://github.com/rust-lang/rust/issues). /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// let x = 3.14; /// let y = 1_f64 / x; diff --git a/clippy_lints/src/arithmetic.rs b/clippy_lints/src/arithmetic.rs index 24c2a972811..36fe7b7a867 100644 --- a/clippy_lints/src/arithmetic.rs +++ b/clippy_lints/src/arithmetic.rs @@ -6,7 +6,8 @@ use rustc_session::{declare_tool_lint, impl_lint_pass}; use rustc_span::source_map::Span; declare_clippy_lint! { - /// **What it does:** Checks for integer arithmetic operations which could overflow or panic. + /// ### What it does + /// Checks for integer arithmetic operations which could overflow or panic. /// /// Specifically, checks for any operators (`+`, `-`, `*`, `<<`, etc) which are capable /// of overflowing according to the [Rust @@ -14,13 +15,12 @@ declare_clippy_lint! { /// or which can panic (`/`, `%`). No bounds analysis or sophisticated reasoning is /// attempted. /// - /// **Why is this bad?** Integer overflow will trigger a panic in debug builds or will wrap in + /// ### Why is this bad? + /// Integer overflow will trigger a panic in debug builds or will wrap in /// release mode. Division by zero will cause a panic in either mode. In some applications one /// wants explicitly checked, wrapping or saturating arithmetic. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// # let a = 0; /// a + 1; @@ -31,14 +31,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for float arithmetic. + /// ### What it does + /// Checks for float arithmetic. /// - /// **Why is this bad?** For some embedded systems or kernel development, it + /// ### Why is this bad? + /// For some embedded systems or kernel development, it /// can be useful to rule out floating-point numbers. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// # let a = 0.0; /// a + 1.0; diff --git a/clippy_lints/src/as_conversions.rs b/clippy_lints/src/as_conversions.rs index 4b31e16094e..7c39a3e2ce3 100644 --- a/clippy_lints/src/as_conversions.rs +++ b/clippy_lints/src/as_conversions.rs @@ -5,7 +5,8 @@ use rustc_middle::lint::in_external_macro; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks for usage of `as` conversions. + /// ### What it does + /// Checks for usage of `as` conversions. /// /// Note that this lint is specialized in linting *every single* use of `as` /// regardless of whether good alternatives exist or not. @@ -15,14 +16,13 @@ declare_clippy_lint! { /// There is a good explanation the reason why this lint should work in this way and how it is useful /// [in this issue](https://github.com/rust-lang/rust-clippy/issues/5122). /// - /// **Why is this bad?** `as` conversions will perform many kinds of + /// ### Why is this bad? + /// `as` conversions will perform many kinds of /// conversions, including silently lossy conversions and dangerous coercions. /// There are cases when it makes sense to use `as`, so the lint is /// Allow by default. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust,ignore /// let a: u32; /// ... diff --git a/clippy_lints/src/asm_syntax.rs b/clippy_lints/src/asm_syntax.rs index b970c71b753..825832eb79d 100644 --- a/clippy_lints/src/asm_syntax.rs +++ b/clippy_lints/src/asm_syntax.rs @@ -53,14 +53,14 @@ fn check_expr_asm_syntax(lint: &'static Lint, cx: &EarlyContext<'_>, expr: &Expr } declare_clippy_lint! { - /// **What it does:** Checks for usage of Intel x86 assembly syntax. + /// ### What it does + /// Checks for usage of Intel x86 assembly syntax. /// - /// **Why is this bad?** The lint has been enabled to indicate a preference + /// ### Why is this bad? + /// The lint has been enabled to indicate a preference /// for AT&T x86 assembly syntax. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// /// ```rust,no_run /// # #![feature(asm)] @@ -89,14 +89,14 @@ impl EarlyLintPass for InlineAsmX86IntelSyntax { } declare_clippy_lint! { - /// **What it does:** Checks for usage of AT&T x86 assembly syntax. + /// ### What it does + /// Checks for usage of AT&T x86 assembly syntax. /// - /// **Why is this bad?** The lint has been enabled to indicate a preference + /// ### Why is this bad? + /// The lint has been enabled to indicate a preference /// for Intel x86 assembly syntax. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// /// ```rust,no_run /// # #![feature(asm)] diff --git a/clippy_lints/src/assertions_on_constants.rs b/clippy_lints/src/assertions_on_constants.rs index 5235b2642d1..cb9347a923d 100644 --- a/clippy_lints/src/assertions_on_constants.rs +++ b/clippy_lints/src/assertions_on_constants.rs @@ -8,14 +8,17 @@ use rustc_lint::{LateContext, LateLintPass}; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks for `assert!(true)` and `assert!(false)` calls. + /// ### What it does + /// Checks for `assert!(true)` and `assert!(false)` calls. /// - /// **Why is this bad?** Will be optimized out by the compiler or should probably be replaced by a + /// ### Why is this bad? + /// Will be optimized out by the compiler or should probably be replaced by a /// `panic!()` or `unreachable!()` /// - /// **Known problems:** None + /// ### Known problems + /// None /// - /// **Example:** + /// ### Example /// ```rust,ignore /// assert!(false) /// assert!(true) diff --git a/clippy_lints/src/assign_ops.rs b/clippy_lints/src/assign_ops.rs index 17ce3cd809f..2097a1feff9 100644 --- a/clippy_lints/src/assign_ops.rs +++ b/clippy_lints/src/assign_ops.rs @@ -12,15 +12,18 @@ use rustc_middle::hir::map::Map; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks for `a = a op b` or `a = b commutative_op a` + /// ### What it does + /// Checks for `a = a op b` or `a = b commutative_op a` /// patterns. /// - /// **Why is this bad?** These can be written as the shorter `a op= b`. + /// ### Why is this bad? + /// These can be written as the shorter `a op= b`. /// - /// **Known problems:** While forbidden by the spec, `OpAssign` traits may have + /// ### Known problems + /// While forbidden by the spec, `OpAssign` traits may have /// implementations that differ from the regular `Op` impl. /// - /// **Example:** + /// ### Example /// ```rust /// let mut a = 5; /// let b = 0; @@ -37,17 +40,20 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for `a op= a op b` or `a op= b op a` patterns. + /// ### What it does + /// Checks for `a op= a op b` or `a op= b op a` patterns. /// - /// **Why is this bad?** Most likely these are bugs where one meant to write `a + /// ### Why is this bad? + /// Most likely these are bugs where one meant to write `a /// op= b`. /// - /// **Known problems:** Clippy cannot know for sure if `a op= a op b` should have + /// ### Known problems + /// Clippy cannot know for sure if `a op= a op b` should have /// been `a = a op a op b` or `a = a op b`/`a op= b`. Therefore, it suggests both. /// If `a op= a op b` is really the correct behaviour it should be /// written as `a = a op a op b` as it's less confusing. /// - /// **Example:** + /// ### Example /// ```rust /// let mut a = 5; /// let b = 2; diff --git a/clippy_lints/src/async_yields_async.rs b/clippy_lints/src/async_yields_async.rs index e6c7c68f91a..182736a5a20 100644 --- a/clippy_lints/src/async_yields_async.rs +++ b/clippy_lints/src/async_yields_async.rs @@ -7,15 +7,14 @@ use rustc_lint::{LateContext, LateLintPass}; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks for async blocks that yield values of types + /// ### What it does + /// Checks for async blocks that yield values of types /// that can themselves be awaited. /// - /// **Why is this bad?** An await is likely missing. - /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Why is this bad? + /// An await is likely missing. /// + /// ### Example /// ```rust /// async fn foo() {} /// diff --git a/clippy_lints/src/atomic_ordering.rs b/clippy_lints/src/atomic_ordering.rs index 7ceb01f5590..cece28e8b3c 100644 --- a/clippy_lints/src/atomic_ordering.rs +++ b/clippy_lints/src/atomic_ordering.rs @@ -8,16 +8,16 @@ use rustc_middle::ty; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks for usage of invalid atomic + /// ### What it does + /// Checks for usage of invalid atomic /// ordering in atomic loads/stores/exchanges/updates and /// memory fences. /// - /// **Why is this bad?** Using an invalid atomic ordering + /// ### Why is this bad? + /// Using an invalid atomic ordering /// will cause a panic at run-time. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust,no_run /// # use std::sync::atomic::{self, AtomicU8, Ordering}; /// diff --git a/clippy_lints/src/attrs.rs b/clippy_lints/src/attrs.rs index f272ed010a1..c9ff468874b 100644 --- a/clippy_lints/src/attrs.rs +++ b/clippy_lints/src/attrs.rs @@ -41,10 +41,12 @@ static UNIX_SYSTEMS: &[&str] = &[ static NON_UNIX_SYSTEMS: &[&str] = &["hermit", "none", "wasi"]; declare_clippy_lint! { - /// **What it does:** Checks for items annotated with `#[inline(always)]`, + /// ### What it does + /// Checks for items annotated with `#[inline(always)]`, /// unless the annotated function is empty or simply panics. /// - /// **Why is this bad?** While there are valid uses of this annotation (and once + /// ### Why is this bad? + /// While there are valid uses of this annotation (and once /// you know when to use it, by all means `allow` this lint), it's a common /// newbie-mistake to pepper one's code with it. /// @@ -52,11 +54,12 @@ declare_clippy_lint! { /// measure if that additional function call really affects your runtime profile /// sufficiently to make up for the increase in compile time. /// - /// **Known problems:** False positives, big time. This lint is meant to be + /// ### Known problems + /// False positives, big time. This lint is meant to be /// deactivated by everyone doing serious performance work. This means having /// done the measurement. /// - /// **Example:** + /// ### Example /// ```ignore /// #[inline(always)] /// fn not_quite_hot_code(..) { ... } @@ -67,7 +70,8 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for `extern crate` and `use` items annotated with + /// ### What it does + /// Checks for `extern crate` and `use` items annotated with /// lint attributes. /// /// This lint permits `#[allow(unused_imports)]`, `#[allow(deprecated)]`, @@ -75,12 +79,11 @@ declare_clippy_lint! { /// `#[allow(clippy::enum_glob_use)]` on `use` items and `#[allow(unused_imports)]` on /// `extern crate` items with a `#[macro_use]` attribute. /// - /// **Why is this bad?** Lint attributes have no effect on crate imports. Most + /// ### Why is this bad? + /// Lint attributes have no effect on crate imports. Most /// likely a `!` was forgotten. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```ignore /// // Bad /// #[deny(dead_code)] @@ -101,15 +104,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for `#[deprecated]` annotations with a `since` + /// ### What it does + /// Checks for `#[deprecated]` annotations with a `since` /// field that is not a valid semantic version. /// - /// **Why is this bad?** For checking the version of the deprecation, it must be + /// ### Why is this bad? + /// For checking the version of the deprecation, it must be /// a valid semver. Failing that, the contained information is useless. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// #[deprecated(since = "forever")] /// fn something_else() { /* ... */ } @@ -120,20 +123,22 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for empty lines after outer attributes + /// ### What it does + /// Checks for empty lines after outer attributes /// - /// **Why is this bad?** + /// ### Why is this bad? /// Most likely the attribute was meant to be an inner attribute using a '!'. /// If it was meant to be an outer attribute, then the following item /// should not be separated by empty lines. /// - /// **Known problems:** Can cause false positives. + /// ### Known problems + /// Can cause false positives. /// /// From the clippy side it's difficult to detect empty lines between an attributes and the /// following item because empty lines and comments are not part of the AST. The parsing /// currently works for basic cases but is not perfect. /// - /// **Example:** + /// ### Example /// ```rust /// // Good (as inner attribute) /// #![allow(dead_code)] @@ -155,14 +160,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for `warn`/`deny`/`forbid` attributes targeting the whole clippy::restriction category. + /// ### What it does + /// Checks for `warn`/`deny`/`forbid` attributes targeting the whole clippy::restriction category. /// - /// **Why is this bad?** Restriction lints sometimes are in contrast with other lints or even go against idiomatic rust. + /// ### Why is this bad? + /// Restriction lints sometimes are in contrast with other lints or even go against idiomatic rust. /// These lints should only be enabled on a lint-by-lint basis and with careful consideration. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// Bad: /// ```rust /// #![deny(clippy::restriction)] @@ -178,18 +183,20 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for `#[cfg_attr(rustfmt, rustfmt_skip)]` and suggests to replace it + /// ### What it does + /// Checks for `#[cfg_attr(rustfmt, rustfmt_skip)]` and suggests to replace it /// with `#[rustfmt::skip]`. /// - /// **Why is this bad?** Since tool_attributes ([rust-lang/rust#44690](https://github.com/rust-lang/rust/issues/44690)) + /// ### Why is this bad? + /// Since tool_attributes ([rust-lang/rust#44690](https://github.com/rust-lang/rust/issues/44690)) /// are stable now, they should be used instead of the old `cfg_attr(rustfmt)` attributes. /// - /// **Known problems:** This lint doesn't detect crate level inner attributes, because they get + /// ### Known problems + /// This lint doesn't detect crate level inner attributes, because they get /// processed before the PreExpansionPass lints get executed. See /// [#3123](https://github.com/rust-lang/rust-clippy/pull/3123#issuecomment-422321765) /// - /// **Example:** - /// + /// ### Example /// Bad: /// ```rust /// #[cfg_attr(rustfmt, rustfmt_skip)] @@ -207,15 +214,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for cfg attributes having operating systems used in target family position. + /// ### What it does + /// Checks for cfg attributes having operating systems used in target family position. /// - /// **Why is this bad?** The configuration option will not be recognised and the related item will not be included + /// ### Why is this bad? + /// The configuration option will not be recognised and the related item will not be included /// by the conditional compilation engine. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// Bad: /// ```rust /// #[cfg(linux)] diff --git a/clippy_lints/src/await_holding_invalid.rs b/clippy_lints/src/await_holding_invalid.rs index 1739a57a240..0cc79c8b6e8 100644 --- a/clippy_lints/src/await_holding_invalid.rs +++ b/clippy_lints/src/await_holding_invalid.rs @@ -8,10 +8,12 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::Span; declare_clippy_lint! { - /// **What it does:** Checks for calls to await while holding a + /// ### What it does + /// Checks for calls to await while holding a /// non-async-aware MutexGuard. /// - /// **Why is this bad?** The Mutex types found in std::sync and parking_lot + /// ### Why is this bad? + /// The Mutex types found in std::sync and parking_lot /// are not designed to operate in an async context across await points. /// /// There are two potential solutions. One is to use an asynx-aware Mutex @@ -19,10 +21,10 @@ declare_clippy_lint! { /// other solution is to ensure the mutex is unlocked before calling await, /// either by introducing a scope or an explicit call to Drop::drop. /// - /// **Known problems:** Will report false positive for explicitly dropped guards ([#6446](https://github.com/rust-lang/rust-clippy/issues/6446)). - /// - /// **Example:** + /// ### Known problems + /// Will report false positive for explicitly dropped guards ([#6446](https://github.com/rust-lang/rust-clippy/issues/6446)). /// + /// ### Example /// ```rust,ignore /// use std::sync::Mutex; /// @@ -51,17 +53,19 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for calls to await while holding a + /// ### What it does + /// Checks for calls to await while holding a /// `RefCell` `Ref` or `RefMut`. /// - /// **Why is this bad?** `RefCell` refs only check for exclusive mutable access + /// ### Why is this bad? + /// `RefCell` refs only check for exclusive mutable access /// at runtime. Holding onto a `RefCell` ref across an `await` suspension point /// risks panics from a mutable ref shared while other refs are outstanding. /// - /// **Known problems:** Will report false positive for explicitly dropped refs ([#6353](https://github.com/rust-lang/rust-clippy/issues/6353)). - /// - /// **Example:** + /// ### Known problems + /// Will report false positive for explicitly dropped refs ([#6353](https://github.com/rust-lang/rust-clippy/issues/6353)). /// + /// ### Example /// ```rust,ignore /// use std::cell::RefCell; /// diff --git a/clippy_lints/src/bit_mask.rs b/clippy_lints/src/bit_mask.rs index 991ed94572c..11346e7c96a 100644 --- a/clippy_lints/src/bit_mask.rs +++ b/clippy_lints/src/bit_mask.rs @@ -10,7 +10,8 @@ use rustc_session::{declare_tool_lint, impl_lint_pass}; use rustc_span::source_map::Span; declare_clippy_lint! { - /// **What it does:** Checks for incompatible bit masks in comparisons. + /// ### What it does + /// Checks for incompatible bit masks in comparisons. /// /// The formula for detecting if an expression of the type `_ m /// c` (where `` is one of {`&`, `|`} and `` is one of @@ -26,7 +27,8 @@ declare_clippy_lint! { /// |`<` or `>=`| `|` |`x | 1 < 1` |`false` |`m >= c` | /// |`<=` or `>` | `|` |`x | 1 > 0` |`true` |`m > c` | /// - /// **Why is this bad?** If the bits that the comparison cares about are always + /// ### Why is this bad? + /// If the bits that the comparison cares about are always /// set to zero or one by the bit mask, the comparison is constant `true` or /// `false` (depending on mask, compared value, and operators). /// @@ -34,9 +36,7 @@ declare_clippy_lint! { /// this intentionally is to win an underhanded Rust contest or create a /// test-case for this lint. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// # let x = 1; /// if (x & 1 == 2) { } @@ -47,7 +47,8 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for bit masks in comparisons which can be removed + /// ### What it does + /// Checks for bit masks in comparisons which can be removed /// without changing the outcome. The basic structure can be seen in the /// following table: /// @@ -56,16 +57,18 @@ declare_clippy_lint! { /// |`>` / `<=`|`|` / `^`|`x | 2 > 3`|`x > 3`| /// |`<` / `>=`|`|` / `^`|`x ^ 1 < 4`|`x < 4`| /// - /// **Why is this bad?** Not equally evil as [`bad_bit_mask`](#bad_bit_mask), + /// ### Why is this bad? + /// Not equally evil as [`bad_bit_mask`](#bad_bit_mask), /// but still a bit misleading, because the bit mask is ineffective. /// - /// **Known problems:** False negatives: This lint will only match instances + /// ### Known problems + /// False negatives: This lint will only match instances /// where we have figured out the math (which is for a power-of-two compared /// value). This means things like `x | 1 >= 7` (which would be better written /// as `x >= 6`) will not be reported (but bit masks like this are fairly /// uncommon). /// - /// **Example:** + /// ### Example /// ```rust /// # let x = 1; /// if (x | 1 > 3) { } @@ -76,15 +79,18 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for bit masks that can be replaced by a call + /// ### What it does + /// Checks for bit masks that can be replaced by a call /// to `trailing_zeros` /// - /// **Why is this bad?** `x.trailing_zeros() > 4` is much clearer than `x & 15 + /// ### Why is this bad? + /// `x.trailing_zeros() > 4` is much clearer than `x & 15 /// == 0` /// - /// **Known problems:** llvm generates better code for `x & 15 == 0` on x86 + /// ### Known problems + /// llvm generates better code for `x & 15 == 0` on x86 /// - /// **Example:** + /// ### Example /// ```rust /// # let x = 1; /// if x & 0b1111 == 0 { } diff --git a/clippy_lints/src/blacklisted_name.rs b/clippy_lints/src/blacklisted_name.rs index 8eb94f3c28e..916c78c982a 100644 --- a/clippy_lints/src/blacklisted_name.rs +++ b/clippy_lints/src/blacklisted_name.rs @@ -5,15 +5,15 @@ use rustc_lint::{LateContext, LateLintPass}; use rustc_session::{declare_tool_lint, impl_lint_pass}; declare_clippy_lint! { - /// **What it does:** Checks for usage of blacklisted names for variables, such + /// ### What it does + /// Checks for usage of blacklisted names for variables, such /// as `foo`. /// - /// **Why is this bad?** These names are usually placeholder names and should be + /// ### Why is this bad? + /// These names are usually placeholder names and should be /// avoided. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// let foo = 3.14; /// ``` diff --git a/clippy_lints/src/blocks_in_if_conditions.rs b/clippy_lints/src/blocks_in_if_conditions.rs index badcf8d2a43..9b2e4f8998e 100644 --- a/clippy_lints/src/blocks_in_if_conditions.rs +++ b/clippy_lints/src/blocks_in_if_conditions.rs @@ -13,14 +13,14 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::sym; declare_clippy_lint! { - /// **What it does:** Checks for `if` conditions that use blocks containing an + /// ### What it does + /// Checks for `if` conditions that use blocks containing an /// expression, statements or conditions that use closures with blocks. /// - /// **Why is this bad?** Style, using blocks in the condition makes it hard to read. + /// ### Why is this bad? + /// Style, using blocks in the condition makes it hard to read. /// - /// **Known problems:** None. - /// - /// **Examples:** + /// ### Examples /// ```rust /// // Bad /// if { true } { /* ... */ } diff --git a/clippy_lints/src/bool_assert_comparison.rs b/clippy_lints/src/bool_assert_comparison.rs index bee706ed402..8d3f68565b2 100644 --- a/clippy_lints/src/bool_assert_comparison.rs +++ b/clippy_lints/src/bool_assert_comparison.rs @@ -6,14 +6,13 @@ use rustc_lint::{EarlyContext, EarlyLintPass}; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** This lint warns about boolean comparisons in assert-like macros. + /// ### What it does + /// This lint warns about boolean comparisons in assert-like macros. /// - /// **Why is this bad?** It is shorter to use the equivalent. - /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Why is this bad? + /// It is shorter to use the equivalent. /// + /// ### Example /// ```rust /// // Bad /// assert_eq!("a".is_empty(), false); diff --git a/clippy_lints/src/booleans.rs b/clippy_lints/src/booleans.rs index e72399af232..4a83d35a568 100644 --- a/clippy_lints/src/booleans.rs +++ b/clippy_lints/src/booleans.rs @@ -14,16 +14,19 @@ use rustc_span::source_map::Span; use rustc_span::sym; declare_clippy_lint! { - /// **What it does:** Checks for boolean expressions that can be written more + /// ### What it does + /// Checks for boolean expressions that can be written more /// concisely. /// - /// **Why is this bad?** Readability of boolean expressions suffers from + /// ### Why is this bad? + /// Readability of boolean expressions suffers from /// unnecessary duplication. /// - /// **Known problems:** Ignores short circuiting behavior of `||` and + /// ### Known problems + /// Ignores short circuiting behavior of `||` and /// `&&`. Ignores `|`, `&` and `^`. /// - /// **Example:** + /// ### Example /// ```ignore /// if a && true // should be: if a /// if !(a == b) // should be: if a != b @@ -34,14 +37,17 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for boolean expressions that contain terminals that + /// ### What it does + /// Checks for boolean expressions that contain terminals that /// can be eliminated. /// - /// **Why is this bad?** This is most likely a logic bug. + /// ### Why is this bad? + /// This is most likely a logic bug. /// - /// **Known problems:** Ignores short circuiting behavior. + /// ### Known problems + /// Ignores short circuiting behavior. /// - /// **Example:** + /// ### Example /// ```ignore /// if a && b || a { ... } /// ``` diff --git a/clippy_lints/src/bytecount.rs b/clippy_lints/src/bytecount.rs index 4f7ffdcdfb4..c444984bc13 100644 --- a/clippy_lints/src/bytecount.rs +++ b/clippy_lints/src/bytecount.rs @@ -12,18 +12,20 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::sym; declare_clippy_lint! { - /// **What it does:** Checks for naive byte counts + /// ### What it does + /// Checks for naive byte counts /// - /// **Why is this bad?** The [`bytecount`](https://crates.io/crates/bytecount) + /// ### Why is this bad? + /// The [`bytecount`](https://crates.io/crates/bytecount) /// crate has methods to count your bytes faster, especially for large slices. /// - /// **Known problems:** If you have predominantly small slices, the + /// ### Known problems + /// If you have predominantly small slices, the /// `bytecount::count(..)` method may actually be slower. However, if you can /// ensure that less than 2³²-1 matches arise, the `naive_count_32(..)` can be /// faster in those cases. /// - /// **Example:** - /// + /// ### Example /// ```rust /// # let vec = vec![1_u8]; /// &vec.iter().filter(|x| **x == 0u8).count(); // use bytecount::count instead diff --git a/clippy_lints/src/cargo_common_metadata.rs b/clippy_lints/src/cargo_common_metadata.rs index 21c7b2448ce..bd5426ba707 100644 --- a/clippy_lints/src/cargo_common_metadata.rs +++ b/clippy_lints/src/cargo_common_metadata.rs @@ -9,15 +9,15 @@ use rustc_session::{declare_tool_lint, impl_lint_pass}; use rustc_span::source_map::DUMMY_SP; declare_clippy_lint! { - /// **What it does:** Checks to see if all common metadata is defined in + /// ### What it does + /// Checks to see if all common metadata is defined in /// `Cargo.toml`. See: https://rust-lang-nursery.github.io/api-guidelines/documentation.html#cargotoml-includes-all-common-metadata-c-metadata /// - /// **Why is this bad?** It will be more difficult for users to discover the + /// ### Why is this bad? + /// It will be more difficult for users to discover the /// purpose of the crate, and key information related to it. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```toml /// # This `Cargo.toml` is missing a description field: /// [package] diff --git a/clippy_lints/src/case_sensitive_file_extension_comparisons.rs b/clippy_lints/src/case_sensitive_file_extension_comparisons.rs index c9ef379be56..86b32475ceb 100644 --- a/clippy_lints/src/case_sensitive_file_extension_comparisons.rs +++ b/clippy_lints/src/case_sensitive_file_extension_comparisons.rs @@ -8,17 +8,14 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::{source_map::Spanned, symbol::sym, Span}; declare_clippy_lint! { - /// **What it does:** + /// ### What it does /// Checks for calls to `ends_with` with possible file extensions /// and suggests to use a case-insensitive approach instead. /// - /// **Why is this bad?** + /// ### Why is this bad? /// `ends_with` is case-sensitive and may not detect files with a valid extension. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust /// fn is_rust_file(filename: &str) -> bool { /// filename.ends_with(".rs") diff --git a/clippy_lints/src/casts/mod.rs b/clippy_lints/src/casts/mod.rs index ae4fdd12c41..27e1bea7993 100644 --- a/clippy_lints/src/casts/mod.rs +++ b/clippy_lints/src/casts/mod.rs @@ -20,7 +20,8 @@ use rustc_semver::RustcVersion; use rustc_session::{declare_tool_lint, impl_lint_pass}; declare_clippy_lint! { - /// **What it does:** Checks for casts from any numerical to a float type where + /// ### What it does + /// Checks for casts from any numerical to a float type where /// the receiving type cannot store all values from the original type without /// rounding errors. This possible rounding is to be expected, so this lint is /// `Allow` by default. @@ -28,13 +29,12 @@ declare_clippy_lint! { /// Basically, this warns on casting any integer with 32 or more bits to `f32` /// or any 64-bit integer to `f64`. /// - /// **Why is this bad?** It's not bad at all. But in some applications it can be + /// ### Why is this bad? + /// It's not bad at all. But in some applications it can be /// helpful to know where precision loss can take place. This lint can help find /// those places in the code. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// let x = u64::MAX; /// x as f64; @@ -45,17 +45,17 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for casts from a signed to an unsigned numerical + /// ### What it does + /// Checks for casts from a signed to an unsigned numerical /// type. In this case, negative values wrap around to large positive values, /// which can be quite surprising in practice. However, as the cast works as /// defined, this lint is `Allow` by default. /// - /// **Why is this bad?** Possibly surprising results. You can activate this lint + /// ### Why is this bad? + /// Possibly surprising results. You can activate this lint /// as a one-time check to see where numerical wrapping can arise. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// let y: i8 = -1; /// y as u128; // will return 18446744073709551615 @@ -66,17 +66,17 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for casts between numerical types that may + /// ### What it does + /// Checks for casts between numerical types that may /// truncate large values. This is expected behavior, so the cast is `Allow` by /// default. /// - /// **Why is this bad?** In some problem domains, it is good practice to avoid + /// ### Why is this bad? + /// In some problem domains, it is good practice to avoid /// truncation. This lint can be activated to help assess where additional /// checks could be beneficial. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// fn as_u8(x: u64) -> u8 { /// x as u8 @@ -88,20 +88,20 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for casts from an unsigned type to a signed type of + /// ### What it does + /// Checks for casts from an unsigned type to a signed type of /// the same size. Performing such a cast is a 'no-op' for the compiler, /// i.e., nothing is changed at the bit level, and the binary representation of /// the value is reinterpreted. This can cause wrapping if the value is too big /// for the target signed type. However, the cast works as defined, so this lint /// is `Allow` by default. /// - /// **Why is this bad?** While such a cast is not bad in itself, the results can + /// ### Why is this bad? + /// While such a cast is not bad in itself, the results can /// be surprising when this is not the intended behavior, as demonstrated by the /// example below. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// u32::MAX as i32; // will yield a value of `-1` /// ``` @@ -111,19 +111,19 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for casts between numerical types that may + /// ### What it does + /// Checks for casts between numerical types that may /// be replaced by safe conversion functions. /// - /// **Why is this bad?** Rust's `as` keyword will perform many kinds of + /// ### Why is this bad? + /// Rust's `as` keyword will perform many kinds of /// conversions, including silently lossy conversions. Conversion functions such /// as `i32::from` will only perform lossless conversions. Using the conversion /// functions prevents conversions from turning into silent lossy conversions if /// the types of the input expressions ever change, and make it easier for /// people reading the code to know that the conversion is lossless. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// fn as_u64(x: u8) -> u64 { /// x as u64 @@ -143,14 +143,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for casts to the same type, casts of int literals to integer types + /// ### What it does + /// Checks for casts to the same type, casts of int literals to integer types /// and casts of float literals to float types. /// - /// **Why is this bad?** It's just unnecessary. - /// - /// **Known problems:** None. + /// ### Why is this bad? + /// It's just unnecessary. /// - /// **Example:** + /// ### Example /// ```rust /// let _ = 2i32 as i32; /// let _ = 0.5 as f32; @@ -168,17 +168,20 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for casts, using `as` or `pointer::cast`, + /// ### What it does + /// Checks for casts, using `as` or `pointer::cast`, /// from a less-strictly-aligned pointer to a more-strictly-aligned pointer /// - /// **Why is this bad?** Dereferencing the resulting pointer may be undefined + /// ### Why is this bad? + /// Dereferencing the resulting pointer may be undefined /// behavior. /// - /// **Known problems:** Using `std::ptr::read_unaligned` and `std::ptr::write_unaligned` or similar + /// ### Known problems + /// Using `std::ptr::read_unaligned` and `std::ptr::write_unaligned` or similar /// on the resulting pointer is fine. Is over-zealous: Casts with manual alignment checks or casts like /// u64-> u8 -> u16 can be fine. Miri is able to do a more in-depth analysis. /// - /// **Example:** + /// ### Example /// ```rust /// let _ = (&1u8 as *const u8) as *const u16; /// let _ = (&mut 1u8 as *mut u8) as *mut u16; @@ -192,9 +195,10 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for casts of function pointers to something other than usize + /// ### What it does + /// Checks for casts of function pointers to something other than usize /// - /// **Why is this bad?** + /// ### Why is this bad? /// Casting a function pointer to anything other than usize/isize is not portable across /// architectures, because you end up losing bits if the target type is too small or end up with a /// bunch of extra bits that waste space and add more instructions to the final binary than @@ -202,8 +206,7 @@ declare_clippy_lint! { /// /// Casting to isize also doesn't make sense since there are no signed addresses. /// - /// **Example** - /// + /// ### Example /// ```rust /// // Bad /// fn fun() -> i32 { 1 } @@ -219,16 +222,16 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for casts of a function pointer to a numeric type not wide enough to + /// ### What it does + /// Checks for casts of a function pointer to a numeric type not wide enough to /// store address. /// - /// **Why is this bad?** + /// ### Why is this bad? /// Such a cast discards some bits of the function's address. If this is intended, it would be more /// clearly expressed by casting to usize first, then casting the usize to the intended type (with /// a comment) to perform the truncation. /// - /// **Example** - /// + /// ### Example /// ```rust /// // Bad /// fn fn1() -> i16 { @@ -249,15 +252,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for casts of `&T` to `&mut T` anywhere in the code. + /// ### What it does + /// Checks for casts of `&T` to `&mut T` anywhere in the code. /// - /// **Why is this bad?** It’s basically guaranteed to be undefined behaviour. + /// ### Why is this bad? + /// It’s basically guaranteed to be undefined behaviour. /// `UnsafeCell` is the only way to obtain aliasable data that is considered /// mutable. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust,ignore /// fn x(r: &i32) { /// unsafe { @@ -283,18 +286,18 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for expressions where a character literal is cast + /// ### What it does + /// Checks for expressions where a character literal is cast /// to `u8` and suggests using a byte literal instead. /// - /// **Why is this bad?** In general, casting values to smaller types is + /// ### Why is this bad? + /// In general, casting values to smaller types is /// error-prone and should be avoided where possible. In the particular case of /// converting a character literal to u8, it is easy to avoid by just using a /// byte literal instead. As an added bonus, `b'a'` is even slightly shorter /// than `'a' as u8`. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust,ignore /// 'x' as u8 /// ``` @@ -310,18 +313,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** + /// ### What it does /// Checks for `as` casts between raw pointers without changing its mutability, /// namely `*const T` to `*const U` and `*mut T` to `*mut U`. /// - /// **Why is this bad?** + /// ### Why is this bad? /// Though `as` casts between raw pointers is not terrible, `pointer::cast` is safer because /// it cannot accidentally change the pointer's mutability nor cast the pointer to other types like `usize`. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust /// let ptr: *const u32 = &42_u32; /// let mut_ptr: *mut u32 = &mut 42_u32; diff --git a/clippy_lints/src/checked_conversions.rs b/clippy_lints/src/checked_conversions.rs index 8d3123e1ec8..842bbf006cc 100644 --- a/clippy_lints/src/checked_conversions.rs +++ b/clippy_lints/src/checked_conversions.rs @@ -13,13 +13,13 @@ use rustc_semver::RustcVersion; use rustc_session::{declare_tool_lint, impl_lint_pass}; declare_clippy_lint! { - /// **What it does:** Checks for explicit bounds checking when casting. + /// ### What it does + /// Checks for explicit bounds checking when casting. /// - /// **Why is this bad?** Reduces the readability of statements & is error prone. + /// ### Why is this bad? + /// Reduces the readability of statements & is error prone. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// # let foo: u32 = 5; /// # let _ = diff --git a/clippy_lints/src/cognitive_complexity.rs b/clippy_lints/src/cognitive_complexity.rs index f62c6a9c325..96c30d57ee1 100644 --- a/clippy_lints/src/cognitive_complexity.rs +++ b/clippy_lints/src/cognitive_complexity.rs @@ -14,15 +14,19 @@ use rustc_span::source_map::Span; use rustc_span::{sym, BytePos}; declare_clippy_lint! { - /// **What it does:** Checks for methods with high cognitive complexity. + /// ### What it does + /// Checks for methods with high cognitive complexity. /// - /// **Why is this bad?** Methods of high cognitive complexity tend to be hard to + /// ### Why is this bad? + /// Methods of high cognitive complexity tend to be hard to /// both read and maintain. Also LLVM will tend to optimize small methods better. /// - /// **Known problems:** Sometimes it's hard to find a way to reduce the + /// ### Known problems + /// Sometimes it's hard to find a way to reduce the /// complexity. /// - /// **Example:** No. You'll see it when you get the warning. + /// ### Example + /// No. You'll see it when you get the warning. pub COGNITIVE_COMPLEXITY, nursery, "functions that should be split up into multiple functions" diff --git a/clippy_lints/src/collapsible_if.rs b/clippy_lints/src/collapsible_if.rs index 6e950738239..4aa87980715 100644 --- a/clippy_lints/src/collapsible_if.rs +++ b/clippy_lints/src/collapsible_if.rs @@ -22,15 +22,15 @@ use rustc_lint::{EarlyContext, EarlyLintPass}; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks for nested `if` statements which can be collapsed + /// ### What it does + /// Checks for nested `if` statements which can be collapsed /// by `&&`-combining their conditions. /// - /// **Why is this bad?** Each `if`-statement adds one level of nesting, which + /// ### Why is this bad? + /// Each `if`-statement adds one level of nesting, which /// makes code look more complex than it really is. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust,ignore /// if x { /// if y { @@ -53,15 +53,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for collapsible `else { if ... }` expressions + /// ### What it does + /// Checks for collapsible `else { if ... }` expressions /// that can be collapsed to `else if ...`. /// - /// **Why is this bad?** Each `if`-statement adds one level of nesting, which + /// ### Why is this bad? + /// Each `if`-statement adds one level of nesting, which /// makes code look more complex than it really is. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust,ignore /// /// if x { diff --git a/clippy_lints/src/collapsible_match.rs b/clippy_lints/src/collapsible_match.rs index a6c3a5b0e83..a403a9846ba 100644 --- a/clippy_lints/src/collapsible_match.rs +++ b/clippy_lints/src/collapsible_match.rs @@ -9,18 +9,17 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::{MultiSpan, Span}; declare_clippy_lint! { - /// **What it does:** Finds nested `match` or `if let` expressions where the patterns may be "collapsed" together + /// ### What it does + /// Finds nested `match` or `if let` expressions where the patterns may be "collapsed" together /// without adding any branches. /// /// Note that this lint is not intended to find _all_ cases where nested match patterns can be merged, but only /// cases where merging would most likely make the code more readable. /// - /// **Why is this bad?** It is unnecessarily verbose and complex. - /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Why is this bad? + /// It is unnecessarily verbose and complex. /// + /// ### Example /// ```rust /// fn func(opt: Option>) { /// let n = match opt { diff --git a/clippy_lints/src/comparison_chain.rs b/clippy_lints/src/comparison_chain.rs index b6999bef6e7..597a3c67024 100644 --- a/clippy_lints/src/comparison_chain.rs +++ b/clippy_lints/src/comparison_chain.rs @@ -6,16 +6,19 @@ use rustc_lint::{LateContext, LateLintPass}; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks comparison chains written with `if` that can be + /// ### What it does + /// Checks comparison chains written with `if` that can be /// rewritten with `match` and `cmp`. /// - /// **Why is this bad?** `if` is not guaranteed to be exhaustive and conditionals can get + /// ### Why is this bad? + /// `if` is not guaranteed to be exhaustive and conditionals can get /// repetitive /// - /// **Known problems:** The match statement may be slower due to the compiler + /// ### Known problems + /// The match statement may be slower due to the compiler /// not inlining the call to cmp. See issue [#5354](https://github.com/rust-lang/rust-clippy/issues/5354) /// - /// **Example:** + /// ### Example /// ```rust,ignore /// # fn a() {} /// # fn b() {} diff --git a/clippy_lints/src/copies.rs b/clippy_lints/src/copies.rs index 9cbcde59768..2dcd5545799 100644 --- a/clippy_lints/src/copies.rs +++ b/clippy_lints/src/copies.rs @@ -16,13 +16,13 @@ use rustc_span::{source_map::Span, symbol::Symbol, BytePos}; use std::borrow::Cow; declare_clippy_lint! { - /// **What it does:** Checks for consecutive `if`s with the same condition. + /// ### What it does + /// Checks for consecutive `if`s with the same condition. /// - /// **Why is this bad?** This is probably a copy & paste error. + /// ### Why is this bad? + /// This is probably a copy & paste error. /// - /// **Known problems:** Hopefully none. - /// - /// **Example:** + /// ### Example /// ```ignore /// if a == b { /// … @@ -47,15 +47,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for consecutive `if`s with the same function call. + /// ### What it does + /// Checks for consecutive `if`s with the same function call. /// - /// **Why is this bad?** This is probably a copy & paste error. + /// ### Why is this bad? + /// This is probably a copy & paste error. /// Despite the fact that function can have side effects and `if` works as /// intended, such an approach is implicit and can be considered a "code smell". /// - /// **Known problems:** Hopefully none. - /// - /// **Example:** + /// ### Example /// ```ignore /// if foo() == bar { /// … @@ -94,14 +94,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for `if/else` with the same body as the *then* part + /// ### What it does + /// Checks for `if/else` with the same body as the *then* part /// and the *else* part. /// - /// **Why is this bad?** This is probably a copy & paste error. - /// - /// **Known problems:** Hopefully none. + /// ### Why is this bad? + /// This is probably a copy & paste error. /// - /// **Example:** + /// ### Example /// ```ignore /// let foo = if … { /// 42 @@ -115,17 +115,19 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks if the `if` and `else` block contain shared code that can be + /// ### What it does + /// Checks if the `if` and `else` block contain shared code that can be /// moved out of the blocks. /// - /// **Why is this bad?** Duplicate code is less maintainable. + /// ### Why is this bad? + /// Duplicate code is less maintainable. /// - /// **Known problems:** + /// ### Known problems /// * The lint doesn't check if the moved expressions modify values that are beeing used in /// the if condition. The suggestion can in that case modify the behavior of the program. /// See [rust-clippy#7452](https://github.com/rust-lang/rust-clippy/issues/7452) /// - /// **Example:** + /// ### Example /// ```ignore /// let foo = if … { /// println!("Hello World"); diff --git a/clippy_lints/src/copy_iterator.rs b/clippy_lints/src/copy_iterator.rs index 35079c6bedc..c2e9e8b3ab7 100644 --- a/clippy_lints/src/copy_iterator.rs +++ b/clippy_lints/src/copy_iterator.rs @@ -8,15 +8,15 @@ use rustc_span::sym; use if_chain::if_chain; declare_clippy_lint! { - /// **What it does:** Checks for types that implement `Copy` as well as + /// ### What it does + /// Checks for types that implement `Copy` as well as /// `Iterator`. /// - /// **Why is this bad?** Implicit copies can be confusing when working with + /// ### Why is this bad? + /// Implicit copies can be confusing when working with /// iterator combinators. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust,ignore /// #[derive(Copy, Clone)] /// struct Countdown(u8); diff --git a/clippy_lints/src/create_dir.rs b/clippy_lints/src/create_dir.rs index 7b5cce6462a..e4ee2772483 100644 --- a/clippy_lints/src/create_dir.rs +++ b/clippy_lints/src/create_dir.rs @@ -8,13 +8,13 @@ use rustc_lint::{LateContext, LateLintPass}; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks usage of `std::fs::create_dir` and suggest using `std::fs::create_dir_all` instead. + /// ### What it does + /// Checks usage of `std::fs::create_dir` and suggest using `std::fs::create_dir_all` instead. /// - /// **Why is this bad?** Sometimes `std::fs::create_dir` is mistakenly chosen over `std::fs::create_dir_all`. + /// ### Why is this bad? + /// Sometimes `std::fs::create_dir` is mistakenly chosen over `std::fs::create_dir_all`. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// /// ```rust /// std::fs::create_dir("foo"); diff --git a/clippy_lints/src/dbg_macro.rs b/clippy_lints/src/dbg_macro.rs index 286cc7e223e..bab4a696f83 100644 --- a/clippy_lints/src/dbg_macro.rs +++ b/clippy_lints/src/dbg_macro.rs @@ -8,14 +8,14 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::source_map::Span; declare_clippy_lint! { - /// **What it does:** Checks for usage of dbg!() macro. + /// ### What it does + /// Checks for usage of dbg!() macro. /// - /// **Why is this bad?** `dbg!` macro is intended as a debugging tool. It + /// ### Why is this bad? + /// `dbg!` macro is intended as a debugging tool. It /// should not be in version control. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust,ignore /// // Bad /// dbg!(true) diff --git a/clippy_lints/src/default.rs b/clippy_lints/src/default.rs index 947479db8f5..db8f2171348 100644 --- a/clippy_lints/src/default.rs +++ b/clippy_lints/src/default.rs @@ -13,14 +13,14 @@ use rustc_span::symbol::{Ident, Symbol}; use rustc_span::Span; declare_clippy_lint! { - /// **What it does:** Checks for literal calls to `Default::default()`. + /// ### What it does + /// Checks for literal calls to `Default::default()`. /// - /// **Why is this bad?** It's more clear to the reader to use the name of the type whose default is + /// ### Why is this bad? + /// It's more clear to the reader to use the name of the type whose default is /// being gotten than the generic `Default`. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// // Bad /// let s: String = Default::default(); @@ -34,14 +34,17 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for immediate reassignment of fields initialized + /// ### What it does + /// Checks for immediate reassignment of fields initialized /// with Default::default(). /// - /// **Why is this bad?**It's more idiomatic to use the [functional update syntax](https://doc.rust-lang.org/reference/expressions/struct-expr.html#functional-update-syntax). + /// ### Why is this bad? + ///It's more idiomatic to use the [functional update syntax](https://doc.rust-lang.org/reference/expressions/struct-expr.html#functional-update-syntax). /// - /// **Known problems:** Assignments to patterns that are of tuple type are not linted. + /// ### Known problems + /// Assignments to patterns that are of tuple type are not linted. /// - /// **Example:** + /// ### Example /// Bad: /// ``` /// # #[derive(Default)] diff --git a/clippy_lints/src/default_numeric_fallback.rs b/clippy_lints/src/default_numeric_fallback.rs index e719a1b0abf..3f1b7ea6214 100644 --- a/clippy_lints/src/default_numeric_fallback.rs +++ b/clippy_lints/src/default_numeric_fallback.rs @@ -18,7 +18,8 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use std::iter; declare_clippy_lint! { - /// **What it does:** Checks for usage of unconstrained numeric literals which may cause default numeric fallback in type + /// ### What it does + /// Checks for usage of unconstrained numeric literals which may cause default numeric fallback in type /// inference. /// /// Default numeric fallback means that if numeric types have not yet been bound to concrete @@ -27,12 +28,14 @@ declare_clippy_lint! { /// /// See [RFC0212](https://github.com/rust-lang/rfcs/blob/master/text/0212-restore-int-fallback.md) for more information about the fallback. /// - /// **Why is this bad?** For those who are very careful about types, default numeric fallback + /// ### Why is this bad? + /// For those who are very careful about types, default numeric fallback /// can be a pitfall that cause unexpected runtime behavior. /// - /// **Known problems:** This lint can only be allowed at the function level or above. + /// ### Known problems + /// This lint can only be allowed at the function level or above. /// - /// **Example:** + /// ### Example /// ```rust /// let i = 10; /// let f = 1.23; diff --git a/clippy_lints/src/deprecated_lints.rs b/clippy_lints/src/deprecated_lints.rs index 2933fbc9341..c604516742c 100644 --- a/clippy_lints/src/deprecated_lints.rs +++ b/clippy_lints/src/deprecated_lints.rs @@ -12,27 +12,33 @@ macro_rules! declare_deprecated_lint { } declare_deprecated_lint! { - /// **What it does:** Nothing. This lint has been deprecated. + /// ### What it does + /// Nothing. This lint has been deprecated. /// - /// **Deprecation reason:** This used to check for `assert!(a == b)` and recommend + /// ### Deprecation reason + /// This used to check for `assert!(a == b)` and recommend /// replacement with `assert_eq!(a, b)`, but this is no longer needed after RFC 2011. pub SHOULD_ASSERT_EQ, "`assert!()` will be more flexible with RFC 2011" } declare_deprecated_lint! { - /// **What it does:** Nothing. This lint has been deprecated. + /// ### What it does + /// Nothing. This lint has been deprecated. /// - /// **Deprecation reason:** This used to check for `Vec::extend`, which was slower than + /// ### Deprecation reason + /// This used to check for `Vec::extend`, which was slower than /// `Vec::extend_from_slice`. Thanks to specialization, this is no longer true. pub EXTEND_FROM_SLICE, "`.extend_from_slice(_)` is a faster way to extend a Vec by a slice" } declare_deprecated_lint! { - /// **What it does:** Nothing. This lint has been deprecated. + /// ### What it does + /// Nothing. This lint has been deprecated. /// - /// **Deprecation reason:** `Range::step_by(0)` used to be linted since it's + /// ### Deprecation reason + /// `Range::step_by(0)` used to be linted since it's /// an infinite iterator, which is better expressed by `iter::repeat`, /// but the method has been removed for `Iterator::step_by` which panics /// if given a zero @@ -41,27 +47,33 @@ declare_deprecated_lint! { } declare_deprecated_lint! { - /// **What it does:** Nothing. This lint has been deprecated. + /// ### What it does + /// Nothing. This lint has been deprecated. /// - /// **Deprecation reason:** This used to check for `Vec::as_slice`, which was unstable with good + /// ### Deprecation reason + /// This used to check for `Vec::as_slice`, which was unstable with good /// stable alternatives. `Vec::as_slice` has now been stabilized. pub UNSTABLE_AS_SLICE, "`Vec::as_slice` has been stabilized in 1.7" } declare_deprecated_lint! { - /// **What it does:** Nothing. This lint has been deprecated. + /// ### What it does + /// Nothing. This lint has been deprecated. /// - /// **Deprecation reason:** This used to check for `Vec::as_mut_slice`, which was unstable with good + /// ### Deprecation reason + /// This used to check for `Vec::as_mut_slice`, which was unstable with good /// stable alternatives. `Vec::as_mut_slice` has now been stabilized. pub UNSTABLE_AS_MUT_SLICE, "`Vec::as_mut_slice` has been stabilized in 1.7" } declare_deprecated_lint! { - /// **What it does:** Nothing. This lint has been deprecated. + /// ### What it does + /// Nothing. This lint has been deprecated. /// - /// **Deprecation reason:** This lint should never have applied to non-pointer types, as transmuting + /// ### Deprecation reason + /// This lint should never have applied to non-pointer types, as transmuting /// between non-pointer types of differing alignment is well-defined behavior (it's semantically /// equivalent to a memcpy). This lint has thus been refactored into two separate lints: /// cast_ptr_alignment and transmute_ptr_to_ptr. @@ -70,9 +82,11 @@ declare_deprecated_lint! { } declare_deprecated_lint! { - /// **What it does:** Nothing. This lint has been deprecated. + /// ### What it does + /// Nothing. This lint has been deprecated. /// - /// **Deprecation reason:** This lint is too subjective, not having a good reason for being in clippy. + /// ### Deprecation reason + /// This lint is too subjective, not having a good reason for being in clippy. /// Additionally, compound assignment operators may be overloaded separately from their non-assigning /// counterparts, so this lint may suggest a change in behavior or the code may not compile. pub ASSIGN_OPS, @@ -80,9 +94,11 @@ declare_deprecated_lint! { } declare_deprecated_lint! { - /// **What it does:** Nothing. This lint has been deprecated. + /// ### What it does + /// Nothing. This lint has been deprecated. /// - /// **Deprecation reason:** The original rule will only lint for `if let`. After + /// ### Deprecation reason + /// The original rule will only lint for `if let`. After /// making it support to lint `match`, naming as `if let` is not suitable for it. /// So, this lint is deprecated. pub IF_LET_REDUNDANT_PATTERN_MATCHING, @@ -90,9 +106,11 @@ declare_deprecated_lint! { } declare_deprecated_lint! { - /// **What it does:** Nothing. This lint has been deprecated. + /// ### What it does + /// Nothing. This lint has been deprecated. /// - /// **Deprecation reason:** This lint used to suggest replacing `let mut vec = + /// ### Deprecation reason + /// This lint used to suggest replacing `let mut vec = /// Vec::with_capacity(n); vec.set_len(n);` with `let vec = vec![0; n];`. The /// replacement has very different performance characteristics so the lint is /// deprecated. @@ -101,51 +119,63 @@ declare_deprecated_lint! { } declare_deprecated_lint! { - /// **What it does:** Nothing. This lint has been deprecated. + /// ### What it does + /// Nothing. This lint has been deprecated. /// - /// **Deprecation reason:** This lint has been superseded by #[must_use] in rustc. + /// ### Deprecation reason + /// This lint has been superseded by #[must_use] in rustc. pub UNUSED_COLLECT, "`collect` has been marked as #[must_use] in rustc and that covers all cases of this lint" } declare_deprecated_lint! { - /// **What it does:** Nothing. This lint has been deprecated. + /// ### What it does + /// Nothing. This lint has been deprecated. /// - /// **Deprecation reason:** Associated-constants are now preferred. + /// ### Deprecation reason + /// Associated-constants are now preferred. pub REPLACE_CONSTS, "associated-constants `MIN`/`MAX` of integers are preferred to `{min,max}_value()` and module constants" } declare_deprecated_lint! { - /// **What it does:** Nothing. This lint has been deprecated. + /// ### What it does + /// Nothing. This lint has been deprecated. /// - /// **Deprecation reason:** The regex! macro does not exist anymore. + /// ### Deprecation reason + /// The regex! macro does not exist anymore. pub REGEX_MACRO, "the regex! macro has been removed from the regex crate in 2018" } declare_deprecated_lint! { - /// **What it does:** Nothing. This lint has been deprecated. + /// ### What it does + /// Nothing. This lint has been deprecated. /// - /// **Deprecation reason:** This lint has been replaced by `manual_find_map`, a + /// ### Deprecation reason + /// This lint has been replaced by `manual_find_map`, a /// more specific lint. pub FIND_MAP, "this lint has been replaced by `manual_find_map`, a more specific lint" } declare_deprecated_lint! { - /// **What it does:** Nothing. This lint has been deprecated. + /// ### What it does + /// Nothing. This lint has been deprecated. /// - /// **Deprecation reason:** This lint has been replaced by `manual_filter_map`, a + /// ### Deprecation reason + /// This lint has been replaced by `manual_filter_map`, a /// more specific lint. pub FILTER_MAP, "this lint has been replaced by `manual_filter_map`, a more specific lint" } declare_deprecated_lint! { - /// **What it does:** Nothing. This lint has been deprecated. + /// ### What it does + /// Nothing. This lint has been deprecated. /// - /// **Deprecation reason:** The `avoid_breaking_exported_api` config option was added, which + /// ### Deprecation reason + /// The `avoid_breaking_exported_api` config option was added, which /// enables the `enum_variant_names` lint for public items. /// ``` pub PUB_ENUM_VARIANT_NAMES, @@ -153,9 +183,11 @@ declare_deprecated_lint! { } declare_deprecated_lint! { - /// **What it does:** Nothing. This lint has been deprecated. + /// ### What it does + /// Nothing. This lint has been deprecated. /// - /// **Deprecation reason:** The `avoid_breaking_exported_api` config option was added, which + /// ### Deprecation reason + /// The `avoid_breaking_exported_api` config option was added, which /// enables the `wrong_self_conversion` lint for public items. pub WRONG_PUB_SELF_CONVENTION, "set the `avoid-breaking-exported-api` config option to `false` to enable the `wrong_self_convention` lint for public items" diff --git a/clippy_lints/src/dereference.rs b/clippy_lints/src/dereference.rs index 682003f9c2c..ded7001ad8c 100644 --- a/clippy_lints/src/dereference.rs +++ b/clippy_lints/src/dereference.rs @@ -11,12 +11,14 @@ use rustc_session::{declare_tool_lint, impl_lint_pass}; use rustc_span::{symbol::sym, Span}; declare_clippy_lint! { - /// **What it does:** Checks for explicit `deref()` or `deref_mut()` method calls. + /// ### What it does + /// Checks for explicit `deref()` or `deref_mut()` method calls. /// - /// **Why is this bad?** Dereferencing by `&*x` or `&mut *x` is clearer and more concise, + /// ### Why is this bad? + /// Dereferencing by `&*x` or `&mut *x` is clearer and more concise, /// when not part of a method chain. /// - /// **Example:** + /// ### Example /// ```rust /// use std::ops::Deref; /// let a: &mut String = &mut String::from("foo"); diff --git a/clippy_lints/src/derive.rs b/clippy_lints/src/derive.rs index 7aafaf71383..dcfa5253f83 100644 --- a/clippy_lints/src/derive.rs +++ b/clippy_lints/src/derive.rs @@ -15,10 +15,12 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::source_map::Span; declare_clippy_lint! { - /// **What it does:** Checks for deriving `Hash` but implementing `PartialEq` + /// ### What it does + /// Checks for deriving `Hash` but implementing `PartialEq` /// explicitly or vice versa. /// - /// **Why is this bad?** The implementation of these traits must agree (for + /// ### Why is this bad? + /// The implementation of these traits must agree (for /// example for use with `HashMap`) so it’s probably a bad idea to use a /// default-generated `Hash` implementation with an explicitly defined /// `PartialEq`. In particular, the following must hold for any type: @@ -27,9 +29,7 @@ declare_clippy_lint! { /// k1 == k2 ⇒ hash(k1) == hash(k2) /// ``` /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```ignore /// #[derive(Hash)] /// struct Foo; @@ -44,10 +44,12 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for deriving `Ord` but implementing `PartialOrd` + /// ### What it does + /// Checks for deriving `Ord` but implementing `PartialOrd` /// explicitly or vice versa. /// - /// **Why is this bad?** The implementation of these traits must agree (for + /// ### Why is this bad? + /// The implementation of these traits must agree (for /// example for use with `sort`) so it’s probably a bad idea to use a /// default-generated `Ord` implementation with an explicitly defined /// `PartialOrd`. In particular, the following must hold for any type @@ -57,10 +59,7 @@ declare_clippy_lint! { /// k1.cmp(&k2) == k1.partial_cmp(&k2).unwrap() /// ``` /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust,ignore /// #[derive(Ord, PartialEq, Eq)] /// struct Foo; @@ -95,18 +94,21 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for explicit `Clone` implementations for `Copy` + /// ### What it does + /// Checks for explicit `Clone` implementations for `Copy` /// types. /// - /// **Why is this bad?** To avoid surprising behaviour, these traits should + /// ### Why is this bad? + /// To avoid surprising behaviour, these traits should /// agree and the behaviour of `Copy` cannot be overridden. In almost all /// situations a `Copy` type should have a `Clone` implementation that does /// nothing more than copy the object, which is what `#[derive(Copy, Clone)]` /// gets you. /// - /// **Known problems:** Bounds of generic types are sometimes wrong: https://github.com/rust-lang/rust/issues/26925 + /// ### Known problems + /// Bounds of generic types are sometimes wrong: https://github.com/rust-lang/rust/issues/26925 /// - /// **Example:** + /// ### Example /// ```rust,ignore /// #[derive(Copy)] /// struct Foo; @@ -121,16 +123,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for deriving `serde::Deserialize` on a type that + /// ### What it does + /// Checks for deriving `serde::Deserialize` on a type that /// has methods using `unsafe`. /// - /// **Why is this bad?** Deriving `serde::Deserialize` will create a constructor + /// ### Why is this bad? + /// Deriving `serde::Deserialize` will create a constructor /// that may violate invariants hold by another constructor. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust,ignore /// use serde::Deserialize; /// diff --git a/clippy_lints/src/disallowed_method.rs b/clippy_lints/src/disallowed_method.rs index aa1a609afed..7069cb4198c 100644 --- a/clippy_lints/src/disallowed_method.rs +++ b/clippy_lints/src/disallowed_method.rs @@ -8,15 +8,14 @@ use rustc_session::{declare_tool_lint, impl_lint_pass}; use rustc_span::Symbol; declare_clippy_lint! { - /// **What it does:** Denies the configured methods and functions in clippy.toml + /// ### What it does + /// Denies the configured methods and functions in clippy.toml /// - /// **Why is this bad?** Some methods are undesirable in certain contexts, + /// ### Why is this bad? + /// Some methods are undesirable in certain contexts, /// and it's beneficial to lint for them as needed. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// An example clippy.toml configuration: /// ```toml /// # clippy.toml diff --git a/clippy_lints/src/disallowed_script_idents.rs b/clippy_lints/src/disallowed_script_idents.rs index 12c525634c5..6d38d30cd0b 100644 --- a/clippy_lints/src/disallowed_script_idents.rs +++ b/clippy_lints/src/disallowed_script_idents.rs @@ -6,7 +6,8 @@ use rustc_session::{declare_tool_lint, impl_lint_pass}; use unicode_script::{Script, UnicodeScript}; declare_clippy_lint! { - /// **What it does:** Checks for usage of unicode scripts other than those explicitly allowed + /// ### What it does + /// Checks for usage of unicode scripts other than those explicitly allowed /// by the lint config. /// /// This lint doesn't take into account non-text scripts such as `Unknown` and `Linear_A`. @@ -19,7 +20,8 @@ declare_clippy_lint! { /// [aliases]: http://www.unicode.org/reports/tr24/tr24-31.html#Script_Value_Aliases /// [supported_scripts]: https://www.unicode.org/iso15924/iso15924-codes.html /// - /// **Why is this bad?** It may be not desired to have many different scripts for + /// ### Why is this bad? + /// It may be not desired to have many different scripts for /// identifiers in the codebase. /// /// Note that if you only want to allow plain English, you might want to use @@ -27,9 +29,7 @@ declare_clippy_lint! { /// /// [`non_ascii_idents`]: https://doc.rust-lang.org/rustc/lints/listing/allowed-by-default.html#non-ascii-idents /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// // Assuming that `clippy.toml` contains the following line: /// // allowed-locales = ["Latin", "Cyrillic"] diff --git a/clippy_lints/src/disallowed_type.rs b/clippy_lints/src/disallowed_type.rs index 7c76e2322c2..e627168b932 100644 --- a/clippy_lints/src/disallowed_type.rs +++ b/clippy_lints/src/disallowed_type.rs @@ -9,14 +9,13 @@ use rustc_session::{declare_tool_lint, impl_lint_pass}; use rustc_span::{Span, Symbol}; declare_clippy_lint! { - /// **What it does:** Denies the configured types in clippy.toml. + /// ### What it does + /// Denies the configured types in clippy.toml. /// - /// **Why is this bad?** Some types are undesirable in certain contexts. - /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Why is this bad? + /// Some types are undesirable in certain contexts. /// + /// ### Example: /// An example clippy.toml configuration: /// ```toml /// # clippy.toml diff --git a/clippy_lints/src/doc.rs b/clippy_lints/src/doc.rs index 0c19988a975..c39829fdc7a 100644 --- a/clippy_lints/src/doc.rs +++ b/clippy_lints/src/doc.rs @@ -30,15 +30,18 @@ use std::thread; use url::Url; declare_clippy_lint! { - /// **What it does:** Checks for the presence of `_`, `::` or camel-case words + /// ### What it does + /// Checks for the presence of `_`, `::` or camel-case words /// outside ticks in documentation. /// - /// **Why is this bad?** *Rustdoc* supports markdown formatting, `_`, `::` and + /// ### Why is this bad? + /// *Rustdoc* supports markdown formatting, `_`, `::` and /// camel-case probably indicates some code which should be included between /// ticks. `_` can also be used for emphasis in markdown, this lint tries to /// consider that. /// - /// **Known problems:** Lots of bad docs won’t be fixed, what the lint checks + /// ### Known problems + /// Lots of bad docs won’t be fixed, what the lint checks /// for is limited, and there are still false positives. HTML elements and their /// content are not linted. /// @@ -47,7 +50,7 @@ declare_clippy_lint! { /// `[`SmallVec<[T; INLINE_CAPACITY]>`]` and then [`SmallVec<[T; INLINE_CAPACITY]>`]: SmallVec /// would fail. /// - /// **Examples:** + /// ### Examples /// ```rust /// /// Do something with the foo_bar parameter. See also /// /// that::other::module::foo. @@ -68,15 +71,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for the doc comments of publicly visible + /// ### What it does + /// Checks for the doc comments of publicly visible /// unsafe functions and warns if there is no `# Safety` section. /// - /// **Why is this bad?** Unsafe functions should document their safety + /// ### Why is this bad? + /// Unsafe functions should document their safety /// preconditions, so that users can be sure they are using them safely. /// - /// **Known problems:** None. - /// - /// **Examples:** + /// ### Examples /// ```rust ///# type Universe = (); /// /// This function should really be documented @@ -102,16 +105,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks the doc comments of publicly visible functions that + /// ### What it does + /// Checks the doc comments of publicly visible functions that /// return a `Result` type and warns if there is no `# Errors` section. /// - /// **Why is this bad?** Documenting the type of errors that can be returned from a + /// ### Why is this bad? + /// Documenting the type of errors that can be returned from a /// function can help callers write code to handle the errors appropriately. /// - /// **Known problems:** None. - /// - /// **Examples:** - /// + /// ### Examples /// Since the following function returns a `Result` it has an `# Errors` section in /// its doc comment: /// @@ -131,16 +133,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks the doc comments of publicly visible functions that + /// ### What it does + /// Checks the doc comments of publicly visible functions that /// may panic and warns if there is no `# Panics` section. /// - /// **Why is this bad?** Documenting the scenarios in which panicking occurs + /// ### Why is this bad? + /// Documenting the scenarios in which panicking occurs /// can help callers who do not want to panic to avoid those situations. /// - /// **Known problems:** None. - /// - /// **Examples:** - /// + /// ### Examples /// Since the following function may panic it has a `# Panics` section in /// its doc comment: /// @@ -162,14 +163,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for `fn main() { .. }` in doctests + /// ### What it does + /// Checks for `fn main() { .. }` in doctests /// - /// **Why is this bad?** The test can be shorter (and likely more readable) + /// ### Why is this bad? + /// The test can be shorter (and likely more readable) /// if the `fn main()` is left implicit. /// - /// **Known problems:** None. - /// - /// **Examples:** + /// ### Examples /// ``````rust /// /// An example of a doctest with a `main()` function /// /// diff --git a/clippy_lints/src/double_comparison.rs b/clippy_lints/src/double_comparison.rs index 4966638cb1b..6520bb91faf 100644 --- a/clippy_lints/src/double_comparison.rs +++ b/clippy_lints/src/double_comparison.rs @@ -10,14 +10,14 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::source_map::Span; declare_clippy_lint! { - /// **What it does:** Checks for double comparisons that could be simplified to a single expression. + /// ### What it does + /// Checks for double comparisons that could be simplified to a single expression. /// /// - /// **Why is this bad?** Readability. + /// ### Why is this bad? + /// Readability. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// # let x = 1; /// # let y = 2; diff --git a/clippy_lints/src/double_parens.rs b/clippy_lints/src/double_parens.rs index e4e4a93b011..d0d87b6df9a 100644 --- a/clippy_lints/src/double_parens.rs +++ b/clippy_lints/src/double_parens.rs @@ -4,14 +4,14 @@ use rustc_lint::{EarlyContext, EarlyLintPass}; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks for unnecessary double parentheses. + /// ### What it does + /// Checks for unnecessary double parentheses. /// - /// **Why is this bad?** This makes code harder to read and might indicate a + /// ### Why is this bad? + /// This makes code harder to read and might indicate a /// mistake. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// // Bad /// fn simple_double_parens() -> i32 { diff --git a/clippy_lints/src/drop_forget_ref.rs b/clippy_lints/src/drop_forget_ref.rs index b5b29760636..0f3dc866afb 100644 --- a/clippy_lints/src/drop_forget_ref.rs +++ b/clippy_lints/src/drop_forget_ref.rs @@ -8,17 +8,17 @@ use rustc_middle::ty; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks for calls to `std::mem::drop` with a reference + /// ### What it does + /// Checks for calls to `std::mem::drop` with a reference /// instead of an owned value. /// - /// **Why is this bad?** Calling `drop` on a reference will only drop the + /// ### Why is this bad? + /// Calling `drop` on a reference will only drop the /// reference itself, which is a no-op. It will not call the `drop` method (from /// the `Drop` trait implementation) on the underlying referenced value, which /// is likely what was intended. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```ignore /// let mut lock_guard = mutex.lock(); /// std::mem::drop(&lock_guard) // Should have been drop(lock_guard), mutex @@ -31,17 +31,17 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for calls to `std::mem::forget` with a reference + /// ### What it does + /// Checks for calls to `std::mem::forget` with a reference /// instead of an owned value. /// - /// **Why is this bad?** Calling `forget` on a reference will only forget the + /// ### Why is this bad? + /// Calling `forget` on a reference will only forget the /// reference itself, which is a no-op. It will not forget the underlying /// referenced /// value, which is likely what was intended. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// let x = Box::new(1); /// std::mem::forget(&x) // Should have been forget(x), x will still be dropped @@ -52,16 +52,16 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for calls to `std::mem::drop` with a value + /// ### What it does + /// Checks for calls to `std::mem::drop` with a value /// that derives the Copy trait /// - /// **Why is this bad?** Calling `std::mem::drop` [does nothing for types that + /// ### Why is this bad? + /// Calling `std::mem::drop` [does nothing for types that /// implement Copy](https://doc.rust-lang.org/std/mem/fn.drop.html), since the /// value will be copied and moved into the function on invocation. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// let x: i32 = 42; // i32 implements Copy /// std::mem::drop(x) // A copy of x is passed to the function, leaving the @@ -73,10 +73,12 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for calls to `std::mem::forget` with a value that + /// ### What it does + /// Checks for calls to `std::mem::forget` with a value that /// derives the Copy trait /// - /// **Why is this bad?** Calling `std::mem::forget` [does nothing for types that + /// ### Why is this bad? + /// Calling `std::mem::forget` [does nothing for types that /// implement Copy](https://doc.rust-lang.org/std/mem/fn.drop.html) since the /// value will be copied and moved into the function on invocation. /// @@ -86,9 +88,7 @@ declare_clippy_lint! { /// there /// is nothing for `std::mem::forget` to ignore. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// let x: i32 = 42; // i32 implements Copy /// std::mem::forget(x) // A copy of x is passed to the function, leaving the diff --git a/clippy_lints/src/duration_subsec.rs b/clippy_lints/src/duration_subsec.rs index 94b09bf7173..3774de62521 100644 --- a/clippy_lints/src/duration_subsec.rs +++ b/clippy_lints/src/duration_subsec.rs @@ -12,15 +12,15 @@ use clippy_utils::diagnostics::span_lint_and_sugg; use clippy_utils::paths; declare_clippy_lint! { - /// **What it does:** Checks for calculation of subsecond microseconds or milliseconds + /// ### What it does + /// Checks for calculation of subsecond microseconds or milliseconds /// from other `Duration` methods. /// - /// **Why is this bad?** It's more concise to call `Duration::subsec_micros()` or + /// ### Why is this bad? + /// It's more concise to call `Duration::subsec_micros()` or /// `Duration::subsec_millis()` than to calculate them. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// # use std::time::Duration; /// let dur = Duration::new(5, 0); diff --git a/clippy_lints/src/else_if_without_else.rs b/clippy_lints/src/else_if_without_else.rs index 26984df9539..0541ac5eccc 100644 --- a/clippy_lints/src/else_if_without_else.rs +++ b/clippy_lints/src/else_if_without_else.rs @@ -7,14 +7,14 @@ use rustc_middle::lint::in_external_macro; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks for usage of if expressions with an `else if` branch, + /// ### What it does + /// Checks for usage of if expressions with an `else if` branch, /// but without a final `else` branch. /// - /// **Why is this bad?** Some coding guidelines require this (e.g., MISRA-C:2004 Rule 14.10). + /// ### Why is this bad? + /// Some coding guidelines require this (e.g., MISRA-C:2004 Rule 14.10). /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// # fn a() {} /// # fn b() {} diff --git a/clippy_lints/src/empty_enum.rs b/clippy_lints/src/empty_enum.rs index c92984a9834..3453c2da278 100644 --- a/clippy_lints/src/empty_enum.rs +++ b/clippy_lints/src/empty_enum.rs @@ -6,13 +6,15 @@ use rustc_lint::{LateContext, LateLintPass}; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks for `enum`s with no variants. + /// ### What it does + /// Checks for `enum`s with no variants. /// /// As of this writing, the `never_type` is still a /// nightly-only experimental API. Therefore, this lint is only triggered /// if the `never_type` is enabled. /// - /// **Why is this bad?** If you want to introduce a type which + /// ### Why is this bad? + /// If you want to introduce a type which /// can't be instantiated, you should use `!` (the primitive type "never"), /// or a wrapper around it, because `!` has more extensive /// compiler support (type inference, etc...) and wrappers @@ -20,10 +22,7 @@ declare_clippy_lint! { /// For further information visit [never type documentation](https://doc.rust-lang.org/std/primitive.never.html) /// /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// Bad: /// ```rust /// enum Test {} diff --git a/clippy_lints/src/entry.rs b/clippy_lints/src/entry.rs index 2eb8b1422ed..e1d0d65edb1 100644 --- a/clippy_lints/src/entry.rs +++ b/clippy_lints/src/entry.rs @@ -16,12 +16,15 @@ use rustc_span::{Span, SyntaxContext, DUMMY_SP}; use std::fmt::Write; declare_clippy_lint! { - /// **What it does:** Checks for uses of `contains_key` + `insert` on `HashMap` + /// ### What it does + /// Checks for uses of `contains_key` + `insert` on `HashMap` /// or `BTreeMap`. /// - /// **Why is this bad?** Using `entry` is more efficient. + /// ### Why is this bad? + /// Using `entry` is more efficient. /// - /// **Known problems:** The suggestion may have type inference errors in some cases. e.g. + /// ### Known problems + /// The suggestion may have type inference errors in some cases. e.g. /// ```rust /// let mut map = std::collections::HashMap::new(); /// let _ = if !map.contains_key(&0) { @@ -31,7 +34,7 @@ declare_clippy_lint! { /// }; /// ``` /// - /// **Example:** + /// ### Example /// ```rust /// # use std::collections::HashMap; /// # let mut map = HashMap::new(); diff --git a/clippy_lints/src/enum_clike.rs b/clippy_lints/src/enum_clike.rs index 021136ac5e0..a2c3c7a7b49 100644 --- a/clippy_lints/src/enum_clike.rs +++ b/clippy_lints/src/enum_clike.rs @@ -11,15 +11,15 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use std::convert::TryFrom; declare_clippy_lint! { - /// **What it does:** Checks for C-like enumerations that are + /// ### What it does + /// Checks for C-like enumerations that are /// `repr(isize/usize)` and have values that don't fit into an `i32`. /// - /// **Why is this bad?** This will truncate the variant value on 32 bit + /// ### Why is this bad? + /// This will truncate the variant value on 32 bit /// architectures, but works fine on 64 bit. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// # #[cfg(target_pointer_width = "64")] /// #[repr(usize)] diff --git a/clippy_lints/src/enum_variants.rs b/clippy_lints/src/enum_variants.rs index b1a105a51c1..32b95745b64 100644 --- a/clippy_lints/src/enum_variants.rs +++ b/clippy_lints/src/enum_variants.rs @@ -10,15 +10,15 @@ use rustc_span::source_map::Span; use rustc_span::symbol::Symbol; declare_clippy_lint! { - /// **What it does:** Detects enumeration variants that are prefixed or suffixed + /// ### What it does + /// Detects enumeration variants that are prefixed or suffixed /// by the same characters. /// - /// **Why is this bad?** Enumeration variant names should specify their variant, + /// ### Why is this bad? + /// Enumeration variant names should specify their variant, /// not repeat the enumeration name. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// enum Cake { /// BlackForestCake, @@ -40,14 +40,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Detects type names that are prefixed or suffixed by the + /// ### What it does + /// Detects type names that are prefixed or suffixed by the /// containing module's name. /// - /// **Why is this bad?** It requires the user to type the module name twice. - /// - /// **Known problems:** None. + /// ### Why is this bad? + /// It requires the user to type the module name twice. /// - /// **Example:** + /// ### Example /// ```rust /// mod cake { /// struct BlackForestCake; @@ -65,10 +65,12 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for modules that have the same name as their + /// ### What it does + /// Checks for modules that have the same name as their /// parent module /// - /// **Why is this bad?** A typical beginner mistake is to have `mod foo;` and + /// ### Why is this bad? + /// A typical beginner mistake is to have `mod foo;` and /// again `mod foo { .. /// }` in `foo.rs`. /// The expectation is that items inside the inner `mod foo { .. }` are then @@ -78,9 +80,7 @@ declare_clippy_lint! { /// If this is done on purpose, it would be better to choose a more /// representative module name. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```ignore /// // lib.rs /// mod foo; diff --git a/clippy_lints/src/eq_op.rs b/clippy_lints/src/eq_op.rs index d39cabfb282..51d5094e8c9 100644 --- a/clippy_lints/src/eq_op.rs +++ b/clippy_lints/src/eq_op.rs @@ -9,18 +9,21 @@ use rustc_lint::{LateContext, LateLintPass}; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks for equal operands to comparison, logical and + /// ### What it does + /// Checks for equal operands to comparison, logical and /// bitwise, difference and division binary operators (`==`, `>`, etc., `&&`, /// `||`, `&`, `|`, `^`, `-` and `/`). /// - /// **Why is this bad?** This is usually just a typo or a copy and paste error. + /// ### Why is this bad? + /// This is usually just a typo or a copy and paste error. /// - /// **Known problems:** False negatives: We had some false positives regarding + /// ### Known problems + /// False negatives: We had some false positives regarding /// calls (notably [racer](https://github.com/phildawes/racer) had one instance /// of `x.pop() && x.pop()`), so we removed matching any function or method /// calls. We may introduce a list of known pure functions in the future. /// - /// **Example:** + /// ### Example /// ```rust /// # let x = 1; /// if x + 1 == x + 1 {} @@ -37,15 +40,18 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for arguments to `==` which have their address + /// ### What it does + /// Checks for arguments to `==` which have their address /// taken to satisfy a bound /// and suggests to dereference the other argument instead /// - /// **Why is this bad?** It is more idiomatic to dereference the other argument. + /// ### Why is this bad? + /// It is more idiomatic to dereference the other argument. /// - /// **Known problems:** None + /// ### Known problems + /// None /// - /// **Example:** + /// ### Example /// ```ignore /// // Bad /// &x == y diff --git a/clippy_lints/src/erasing_op.rs b/clippy_lints/src/erasing_op.rs index 4aa9c25b1b0..026d14d0ea2 100644 --- a/clippy_lints/src/erasing_op.rs +++ b/clippy_lints/src/erasing_op.rs @@ -6,15 +6,15 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::source_map::Span; declare_clippy_lint! { - /// **What it does:** Checks for erasing operations, e.g., `x * 0`. + /// ### What it does + /// Checks for erasing operations, e.g., `x * 0`. /// - /// **Why is this bad?** The whole expression can be replaced by zero. + /// ### Why is this bad? + /// The whole expression can be replaced by zero. /// This is most likely not the intended outcome and should probably be /// corrected /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// let x = 1; /// 0 / x; diff --git a/clippy_lints/src/escape.rs b/clippy_lints/src/escape.rs index 5f400d079da..8b0e9e6bc9b 100644 --- a/clippy_lints/src/escape.rs +++ b/clippy_lints/src/escape.rs @@ -19,16 +19,16 @@ pub struct BoxedLocal { } declare_clippy_lint! { - /// **What it does:** Checks for usage of `Box` where an unboxed `T` would + /// ### What it does + /// Checks for usage of `Box` where an unboxed `T` would /// work fine. /// - /// **Why is this bad?** This is an unnecessary allocation, and bad for + /// ### Why is this bad? + /// This is an unnecessary allocation, and bad for /// performance. It is only necessary to allocate if you wish to move the box /// into something. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// # fn foo(bar: usize) {} /// // Bad diff --git a/clippy_lints/src/eta_reduction.rs b/clippy_lints/src/eta_reduction.rs index 667eb8eb283..192b69e18f9 100644 --- a/clippy_lints/src/eta_reduction.rs +++ b/clippy_lints/src/eta_reduction.rs @@ -14,19 +14,22 @@ use rustc_middle::ty::{self, ClosureKind, Ty}; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks for closures which just call another function where + /// ### What it does + /// Checks for closures which just call another function where /// the function can be called directly. `unsafe` functions or calls where types /// get adjusted are ignored. /// - /// **Why is this bad?** Needlessly creating a closure adds code for no benefit + /// ### Why is this bad? + /// Needlessly creating a closure adds code for no benefit /// and gives the optimizer more work. /// - /// **Known problems:** If creating the closure inside the closure has a side- + /// ### Known problems + /// If creating the closure inside the closure has a side- /// effect then moving the closure creation out will change when that side- /// effect runs. /// See [#1439](https://github.com/rust-lang/rust-clippy/issues/1439) for more details. /// - /// **Example:** + /// ### Example /// ```rust,ignore /// // Bad /// xs.map(|x| foo(x)) @@ -42,17 +45,20 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for closures which only invoke a method on the closure + /// ### What it does + /// Checks for closures which only invoke a method on the closure /// argument and can be replaced by referencing the method directly. /// - /// **Why is this bad?** It's unnecessary to create the closure. + /// ### Why is this bad? + /// It's unnecessary to create the closure. /// - /// **Known problems:** [#3071](https://github.com/rust-lang/rust-clippy/issues/3071), + /// ### Known problems + /// [#3071](https://github.com/rust-lang/rust-clippy/issues/3071), /// [#3942](https://github.com/rust-lang/rust-clippy/issues/3942), /// [#4002](https://github.com/rust-lang/rust-clippy/issues/4002) /// /// - /// **Example:** + /// ### Example /// ```rust,ignore /// Some('a').map(|s| s.to_uppercase()); /// ``` diff --git a/clippy_lints/src/eval_order_dependence.rs b/clippy_lints/src/eval_order_dependence.rs index 03a8b40df55..f72a1e446d5 100644 --- a/clippy_lints/src/eval_order_dependence.rs +++ b/clippy_lints/src/eval_order_dependence.rs @@ -9,17 +9,20 @@ use rustc_middle::ty; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks for a read and a write to the same variable where + /// ### What it does + /// Checks for a read and a write to the same variable where /// whether the read occurs before or after the write depends on the evaluation /// order of sub-expressions. /// - /// **Why is this bad?** It is often confusing to read. In addition, the + /// ### Why is this bad? + /// It is often confusing to read. In addition, the /// sub-expression evaluation order for Rust is not well documented. /// - /// **Known problems:** Code which intentionally depends on the evaluation + /// ### Known problems + /// Code which intentionally depends on the evaluation /// order, or which is correct for any evaluation order. /// - /// **Example:** + /// ### Example /// ```rust /// let mut x = 0; /// @@ -43,16 +46,19 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for diverging calls that are not match arms or + /// ### What it does + /// Checks for diverging calls that are not match arms or /// statements. /// - /// **Why is this bad?** It is often confusing to read. In addition, the + /// ### Why is this bad? + /// It is often confusing to read. In addition, the /// sub-expression evaluation order for Rust is not well documented. /// - /// **Known problems:** Someone might want to use `some_bool || panic!()` as a + /// ### Known problems + /// Someone might want to use `some_bool || panic!()` as a /// shorthand. /// - /// **Example:** + /// ### Example /// ```rust,no_run /// # fn b() -> bool { true } /// # fn c() -> bool { true } diff --git a/clippy_lints/src/excessive_bools.rs b/clippy_lints/src/excessive_bools.rs index 4e2dbf005d5..476e6d23f12 100644 --- a/clippy_lints/src/excessive_bools.rs +++ b/clippy_lints/src/excessive_bools.rs @@ -8,19 +8,19 @@ use rustc_span::{sym, Span}; use std::convert::TryInto; declare_clippy_lint! { - /// **What it does:** Checks for excessive + /// ### What it does + /// Checks for excessive /// use of bools in structs. /// - /// **Why is this bad?** Excessive bools in a struct + /// ### Why is this bad? + /// Excessive bools in a struct /// is often a sign that it's used as a state machine, /// which is much better implemented as an enum. /// If it's not the case, excessive bools usually benefit /// from refactoring into two-variant enums for better /// readability and API. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// Bad: /// ```rust /// struct S { @@ -44,19 +44,19 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for excessive use of + /// ### What it does + /// Checks for excessive use of /// bools in function definitions. /// - /// **Why is this bad?** Calls to such functions + /// ### Why is this bad? + /// Calls to such functions /// are confusing and error prone, because it's /// hard to remember argument order and you have /// no type system support to back you up. Using /// two-variant enums instead of bools often makes /// API easier to use. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// Bad: /// ```rust,ignore /// fn f(is_round: bool, is_hot: bool) { ... } diff --git a/clippy_lints/src/exhaustive_items.rs b/clippy_lints/src/exhaustive_items.rs index 60ad2e8ee14..e00126046c0 100644 --- a/clippy_lints/src/exhaustive_items.rs +++ b/clippy_lints/src/exhaustive_items.rs @@ -8,16 +8,15 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::sym; declare_clippy_lint! { - /// **What it does:** Warns on any exported `enum`s that are not tagged `#[non_exhaustive]` + /// ### What it does + /// Warns on any exported `enum`s that are not tagged `#[non_exhaustive]` /// - /// **Why is this bad?** Exhaustive enums are typically fine, but a project which does + /// ### Why is this bad? + /// Exhaustive enums are typically fine, but a project which does /// not wish to make a stability commitment around exported enums may wish to /// disable them by default. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust /// enum Foo { /// Bar, @@ -38,16 +37,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Warns on any exported `structs`s that are not tagged `#[non_exhaustive]` + /// ### What it does + /// Warns on any exported `structs`s that are not tagged `#[non_exhaustive]` /// - /// **Why is this bad?** Exhaustive structs are typically fine, but a project which does + /// ### Why is this bad? + /// Exhaustive structs are typically fine, but a project which does /// not wish to make a stability commitment around exported structs may wish to /// disable them by default. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust /// struct Foo { /// bar: u8, diff --git a/clippy_lints/src/exit.rs b/clippy_lints/src/exit.rs index 16246e548b6..9cd5b2d9f44 100644 --- a/clippy_lints/src/exit.rs +++ b/clippy_lints/src/exit.rs @@ -6,15 +6,15 @@ use rustc_lint::{LateContext, LateLintPass}; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** `exit()` terminates the program and doesn't provide a + /// ### What it does + /// `exit()` terminates the program and doesn't provide a /// stack trace. /// - /// **Why is this bad?** Ideally a program is terminated by finishing + /// ### Why is this bad? + /// Ideally a program is terminated by finishing /// the main function. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```ignore /// std::process::exit(0) /// ``` diff --git a/clippy_lints/src/explicit_write.rs b/clippy_lints/src/explicit_write.rs index 66724294804..4f46ef906f4 100644 --- a/clippy_lints/src/explicit_write.rs +++ b/clippy_lints/src/explicit_write.rs @@ -9,14 +9,14 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::sym; declare_clippy_lint! { - /// **What it does:** Checks for usage of `write!()` / `writeln()!` which can be + /// ### What it does + /// Checks for usage of `write!()` / `writeln()!` which can be /// replaced with `(e)print!()` / `(e)println!()` /// - /// **Why is this bad?** Using `(e)println! is clearer and more concise + /// ### Why is this bad? + /// Using `(e)println! is clearer and more concise /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// # use std::io::Write; /// # let bar = "furchtbar"; diff --git a/clippy_lints/src/fallible_impl_from.rs b/clippy_lints/src/fallible_impl_from.rs index 2937fcb9ca0..7e4d1b3ef9f 100644 --- a/clippy_lints/src/fallible_impl_from.rs +++ b/clippy_lints/src/fallible_impl_from.rs @@ -10,13 +10,13 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::{sym, Span}; declare_clippy_lint! { - /// **What it does:** Checks for impls of `From<..>` that contain `panic!()` or `unwrap()` + /// ### What it does + /// Checks for impls of `From<..>` that contain `panic!()` or `unwrap()` /// - /// **Why is this bad?** `TryFrom` should be used if there's a possibility of failure. + /// ### Why is this bad? + /// `TryFrom` should be used if there's a possibility of failure. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// struct Foo(i32); /// diff --git a/clippy_lints/src/float_equality_without_abs.rs b/clippy_lints/src/float_equality_without_abs.rs index 1e503cc795c..c33d80b8e8e 100644 --- a/clippy_lints/src/float_equality_without_abs.rs +++ b/clippy_lints/src/float_equality_without_abs.rs @@ -11,30 +11,32 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::source_map::Spanned; declare_clippy_lint! { - /// **What it does:** Checks for statements of the form `(a - b) < f32::EPSILON` or - /// `(a - b) < f64::EPSILON`. Notes the missing `.abs()`. - /// - /// **Why is this bad?** The code without `.abs()` is more likely to have a bug. - /// - /// **Known problems:** If the user can ensure that b is larger than a, the `.abs()` is - /// technically unneccessary. However, it will make the code more robust and doesn't have any - /// large performance implications. If the abs call was deliberately left out for performance - /// reasons, it is probably better to state this explicitly in the code, which then can be done - /// with an allow. - /// - /// **Example:** - /// - /// ```rust - /// pub fn is_roughly_equal(a: f32, b: f32) -> bool { - /// (a - b) < f32::EPSILON - /// } - /// ``` - /// Use instead: - /// ```rust - /// pub fn is_roughly_equal(a: f32, b: f32) -> bool { - /// (a - b).abs() < f32::EPSILON - /// } - /// ``` + /// ### What it does + /// Checks for statements of the form `(a - b) < f32::EPSILON` or + /// `(a - b) < f64::EPSILON`. Notes the missing `.abs()`. + /// + /// ### Why is this bad? + /// The code without `.abs()` is more likely to have a bug. + /// + /// ### Known problems + /// If the user can ensure that b is larger than a, the `.abs()` is + /// technically unneccessary. However, it will make the code more robust and doesn't have any + /// large performance implications. If the abs call was deliberately left out for performance + /// reasons, it is probably better to state this explicitly in the code, which then can be done + /// with an allow. + /// + /// ### Example + /// ```rust + /// pub fn is_roughly_equal(a: f32, b: f32) -> bool { + /// (a - b) < f32::EPSILON + /// } + /// ``` + /// Use instead: + /// ```rust + /// pub fn is_roughly_equal(a: f32, b: f32) -> bool { + /// (a - b).abs() < f32::EPSILON + /// } + /// ``` pub FLOAT_EQUALITY_WITHOUT_ABS, suspicious, "float equality check without `.abs()`" diff --git a/clippy_lints/src/float_literal.rs b/clippy_lints/src/float_literal.rs index 7968e7b764d..a3d70f31f00 100644 --- a/clippy_lints/src/float_literal.rs +++ b/clippy_lints/src/float_literal.rs @@ -10,15 +10,14 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use std::fmt; declare_clippy_lint! { - /// **What it does:** Checks for float literals with a precision greater + /// ### What it does + /// Checks for float literals with a precision greater /// than that supported by the underlying type. /// - /// **Why is this bad?** Rust will truncate the literal silently. - /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Why is this bad? + /// Rust will truncate the literal silently. /// + /// ### Example /// ```rust /// // Bad /// let v: f32 = 0.123_456_789_9; @@ -34,16 +33,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for whole number float literals that + /// ### What it does + /// Checks for whole number float literals that /// cannot be represented as the underlying type without loss. /// - /// **Why is this bad?** Rust will silently lose precision during + /// ### Why is this bad? + /// Rust will silently lose precision during /// conversion to a float. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust /// // Bad /// let _: f32 = 16_777_217.0; // 16_777_216.0 diff --git a/clippy_lints/src/floating_point_arithmetic.rs b/clippy_lints/src/floating_point_arithmetic.rs index e38384b01d4..b01c0cdd846 100644 --- a/clippy_lints/src/floating_point_arithmetic.rs +++ b/clippy_lints/src/floating_point_arithmetic.rs @@ -18,16 +18,15 @@ use std::f64::consts as f64_consts; use sugg::Sugg; declare_clippy_lint! { - /// **What it does:** Looks for floating-point expressions that + /// ### What it does + /// Looks for floating-point expressions that /// can be expressed using built-in methods to improve accuracy /// at the cost of performance. /// - /// **Why is this bad?** Negatively impacts accuracy. - /// - /// **Known problems:** None - /// - /// **Example:** + /// ### Why is this bad? + /// Negatively impacts accuracy. /// + /// ### Example /// ```rust /// let a = 3f32; /// let _ = a.powf(1.0 / 3.0); @@ -49,16 +48,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Looks for floating-point expressions that + /// ### What it does + /// Looks for floating-point expressions that /// can be expressed using built-in methods to improve both /// accuracy and performance. /// - /// **Why is this bad?** Negatively impacts accuracy and performance. - /// - /// **Known problems:** None - /// - /// **Example:** + /// ### Why is this bad? + /// Negatively impacts accuracy and performance. /// + /// ### Example /// ```rust /// use std::f32::consts::E; /// diff --git a/clippy_lints/src/format.rs b/clippy_lints/src/format.rs index ca3490d8eda..863c606f5a9 100644 --- a/clippy_lints/src/format.rs +++ b/clippy_lints/src/format.rs @@ -13,18 +13,18 @@ use rustc_span::symbol::kw; use rustc_span::{sym, Span}; declare_clippy_lint! { - /// **What it does:** Checks for the use of `format!("string literal with no + /// ### What it does + /// Checks for the use of `format!("string literal with no /// argument")` and `format!("{}", foo)` where `foo` is a string. /// - /// **Why is this bad?** There is no point of doing that. `format!("foo")` can + /// ### Why is this bad? + /// There is no point of doing that. `format!("foo")` can /// be replaced by `"foo".to_owned()` if you really need a `String`. The even /// worse `&format!("foo")` is often encountered in the wild. `format!("{}", /// foo)` can be replaced by `foo.clone()` if `foo: String` or `foo.to_owned()` /// if `foo: &str`. /// - /// **Known problems:** None. - /// - /// **Examples:** + /// ### Examples /// ```rust /// /// // Bad diff --git a/clippy_lints/src/formatting.rs b/clippy_lints/src/formatting.rs index 8aefb8d46f6..b4cf1971d78 100644 --- a/clippy_lints/src/formatting.rs +++ b/clippy_lints/src/formatting.rs @@ -9,15 +9,15 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::source_map::Span; declare_clippy_lint! { - /// **What it does:** Checks for use of the non-existent `=*`, `=!` and `=-` + /// ### What it does + /// Checks for use of the non-existent `=*`, `=!` and `=-` /// operators. /// - /// **Why is this bad?** This is either a typo of `*=`, `!=` or `-=` or + /// ### Why is this bad? + /// This is either a typo of `*=`, `!=` or `-=` or /// confusing. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust,ignore /// a =- 42; // confusing, should it be `a -= 42` or `a = -42`? /// ``` @@ -27,15 +27,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks the formatting of a unary operator on the right hand side + /// ### What it does + /// Checks the formatting of a unary operator on the right hand side /// of a binary operator. It lints if there is no space between the binary and unary operators, /// but there is a space between the unary and its operand. /// - /// **Why is this bad?** This is either a typo in the binary operator or confusing. - /// - /// **Known problems:** None. + /// ### Why is this bad? + /// This is either a typo in the binary operator or confusing. /// - /// **Example:** + /// ### Example /// ```rust,ignore /// if foo <- 30 { // this should be `foo < -30` but looks like a different operator /// } @@ -49,15 +49,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for formatting of `else`. It lints if the `else` + /// ### What it does + /// Checks for formatting of `else`. It lints if the `else` /// is followed immediately by a newline or the `else` seems to be missing. /// - /// **Why is this bad?** This is probably some refactoring remnant, even if the + /// ### Why is this bad? + /// This is probably some refactoring remnant, even if the /// code is correct, it might look confusing. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust,ignore /// if foo { /// } { // looks like an `else` is missing here @@ -85,14 +85,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for possible missing comma in an array. It lints if + /// ### What it does + /// Checks for possible missing comma in an array. It lints if /// an array element is a binary operator expression and it lies on two lines. /// - /// **Why is this bad?** This could lead to unexpected results. - /// - /// **Known problems:** None. + /// ### Why is this bad? + /// This could lead to unexpected results. /// - /// **Example:** + /// ### Example /// ```rust,ignore /// let a = &[ /// -1, -2, -3 // <= no comma here diff --git a/clippy_lints/src/from_over_into.rs b/clippy_lints/src/from_over_into.rs index 48316c3a61d..623546cd1de 100644 --- a/clippy_lints/src/from_over_into.rs +++ b/clippy_lints/src/from_over_into.rs @@ -8,14 +8,13 @@ use rustc_session::{declare_tool_lint, impl_lint_pass}; use rustc_span::symbol::sym; declare_clippy_lint! { - /// **What it does:** Searches for implementations of the `Into<..>` trait and suggests to implement `From<..>` instead. + /// ### What it does + /// Searches for implementations of the `Into<..>` trait and suggests to implement `From<..>` instead. /// - /// **Why is this bad?** According the std docs implementing `From<..>` is preferred since it gives you `Into<..>` for free where the reverse isn't true. - /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Why is this bad? + /// According the std docs implementing `From<..>` is preferred since it gives you `Into<..>` for free where the reverse isn't true. /// + /// ### Example /// ```rust /// struct StringWrapper(String); /// diff --git a/clippy_lints/src/from_str_radix_10.rs b/clippy_lints/src/from_str_radix_10.rs index 3da5bc95b6d..cc4bb85c50f 100644 --- a/clippy_lints/src/from_str_radix_10.rs +++ b/clippy_lints/src/from_str_radix_10.rs @@ -10,20 +10,22 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::symbol::sym; declare_clippy_lint! { - /// **What it does:** + /// ### What it does + /// /// Checks for function invocations of the form `primitive::from_str_radix(s, 10)` /// - /// **Why is this bad?** + /// ### Why is this bad? + /// /// This specific common use case can be rewritten as `s.parse::()` /// (and in most cases, the turbofish can be removed), which reduces code length /// and complexity. /// - /// **Known problems:** + /// ### Known problems + /// /// This lint may suggest using (&).parse() instead of .parse() directly /// in some cases, which is correct but adds unnecessary complexity to the code. /// - /// **Example:** - /// + /// ### Example /// ```ignore /// let input: &str = get_input(); /// let num = u16::from_str_radix(input, 10)?; diff --git a/clippy_lints/src/functions/mod.rs b/clippy_lints/src/functions/mod.rs index 2beb9bc94bf..ce23c0ce4a0 100644 --- a/clippy_lints/src/functions/mod.rs +++ b/clippy_lints/src/functions/mod.rs @@ -11,15 +11,15 @@ use rustc_session::{declare_tool_lint, impl_lint_pass}; use rustc_span::Span; declare_clippy_lint! { - /// **What it does:** Checks for functions with too many parameters. + /// ### What it does + /// Checks for functions with too many parameters. /// - /// **Why is this bad?** Functions with lots of parameters are considered bad + /// ### Why is this bad? + /// Functions with lots of parameters are considered bad /// style and reduce readability (“what does the 5th parameter mean?”). Consider /// grouping some parameters into a new type. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// # struct Color; /// fn foo(x: u32, y: u32, name: &str, c: Color, w: f32, h: f32, a: f32, b: f32) { @@ -32,16 +32,16 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for functions with a large amount of lines. + /// ### What it does + /// Checks for functions with a large amount of lines. /// - /// **Why is this bad?** Functions with a lot of lines are harder to understand + /// ### Why is this bad? + /// Functions with a lot of lines are harder to understand /// due to having to look at a larger amount of code to understand what the /// function is doing. Consider splitting the body of the function into /// multiple functions. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// fn im_too_long() { /// println!(""); @@ -55,15 +55,16 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for public functions that dereference raw pointer + /// ### What it does + /// Checks for public functions that dereference raw pointer /// arguments but are not marked `unsafe`. /// - /// **Why is this bad?** The function should probably be marked `unsafe`, since + /// ### Why is this bad? + /// The function should probably be marked `unsafe`, since /// for an arbitrary raw pointer, there is no way of telling for sure if it is /// valid. /// - /// **Known problems:** - /// + /// ### Known problems /// * It does not check functions recursively so if the pointer is passed to a /// private non-`unsafe` function which does the dereferencing, the lint won't /// trigger. @@ -71,7 +72,7 @@ declare_clippy_lint! { /// got from an argument in some other way (`fn foo(bar: &[*const u8])` or /// `some_argument.get_raw_ptr()`). /// - /// **Example:** + /// ### Example /// ```rust,ignore /// // Bad /// pub fn foo(x: *const u8) { @@ -89,17 +90,17 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for a [`#[must_use]`] attribute on + /// ### What it does + /// Checks for a [`#[must_use]`] attribute on /// unit-returning functions and methods. /// /// [`#[must_use]`]: https://doc.rust-lang.org/reference/attributes/diagnostics.html#the-must_use-attribute /// - /// **Why is this bad?** Unit values are useless. The attribute is likely + /// ### Why is this bad? + /// Unit values are useless. The attribute is likely /// a remnant of a refactoring that removed the return type. /// - /// **Known problems:** None. - /// - /// **Examples:** + /// ### Examples /// ```rust /// #[must_use] /// fn useless() { } @@ -110,19 +111,19 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for a [`#[must_use]`] attribute without + /// ### What it does + /// Checks for a [`#[must_use]`] attribute without /// further information on functions and methods that return a type already /// marked as `#[must_use]`. /// /// [`#[must_use]`]: https://doc.rust-lang.org/reference/attributes/diagnostics.html#the-must_use-attribute /// - /// **Why is this bad?** The attribute isn't needed. Not using the result + /// ### Why is this bad? + /// The attribute isn't needed. Not using the result /// will already be reported. Alternatively, one can add some text to the /// attribute to improve the lint message. /// - /// **Known problems:** None. - /// - /// **Examples:** + /// ### Examples /// ```rust /// #[must_use] /// fn double_must_use() -> Result<(), ()> { @@ -135,16 +136,19 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for public functions that have no + /// ### What it does + /// Checks for public functions that have no /// [`#[must_use]`] attribute, but return something not already marked /// must-use, have no mutable arg and mutate no statics. /// /// [`#[must_use]`]: https://doc.rust-lang.org/reference/attributes/diagnostics.html#the-must_use-attribute /// - /// **Why is this bad?** Not bad at all, this lint just shows places where + /// ### Why is this bad? + /// Not bad at all, this lint just shows places where /// you could add the attribute. /// - /// **Known problems:** The lint only checks the arguments for mutable + /// ### Known problems + /// The lint only checks the arguments for mutable /// types without looking if they are actually changed. On the other hand, /// it also ignores a broad range of potentially interesting side effects, /// because we cannot decide whether the programmer intends the function to @@ -152,7 +156,7 @@ declare_clippy_lint! { /// positives. At least we don't lint if the result type is unit or already /// `#[must_use]`. /// - /// **Examples:** + /// ### Examples /// ```rust /// // this could be annotated with `#[must_use]`. /// fn id(t: T) -> T { t } @@ -163,20 +167,23 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for public functions that return a `Result` + /// ### What it does + /// Checks for public functions that return a `Result` /// with an `Err` type of `()`. It suggests using a custom type that /// implements `std::error::Error`. /// - /// **Why is this bad?** Unit does not implement `Error` and carries no + /// ### Why is this bad? + /// Unit does not implement `Error` and carries no /// further information about what went wrong. /// - /// **Known problems:** Of course, this lint assumes that `Result` is used + /// ### Known problems + /// Of course, this lint assumes that `Result` is used /// for a fallible operation (which is after all the intended use). However /// code may opt to (mis)use it as a basic two-variant-enum. In that case, /// the suggestion is misguided, and the code should use a custom enum /// instead. /// - /// **Examples:** + /// ### Examples /// ```rust /// pub fn read_u8() -> Result { Err(()) } /// ``` diff --git a/clippy_lints/src/future_not_send.rs b/clippy_lints/src/future_not_send.rs index 515b8887453..0be03969bcb 100644 --- a/clippy_lints/src/future_not_send.rs +++ b/clippy_lints/src/future_not_send.rs @@ -12,12 +12,14 @@ use rustc_trait_selection::traits::error_reporting::suggestions::InferCtxtExt; use rustc_trait_selection::traits::{self, FulfillmentError, TraitEngine}; declare_clippy_lint! { - /// **What it does:** This lint requires Future implementations returned from + /// ### What it does + /// This lint requires Future implementations returned from /// functions and methods to implement the `Send` marker trait. It is mostly /// used by library authors (public and internal) that target an audience where /// multithreaded executors are likely to be used for running these Futures. /// - /// **Why is this bad?** A Future implementation captures some state that it + /// ### Why is this bad? + /// A Future implementation captures some state that it /// needs to eventually produce its final value. When targeting a multithreaded /// executor (which is the norm on non-embedded devices) this means that this /// state may need to be transported to other threads, in other words the @@ -31,10 +33,7 @@ declare_clippy_lint! { /// modifying the library where the offending Future implementation is /// produced. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust /// async fn not_send(bytes: std::rc::Rc<[u8]>) {} /// ``` diff --git a/clippy_lints/src/get_last_with_len.rs b/clippy_lints/src/get_last_with_len.rs index 8e45fdfecc4..ced35030de8 100644 --- a/clippy_lints/src/get_last_with_len.rs +++ b/clippy_lints/src/get_last_with_len.rs @@ -14,10 +14,12 @@ use rustc_span::source_map::Spanned; use rustc_span::sym; declare_clippy_lint! { - /// **What it does:** Checks for using `x.get(x.len() - 1)` instead of + /// ### What it does + /// Checks for using `x.get(x.len() - 1)` instead of /// `x.last()`. /// - /// **Why is this bad?** Using `x.last()` is easier to read and has the same + /// ### Why is this bad? + /// Using `x.last()` is easier to read and has the same /// result. /// /// Note that using `x[x.len() - 1]` is semantically different from @@ -27,10 +29,7 @@ declare_clippy_lint! { /// There is another lint (get_unwrap) that covers the case of using /// `x.get(index).unwrap()` instead of `x[index]`. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust /// // Bad /// let x = vec![2, 3, 5]; diff --git a/clippy_lints/src/identity_op.rs b/clippy_lints/src/identity_op.rs index 99c461930e4..5feb0ce8dec 100644 --- a/clippy_lints/src/identity_op.rs +++ b/clippy_lints/src/identity_op.rs @@ -11,14 +11,14 @@ use clippy_utils::diagnostics::span_lint; use clippy_utils::{clip, unsext}; declare_clippy_lint! { - /// **What it does:** Checks for identity operations, e.g., `x + 0`. + /// ### What it does + /// Checks for identity operations, e.g., `x + 0`. /// - /// **Why is this bad?** This code can be removed without changing the + /// ### Why is this bad? + /// This code can be removed without changing the /// meaning. So it just obscures what's going on. Delete it mercilessly. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// # let x = 1; /// x / 1 + 0 * 1 - 0 | 0; diff --git a/clippy_lints/src/if_let_mutex.rs b/clippy_lints/src/if_let_mutex.rs index 5403d76ea30..d3ddeda9fd1 100644 --- a/clippy_lints/src/if_let_mutex.rs +++ b/clippy_lints/src/if_let_mutex.rs @@ -9,16 +9,15 @@ use rustc_middle::hir::map::Map; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks for `Mutex::lock` calls in `if let` expression + /// ### What it does + /// Checks for `Mutex::lock` calls in `if let` expression /// with lock calls in any of the else blocks. /// - /// **Why is this bad?** The Mutex lock remains held for the whole + /// ### Why is this bad? + /// The Mutex lock remains held for the whole /// `if let ... else` block and deadlocks. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust,ignore /// if let Ok(thing) = mutex.lock() { /// do_thing(); diff --git a/clippy_lints/src/if_let_some_result.rs b/clippy_lints/src/if_let_some_result.rs index 611da3744ee..587307811a1 100644 --- a/clippy_lints/src/if_let_some_result.rs +++ b/clippy_lints/src/if_let_some_result.rs @@ -10,14 +10,14 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::sym; declare_clippy_lint! { - /// **What it does:*** Checks for unnecessary `ok()` in if let. + /// ### What it does + ///* Checks for unnecessary `ok()` in if let. /// - /// **Why is this bad?** Calling `ok()` in if let is unnecessary, instead match + /// ### Why is this bad? + /// Calling `ok()` in if let is unnecessary, instead match /// on `Ok(pat)` /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```ignore /// for i in iter { /// if let Some(value) = i.parse().ok() { diff --git a/clippy_lints/src/if_not_else.rs b/clippy_lints/src/if_not_else.rs index c56f67df061..28db7233d70 100644 --- a/clippy_lints/src/if_not_else.rs +++ b/clippy_lints/src/if_not_else.rs @@ -8,14 +8,14 @@ use rustc_middle::lint::in_external_macro; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks for usage of `!` or `!=` in an if condition with an + /// ### What it does + /// Checks for usage of `!` or `!=` in an if condition with an /// else branch. /// - /// **Why is this bad?** Negations reduce the readability of statements. + /// ### Why is this bad? + /// Negations reduce the readability of statements. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// # let v: Vec = vec![]; /// # fn a() {} diff --git a/clippy_lints/src/if_then_some_else_none.rs b/clippy_lints/src/if_then_some_else_none.rs index eadcd0867a8..17b9a2f888e 100644 --- a/clippy_lints/src/if_then_some_else_none.rs +++ b/clippy_lints/src/if_then_some_else_none.rs @@ -10,14 +10,13 @@ use rustc_semver::RustcVersion; use rustc_session::{declare_tool_lint, impl_lint_pass}; declare_clippy_lint! { - /// **What it does:** Checks for if-else that could be written to `bool::then`. + /// ### What it does + /// Checks for if-else that could be written to `bool::then`. /// - /// **Why is this bad?** Looks a little redundant. Using `bool::then` helps it have less lines of code. - /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Why is this bad? + /// Looks a little redundant. Using `bool::then` helps it have less lines of code. /// + /// ### Example /// ```rust /// # let v = vec![0]; /// let a = if v.is_empty() { diff --git a/clippy_lints/src/implicit_hasher.rs b/clippy_lints/src/implicit_hasher.rs index 879d6a75bbe..aae44f64e66 100644 --- a/clippy_lints/src/implicit_hasher.rs +++ b/clippy_lints/src/implicit_hasher.rs @@ -22,18 +22,21 @@ use clippy_utils::source::{snippet, snippet_opt}; use clippy_utils::ty::is_type_diagnostic_item; declare_clippy_lint! { - /// **What it does:** Checks for public `impl` or `fn` missing generalization + /// ### What it does + /// Checks for public `impl` or `fn` missing generalization /// over different hashers and implicitly defaulting to the default hashing /// algorithm (`SipHash`). /// - /// **Why is this bad?** `HashMap` or `HashSet` with custom hashers cannot be + /// ### Why is this bad? + /// `HashMap` or `HashSet` with custom hashers cannot be /// used with them. /// - /// **Known problems:** Suggestions for replacing constructors can contain + /// ### Known problems + /// Suggestions for replacing constructors can contain /// false-positives. Also applying suggestions can require modification of other /// pieces of code, possibly including external crates. /// - /// **Example:** + /// ### Example /// ```rust /// # use std::collections::HashMap; /// # use std::hash::{Hash, BuildHasher}; diff --git a/clippy_lints/src/implicit_return.rs b/clippy_lints/src/implicit_return.rs index f2f830ca5c0..fa7b5302cb1 100644 --- a/clippy_lints/src/implicit_return.rs +++ b/clippy_lints/src/implicit_return.rs @@ -13,17 +13,17 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::{Span, SyntaxContext}; declare_clippy_lint! { - /// **What it does:** Checks for missing return statements at the end of a block. + /// ### What it does + /// Checks for missing return statements at the end of a block. /// - /// **Why is this bad?** Actually omitting the return keyword is idiomatic Rust code. Programmers + /// ### Why is this bad? + /// Actually omitting the return keyword is idiomatic Rust code. Programmers /// coming from other languages might prefer the expressiveness of `return`. It's possible to miss /// the last returning statement because the only difference is a missing `;`. Especially in bigger /// code with multiple return paths having a `return` keyword makes it easier to find the /// corresponding statements. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// fn foo(x: usize) -> usize { /// x diff --git a/clippy_lints/src/implicit_saturating_sub.rs b/clippy_lints/src/implicit_saturating_sub.rs index 4069a685ea0..0a7d31dce2f 100644 --- a/clippy_lints/src/implicit_saturating_sub.rs +++ b/clippy_lints/src/implicit_saturating_sub.rs @@ -8,14 +8,13 @@ use rustc_lint::{LateContext, LateLintPass}; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks for implicit saturating subtraction. + /// ### What it does + /// Checks for implicit saturating subtraction. /// - /// **Why is this bad?** Simplicity and readability. Instead we can easily use an builtin function. - /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Why is this bad? + /// Simplicity and readability. Instead we can easily use an builtin function. /// + /// ### Example /// ```rust /// let end: u32 = 10; /// let start: u32 = 5; diff --git a/clippy_lints/src/inconsistent_struct_constructor.rs b/clippy_lints/src/inconsistent_struct_constructor.rs index 3b635071f28..1f8240a1f63 100644 --- a/clippy_lints/src/inconsistent_struct_constructor.rs +++ b/clippy_lints/src/inconsistent_struct_constructor.rs @@ -10,11 +10,13 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::symbol::Symbol; declare_clippy_lint! { - /// **What it does:** Checks for struct constructors where all fields are shorthand and + /// ### What it does + /// Checks for struct constructors where all fields are shorthand and /// the order of the field init shorthand in the constructor is inconsistent /// with the order in the struct definition. /// - /// **Why is this bad?** Since the order of fields in a constructor doesn't affect the + /// ### Why is this bad? + /// Since the order of fields in a constructor doesn't affect the /// resulted instance as the below example indicates, /// /// ```rust @@ -32,10 +34,7 @@ declare_clippy_lint! { /// /// inconsistent order can be confusing and decreases readability and consistency. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust /// struct Foo { /// x: i32, diff --git a/clippy_lints/src/indexing_slicing.rs b/clippy_lints/src/indexing_slicing.rs index bfa284f333a..8c1f1073309 100644 --- a/clippy_lints/src/indexing_slicing.rs +++ b/clippy_lints/src/indexing_slicing.rs @@ -10,14 +10,17 @@ use rustc_middle::ty; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks for out of bounds array indexing with a constant + /// ### What it does + /// Checks for out of bounds array indexing with a constant /// index. /// - /// **Why is this bad?** This will always panic at runtime. + /// ### Why is this bad? + /// This will always panic at runtime. /// - /// **Known problems:** Hopefully none. + /// ### Known problems + /// Hopefully none. /// - /// **Example:** + /// ### Example /// ```no_run /// # #![allow(const_err)] /// let x = [1, 2, 3, 4]; @@ -36,16 +39,19 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for usage of indexing or slicing. Arrays are special cases, this lint + /// ### What it does + /// Checks for usage of indexing or slicing. Arrays are special cases, this lint /// does report on arrays if we can tell that slicing operations are in bounds and does not /// lint on constant `usize` indexing on arrays because that is handled by rustc's `const_err` lint. /// - /// **Why is this bad?** Indexing and slicing can panic at runtime and there are + /// ### Why is this bad? + /// Indexing and slicing can panic at runtime and there are /// safe alternatives. /// - /// **Known problems:** Hopefully none. + /// ### Known problems + /// Hopefully none. /// - /// **Example:** + /// ### Example /// ```rust,no_run /// // Vector /// let x = vec![0; 5]; diff --git a/clippy_lints/src/infinite_iter.rs b/clippy_lints/src/infinite_iter.rs index 295a4e1fccb..2411a3175b9 100644 --- a/clippy_lints/src/infinite_iter.rs +++ b/clippy_lints/src/infinite_iter.rs @@ -7,14 +7,14 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::symbol::{sym, Symbol}; declare_clippy_lint! { - /// **What it does:** Checks for iteration that is guaranteed to be infinite. + /// ### What it does + /// Checks for iteration that is guaranteed to be infinite. /// - /// **Why is this bad?** While there may be places where this is acceptable + /// ### Why is this bad? + /// While there may be places where this is acceptable /// (e.g., in event streams), in most cases this is simply an error. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```no_run /// use std::iter; /// @@ -26,15 +26,18 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for iteration that may be infinite. + /// ### What it does + /// Checks for iteration that may be infinite. /// - /// **Why is this bad?** While there may be places where this is acceptable + /// ### Why is this bad? + /// While there may be places where this is acceptable /// (e.g., in event streams), in most cases this is simply an error. /// - /// **Known problems:** The code may have a condition to stop iteration, but + /// ### Known problems + /// The code may have a condition to stop iteration, but /// this lint is not clever enough to analyze it. /// - /// **Example:** + /// ### Example /// ```rust /// let infinite_iter = 0..; /// [0..].iter().zip(infinite_iter.take_while(|x| *x > 5)); diff --git a/clippy_lints/src/inherent_impl.rs b/clippy_lints/src/inherent_impl.rs index 9641784eb9a..d87055c842c 100644 --- a/clippy_lints/src/inherent_impl.rs +++ b/clippy_lints/src/inherent_impl.rs @@ -10,13 +10,13 @@ use rustc_span::Span; use std::collections::hash_map::Entry; declare_clippy_lint! { - /// **What it does:** Checks for multiple inherent implementations of a struct + /// ### What it does + /// Checks for multiple inherent implementations of a struct /// - /// **Why is this bad?** Splitting the implementation of a type makes the code harder to navigate. + /// ### Why is this bad? + /// Splitting the implementation of a type makes the code harder to navigate. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// struct X; /// impl X { diff --git a/clippy_lints/src/inherent_to_string.rs b/clippy_lints/src/inherent_to_string.rs index b023e13e846..b62fad4bd39 100644 --- a/clippy_lints/src/inherent_to_string.rs +++ b/clippy_lints/src/inherent_to_string.rs @@ -8,14 +8,16 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::sym; declare_clippy_lint! { - /// **What it does:** Checks for the definition of inherent methods with a signature of `to_string(&self) -> String`. + /// ### What it does + /// Checks for the definition of inherent methods with a signature of `to_string(&self) -> String`. /// - /// **Why is this bad?** This method is also implicitly defined if a type implements the `Display` trait. As the functionality of `Display` is much more versatile, it should be preferred. + /// ### Why is this bad? + /// This method is also implicitly defined if a type implements the `Display` trait. As the functionality of `Display` is much more versatile, it should be preferred. /// - /// **Known problems:** None - /// - /// ** Example:** + /// ### Known problems + /// None /// + /// ### Example /// ```rust /// // Bad /// pub struct A; @@ -45,14 +47,16 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for the definition of inherent methods with a signature of `to_string(&self) -> String` and if the type implementing this method also implements the `Display` trait. - /// - /// **Why is this bad?** This method is also implicitly defined if a type implements the `Display` trait. The less versatile inherent method will then shadow the implementation introduced by `Display`. + /// ### What it does + /// Checks for the definition of inherent methods with a signature of `to_string(&self) -> String` and if the type implementing this method also implements the `Display` trait. /// - /// **Known problems:** None + /// ### Why is this bad? + /// This method is also implicitly defined if a type implements the `Display` trait. The less versatile inherent method will then shadow the implementation introduced by `Display`. /// - /// ** Example:** + /// ### Known problems + /// None /// + /// ### Example /// ```rust /// // Bad /// use std::fmt; diff --git a/clippy_lints/src/inline_fn_without_body.rs b/clippy_lints/src/inline_fn_without_body.rs index 20f00bd51ba..3e3df903f17 100644 --- a/clippy_lints/src/inline_fn_without_body.rs +++ b/clippy_lints/src/inline_fn_without_body.rs @@ -10,14 +10,14 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::{sym, Symbol}; declare_clippy_lint! { - /// **What it does:** Checks for `#[inline]` on trait methods without bodies + /// ### What it does + /// Checks for `#[inline]` on trait methods without bodies /// - /// **Why is this bad?** Only implementations of trait methods may be inlined. + /// ### Why is this bad? + /// Only implementations of trait methods may be inlined. /// The inline attribute is ignored for trait methods without bodies. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// trait Animal { /// #[inline] diff --git a/clippy_lints/src/int_plus_one.rs b/clippy_lints/src/int_plus_one.rs index c4a1222b51f..49b69dd072a 100644 --- a/clippy_lints/src/int_plus_one.rs +++ b/clippy_lints/src/int_plus_one.rs @@ -8,13 +8,13 @@ use rustc_lint::{EarlyContext, EarlyLintPass}; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks for usage of `x >= y + 1` or `x - 1 >= y` (and `<=`) in a block + /// ### What it does + /// Checks for usage of `x >= y + 1` or `x - 1 >= y` (and `<=`) in a block /// - /// **Why is this bad?** Readability -- better to use `> y` instead of `>= y + 1`. + /// ### Why is this bad? + /// Readability -- better to use `> y` instead of `>= y + 1`. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// # let x = 1; /// # let y = 1; diff --git a/clippy_lints/src/integer_division.rs b/clippy_lints/src/integer_division.rs index e5482f675e7..a0e6f12b812 100644 --- a/clippy_lints/src/integer_division.rs +++ b/clippy_lints/src/integer_division.rs @@ -5,15 +5,15 @@ use rustc_lint::{LateContext, LateLintPass}; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks for division of integers + /// ### What it does + /// Checks for division of integers /// - /// **Why is this bad?** When outside of some very specific algorithms, + /// ### Why is this bad? + /// When outside of some very specific algorithms, /// integer division is very often a mistake because it discards the /// remainder. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// // Bad /// let x = 3 / 2; diff --git a/clippy_lints/src/invalid_upcast_comparisons.rs b/clippy_lints/src/invalid_upcast_comparisons.rs index 37011f5578d..3b28b121204 100644 --- a/clippy_lints/src/invalid_upcast_comparisons.rs +++ b/clippy_lints/src/invalid_upcast_comparisons.rs @@ -14,18 +14,20 @@ use clippy_utils::source::snippet; use clippy_utils::{comparisons, sext}; declare_clippy_lint! { - /// **What it does:** Checks for comparisons where the relation is always either + /// ### What it does + /// Checks for comparisons where the relation is always either /// true or false, but where one side has been upcast so that the comparison is /// necessary. Only integer types are checked. /// - /// **Why is this bad?** An expression like `let x : u8 = ...; (x as u32) > 300` + /// ### Why is this bad? + /// An expression like `let x : u8 = ...; (x as u32) > 300` /// will mistakenly imply that it is possible for `x` to be outside the range of /// `u8`. /// - /// **Known problems:** + /// ### Known problems /// https://github.com/rust-lang/rust-clippy/issues/886 /// - /// **Example:** + /// ### Example /// ```rust /// let x: u8 = 1; /// (x as u32) > 300; diff --git a/clippy_lints/src/items_after_statements.rs b/clippy_lints/src/items_after_statements.rs index c69571f32a2..429c6ed7d2d 100644 --- a/clippy_lints/src/items_after_statements.rs +++ b/clippy_lints/src/items_after_statements.rs @@ -7,15 +7,15 @@ use rustc_middle::lint::in_external_macro; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks for items declared after some statement in a block. + /// ### What it does + /// Checks for items declared after some statement in a block. /// - /// **Why is this bad?** Items live for the entire scope they are declared + /// ### Why is this bad? + /// Items live for the entire scope they are declared /// in. But statements are processed in order. This might cause confusion as /// it's hard to figure out which item is meant in a statement. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// // Bad /// fn foo() { diff --git a/clippy_lints/src/large_const_arrays.rs b/clippy_lints/src/large_const_arrays.rs index 48dc5fefe99..5d4e06c2af0 100644 --- a/clippy_lints/src/large_const_arrays.rs +++ b/clippy_lints/src/large_const_arrays.rs @@ -11,15 +11,15 @@ use rustc_span::{BytePos, Pos, Span}; use rustc_typeck::hir_ty_to_ty; declare_clippy_lint! { - /// **What it does:** Checks for large `const` arrays that should + /// ### What it does + /// Checks for large `const` arrays that should /// be defined as `static` instead. /// - /// **Why is this bad?** Performance: const variables are inlined upon use. + /// ### Why is this bad? + /// Performance: const variables are inlined upon use. /// Static items result in only one instance and has a fixed location in memory. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust,ignore /// // Bad /// pub const a = [0u32; 1_000_000]; diff --git a/clippy_lints/src/large_enum_variant.rs b/clippy_lints/src/large_enum_variant.rs index f166748d86b..cde2336b690 100644 --- a/clippy_lints/src/large_enum_variant.rs +++ b/clippy_lints/src/large_enum_variant.rs @@ -10,20 +10,22 @@ use rustc_session::{declare_tool_lint, impl_lint_pass}; use rustc_target::abi::LayoutOf; declare_clippy_lint! { - /// **What it does:** Checks for large size differences between variants on + /// ### What it does + /// Checks for large size differences between variants on /// `enum`s. /// - /// **Why is this bad?** Enum size is bounded by the largest variant. Having a + /// ### Why is this bad? + /// Enum size is bounded by the largest variant. Having a /// large variant can penalize the memory layout of that enum. /// - /// **Known problems:** This lint obviously cannot take the distribution of + /// ### Known problems + /// This lint obviously cannot take the distribution of /// variants in your running program into account. It is possible that the /// smaller variants make up less than 1% of all instances, in which case /// the overhead is negligible and the boxing is counter-productive. Always /// measure the change this lint suggests. /// - /// **Example:** - /// + /// ### Example /// ```rust /// // Bad /// enum Test { diff --git a/clippy_lints/src/large_stack_arrays.rs b/clippy_lints/src/large_stack_arrays.rs index c46b98022c6..7088630bfdb 100644 --- a/clippy_lints/src/large_stack_arrays.rs +++ b/clippy_lints/src/large_stack_arrays.rs @@ -10,13 +10,13 @@ use rustc_session::{declare_tool_lint, impl_lint_pass}; use crate::rustc_target::abi::LayoutOf; declare_clippy_lint! { - /// **What it does:** Checks for local arrays that may be too large. + /// ### What it does + /// Checks for local arrays that may be too large. /// - /// **Why is this bad?** Large local arrays may cause stack overflow. + /// ### Why is this bad? + /// Large local arrays may cause stack overflow. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust,ignore /// let a = [0u32; 1_000_000]; /// ``` diff --git a/clippy_lints/src/len_zero.rs b/clippy_lints/src/len_zero.rs index 892b3af0b32..b66d7a9f729 100644 --- a/clippy_lints/src/len_zero.rs +++ b/clippy_lints/src/len_zero.rs @@ -18,17 +18,17 @@ use rustc_span::{ }; declare_clippy_lint! { - /// **What it does:** Checks for getting the length of something via `.len()` + /// ### What it does + /// Checks for getting the length of something via `.len()` /// just to compare to zero, and suggests using `.is_empty()` where applicable. /// - /// **Why is this bad?** Some structures can answer `.is_empty()` much faster + /// ### Why is this bad? + /// Some structures can answer `.is_empty()` much faster /// than calculating their length. So it is good to get into the habit of using /// `.is_empty()`, and having it is cheap. /// Besides, it makes the intent clearer than a manual comparison in some contexts. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```ignore /// if x.len() == 0 { /// .. @@ -52,18 +52,18 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for items that implement `.len()` but not + /// ### What it does + /// Checks for items that implement `.len()` but not /// `.is_empty()`. /// - /// **Why is this bad?** It is good custom to have both methods, because for + /// ### Why is this bad? + /// It is good custom to have both methods, because for /// some data structures, asking about the length will be a costly operation, /// whereas `.is_empty()` can usually answer in constant time. Also it used to /// lead to false positives on the [`len_zero`](#len_zero) lint – currently that /// lint will ignore such entities. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```ignore /// impl X { /// pub fn len(&self) -> usize { @@ -77,17 +77,17 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for comparing to an empty slice such as `""` or `[]`, + /// ### What it does + /// Checks for comparing to an empty slice such as `""` or `[]`, /// and suggests using `.is_empty()` where applicable. /// - /// **Why is this bad?** Some structures can answer `.is_empty()` much faster + /// ### Why is this bad? + /// Some structures can answer `.is_empty()` much faster /// than checking for equality. So it is good to get into the habit of using /// `.is_empty()`, and having it is cheap. /// Besides, it makes the intent clearer than a manual comparison in some contexts. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// /// ```ignore /// if s == "" { diff --git a/clippy_lints/src/let_if_seq.rs b/clippy_lints/src/let_if_seq.rs index 67eae4d87bb..13f0d43cf8d 100644 --- a/clippy_lints/src/let_if_seq.rs +++ b/clippy_lints/src/let_if_seq.rs @@ -9,14 +9,14 @@ use rustc_lint::{LateContext, LateLintPass}; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks for variable declarations immediately followed by a + /// ### What it does + /// Checks for variable declarations immediately followed by a /// conditional affectation. /// - /// **Why is this bad?** This is not idiomatic Rust. + /// ### Why is this bad? + /// This is not idiomatic Rust. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust,ignore /// let foo; /// diff --git a/clippy_lints/src/let_underscore.rs b/clippy_lints/src/let_underscore.rs index e627b1385bc..8992d25932c 100644 --- a/clippy_lints/src/let_underscore.rs +++ b/clippy_lints/src/let_underscore.rs @@ -9,15 +9,15 @@ use rustc_middle::ty::subst::GenericArgKind; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks for `let _ = ` + /// ### What it does + /// Checks for `let _ = ` /// where expr is #[must_use] /// - /// **Why is this bad?** It's better to explicitly + /// ### Why is this bad? + /// It's better to explicitly /// handle the value of a #[must_use] expr /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// fn f() -> Result { /// Ok(0) @@ -33,17 +33,17 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for `let _ = sync_lock` + /// ### What it does + /// Checks for `let _ = sync_lock` /// - /// **Why is this bad?** This statement immediately drops the lock instead of + /// ### Why is this bad? + /// This statement immediately drops the lock instead of /// extending its lifetime to the end of the scope, which is often not intended. /// To extend lock lifetime to the end of the scope, use an underscore-prefixed /// name instead (i.e. _lock). If you want to explicitly drop the lock, /// `std::mem::drop` conveys your intention better and is less error-prone. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// /// Bad: /// ```rust,ignore @@ -60,19 +60,19 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for `let _ = ` + /// ### What it does + /// Checks for `let _ = ` /// where expr has a type that implements `Drop` /// - /// **Why is this bad?** This statement immediately drops the initializer + /// ### Why is this bad? + /// This statement immediately drops the initializer /// expression instead of extending its lifetime to the end of the scope, which /// is often not intended. To extend the expression's lifetime to the end of the /// scope, use an underscore-prefixed name instead (i.e. _var). If you want to /// explicitly drop the expression, `std::mem::drop` conveys your intention /// better and is less error-prone. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// /// Bad: /// ```rust,ignore diff --git a/clippy_lints/src/lib.rs b/clippy_lints/src/lib.rs index aa763b5c5e6..3cffb507f70 100644 --- a/clippy_lints/src/lib.rs +++ b/clippy_lints/src/lib.rs @@ -73,14 +73,13 @@ use rustc_session::Session; /// use clippy_lints::declare_clippy_lint; /// /// declare_clippy_lint! { -/// /// **What it does:** Checks for ... (describe what the lint matches). +/// /// ### What it does +/// /// Checks for ... (describe what the lint matches). /// /// -/// /// **Why is this bad?** Supply the reason for linting the code. -/// /// -/// /// **Known problems:** None. (Or describe where it could go wrong.) -/// /// -/// /// **Example:** +/// /// ### Why is this bad? +/// /// Supply the reason for linting the code. /// /// +/// /// ### Example /// /// ```rust /// /// // Bad /// /// Insert a short example of code that triggers the lint diff --git a/clippy_lints/src/lifetimes.rs b/clippy_lints/src/lifetimes.rs index 5ae68ba5b2f..e5e6f8d25cc 100644 --- a/clippy_lints/src/lifetimes.rs +++ b/clippy_lints/src/lifetimes.rs @@ -18,20 +18,22 @@ use rustc_span::source_map::Span; use rustc_span::symbol::{kw, Symbol}; declare_clippy_lint! { - /// **What it does:** Checks for lifetime annotations which can be removed by + /// ### What it does + /// Checks for lifetime annotations which can be removed by /// relying on lifetime elision. /// - /// **Why is this bad?** The additional lifetimes make the code look more + /// ### Why is this bad? + /// The additional lifetimes make the code look more /// complicated, while there is nothing out of the ordinary going on. Removing /// them leads to more readable code. /// - /// **Known problems:** + /// ### Known problems /// - We bail out if the function has a `where` clause where lifetimes /// are mentioned due to potenial false positives. /// - Lifetime bounds such as `impl Foo + 'a` and `T: 'a` must be elided with the /// placeholder notation `'_` because the fully elided notation leaves the type bound to `'static`. /// - /// **Example:** + /// ### Example /// ```rust /// // Bad: unnecessary lifetime annotations /// fn in_and_out<'a>(x: &'a u8, y: u8) -> &'a u8 { @@ -50,16 +52,16 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for lifetimes in generics that are never used + /// ### What it does + /// Checks for lifetimes in generics that are never used /// anywhere else. /// - /// **Why is this bad?** The additional lifetimes make the code look more + /// ### Why is this bad? + /// The additional lifetimes make the code look more /// complicated, while there is nothing out of the ordinary going on. Removing /// them leads to more readable code. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// // Bad: unnecessary lifetimes /// fn unused_lifetime<'a>(x: u8) { diff --git a/clippy_lints/src/literal_representation.rs b/clippy_lints/src/literal_representation.rs index e0c5578bd60..699ddce0cff 100644 --- a/clippy_lints/src/literal_representation.rs +++ b/clippy_lints/src/literal_representation.rs @@ -16,15 +16,14 @@ use rustc_session::{declare_tool_lint, impl_lint_pass}; use std::iter; declare_clippy_lint! { - /// **What it does:** Warns if a long integral or floating-point constant does + /// ### What it does + /// Warns if a long integral or floating-point constant does /// not contain underscores. /// - /// **Why is this bad?** Reading long numbers is difficult without separators. - /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Why is this bad? + /// Reading long numbers is difficult without separators. /// + /// ### Example /// ```rust /// // Bad /// let x: u64 = 61864918973511; @@ -38,17 +37,18 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Warns for mistyped suffix in literals + /// ### What it does + /// Warns for mistyped suffix in literals /// - /// **Why is this bad?** This is most probably a typo + /// ### Why is this bad? + /// This is most probably a typo /// - /// **Known problems:** + /// ### Known problems /// - Recommends a signed suffix, even though the number might be too big and an unsigned /// suffix is required /// - Does not match on `_127` since that is a valid grouping for decimal and octal numbers /// - /// **Example:** - /// + /// ### Example /// ```rust /// // Probably mistyped /// 2_32; @@ -62,16 +62,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Warns if an integral or floating-point constant is + /// ### What it does + /// Warns if an integral or floating-point constant is /// grouped inconsistently with underscores. /// - /// **Why is this bad?** Readers may incorrectly interpret inconsistently + /// ### Why is this bad? + /// Readers may incorrectly interpret inconsistently /// grouped digits. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust /// // Bad /// let x: u64 = 618_64_9189_73_511; @@ -85,15 +84,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Warns if hexadecimal or binary literals are not grouped + /// ### What it does + /// Warns if hexadecimal or binary literals are not grouped /// by nibble or byte. /// - /// **Why is this bad?** Negatively impacts readability. - /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Why is this bad? + /// Negatively impacts readability. /// + /// ### Example /// ```rust /// let x: u32 = 0xFFF_FFF; /// let y: u8 = 0b01_011_101; @@ -104,16 +102,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Warns if the digits of an integral or floating-point + /// ### What it does + /// Warns if the digits of an integral or floating-point /// constant are grouped into groups that /// are too large. /// - /// **Why is this bad?** Negatively impacts readability. - /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Why is this bad? + /// Negatively impacts readability. /// + /// ### Example /// ```rust /// let x: u64 = 6186491_8973511; /// ``` @@ -123,15 +120,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Warns if there is a better representation for a numeric literal. + /// ### What it does + /// Warns if there is a better representation for a numeric literal. /// - /// **Why is this bad?** Especially for big powers of 2 a hexadecimal representation is more + /// ### Why is this bad? + /// Especially for big powers of 2 a hexadecimal representation is more /// readable than a decimal representation. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// `255` => `0xFF` /// `65_535` => `0xFFFF` /// `4_042_322_160` => `0xF0F0_F0F0` diff --git a/clippy_lints/src/loops/mod.rs b/clippy_lints/src/loops/mod.rs index 56a123b69c6..7ca54d53972 100644 --- a/clippy_lints/src/loops/mod.rs +++ b/clippy_lints/src/loops/mod.rs @@ -26,14 +26,14 @@ use rustc_span::source_map::Span; use utils::{get_span_of_entire_for_loop, make_iterator_snippet, IncrementVisitor, InitializeVisitor}; declare_clippy_lint! { - /// **What it does:** Checks for for-loops that manually copy items between + /// ### What it does + /// Checks for for-loops that manually copy items between /// slices that could be optimized by having a memcpy. /// - /// **Why is this bad?** It is not as fast as a memcpy. + /// ### Why is this bad? + /// It is not as fast as a memcpy. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// # let src = vec![1]; /// # let mut dst = vec![0; 65]; @@ -53,15 +53,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for looping over the range of `0..len` of some + /// ### What it does + /// Checks for looping over the range of `0..len` of some /// collection just to get the values by index. /// - /// **Why is this bad?** Just iterating the collection itself makes the intent + /// ### Why is this bad? + /// Just iterating the collection itself makes the intent /// more clear and is probably faster. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// let vec = vec!['a', 'b', 'c']; /// for i in 0..vec.len() { @@ -81,15 +81,18 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for loops on `x.iter()` where `&x` will do, and + /// ### What it does + /// Checks for loops on `x.iter()` where `&x` will do, and /// suggests the latter. /// - /// **Why is this bad?** Readability. + /// ### Why is this bad? + /// Readability. /// - /// **Known problems:** False negatives. We currently only warn on some known + /// ### Known problems + /// False negatives. We currently only warn on some known /// types. /// - /// **Example:** + /// ### Example /// ```rust /// // with `y` a `Vec` or slice: /// # let y = vec![1]; @@ -110,14 +113,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for loops on `y.into_iter()` where `y` will do, and + /// ### What it does + /// Checks for loops on `y.into_iter()` where `y` will do, and /// suggests the latter. /// - /// **Why is this bad?** Readability. + /// ### Why is this bad? + /// Readability. /// - /// **Known problems:** None - /// - /// **Example:** + /// ### Example /// ```rust /// # let y = vec![1]; /// // with `y` a `Vec` or slice: @@ -138,18 +141,18 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for loops on `x.next()`. + /// ### What it does + /// Checks for loops on `x.next()`. /// - /// **Why is this bad?** `next()` returns either `Some(value)` if there was a + /// ### Why is this bad? + /// `next()` returns either `Some(value)` if there was a /// value, or `None` otherwise. The insidious thing is that `Option<_>` /// implements `IntoIterator`, so that possibly one value will be iterated, /// leading to some hard to find bugs. No one will want to write such code /// [except to win an Underhanded Rust /// Contest](https://www.reddit.com/r/rust/comments/3hb0wm/underhanded_rust_contest/cu5yuhr). /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```ignore /// for x in y.next() { /// .. @@ -161,14 +164,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for `for` loops over `Option` or `Result` values. + /// ### What it does + /// Checks for `for` loops over `Option` or `Result` values. /// - /// **Why is this bad?** Readability. This is more clearly expressed as an `if + /// ### Why is this bad? + /// Readability. This is more clearly expressed as an `if /// let`. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// # let opt = Some(1); /// @@ -204,15 +207,18 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Detects `loop + match` combinations that are easier + /// ### What it does + /// Detects `loop + match` combinations that are easier /// written as a `while let` loop. /// - /// **Why is this bad?** The `while let` loop is usually shorter and more + /// ### Why is this bad? + /// The `while let` loop is usually shorter and more /// readable. /// - /// **Known problems:** Sometimes the wrong binding is displayed ([#383](https://github.com/rust-lang/rust-clippy/issues/383)). + /// ### Known problems + /// Sometimes the wrong binding is displayed ([#383](https://github.com/rust-lang/rust-clippy/issues/383)). /// - /// **Example:** + /// ### Example /// ```rust,no_run /// # let y = Some(1); /// loop { @@ -233,16 +239,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for functions collecting an iterator when collect + /// ### What it does + /// Checks for functions collecting an iterator when collect /// is not needed. /// - /// **Why is this bad?** `collect` causes the allocation of a new data structure, + /// ### Why is this bad? + /// `collect` causes the allocation of a new data structure, /// when this allocation may not be needed. /// - /// **Known problems:** - /// None - /// - /// **Example:** + /// ### Example /// ```rust /// # let iterator = vec![1].into_iter(); /// let len = iterator.clone().collect::>().len(); @@ -255,15 +260,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks `for` loops over slices with an explicit counter + /// ### What it does + /// Checks `for` loops over slices with an explicit counter /// and suggests the use of `.enumerate()`. /// - /// **Why is it bad?** Using `.enumerate()` makes the intent more clear, + /// ### Why is this bad? + /// Using `.enumerate()` makes the intent more clear, /// declutters the code and may be faster in some instances. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// # let v = vec![1]; /// # fn bar(bar: usize, baz: usize) {} @@ -285,9 +290,11 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for empty `loop` expressions. + /// ### What it does + /// Checks for empty `loop` expressions. /// - /// **Why is this bad?** These busy loops burn CPU cycles without doing + /// ### Why is this bad? + /// These busy loops burn CPU cycles without doing /// anything. It is _almost always_ a better idea to `panic!` than to have /// a busy loop. /// @@ -306,9 +313,7 @@ declare_clippy_lint! { /// - [`x86_64::instructions::hlt`](https://docs.rs/x86_64/0.12.2/x86_64/instructions/fn.hlt.html) /// - [`cortex_m::asm::wfi`](https://docs.rs/cortex-m/0.6.3/cortex_m/asm/fn.wfi.html) /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```no_run /// loop {} /// ``` @@ -318,14 +323,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for `while let` expressions on iterators. + /// ### What it does + /// Checks for `while let` expressions on iterators. /// - /// **Why is this bad?** Readability. A simple `for` loop is shorter and conveys + /// ### Why is this bad? + /// Readability. A simple `for` loop is shorter and conveys /// the intent better. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```ignore /// while let Some(val) = iter() { /// .. @@ -337,15 +342,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for iterating a map (`HashMap` or `BTreeMap`) and + /// ### What it does + /// Checks for iterating a map (`HashMap` or `BTreeMap`) and /// ignoring either the keys or values. /// - /// **Why is this bad?** Readability. There are `keys` and `values` methods that + /// ### Why is this bad? + /// Readability. There are `keys` and `values` methods that /// can be used to express that don't need the values or keys. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```ignore /// for (k, _) in &map { /// .. @@ -365,15 +370,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for loops that will always `break`, `return` or + /// ### What it does + /// Checks for loops that will always `break`, `return` or /// `continue` an outer loop. /// - /// **Why is this bad?** This loop never loops, all it does is obfuscating the + /// ### Why is this bad? + /// This loop never loops, all it does is obfuscating the /// code. /// - /// **Known problems:** None - /// - /// **Example:** + /// ### Example /// ```rust /// loop { /// ..; @@ -386,13 +391,13 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for loops which have a range bound that is a mutable variable - /// - /// **Why is this bad?** One might think that modifying the mutable variable changes the loop bounds + /// ### What it does + /// Checks for loops which have a range bound that is a mutable variable /// - /// **Known problems:** None + /// ### Why is this bad? + /// One might think that modifying the mutable variable changes the loop bounds /// - /// **Example:** + /// ### Example /// ```rust /// let mut foo = 42; /// for i in 0..foo { @@ -406,17 +411,20 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks whether variables used within while loop condition + /// ### What it does + /// Checks whether variables used within while loop condition /// can be (and are) mutated in the body. /// - /// **Why is this bad?** If the condition is unchanged, entering the body of the loop + /// ### Why is this bad? + /// If the condition is unchanged, entering the body of the loop /// will lead to an infinite loop. /// - /// **Known problems:** If the `while`-loop is in a closure, the check for mutation of the + /// ### Known problems + /// If the `while`-loop is in a closure, the check for mutation of the /// condition variables in the body can cause false negatives. For example when only `Upvar` `a` is /// in the condition and only `Upvar` `b` gets mutated in the body, the lint will not trigger. /// - /// **Example:** + /// ### Example /// ```rust /// let i = 0; /// while i > 10 { @@ -429,15 +437,16 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks whether a for loop is being used to push a constant + /// ### What it does + /// Checks whether a for loop is being used to push a constant /// value into a Vec. /// - /// **Why is this bad?** This kind of operation can be expressed more succinctly with + /// ### Why is this bad? + /// This kind of operation can be expressed more succinctly with /// `vec![item;SIZE]` or `vec.resize(NEW_SIZE, item)` and using these alternatives may also /// have better performance. - /// **Known problems:** None /// - /// **Example:** + /// ### Example /// ```rust /// let item1 = 2; /// let item2 = 3; @@ -462,13 +471,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks whether a for loop has a single element. + /// ### What it does + /// Checks whether a for loop has a single element. /// - /// **Why is this bad?** There is no reason to have a loop of a + /// ### Why is this bad? + /// There is no reason to have a loop of a /// single element. - /// **Known problems:** None /// - /// **Example:** + /// ### Example /// ```rust /// let item1 = 2; /// for item in &[item1] { @@ -487,15 +497,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Check for unnecessary `if let` usage in a for loop + /// ### What it does + /// Check for unnecessary `if let` usage in a for loop /// where only the `Some` or `Ok` variant of the iterator element is used. /// - /// **Why is this bad?** It is verbose and can be simplified + /// ### Why is this bad? + /// It is verbose and can be simplified /// by first calling the `flatten` method on the `Iterator`. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// /// ```rust /// let x = vec![Some(1), Some(2), Some(3)]; diff --git a/clippy_lints/src/macro_use.rs b/clippy_lints/src/macro_use.rs index 66479ae264e..a371f8bbd3c 100644 --- a/clippy_lints/src/macro_use.rs +++ b/clippy_lints/src/macro_use.rs @@ -12,14 +12,14 @@ use rustc_session::{declare_tool_lint, impl_lint_pass}; use rustc_span::{edition::Edition, sym, Span}; declare_clippy_lint! { - /// **What it does:** Checks for `#[macro_use] use...`. + /// ### What it does + /// Checks for `#[macro_use] use...`. /// - /// **Why is this bad?** Since the Rust 2018 edition you can import + /// ### Why is this bad? + /// Since the Rust 2018 edition you can import /// macro's directly, this is considered idiomatic. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust,ignore /// #[macro_use] /// use some_macro; diff --git a/clippy_lints/src/main_recursion.rs b/clippy_lints/src/main_recursion.rs index 07d8a440aea..776e4b3fe76 100644 --- a/clippy_lints/src/main_recursion.rs +++ b/clippy_lints/src/main_recursion.rs @@ -7,14 +7,14 @@ use rustc_lint::{LateContext, LateLintPass}; use rustc_session::{declare_tool_lint, impl_lint_pass}; declare_clippy_lint! { - /// **What it does:** Checks for recursion using the entrypoint. + /// ### What it does + /// Checks for recursion using the entrypoint. /// - /// **Why is this bad?** Apart from special setups (which we could detect following attributes like #![no_std]), + /// ### Why is this bad? + /// Apart from special setups (which we could detect following attributes like #![no_std]), /// recursing into main() seems like an unintuitive antipattern we should be able to detect. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```no_run /// fn main() { /// main(); diff --git a/clippy_lints/src/manual_async_fn.rs b/clippy_lints/src/manual_async_fn.rs index 5d88ff3b99f..8e1385fb83a 100644 --- a/clippy_lints/src/manual_async_fn.rs +++ b/clippy_lints/src/manual_async_fn.rs @@ -14,14 +14,13 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::{sym, Span}; declare_clippy_lint! { - /// **What it does:** It checks for manual implementations of `async` functions. + /// ### What it does + /// It checks for manual implementations of `async` functions. /// - /// **Why is this bad?** It's more idiomatic to use the dedicated syntax. - /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Why is this bad? + /// It's more idiomatic to use the dedicated syntax. /// + /// ### Example /// ```rust /// use std::future::Future; /// diff --git a/clippy_lints/src/manual_map.rs b/clippy_lints/src/manual_map.rs index 563d5cdb5fb..7dec1595e0d 100644 --- a/clippy_lints/src/manual_map.rs +++ b/clippy_lints/src/manual_map.rs @@ -16,14 +16,13 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::{sym, SyntaxContext}; declare_clippy_lint! { - /// **What it does:** Checks for usages of `match` which could be implemented using `map` + /// ### What it does + /// Checks for usages of `match` which could be implemented using `map` /// - /// **Why is this bad?** Using the `map` method is clearer and more concise. - /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Why is this bad? + /// Using the `map` method is clearer and more concise. /// + /// ### Example /// ```rust /// match Some(0) { /// Some(x) => Some(x + 1), diff --git a/clippy_lints/src/manual_non_exhaustive.rs b/clippy_lints/src/manual_non_exhaustive.rs index 54f714b54b6..335ea001ee4 100644 --- a/clippy_lints/src/manual_non_exhaustive.rs +++ b/clippy_lints/src/manual_non_exhaustive.rs @@ -11,15 +11,14 @@ use rustc_session::{declare_tool_lint, impl_lint_pass}; use rustc_span::{sym, Span}; declare_clippy_lint! { - /// **What it does:** Checks for manual implementations of the non-exhaustive pattern. + /// ### What it does + /// Checks for manual implementations of the non-exhaustive pattern. /// - /// **Why is this bad?** Using the #[non_exhaustive] attribute expresses better the intent + /// ### Why is this bad? + /// Using the #[non_exhaustive] attribute expresses better the intent /// and allows possible optimizations when applied to enums. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust /// struct S { /// pub a: i32, diff --git a/clippy_lints/src/manual_ok_or.rs b/clippy_lints/src/manual_ok_or.rs index 847c8c648b0..b2f287af697 100644 --- a/clippy_lints/src/manual_ok_or.rs +++ b/clippy_lints/src/manual_ok_or.rs @@ -13,15 +13,15 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::symbol::sym; declare_clippy_lint! { - /// **What it does:** + /// ### What it does + /// /// Finds patterns that reimplement `Option::ok_or`. /// - /// **Why is this bad?** - /// Concise code helps focusing on behavior instead of boilerplate. + /// ### Why is this bad? /// - /// **Known problems:** None. + /// Concise code helps focusing on behavior instead of boilerplate. /// - /// **Examples:** + /// ### Examples /// ```rust /// let foo: Option = None; /// foo.map_or(Err("error"), |v| Ok(v)); diff --git a/clippy_lints/src/manual_strip.rs b/clippy_lints/src/manual_strip.rs index 61b5fe81fa9..db12c377488 100644 --- a/clippy_lints/src/manual_strip.rs +++ b/clippy_lints/src/manual_strip.rs @@ -18,21 +18,17 @@ use rustc_span::source_map::Spanned; use rustc_span::Span; declare_clippy_lint! { - /// **What it does:** + /// ### What it does /// Suggests using `strip_{prefix,suffix}` over `str::{starts,ends}_with` and slicing using /// the pattern's length. /// - /// **Why is this bad?** + /// ### Why is this bad? /// Using `str:strip_{prefix,suffix}` is safer and may have better performance as there is no /// slicing which may panic and the compiler does not need to insert this panic code. It is /// also sometimes more readable as it removes the need for duplicating or storing the pattern /// used by `str::{starts,ends}_with` and in the slicing. /// - /// **Known problems:** - /// None. - /// - /// **Example:** - /// + /// ### Example /// ```rust /// let s = "hello, world!"; /// if s.starts_with("hello, ") { diff --git a/clippy_lints/src/manual_unwrap_or.rs b/clippy_lints/src/manual_unwrap_or.rs index 9d8d77cf8f0..426789742d5 100644 --- a/clippy_lints/src/manual_unwrap_or.rs +++ b/clippy_lints/src/manual_unwrap_or.rs @@ -15,15 +15,13 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::sym; declare_clippy_lint! { - /// **What it does:** + /// ### What it does /// Finds patterns that reimplement `Option::unwrap_or` or `Result::unwrap_or`. /// - /// **Why is this bad?** + /// ### Why is this bad? /// Concise code helps focusing on behavior instead of boilerplate. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// let foo: Option = None; /// match foo { diff --git a/clippy_lints/src/map_clone.rs b/clippy_lints/src/map_clone.rs index e1f80ab025c..394606200bb 100644 --- a/clippy_lints/src/map_clone.rs +++ b/clippy_lints/src/map_clone.rs @@ -15,16 +15,15 @@ use rustc_span::symbol::Ident; use rustc_span::{sym, Span}; declare_clippy_lint! { - /// **What it does:** Checks for usage of `map(|x| x.clone())` or + /// ### What it does + /// Checks for usage of `map(|x| x.clone())` or /// dereferencing closures for `Copy` types, on `Iterator` or `Option`, /// and suggests `cloned()` or `copied()` instead /// - /// **Why is this bad?** Readability, this can be written more concisely - /// - /// **Known problems:** None - /// - /// **Example:** + /// ### Why is this bad? + /// Readability, this can be written more concisely /// + /// ### Example /// ```rust /// let x = vec![42, 43]; /// let y = x.iter(); diff --git a/clippy_lints/src/map_err_ignore.rs b/clippy_lints/src/map_err_ignore.rs index 425a9734e5f..82d3732326e 100644 --- a/clippy_lints/src/map_err_ignore.rs +++ b/clippy_lints/src/map_err_ignore.rs @@ -4,13 +4,13 @@ use rustc_lint::{LateContext, LateLintPass}; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks for instances of `map_err(|_| Some::Enum)` + /// ### What it does + /// Checks for instances of `map_err(|_| Some::Enum)` /// - /// **Why is this bad?** This `map_err` throws away the original error rather than allowing the enum to contain and report the cause of the error + /// ### Why is this bad? + /// This `map_err` throws away the original error rather than allowing the enum to contain and report the cause of the error /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// Before: /// ```rust /// use std::fmt; diff --git a/clippy_lints/src/map_unit_fn.rs b/clippy_lints/src/map_unit_fn.rs index 57cd907e77e..fd40590d077 100644 --- a/clippy_lints/src/map_unit_fn.rs +++ b/clippy_lints/src/map_unit_fn.rs @@ -12,16 +12,15 @@ use rustc_span::source_map::Span; use rustc_span::sym; declare_clippy_lint! { - /// **What it does:** Checks for usage of `option.map(f)` where f is a function + /// ### What it does + /// Checks for usage of `option.map(f)` where f is a function /// or closure that returns the unit type `()`. /// - /// **Why is this bad?** Readability, this can be written more clearly with + /// ### Why is this bad? + /// Readability, this can be written more clearly with /// an if let statement /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust /// # fn do_stuff() -> Option { Some(String::new()) } /// # fn log_err_msg(foo: String) -> Option { Some(foo) } @@ -54,16 +53,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for usage of `result.map(f)` where f is a function + /// ### What it does + /// Checks for usage of `result.map(f)` where f is a function /// or closure that returns the unit type `()`. /// - /// **Why is this bad?** Readability, this can be written more clearly with + /// ### Why is this bad? + /// Readability, this can be written more clearly with /// an if let statement /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust /// # fn do_stuff() -> Result { Ok(String::new()) } /// # fn log_err_msg(foo: String) -> Result { Ok(foo) } diff --git a/clippy_lints/src/match_on_vec_items.rs b/clippy_lints/src/match_on_vec_items.rs index ca6fb0831fe..e66a35452f0 100644 --- a/clippy_lints/src/match_on_vec_items.rs +++ b/clippy_lints/src/match_on_vec_items.rs @@ -10,13 +10,13 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::sym; declare_clippy_lint! { - /// **What it does:** Checks for `match vec[idx]` or `match vec[n..m]`. + /// ### What it does + /// Checks for `match vec[idx]` or `match vec[n..m]`. /// - /// **Why is this bad?** This can panic at runtime. + /// ### Why is this bad? + /// This can panic at runtime. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust, no_run /// let arr = vec![0, 1, 2, 3]; /// let idx = 1; diff --git a/clippy_lints/src/matches.rs b/clippy_lints/src/matches.rs index d7f600b3ab2..5360c02f905 100644 --- a/clippy_lints/src/matches.rs +++ b/clippy_lints/src/matches.rs @@ -35,14 +35,14 @@ use std::iter; use std::ops::Bound; declare_clippy_lint! { - /// **What it does:** Checks for matches with a single arm where an `if let` + /// ### What it does + /// Checks for matches with a single arm where an `if let` /// will usually suffice. /// - /// **Why is this bad?** Just readability – `if let` nests less than a `match`. + /// ### Why is this bad? + /// Just readability – `if let` nests less than a `match`. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// # fn bar(stool: &str) {} /// # let x = Some("abc"); @@ -63,15 +63,17 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for matches with two arms where an `if let else` will + /// ### What it does + /// Checks for matches with two arms where an `if let else` will /// usually suffice. /// - /// **Why is this bad?** Just readability – `if let` nests less than a `match`. - /// - /// **Known problems:** Personal style preferences may differ. + /// ### Why is this bad? + /// Just readability – `if let` nests less than a `match`. /// - /// **Example:** + /// ### Known problems + /// Personal style preferences may differ. /// + /// ### Example /// Using `match`: /// /// ```rust @@ -102,16 +104,16 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for matches where all arms match a reference, + /// ### What it does + /// Checks for matches where all arms match a reference, /// suggesting to remove the reference and deref the matched expression /// instead. It also checks for `if let &foo = bar` blocks. /// - /// **Why is this bad?** It just makes the code less readable. That reference + /// ### Why is this bad? + /// It just makes the code less readable. That reference /// destructuring adds nothing to the code. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust,ignore /// // Bad /// match x { @@ -133,14 +135,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for matches where match expression is a `bool`. It + /// ### What it does + /// Checks for matches where match expression is a `bool`. It /// suggests to replace the expression with an `if...else` block. /// - /// **Why is this bad?** It makes the code less readable. + /// ### Why is this bad? + /// It makes the code less readable. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// # fn foo() {} /// # fn bar() {} @@ -167,14 +169,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for overlapping match arms. + /// ### What it does + /// Checks for overlapping match arms. /// - /// **Why is this bad?** It is likely to be an error and if not, makes the code + /// ### Why is this bad? + /// It is likely to be an error and if not, makes the code /// less obvious. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// let x = 5; /// match x { @@ -189,15 +191,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for arm which matches all errors with `Err(_)` + /// ### What it does + /// Checks for arm which matches all errors with `Err(_)` /// and take drastic actions like `panic!`. /// - /// **Why is this bad?** It is generally a bad practice, similar to + /// ### Why is this bad? + /// It is generally a bad practice, similar to /// catching all exceptions in java with `catch(Exception)` /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// let x: Result = Ok(3); /// match x { @@ -211,14 +213,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for match which is used to add a reference to an + /// ### What it does + /// Checks for match which is used to add a reference to an /// `Option` value. /// - /// **Why is this bad?** Using `as_ref()` or `as_mut()` instead is shorter. + /// ### Why is this bad? + /// Using `as_ref()` or `as_mut()` instead is shorter. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// let x: Option<()> = None; /// @@ -237,14 +239,17 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for wildcard enum matches using `_`. + /// ### What it does + /// Checks for wildcard enum matches using `_`. /// - /// **Why is this bad?** New enum variants added by library updates can be missed. + /// ### Why is this bad? + /// New enum variants added by library updates can be missed. /// - /// **Known problems:** Suggested replacements may be incorrect if guards exhaustively cover some + /// ### Known problems + /// Suggested replacements may be incorrect if guards exhaustively cover some /// variants, and also may not use correct path to enum if it's not present in the current scope. /// - /// **Example:** + /// ### Example /// ```rust /// # enum Foo { A(usize), B(usize) } /// # let x = Foo::B(1); @@ -266,15 +271,17 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for wildcard enum matches for a single variant. + /// ### What it does + /// Checks for wildcard enum matches for a single variant. /// - /// **Why is this bad?** New enum variants added by library updates can be missed. + /// ### Why is this bad? + /// New enum variants added by library updates can be missed. /// - /// **Known problems:** Suggested replacements may not use correct path to enum + /// ### Known problems + /// Suggested replacements may not use correct path to enum /// if it's not present in the current scope. /// - /// **Example:** - /// + /// ### Example /// ```rust /// # enum Foo { A, B, C } /// # let x = Foo::B; @@ -298,14 +305,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for wildcard pattern used with others patterns in same match arm. + /// ### What it does + /// Checks for wildcard pattern used with others patterns in same match arm. /// - /// **Why is this bad?** Wildcard pattern already covers any other pattern as it will match anyway. + /// ### Why is this bad? + /// Wildcard pattern already covers any other pattern as it will match anyway. /// It makes the code less readable, especially to spot wildcard pattern use in match arm. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// // Bad /// match "foo" { @@ -325,14 +332,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for matches being used to destructure a single-variant enum + /// ### What it does + /// Checks for matches being used to destructure a single-variant enum /// or tuple struct where a `let` will suffice. /// - /// **Why is this bad?** Just readability – `let` doesn't nest, whereas a `match` does. + /// ### Why is this bad? + /// Just readability – `let` doesn't nest, whereas a `match` does. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// enum Wrapper { /// Data(i32), @@ -360,14 +367,17 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for useless match that binds to only one value. + /// ### What it does + /// Checks for useless match that binds to only one value. /// - /// **Why is this bad?** Readability and needless complexity. + /// ### Why is this bad? + /// Readability and needless complexity. /// - /// **Known problems:** Suggested replacements may be incorrect when `match` + /// ### Known problems + /// Suggested replacements may be incorrect when `match` /// is actually binding temporary value, bringing a 'dropped while borrowed' error. /// - /// **Example:** + /// ### Example /// ```rust /// # let a = 1; /// # let b = 2; @@ -388,14 +398,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for unnecessary '..' pattern binding on struct when all fields are explicitly matched. + /// ### What it does + /// Checks for unnecessary '..' pattern binding on struct when all fields are explicitly matched. /// - /// **Why is this bad?** Correctness and readability. It's like having a wildcard pattern after + /// ### Why is this bad? + /// Correctness and readability. It's like having a wildcard pattern after /// matching all enum variants explicitly. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// # struct A { a: i32 } /// let a = A { a: 5 }; @@ -418,21 +428,23 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Lint for redundant pattern matching over `Result`, `Option`, + /// ### What it does + /// Lint for redundant pattern matching over `Result`, `Option`, /// `std::task::Poll` or `std::net::IpAddr` /// - /// **Why is this bad?** It's more concise and clear to just use the proper + /// ### Why is this bad? + /// It's more concise and clear to just use the proper /// utility function /// - /// **Known problems:** This will change the drop order for the matched type. Both `if let` and + /// ### Known problems + /// This will change the drop order for the matched type. Both `if let` and /// `while let` will drop the value at the end of the block, both `if` and `while` will drop the /// value before entering the block. For most types this change will not matter, but for a few /// types this will not be an acceptable change (e.g. locks). See the /// [reference](https://doc.rust-lang.org/reference/destructors.html#drop-scopes) for more about /// drop order. /// - /// **Example:** - /// + /// ### Example /// ```rust /// # use std::task::Poll; /// # use std::net::{IpAddr, Ipv4Addr, Ipv6Addr}; @@ -471,15 +483,18 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for `match` or `if let` expressions producing a + /// ### What it does + /// Checks for `match` or `if let` expressions producing a /// `bool` that could be written using `matches!` /// - /// **Why is this bad?** Readability and needless complexity. + /// ### Why is this bad? + /// Readability and needless complexity. /// - /// **Known problems:** This lint falsely triggers, if there are arms with + /// ### Known problems + /// This lint falsely triggers, if there are arms with /// `cfg` attributes that remove an arm evaluating to `false`. /// - /// **Example:** + /// ### Example /// ```rust /// let x = Some(5); /// @@ -504,17 +519,20 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for `match` with identical arm bodies. + /// ### What it does + /// Checks for `match` with identical arm bodies. /// - /// **Why is this bad?** This is probably a copy & paste error. If arm bodies + /// ### Why is this bad? + /// This is probably a copy & paste error. If arm bodies /// are the same on purpose, you can factor them /// [using `|`](https://doc.rust-lang.org/book/patterns.html#multiple-patterns). /// - /// **Known problems:** False positive possible with order dependent `match` + /// ### Known problems + /// False positive possible with order dependent `match` /// (see issue /// [#860](https://github.com/rust-lang/rust-clippy/issues/860)). /// - /// **Example:** + /// ### Example /// ```rust,ignore /// match foo { /// Bar => bar(), diff --git a/clippy_lints/src/mem_discriminant.rs b/clippy_lints/src/mem_discriminant.rs index aca96e06ef2..59176c4b846 100644 --- a/clippy_lints/src/mem_discriminant.rs +++ b/clippy_lints/src/mem_discriminant.rs @@ -9,14 +9,14 @@ use rustc_lint::{LateContext, LateLintPass}; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks for calls of `mem::discriminant()` on a non-enum type. + /// ### What it does + /// Checks for calls of `mem::discriminant()` on a non-enum type. /// - /// **Why is this bad?** The value of `mem::discriminant()` on non-enum types + /// ### Why is this bad? + /// The value of `mem::discriminant()` on non-enum types /// is unspecified. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// use std::mem; /// diff --git a/clippy_lints/src/mem_forget.rs b/clippy_lints/src/mem_forget.rs index a28cb5f32fe..07202a59c4b 100644 --- a/clippy_lints/src/mem_forget.rs +++ b/clippy_lints/src/mem_forget.rs @@ -5,15 +5,15 @@ use rustc_lint::{LateContext, LateLintPass}; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks for usage of `std::mem::forget(t)` where `t` is + /// ### What it does + /// Checks for usage of `std::mem::forget(t)` where `t` is /// `Drop`. /// - /// **Why is this bad?** `std::mem::forget(t)` prevents `t` from running its + /// ### Why is this bad? + /// `std::mem::forget(t)` prevents `t` from running its /// destructor, possibly causing leaks. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// # use std::mem; /// # use std::rc::Rc; diff --git a/clippy_lints/src/mem_replace.rs b/clippy_lints/src/mem_replace.rs index 183daee3617..3d071c9081b 100644 --- a/clippy_lints/src/mem_replace.rs +++ b/clippy_lints/src/mem_replace.rs @@ -14,16 +14,16 @@ use rustc_span::source_map::Span; use rustc_span::symbol::sym; declare_clippy_lint! { - /// **What it does:** Checks for `mem::replace()` on an `Option` with + /// ### What it does + /// Checks for `mem::replace()` on an `Option` with /// `None`. /// - /// **Why is this bad?** `Option` already has the method `take()` for + /// ### Why is this bad? + /// `Option` already has the method `take()` for /// taking its current value (Some(..) or None) and replacing it with /// `None`. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// use std::mem; /// @@ -41,17 +41,16 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for `mem::replace(&mut _, mem::uninitialized())` + /// ### What it does + /// Checks for `mem::replace(&mut _, mem::uninitialized())` /// and `mem::replace(&mut _, mem::zeroed())`. /// - /// **Why is this bad?** This will lead to undefined behavior even if the + /// ### Why is this bad? + /// This will lead to undefined behavior even if the /// value is overwritten later, because the uninitialized value may be /// observed in the case of a panic. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ``` /// use std::mem; ///# fn may_panic(v: Vec) -> Vec { v } @@ -73,15 +72,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for `std::mem::replace` on a value of type + /// ### What it does + /// Checks for `std::mem::replace` on a value of type /// `T` with `T::default()`. /// - /// **Why is this bad?** `std::mem` module already has the method `take` to + /// ### Why is this bad? + /// `std::mem` module already has the method `take` to /// take the current value and replace it with the default value of that type. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// let mut text = String::from("foo"); /// let replaced = std::mem::replace(&mut text, String::default()); diff --git a/clippy_lints/src/methods/mod.rs b/clippy_lints/src/methods/mod.rs index 283fcf281df..d3e12023814 100644 --- a/clippy_lints/src/methods/mod.rs +++ b/clippy_lints/src/methods/mod.rs @@ -80,16 +80,15 @@ use rustc_span::{sym, Span}; use rustc_typeck::hir_ty_to_ty; declare_clippy_lint! { - /// **What it does:** Checks for usages of `cloned()` on an `Iterator` or `Option` where + /// ### What it does + /// Checks for usages of `cloned()` on an `Iterator` or `Option` where /// `copied()` could be used instead. /// - /// **Why is this bad?** `copied()` is better because it guarantees that the type being cloned + /// ### Why is this bad? + /// `copied()` is better because it guarantees that the type being cloned /// implements `Copy`. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust /// [1, 2, 3].iter().cloned(); /// ``` @@ -103,16 +102,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for usages of `Iterator::flat_map()` where `filter_map()` could be + /// ### What it does + /// Checks for usages of `Iterator::flat_map()` where `filter_map()` could be /// used instead. /// - /// **Why is this bad?** When applicable, `filter_map()` is more clear since it shows that + /// ### Why is this bad? + /// When applicable, `filter_map()` is more clear since it shows that /// `Option` is used to produce 0 or 1 items. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust /// let nums: Vec = ["1", "2", "whee!"].iter().flat_map(|x| x.parse().ok()).collect(); /// ``` @@ -126,9 +124,11 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for `.unwrap()` calls on `Option`s and on `Result`s. + /// ### What it does + /// Checks for `.unwrap()` calls on `Option`s and on `Result`s. /// - /// **Why is this bad?** It is better to handle the `None` or `Err` case, + /// ### Why is this bad? + /// It is better to handle the `None` or `Err` case, /// or at least call `.expect(_)` with a more helpful message. Still, for a lot of /// quick-and-dirty code, `unwrap` is a good choice, which is why this lint is /// `Allow` by default. @@ -141,9 +141,7 @@ declare_clippy_lint! { /// messages on display. Therefore, it may be beneficial to look at the places /// where they may get displayed. Activate this lint to do just that. /// - /// **Known problems:** None. - /// - /// **Examples:** + /// ### Examples /// ```rust /// # let opt = Some(1); /// @@ -171,9 +169,11 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for `.expect()` calls on `Option`s and `Result`s. + /// ### What it does + /// Checks for `.expect()` calls on `Option`s and `Result`s. /// - /// **Why is this bad?** Usually it is better to handle the `None` or `Err` case. + /// ### Why is this bad? + /// Usually it is better to handle the `None` or `Err` case. /// Still, for a lot of quick-and-dirty code, `expect` is a good choice, which is why /// this lint is `Allow` by default. /// @@ -181,9 +181,7 @@ declare_clippy_lint! { /// values. Normally, you want to implement more sophisticated error handling, /// and propagate errors upwards with `?` operator. /// - /// **Known problems:** None. - /// - /// **Examples:** + /// ### Examples /// ```rust,ignore /// # let opt = Some(1); /// @@ -213,20 +211,20 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for methods that should live in a trait + /// ### What it does + /// Checks for methods that should live in a trait /// implementation of a `std` trait (see [llogiq's blog /// post](http://llogiq.github.io/2015/07/30/traits.html) for further /// information) instead of an inherent implementation. /// - /// **Why is this bad?** Implementing the traits improve ergonomics for users of + /// ### Why is this bad? + /// Implementing the traits improve ergonomics for users of /// the code, often with very little cost. Also people seeing a `mul(...)` /// method /// may expect `*` to work equally, so you should have good reason to disappoint /// them. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// struct X; /// impl X { @@ -242,7 +240,8 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for methods with certain name prefixes and which + /// ### What it does + /// Checks for methods with certain name prefixes and which /// doesn't match how self is taken. The actual rules are: /// /// |Prefix |Postfix |`self` taken | `self` type | @@ -265,13 +264,12 @@ declare_clippy_lint! { /// Please find more info here: /// https://rust-lang.github.io/api-guidelines/naming.html#ad-hoc-conversions-follow-as_-to_-into_-conventions-c-conv /// - /// **Why is this bad?** Consistency breeds readability. If you follow the + /// ### Why is this bad? + /// Consistency breeds readability. If you follow the /// conventions, your users won't be surprised that they, e.g., need to supply a /// mutable reference to a `as_..` function. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// # struct X; /// impl X { @@ -287,14 +285,17 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for usage of `ok().expect(..)`. + /// ### What it does + /// Checks for usage of `ok().expect(..)`. /// - /// **Why is this bad?** Because you usually call `expect()` on the `Result` + /// ### Why is this bad? + /// Because you usually call `expect()` on the `Result` /// directly to get a better error message. /// - /// **Known problems:** The error type needs to implement `Debug` + /// ### Known problems + /// The error type needs to implement `Debug` /// - /// **Example:** + /// ### Example /// ```rust /// # let x = Ok::<_, ()>(()); /// @@ -310,15 +311,18 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for usage of `option.map(_).unwrap_or(_)` or `option.map(_).unwrap_or_else(_)` or + /// ### What it does + /// Checks for usage of `option.map(_).unwrap_or(_)` or `option.map(_).unwrap_or_else(_)` or /// `result.map(_).unwrap_or_else(_)`. /// - /// **Why is this bad?** Readability, these can be written more concisely (resp.) as + /// ### Why is this bad? + /// Readability, these can be written more concisely (resp.) as /// `option.map_or(_, _)`, `option.map_or_else(_, _)` and `result.map_or_else(_, _)`. /// - /// **Known problems:** The order of the arguments is not in execution order + /// ### Known problems + /// The order of the arguments is not in execution order /// - /// **Examples:** + /// ### Examples /// ```rust /// # let x = Some(1); /// @@ -347,14 +351,17 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for usage of `_.map_or(None, _)`. + /// ### What it does + /// Checks for usage of `_.map_or(None, _)`. /// - /// **Why is this bad?** Readability, this can be written more concisely as + /// ### Why is this bad? + /// Readability, this can be written more concisely as /// `_.and_then(_)`. /// - /// **Known problems:** The order of the arguments is not in execution order. + /// ### Known problems + /// The order of the arguments is not in execution order. /// - /// **Example:** + /// ### Example /// ```rust /// # let opt = Some(1); /// @@ -370,15 +377,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for usage of `_.map_or(None, Some)`. + /// ### What it does + /// Checks for usage of `_.map_or(None, Some)`. /// - /// **Why is this bad?** Readability, this can be written more concisely as + /// ### Why is this bad? + /// Readability, this can be written more concisely as /// `_.ok()`. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// Bad: /// ```rust /// # let r: Result = Ok(1); @@ -396,16 +402,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for usage of `_.and_then(|x| Some(y))`, `_.and_then(|x| Ok(y))` or + /// ### What it does + /// Checks for usage of `_.and_then(|x| Some(y))`, `_.and_then(|x| Ok(y))` or /// `_.or_else(|x| Err(y))`. /// - /// **Why is this bad?** Readability, this can be written more concisely as + /// ### Why is this bad? + /// Readability, this can be written more concisely as /// `_.map(|x| y)` or `_.map_err(|x| y)`. /// - /// **Known problems:** None - /// - /// **Example:** - /// + /// ### Example /// ```rust /// # fn opt() -> Option<&'static str> { Some("42") } /// # fn res() -> Result<&'static str, &'static str> { Ok("42") } @@ -429,14 +434,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for usage of `_.filter(_).next()`. + /// ### What it does + /// Checks for usage of `_.filter(_).next()`. /// - /// **Why is this bad?** Readability, this can be written more concisely as + /// ### Why is this bad? + /// Readability, this can be written more concisely as /// `_.find(_)`. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// # let vec = vec![1]; /// vec.iter().filter(|x| **x == 0).next(); @@ -452,14 +457,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for usage of `_.skip_while(condition).next()`. + /// ### What it does + /// Checks for usage of `_.skip_while(condition).next()`. /// - /// **Why is this bad?** Readability, this can be written more concisely as + /// ### Why is this bad? + /// Readability, this can be written more concisely as /// `_.find(!condition)`. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// # let vec = vec![1]; /// vec.iter().skip_while(|x| **x == 0).next(); @@ -475,14 +480,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for usage of `_.map(_).flatten(_)` on `Iterator` and `Option` + /// ### What it does + /// Checks for usage of `_.map(_).flatten(_)` on `Iterator` and `Option` /// - /// **Why is this bad?** Readability, this can be written more concisely as + /// ### Why is this bad? + /// Readability, this can be written more concisely as /// `_.flat_map(_)` /// - /// **Known problems:** - /// - /// **Example:** + /// ### Example /// ```rust /// let vec = vec![vec![1]]; /// @@ -498,15 +503,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for usage of `_.filter(_).map(_)` that can be written more simply + /// ### What it does + /// Checks for usage of `_.filter(_).map(_)` that can be written more simply /// as `filter_map(_)`. /// - /// **Why is this bad?** Redundant code in the `filter` and `map` operations is poor style and + /// ### Why is this bad? + /// Redundant code in the `filter` and `map` operations is poor style and /// less performant. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// Bad: /// ```rust /// (0_i32..10) @@ -524,15 +529,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for usage of `_.find(_).map(_)` that can be written more simply + /// ### What it does + /// Checks for usage of `_.find(_).map(_)` that can be written more simply /// as `find_map(_)`. /// - /// **Why is this bad?** Redundant code in the `find` and `map` operations is poor style and + /// ### Why is this bad? + /// Redundant code in the `find` and `map` operations is poor style and /// less performant. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// Bad: /// ```rust /// (0_i32..10) @@ -550,14 +555,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for usage of `_.filter_map(_).next()`. + /// ### What it does + /// Checks for usage of `_.filter_map(_).next()`. /// - /// **Why is this bad?** Readability, this can be written more concisely as + /// ### Why is this bad? + /// Readability, this can be written more concisely as /// `_.find_map(_)`. /// - /// **Known problems:** None - /// - /// **Example:** + /// ### Example /// ```rust /// (0..3).filter_map(|x| if x == 2 { Some(x) } else { None }).next(); /// ``` @@ -572,13 +577,13 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for usage of `flat_map(|x| x)`. + /// ### What it does + /// Checks for usage of `flat_map(|x| x)`. /// - /// **Why is this bad?** Readability, this can be written more concisely by using `flatten`. + /// ### Why is this bad? + /// Readability, this can be written more concisely by using `flatten`. /// - /// **Known problems:** None - /// - /// **Example:** + /// ### Example /// ```rust /// # let iter = vec![vec![0]].into_iter(); /// iter.flat_map(|x| x); @@ -594,16 +599,16 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for an iterator or string search (such as `find()`, + /// ### What it does + /// Checks for an iterator or string search (such as `find()`, /// `position()`, or `rposition()`) followed by a call to `is_some()` or `is_none()`. /// - /// **Why is this bad?** Readability, this can be written more concisely as: + /// ### Why is this bad? + /// Readability, this can be written more concisely as: /// * `_.any(_)`, or `_.contains(_)` for `is_some()`, /// * `!_.any(_)`, or `!_.contains(_)` for `is_none()`. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// let vec = vec![1]; /// vec.iter().find(|x| **x == 0).is_some(); @@ -623,15 +628,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for usage of `.chars().next()` on a `str` to check + /// ### What it does + /// Checks for usage of `.chars().next()` on a `str` to check /// if it starts with a given char. /// - /// **Why is this bad?** Readability, this can be written more concisely as + /// ### Why is this bad? + /// Readability, this can be written more concisely as /// `_.starts_with(_)`. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// let name = "foo"; /// if name.chars().next() == Some('_') {}; @@ -647,17 +652,20 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for calls to `.or(foo(..))`, `.unwrap_or(foo(..))`, + /// ### What it does + /// Checks for calls to `.or(foo(..))`, `.unwrap_or(foo(..))`, /// etc., and suggests to use `or_else`, `unwrap_or_else`, etc., or /// `unwrap_or_default` instead. /// - /// **Why is this bad?** The function will always be called and potentially + /// ### Why is this bad? + /// The function will always be called and potentially /// allocate an object acting as the default. /// - /// **Known problems:** If the function has side-effects, not calling it will + /// ### Known problems + /// If the function has side-effects, not calling it will /// change the semantic of the program, but you shouldn't rely on that anyway. /// - /// **Example:** + /// ### Example /// ```rust /// # let foo = Some(String::new()); /// foo.unwrap_or(String::new()); @@ -678,15 +686,18 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for calls to `.expect(&format!(...))`, `.expect(foo(..))`, + /// ### What it does + /// Checks for calls to `.expect(&format!(...))`, `.expect(foo(..))`, /// etc., and suggests to use `unwrap_or_else` instead /// - /// **Why is this bad?** The function will always be called. + /// ### Why is this bad? + /// The function will always be called. /// - /// **Known problems:** If the function has side-effects, not calling it will + /// ### Known problems + /// If the function has side-effects, not calling it will /// change the semantics of the program, but you shouldn't rely on that anyway. /// - /// **Example:** + /// ### Example /// ```rust /// # let foo = Some(String::new()); /// # let err_code = "418"; @@ -713,14 +724,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for usage of `.clone()` on a `Copy` type. + /// ### What it does + /// Checks for usage of `.clone()` on a `Copy` type. /// - /// **Why is this bad?** The only reason `Copy` types implement `Clone` is for + /// ### Why is this bad? + /// The only reason `Copy` types implement `Clone` is for /// generics, not for using the `clone` method on a concrete type. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// 42u64.clone(); /// ``` @@ -730,15 +741,17 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for usage of `.clone()` on a ref-counted pointer, + /// ### What it does + /// Checks for usage of `.clone()` on a ref-counted pointer, /// (`Rc`, `Arc`, `rc::Weak`, or `sync::Weak`), and suggests calling Clone via unified /// function syntax instead (e.g., `Rc::clone(foo)`). /// - /// **Why is this bad?** Calling '.clone()' on an Rc, Arc, or Weak + /// ### Why is this bad? + /// Calling '.clone()' on an Rc, Arc, or Weak /// can obscure the fact that only the pointer is being cloned, not the underlying /// data. /// - /// **Example:** + /// ### Example /// ```rust /// # use std::rc::Rc; /// let x = Rc::new(1); @@ -755,14 +768,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for usage of `.clone()` on an `&&T`. + /// ### What it does + /// Checks for usage of `.clone()` on an `&&T`. /// - /// **Why is this bad?** Cloning an `&&T` copies the inner `&T`, instead of + /// ### Why is this bad? + /// Cloning an `&&T` copies the inner `&T`, instead of /// cloning the underlying `T`. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// fn main() { /// let x = vec![1]; @@ -777,16 +790,16 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for usage of `.to_string()` on an `&&T` where + /// ### What it does + /// Checks for usage of `.to_string()` on an `&&T` where /// `T` implements `ToString` directly (like `&&str` or `&&String`). /// - /// **Why is this bad?** This bypasses the specialized implementation of + /// ### Why is this bad? + /// This bypasses the specialized implementation of /// `ToString` and instead goes through the more expensive string formatting /// facilities. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// // Generic implementation for `T: Display` is used (slow) /// ["foo", "bar"].iter().map(|s| s.to_string()); @@ -800,14 +813,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for `new` not returning a type that contains `Self`. + /// ### What it does + /// Checks for `new` not returning a type that contains `Self`. /// - /// **Why is this bad?** As a convention, `new` methods are used to make a new + /// ### Why is this bad? + /// As a convention, `new` methods are used to make a new /// instance of a type. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// In an impl block: /// ```rust /// # struct Foo; @@ -861,15 +874,18 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for string methods that receive a single-character + /// ### What it does + /// Checks for string methods that receive a single-character /// `str` as an argument, e.g., `_.split("x")`. /// - /// **Why is this bad?** Performing these methods using a `char` is faster than + /// ### Why is this bad? + /// Performing these methods using a `char` is faster than /// using a `str`. /// - /// **Known problems:** Does not catch multi-byte unicode characters. + /// ### Known problems + /// Does not catch multi-byte unicode characters. /// - /// **Example:** + /// ### Example /// ```rust,ignore /// // Bad /// _.split("x"); @@ -882,14 +898,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for calling `.step_by(0)` on iterators which panics. + /// ### What it does + /// Checks for calling `.step_by(0)` on iterators which panics. /// - /// **Why is this bad?** This very much looks like an oversight. Use `panic!()` instead if you + /// ### Why is this bad? + /// This very much looks like an oversight. Use `panic!()` instead if you /// actually intend to panic. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust,should_panic /// for x in (0..100).step_by(0) { /// //.. @@ -901,15 +917,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for indirect collection of populated `Option` + /// ### What it does + /// Checks for indirect collection of populated `Option` /// - /// **Why is this bad?** `Option` is like a collection of 0-1 things, so `flatten` + /// ### Why is this bad? + /// `Option` is like a collection of 0-1 things, so `flatten` /// automatically does this without suspicious-looking `unwrap` calls. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust /// let _ = std::iter::empty::>().filter(Option::is_some).map(Option::unwrap); /// ``` @@ -923,16 +938,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for the use of `iter.nth(0)`. + /// ### What it does + /// Checks for the use of `iter.nth(0)`. /// - /// **Why is this bad?** `iter.next()` is equivalent to + /// ### Why is this bad? + /// `iter.next()` is equivalent to /// `iter.nth(0)`, as they both consume the next element, /// but is more readable. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust /// # use std::collections::HashSet; /// // Bad @@ -951,15 +965,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for use of `.iter().nth()` (and the related + /// ### What it does + /// Checks for use of `.iter().nth()` (and the related /// `.iter_mut().nth()`) on standard library types with O(1) element access. /// - /// **Why is this bad?** `.get()` and `.get_mut()` are more efficient and more + /// ### Why is this bad? + /// `.get()` and `.get_mut()` are more efficient and more /// readable. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// let some_vec = vec![0, 1, 2, 3]; /// let bad_vec = some_vec.iter().nth(3); @@ -977,13 +991,13 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for use of `.skip(x).next()` on iterators. - /// - /// **Why is this bad?** `.nth(x)` is cleaner + /// ### What it does + /// Checks for use of `.skip(x).next()` on iterators. /// - /// **Known problems:** None. + /// ### Why is this bad? + /// `.nth(x)` is cleaner /// - /// **Example:** + /// ### Example /// ```rust /// let some_vec = vec![0, 1, 2, 3]; /// let bad_vec = some_vec.iter().skip(3).next(); @@ -1001,13 +1015,16 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for use of `.get().unwrap()` (or + /// ### What it does + /// Checks for use of `.get().unwrap()` (or /// `.get_mut().unwrap`) on a standard library type which implements `Index` /// - /// **Why is this bad?** Using the Index trait (`[]`) is more clear and more + /// ### Why is this bad? + /// Using the Index trait (`[]`) is more clear and more /// concise. /// - /// **Known problems:** Not a replacement for error handling: Using either + /// ### Known problems + /// Not a replacement for error handling: Using either /// `.unwrap()` or the Index trait (`[]`) carries the risk of causing a `panic` /// if the value being accessed is `None`. If the use of `.get().unwrap()` is a /// temporary placeholder for dealing with the `Option` type, then this does @@ -1016,7 +1033,7 @@ declare_clippy_lint! { /// is handled in a future refactor instead of using `.unwrap()` or the Index /// trait. /// - /// **Example:** + /// ### Example /// ```rust /// let mut some_vec = vec![0, 1, 2, 3]; /// let last = some_vec.get(3).unwrap(); @@ -1034,14 +1051,13 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for occurrences where one vector gets extended instead of append + /// ### What it does + /// Checks for occurrences where one vector gets extended instead of append /// - /// **Why is this bad?** Using `append` instead of `extend` is more concise and faster - /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Why is this bad? + /// Using `append` instead of `extend` is more concise and faster /// + /// ### Example /// ```rust /// let mut a = vec![1, 2, 3]; /// let mut b = vec![4, 5, 6]; @@ -1058,14 +1074,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for the use of `.extend(s.chars())` where s is a + /// ### What it does + /// Checks for the use of `.extend(s.chars())` where s is a /// `&str` or `String`. /// - /// **Why is this bad?** `.push_str(s)` is clearer + /// ### Why is this bad? + /// `.push_str(s)` is clearer /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// let abc = "abc"; /// let def = String::from("def"); @@ -1087,14 +1103,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for the use of `.cloned().collect()` on slice to + /// ### What it does + /// Checks for the use of `.cloned().collect()` on slice to /// create a `Vec`. /// - /// **Why is this bad?** `.to_vec()` is clearer - /// - /// **Known problems:** None. + /// ### Why is this bad? + /// `.to_vec()` is clearer /// - /// **Example:** + /// ### Example /// ```rust /// let s = [1, 2, 3, 4, 5]; /// let s2: Vec = s[..].iter().cloned().collect(); @@ -1110,15 +1126,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for usage of `_.chars().last()` or + /// ### What it does + /// Checks for usage of `_.chars().last()` or /// `_.chars().next_back()` on a `str` to check if it ends with a given char. /// - /// **Why is this bad?** Readability, this can be written more concisely as + /// ### Why is this bad? + /// Readability, this can be written more concisely as /// `_.ends_with(_)`. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// # let name = "_"; /// @@ -1134,14 +1150,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for usage of `.as_ref()` or `.as_mut()` where the + /// ### What it does + /// Checks for usage of `.as_ref()` or `.as_mut()` where the /// types before and after the call are the same. /// - /// **Why is this bad?** The call is unnecessary. - /// - /// **Known problems:** None. + /// ### Why is this bad? + /// The call is unnecessary. /// - /// **Example:** + /// ### Example /// ```rust /// # fn do_stuff(x: &[i32]) {} /// let x: &[i32] = &[1, 2, 3, 4, 5]; @@ -1159,15 +1175,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for using `fold` when a more succinct alternative exists. + /// ### What it does + /// Checks for using `fold` when a more succinct alternative exists. /// Specifically, this checks for `fold`s which could be replaced by `any`, `all`, /// `sum` or `product`. /// - /// **Why is this bad?** Readability. - /// - /// **Known problems:** None. + /// ### Why is this bad? + /// Readability. /// - /// **Example:** + /// ### Example /// ```rust /// let _ = (0..3).fold(false, |acc, x| acc || x > 2); /// ``` @@ -1181,16 +1197,16 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for `filter_map` calls which could be replaced by `filter` or `map`. + /// ### What it does + /// Checks for `filter_map` calls which could be replaced by `filter` or `map`. /// More specifically it checks if the closure provided is only performing one of the /// filter or map operations and suggests the appropriate option. /// - /// **Why is this bad?** Complexity. The intent is also clearer if only a single + /// ### Why is this bad? + /// Complexity. The intent is also clearer if only a single /// operation is being performed. /// - /// **Known problems:** None - /// - /// **Example:** + /// ### Example /// ```rust /// let _ = (0..3).filter_map(|x| if x > 2 { Some(x) } else { None }); /// @@ -1210,17 +1226,16 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for `into_iter` calls on references which should be replaced by `iter` + /// ### What it does + /// Checks for `into_iter` calls on references which should be replaced by `iter` /// or `iter_mut`. /// - /// **Why is this bad?** Readability. Calling `into_iter` on a reference will not move out its + /// ### Why is this bad? + /// Readability. Calling `into_iter` on a reference will not move out its /// content into the resulting iterator, which is confusing. It is better just call `iter` or /// `iter_mut` directly. /// - /// **Known problems:** None - /// - /// **Example:** - /// + /// ### Example /// ```rust /// // Bad /// let _ = (&vec![3, 4, 5]).into_iter(); @@ -1234,16 +1249,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for calls to `map` followed by a `count`. + /// ### What it does + /// Checks for calls to `map` followed by a `count`. /// - /// **Why is this bad?** It looks suspicious. Maybe `map` was confused with `filter`. + /// ### Why is this bad? + /// It looks suspicious. Maybe `map` was confused with `filter`. /// If the `map` call is intentional, this should be rewritten. Or, if you intend to /// drive the iterator to completion, you can just use `for_each` instead. /// - /// **Known problems:** None - /// - /// **Example:** - /// + /// ### Example /// ```rust /// let _ = (0..3).map(|x| x + 2).count(); /// ``` @@ -1253,16 +1267,18 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for `MaybeUninit::uninit().assume_init()`. + /// ### What it does + /// Checks for `MaybeUninit::uninit().assume_init()`. /// - /// **Why is this bad?** For most types, this is undefined behavior. + /// ### Why is this bad? + /// For most types, this is undefined behavior. /// - /// **Known problems:** For now, we accept empty tuples and tuples / arrays + /// ### Known problems + /// For now, we accept empty tuples and tuples / arrays /// of `MaybeUninit`. There may be other types that allow uninitialized /// data, but those are not yet rigorously defined. /// - /// **Example:** - /// + /// ### Example /// ```rust /// // Beware the UB /// use std::mem::MaybeUninit; @@ -1285,12 +1301,13 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for `.checked_add/sub(x).unwrap_or(MAX/MIN)`. + /// ### What it does + /// Checks for `.checked_add/sub(x).unwrap_or(MAX/MIN)`. /// - /// **Why is this bad?** These can be written simply with `saturating_add/sub` methods. - /// - /// **Example:** + /// ### Why is this bad? + /// These can be written simply with `saturating_add/sub` methods. /// + /// ### Example /// ```rust /// # let y: u32 = 0; /// # let x: u32 = 100; @@ -1312,14 +1329,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for `offset(_)`, `wrapping_`{`add`, `sub`}, etc. on raw pointers to + /// ### What it does + /// Checks for `offset(_)`, `wrapping_`{`add`, `sub`}, etc. on raw pointers to /// zero-sized types /// - /// **Why is this bad?** This is a no-op, and likely unintended - /// - /// **Known problems:** None + /// ### Why is this bad? + /// This is a no-op, and likely unintended /// - /// **Example:** + /// ### Example /// ```rust /// unsafe { (&() as *const ()).offset(1) }; /// ``` @@ -1329,15 +1346,16 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for `FileType::is_file()`. + /// ### What it does + /// Checks for `FileType::is_file()`. /// - /// **Why is this bad?** When people testing a file type with `FileType::is_file` + /// ### Why is this bad? + /// When people testing a file type with `FileType::is_file` /// they are testing whether a path is something they can get bytes from. But /// `is_file` doesn't cover special file types in unix-like systems, and doesn't cover /// symlink in windows. Using `!FileType::is_dir()` is a better way to that intention. /// - /// **Example:** - /// + /// ### Example /// ```rust /// # || { /// let metadata = std::fs::metadata("foo.txt")?; @@ -1369,14 +1387,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for usage of `_.as_ref().map(Deref::deref)` or it's aliases (such as String::as_str). + /// ### What it does + /// Checks for usage of `_.as_ref().map(Deref::deref)` or it's aliases (such as String::as_str). /// - /// **Why is this bad?** Readability, this can be written more concisely as + /// ### Why is this bad? + /// Readability, this can be written more concisely as /// `_.as_deref()`. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// # let opt = Some("".to_string()); /// opt.as_ref().map(String::as_str) @@ -1394,13 +1412,13 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for usage of `iter().next()` on a Slice or an Array - /// - /// **Why is this bad?** These can be shortened into `.get()` + /// ### What it does + /// Checks for usage of `iter().next()` on a Slice or an Array /// - /// **Known problems:** None. + /// ### Why is this bad? + /// These can be shortened into `.get()` /// - /// **Example:** + /// ### Example /// ```rust /// # let a = [1, 2, 3]; /// # let b = vec![1, 2, 3]; @@ -1420,14 +1438,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Warns when using `push_str`/`insert_str` with a single-character string literal + /// ### What it does + /// Warns when using `push_str`/`insert_str` with a single-character string literal /// where `push`/`insert` with a `char` would work fine. /// - /// **Why is this bad?** It's less clear that we are pushing a single character. + /// ### Why is this bad? + /// It's less clear that we are pushing a single character. /// - /// **Known problems:** None - /// - /// **Example:** + /// ### Example /// ```rust /// let mut string = String::new(); /// string.insert_str(0, "R"); @@ -1445,7 +1463,8 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** As the counterpart to `or_fun_call`, this lint looks for unnecessary + /// ### What it does + /// As the counterpart to `or_fun_call`, this lint looks for unnecessary /// lazily evaluated closures on `Option` and `Result`. /// /// This lint suggests changing the following functions, when eager evaluation results in @@ -1456,13 +1475,14 @@ declare_clippy_lint! { /// - `get_or_insert_with` to `get_or_insert` /// - `ok_or_else` to `ok_or` /// - /// **Why is this bad?** Using eager evaluation is shorter and simpler in some cases. + /// ### Why is this bad? + /// Using eager evaluation is shorter and simpler in some cases. /// - /// **Known problems:** It is possible, but not recommended for `Deref` and `Index` to have + /// ### Known problems + /// It is possible, but not recommended for `Deref` and `Index` to have /// side effects. Eagerly evaluating them can change the semantics of the program. /// - /// **Example:** - /// + /// ### Example /// ```rust /// // example code where clippy issues a warning /// let opt: Option = None; @@ -1481,14 +1501,13 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for usage of `_.map(_).collect::()`. - /// - /// **Why is this bad?** Using `try_for_each` instead is more readable and idiomatic. - /// - /// **Known problems:** None + /// ### What it does + /// Checks for usage of `_.map(_).collect::()`. /// - /// **Example:** + /// ### Why is this bad? + /// Using `try_for_each` instead is more readable and idiomatic. /// + /// ### Example /// ```rust /// (0..3).map(|t| Err(t)).collect::>(); /// ``` @@ -1502,16 +1521,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for `from_iter()` function calls on types that implement the `FromIterator` + /// ### What it does + /// Checks for `from_iter()` function calls on types that implement the `FromIterator` /// trait. /// - /// **Why is this bad?** It is recommended style to use collect. See + /// ### Why is this bad? + /// It is recommended style to use collect. See /// [FromIterator documentation](https://doc.rust-lang.org/std/iter/trait.FromIterator.html) /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust /// use std::iter::FromIterator; /// @@ -1535,15 +1553,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for usage of `inspect().for_each()`. + /// ### What it does + /// Checks for usage of `inspect().for_each()`. /// - /// **Why is this bad?** It is the same as performing the computation + /// ### Why is this bad? + /// It is the same as performing the computation /// inside `inspect` at the beginning of the closure in `for_each`. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust /// [1,2,3,4,5].iter() /// .inspect(|&x| println!("inspect the number: {}", x)) @@ -1565,14 +1582,13 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for usage of `filter_map(|x| x)`. - /// - /// **Why is this bad?** Readability, this can be written more concisely by using `flatten`. + /// ### What it does + /// Checks for usage of `filter_map(|x| x)`. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Why is this bad? + /// Readability, this can be written more concisely by using `flatten`. /// + /// ### Example /// ```rust /// # let iter = vec![Some(1)].into_iter(); /// iter.filter_map(|x| x); @@ -1588,14 +1604,13 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for instances of `map(f)` where `f` is the identity function. - /// - /// **Why is this bad?** It can be written more concisely without the call to `map`. + /// ### What it does + /// Checks for instances of `map(f)` where `f` is the identity function. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Why is this bad? + /// It can be written more concisely without the call to `map`. /// + /// ### Example /// ```rust /// let x = [1, 2, 3]; /// let y: Vec<_> = x.iter().map(|x| x).map(|x| 2*x).collect(); @@ -1611,15 +1626,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for the use of `.bytes().nth()`. + /// ### What it does + /// Checks for the use of `.bytes().nth()`. /// - /// **Why is this bad?** `.as_bytes().get()` is more efficient and more + /// ### Why is this bad? + /// `.as_bytes().get()` is more efficient and more /// readable. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust /// // Bad /// let _ = "Hello".bytes().nth(3); @@ -1633,15 +1647,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for the usage of `_.to_owned()`, `vec.to_vec()`, or similar when calling `_.clone()` would be clearer. + /// ### What it does + /// Checks for the usage of `_.to_owned()`, `vec.to_vec()`, or similar when calling `_.clone()` would be clearer. /// - /// **Why is this bad?** These methods do the same thing as `_.clone()` but may be confusing as + /// ### Why is this bad? + /// These methods do the same thing as `_.clone()` but may be confusing as /// to why we are calling `to_vec` on something that is already a `Vec` or calling `to_owned` on something that is already owned. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust /// let a = vec![1, 2, 3]; /// let b = a.to_vec(); @@ -1659,15 +1672,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for the use of `.iter().count()`. + /// ### What it does + /// Checks for the use of `.iter().count()`. /// - /// **Why is this bad?** `.len()` is more efficient and more + /// ### Why is this bad? + /// `.len()` is more efficient and more /// readable. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust /// // Bad /// let some_vec = vec![0, 1, 2, 3]; @@ -1685,17 +1697,16 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for calls to [`splitn`] + /// ### What it does + /// Checks for calls to [`splitn`] /// (https://doc.rust-lang.org/std/primitive.str.html#method.splitn) and /// related functions with either zero or one splits. /// - /// **Why is this bad?** These calls don't actually split the value and are + /// ### Why is this bad? + /// These calls don't actually split the value and are /// likely to be intended as a different number. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust /// // Bad /// let s = ""; @@ -1715,14 +1726,13 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for manual implementations of `str::repeat` - /// - /// **Why is this bad?** These are both harder to read, as well as less performant. - /// - /// **Known problems:** None. + /// ### What it does + /// Checks for manual implementations of `str::repeat` /// - /// **Example:** + /// ### Why is this bad? + /// These are both harder to read, as well as less performant. /// + /// ### Example /// ```rust /// // Bad /// let x: String = std::iter::repeat('x').take(10).collect(); diff --git a/clippy_lints/src/minmax.rs b/clippy_lints/src/minmax.rs index ff3473b744e..dc2dd45e4ed 100644 --- a/clippy_lints/src/minmax.rs +++ b/clippy_lints/src/minmax.rs @@ -8,15 +8,15 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use std::cmp::Ordering; declare_clippy_lint! { - /// **What it does:** Checks for expressions where `std::cmp::min` and `max` are + /// ### What it does + /// Checks for expressions where `std::cmp::min` and `max` are /// used to clamp values, but switched so that the result is constant. /// - /// **Why is this bad?** This is in all probability not the intended outcome. At + /// ### Why is this bad? + /// This is in all probability not the intended outcome. At /// the least it hurts readability of the code. /// - /// **Known problems:** None - /// - /// **Example:** + /// ### Example /// ```ignore /// min(0, max(100, x)) /// ``` diff --git a/clippy_lints/src/misc.rs b/clippy_lints/src/misc.rs index 7cfce2e61cc..c796abe9815 100644 --- a/clippy_lints/src/misc.rs +++ b/clippy_lints/src/misc.rs @@ -25,10 +25,12 @@ use clippy_utils::{ }; declare_clippy_lint! { - /// **What it does:** Checks for function arguments and let bindings denoted as + /// ### What it does + /// Checks for function arguments and let bindings denoted as /// `ref`. /// - /// **Why is this bad?** The `ref` declaration makes the function take an owned + /// ### Why is this bad? + /// The `ref` declaration makes the function take an owned /// value, but turns the argument into a reference (which means that the value /// is destroyed when exiting the function). This adds not much value: either /// take a reference type, or take an owned value and create references in the @@ -37,11 +39,12 @@ declare_clippy_lint! { /// For let bindings, `let x = &foo;` is preferred over `let ref x = foo`. The /// type of `x` is more obvious with the former. /// - /// **Known problems:** If the argument is dereferenced within the function, + /// ### Known problems + /// If the argument is dereferenced within the function, /// removing the `ref` will lead to errors. This can be fixed by removing the /// dereferences, e.g., changing `*x` to `x` within the function. /// - /// **Example:** + /// ### Example /// ```rust,ignore /// // Bad /// fn foo(ref x: u8) -> bool { @@ -59,14 +62,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for comparisons to NaN. + /// ### What it does + /// Checks for comparisons to NaN. /// - /// **Why is this bad?** NaN does not compare meaningfully to anything – not + /// ### Why is this bad? + /// NaN does not compare meaningfully to anything – not /// even itself – so those comparisons are simply wrong. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// # let x = 1.0; /// @@ -82,18 +85,18 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for (in-)equality comparisons on floating-point + /// ### What it does + /// Checks for (in-)equality comparisons on floating-point /// values (apart from zero), except in functions called `*eq*` (which probably /// implement equality for a type involving floats). /// - /// **Why is this bad?** Floating point calculations are usually imprecise, so + /// ### Why is this bad? + /// Floating point calculations are usually imprecise, so /// asking if two values are *exactly* equal is asking for trouble. For a good /// guide on what to do, see [the floating point /// guide](http://www.floating-point-gui.de/errors/comparison). /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// let x = 1.2331f64; /// let y = 1.2332f64; @@ -115,16 +118,16 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for conversions to owned values just for the sake + /// ### What it does + /// Checks for conversions to owned values just for the sake /// of a comparison. /// - /// **Why is this bad?** The comparison can operate on a reference, so creating + /// ### Why is this bad? + /// The comparison can operate on a reference, so creating /// an owned value effectively throws it away directly afterwards, which is /// needlessly consuming code and heap space. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// # let x = "foo"; /// # let y = String::from("foo"); @@ -142,18 +145,18 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for getting the remainder of a division by one or minus + /// ### What it does + /// Checks for getting the remainder of a division by one or minus /// one. /// - /// **Why is this bad?** The result for a divisor of one can only ever be zero; for + /// ### Why is this bad? + /// The result for a divisor of one can only ever be zero; for /// minus one it can cause panic/overflow (if the left operand is the minimal value of /// the respective integer type) or results in zero. No one will write such code /// deliberately, unless trying to win an Underhanded Rust Contest. Even for that /// contest, it's probably a bad idea. Use something more underhanded. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// # let x = 1; /// let a = x % 1; @@ -165,17 +168,20 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for the use of bindings with a single leading + /// ### What it does + /// Checks for the use of bindings with a single leading /// underscore. /// - /// **Why is this bad?** A single leading underscore is usually used to indicate + /// ### Why is this bad? + /// A single leading underscore is usually used to indicate /// that a binding will not be used. Using such a binding breaks this /// expectation. /// - /// **Known problems:** The lint does not work properly with desugaring and + /// ### Known problems + /// The lint does not work properly with desugaring and /// macro, it has been allowed in the mean time. /// - /// **Example:** + /// ### Example /// ```rust /// let _x = 0; /// let y = _x + 1; // Here we are using `_x`, even though it has a leading @@ -187,17 +193,17 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for the use of short circuit boolean conditions as + /// ### What it does + /// Checks for the use of short circuit boolean conditions as /// a /// statement. /// - /// **Why is this bad?** Using a short circuit boolean condition as a statement + /// ### Why is this bad? + /// Using a short circuit boolean condition as a statement /// may hide the fact that the second part is executed or not depending on the /// outcome of the first part. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust,ignore /// f() && g(); // We should write `if f() { g(); }`. /// ``` @@ -207,15 +213,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Catch casts from `0` to some pointer type + /// ### What it does + /// Catch casts from `0` to some pointer type /// - /// **Why is this bad?** This generally means `null` and is better expressed as + /// ### Why is this bad? + /// This generally means `null` and is better expressed as /// {`std`, `core`}`::ptr::`{`null`, `null_mut`}. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust /// // Bad /// let a = 0 as *const u32; @@ -229,18 +234,18 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for (in-)equality comparisons on floating-point + /// ### What it does + /// Checks for (in-)equality comparisons on floating-point /// value and constant, except in functions called `*eq*` (which probably /// implement equality for a type involving floats). /// - /// **Why is this bad?** Floating point calculations are usually imprecise, so + /// ### Why is this bad? + /// Floating point calculations are usually imprecise, so /// asking if two values are *exactly* equal is asking for trouble. For a good /// guide on what to do, see [the floating point /// guide](http://www.floating-point-gui.de/errors/comparison). /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// let x: f64 = 1.0; /// const ONE: f64 = 1.00; diff --git a/clippy_lints/src/misc_early/mod.rs b/clippy_lints/src/misc_early/mod.rs index 050b6805b7c..06fe967dafc 100644 --- a/clippy_lints/src/misc_early/mod.rs +++ b/clippy_lints/src/misc_early/mod.rs @@ -18,14 +18,14 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::source_map::Span; declare_clippy_lint! { - /// **What it does:** Checks for structure field patterns bound to wildcards. + /// ### What it does + /// Checks for structure field patterns bound to wildcards. /// - /// **Why is this bad?** Using `..` instead is shorter and leaves the focus on + /// ### Why is this bad? + /// Using `..` instead is shorter and leaves the focus on /// the fields that are actually bound. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// # struct Foo { /// # a: i32, @@ -52,14 +52,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for function arguments having the similar names + /// ### What it does + /// Checks for function arguments having the similar names /// differing by an underscore. /// - /// **Why is this bad?** It affects code readability. - /// - /// **Known problems:** None. + /// ### Why is this bad? + /// It affects code readability. /// - /// **Example:** + /// ### Example /// ```rust /// // Bad /// fn foo(a: i32, _a: i32) {} @@ -73,14 +73,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Detects expressions of the form `--x`. + /// ### What it does + /// Detects expressions of the form `--x`. /// - /// **Why is this bad?** It can mislead C/C++ programmers to think `x` was + /// ### Why is this bad? + /// It can mislead C/C++ programmers to think `x` was /// decremented. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// let mut x = 3; /// --x; @@ -91,14 +91,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Warns on hexadecimal literals with mixed-case letter + /// ### What it does + /// Warns on hexadecimal literals with mixed-case letter /// digits. /// - /// **Why is this bad?** It looks confusing. + /// ### Why is this bad? + /// It looks confusing. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// // Bad /// let y = 0x1a9BAcD; @@ -112,14 +112,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Warns if literal suffixes are not separated by an + /// ### What it does + /// Warns if literal suffixes are not separated by an /// underscore. /// - /// **Why is this bad?** It is much less readable. - /// - /// **Known problems:** None. + /// ### Why is this bad? + /// It is much less readable. /// - /// **Example:** + /// ### Example /// ```rust /// // Bad /// let y = 123832i32; @@ -133,17 +133,17 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Warns if an integral constant literal starts with `0`. + /// ### What it does + /// Warns if an integral constant literal starts with `0`. /// - /// **Why is this bad?** In some languages (including the infamous C language + /// ### Why is this bad? + /// In some languages (including the infamous C language /// and most of its /// family), this marks an octal constant. In Rust however, this is a decimal /// constant. This could /// be confusing for both the writer and a reader of the constant. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// /// In Rust: /// ```rust @@ -171,13 +171,13 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Warns if a generic shadows a built-in type. - /// - /// **Why is this bad?** This gives surprising type errors. + /// ### What it does + /// Warns if a generic shadows a built-in type. /// - /// **Known problems:** None. + /// ### Why is this bad? + /// This gives surprising type errors. /// - /// **Example:** + /// ### Example /// /// ```ignore /// impl Foo { @@ -192,14 +192,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for patterns in the form `name @ _`. + /// ### What it does + /// Checks for patterns in the form `name @ _`. /// - /// **Why is this bad?** It's almost always more readable to just use direct + /// ### Why is this bad? + /// It's almost always more readable to just use direct /// bindings. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// # let v = Some("abc"); /// @@ -221,19 +221,19 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for tuple patterns with a wildcard + /// ### What it does + /// Checks for tuple patterns with a wildcard /// pattern (`_`) is next to a rest pattern (`..`). /// /// _NOTE_: While `_, ..` means there is at least one element left, `..` /// means there are 0 or more elements left. This can make a difference /// when refactoring, but shouldn't result in errors in the refactored code, /// since the wildcard pattern isn't used anyway. - /// **Why is this bad?** The wildcard pattern is unneeded as the rest pattern + /// ### Why is this bad? + /// The wildcard pattern is unneeded as the rest pattern /// can match that element as well. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// # struct TupleStruct(u32, u32, u32); /// # let t = TupleStruct(1, 2, 3); diff --git a/clippy_lints/src/missing_const_for_fn.rs b/clippy_lints/src/missing_const_for_fn.rs index 59cbc481ed4..5b2584d43a1 100644 --- a/clippy_lints/src/missing_const_for_fn.rs +++ b/clippy_lints/src/missing_const_for_fn.rs @@ -13,16 +13,13 @@ use rustc_span::Span; use rustc_typeck::hir_ty_to_ty; declare_clippy_lint! { - /// **What it does:** - /// + /// ### What it does /// Suggests the use of `const` in functions and methods where possible. /// - /// **Why is this bad?** - /// + /// ### Why is this bad? /// Not having the function const prevents callers of the function from being const as well. /// - /// **Known problems:** - /// + /// ### Known problems /// Const functions are currently still being worked on, with some features only being available /// on nightly. This lint does not consider all edge cases currently and the suggestions may be /// incorrect if you are using this lint on stable. @@ -42,8 +39,7 @@ declare_clippy_lint! { /// can't be const as it calls a non-const function. Making `a` const and running Clippy again, /// will suggest to make `b` const, too. /// - /// **Example:** - /// + /// ### Example /// ```rust /// # struct Foo { /// # random_number: usize, diff --git a/clippy_lints/src/missing_doc.rs b/clippy_lints/src/missing_doc.rs index ec1572c26c2..aeed8268902 100644 --- a/clippy_lints/src/missing_doc.rs +++ b/clippy_lints/src/missing_doc.rs @@ -17,15 +17,15 @@ use rustc_span::source_map::Span; use rustc_span::sym; declare_clippy_lint! { - /// **What it does:** Warns if there is missing doc for any documentable item + /// ### What it does + /// Warns if there is missing doc for any documentable item /// (public or private). /// - /// **Why is this bad?** Doc is good. *rustc* has a `MISSING_DOCS` + /// ### Why is this bad? + /// Doc is good. *rustc* has a `MISSING_DOCS` /// allowed-by-default lint for /// public members, but has no way to enforce documentation of private items. /// This lint fixes that. - /// - /// **Known problems:** None. pub MISSING_DOCS_IN_PRIVATE_ITEMS, restriction, "detects missing documentation for public and private members" diff --git a/clippy_lints/src/missing_enforced_import_rename.rs b/clippy_lints/src/missing_enforced_import_rename.rs index 59565350f72..9d27870321c 100644 --- a/clippy_lints/src/missing_enforced_import_rename.rs +++ b/clippy_lints/src/missing_enforced_import_rename.rs @@ -10,17 +10,16 @@ use rustc_span::Symbol; use crate::utils::conf::Rename; declare_clippy_lint! { - /// **What it does:** Checks for imports that do not rename the item as specified + /// ### What it does + /// Checks for imports that do not rename the item as specified /// in the `enforce-import-renames` config option. /// - /// **Why is this bad?** Consistency is important, if a project has defined import + /// ### Why is this bad? + /// Consistency is important, if a project has defined import /// renames they should be followed. More practically, some item names are too /// vague outside of their defining scope this can enforce a more meaningful naming. /// - /// **Known problems:** None - /// - /// **Example:** - /// + /// ### Example /// An example clippy.toml configuration: /// ```toml /// # clippy.toml diff --git a/clippy_lints/src/missing_inline.rs b/clippy_lints/src/missing_inline.rs index 041fe64a1a9..be5b4b4006f 100644 --- a/clippy_lints/src/missing_inline.rs +++ b/clippy_lints/src/missing_inline.rs @@ -7,10 +7,12 @@ use rustc_span::source_map::Span; use rustc_span::sym; declare_clippy_lint! { - /// **What it does:** it lints if an exported function, method, trait method with default impl, + /// ### What it does + /// it lints if an exported function, method, trait method with default impl, /// or trait method impl is not `#[inline]`. /// - /// **Why is this bad?** In general, it is not. Functions can be inlined across + /// ### Why is this bad? + /// In general, it is not. Functions can be inlined across /// crates when that's profitable as long as any form of LTO is used. When LTO is disabled, /// functions that are not `#[inline]` cannot be inlined across crates. Certain types of crates /// might intend for most of the methods in their public API to be able to be inlined across @@ -18,9 +20,7 @@ declare_clippy_lint! { /// sense. It allows the crate to require all exported methods to be `#[inline]` by default, and /// then opt out for specific methods where this might not make sense. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// pub fn foo() {} // missing #[inline] /// fn ok() {} // ok diff --git a/clippy_lints/src/modulo_arithmetic.rs b/clippy_lints/src/modulo_arithmetic.rs index 1414fdc1b11..2d14943b56c 100644 --- a/clippy_lints/src/modulo_arithmetic.rs +++ b/clippy_lints/src/modulo_arithmetic.rs @@ -9,18 +9,18 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use std::fmt::Display; declare_clippy_lint! { - /// **What it does:** Checks for modulo arithmetic. + /// ### What it does + /// Checks for modulo arithmetic. /// - /// **Why is this bad?** The results of modulo (%) operation might differ + /// ### Why is this bad? + /// The results of modulo (%) operation might differ /// depending on the language, when negative numbers are involved. /// If you interop with different languages it might be beneficial /// to double check all places that use modulo arithmetic. /// /// For example, in Rust `17 % -3 = 2`, but in Python `17 % -3 = -1`. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// let x = -17 % 3; /// ``` diff --git a/clippy_lints/src/multiple_crate_versions.rs b/clippy_lints/src/multiple_crate_versions.rs index f5ce3e32551..1c61970fdc8 100644 --- a/clippy_lints/src/multiple_crate_versions.rs +++ b/clippy_lints/src/multiple_crate_versions.rs @@ -13,17 +13,20 @@ use if_chain::if_chain; use itertools::Itertools; declare_clippy_lint! { - /// **What it does:** Checks to see if multiple versions of a crate are being + /// ### What it does + /// Checks to see if multiple versions of a crate are being /// used. /// - /// **Why is this bad?** This bloats the size of targets, and can lead to + /// ### Why is this bad? + /// This bloats the size of targets, and can lead to /// confusing error messages when structs or traits are used interchangeably /// between different versions of a crate. /// - /// **Known problems:** Because this can be caused purely by the dependencies + /// ### Known problems + /// Because this can be caused purely by the dependencies /// themselves, it's not always possible to fix this issue. /// - /// **Example:** + /// ### Example /// ```toml /// # This will pull in both winapi v0.3.x and v0.2.x, triggering a warning. /// [dependencies] diff --git a/clippy_lints/src/mut_key.rs b/clippy_lints/src/mut_key.rs index 68f7cdf6ea0..2c7681c45a4 100644 --- a/clippy_lints/src/mut_key.rs +++ b/clippy_lints/src/mut_key.rs @@ -10,18 +10,21 @@ use rustc_span::symbol::sym; use std::iter; declare_clippy_lint! { - /// **What it does:** Checks for sets/maps with mutable key types. + /// ### What it does + /// Checks for sets/maps with mutable key types. /// - /// **Why is this bad?** All of `HashMap`, `HashSet`, `BTreeMap` and + /// ### Why is this bad? + /// All of `HashMap`, `HashSet`, `BTreeMap` and /// `BtreeSet` rely on either the hash or the order of keys be unchanging, /// so having types with interior mutability is a bad idea. /// - /// **Known problems:** It's correct to use a struct, that contains interior mutability + /// ### Known problems + /// It's correct to use a struct, that contains interior mutability /// as a key, when its `Hash` implementation doesn't access any of the interior mutable types. /// However, this lint is unable to recognize this, so it causes a false positive in theses cases. /// The `bytes` crate is a great example of this. /// - /// **Example:** + /// ### Example /// ```rust /// use std::cmp::{PartialEq, Eq}; /// use std::collections::HashSet; diff --git a/clippy_lints/src/mut_mut.rs b/clippy_lints/src/mut_mut.rs index 4b9c51d0c16..d5032c5ba7f 100644 --- a/clippy_lints/src/mut_mut.rs +++ b/clippy_lints/src/mut_mut.rs @@ -9,15 +9,15 @@ use rustc_middle::ty; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks for instances of `mut mut` references. + /// ### What it does + /// Checks for instances of `mut mut` references. /// - /// **Why is this bad?** Multiple `mut`s don't add anything meaningful to the + /// ### Why is this bad? + /// Multiple `mut`s don't add anything meaningful to the /// source. This is either a copy'n'paste error, or it shows a fundamental /// misunderstanding of references. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// # let mut y = 1; /// let x = &mut &mut y; diff --git a/clippy_lints/src/mut_mutex_lock.rs b/clippy_lints/src/mut_mutex_lock.rs index b9ba74c7d02..85e870632a5 100644 --- a/clippy_lints/src/mut_mutex_lock.rs +++ b/clippy_lints/src/mut_mutex_lock.rs @@ -8,17 +8,16 @@ use rustc_middle::ty; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks for `&mut Mutex::lock` calls + /// ### What it does + /// Checks for `&mut Mutex::lock` calls /// - /// **Why is this bad?** `Mutex::lock` is less efficient than + /// ### Why is this bad? + /// `Mutex::lock` is less efficient than /// calling `Mutex::get_mut`. In addition you also have a statically /// guarantee that the mutex isn't locked, instead of just a runtime /// guarantee. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust /// use std::sync::{Arc, Mutex}; /// diff --git a/clippy_lints/src/mut_reference.rs b/clippy_lints/src/mut_reference.rs index 6efe8ffcde0..8d5d7951fc5 100644 --- a/clippy_lints/src/mut_reference.rs +++ b/clippy_lints/src/mut_reference.rs @@ -7,15 +7,15 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use std::iter; declare_clippy_lint! { - /// **What it does:** Detects passing a mutable reference to a function that only + /// ### What it does + /// Detects passing a mutable reference to a function that only /// requires an immutable reference. /// - /// **Why is this bad?** The mutable reference rules out all other references to + /// ### Why is this bad? + /// The mutable reference rules out all other references to /// the value. Also the code misleads about the intent of the call site. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```ignore /// // Bad /// my_vec.push(&mut value) diff --git a/clippy_lints/src/mutable_debug_assertion.rs b/clippy_lints/src/mutable_debug_assertion.rs index 81bf853300f..ee50891cc31 100644 --- a/clippy_lints/src/mutable_debug_assertion.rs +++ b/clippy_lints/src/mutable_debug_assertion.rs @@ -9,17 +9,17 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::Span; declare_clippy_lint! { - /// **What it does:** Checks for function/method calls with a mutable + /// ### What it does + /// Checks for function/method calls with a mutable /// parameter in `debug_assert!`, `debug_assert_eq!` and `debug_assert_ne!` macros. /// - /// **Why is this bad?** In release builds `debug_assert!` macros are optimized out by the + /// ### Why is this bad? + /// In release builds `debug_assert!` macros are optimized out by the /// compiler. /// Therefore mutating something in a `debug_assert!` macro results in different behaviour /// between a release and debug build. /// - /// **Known problems:** None - /// - /// **Example:** + /// ### Example /// ```rust,ignore /// debug_assert_eq!(vec![3].pop(), Some(3)); /// // or diff --git a/clippy_lints/src/mutex_atomic.rs b/clippy_lints/src/mutex_atomic.rs index 354e2c3fb74..436ceec6cfa 100644 --- a/clippy_lints/src/mutex_atomic.rs +++ b/clippy_lints/src/mutex_atomic.rs @@ -10,17 +10,20 @@ use rustc_middle::ty::{self, Ty}; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks for usages of `Mutex` where an atomic will do. + /// ### What it does + /// Checks for usages of `Mutex` where an atomic will do. /// - /// **Why is this bad?** Using a mutex just to make access to a plain bool or + /// ### Why is this bad? + /// Using a mutex just to make access to a plain bool or /// reference sequential is shooting flies with cannons. /// `std::sync::atomic::AtomicBool` and `std::sync::atomic::AtomicPtr` are leaner and /// faster. /// - /// **Known problems:** This lint cannot detect if the mutex is actually used + /// ### Known problems + /// This lint cannot detect if the mutex is actually used /// for waiting before a critical section. /// - /// **Example:** + /// ### Example /// ```rust /// # let y = true; /// @@ -38,17 +41,20 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for usages of `Mutex` where `X` is an integral + /// ### What it does + /// Checks for usages of `Mutex` where `X` is an integral /// type. /// - /// **Why is this bad?** Using a mutex just to make access to a plain integer + /// ### Why is this bad? + /// Using a mutex just to make access to a plain integer /// sequential is /// shooting flies with cannons. `std::sync::atomic::AtomicUsize` is leaner and faster. /// - /// **Known problems:** This lint cannot detect if the mutex is actually used + /// ### Known problems + /// This lint cannot detect if the mutex is actually used /// for waiting before a critical section. /// - /// **Example:** + /// ### Example /// ```rust /// # use std::sync::Mutex; /// let x = Mutex::new(0usize); diff --git a/clippy_lints/src/needless_arbitrary_self_type.rs b/clippy_lints/src/needless_arbitrary_self_type.rs index fe3c4455be5..9a3d9383cd9 100644 --- a/clippy_lints/src/needless_arbitrary_self_type.rs +++ b/clippy_lints/src/needless_arbitrary_self_type.rs @@ -9,13 +9,13 @@ use rustc_span::symbol::kw; use rustc_span::Span; declare_clippy_lint! { - /// **What it does:** The lint checks for `self` in fn parameters that + /// ### What it does + /// The lint checks for `self` in fn parameters that /// specify the `Self`-type explicitly - /// **Why is this bad?** Increases the amount and decreases the readability of code + /// ### Why is this bad? + /// Increases the amount and decreases the readability of code /// - /// **Known problems:** None - /// - /// **Example:** + /// ### Example /// ```rust /// enum ValType { /// I32, diff --git a/clippy_lints/src/needless_bitwise_bool.rs b/clippy_lints/src/needless_bitwise_bool.rs index b30bfbd4294..203da29cb91 100644 --- a/clippy_lints/src/needless_bitwise_bool.rs +++ b/clippy_lints/src/needless_bitwise_bool.rs @@ -9,20 +9,19 @@ use rustc_middle::ty; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** + /// ### What it does /// Checks for uses of bitwise and/or operators between booleans, where performance may be improved by using /// a lazy and. /// - /// **Why is this bad?** + /// ### Why is this bad? /// The bitwise operators do not support short-circuiting, so it may hinder code performance. /// Additionally, boolean logic "masked" as bitwise logic is not caught by lints like `unnecessary_fold` /// - /// **Known problems:** + /// ### Known problems /// This lint evaluates only when the right side is determined to have no side effects. At this time, that /// determination is quite conservative. /// - /// **Example:** - /// + /// ### Example /// ```rust /// let (x,y) = (true, false); /// if x & !y {} // where both x and y are booleans diff --git a/clippy_lints/src/needless_bool.rs b/clippy_lints/src/needless_bool.rs index 780690548e5..36f2829a5b9 100644 --- a/clippy_lints/src/needless_bool.rs +++ b/clippy_lints/src/needless_bool.rs @@ -15,17 +15,20 @@ use rustc_span::source_map::Spanned; use rustc_span::Span; declare_clippy_lint! { - /// **What it does:** Checks for expressions of the form `if c { true } else { + /// ### What it does + /// Checks for expressions of the form `if c { true } else { /// false }` (or vice versa) and suggests using the condition directly. /// - /// **Why is this bad?** Redundant code. + /// ### Why is this bad? + /// Redundant code. /// - /// **Known problems:** Maybe false positives: Sometimes, the two branches are + /// ### Known problems + /// Maybe false positives: Sometimes, the two branches are /// painstakingly documented (which we, of course, do not detect), so they *may* /// have some value. Even then, the documentation can be rewritten to match the /// shorter code. /// - /// **Example:** + /// ### Example /// ```rust,ignore /// if x { /// false @@ -43,15 +46,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for expressions of the form `x == true`, + /// ### What it does + /// Checks for expressions of the form `x == true`, /// `x != true` and order comparisons such as `x < true` (or vice versa) and /// suggest using the variable directly. /// - /// **Why is this bad?** Unnecessary code. + /// ### Why is this bad? + /// Unnecessary code. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust,ignore /// if x == true {} /// if y == false {} diff --git a/clippy_lints/src/needless_borrow.rs b/clippy_lints/src/needless_borrow.rs index dd1dfa2bdfb..3f0b23ee4d3 100644 --- a/clippy_lints/src/needless_borrow.rs +++ b/clippy_lints/src/needless_borrow.rs @@ -17,15 +17,15 @@ use rustc_session::{declare_tool_lint, impl_lint_pass}; use rustc_span::Span; declare_clippy_lint! { - /// **What it does:** Checks for address of operations (`&`) that are going to + /// ### What it does + /// Checks for address of operations (`&`) that are going to /// be dereferenced immediately by the compiler. /// - /// **Why is this bad?** Suggests that the receiver of the expression borrows + /// ### Why is this bad? + /// Suggests that the receiver of the expression borrows /// the expression. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// // Bad /// let x: &i32 = &&&&&&5; @@ -39,13 +39,13 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for `ref` bindings which create a reference to a reference. - /// - /// **Why is this bad?** The address-of operator at the use site is clearer about the need for a reference. + /// ### What it does + /// Checks for `ref` bindings which create a reference to a reference. /// - /// **Known problems:** None. + /// ### Why is this bad? + /// The address-of operator at the use site is clearer about the need for a reference. /// - /// **Example:** + /// ### Example /// ```rust /// // Bad /// let x = Some(""); diff --git a/clippy_lints/src/needless_borrowed_ref.rs b/clippy_lints/src/needless_borrowed_ref.rs index 0e976b130eb..36879eda7c0 100644 --- a/clippy_lints/src/needless_borrowed_ref.rs +++ b/clippy_lints/src/needless_borrowed_ref.rs @@ -7,12 +7,15 @@ use rustc_lint::{LateContext, LateLintPass}; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks for bindings that destructure a reference and borrow the inner + /// ### What it does + /// Checks for bindings that destructure a reference and borrow the inner /// value with `&ref`. /// - /// **Why is this bad?** This pattern has no effect in almost all cases. + /// ### Why is this bad? + /// This pattern has no effect in almost all cases. /// - /// **Known problems:** In some cases, `&ref` is needed to avoid a lifetime mismatch error. + /// ### Known problems + /// In some cases, `&ref` is needed to avoid a lifetime mismatch error. /// Example: /// ```rust /// fn foo(a: &Option, b: &Option) { @@ -23,7 +26,7 @@ declare_clippy_lint! { /// } /// ``` /// - /// **Example:** + /// ### Example /// Bad: /// ```rust /// let mut v = Vec::::new(); diff --git a/clippy_lints/src/needless_continue.rs b/clippy_lints/src/needless_continue.rs index 1d19413e0d0..5088b8bb0d3 100644 --- a/clippy_lints/src/needless_continue.rs +++ b/clippy_lints/src/needless_continue.rs @@ -42,20 +42,20 @@ use rustc_span::source_map::{original_sp, DUMMY_SP}; use rustc_span::Span; declare_clippy_lint! { - /// **What it does:** The lint checks for `if`-statements appearing in loops + /// ### What it does + /// The lint checks for `if`-statements appearing in loops /// that contain a `continue` statement in either their main blocks or their /// `else`-blocks, when omitting the `else`-block possibly with some /// rearrangement of code can make the code easier to understand. /// - /// **Why is this bad?** Having explicit `else` blocks for `if` statements + /// ### Why is this bad? + /// Having explicit `else` blocks for `if` statements /// containing `continue` in their THEN branch adds unnecessary branching and /// nesting to the code. Having an else block containing just `continue` can /// also be better written by grouping the statements following the whole `if` /// statement within the THEN block and omitting the else block completely. /// - /// **Known problems:** None - /// - /// **Example:** + /// ### Example /// ```rust /// # fn condition() -> bool { false } /// # fn update_condition() {} diff --git a/clippy_lints/src/needless_for_each.rs b/clippy_lints/src/needless_for_each.rs index a723a472a25..d9aa42fe8ee 100644 --- a/clippy_lints/src/needless_for_each.rs +++ b/clippy_lints/src/needless_for_each.rs @@ -16,18 +16,17 @@ use clippy_utils::source::snippet_with_applicability; use clippy_utils::ty::has_iter_method; declare_clippy_lint! { - /// **What it does:** Checks for usage of `for_each` that would be more simply written as a + /// ### What it does + /// Checks for usage of `for_each` that would be more simply written as a /// `for` loop. /// - /// **Why is this bad?** `for_each` may be used after applying iterator transformers like + /// ### Why is this bad? + /// `for_each` may be used after applying iterator transformers like /// `filter` for better readability and performance. It may also be used to fit a simple /// operation on one line. /// But when none of these apply, a simple `for` loop is more idiomatic. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust /// let v = vec![0, 1, 2]; /// v.iter().for_each(|elem| { diff --git a/clippy_lints/src/needless_pass_by_value.rs b/clippy_lints/src/needless_pass_by_value.rs index 283b1847b6c..03eeb54d8d1 100644 --- a/clippy_lints/src/needless_pass_by_value.rs +++ b/clippy_lints/src/needless_pass_by_value.rs @@ -24,20 +24,22 @@ use rustc_typeck::expr_use_visitor as euv; use std::borrow::Cow; declare_clippy_lint! { - /// **What it does:** Checks for functions taking arguments by value, but not + /// ### What it does + /// Checks for functions taking arguments by value, but not /// consuming them in its /// body. /// - /// **Why is this bad?** Taking arguments by reference is more flexible and can + /// ### Why is this bad? + /// Taking arguments by reference is more flexible and can /// sometimes avoid /// unnecessary allocations. /// - /// **Known problems:** + /// ### Known problems /// * This lint suggests taking an argument by reference, /// however sometimes it is better to let users decide the argument type /// (by using `Borrow` trait, for example), depending on how the function is used. /// - /// **Example:** + /// ### Example /// ```rust /// fn foo(v: Vec) { /// assert_eq!(v.len(), 42); diff --git a/clippy_lints/src/needless_question_mark.rs b/clippy_lints/src/needless_question_mark.rs index c64491c63e2..42e48336e15 100644 --- a/clippy_lints/src/needless_question_mark.rs +++ b/clippy_lints/src/needless_question_mark.rs @@ -10,15 +10,13 @@ use rustc_middle::ty::TyS; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** + /// ### What it does /// Suggests alternatives for useless applications of `?` in terminating expressions /// - /// **Why is this bad?** There's no reason to use `?` to short-circuit when execution of the body will end there anyway. - /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Why is this bad? + /// There's no reason to use `?` to short-circuit when execution of the body will end there anyway. /// + /// ### Example /// ```rust /// struct TO { /// magic: Option, diff --git a/clippy_lints/src/needless_update.rs b/clippy_lints/src/needless_update.rs index 8f325404deb..2a33b7392ca 100644 --- a/clippy_lints/src/needless_update.rs +++ b/clippy_lints/src/needless_update.rs @@ -5,18 +5,18 @@ use rustc_middle::ty; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks for needlessly including a base struct on update + /// ### What it does + /// Checks for needlessly including a base struct on update /// when all fields are changed anyway. /// /// This lint is not applied to structs marked with /// [non_exhaustive](https://doc.rust-lang.org/reference/attributes/type_system.html). /// - /// **Why is this bad?** This will cost resources (because the base has to be + /// ### Why is this bad? + /// This will cost resources (because the base has to be /// somewhere), and make the code less readable. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// # struct Point { /// # x: i32, diff --git a/clippy_lints/src/neg_cmp_op_on_partial_ord.rs b/clippy_lints/src/neg_cmp_op_on_partial_ord.rs index c824f6f54b5..6ad49b70605 100644 --- a/clippy_lints/src/neg_cmp_op_on_partial_ord.rs +++ b/clippy_lints/src/neg_cmp_op_on_partial_ord.rs @@ -8,19 +8,16 @@ use rustc_middle::lint::in_external_macro; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** + /// ### What it does /// Checks for the usage of negated comparison operators on types which only implement /// `PartialOrd` (e.g., `f64`). /// - /// **Why is this bad?** + /// ### Why is this bad? /// These operators make it easy to forget that the underlying types actually allow not only three /// potential Orderings (Less, Equal, Greater) but also a fourth one (Uncomparable). This is /// especially easy to miss if the operator based comparison result is negated. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust /// use std::cmp::Ordering; /// diff --git a/clippy_lints/src/neg_multiply.rs b/clippy_lints/src/neg_multiply.rs index d5e1ea6d242..fa36d8fb1b3 100644 --- a/clippy_lints/src/neg_multiply.rs +++ b/clippy_lints/src/neg_multiply.rs @@ -7,13 +7,16 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::source_map::Span; declare_clippy_lint! { - /// **What it does:** Checks for multiplication by -1 as a form of negation. + /// ### What it does + /// Checks for multiplication by -1 as a form of negation. /// - /// **Why is this bad?** It's more readable to just negate. + /// ### Why is this bad? + /// It's more readable to just negate. /// - /// **Known problems:** This only catches integers (for now). + /// ### Known problems + /// This only catches integers (for now). /// - /// **Example:** + /// ### Example /// ```ignore /// x * -1 /// ``` diff --git a/clippy_lints/src/new_without_default.rs b/clippy_lints/src/new_without_default.rs index bc409dd6efb..5c63d245bf1 100644 --- a/clippy_lints/src/new_without_default.rs +++ b/clippy_lints/src/new_without_default.rs @@ -13,18 +13,17 @@ use rustc_session::{declare_tool_lint, impl_lint_pass}; use rustc_span::sym; declare_clippy_lint! { - /// **What it does:** Checks for types with a `fn new() -> Self` method and no + /// ### What it does + /// Checks for types with a `fn new() -> Self` method and no /// implementation of /// [`Default`](https://doc.rust-lang.org/std/default/trait.Default.html). /// - /// **Why is this bad?** The user might expect to be able to use + /// ### Why is this bad? + /// The user might expect to be able to use /// [`Default`](https://doc.rust-lang.org/std/default/trait.Default.html) as the /// type can be constructed without arguments. /// - /// **Known problems:** Hopefully none. - /// - /// **Example:** - /// + /// ### Example /// ```ignore /// struct Foo(Bar); /// diff --git a/clippy_lints/src/no_effect.rs b/clippy_lints/src/no_effect.rs index 910b0536092..e07518b2586 100644 --- a/clippy_lints/src/no_effect.rs +++ b/clippy_lints/src/no_effect.rs @@ -9,15 +9,15 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use std::ops::Deref; declare_clippy_lint! { - /// **What it does:** Checks for statements which have no effect. + /// ### What it does + /// Checks for statements which have no effect. /// - /// **Why is this bad?** Similar to dead code, these statements are actually + /// ### Why is this bad? + /// Similar to dead code, these statements are actually /// executed. However, as they have no effect, all they do is make the code less /// readable. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// 0; /// ``` @@ -27,15 +27,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for expression statements that can be reduced to a + /// ### What it does + /// Checks for expression statements that can be reduced to a /// sub-expression. /// - /// **Why is this bad?** Expressions by themselves often have no side-effects. + /// ### Why is this bad? + /// Expressions by themselves often have no side-effects. /// Having such expressions reduces readability. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust,ignore /// compute_array()[0]; /// ``` diff --git a/clippy_lints/src/non_copy_const.rs b/clippy_lints/src/non_copy_const.rs index d775cd7c7f7..aa3067876eb 100644 --- a/clippy_lints/src/non_copy_const.rs +++ b/clippy_lints/src/non_copy_const.rs @@ -24,10 +24,12 @@ use rustc_typeck::hir_ty_to_ty; // FIXME: this is a correctness problem but there's no suitable // warn-by-default category. declare_clippy_lint! { - /// **What it does:** Checks for declaration of `const` items which is interior + /// ### What it does + /// Checks for declaration of `const` items which is interior /// mutable (e.g., contains a `Cell`, `Mutex`, `AtomicXxxx`, etc.). /// - /// **Why is this bad?** Consts are copied everywhere they are referenced, i.e., + /// ### Why is this bad? + /// Consts are copied everywhere they are referenced, i.e., /// every time you refer to the const a fresh instance of the `Cell` or `Mutex` /// or `AtomicXxxx` will be created, which defeats the whole purpose of using /// these types in the first place. @@ -35,7 +37,8 @@ declare_clippy_lint! { /// The `const` should better be replaced by a `static` item if a global /// variable is wanted, or replaced by a `const fn` if a constructor is wanted. /// - /// **Known problems:** A "non-constant" const item is a legacy way to supply an + /// ### Known problems + /// A "non-constant" const item is a legacy way to supply an /// initialized value to downstream `static` items (e.g., the /// `std::sync::ONCE_INIT` constant). In this case the use of `const` is legit, /// and this lint should be suppressed. @@ -52,7 +55,7 @@ declare_clippy_lint! { /// the interior mutable field is used or not. See issues /// [#5812](https://github.com/rust-lang/rust-clippy/issues/5812) and /// - /// **Example:** + /// ### Example /// ```rust /// use std::sync::atomic::{AtomicUsize, Ordering::SeqCst}; /// @@ -74,17 +77,20 @@ declare_clippy_lint! { // FIXME: this is a correctness problem but there's no suitable // warn-by-default category. declare_clippy_lint! { - /// **What it does:** Checks if `const` items which is interior mutable (e.g., + /// ### What it does + /// Checks if `const` items which is interior mutable (e.g., /// contains a `Cell`, `Mutex`, `AtomicXxxx`, etc.) has been borrowed directly. /// - /// **Why is this bad?** Consts are copied everywhere they are referenced, i.e., + /// ### Why is this bad? + /// Consts are copied everywhere they are referenced, i.e., /// every time you refer to the const a fresh instance of the `Cell` or `Mutex` /// or `AtomicXxxx` will be created, which defeats the whole purpose of using /// these types in the first place. /// /// The `const` value should be stored inside a `static` item. /// - /// **Known problems:** When an enum has variants with interior mutability, use of its non + /// ### Known problems + /// When an enum has variants with interior mutability, use of its non /// interior mutable variants can generate false positives. See issue /// [#3962](https://github.com/rust-lang/rust-clippy/issues/3962) /// @@ -93,7 +99,7 @@ declare_clippy_lint! { /// [#5812](https://github.com/rust-lang/rust-clippy/issues/5812) and /// [#3825](https://github.com/rust-lang/rust-clippy/issues/3825) /// - /// **Example:** + /// ### Example /// ```rust /// use std::sync::atomic::{AtomicUsize, Ordering::SeqCst}; /// const CONST_ATOM: AtomicUsize = AtomicUsize::new(12); diff --git a/clippy_lints/src/non_expressive_names.rs b/clippy_lints/src/non_expressive_names.rs index 7183a7c3858..dc55b103eb6 100644 --- a/clippy_lints/src/non_expressive_names.rs +++ b/clippy_lints/src/non_expressive_names.rs @@ -12,14 +12,14 @@ use rustc_span::symbol::{Ident, Symbol}; use std::cmp::Ordering; declare_clippy_lint! { - /// **What it does:** Checks for names that are very similar and thus confusing. + /// ### What it does + /// Checks for names that are very similar and thus confusing. /// - /// **Why is this bad?** It's hard to distinguish between names that differ only + /// ### Why is this bad? + /// It's hard to distinguish between names that differ only /// by a single character. /// - /// **Known problems:** None? - /// - /// **Example:** + /// ### Example /// ```ignore /// let checked_exp = something; /// let checked_expr = something_else; @@ -30,15 +30,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for too many variables whose name consists of a + /// ### What it does + /// Checks for too many variables whose name consists of a /// single character. /// - /// **Why is this bad?** It's hard to memorize what a variable means without a + /// ### Why is this bad? + /// It's hard to memorize what a variable means without a /// descriptive name. /// - /// **Known problems:** None? - /// - /// **Example:** + /// ### Example /// ```ignore /// let (a, b, c, d, e, f, g) = (...); /// ``` @@ -48,15 +48,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks if you have variables whose name consists of just + /// ### What it does + /// Checks if you have variables whose name consists of just /// underscores and digits. /// - /// **Why is this bad?** It's hard to memorize what a variable means without a + /// ### Why is this bad? + /// It's hard to memorize what a variable means without a /// descriptive name. /// - /// **Known problems:** None? - /// - /// **Example:** + /// ### Example /// ```rust /// let _1 = 1; /// let ___1 = 1; diff --git a/clippy_lints/src/non_octal_unix_permissions.rs b/clippy_lints/src/non_octal_unix_permissions.rs index a83daea97bf..3b74f69d375 100644 --- a/clippy_lints/src/non_octal_unix_permissions.rs +++ b/clippy_lints/src/non_octal_unix_permissions.rs @@ -9,15 +9,14 @@ use rustc_lint::{LateContext, LateLintPass}; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks for non-octal values used to set Unix file permissions. + /// ### What it does + /// Checks for non-octal values used to set Unix file permissions. /// - /// **Why is this bad?** They will be converted into octal, creating potentially + /// ### Why is this bad? + /// They will be converted into octal, creating potentially /// unintended file permissions. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust,ignore /// use std::fs::OpenOptions; /// use std::os::unix::fs::OpenOptionsExt; diff --git a/clippy_lints/src/nonstandard_macro_braces.rs b/clippy_lints/src/nonstandard_macro_braces.rs index 043e7fa30d6..dbe9cbe0ded 100644 --- a/clippy_lints/src/nonstandard_macro_braces.rs +++ b/clippy_lints/src/nonstandard_macro_braces.rs @@ -13,16 +13,14 @@ use rustc_span::Span; use serde::{de, Deserialize}; declare_clippy_lint! { - /// **What it does:** Checks that common macros are used with consistent bracing. + /// ### What it does + /// Checks that common macros are used with consistent bracing. /// - /// **Why is this bad?** This is mostly a consistency lint although using () or [] + /// ### Why is this bad? + /// This is mostly a consistency lint although using () or [] /// doesn't give you a semicolon in item position, which can be unexpected. /// - /// **Known problems:** - /// None - /// - /// **Example:** - /// + /// ### Example /// ```rust /// vec!{1, 2, 3}; /// ``` diff --git a/clippy_lints/src/open_options.rs b/clippy_lints/src/open_options.rs index fded48038e3..4064d94da2a 100644 --- a/clippy_lints/src/open_options.rs +++ b/clippy_lints/src/open_options.rs @@ -8,15 +8,15 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::source_map::{Span, Spanned}; declare_clippy_lint! { - /// **What it does:** Checks for duplicate open options as well as combinations + /// ### What it does + /// Checks for duplicate open options as well as combinations /// that make no sense. /// - /// **Why is this bad?** In the best case, the code will be harder to read than + /// ### Why is this bad? + /// In the best case, the code will be harder to read than /// necessary. I don't know the worst case. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// use std::fs::OpenOptions; /// diff --git a/clippy_lints/src/option_env_unwrap.rs b/clippy_lints/src/option_env_unwrap.rs index b6f518661bd..d7306628030 100644 --- a/clippy_lints/src/option_env_unwrap.rs +++ b/clippy_lints/src/option_env_unwrap.rs @@ -7,17 +7,16 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::sym; declare_clippy_lint! { - /// **What it does:** Checks for usage of `option_env!(...).unwrap()` and + /// ### What it does + /// Checks for usage of `option_env!(...).unwrap()` and /// suggests usage of the `env!` macro. /// - /// **Why is this bad?** Unwrapping the result of `option_env!` will panic + /// ### Why is this bad? + /// Unwrapping the result of `option_env!` will panic /// at run-time if the environment variable doesn't exist, whereas `env!` /// catches it at compile-time. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust,no_run /// let _ = option_env!("HOME").unwrap(); /// ``` diff --git a/clippy_lints/src/option_if_let_else.rs b/clippy_lints/src/option_if_let_else.rs index b2be35bdddb..7aef3a5f34c 100644 --- a/clippy_lints/src/option_if_let_else.rs +++ b/clippy_lints/src/option_if_let_else.rs @@ -12,24 +12,23 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::sym; declare_clippy_lint! { - /// **What it does:** + /// ### What it does /// Lints usage of `if let Some(v) = ... { y } else { x }` which is more /// idiomatically done with `Option::map_or` (if the else bit is a pure /// expression) or `Option::map_or_else` (if the else bit is an impure /// expression). /// - /// **Why is this bad?** + /// ### Why is this bad? /// Using the dedicated functions of the Option type is clearer and /// more concise than an `if let` expression. /// - /// **Known problems:** + /// ### Known problems /// This lint uses a deliberately conservative metric for checking /// if the inside of either body contains breaks or continues which will /// cause it to not suggest a fix if either block contains a loop with /// continues or breaks contained within the loop. /// - /// **Example:** - /// + /// ### Example /// ```rust /// # let optional: Option = Some(0); /// # fn do_complicated_function() -> u32 { 5 }; diff --git a/clippy_lints/src/overflow_check_conditional.rs b/clippy_lints/src/overflow_check_conditional.rs index e222782c2cc..34755afdb72 100644 --- a/clippy_lints/src/overflow_check_conditional.rs +++ b/clippy_lints/src/overflow_check_conditional.rs @@ -6,14 +6,14 @@ use rustc_lint::{LateContext, LateLintPass}; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Detects classic underflow/overflow checks. + /// ### What it does + /// Detects classic underflow/overflow checks. /// - /// **Why is this bad?** Most classic C underflow/overflow checks will fail in + /// ### Why is this bad? + /// Most classic C underflow/overflow checks will fail in /// Rust. Users can use functions like `overflowing_*` and `wrapping_*` instead. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// # let a = 1; /// # let b = 2; diff --git a/clippy_lints/src/panic_in_result_fn.rs b/clippy_lints/src/panic_in_result_fn.rs index cef74d87e7c..e2b6ba8e2d2 100644 --- a/clippy_lints/src/panic_in_result_fn.rs +++ b/clippy_lints/src/panic_in_result_fn.rs @@ -8,14 +8,16 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::{sym, Span}; declare_clippy_lint! { - /// **What it does:** Checks for usage of `panic!`, `unimplemented!`, `todo!`, `unreachable!` or assertions in a function of type result. + /// ### What it does + /// Checks for usage of `panic!`, `unimplemented!`, `todo!`, `unreachable!` or assertions in a function of type result. /// - /// **Why is this bad?** For some codebases, it is desirable for functions of type result to return an error instead of crashing. Hence panicking macros should be avoided. + /// ### Why is this bad? + /// For some codebases, it is desirable for functions of type result to return an error instead of crashing. Hence panicking macros should be avoided. /// - /// **Known problems:** Functions called from a function returning a `Result` may invoke a panicking macro. This is not checked. - /// - /// **Example:** + /// ### Known problems + /// Functions called from a function returning a `Result` may invoke a panicking macro. This is not checked. /// + /// ### Example /// ```rust /// fn result_with_panic() -> Result /// { diff --git a/clippy_lints/src/panic_unimplemented.rs b/clippy_lints/src/panic_unimplemented.rs index dc28874c16e..d8d9081d6f1 100644 --- a/clippy_lints/src/panic_unimplemented.rs +++ b/clippy_lints/src/panic_unimplemented.rs @@ -7,13 +7,13 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::Span; declare_clippy_lint! { - /// **What it does:** Checks for usage of `panic!`. + /// ### What it does + /// Checks for usage of `panic!`. /// - /// **Why is this bad?** `panic!` will stop the execution of the executable + /// ### Why is this bad? + /// `panic!` will stop the execution of the executable /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```no_run /// panic!("even with a good reason"); /// ``` @@ -23,13 +23,13 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for usage of `unimplemented!`. - /// - /// **Why is this bad?** This macro should not be present in production code + /// ### What it does + /// Checks for usage of `unimplemented!`. /// - /// **Known problems:** None. + /// ### Why is this bad? + /// This macro should not be present in production code /// - /// **Example:** + /// ### Example /// ```no_run /// unimplemented!(); /// ``` @@ -39,13 +39,13 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for usage of `todo!`. + /// ### What it does + /// Checks for usage of `todo!`. /// - /// **Why is this bad?** This macro should not be present in production code + /// ### Why is this bad? + /// This macro should not be present in production code /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```no_run /// todo!(); /// ``` @@ -55,13 +55,13 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for usage of `unreachable!`. - /// - /// **Why is this bad?** This macro can cause code to panic + /// ### What it does + /// Checks for usage of `unreachable!`. /// - /// **Known problems:** None. + /// ### Why is this bad? + /// This macro can cause code to panic /// - /// **Example:** + /// ### Example /// ```no_run /// unreachable!(); /// ``` diff --git a/clippy_lints/src/partialeq_ne_impl.rs b/clippy_lints/src/partialeq_ne_impl.rs index 1251ddd9a02..4ec493e5f45 100644 --- a/clippy_lints/src/partialeq_ne_impl.rs +++ b/clippy_lints/src/partialeq_ne_impl.rs @@ -7,16 +7,16 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::sym; declare_clippy_lint! { - /// **What it does:** Checks for manual re-implementations of `PartialEq::ne`. + /// ### What it does + /// Checks for manual re-implementations of `PartialEq::ne`. /// - /// **Why is this bad?** `PartialEq::ne` is required to always return the + /// ### Why is this bad? + /// `PartialEq::ne` is required to always return the /// negated result of `PartialEq::eq`, which is exactly what the default /// implementation does. Therefore, there should never be any need to /// re-implement it. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// struct Foo; /// diff --git a/clippy_lints/src/pass_by_ref_or_value.rs b/clippy_lints/src/pass_by_ref_or_value.rs index f6a70478559..f738ac25417 100644 --- a/clippy_lints/src/pass_by_ref_or_value.rs +++ b/clippy_lints/src/pass_by_ref_or_value.rs @@ -20,15 +20,18 @@ use rustc_target::spec::abi::Abi; use rustc_target::spec::Target; declare_clippy_lint! { - /// **What it does:** Checks for functions taking arguments by reference, where + /// ### What it does + /// Checks for functions taking arguments by reference, where /// the argument type is `Copy` and small enough to be more efficient to always /// pass by value. /// - /// **Why is this bad?** In many calling conventions instances of structs will + /// ### Why is this bad? + /// In many calling conventions instances of structs will /// be passed through registers if they fit into two or less general purpose /// registers. /// - /// **Known problems:** This lint is target register size dependent, it is + /// ### Known problems + /// This lint is target register size dependent, it is /// limited to 32-bit to try and reduce portability problems between 32 and /// 64-bit, but if you are compiling for 8 or 16-bit targets then the limit /// will be different. @@ -50,7 +53,7 @@ declare_clippy_lint! { /// that explains a real case in which this false positive /// led to an **undefined behaviour** introduced with unsafe code. /// - /// **Example:** + /// ### Example /// /// ```rust /// // Bad @@ -67,18 +70,19 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for functions taking arguments by value, where + /// ### What it does + /// Checks for functions taking arguments by value, where /// the argument type is `Copy` and large enough to be worth considering /// passing by reference. Does not trigger if the function is being exported, /// because that might induce API breakage, if the parameter is declared as mutable, /// or if the argument is a `self`. /// - /// **Why is this bad?** Arguments passed by value might result in an unnecessary + /// ### Why is this bad? + /// Arguments passed by value might result in an unnecessary /// shallow copy, taking up more space in the stack and requiring a call to /// `memcpy`, which can be expensive. /// - /// **Example:** - /// + /// ### Example /// ```rust /// #[derive(Clone, Copy)] /// struct TooLarge([u8; 2048]); diff --git a/clippy_lints/src/path_buf_push_overwrite.rs b/clippy_lints/src/path_buf_push_overwrite.rs index 00245926381..3df7a72d295 100644 --- a/clippy_lints/src/path_buf_push_overwrite.rs +++ b/clippy_lints/src/path_buf_push_overwrite.rs @@ -10,15 +10,15 @@ use rustc_span::symbol::sym; use std::path::{Component, Path}; declare_clippy_lint! { - /// **What it does:*** Checks for [push](https://doc.rust-lang.org/std/path/struct.PathBuf.html#method.push) + /// ### What it does + ///* Checks for [push](https://doc.rust-lang.org/std/path/struct.PathBuf.html#method.push) /// calls on `PathBuf` that can cause overwrites. /// - /// **Why is this bad?** Calling `push` with a root path at the start can overwrite the + /// ### Why is this bad? + /// Calling `push` with a root path at the start can overwrite the /// previous defined path. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// use std::path::PathBuf; /// diff --git a/clippy_lints/src/pattern_type_mismatch.rs b/clippy_lints/src/pattern_type_mismatch.rs index ea4065d371b..4534f6e2516 100644 --- a/clippy_lints/src/pattern_type_mismatch.rs +++ b/clippy_lints/src/pattern_type_mismatch.rs @@ -13,7 +13,8 @@ use rustc_span::source_map::Span; use std::iter; declare_clippy_lint! { - /// **What it does:** Checks for patterns that aren't exact representations of the types + /// ### What it does + /// Checks for patterns that aren't exact representations of the types /// they are applied to. /// /// To satisfy this lint, you will have to adjust either the expression that is matched @@ -32,14 +33,12 @@ declare_clippy_lint! { /// this lint can still be used to highlight areas of interest and ensure a good understanding /// of ownership semantics. /// - /// **Why is this bad?** It isn't bad in general. But in some contexts it can be desirable + /// ### Why is this bad? + /// It isn't bad in general. But in some contexts it can be desirable /// because it increases ownership hints in the code, and will guard against some changes /// in ownership. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// This example shows the basic adjustments necessary to satisfy the lint. Note how /// the matched expression is explicitly dereferenced with `*` and the `inner` variable /// is bound to a shared borrow via `ref inner`. diff --git a/clippy_lints/src/precedence.rs b/clippy_lints/src/precedence.rs index 9cf00c953b9..1a8da00d9d6 100644 --- a/clippy_lints/src/precedence.rs +++ b/clippy_lints/src/precedence.rs @@ -25,7 +25,8 @@ const ALLOWED_ODD_FUNCTIONS: [&str; 14] = [ ]; declare_clippy_lint! { - /// **What it does:** Checks for operations where precedence may be unclear + /// ### What it does + /// Checks for operations where precedence may be unclear /// and suggests to add parentheses. Currently it catches the following: /// * mixed usage of arithmetic and bit shifting/combining operators without /// parentheses @@ -33,13 +34,12 @@ declare_clippy_lint! { /// numeric literal) /// followed by a method call /// - /// **Why is this bad?** Not everyone knows the precedence of those operators by + /// ### Why is this bad? + /// Not everyone knows the precedence of those operators by /// heart, so expressions like these may trip others trying to reason about the /// code. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// * `1 << 2 + 3` equals 32, while `(1 << 2) + 3` equals 7 /// * `-1i32.abs()` equals -1, while `(-1i32).abs()` equals 1 pub PRECEDENCE, diff --git a/clippy_lints/src/ptr.rs b/clippy_lints/src/ptr.rs index b15447622a8..c0d1f1eb6e6 100644 --- a/clippy_lints/src/ptr.rs +++ b/clippy_lints/src/ptr.rs @@ -20,16 +20,19 @@ use rustc_span::{sym, MultiSpan}; use std::borrow::Cow; declare_clippy_lint! { - /// **What it does:** This lint checks for function arguments of type `&String` + /// ### What it does + /// This lint checks for function arguments of type `&String` /// or `&Vec` unless the references are mutable. It will also suggest you /// replace `.clone()` calls with the appropriate `.to_owned()`/`to_string()` /// calls. /// - /// **Why is this bad?** Requiring the argument to be of the specific size + /// ### Why is this bad? + /// Requiring the argument to be of the specific size /// makes the function less useful for no benefit; slices in the form of `&[T]` /// or `&str` usually suffice and can be obtained from other types, too. /// - /// **Known problems:** The lint does not follow data. So if you have an + /// ### Known problems + /// The lint does not follow data. So if you have an /// argument `x` and write `let y = x; y.clone()` the lint will not suggest /// changing that `.clone()` to `.to_owned()`. /// @@ -59,7 +62,7 @@ declare_clippy_lint! { /// other crates referencing it, of which you may not be aware. Carefully /// deprecate the function before applying the lint suggestions in this case. /// - /// **Example:** + /// ### Example /// ```ignore /// // Bad /// fn foo(&Vec) { .. } @@ -73,15 +76,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** This lint checks for equality comparisons with `ptr::null` + /// ### What it does + /// This lint checks for equality comparisons with `ptr::null` /// - /// **Why is this bad?** It's easier and more readable to use the inherent + /// ### Why is this bad? + /// It's easier and more readable to use the inherent /// `.is_null()` /// method instead /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```ignore /// // Bad /// if x == ptr::null { @@ -99,19 +102,22 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** This lint checks for functions that take immutable + /// ### What it does + /// This lint checks for functions that take immutable /// references and return mutable ones. /// - /// **Why is this bad?** This is trivially unsound, as one can create two + /// ### Why is this bad? + /// This is trivially unsound, as one can create two /// mutable references from the same (immutable!) source. /// This [error](https://github.com/rust-lang/rust/issues/39465) /// actually lead to an interim Rust release 1.15.1. /// - /// **Known problems:** To be on the conservative side, if there's at least one + /// ### Known problems + /// To be on the conservative side, if there's at least one /// mutable reference with the output lifetime, this lint will not trigger. /// In practice, this case is unlikely anyway. /// - /// **Example:** + /// ### Example /// ```ignore /// fn foo(&Foo) -> &mut Bar { .. } /// ``` @@ -121,13 +127,13 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** This lint checks for invalid usages of `ptr::null`. - /// - /// **Why is this bad?** This causes undefined behavior. + /// ### What it does + /// This lint checks for invalid usages of `ptr::null`. /// - /// **Known problems:** None. + /// ### Why is this bad? + /// This causes undefined behavior. /// - /// **Example:** + /// ### Example /// ```ignore /// // Bad. Undefined behavior /// unsafe { std::slice::from_raw_parts(ptr::null(), 0); } diff --git a/clippy_lints/src/ptr_eq.rs b/clippy_lints/src/ptr_eq.rs index 77cfa3f6b17..d6d7049fb61 100644 --- a/clippy_lints/src/ptr_eq.rs +++ b/clippy_lints/src/ptr_eq.rs @@ -8,16 +8,15 @@ use rustc_lint::{LateContext, LateLintPass}; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Use `std::ptr::eq` when applicable + /// ### What it does + /// Use `std::ptr::eq` when applicable /// - /// **Why is this bad?** `ptr::eq` can be used to compare `&T` references + /// ### Why is this bad? + /// `ptr::eq` can be used to compare `&T` references /// (which coerce to `*const T` implicitly) by their address rather than /// comparing the values they point to. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust /// let a = &[1, 2, 3]; /// let b = &[1, 2, 3]; diff --git a/clippy_lints/src/ptr_offset_with_cast.rs b/clippy_lints/src/ptr_offset_with_cast.rs index afb198f4955..f1975056ddc 100644 --- a/clippy_lints/src/ptr_offset_with_cast.rs +++ b/clippy_lints/src/ptr_offset_with_cast.rs @@ -8,15 +8,15 @@ use rustc_span::sym; use std::fmt; declare_clippy_lint! { - /// **What it does:** Checks for usage of the `offset` pointer method with a `usize` casted to an + /// ### What it does + /// Checks for usage of the `offset` pointer method with a `usize` casted to an /// `isize`. /// - /// **Why is this bad?** If we’re always increasing the pointer address, we can avoid the numeric + /// ### Why is this bad? + /// If we’re always increasing the pointer address, we can avoid the numeric /// cast by using the `add` method instead. /// - /// **Known problems:** None - /// - /// **Example:** + /// ### Example /// ```rust /// let vec = vec![b'a', b'b', b'c']; /// let ptr = vec.as_ptr(); diff --git a/clippy_lints/src/question_mark.rs b/clippy_lints/src/question_mark.rs index d66bac52243..0e682c692c7 100644 --- a/clippy_lints/src/question_mark.rs +++ b/clippy_lints/src/question_mark.rs @@ -13,13 +13,13 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::sym; declare_clippy_lint! { - /// **What it does:** Checks for expressions that could be replaced by the question mark operator. + /// ### What it does + /// Checks for expressions that could be replaced by the question mark operator. /// - /// **Why is this bad?** Question mark usage is more idiomatic. + /// ### Why is this bad? + /// Question mark usage is more idiomatic. /// - /// **Known problems:** None - /// - /// **Example:** + /// ### Example /// ```ignore /// if option.is_none() { /// return None; diff --git a/clippy_lints/src/ranges.rs b/clippy_lints/src/ranges.rs index b41c478c266..0179bd48ee3 100644 --- a/clippy_lints/src/ranges.rs +++ b/clippy_lints/src/ranges.rs @@ -18,14 +18,14 @@ use rustc_span::symbol::Ident; use std::cmp::Ordering; declare_clippy_lint! { - /// **What it does:** Checks for zipping a collection with the range of + /// ### What it does + /// Checks for zipping a collection with the range of /// `0.._.len()`. /// - /// **Why is this bad?** The code is better expressed with `.enumerate()`. + /// ### Why is this bad? + /// The code is better expressed with `.enumerate()`. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// # let x = vec![1]; /// x.iter().zip(0..x.len()); @@ -41,13 +41,16 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for exclusive ranges where 1 is added to the + /// ### What it does + /// Checks for exclusive ranges where 1 is added to the /// upper bound, e.g., `x..(y+1)`. /// - /// **Why is this bad?** The code is more readable with an inclusive range + /// ### Why is this bad? + /// The code is more readable with an inclusive range /// like `x..=y`. /// - /// **Known problems:** Will add unnecessary pair of parentheses when the + /// ### Known problems + /// Will add unnecessary pair of parentheses when the /// expression is not wrapped in a pair but starts with a opening parenthesis /// and ends with a closing one. /// I.e., `let _ = (f()+1)..(f()+1)` results in `let _ = ((f()+1)..=f())`. @@ -61,7 +64,7 @@ declare_clippy_lint! { /// `RangeBounds` trait /// ([#3307](https://github.com/rust-lang/rust-clippy/issues/3307)). /// - /// **Example:** + /// ### Example /// ```rust,ignore /// for x..(y+1) { .. } /// ``` @@ -75,18 +78,21 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for inclusive ranges where 1 is subtracted from + /// ### What it does + /// Checks for inclusive ranges where 1 is subtracted from /// the upper bound, e.g., `x..=(y-1)`. /// - /// **Why is this bad?** The code is more readable with an exclusive range + /// ### Why is this bad? + /// The code is more readable with an exclusive range /// like `x..y`. /// - /// **Known problems:** This will cause a warning that cannot be fixed if + /// ### Known problems + /// This will cause a warning that cannot be fixed if /// the consumer of the range only accepts a specific range type, instead of /// the generic `RangeBounds` trait /// ([#3307](https://github.com/rust-lang/rust-clippy/issues/3307)). /// - /// **Example:** + /// ### Example /// ```rust,ignore /// for x..=(y-1) { .. } /// ``` @@ -100,16 +106,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for range expressions `x..y` where both `x` and `y` + /// ### What it does + /// Checks for range expressions `x..y` where both `x` and `y` /// are constant and `x` is greater or equal to `y`. /// - /// **Why is this bad?** Empty ranges yield no values so iterating them is a no-op. + /// ### Why is this bad? + /// Empty ranges yield no values so iterating them is a no-op. /// Moreover, trying to use a reversed range to index a slice will panic at run-time. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust,no_run /// fn main() { /// (10..=0).for_each(|x| println!("{}", x)); @@ -133,16 +138,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for expressions like `x >= 3 && x < 8` that could + /// ### What it does + /// Checks for expressions like `x >= 3 && x < 8` that could /// be more readably expressed as `(3..8).contains(x)`. /// - /// **Why is this bad?** `contains` expresses the intent better and has less + /// ### Why is this bad? + /// `contains` expresses the intent better and has less /// failure modes (such as fencepost errors or using `||` instead of `&&`). /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust /// // given /// let x = 6; diff --git a/clippy_lints/src/redundant_clone.rs b/clippy_lints/src/redundant_clone.rs index 56ef95a88c8..530b3396abe 100644 --- a/clippy_lints/src/redundant_clone.rs +++ b/clippy_lints/src/redundant_clone.rs @@ -32,17 +32,18 @@ macro_rules! unwrap_or_continue { } declare_clippy_lint! { - /// **What it does:** Checks for a redundant `clone()` (and its relatives) which clones an owned + /// ### What it does + /// Checks for a redundant `clone()` (and its relatives) which clones an owned /// value that is going to be dropped without further use. /// - /// **Why is this bad?** It is not always possible for the compiler to eliminate useless + /// ### Why is this bad? + /// It is not always possible for the compiler to eliminate useless /// allocations and deallocations generated by redundant `clone()`s. /// - /// **Known problems:** - /// + /// ### Known problems /// False-negatives: analysis performed by this lint is conservative and limited. /// - /// **Example:** + /// ### Example /// ```rust /// # use std::path::Path; /// # #[derive(Clone)] diff --git a/clippy_lints/src/redundant_closure_call.rs b/clippy_lints/src/redundant_closure_call.rs index 8f56a21ac5b..a79b2fe76e2 100644 --- a/clippy_lints/src/redundant_closure_call.rs +++ b/clippy_lints/src/redundant_closure_call.rs @@ -14,15 +14,15 @@ use rustc_middle::lint::in_external_macro; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Detects closures called in the same expression where they + /// ### What it does + /// Detects closures called in the same expression where they /// are defined. /// - /// **Why is this bad?** It is unnecessarily adding to the expression's + /// ### Why is this bad? + /// It is unnecessarily adding to the expression's /// complexity. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust,ignore /// // Bad /// let a = (|| 42)() diff --git a/clippy_lints/src/redundant_else.rs b/clippy_lints/src/redundant_else.rs index 061526c6f09..68b256d2944 100644 --- a/clippy_lints/src/redundant_else.rs +++ b/clippy_lints/src/redundant_else.rs @@ -6,14 +6,16 @@ use rustc_middle::lint::in_external_macro; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks for `else` blocks that can be removed without changing semantics. + /// ### What it does + /// Checks for `else` blocks that can be removed without changing semantics. /// - /// **Why is this bad?** The `else` block adds unnecessary indentation and verbosity. + /// ### Why is this bad? + /// The `else` block adds unnecessary indentation and verbosity. /// - /// **Known problems:** Some may prefer to keep the `else` block for clarity. - /// - /// **Example:** + /// ### Known problems + /// Some may prefer to keep the `else` block for clarity. /// + /// ### Example /// ```rust /// fn my_func(count: u32) { /// if count == 0 { diff --git a/clippy_lints/src/redundant_field_names.rs b/clippy_lints/src/redundant_field_names.rs index d5ee8d3468d..47df4917510 100644 --- a/clippy_lints/src/redundant_field_names.rs +++ b/clippy_lints/src/redundant_field_names.rs @@ -8,15 +8,15 @@ use rustc_semver::RustcVersion; use rustc_session::{declare_tool_lint, impl_lint_pass}; declare_clippy_lint! { - /// **What it does:** Checks for fields in struct literals where shorthands + /// ### What it does + /// Checks for fields in struct literals where shorthands /// could be used. /// - /// **Why is this bad?** If the field and variable names are the same, + /// ### Why is this bad? + /// If the field and variable names are the same, /// the field name is redundant. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// let bar: u8 = 123; /// diff --git a/clippy_lints/src/redundant_pub_crate.rs b/clippy_lints/src/redundant_pub_crate.rs index 05f9e01acb4..59a55b9dffa 100644 --- a/clippy_lints/src/redundant_pub_crate.rs +++ b/clippy_lints/src/redundant_pub_crate.rs @@ -5,16 +5,15 @@ use rustc_lint::{LateContext, LateLintPass}; use rustc_session::{declare_tool_lint, impl_lint_pass}; declare_clippy_lint! { - /// **What it does:** Checks for items declared `pub(crate)` that are not crate visible because they + /// ### What it does + /// Checks for items declared `pub(crate)` that are not crate visible because they /// are inside a private module. /// - /// **Why is this bad?** Writing `pub(crate)` is misleading when it's redundant due to the parent + /// ### Why is this bad? + /// Writing `pub(crate)` is misleading when it's redundant due to the parent /// module's visibility. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust /// mod internal { /// pub(crate) fn internal_fn() { } diff --git a/clippy_lints/src/redundant_slicing.rs b/clippy_lints/src/redundant_slicing.rs index 9c6cd7b4fa6..290348c4509 100644 --- a/clippy_lints/src/redundant_slicing.rs +++ b/clippy_lints/src/redundant_slicing.rs @@ -10,17 +10,19 @@ use rustc_middle::ty::TyS; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks for redundant slicing expressions which use the full range, and + /// ### What it does + /// Checks for redundant slicing expressions which use the full range, and /// do not change the type. /// - /// **Why is this bad?** It unnecessarily adds complexity to the expression. + /// ### Why is this bad? + /// It unnecessarily adds complexity to the expression. /// - /// **Known problems:** If the type being sliced has an implementation of `Index` + /// ### Known problems + /// If the type being sliced has an implementation of `Index` /// that actually changes anything then it can't be removed. However, this would be surprising /// to people reading the code and should have a note with it. /// - /// **Example:** - /// + /// ### Example /// ```ignore /// fn get_slice(x: &[u32]) -> &[u32] { /// &x[..] diff --git a/clippy_lints/src/redundant_static_lifetimes.rs b/clippy_lints/src/redundant_static_lifetimes.rs index 48107d9c037..d5a1a61da6b 100644 --- a/clippy_lints/src/redundant_static_lifetimes.rs +++ b/clippy_lints/src/redundant_static_lifetimes.rs @@ -8,14 +8,14 @@ use rustc_semver::RustcVersion; use rustc_session::{declare_tool_lint, impl_lint_pass}; declare_clippy_lint! { - /// **What it does:** Checks for constants and statics with an explicit `'static` lifetime. + /// ### What it does + /// Checks for constants and statics with an explicit `'static` lifetime. /// - /// **Why is this bad?** Adding `'static` to every reference can create very + /// ### Why is this bad? + /// Adding `'static` to every reference can create very /// complicated types. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```ignore /// const FOO: &'static [(&'static str, &'static str, fn(&Bar) -> bool)] = /// &[...] diff --git a/clippy_lints/src/ref_option_ref.rs b/clippy_lints/src/ref_option_ref.rs index 0cf4e0ce7fe..65ab6cac442 100644 --- a/clippy_lints/src/ref_option_ref.rs +++ b/clippy_lints/src/ref_option_ref.rs @@ -9,16 +9,18 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::symbol::sym; declare_clippy_lint! { - /// **What it does:** Checks for usage of `&Option<&T>`. + /// ### What it does + /// Checks for usage of `&Option<&T>`. /// - /// **Why is this bad?** Since `&` is Copy, it's useless to have a + /// ### Why is this bad? + /// Since `&` is Copy, it's useless to have a /// reference on `Option<&T>`. /// - /// **Known problems:** It may be irrelevant to use this lint on + /// ### Known problems + /// It may be irrelevant to use this lint on /// public API code as it will make a breaking change to apply it. /// - /// **Example:** - /// + /// ### Example /// ```rust,ignore /// let x: &Option<&u32> = &Some(&0u32); /// ``` diff --git a/clippy_lints/src/reference.rs b/clippy_lints/src/reference.rs index d6336389b0a..e0930d69ab9 100644 --- a/clippy_lints/src/reference.rs +++ b/clippy_lints/src/reference.rs @@ -10,15 +10,18 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::BytePos; declare_clippy_lint! { - /// **What it does:** Checks for usage of `*&` and `*&mut` in expressions. + /// ### What it does + /// Checks for usage of `*&` and `*&mut` in expressions. /// - /// **Why is this bad?** Immediately dereferencing a reference is no-op and + /// ### Why is this bad? + /// Immediately dereferencing a reference is no-op and /// makes the code less clear. /// - /// **Known problems:** Multiple dereference/addrof pairs are not handled so + /// ### Known problems + /// Multiple dereference/addrof pairs are not handled so /// the suggested fix for `x = **&&y` is `x = *&y`, which is still incorrect. /// - /// **Example:** + /// ### Example /// ```rust,ignore /// // Bad /// let a = f(*&mut b); @@ -101,13 +104,15 @@ impl EarlyLintPass for DerefAddrOf { } declare_clippy_lint! { - /// **What it does:** Checks for references in expressions that use + /// ### What it does + /// Checks for references in expressions that use /// auto dereference. /// - /// **Why is this bad?** The reference is a no-op and is automatically + /// ### Why is this bad? + /// The reference is a no-op and is automatically /// dereferenced by the compiler and makes the code less clear. /// - /// **Example:** + /// ### Example /// ```rust /// struct Point(u32, u32); /// let point = Point(30, 20); diff --git a/clippy_lints/src/regex.rs b/clippy_lints/src/regex.rs index 75151167454..eab09733730 100644 --- a/clippy_lints/src/regex.rs +++ b/clippy_lints/src/regex.rs @@ -11,15 +11,15 @@ use rustc_span::source_map::{BytePos, Span}; use std::convert::TryFrom; declare_clippy_lint! { - /// **What it does:** Checks [regex](https://crates.io/crates/regex) creation + /// ### What it does + /// Checks [regex](https://crates.io/crates/regex) creation /// (with `Regex::new`, `RegexBuilder::new`, or `RegexSet::new`) for correct /// regex syntax. /// - /// **Why is this bad?** This will lead to a runtime panic. + /// ### Why is this bad? + /// This will lead to a runtime panic. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```ignore /// Regex::new("|") /// ``` @@ -29,18 +29,21 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for trivial [regex](https://crates.io/crates/regex) + /// ### What it does + /// Checks for trivial [regex](https://crates.io/crates/regex) /// creation (with `Regex::new`, `RegexBuilder::new`, or `RegexSet::new`). /// - /// **Why is this bad?** Matching the regex can likely be replaced by `==` or + /// ### Why is this bad? + /// Matching the regex can likely be replaced by `==` or /// `str::starts_with`, `str::ends_with` or `std::contains` or other `str` /// methods. /// - /// **Known problems:** If the same regex is going to be applied to multiple + /// ### Known problems + /// If the same regex is going to be applied to multiple /// inputs, the precomputations done by `Regex` construction can give /// significantly better performance than any of the `str`-based methods. /// - /// **Example:** + /// ### Example /// ```ignore /// Regex::new("^foobar") /// ``` diff --git a/clippy_lints/src/repeat_once.rs b/clippy_lints/src/repeat_once.rs index 17cb96bc4eb..54b9c8b3275 100644 --- a/clippy_lints/src/repeat_once.rs +++ b/clippy_lints/src/repeat_once.rs @@ -11,7 +11,8 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::sym; declare_clippy_lint! { - /// **What it does:** Checks for usage of `.repeat(1)` and suggest the following method for each types. + /// ### What it does + /// Checks for usage of `.repeat(1)` and suggest the following method for each types. /// - `.to_string()` for `str` /// - `.clone()` for `String` /// - `.to_vec()` for `slice` @@ -19,13 +20,11 @@ declare_clippy_lint! { /// The lint will evaluate constant expressions and values as arguments of `.repeat(..)` and emit a message if /// they are equivalent to `1`. (Related discussion in [rust-clippy#7306](https://github.com/rust-lang/rust-clippy/issues/7306)) /// - /// **Why is this bad?** For example, `String.repeat(1)` is equivalent to `.clone()`. If cloning + /// ### Why is this bad? + /// For example, `String.repeat(1)` is equivalent to `.clone()`. If cloning /// the string is the intention behind this, `clone()` should be used. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust /// fn main() { /// let x = String::from("hello world").repeat(1); diff --git a/clippy_lints/src/returns.rs b/clippy_lints/src/returns.rs index 251d527c265..db4b1002ce1 100644 --- a/clippy_lints/src/returns.rs +++ b/clippy_lints/src/returns.rs @@ -15,15 +15,15 @@ use rustc_span::source_map::Span; use rustc_span::sym; declare_clippy_lint! { - /// **What it does:** Checks for `let`-bindings, which are subsequently + /// ### What it does + /// Checks for `let`-bindings, which are subsequently /// returned. /// - /// **Why is this bad?** It is just extraneous code. Remove it to make your code + /// ### Why is this bad? + /// It is just extraneous code. Remove it to make your code /// more rusty. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// fn foo() -> String { /// let x = String::new(); @@ -42,14 +42,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for return statements at the end of a block. + /// ### What it does + /// Checks for return statements at the end of a block. /// - /// **Why is this bad?** Removing the `return` and semicolon will make the code + /// ### Why is this bad? + /// Removing the `return` and semicolon will make the code /// more rusty. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// fn foo(x: usize) -> usize { /// return x; diff --git a/clippy_lints/src/self_assignment.rs b/clippy_lints/src/self_assignment.rs index e7925c4fbde..fbd65fef7d1 100644 --- a/clippy_lints/src/self_assignment.rs +++ b/clippy_lints/src/self_assignment.rs @@ -6,16 +6,18 @@ use rustc_lint::{LateContext, LateLintPass}; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks for explicit self-assignments. + /// ### What it does + /// Checks for explicit self-assignments. /// - /// **Why is this bad?** Self-assignments are redundant and unlikely to be + /// ### Why is this bad? + /// Self-assignments are redundant and unlikely to be /// intentional. /// - /// **Known problems:** If expression contains any deref coercions or + /// ### Known problems + /// If expression contains any deref coercions or /// indexing operations they are assumed not to have any side effects. /// - /// **Example:** - /// + /// ### Example /// ```rust /// struct Event { /// id: usize, diff --git a/clippy_lints/src/self_named_constructor.rs b/clippy_lints/src/self_named_constructor.rs index da991e1d90c..2123a14cc1b 100644 --- a/clippy_lints/src/self_named_constructor.rs +++ b/clippy_lints/src/self_named_constructor.rs @@ -6,14 +6,13 @@ use rustc_lint::{LateContext, LateLintPass}; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Warns when constructors have the same name as their types. + /// ### What it does + /// Warns when constructors have the same name as their types. /// - /// **Why is this bad?** Repeating the name of the type is redundant. - /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Why is this bad? + /// Repeating the name of the type is redundant. /// + /// ### Example /// ```rust,ignore /// struct Foo {} /// diff --git a/clippy_lints/src/semicolon_if_nothing_returned.rs b/clippy_lints/src/semicolon_if_nothing_returned.rs index da3e30af35c..6966230156c 100644 --- a/clippy_lints/src/semicolon_if_nothing_returned.rs +++ b/clippy_lints/src/semicolon_if_nothing_returned.rs @@ -9,16 +9,15 @@ use rustc_lint::{LateContext, LateLintPass}; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Looks for blocks of expressions and fires if the last expression returns + /// ### What it does + /// Looks for blocks of expressions and fires if the last expression returns /// `()` but is not followed by a semicolon. /// - /// **Why is this bad?** The semicolon might be optional but when extending the block with new + /// ### Why is this bad? + /// The semicolon might be optional but when extending the block with new /// code, it doesn't require a change in previous last line. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust /// fn main() { /// println!("Hello world") diff --git a/clippy_lints/src/serde_api.rs b/clippy_lints/src/serde_api.rs index 169f7d26285..2cd0f85999c 100644 --- a/clippy_lints/src/serde_api.rs +++ b/clippy_lints/src/serde_api.rs @@ -5,14 +5,15 @@ use rustc_lint::{LateContext, LateLintPass}; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks for mis-uses of the serde API. + /// ### What it does + /// Checks for mis-uses of the serde API. /// - /// **Why is this bad?** Serde is very finnicky about how its API should be + /// ### Why is this bad? + /// Serde is very finnicky about how its API should be /// used, but the type system can't be used to enforce it (yet?). /// - /// **Known problems:** None. - /// - /// **Example:** Implementing `Visitor::visit_string` but not + /// ### Example + /// Implementing `Visitor::visit_string` but not /// `Visitor::visit_str`. pub SERDE_API_MISUSE, correctness, diff --git a/clippy_lints/src/shadow.rs b/clippy_lints/src/shadow.rs index ac3f7ebd14b..b28a37cabd4 100644 --- a/clippy_lints/src/shadow.rs +++ b/clippy_lints/src/shadow.rs @@ -14,17 +14,20 @@ use rustc_span::source_map::Span; use rustc_span::symbol::Symbol; declare_clippy_lint! { - /// **What it does:** Checks for bindings that shadow other bindings already in + /// ### What it does + /// Checks for bindings that shadow other bindings already in /// scope, while just changing reference level or mutability. /// - /// **Why is this bad?** Not much, in fact it's a very common pattern in Rust + /// ### Why is this bad? + /// Not much, in fact it's a very common pattern in Rust /// code. Still, some may opt to avoid it in their code base, they can set this /// lint to `Warn`. /// - /// **Known problems:** This lint, as the other shadowing related lints, + /// ### Known problems + /// This lint, as the other shadowing related lints, /// currently only catches very simple patterns. /// - /// **Example:** + /// ### Example /// ```rust /// # let x = 1; /// // Bad @@ -39,18 +42,21 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for bindings that shadow other bindings already in + /// ### What it does + /// Checks for bindings that shadow other bindings already in /// scope, while reusing the original value. /// - /// **Why is this bad?** Not too much, in fact it's a common pattern in Rust + /// ### Why is this bad? + /// Not too much, in fact it's a common pattern in Rust /// code. Still, some argue that name shadowing like this hurts readability, /// because a value may be bound to different things depending on position in /// the code. /// - /// **Known problems:** This lint, as the other shadowing related lints, + /// ### Known problems + /// This lint, as the other shadowing related lints, /// currently only catches very simple patterns. /// - /// **Example:** + /// ### Example /// ```rust /// let x = 2; /// let x = x + 1; @@ -66,21 +72,24 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for bindings that shadow other bindings already in + /// ### What it does + /// Checks for bindings that shadow other bindings already in /// scope, either without a initialization or with one that does not even use /// the original value. /// - /// **Why is this bad?** Name shadowing can hurt readability, especially in + /// ### Why is this bad? + /// Name shadowing can hurt readability, especially in /// large code bases, because it is easy to lose track of the active binding at /// any place in the code. This can be alleviated by either giving more specific /// names to bindings or introducing more scopes to contain the bindings. /// - /// **Known problems:** This lint, as the other shadowing related lints, + /// ### Known problems + /// This lint, as the other shadowing related lints, /// currently only catches very simple patterns. Note that /// `allow`/`warn`/`deny`/`forbid` attributes only work on the function level /// for this lint. /// - /// **Example:** + /// ### Example /// ```rust /// # let y = 1; /// # let z = 2; diff --git a/clippy_lints/src/single_component_path_imports.rs b/clippy_lints/src/single_component_path_imports.rs index 1eaad438237..f6487b8c46b 100644 --- a/clippy_lints/src/single_component_path_imports.rs +++ b/clippy_lints/src/single_component_path_imports.rs @@ -7,15 +7,14 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::{edition::Edition, symbol::kw, Span, Symbol}; declare_clippy_lint! { - /// **What it does:** Checking for imports with single component use path. + /// ### What it does + /// Checking for imports with single component use path. /// - /// **Why is this bad?** Import with single component use path such as `use cratename;` + /// ### Why is this bad? + /// Import with single component use path such as `use cratename;` /// is not necessary, and thus should be removed. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust,ignore /// use regex; /// diff --git a/clippy_lints/src/size_of_in_element_count.rs b/clippy_lints/src/size_of_in_element_count.rs index b1965cfd601..3e4e4a8d0c0 100644 --- a/clippy_lints/src/size_of_in_element_count.rs +++ b/clippy_lints/src/size_of_in_element_count.rs @@ -11,16 +11,16 @@ use rustc_middle::ty::{self, Ty, TyS, TypeAndMut}; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Detects expressions where + /// ### What it does + /// Detects expressions where /// `size_of::` or `size_of_val::` is used as a /// count of elements of type `T` /// - /// **Why is this bad?** These functions expect a count + /// ### Why is this bad? + /// These functions expect a count /// of `T` and not a number of bytes /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust,no_run /// # use std::ptr::copy_nonoverlapping; /// # use std::mem::size_of; diff --git a/clippy_lints/src/slow_vector_initialization.rs b/clippy_lints/src/slow_vector_initialization.rs index e5c58d70b60..3d039e13065 100644 --- a/clippy_lints/src/slow_vector_initialization.rs +++ b/clippy_lints/src/slow_vector_initialization.rs @@ -13,14 +13,14 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::symbol::sym; declare_clippy_lint! { - /// **What it does:** Checks slow zero-filled vector initialization + /// ### What it does + /// Checks slow zero-filled vector initialization /// - /// **Why is this bad?** These structures are non-idiomatic and less efficient than simply using + /// ### Why is this bad? + /// These structures are non-idiomatic and less efficient than simply using /// `vec![0; len]`. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// # use core::iter::repeat; /// # let len = 4; diff --git a/clippy_lints/src/stable_sort_primitive.rs b/clippy_lints/src/stable_sort_primitive.rs index 65790375c73..4ea1293d504 100644 --- a/clippy_lints/src/stable_sort_primitive.rs +++ b/clippy_lints/src/stable_sort_primitive.rs @@ -7,22 +7,18 @@ use rustc_lint::{LateContext, LateLintPass}; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** + /// ### What it does /// When sorting primitive values (integers, bools, chars, as well /// as arrays, slices, and tuples of such items), it is better to /// use an unstable sort than a stable sort. /// - /// **Why is this bad?** + /// ### Why is this bad? /// Using a stable sort consumes more memory and cpu cycles. Because /// values which compare equal are identical, preserving their /// relative order (the guarantee that a stable sort provides) means /// nothing, while the extra costs still apply. /// - /// **Known problems:** - /// None - /// - /// **Example:** - /// + /// ### Example /// ```rust /// let mut vec = vec![2, 1, 3]; /// vec.sort(); diff --git a/clippy_lints/src/strings.rs b/clippy_lints/src/strings.rs index 958e462125e..1a78a4968e5 100644 --- a/clippy_lints/src/strings.rs +++ b/clippy_lints/src/strings.rs @@ -14,16 +14,15 @@ use rustc_span::source_map::Spanned; use rustc_span::sym; declare_clippy_lint! { - /// **What it does:** Checks for string appends of the form `x = x + y` (without + /// ### What it does + /// Checks for string appends of the form `x = x + y` (without /// `let`!). /// - /// **Why is this bad?** It's not really bad, but some people think that the + /// ### Why is this bad? + /// It's not really bad, but some people think that the /// `.push_str(_)` method is more readable. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust /// let mut x = "Hello".to_owned(); /// x = x + ", World"; @@ -38,11 +37,13 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for all instances of `x + _` where `x` is of type + /// ### What it does + /// Checks for all instances of `x + _` where `x` is of type /// `String`, but only if [`string_add_assign`](#string_add_assign) does *not* /// match. /// - /// **Why is this bad?** It's not bad in and of itself. However, this particular + /// ### Why is this bad? + /// It's not bad in and of itself. However, this particular /// `Add` implementation is asymmetric (the other operand need not be `String`, /// but `x` does), while addition as mathematically defined is symmetric, also /// the `String::push_str(_)` function is a perfectly good replacement. @@ -52,10 +53,7 @@ declare_clippy_lint! { /// in other languages is actually fine, which is why we decided to make this /// particular lint `allow` by default. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust /// let x = "Hello".to_owned(); /// x + ", World"; @@ -66,13 +64,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for the `as_bytes` method called on string literals + /// ### What it does + /// Checks for the `as_bytes` method called on string literals /// that contain only ASCII characters. /// - /// **Why is this bad?** Byte string literals (e.g., `b"foo"`) can be used + /// ### Why is this bad? + /// Byte string literals (e.g., `b"foo"`) can be used /// instead. They are shorter but less discoverable than `as_bytes()`. /// - /// **Known Problems:** + /// ### Known problems /// `"str".as_bytes()` and the suggested replacement of `b"str"` are not /// equivalent because they have different types. The former is `&[u8]` /// while the latter is `&[u8; 3]`. That means in general they will have a @@ -94,7 +94,7 @@ declare_clippy_lint! { /// `b"str"` but `&b"str"[..]`, which is a great deal of punctuation and not /// more readable than a function call. /// - /// **Example:** + /// ### Example /// ```rust /// // Bad /// let bs = "a byte string".as_bytes(); @@ -177,13 +177,13 @@ fn is_add(cx: &LateContext<'_>, src: &Expr<'_>, target: &Expr<'_>) -> bool { } declare_clippy_lint! { - /// **What it does:** Check if the string is transformed to byte array and casted back to string. + /// ### What it does + /// Check if the string is transformed to byte array and casted back to string. /// - /// **Why is this bad?** It's unnecessary, the string can be used directly. + /// ### Why is this bad? + /// It's unnecessary, the string can be used directly. /// - /// **Known problems:** None - /// - /// **Example:** + /// ### Example /// ```rust /// let _ = std::str::from_utf8(&"Hello World!".as_bytes()[6..11]).unwrap(); /// ``` @@ -317,16 +317,15 @@ impl<'tcx> LateLintPass<'tcx> for StringLitAsBytes { } declare_clippy_lint! { - /// **What it does:** This lint checks for `.to_string()` method calls on values of type `&str`. + /// ### What it does + /// This lint checks for `.to_string()` method calls on values of type `&str`. /// - /// **Why is this bad?** The `to_string` method is also used on other types to convert them to a string. + /// ### Why is this bad? + /// The `to_string` method is also used on other types to convert them to a string. /// When called on a `&str` it turns the `&str` into the owned variant `String`, which can be better /// expressed with `.to_owned()`. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust /// // example code where clippy issues a warning /// let _ = "str".to_string(); @@ -366,14 +365,14 @@ impl LateLintPass<'_> for StrToString { } declare_clippy_lint! { - /// **What it does:** This lint checks for `.to_string()` method calls on values of type `String`. + /// ### What it does + /// This lint checks for `.to_string()` method calls on values of type `String`. /// - /// **Why is this bad?** The `to_string` method is also used on other types to convert them to a string. + /// ### Why is this bad? + /// The `to_string` method is also used on other types to convert them to a string. /// When called on a `String` it only clones the `String`, which can be better expressed with `.clone()`. - /// **Known problems:** None. - /// - /// **Example:** /// + /// ### Example /// ```rust /// // example code where clippy issues a warning /// let msg = String::from("Hello World"); diff --git a/clippy_lints/src/strlen_on_c_strings.rs b/clippy_lints/src/strlen_on_c_strings.rs index 2ccf3a3796d..516fa3d95b4 100644 --- a/clippy_lints/src/strlen_on_c_strings.rs +++ b/clippy_lints/src/strlen_on_c_strings.rs @@ -11,16 +11,15 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::symbol::{sym, Symbol}; declare_clippy_lint! { - /// **What it does:** Checks for usage of `libc::strlen` on a `CString` or `CStr` value, + /// ### What it does + /// Checks for usage of `libc::strlen` on a `CString` or `CStr` value, /// and suggest calling `as_bytes().len()` or `to_bytes().len()` respectively instead. /// - /// **Why is this bad?** This avoids calling an unsafe `libc` function. + /// ### Why is this bad? + /// This avoids calling an unsafe `libc` function. /// Currently, it also avoids calculating the length. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust, ignore /// use std::ffi::CString; /// let cstring = CString::new("foo").expect("CString::new failed"); diff --git a/clippy_lints/src/suspicious_operation_groupings.rs b/clippy_lints/src/suspicious_operation_groupings.rs index bb707f78fcc..a8e962d1af3 100644 --- a/clippy_lints/src/suspicious_operation_groupings.rs +++ b/clippy_lints/src/suspicious_operation_groupings.rs @@ -13,20 +13,21 @@ use rustc_span::symbol::Ident; use rustc_span::Span; declare_clippy_lint! { - /// **What it does:** + /// ### What it does /// Checks for unlikely usages of binary operators that are almost /// certainly typos and/or copy/paste errors, given the other usages /// of binary operators nearby. - /// **Why is this bad?** + /// + /// ### Why is this bad? /// They are probably bugs and if they aren't then they look like bugs /// and you should add a comment explaining why you are doing such an /// odd set of operations. - /// **Known problems:** + /// + /// ### Known problems /// There may be some false positives if you are trying to do something /// unusual that happens to look like a typo. /// - /// **Example:** - /// + /// ### Example /// ```rust /// struct Vec3 { /// x: f64, diff --git a/clippy_lints/src/suspicious_trait_impl.rs b/clippy_lints/src/suspicious_trait_impl.rs index f2bffd55321..682fad00a13 100644 --- a/clippy_lints/src/suspicious_trait_impl.rs +++ b/clippy_lints/src/suspicious_trait_impl.rs @@ -8,14 +8,14 @@ use rustc_middle::hir::map::Map; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Lints for suspicious operations in impls of arithmetic operators, e.g. + /// ### What it does + /// Lints for suspicious operations in impls of arithmetic operators, e.g. /// subtracting elements in an Add impl. /// - /// **Why this is bad?** This is probably a typo or copy-and-paste error and not intended. + /// ### Why is this bad? + /// This is probably a typo or copy-and-paste error and not intended. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```ignore /// impl Add for Foo { /// type Output = Foo; @@ -31,14 +31,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Lints for suspicious operations in impls of OpAssign, e.g. + /// ### What it does + /// Lints for suspicious operations in impls of OpAssign, e.g. /// subtracting elements in an AddAssign impl. /// - /// **Why this is bad?** This is probably a typo or copy-and-paste error and not intended. - /// - /// **Known problems:** None. + /// ### Why is this bad? + /// This is probably a typo or copy-and-paste error and not intended. /// - /// **Example:** + /// ### Example /// ```ignore /// impl AddAssign for Foo { /// fn add_assign(&mut self, other: Foo) { diff --git a/clippy_lints/src/swap.rs b/clippy_lints/src/swap.rs index 19967e2c970..4fa8e77a67b 100644 --- a/clippy_lints/src/swap.rs +++ b/clippy_lints/src/swap.rs @@ -12,14 +12,14 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::sym; declare_clippy_lint! { - /// **What it does:** Checks for manual swapping. + /// ### What it does + /// Checks for manual swapping. /// - /// **Why is this bad?** The `std::mem::swap` function exposes the intent better + /// ### Why is this bad? + /// The `std::mem::swap` function exposes the intent better /// without deinitializing or copying either variable. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// let mut a = 42; /// let mut b = 1337; @@ -40,13 +40,13 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for `foo = bar; bar = foo` sequences. - /// - /// **Why is this bad?** This looks like a failed attempt to swap. + /// ### What it does + /// Checks for `foo = bar; bar = foo` sequences. /// - /// **Known problems:** None. + /// ### Why is this bad? + /// This looks like a failed attempt to swap. /// - /// **Example:** + /// ### Example /// ```rust /// # let mut a = 1; /// # let mut b = 2; diff --git a/clippy_lints/src/tabs_in_doc_comments.rs b/clippy_lints/src/tabs_in_doc_comments.rs index e2c144709f5..6a73b94d87e 100644 --- a/clippy_lints/src/tabs_in_doc_comments.rs +++ b/clippy_lints/src/tabs_in_doc_comments.rs @@ -7,16 +7,16 @@ use rustc_span::source_map::{BytePos, Span}; use std::convert::TryFrom; declare_clippy_lint! { - /// **What it does:** Checks doc comments for usage of tab characters. + /// ### What it does + /// Checks doc comments for usage of tab characters. /// - /// **Why is this bad?** The rust style-guide promotes spaces instead of tabs for indentation. + /// ### Why is this bad? + /// The rust style-guide promotes spaces instead of tabs for indentation. /// To keep a consistent view on the source, also doc comments should not have tabs. /// Also, explaining ascii-diagrams containing tabs can get displayed incorrectly when the /// display settings of the author and reader differ. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// /// /// /// Struct to hold two strings: diff --git a/clippy_lints/src/temporary_assignment.rs b/clippy_lints/src/temporary_assignment.rs index 8ef25dc816c..a9da690339c 100644 --- a/clippy_lints/src/temporary_assignment.rs +++ b/clippy_lints/src/temporary_assignment.rs @@ -5,15 +5,15 @@ use rustc_lint::{LateContext, LateLintPass}; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks for construction of a structure or tuple just to + /// ### What it does + /// Checks for construction of a structure or tuple just to /// assign a value in it. /// - /// **Why is this bad?** Readability. If the structure is only created to be + /// ### Why is this bad? + /// Readability. If the structure is only created to be /// updated, why not write the structure you want in the first place? /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// (0, 0).0 = 1 /// ``` diff --git a/clippy_lints/src/to_digit_is_some.rs b/clippy_lints/src/to_digit_is_some.rs index c66a596c784..1c14a919995 100644 --- a/clippy_lints/src/to_digit_is_some.rs +++ b/clippy_lints/src/to_digit_is_some.rs @@ -9,12 +9,14 @@ use rustc_middle::ty; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks for `.to_digit(..).is_some()` on `char`s. + /// ### What it does + /// Checks for `.to_digit(..).is_some()` on `char`s. /// - /// **Why is this bad?** This is a convoluted way of checking if a `char` is a digit. It's + /// ### Why is this bad? + /// This is a convoluted way of checking if a `char` is a digit. It's /// more straight forward to use the dedicated `is_digit` method. /// - /// **Example:** + /// ### Example /// ```rust /// # let c = 'c'; /// # let radix = 10; diff --git a/clippy_lints/src/to_string_in_display.rs b/clippy_lints/src/to_string_in_display.rs index 4fb297ac6c6..b036ed9a3d2 100644 --- a/clippy_lints/src/to_string_in_display.rs +++ b/clippy_lints/src/to_string_in_display.rs @@ -7,15 +7,15 @@ use rustc_session::{declare_tool_lint, impl_lint_pass}; use rustc_span::symbol::sym; declare_clippy_lint! { - /// **What it does:** Checks for uses of `to_string()` in `Display` traits. + /// ### What it does + /// Checks for uses of `to_string()` in `Display` traits. /// - /// **Why is this bad?** Usually `to_string` is implemented indirectly + /// ### Why is this bad? + /// Usually `to_string` is implemented indirectly /// via `Display`. Hence using it while implementing `Display` would /// lead to infinite recursion. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// /// ```rust /// use std::fmt; diff --git a/clippy_lints/src/trait_bounds.rs b/clippy_lints/src/trait_bounds.rs index 74a94db1800..79367c4230c 100644 --- a/clippy_lints/src/trait_bounds.rs +++ b/clippy_lints/src/trait_bounds.rs @@ -11,14 +11,14 @@ use rustc_session::{declare_tool_lint, impl_lint_pass}; use rustc_span::Span; declare_clippy_lint! { - /// **What it does:** This lint warns about unnecessary type repetitions in trait bounds + /// ### What it does + /// This lint warns about unnecessary type repetitions in trait bounds /// - /// **Why is this bad?** Repeating the type for every bound makes the code + /// ### Why is this bad? + /// Repeating the type for every bound makes the code /// less readable than combining the bounds /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// pub fn foo(t: T) where T: Copy, T: Clone {} /// ``` @@ -34,15 +34,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for cases where generics are being used and multiple + /// ### What it does + /// Checks for cases where generics are being used and multiple /// syntax specifications for trait bounds are used simultaneously. /// - /// **Why is this bad?** Duplicate bounds makes the code + /// ### Why is this bad? + /// Duplicate bounds makes the code /// less readable than specifing them only once. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// fn func(arg: T) where T: Clone + Default {} /// ``` diff --git a/clippy_lints/src/transmute/mod.rs b/clippy_lints/src/transmute/mod.rs index 89fd5faa165..33ec9c331ce 100644 --- a/clippy_lints/src/transmute/mod.rs +++ b/clippy_lints/src/transmute/mod.rs @@ -20,15 +20,18 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::symbol::sym; declare_clippy_lint! { - /// **What it does:** Checks for transmutes that can't ever be correct on any + /// ### What it does + /// Checks for transmutes that can't ever be correct on any /// architecture. /// - /// **Why is this bad?** It's basically guaranteed to be undefined behaviour. + /// ### Why is this bad? + /// It's basically guaranteed to be undefined behaviour. /// - /// **Known problems:** When accessing C, users might want to store pointer + /// ### Known problems + /// When accessing C, users might want to store pointer /// sized objects in `extradata` arguments to save an allocation. /// - /// **Example:** + /// ### Example /// ```ignore /// let ptr: *const T = core::intrinsics::transmute('x') /// ``` @@ -39,15 +42,15 @@ declare_clippy_lint! { // FIXME: Move this to `complexity` again, after #5343 is fixed declare_clippy_lint! { - /// **What it does:** Checks for transmutes to the original type of the object + /// ### What it does + /// Checks for transmutes to the original type of the object /// and transmutes that could be a cast. /// - /// **Why is this bad?** Readability. The code tricks people into thinking that + /// ### Why is this bad? + /// Readability. The code tricks people into thinking that /// something complex is going on. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust,ignore /// core::intrinsics::transmute(t); // where the result type is the same as `t`'s /// ``` @@ -58,14 +61,14 @@ declare_clippy_lint! { // FIXME: Merge this lint with USELESS_TRANSMUTE once that is out of the nursery. declare_clippy_lint! { - /// **What it does:**Checks for transmutes that could be a pointer cast. + /// ### What it does + ///Checks for transmutes that could be a pointer cast. /// - /// **Why is this bad?** Readability. The code tricks people into thinking that + /// ### Why is this bad? + /// Readability. The code tricks people into thinking that /// something complex is going on. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// /// ```rust /// # let p: *const [i32] = &[]; @@ -82,14 +85,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for transmutes between a type `T` and `*T`. + /// ### What it does + /// Checks for transmutes between a type `T` and `*T`. /// - /// **Why is this bad?** It's easy to mistakenly transmute between a type and a + /// ### Why is this bad? + /// It's easy to mistakenly transmute between a type and a /// pointer to that type. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust,ignore /// core::intrinsics::transmute(t) // where the result type is the same as /// // `*t` or `&t`'s @@ -100,17 +103,19 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for transmutes from a pointer to a reference. + /// ### What it does + /// Checks for transmutes from a pointer to a reference. /// - /// **Why is this bad?** This can always be rewritten with `&` and `*`. + /// ### Why is this bad? + /// This can always be rewritten with `&` and `*`. /// - /// **Known problems:** + /// ### Known problems /// - `mem::transmute` in statics and constants is stable from Rust 1.46.0, /// while dereferencing raw pointer is not stable yet. /// If you need to do this in those places, /// you would have to use `transmute` instead. /// - /// **Example:** + /// ### Example /// ```rust,ignore /// unsafe { /// let _: &T = std::mem::transmute(p); // where p: *const T @@ -125,11 +130,13 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for transmutes from an integer to a `char`. + /// ### What it does + /// Checks for transmutes from an integer to a `char`. /// - /// **Why is this bad?** Not every integer is a Unicode scalar value. + /// ### Why is this bad? + /// Not every integer is a Unicode scalar value. /// - /// **Known problems:** + /// ### Known problems /// - [`from_u32`] which this lint suggests using is slower than `transmute` /// as it needs to validate the input. /// If you are certain that the input is always a valid Unicode scalar value, @@ -140,7 +147,7 @@ declare_clippy_lint! { /// [`from_u32`]: https://doc.rust-lang.org/std/char/fn.from_u32.html /// [`from_u32_unchecked`]: https://doc.rust-lang.org/std/char/fn.from_u32_unchecked.html /// - /// **Example:** + /// ### Example /// ```rust /// let x = 1_u32; /// unsafe { @@ -156,11 +163,13 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for transmutes from a `&[u8]` to a `&str`. + /// ### What it does + /// Checks for transmutes from a `&[u8]` to a `&str`. /// - /// **Why is this bad?** Not every byte slice is a valid UTF-8 string. + /// ### Why is this bad? + /// Not every byte slice is a valid UTF-8 string. /// - /// **Known problems:** + /// ### Known problems /// - [`from_utf8`] which this lint suggests using is slower than `transmute` /// as it needs to validate the input. /// If you are certain that the input is always a valid UTF-8, @@ -171,7 +180,7 @@ declare_clippy_lint! { /// [`from_utf8`]: https://doc.rust-lang.org/std/str/fn.from_utf8.html /// [`from_utf8_unchecked`]: https://doc.rust-lang.org/std/str/fn.from_utf8_unchecked.html /// - /// **Example:** + /// ### Example /// ```rust /// let b: &[u8] = &[1_u8, 2_u8]; /// unsafe { @@ -187,13 +196,13 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for transmutes from an integer to a `bool`. - /// - /// **Why is this bad?** This might result in an invalid in-memory representation of a `bool`. + /// ### What it does + /// Checks for transmutes from an integer to a `bool`. /// - /// **Known problems:** None. + /// ### Why is this bad? + /// This might result in an invalid in-memory representation of a `bool`. /// - /// **Example:** + /// ### Example /// ```rust /// let x = 1_u8; /// unsafe { @@ -209,14 +218,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for transmutes from an integer to a float. + /// ### What it does + /// Checks for transmutes from an integer to a float. /// - /// **Why is this bad?** Transmutes are dangerous and error-prone, whereas `from_bits` is intuitive + /// ### Why is this bad? + /// Transmutes are dangerous and error-prone, whereas `from_bits` is intuitive /// and safe. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// unsafe { /// let _: f32 = std::mem::transmute(1_u32); // where x: u32 @@ -231,14 +240,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for transmutes from a float to an integer. + /// ### What it does + /// Checks for transmutes from a float to an integer. /// - /// **Why is this bad?** Transmutes are dangerous and error-prone, whereas `to_bits` is intuitive + /// ### Why is this bad? + /// Transmutes are dangerous and error-prone, whereas `to_bits` is intuitive /// and safe. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// unsafe { /// let _: u32 = std::mem::transmute(1f32); @@ -253,15 +262,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for transmutes from a pointer to a pointer, or + /// ### What it does + /// Checks for transmutes from a pointer to a pointer, or /// from a reference to a reference. /// - /// **Why is this bad?** Transmutes are dangerous, and these can instead be + /// ### Why is this bad? + /// Transmutes are dangerous, and these can instead be /// written as casts. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// let ptr = &1u32 as *const u32; /// unsafe { @@ -280,15 +289,18 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for transmutes between collections whose + /// ### What it does + /// Checks for transmutes between collections whose /// types have different ABI, size or alignment. /// - /// **Why is this bad?** This is undefined behavior. + /// ### Why is this bad? + /// This is undefined behavior. /// - /// **Known problems:** Currently, we cannot know whether a type is a + /// ### Known problems + /// Currently, we cannot know whether a type is a /// collection, so we just lint the ones that come with `std`. /// - /// **Example:** + /// ### Example /// ```rust /// // different size, therefore likely out-of-bounds memory access /// // You absolutely do not want this in your code! diff --git a/clippy_lints/src/transmuting_null.rs b/clippy_lints/src/transmuting_null.rs index 0c39d4d8cf4..a67fa792205 100644 --- a/clippy_lints/src/transmuting_null.rs +++ b/clippy_lints/src/transmuting_null.rs @@ -10,15 +10,18 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::symbol::sym; declare_clippy_lint! { - /// **What it does:** Checks for transmute calls which would receive a null pointer. + /// ### What it does + /// Checks for transmute calls which would receive a null pointer. /// - /// **Why is this bad?** Transmuting a null pointer is undefined behavior. + /// ### Why is this bad? + /// Transmuting a null pointer is undefined behavior. /// - /// **Known problems:** Not all cases can be detected at the moment of this writing. + /// ### Known problems + /// Not all cases can be detected at the moment of this writing. /// For example, variables which hold a null pointer and are then fed to a `transmute` /// call, aren't detectable yet. /// - /// **Example:** + /// ### Example /// ```rust /// let null_ref: &u64 = unsafe { std::mem::transmute(0 as *const u64) }; /// ``` diff --git a/clippy_lints/src/try_err.rs b/clippy_lints/src/try_err.rs index f2ba2b2ecf6..1196271d5dd 100644 --- a/clippy_lints/src/try_err.rs +++ b/clippy_lints/src/try_err.rs @@ -13,16 +13,16 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::sym; declare_clippy_lint! { - /// **What it does:** Checks for usages of `Err(x)?`. + /// ### What it does + /// Checks for usages of `Err(x)?`. /// - /// **Why is this bad?** The `?` operator is designed to allow calls that + /// ### Why is this bad? + /// The `?` operator is designed to allow calls that /// can fail to be easily chained. For example, `foo()?.bar()` or /// `foo(bar()?)`. Because `Err(x)?` can't be used that way (it will /// always return), it is more clear to write `return Err(x)`. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// fn foo(fail: bool) -> Result { /// if fail { diff --git a/clippy_lints/src/types/mod.rs b/clippy_lints/src/types/mod.rs index 7d629b5455b..ad7409fe3a9 100644 --- a/clippy_lints/src/types/mod.rs +++ b/clippy_lints/src/types/mod.rs @@ -20,16 +20,16 @@ use rustc_session::{declare_tool_lint, impl_lint_pass}; use rustc_span::source_map::Span; declare_clippy_lint! { - /// **What it does:** Checks for use of `Box>` anywhere in the code. + /// ### What it does + /// Checks for use of `Box>` anywhere in the code. /// Check the [Box documentation](https://doc.rust-lang.org/std/boxed/index.html) for more information. /// - /// **Why is this bad?** `Vec` already keeps its contents in a separate area on + /// ### Why is this bad? + /// `Vec` already keeps its contents in a separate area on /// the heap. So if you `Box` it, you just add another level of indirection /// without any benefit whatsoever. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust,ignore /// struct X { /// values: Box>, @@ -49,16 +49,19 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for use of `Vec>` where T: Sized anywhere in the code. + /// ### What it does + /// Checks for use of `Vec>` where T: Sized anywhere in the code. /// Check the [Box documentation](https://doc.rust-lang.org/std/boxed/index.html) for more information. /// - /// **Why is this bad?** `Vec` already keeps its contents in a separate area on + /// ### Why is this bad? + /// `Vec` already keeps its contents in a separate area on /// the heap. So if you `Box` its contents, you just add another level of indirection. /// - /// **Known problems:** Vec> makes sense if T is a large type (see [#3530](https://github.com/rust-lang/rust-clippy/issues/3530), + /// ### Known problems + /// Vec> makes sense if T is a large type (see [#3530](https://github.com/rust-lang/rust-clippy/issues/3530), /// 1st comment). /// - /// **Example:** + /// ### Example /// ```rust /// struct X { /// values: Vec>, @@ -78,19 +81,19 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for use of `Option>` in function signatures and type + /// ### What it does + /// Checks for use of `Option>` in function signatures and type /// definitions /// - /// **Why is this bad?** `Option<_>` represents an optional value. `Option>` + /// ### Why is this bad? + /// `Option<_>` represents an optional value. `Option>` /// represents an optional optional value which is logically the same thing as an optional /// value but has an unneeded extra level of wrapping. /// /// If you have a case where `Some(Some(_))`, `Some(None)` and `None` are distinct cases, /// consider a custom `enum` instead, with clear names for each case. /// - /// **Known problems:** None. - /// - /// **Example** + /// ### Example /// ```rust /// fn get_data() -> Option> { /// None @@ -116,10 +119,12 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for usage of any `LinkedList`, suggesting to use a + /// ### What it does + /// Checks for usage of any `LinkedList`, suggesting to use a /// `Vec` or a `VecDeque` (formerly called `RingBuf`). /// - /// **Why is this bad?** Gankro says: + /// ### Why is this bad? + /// Gankro says: /// /// > The TL;DR of `LinkedList` is that it's built on a massive amount of /// pointers and indirection. @@ -138,10 +143,11 @@ declare_clippy_lint! { /// can still be better /// > because of how expensive it is to seek to the middle of a `LinkedList`. /// - /// **Known problems:** False positives – the instances where using a + /// ### Known problems + /// False positives – the instances where using a /// `LinkedList` makes sense are few and far between, but they can still happen. /// - /// **Example:** + /// ### Example /// ```rust /// # use std::collections::LinkedList; /// let x: LinkedList = LinkedList::new(); @@ -152,15 +158,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for use of `&Box` anywhere in the code. + /// ### What it does + /// Checks for use of `&Box` anywhere in the code. /// Check the [Box documentation](https://doc.rust-lang.org/std/boxed/index.html) for more information. /// - /// **Why is this bad?** Any `&Box` can also be a `&T`, which is more + /// ### Why is this bad? + /// Any `&Box` can also be a `&T`, which is more /// general. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust,ignore /// fn foo(bar: &Box) { ... } /// ``` @@ -176,14 +182,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for use of redundant allocations anywhere in the code. + /// ### What it does + /// Checks for use of redundant allocations anywhere in the code. /// - /// **Why is this bad?** Expressions such as `Rc<&T>`, `Rc>`, `Rc>`, `Rc>`, Arc<&T>`, `Arc>`, + /// ### Why is this bad? + /// Expressions such as `Rc<&T>`, `Rc>`, `Rc>`, `Rc>`, Arc<&T>`, `Arc>`, /// `Arc>`, `Arc>`, `Box<&T>`, `Box>`, `Box>`, `Box>`, add an unnecessary level of indirection. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// # use std::rc::Rc; /// fn foo(bar: Rc<&usize>) {} @@ -200,9 +206,11 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for `Rc` and `Arc` when `T` is a mutable buffer type such as `String` or `Vec`. + /// ### What it does + /// Checks for `Rc` and `Arc` when `T` is a mutable buffer type such as `String` or `Vec`. /// - /// **Why is this bad?** Expressions such as `Rc` usually have no advantage over `Rc`, since + /// ### Why is this bad? + /// Expressions such as `Rc` usually have no advantage over `Rc`, since /// it is larger and involves an extra level of indirection, and doesn't implement `Borrow`. /// /// While mutating a buffer type would still be possible with `Rc::get_mut()`, it only @@ -211,10 +219,11 @@ declare_clippy_lint! { /// type with an interior mutable container (such as `RefCell` or `Mutex`) would normally /// be used. /// - /// **Known problems:** This pattern can be desirable to avoid the overhead of a `RefCell` or `Mutex` for + /// ### Known problems + /// This pattern can be desirable to avoid the overhead of a `RefCell` or `Mutex` for /// cases where mutation only happens before there are any additional references. /// - /// **Example:** + /// ### Example /// ```rust,ignore /// # use std::rc::Rc; /// fn foo(interned: Rc) { ... } @@ -231,15 +240,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for types used in structs, parameters and `let` + /// ### What it does + /// Checks for types used in structs, parameters and `let` /// declarations above a certain complexity threshold. /// - /// **Why is this bad?** Too complex types make the code less readable. Consider + /// ### Why is this bad? + /// Too complex types make the code less readable. Consider /// using a `type` definition to simplify them. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// # use std::rc::Rc; /// struct Foo { @@ -252,16 +261,19 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for `Rc>`. + /// ### What it does + /// Checks for `Rc>`. /// - /// **Why is this bad?** `Rc` is used in single thread and `Mutex` is used in multi thread. + /// ### Why is this bad? + /// `Rc` is used in single thread and `Mutex` is used in multi thread. /// Consider using `Rc>` in single thread or `Arc>` in multi thread. /// - /// **Known problems:** Sometimes combining generic types can lead to the requirement that a + /// ### Known problems + /// Sometimes combining generic types can lead to the requirement that a /// type use Rc in conjunction with Mutex. We must consider those cases false positives, but /// alas they are quite hard to rule out. Luckily they are also rare. /// - /// **Example:** + /// ### Example /// ```rust,ignore /// use std::rc::Rc; /// use std::sync::Mutex; diff --git a/clippy_lints/src/undropped_manually_drops.rs b/clippy_lints/src/undropped_manually_drops.rs index f4f5e1233e3..47571e608c7 100644 --- a/clippy_lints/src/undropped_manually_drops.rs +++ b/clippy_lints/src/undropped_manually_drops.rs @@ -6,15 +6,17 @@ use rustc_lint::{LateContext, LateLintPass}; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Prevents the safe `std::mem::drop` function from being called on `std::mem::ManuallyDrop`. + /// ### What it does + /// Prevents the safe `std::mem::drop` function from being called on `std::mem::ManuallyDrop`. /// - /// **Why is this bad?** The safe `drop` function does not drop the inner value of a `ManuallyDrop`. + /// ### Why is this bad? + /// The safe `drop` function does not drop the inner value of a `ManuallyDrop`. /// - /// **Known problems:** Does not catch cases if the user binds `std::mem::drop` + /// ### Known problems + /// Does not catch cases if the user binds `std::mem::drop` /// to a different name and calls it that way. /// - /// **Example:** - /// + /// ### Example /// ```rust /// struct S; /// drop(std::mem::ManuallyDrop::new(S)); diff --git a/clippy_lints/src/unicode.rs b/clippy_lints/src/unicode.rs index 2f0a61898ba..f337dec8f2b 100644 --- a/clippy_lints/src/unicode.rs +++ b/clippy_lints/src/unicode.rs @@ -10,14 +10,15 @@ use rustc_span::source_map::Span; use unicode_normalization::UnicodeNormalization; declare_clippy_lint! { - /// **What it does:** Checks for invisible Unicode characters in the code. + /// ### What it does + /// Checks for invisible Unicode characters in the code. /// - /// **Why is this bad?** Having an invisible character in the code makes for all + /// ### Why is this bad? + /// Having an invisible character in the code makes for all /// sorts of April fools, but otherwise is very much frowned upon. /// - /// **Known problems:** None. - /// - /// **Example:** You don't see it, but there may be a zero-width space or soft hyphen + /// ### Example + /// You don't see it, but there may be a zero-width space or soft hyphen /// some­where in this text. pub INVISIBLE_CHARACTERS, correctness, @@ -25,17 +26,17 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for non-ASCII characters in string literals. + /// ### What it does + /// Checks for non-ASCII characters in string literals. /// - /// **Why is this bad?** Yeah, we know, the 90's called and wanted their charset + /// ### Why is this bad? + /// Yeah, we know, the 90's called and wanted their charset /// back. Even so, there still are editors and other programs out there that /// don't work well with Unicode. So if the code is meant to be used /// internationally, on multiple operating systems, or has other portability /// requirements, activating this lint could be useful. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// let x = String::from("€"); /// ``` @@ -49,16 +50,17 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for string literals that contain Unicode in a form + /// ### What it does + /// Checks for string literals that contain Unicode in a form /// that is not equal to its /// [NFC-recomposition](http://www.unicode.org/reports/tr15/#Norm_Forms). /// - /// **Why is this bad?** If such a string is compared to another, the results + /// ### Why is this bad? + /// If such a string is compared to another, the results /// may be surprising. /// - /// **Known problems** None. - /// - /// **Example:** You may not see it, but "à"" and "à"" aren't the same string. The + /// ### Example + /// You may not see it, but "à"" and "à"" aren't the same string. The /// former when escaped is actually `"a\u{300}"` while the latter is `"\u{e0}"`. pub UNICODE_NOT_NFC, pedantic, diff --git a/clippy_lints/src/unit_return_expecting_ord.rs b/clippy_lints/src/unit_return_expecting_ord.rs index 1c420a50427..900d4531760 100644 --- a/clippy_lints/src/unit_return_expecting_ord.rs +++ b/clippy_lints/src/unit_return_expecting_ord.rs @@ -10,20 +10,22 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::{BytePos, Span}; declare_clippy_lint! { - /// **What it does:** Checks for functions that expect closures of type + /// ### What it does + /// Checks for functions that expect closures of type /// Fn(...) -> Ord where the implemented closure returns the unit type. /// The lint also suggests to remove the semi-colon at the end of the statement if present. /// - /// **Why is this bad?** Likely, returning the unit type is unintentional, and + /// ### Why is this bad? + /// Likely, returning the unit type is unintentional, and /// could simply be caused by an extra semi-colon. Since () implements Ord /// it doesn't cause a compilation error. /// This is the same reasoning behind the unit_cmp lint. /// - /// **Known problems:** If returning unit is intentional, then there is no + /// ### Known problems + /// If returning unit is intentional, then there is no /// way of specifying this without triggering needless_return lint /// - /// **Example:** - /// + /// ### Example /// ```rust /// let mut twins = vec!((1, 1), (2, 2)); /// twins.sort_by_key(|x| { x.1; }); diff --git a/clippy_lints/src/unit_types/mod.rs b/clippy_lints/src/unit_types/mod.rs index 64420a03933..66b1abbe50b 100644 --- a/clippy_lints/src/unit_types/mod.rs +++ b/clippy_lints/src/unit_types/mod.rs @@ -8,14 +8,14 @@ use rustc_lint::{LateContext, LateLintPass}; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks for binding a unit value. + /// ### What it does + /// Checks for binding a unit value. /// - /// **Why is this bad?** A unit value cannot usefully be used anywhere. So + /// ### Why is this bad? + /// A unit value cannot usefully be used anywhere. So /// binding one is kind of pointless. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// let x = { /// 1; @@ -27,16 +27,16 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for comparisons to unit. This includes all binary + /// ### What it does + /// Checks for comparisons to unit. This includes all binary /// comparisons (like `==` and `<`) and asserts. /// - /// **Why is this bad?** Unit is always equal to itself, and thus is just a + /// ### Why is this bad? + /// Unit is always equal to itself, and thus is just a /// clumsily written constant. Mostly this happens when someone accidentally /// adds semicolons at the end of the operands. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// # fn foo() {}; /// # fn bar() {}; @@ -74,14 +74,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for passing a unit value as an argument to a function without using a + /// ### What it does + /// Checks for passing a unit value as an argument to a function without using a /// unit literal (`()`). /// - /// **Why is this bad?** This is likely the result of an accidental semicolon. - /// - /// **Known problems:** None. + /// ### Why is this bad? + /// This is likely the result of an accidental semicolon. /// - /// **Example:** + /// ### Example /// ```rust,ignore /// foo({ /// let a = bar(); diff --git a/clippy_lints/src/unnamed_address.rs b/clippy_lints/src/unnamed_address.rs index 9cca05b1f1a..1eafdee0352 100644 --- a/clippy_lints/src/unnamed_address.rs +++ b/clippy_lints/src/unnamed_address.rs @@ -7,16 +7,15 @@ use rustc_middle::ty; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks for comparisons with an address of a function item. + /// ### What it does + /// Checks for comparisons with an address of a function item. /// - /// **Why is this bad?** Function item address is not guaranteed to be unique and could vary + /// ### Why is this bad? + /// Function item address is not guaranteed to be unique and could vary /// between different code generation units. Furthermore different function items could have /// the same address after being merged together. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust /// type F = fn(); /// fn a() {} @@ -31,17 +30,16 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for comparisons with an address of a trait vtable. + /// ### What it does + /// Checks for comparisons with an address of a trait vtable. /// - /// **Why is this bad?** Comparing trait objects pointers compares an vtable addresses which + /// ### Why is this bad? + /// Comparing trait objects pointers compares an vtable addresses which /// are not guaranteed to be unique and could vary between different code generation units. /// Furthermore vtables for different types could have the same address after being merged /// together. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust,ignore /// let a: Rc = ... /// let b: Rc = ... diff --git a/clippy_lints/src/unnecessary_self_imports.rs b/clippy_lints/src/unnecessary_self_imports.rs index 48c54d79cf1..4cfd2df551f 100644 --- a/clippy_lints/src/unnecessary_self_imports.rs +++ b/clippy_lints/src/unnecessary_self_imports.rs @@ -7,16 +7,18 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::symbol::kw; declare_clippy_lint! { - /// **What it does:** Checks for imports ending in `::{self}`. + /// ### What it does + /// Checks for imports ending in `::{self}`. /// - /// **Why is this bad?** In most cases, this can be written much more cleanly by omitting `::{self}`. + /// ### Why is this bad? + /// In most cases, this can be written much more cleanly by omitting `::{self}`. /// - /// **Known problems:** Removing `::{self}` will cause any non-module items at the same path to also be imported. + /// ### Known problems + /// Removing `::{self}` will cause any non-module items at the same path to also be imported. /// This might cause a naming conflict (https://github.com/rust-lang/rustfmt/issues/3568). This lint makes no attempt /// to detect this scenario and that is why it is a restriction lint. /// - /// **Example:** - /// + /// ### Example /// ```rust /// use std::io::{self}; /// ``` diff --git a/clippy_lints/src/unnecessary_sort_by.rs b/clippy_lints/src/unnecessary_sort_by.rs index 347d858b640..6fc5707a4ee 100644 --- a/clippy_lints/src/unnecessary_sort_by.rs +++ b/clippy_lints/src/unnecessary_sort_by.rs @@ -12,21 +12,20 @@ use rustc_span::symbol::Ident; use std::iter; declare_clippy_lint! { - /// **What it does:** + /// ### What it does /// Detects uses of `Vec::sort_by` passing in a closure /// which compares the two arguments, either directly or indirectly. /// - /// **Why is this bad?** + /// ### Why is this bad? /// It is more clear to use `Vec::sort_by_key` (or `Vec::sort` if /// possible) than to use `Vec::sort_by` and a more complicated /// closure. /// - /// **Known problems:** + /// ### Known problems /// If the suggested `Vec::sort_by_key` uses Reverse and it isn't already /// imported by a use statement, then it will need to be added manually. /// - /// **Example:** - /// + /// ### Example /// ```rust /// # struct A; /// # impl A { fn foo(&self) {} } diff --git a/clippy_lints/src/unnecessary_wraps.rs b/clippy_lints/src/unnecessary_wraps.rs index a85ffa6aa95..7a62b21937f 100644 --- a/clippy_lints/src/unnecessary_wraps.rs +++ b/clippy_lints/src/unnecessary_wraps.rs @@ -13,15 +13,17 @@ use rustc_span::symbol::sym; use rustc_span::Span; declare_clippy_lint! { - /// **What it does:** Checks for private functions that only return `Ok` or `Some`. + /// ### What it does + /// Checks for private functions that only return `Ok` or `Some`. /// - /// **Why is this bad?** It is not meaningful to wrap values when no `None` or `Err` is returned. + /// ### Why is this bad? + /// It is not meaningful to wrap values when no `None` or `Err` is returned. /// - /// **Known problems:** There can be false positives if the function signature is designed to + /// ### Known problems + /// There can be false positives if the function signature is designed to /// fit some external requirement. /// - /// **Example:** - /// + /// ### Example /// ```rust /// fn get_cool_number(a: bool, b: bool) -> Option { /// if a && b { diff --git a/clippy_lints/src/unnested_or_patterns.rs b/clippy_lints/src/unnested_or_patterns.rs index 07a4e294049..9acfbc994b3 100644 --- a/clippy_lints/src/unnested_or_patterns.rs +++ b/clippy_lints/src/unnested_or_patterns.rs @@ -17,22 +17,17 @@ use std::cell::Cell; use std::mem; declare_clippy_lint! { - /// **What it does:** - /// + /// ### What it does /// Checks for unnested or-patterns, e.g., `Some(0) | Some(2)` and /// suggests replacing the pattern with a nested one, `Some(0 | 2)`. /// /// Another way to think of this is that it rewrites patterns in /// *disjunctive normal form (DNF)* into *conjunctive normal form (CNF)*. /// - /// **Why is this bad?** - /// + /// ### Why is this bad? /// In the example above, `Some` is repeated, which unncessarily complicates the pattern. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust /// fn main() { /// if let Some(0) | Some(2) = Some(0) {} diff --git a/clippy_lints/src/unsafe_removed_from_name.rs b/clippy_lints/src/unsafe_removed_from_name.rs index 16ad9d2dfd3..3c694af2b9d 100644 --- a/clippy_lints/src/unsafe_removed_from_name.rs +++ b/clippy_lints/src/unsafe_removed_from_name.rs @@ -6,15 +6,15 @@ use rustc_span::source_map::Span; use rustc_span::symbol::Ident; declare_clippy_lint! { - /// **What it does:** Checks for imports that remove "unsafe" from an item's + /// ### What it does + /// Checks for imports that remove "unsafe" from an item's /// name. /// - /// **Why is this bad?** Renaming makes it less clear which traits and + /// ### Why is this bad? + /// Renaming makes it less clear which traits and /// structures are unsafe. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust,ignore /// use std::cell::{UnsafeCell as TotallySafeCell}; /// diff --git a/clippy_lints/src/unused_async.rs b/clippy_lints/src/unused_async.rs index 18ee07d3a95..3a6a07c5226 100644 --- a/clippy_lints/src/unused_async.rs +++ b/clippy_lints/src/unused_async.rs @@ -7,16 +7,15 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::Span; declare_clippy_lint! { - /// **What it does:** Checks for functions that are declared `async` but have no `.await`s inside of them. + /// ### What it does + /// Checks for functions that are declared `async` but have no `.await`s inside of them. /// - /// **Why is this bad?** Async functions with no async code create overhead, both mentally and computationally. + /// ### Why is this bad? + /// Async functions with no async code create overhead, both mentally and computationally. /// Callers of async methods either need to be calling from an async function themselves or run it on an executor, both of which /// causes runtime overhead and hassle for the caller. /// - /// **Known problems:** None - /// - /// **Example:** - /// + /// ### Example /// ```rust /// // Bad /// async fn get_random_number() -> i64 { diff --git a/clippy_lints/src/unused_io_amount.rs b/clippy_lints/src/unused_io_amount.rs index ee082d30d93..82bc4a6d153 100644 --- a/clippy_lints/src/unused_io_amount.rs +++ b/clippy_lints/src/unused_io_amount.rs @@ -5,9 +5,11 @@ use rustc_lint::{LateContext, LateLintPass}; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks for unused written/read amount. + /// ### What it does + /// Checks for unused written/read amount. /// - /// **Why is this bad?** `io::Write::write(_vectored)` and + /// ### Why is this bad? + /// `io::Write::write(_vectored)` and /// `io::Read::read(_vectored)` are not guaranteed to /// process the entire buffer. They return how many bytes were processed, which /// might be smaller @@ -15,9 +17,10 @@ declare_clippy_lint! { /// partial-write/read, use /// `write_all`/`read_exact` instead. /// - /// **Known problems:** Detects only common patterns. + /// ### Known problems + /// Detects only common patterns. /// - /// **Example:** + /// ### Example /// ```rust,ignore /// use std::io; /// fn foo(w: &mut W) -> io::Result<()> { diff --git a/clippy_lints/src/unused_self.rs b/clippy_lints/src/unused_self.rs index 15343cf90f2..658ac81f6ea 100644 --- a/clippy_lints/src/unused_self.rs +++ b/clippy_lints/src/unused_self.rs @@ -6,14 +6,14 @@ use rustc_lint::{LateContext, LateLintPass}; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks methods that contain a `self` argument but don't use it + /// ### What it does + /// Checks methods that contain a `self` argument but don't use it /// - /// **Why is this bad?** It may be clearer to define the method as an associated function instead + /// ### Why is this bad? + /// It may be clearer to define the method as an associated function instead /// of an instance method if it doesn't require `self`. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust,ignore /// struct A; /// impl A { diff --git a/clippy_lints/src/unused_unit.rs b/clippy_lints/src/unused_unit.rs index ab0cdf75ffe..9ed5e585f84 100644 --- a/clippy_lints/src/unused_unit.rs +++ b/clippy_lints/src/unused_unit.rs @@ -10,15 +10,15 @@ use rustc_span::source_map::Span; use rustc_span::BytePos; declare_clippy_lint! { - /// **What it does:** Checks for unit (`()`) expressions that can be removed. + /// ### What it does + /// Checks for unit (`()`) expressions that can be removed. /// - /// **Why is this bad?** Such expressions add no value, but can make the code + /// ### Why is this bad? + /// Such expressions add no value, but can make the code /// less readable. Depending on formatting they can make a `break` or `return` /// statement look like a function call. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// fn return_unit() -> () { /// () diff --git a/clippy_lints/src/unwrap.rs b/clippy_lints/src/unwrap.rs index d4efee56eff..c5b8acb9982 100644 --- a/clippy_lints/src/unwrap.rs +++ b/clippy_lints/src/unwrap.rs @@ -13,13 +13,13 @@ use rustc_span::source_map::Span; use rustc_span::sym; declare_clippy_lint! { - /// **What it does:** Checks for calls of `unwrap[_err]()` that cannot fail. + /// ### What it does + /// Checks for calls of `unwrap[_err]()` that cannot fail. /// - /// **Why is this bad?** Using `if let` or `match` is more idiomatic. + /// ### Why is this bad? + /// Using `if let` or `match` is more idiomatic. /// - /// **Known problems:** None - /// - /// **Example:** + /// ### Example /// ```rust /// # let option = Some(0); /// # fn do_something_with(_x: usize) {} @@ -43,14 +43,17 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for calls of `unwrap[_err]()` that will always fail. + /// ### What it does + /// Checks for calls of `unwrap[_err]()` that will always fail. /// - /// **Why is this bad?** If panicking is desired, an explicit `panic!()` should be used. + /// ### Why is this bad? + /// If panicking is desired, an explicit `panic!()` should be used. /// - /// **Known problems:** This lint only checks `if` conditions not assignments. + /// ### Known problems + /// This lint only checks `if` conditions not assignments. /// So something like `let x: Option<()> = None; x.unwrap();` will not be recognized. /// - /// **Example:** + /// ### Example /// ```rust /// # let option = Some(0); /// # fn do_something_with(_x: usize) {} diff --git a/clippy_lints/src/unwrap_in_result.rs b/clippy_lints/src/unwrap_in_result.rs index d17aa6d8424..6eadd1fc1c9 100644 --- a/clippy_lints/src/unwrap_in_result.rs +++ b/clippy_lints/src/unwrap_in_result.rs @@ -12,13 +12,16 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::{sym, Span}; declare_clippy_lint! { - /// **What it does:** Checks for functions of type Result that contain `expect()` or `unwrap()` + /// ### What it does + /// Checks for functions of type Result that contain `expect()` or `unwrap()` /// - /// **Why is this bad?** These functions promote recoverable errors to non-recoverable errors which may be undesirable in code bases which wish to avoid panics. + /// ### Why is this bad? + /// These functions promote recoverable errors to non-recoverable errors which may be undesirable in code bases which wish to avoid panics. /// - /// **Known problems:** This can cause false positives in functions that handle both recoverable and non recoverable errors. + /// ### Known problems + /// This can cause false positives in functions that handle both recoverable and non recoverable errors. /// - /// **Example:** + /// ### Example /// Before: /// ```rust /// fn divisible_by_3(i_str: String) -> Result<(), String> { diff --git a/clippy_lints/src/upper_case_acronyms.rs b/clippy_lints/src/upper_case_acronyms.rs index 0b58c6c0917..7fa0e23ee73 100644 --- a/clippy_lints/src/upper_case_acronyms.rs +++ b/clippy_lints/src/upper_case_acronyms.rs @@ -8,9 +8,11 @@ use rustc_session::{declare_tool_lint, impl_lint_pass}; use rustc_span::symbol::Ident; declare_clippy_lint! { - /// **What it does:** Checks for fully capitalized names and optionally names containing a capitalized acronym. + /// ### What it does + /// Checks for fully capitalized names and optionally names containing a capitalized acronym. /// - /// **Why is this bad?** In CamelCase, acronyms count as one word. + /// ### Why is this bad? + /// In CamelCase, acronyms count as one word. /// See [naming conventions](https://rust-lang.github.io/api-guidelines/naming.html#casing-conforms-to-rfc-430-c-case) /// for more. /// @@ -18,12 +20,12 @@ declare_clippy_lint! { /// You can use the `upper-case-acronyms-aggressive: true` config option to enable linting /// on all camel case names /// - /// **Known problems:** When two acronyms are contiguous, the lint can't tell where + /// ### Known problems + /// When two acronyms are contiguous, the lint can't tell where /// the first acronym ends and the second starts, so it suggests to lowercase all of /// the letters in the second acronym. /// - /// **Example:** - /// + /// ### Example /// ```rust /// struct HTTPResponse; /// ``` diff --git a/clippy_lints/src/use_self.rs b/clippy_lints/src/use_self.rs index 71117e967e3..fbd552186df 100644 --- a/clippy_lints/src/use_self.rs +++ b/clippy_lints/src/use_self.rs @@ -20,19 +20,20 @@ use rustc_span::Span; use rustc_typeck::hir_ty_to_ty; declare_clippy_lint! { - /// **What it does:** Checks for unnecessary repetition of structure name when a + /// ### What it does + /// Checks for unnecessary repetition of structure name when a /// replacement with `Self` is applicable. /// - /// **Why is this bad?** Unnecessary repetition. Mixed use of `Self` and struct + /// ### Why is this bad? + /// Unnecessary repetition. Mixed use of `Self` and struct /// name /// feels inconsistent. /// - /// **Known problems:** + /// ### Known problems /// - Unaddressed false negative in fn bodies of trait implementations /// - False positive with assotiated types in traits (#4140) /// - /// **Example:** - /// + /// ### Example /// ```rust /// struct Foo {} /// impl Foo { diff --git a/clippy_lints/src/useless_conversion.rs b/clippy_lints/src/useless_conversion.rs index 25a959d3e41..2861b432919 100644 --- a/clippy_lints/src/useless_conversion.rs +++ b/clippy_lints/src/useless_conversion.rs @@ -12,15 +12,14 @@ use rustc_session::{declare_tool_lint, impl_lint_pass}; use rustc_span::sym; declare_clippy_lint! { - /// **What it does:** Checks for `Into`, `TryInto`, `From`, `TryFrom`, or `IntoIter` calls + /// ### What it does + /// Checks for `Into`, `TryInto`, `From`, `TryFrom`, or `IntoIter` calls /// which uselessly convert to the same type. /// - /// **Why is this bad?** Redundant code. - /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Why is this bad? + /// Redundant code. /// + /// ### Example /// ```rust /// // Bad /// // format!() returns a `String` diff --git a/clippy_lints/src/utils/author.rs b/clippy_lints/src/utils/author.rs index c1e7fd7fe95..61fd375a989 100644 --- a/clippy_lints/src/utils/author.rs +++ b/clippy_lints/src/utils/author.rs @@ -13,9 +13,10 @@ use rustc_middle::hir::map::Map; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Generates clippy code that detects the offending pattern + /// ### What it does + /// Generates clippy code that detects the offending pattern /// - /// **Example:** + /// ### Example /// ```rust,ignore /// // ./tests/ui/my_lint.rs /// fn foo() { diff --git a/clippy_lints/src/utils/inspector.rs b/clippy_lints/src/utils/inspector.rs index 4665eeeff7b..f7ddee12dcf 100644 --- a/clippy_lints/src/utils/inspector.rs +++ b/clippy_lints/src/utils/inspector.rs @@ -8,10 +8,11 @@ use rustc_session::Session; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Dumps every ast/hir node which has the `#[clippy::dump]` + /// ### What it does + /// Dumps every ast/hir node which has the `#[clippy::dump]` /// attribute /// - /// **Example:** + /// ### Example /// ```rust,ignore /// #[clippy::dump] /// extern crate foo; diff --git a/clippy_lints/src/utils/internal_lints.rs b/clippy_lints/src/utils/internal_lints.rs index 668807f499f..d660008e7d1 100644 --- a/clippy_lints/src/utils/internal_lints.rs +++ b/clippy_lints/src/utils/internal_lints.rs @@ -36,29 +36,33 @@ use std::borrow::{Borrow, Cow}; pub mod metadata_collector; declare_clippy_lint! { - /// **What it does:** Checks for various things we like to keep tidy in clippy. + /// ### What it does + /// Checks for various things we like to keep tidy in clippy. /// - /// **Why is this bad?** We like to pretend we're an example of tidy code. + /// ### Why is this bad? + /// We like to pretend we're an example of tidy code. /// - /// **Known problems:** None. - /// - /// **Example:** Wrong ordering of the util::paths constants. + /// ### Example + /// Wrong ordering of the util::paths constants. pub CLIPPY_LINTS_INTERNAL, internal, "various things that will negatively affect your clippy experience" } declare_clippy_lint! { - /// **What it does:** Ensures every lint is associated to a `LintPass`. + /// ### What it does + /// Ensures every lint is associated to a `LintPass`. /// - /// **Why is this bad?** The compiler only knows lints via a `LintPass`. Without + /// ### Why is this bad? + /// The compiler only knows lints via a `LintPass`. Without /// putting a lint to a `LintPass::get_lints()`'s return, the compiler will not /// know the name of the lint. /// - /// **Known problems:** Only checks for lints associated using the + /// ### Known problems + /// Only checks for lints associated using the /// `declare_lint_pass!`, `impl_lint_pass!`, and `lint_array!` macros. /// - /// **Example:** + /// ### Example /// ```rust,ignore /// declare_lint! { pub LINT_1, ... } /// declare_lint! { pub LINT_2, ... } @@ -73,15 +77,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for calls to `cx.span_lint*` and suggests to use the `utils::*` + /// ### What it does + /// Checks for calls to `cx.span_lint*` and suggests to use the `utils::*` /// variant of the function. /// - /// **Why is this bad?** The `utils::*` variants also add a link to the Clippy documentation to the + /// ### Why is this bad? + /// The `utils::*` variants also add a link to the Clippy documentation to the /// warning/error messages. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// Bad: /// ```rust,ignore /// cx.span_lint(LINT_NAME, "message"); @@ -97,14 +101,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for calls to `cx.outer().expn_data()` and suggests to use + /// ### What it does + /// Checks for calls to `cx.outer().expn_data()` and suggests to use /// the `cx.outer_expn_data()` /// - /// **Why is this bad?** `cx.outer_expn_data()` is faster and more concise. - /// - /// **Known problems:** None. + /// ### Why is this bad? + /// `cx.outer_expn_data()` is faster and more concise. /// - /// **Example:** + /// ### Example /// Bad: /// ```rust,ignore /// expr.span.ctxt().outer().expn_data() @@ -120,14 +124,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Not an actual lint. This lint is only meant for testing our customized internal compiler + /// ### What it does + /// Not an actual lint. This lint is only meant for testing our customized internal compiler /// error message by calling `panic`. /// - /// **Why is this bad?** ICE in large quantities can damage your teeth + /// ### Why is this bad? + /// ICE in large quantities can damage your teeth /// - /// **Known problems:** None - /// - /// **Example:** + /// ### Example /// Bad: /// ```rust,ignore /// 🍦🍦🍦🍦🍦 @@ -138,14 +142,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for cases of an auto-generated lint without an updated description, + /// ### What it does + /// Checks for cases of an auto-generated lint without an updated description, /// i.e. `default lint description`. /// - /// **Why is this bad?** Indicates that the lint is not finished. - /// - /// **Known problems:** None + /// ### Why is this bad? + /// Indicates that the lint is not finished. /// - /// **Example:** + /// ### Example /// Bad: /// ```rust,ignore /// declare_lint! { pub COOL_LINT, nursery, "default lint description" } @@ -161,7 +165,8 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Lints `span_lint_and_then` function calls, where the + /// ### What it does + /// Lints `span_lint_and_then` function calls, where the /// closure argument has only one statement and that statement is a method /// call to `span_suggestion`, `span_help`, `span_note` (using the same /// span), `help` or `note`. @@ -170,12 +175,11 @@ declare_clippy_lint! { /// wrapper functions `span_lint_and_sugg`, span_lint_and_help`, or /// `span_lint_and_note`. /// - /// **Why is this bad?** Using the wrapper `span_lint_and_*` functions, is more + /// ### Why is this bad? + /// Using the wrapper `span_lint_and_*` functions, is more /// convenient, readable and less error prone. /// - /// **Known problems:** None - /// - /// *Example:** + /// ### Example /// Bad: /// ```rust,ignore /// span_lint_and_then(cx, TEST_LINT, expr.span, lint_msg, |diag| { @@ -222,14 +226,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for calls to `utils::match_type()` on a type diagnostic item + /// ### What it does + /// Checks for calls to `utils::match_type()` on a type diagnostic item /// and suggests to use `utils::is_type_diagnostic_item()` instead. /// - /// **Why is this bad?** `utils::is_type_diagnostic_item()` does not require hardcoded paths. - /// - /// **Known problems:** None. + /// ### Why is this bad? + /// `utils::is_type_diagnostic_item()` does not require hardcoded paths. /// - /// **Example:** + /// ### Example /// Bad: /// ```rust,ignore /// utils::match_type(cx, ty, &paths::VEC) @@ -245,30 +249,27 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** + /// ### What it does /// Checks the paths module for invalid paths. /// - /// **Why is this bad?** + /// ### Why is this bad? /// It indicates a bug in the code. /// - /// **Known problems:** None. - /// - /// **Example:** None. + /// ### Example + /// None. pub INVALID_PATHS, internal, "invalid path" } declare_clippy_lint! { - /// **What it does:** + /// ### What it does /// Checks for interning symbols that have already been pre-interned and defined as constants. /// - /// **Why is this bad?** + /// ### Why is this bad? /// It's faster and easier to use the symbol constant. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// Bad: /// ```rust,ignore /// let _ = sym!(f32); @@ -284,13 +285,13 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for unnecessary conversion from Symbol to a string. - /// - /// **Why is this bad?** It's faster use symbols directly intead of strings. + /// ### What it does + /// Checks for unnecessary conversion from Symbol to a string. /// - /// **Known problems:** None. + /// ### Why is this bad? + /// It's faster use symbols directly intead of strings. /// - /// **Example:** + /// ### Example /// Bad: /// ```rust,ignore /// symbol.as_str() == "clippy"; diff --git a/clippy_lints/src/utils/internal_lints/metadata_collector.rs b/clippy_lints/src/utils/internal_lints/metadata_collector.rs index 3eccc89cdeb..3244677b301 100644 --- a/clippy_lints/src/utils/internal_lints/metadata_collector.rs +++ b/clippy_lints/src/utils/internal_lints/metadata_collector.rs @@ -68,7 +68,7 @@ const CLIPPY_LINT_GROUP_PREFIX: &str = "clippy::"; macro_rules! CONFIGURATION_SECTION_TEMPLATE { () => { r#" -**Configuration** +### Configuration This lint has the following configuration variables: {configurations} @@ -116,18 +116,21 @@ const DEPRECATED_LINT_TYPE: [&str; 3] = ["clippy_lints", "deprecated_lints", "Cl const APPLICABILITY_NAME_INDEX: usize = 2; declare_clippy_lint! { - /// **What it does:** Collects metadata about clippy lints for the website. + /// ### What it does + /// Collects metadata about clippy lints for the website. /// /// This lint will be used to report problems of syntax parsing. You should hopefully never /// see this but never say never I guess ^^ /// - /// **Why is this bad?** This is not a bad thing but definitely a hacky way to do it. See + /// ### Why is this bad? + /// This is not a bad thing but definitely a hacky way to do it. See /// issue [#4310](https://github.com/rust-lang/rust-clippy/issues/4310) for a discussion /// about the implementation. /// - /// **Known problems:** Hopefully none. It would be pretty uncool to have a problem here :) + /// ### Known problems + /// Hopefully none. It would be pretty uncool to have a problem here :) /// - /// **Example output:** + /// ### Example output /// ```json,ignore /// { /// "id": "internal_metadata_collector", @@ -374,7 +377,8 @@ impl<'hir> LateLintPass<'hir> for MetadataCollector { /// Collecting lint declarations like: /// ```rust, ignore /// declare_clippy_lint! { - /// /// **What it does:** Something IDK. + /// /// ### What it does + /// /// Something IDK. /// pub SOME_LINT, /// internal, /// "Who am I?" diff --git a/clippy_lints/src/vec.rs b/clippy_lints/src/vec.rs index 1d5b7c98d31..32fa46f042c 100644 --- a/clippy_lints/src/vec.rs +++ b/clippy_lints/src/vec.rs @@ -19,14 +19,14 @@ pub struct UselessVec { } declare_clippy_lint! { - /// **What it does:** Checks for usage of `&vec![..]` when using `&[..]` would + /// ### What it does + /// Checks for usage of `&vec![..]` when using `&[..]` would /// be possible. /// - /// **Why is this bad?** This is less efficient. + /// ### Why is this bad? + /// This is less efficient. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// # fn foo(my_vec: &[u8]) {} /// diff --git a/clippy_lints/src/vec_init_then_push.rs b/clippy_lints/src/vec_init_then_push.rs index c7190e2f979..0413c02b230 100644 --- a/clippy_lints/src/vec_init_then_push.rs +++ b/clippy_lints/src/vec_init_then_push.rs @@ -13,15 +13,14 @@ use rustc_span::{symbol::sym, Span}; use std::convert::TryInto; declare_clippy_lint! { - /// **What it does:** Checks for calls to `push` immediately after creating a new `Vec`. + /// ### What it does + /// Checks for calls to `push` immediately after creating a new `Vec`. /// - /// **Why is this bad?** The `vec![]` macro is both more performant and easier to read than + /// ### Why is this bad? + /// The `vec![]` macro is both more performant and easier to read than /// multiple `push` calls. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust /// let mut v = Vec::new(); /// v.push(0); diff --git a/clippy_lints/src/vec_resize_to_zero.rs b/clippy_lints/src/vec_resize_to_zero.rs index 5540e87405f..5c0429db6b8 100644 --- a/clippy_lints/src/vec_resize_to_zero.rs +++ b/clippy_lints/src/vec_resize_to_zero.rs @@ -10,13 +10,13 @@ use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::source_map::Spanned; declare_clippy_lint! { - /// **What it does:** Finds occurrences of `Vec::resize(0, an_int)` + /// ### What it does + /// Finds occurrences of `Vec::resize(0, an_int)` /// - /// **Why is this bad?** This is probably an argument inversion mistake. + /// ### Why is this bad? + /// This is probably an argument inversion mistake. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// vec!(1, 2, 3, 4, 5).resize(0, 5) /// ``` diff --git a/clippy_lints/src/verbose_file_reads.rs b/clippy_lints/src/verbose_file_reads.rs index 3ab68df2b6d..e07c12f4f16 100644 --- a/clippy_lints/src/verbose_file_reads.rs +++ b/clippy_lints/src/verbose_file_reads.rs @@ -7,15 +7,14 @@ use rustc_lint::{LateContext, LateLintPass}; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks for use of File::read_to_end and File::read_to_string. + /// ### What it does + /// Checks for use of File::read_to_end and File::read_to_string. /// - /// **Why is this bad?** `fs::{read, read_to_string}` provide the same functionality when `buf` is empty with fewer imports and no intermediate values. + /// ### Why is this bad? + /// `fs::{read, read_to_string}` provide the same functionality when `buf` is empty with fewer imports and no intermediate values. /// See also: [fs::read docs](https://doc.rust-lang.org/std/fs/fn.read.html), [fs::read_to_string docs](https://doc.rust-lang.org/std/fs/fn.read_to_string.html) /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```rust,no_run /// # use std::io::Read; /// # use std::fs::File; diff --git a/clippy_lints/src/wildcard_dependencies.rs b/clippy_lints/src/wildcard_dependencies.rs index 1ca1117a41e..fd3872bacbe 100644 --- a/clippy_lints/src/wildcard_dependencies.rs +++ b/clippy_lints/src/wildcard_dependencies.rs @@ -7,16 +7,15 @@ use rustc_span::source_map::DUMMY_SP; use if_chain::if_chain; declare_clippy_lint! { - /// **What it does:** Checks for wildcard dependencies in the `Cargo.toml`. + /// ### What it does + /// Checks for wildcard dependencies in the `Cargo.toml`. /// - /// **Why is this bad?** [As the edition guide says](https://rust-lang-nursery.github.io/edition-guide/rust-2018/cargo-and-crates-io/crates-io-disallows-wildcard-dependencies.html), + /// ### Why is this bad? + /// [As the edition guide says](https://rust-lang-nursery.github.io/edition-guide/rust-2018/cargo-and-crates-io/crates-io-disallows-wildcard-dependencies.html), /// it is highly unlikely that you work with any possible version of your dependency, /// and wildcard dependencies would cause unnecessary breakage in the ecosystem. /// - /// **Known problems:** None. - /// - /// **Example:** - /// + /// ### Example /// ```toml /// [dependencies] /// regex = "*" diff --git a/clippy_lints/src/wildcard_imports.rs b/clippy_lints/src/wildcard_imports.rs index 520586b3a1f..bafb9d3e3b1 100644 --- a/clippy_lints/src/wildcard_imports.rs +++ b/clippy_lints/src/wildcard_imports.rs @@ -13,15 +13,18 @@ use rustc_span::symbol::kw; use rustc_span::{sym, BytePos}; declare_clippy_lint! { - /// **What it does:** Checks for `use Enum::*`. + /// ### What it does + /// Checks for `use Enum::*`. /// - /// **Why is this bad?** It is usually better style to use the prefixed name of + /// ### Why is this bad? + /// It is usually better style to use the prefixed name of /// an enumeration variant, rather than importing variants. /// - /// **Known problems:** Old-style enumerations that prefix the variants are + /// ### Known problems + /// Old-style enumerations that prefix the variants are /// still around. /// - /// **Example:** + /// ### Example /// ```rust,ignore /// // Bad /// use std::cmp::Ordering::*; @@ -37,9 +40,11 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for wildcard imports `use _::*`. + /// ### What it does + /// Checks for wildcard imports `use _::*`. /// - /// **Why is this bad?** wildcard imports can pollute the namespace. This is especially bad if + /// ### Why is this bad? + /// wildcard imports can pollute the namespace. This is especially bad if /// you try to import something through a wildcard, that already has been imported by name from /// a different source: /// @@ -52,8 +57,7 @@ declare_clippy_lint! { /// /// This can lead to confusing error messages at best and to unexpected behavior at worst. /// - /// **Exceptions:** - /// + /// ### Exceptions /// Wildcard imports are allowed from modules named `prelude`. Many crates (including the standard library) /// provide modules named "prelude" specifically designed for wildcard import. /// @@ -61,14 +65,14 @@ declare_clippy_lint! { /// /// These exceptions can be disabled using the `warn-on-all-wildcard-imports` configuration flag. /// - /// **Known problems:** If macros are imported through the wildcard, this macro is not included + /// ### Known problems + /// If macros are imported through the wildcard, this macro is not included /// by the suggestion and has to be added by hand. /// /// Applying the suggestion when explicit imports of the things imported with a glob import /// exist, may result in `unused_imports` warnings. /// - /// **Example:** - /// + /// ### Example /// ```rust,ignore /// // Bad /// use crate1::*; diff --git a/clippy_lints/src/write.rs b/clippy_lints/src/write.rs index 5229a705865..4553ac704a2 100644 --- a/clippy_lints/src/write.rs +++ b/clippy_lints/src/write.rs @@ -16,14 +16,14 @@ use rustc_span::symbol::{kw, Symbol}; use rustc_span::{sym, BytePos, Span, DUMMY_SP}; declare_clippy_lint! { - /// **What it does:** This lint warns when you use `println!("")` to + /// ### What it does + /// This lint warns when you use `println!("")` to /// print a newline. /// - /// **Why is this bad?** You should use `println!()`, which is simpler. + /// ### Why is this bad? + /// You should use `println!()`, which is simpler. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// // Bad /// println!(""); @@ -37,15 +37,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** This lint warns when you use `print!()` with a format + /// ### What it does + /// This lint warns when you use `print!()` with a format /// string that ends in a newline. /// - /// **Why is this bad?** You should use `println!()` instead, which appends the + /// ### Why is this bad? + /// You should use `println!()` instead, which appends the /// newline. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// # let name = "World"; /// print!("Hello {}!\n", name); @@ -61,15 +61,18 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for printing on *stdout*. The purpose of this lint + /// ### What it does + /// Checks for printing on *stdout*. The purpose of this lint /// is to catch debugging remnants. /// - /// **Why is this bad?** People often print on *stdout* while debugging an + /// ### Why is this bad? + /// People often print on *stdout* while debugging an /// application and might forget to remove those prints afterward. /// - /// **Known problems:** Only catches `print!` and `println!` calls. + /// ### Known problems + /// Only catches `print!` and `println!` calls. /// - /// **Example:** + /// ### Example /// ```rust /// println!("Hello world!"); /// ``` @@ -79,15 +82,18 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for printing on *stderr*. The purpose of this lint + /// ### What it does + /// Checks for printing on *stderr*. The purpose of this lint /// is to catch debugging remnants. /// - /// **Why is this bad?** People often print on *stderr* while debugging an + /// ### Why is this bad? + /// People often print on *stderr* while debugging an /// application and might forget to remove those prints afterward. /// - /// **Known problems:** Only catches `eprint!` and `eprintln!` calls. + /// ### Known problems + /// Only catches `eprint!` and `eprintln!` calls. /// - /// **Example:** + /// ### Example /// ```rust /// eprintln!("Hello world!"); /// ``` @@ -97,13 +103,15 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** Checks for use of `Debug` formatting. The purpose of this + /// ### What it does + /// Checks for use of `Debug` formatting. The purpose of this /// lint is to catch debugging remnants. /// - /// **Why is this bad?** The purpose of the `Debug` trait is to facilitate + /// ### Why is this bad? + /// The purpose of the `Debug` trait is to facilitate /// debugging Rust code. It should not be used in user-facing output. /// - /// **Example:** + /// ### Example /// ```rust /// # let foo = "bar"; /// println!("{:?}", foo); @@ -114,16 +122,19 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** This lint warns about the use of literals as `print!`/`println!` args. + /// ### What it does + /// This lint warns about the use of literals as `print!`/`println!` args. /// - /// **Why is this bad?** Using literals as `println!` args is inefficient + /// ### Why is this bad? + /// Using literals as `println!` args is inefficient /// (c.f., https://github.com/matthiaskrgr/rust-str-bench) and unnecessary /// (i.e., just put the literal in the format string) /// - /// **Known problems:** Will also warn with macro calls as arguments that expand to literals + /// ### Known problems + /// Will also warn with macro calls as arguments that expand to literals /// -- e.g., `println!("{}", env!("FOO"))`. /// - /// **Example:** + /// ### Example /// ```rust /// println!("{}", "foo"); /// ``` @@ -137,14 +148,14 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** This lint warns when you use `writeln!(buf, "")` to + /// ### What it does + /// This lint warns when you use `writeln!(buf, "")` to /// print a newline. /// - /// **Why is this bad?** You should use `writeln!(buf)`, which is simpler. + /// ### Why is this bad? + /// You should use `writeln!(buf)`, which is simpler. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// # use std::fmt::Write; /// # let mut buf = String::new(); @@ -160,16 +171,16 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** This lint warns when you use `write!()` with a format + /// ### What it does + /// This lint warns when you use `write!()` with a format /// string that /// ends in a newline. /// - /// **Why is this bad?** You should use `writeln!()` instead, which appends the + /// ### Why is this bad? + /// You should use `writeln!()` instead, which appends the /// newline. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// # use std::fmt::Write; /// # let mut buf = String::new(); @@ -186,16 +197,19 @@ declare_clippy_lint! { } declare_clippy_lint! { - /// **What it does:** This lint warns about the use of literals as `write!`/`writeln!` args. + /// ### What it does + /// This lint warns about the use of literals as `write!`/`writeln!` args. /// - /// **Why is this bad?** Using literals as `writeln!` args is inefficient + /// ### Why is this bad? + /// Using literals as `writeln!` args is inefficient /// (c.f., https://github.com/matthiaskrgr/rust-str-bench) and unnecessary /// (i.e., just put the literal in the format string) /// - /// **Known problems:** Will also warn with macro calls as arguments that expand to literals + /// ### Known problems + /// Will also warn with macro calls as arguments that expand to literals /// -- e.g., `writeln!(buf, "{}", env!("FOO"))`. /// - /// **Example:** + /// ### Example /// ```rust /// # use std::fmt::Write; /// # let mut buf = String::new(); diff --git a/clippy_lints/src/zero_div_zero.rs b/clippy_lints/src/zero_div_zero.rs index a1ea743ba80..b29ced28ac4 100644 --- a/clippy_lints/src/zero_div_zero.rs +++ b/clippy_lints/src/zero_div_zero.rs @@ -6,13 +6,13 @@ use rustc_lint::{LateContext, LateLintPass}; use rustc_session::{declare_lint_pass, declare_tool_lint}; declare_clippy_lint! { - /// **What it does:** Checks for `0.0 / 0.0`. + /// ### What it does + /// Checks for `0.0 / 0.0`. /// - /// **Why is this bad?** It's less readable than `f32::NAN` or `f64::NAN`. + /// ### Why is this bad? + /// It's less readable than `f32::NAN` or `f64::NAN`. /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Example /// ```rust /// // Bad /// let nan = 0.0f32 / 0.0; diff --git a/clippy_lints/src/zero_sized_map_values.rs b/clippy_lints/src/zero_sized_map_values.rs index d6a8112218f..2fbe27f9479 100644 --- a/clippy_lints/src/zero_sized_map_values.rs +++ b/clippy_lints/src/zero_sized_map_values.rs @@ -10,18 +10,19 @@ use rustc_target::abi::LayoutOf as _; use rustc_typeck::hir_ty_to_ty; declare_clippy_lint! { - /// **What it does:** Checks for maps with zero-sized value types anywhere in the code. + /// ### What it does + /// Checks for maps with zero-sized value types anywhere in the code. /// - /// **Why is this bad?** Since there is only a single value for a zero-sized type, a map + /// ### Why is this bad? + /// Since there is only a single value for a zero-sized type, a map /// containing zero sized values is effectively a set. Using a set in that case improves /// readability and communicates intent more clearly. /// - /// **Known problems:** + /// ### Known problems /// * A zero-sized type cannot be recovered later if it contains private fields. /// * This lints the signature of public items /// - /// **Example:** - /// + /// ### Example /// ```rust /// # use std::collections::HashMap; /// fn unique_words(text: &str) -> HashMap<&str, ()> { diff --git a/doc/adding_lints.md b/doc/adding_lints.md index 5a06afedbf4..f2260c3d1a2 100644 --- a/doc/adding_lints.md +++ b/doc/adding_lints.md @@ -11,6 +11,7 @@ because that's clearly a non-descriptive name. - [Setup](#setup) - [Getting Started](#getting-started) - [Testing](#testing) + - [Cargo lints](#cargo-lints) - [Rustfix tests](#rustfix-tests) - [Edition 2018 tests](#edition-2018-tests) - [Testing manually](#testing-manually) @@ -179,14 +180,11 @@ the auto-generated lint declaration to have a real description, something like t ```rust declare_clippy_lint! { - /// **What it does:** + /// ### What it does /// - /// **Why is this bad?** - /// - /// **Known problems:** None. - /// - /// **Example:** + /// ### Why is this bad? /// + /// ### Example /// ```rust /// // example code /// ``` @@ -487,13 +485,13 @@ Please document your lint with a doc comment akin to the following: ```rust declare_clippy_lint! { - /// **What it does:** Checks for ... (describe what the lint matches). - /// - /// **Why is this bad?** Supply the reason for linting the code. + /// ### What it does + /// Checks for ... (describe what the lint matches). /// - /// **Known problems:** None. (Or describe where it could go wrong.) + /// ### Why is this bad? + /// Supply the reason for linting the code. /// - /// **Example:** + /// ### Example /// /// ```rust,ignore /// // Bad -- cgit 1.4.1-3-g733a5 From c951a3c68daefb078d7e52e87e3cebbfa9a13f10 Mon Sep 17 00:00:00 2001 From: flip1995 Date: Wed, 28 Jul 2021 15:05:11 +0200 Subject: Run cargo collect-metadata in cargo dev serve --- clippy_dev/src/serve.rs | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/serve.rs b/clippy_dev/src/serve.rs index d13c27a1957..b36e2a28ee4 100644 --- a/clippy_dev/src/serve.rs +++ b/clippy_dev/src/serve.rs @@ -15,8 +15,8 @@ pub fn run(port: u16, lint: Option<&str>) -> ! { loop { if mtime("util/gh-pages/lints.json") < mtime("clippy_lints/src") { - Command::new("python3") - .arg("util/export.py") + Command::new("cargo") + .arg("collect-metadata") .spawn() .unwrap() .wait() -- cgit 1.4.1-3-g733a5 From 68b4a43e23d9c7e847e71cdbfa9d915df4997e38 Mon Sep 17 00:00:00 2001 From: Cameron Steffen Date: Mon, 23 Aug 2021 10:58:56 -0500 Subject: Remove stderr limit --- .github/workflows/clippy_dev.yml | 3 --- clippy_dev/src/lib.rs | 1 - clippy_dev/src/main.rs | 9 +------ clippy_dev/src/stderr_length_check.rs | 51 ----------------------------------- 4 files changed, 1 insertion(+), 63 deletions(-) delete mode 100644 clippy_dev/src/stderr_length_check.rs (limited to 'clippy_dev/src') diff --git a/.github/workflows/clippy_dev.yml b/.github/workflows/clippy_dev.yml index 95da775b7bc..9a5416153ab 100644 --- a/.github/workflows/clippy_dev.yml +++ b/.github/workflows/clippy_dev.yml @@ -42,9 +42,6 @@ jobs: run: cargo build --features deny-warnings working-directory: clippy_dev - - name: Test limit_stderr_length - run: cargo dev limit_stderr_length - - name: Test update_lints run: cargo dev update_lints --check diff --git a/clippy_dev/src/lib.rs b/clippy_dev/src/lib.rs index 72bdaf8d592..e05db7af586 100644 --- a/clippy_dev/src/lib.rs +++ b/clippy_dev/src/lib.rs @@ -17,7 +17,6 @@ pub mod fmt; pub mod new_lint; pub mod serve; pub mod setup; -pub mod stderr_length_check; pub mod update_lints; static DEC_CLIPPY_LINT_RE: SyncLazy = SyncLazy::new(|| { diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index ff324ff6ee6..8fdeba9842a 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -3,7 +3,7 @@ #![warn(rust_2018_idioms, unused_lifetimes)] use clap::{App, AppSettings, Arg, ArgMatches, SubCommand}; -use clippy_dev::{bless, fmt, new_lint, serve, setup, stderr_length_check, update_lints}; +use clippy_dev::{bless, fmt, new_lint, serve, setup, update_lints}; fn main() { let matches = get_clap_config(); @@ -33,9 +33,6 @@ fn main() { Err(e) => eprintln!("Unable to create lint: {}", e), } }, - ("limit_stderr_length", _) => { - stderr_length_check::check(); - }, ("setup", Some(sub_command)) => match sub_command.subcommand() { ("intellij", Some(matches)) => setup::intellij::setup_rustc_src( matches @@ -152,10 +149,6 @@ fn get_clap_config<'a>() -> ArgMatches<'a> { .takes_value(true), ), ) - .subcommand( - SubCommand::with_name("limit_stderr_length") - .about("Ensures that stderr files do not grow longer than a certain amount of lines."), - ) .subcommand( SubCommand::with_name("setup") .about("Support for setting up your personal development environment") diff --git a/clippy_dev/src/stderr_length_check.rs b/clippy_dev/src/stderr_length_check.rs deleted file mode 100644 index e02b6f7da5f..00000000000 --- a/clippy_dev/src/stderr_length_check.rs +++ /dev/null @@ -1,51 +0,0 @@ -use crate::clippy_project_root; -use std::ffi::OsStr; -use std::fs; -use std::path::{Path, PathBuf}; -use walkdir::WalkDir; - -// The maximum length allowed for stderr files. -// -// We limit this because small files are easier to deal with than bigger files. -const LENGTH_LIMIT: usize = 200; - -pub fn check() { - let exceeding_files: Vec<_> = exceeding_stderr_files(); - - if !exceeding_files.is_empty() { - eprintln!("Error: stderr files exceeding limit of {} lines:", LENGTH_LIMIT); - for (path, count) in exceeding_files { - println!("{}: {}", path.display(), count); - } - std::process::exit(1); - } -} - -fn exceeding_stderr_files() -> Vec<(PathBuf, usize)> { - // We use `WalkDir` instead of `fs::read_dir` here in order to recurse into subdirectories. - WalkDir::new(clippy_project_root().join("tests/ui")) - .into_iter() - .filter_map(Result::ok) - .filter(|f| !f.file_type().is_dir()) - .filter_map(|e| { - let p = e.into_path(); - let count = count_linenumbers(&p); - if p.extension() == Some(OsStr::new("stderr")) && count > LENGTH_LIMIT { - Some((p, count)) - } else { - None - } - }) - .collect() -} - -#[must_use] -fn count_linenumbers(filepath: &Path) -> usize { - match fs::read(filepath) { - Ok(content) => bytecount::count(&content, b'\n'), - Err(e) => { - eprintln!("Failed to read file: {}", e); - 0 - }, - } -} -- cgit 1.4.1-3-g733a5 From e3b171dcf099fbb7e7d3bd2cb28b11f7d3fb2773 Mon Sep 17 00:00:00 2001 From: Cameron Steffen Date: Wed, 8 Sep 2021 10:55:08 -0500 Subject: Use relative exe paths --- clippy_dev/src/bless.rs | 13 ++----------- tests/cargo/mod.rs | 13 ------------- tests/compile-test.rs | 11 ++++++----- tests/dogfood.rs | 7 ++++++- 4 files changed, 14 insertions(+), 30 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/bless.rs b/clippy_dev/src/bless.rs index c4fa0a9aca7..19153aa74d0 100644 --- a/clippy_dev/src/bless.rs +++ b/clippy_dev/src/bless.rs @@ -1,7 +1,6 @@ //! `bless` updates the reference files in the repo with changed output files //! from the last test run. -use std::env; use std::ffi::OsStr; use std::fs; use std::lazy::SyncLazy; @@ -10,17 +9,9 @@ use walkdir::WalkDir; use crate::clippy_project_root; -// NOTE: this is duplicated with tests/cargo/mod.rs What to do? -pub static CARGO_TARGET_DIR: SyncLazy = SyncLazy::new(|| match env::var_os("CARGO_TARGET_DIR") { - Some(v) => v.into(), - None => env::current_dir().unwrap().join("target"), -}); - static CLIPPY_BUILD_TIME: SyncLazy> = SyncLazy::new(|| { - let profile = env::var("PROFILE").unwrap_or_else(|_| "debug".to_string()); - let mut path = PathBuf::from(&**CARGO_TARGET_DIR); - path.push(profile); - path.push("cargo-clippy"); + let mut path = std::env::current_exe().unwrap(); + path.set_file_name("cargo-clippy"); fs::metadata(path).ok()?.modified().ok() }); diff --git a/tests/cargo/mod.rs b/tests/cargo/mod.rs index a8f3e3145f6..1f3ce557eb4 100644 --- a/tests/cargo/mod.rs +++ b/tests/cargo/mod.rs @@ -7,19 +7,6 @@ pub static CARGO_TARGET_DIR: SyncLazy = SyncLazy::new(|| match env::var None => env::current_dir().unwrap().join("target"), }); -pub static TARGET_LIB: SyncLazy = SyncLazy::new(|| { - if let Some(path) = option_env!("TARGET_LIBS") { - path.into() - } else { - let mut dir = CARGO_TARGET_DIR.clone(); - if let Some(target) = env::var_os("CARGO_BUILD_TARGET") { - dir.push(target); - } - dir.push(env!("PROFILE")); - dir - } -}); - #[must_use] pub fn is_rustc_test_suite() -> bool { option_env!("RUSTC_TEST_SUITE").is_some() diff --git a/tests/compile-test.rs b/tests/compile-test.rs index 27a1627622b..2641fb81234 100644 --- a/tests/compile-test.rs +++ b/tests/compile-test.rs @@ -50,10 +50,6 @@ fn host_lib() -> PathBuf { option_env!("HOST_LIBS").map_or(cargo::CARGO_TARGET_DIR.join(env!("PROFILE")), PathBuf::from) } -fn clippy_driver_path() -> PathBuf { - option_env!("CLIPPY_DRIVER_PATH").map_or(cargo::TARGET_LIB.join("clippy-driver"), PathBuf::from) -} - /// Produces a string with an `--extern` flag for all UI test crate /// dependencies. /// @@ -122,6 +118,7 @@ fn default_config() -> compiletest::Config { } let current_exe_path = std::env::current_exe().unwrap(); let deps_path = current_exe_path.parent().unwrap(); + let profile_path = deps_path.parent().unwrap(); // Using `-L dependency={}` enforces that external dependencies are added with `--extern`. // This is valuable because a) it allows us to monitor what external dependencies are used @@ -137,7 +134,11 @@ fn default_config() -> compiletest::Config { )); config.build_base = host_lib().join("test_build_base"); - config.rustc_path = clippy_driver_path(); + config.rustc_path = profile_path.join(if cfg!(windows) { + "clippy-driver.exe" + } else { + "clippy-driver" + }); config } diff --git a/tests/dogfood.rs b/tests/dogfood.rs index 54f452172de..4190dfcfe6d 100644 --- a/tests/dogfood.rs +++ b/tests/dogfood.rs @@ -15,7 +15,12 @@ use std::process::Command; mod cargo; -static CLIPPY_PATH: SyncLazy = SyncLazy::new(|| cargo::TARGET_LIB.join("cargo-clippy")); +static CLIPPY_PATH: SyncLazy = SyncLazy::new(|| { + let mut path = std::env::current_exe().unwrap(); + assert!(path.pop()); // deps + path.set_file_name("cargo-clippy"); + path +}); #[test] fn dogfood_clippy() { -- cgit 1.4.1-3-g733a5 From ecaf7acd4f9074e255cafaac9aa4b1c601dc311a Mon Sep 17 00:00:00 2001 From: Cameron Steffen Date: Wed, 8 Sep 2021 10:58:18 -0500 Subject: Use relative path for test builds --- clippy_dev/src/bless.rs | 7 ++----- tests/cargo/mod.rs | 9 --------- tests/compile-test.rs | 7 +------ 3 files changed, 3 insertions(+), 20 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/bless.rs b/clippy_dev/src/bless.rs index 19153aa74d0..3d97fa8a892 100644 --- a/clippy_dev/src/bless.rs +++ b/clippy_dev/src/bless.rs @@ -85,10 +85,7 @@ fn updated_since_clippy_build(path: &Path) -> Option { } fn build_dir() -> PathBuf { - let profile = env::var("PROFILE").unwrap_or_else(|_| "debug".to_string()); - let mut path = PathBuf::new(); - path.push(CARGO_TARGET_DIR.clone()); - path.push(profile); - path.push("test_build_base"); + let mut path = std::env::current_exe().unwrap(); + path.set_file_name("test_build_base"); path } diff --git a/tests/cargo/mod.rs b/tests/cargo/mod.rs index 1f3ce557eb4..4dbe71e4b6a 100644 --- a/tests/cargo/mod.rs +++ b/tests/cargo/mod.rs @@ -1,12 +1,3 @@ -use std::env; -use std::lazy::SyncLazy; -use std::path::PathBuf; - -pub static CARGO_TARGET_DIR: SyncLazy = SyncLazy::new(|| match env::var_os("CARGO_TARGET_DIR") { - Some(v) => v.into(), - None => env::current_dir().unwrap().join("target"), -}); - #[must_use] pub fn is_rustc_test_suite() -> bool { option_env!("RUSTC_TEST_SUITE").is_some() diff --git a/tests/compile-test.rs b/tests/compile-test.rs index 2641fb81234..d113c4d3437 100644 --- a/tests/compile-test.rs +++ b/tests/compile-test.rs @@ -1,5 +1,4 @@ #![feature(test)] // compiletest_rs requires this attribute -#![feature(once_cell)] #![cfg_attr(feature = "deny-warnings", deny(warnings))] #![warn(rust_2018_idioms, unused_lifetimes)] @@ -46,10 +45,6 @@ extern crate quote; #[allow(unused_extern_crates)] extern crate syn; -fn host_lib() -> PathBuf { - option_env!("HOST_LIBS").map_or(cargo::CARGO_TARGET_DIR.join(env!("PROFILE")), PathBuf::from) -} - /// Produces a string with an `--extern` flag for all UI test crate /// dependencies. /// @@ -133,7 +128,7 @@ fn default_config() -> compiletest::Config { extern_flags(), )); - config.build_base = host_lib().join("test_build_base"); + config.build_base = profile_path.join("test_build_base"); config.rustc_path = profile_path.join(if cfg!(windows) { "clippy-driver.exe" } else { -- cgit 1.4.1-3-g733a5 From 1074bad06d421feabd6d4c75d0cb110c677d812d Mon Sep 17 00:00:00 2001 From: Cameron Steffen Date: Wed, 8 Sep 2021 10:59:05 -0500 Subject: Rename test_build_base to test --- clippy_dev/src/bless.rs | 2 +- tests/compile-test.rs | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/bless.rs b/clippy_dev/src/bless.rs index 3d97fa8a892..daf0fcc993b 100644 --- a/clippy_dev/src/bless.rs +++ b/clippy_dev/src/bless.rs @@ -86,6 +86,6 @@ fn updated_since_clippy_build(path: &Path) -> Option { fn build_dir() -> PathBuf { let mut path = std::env::current_exe().unwrap(); - path.set_file_name("test_build_base"); + path.set_file_name("test"); path } diff --git a/tests/compile-test.rs b/tests/compile-test.rs index d113c4d3437..c9d10111595 100644 --- a/tests/compile-test.rs +++ b/tests/compile-test.rs @@ -128,7 +128,7 @@ fn default_config() -> compiletest::Config { extern_flags(), )); - config.build_base = profile_path.join("test_build_base"); + config.build_base = profile_path.join("test"); config.rustc_path = profile_path.join(if cfg!(windows) { "clippy-driver.exe" } else { -- cgit 1.4.1-3-g733a5 From 50ea37061937acf9c912e0088ce48783926562a1 Mon Sep 17 00:00:00 2001 From: Michael Wright Date: Sat, 18 Sep 2021 06:43:39 +0200 Subject: Move code generated by `update_lints` to includes --- clippy_dev/src/lib.rs | 68 +- clippy_dev/src/update_lints.rs | 116 +- clippy_lints/src/lib.deprecated.rs | 70 ++ clippy_lints/src/lib.mods.rs | 232 ++++ clippy_lints/src/lib.register_all.rs | 304 +++++ clippy_lints/src/lib.register_cargo.rs | 11 + clippy_lints/src/lib.register_complexity.rs | 94 ++ clippy_lints/src/lib.register_correctness.rs | 73 ++ clippy_lints/src/lib.register_internal.rs | 18 + clippy_lints/src/lib.register_lints.rs | 508 ++++++++ clippy_lints/src/lib.register_nursery.rs | 28 + clippy_lints/src/lib.register_pedantic.rs | 101 ++ clippy_lints/src/lib.register_perf.rs | 27 + clippy_lints/src/lib.register_restriction.rs | 64 + clippy_lints/src/lib.register_style.rs | 114 ++ clippy_lints/src/lib.register_suspicious.rs | 20 + clippy_lints/src/lib.rs | 1637 +------------------------- 17 files changed, 1779 insertions(+), 1706 deletions(-) create mode 100644 clippy_lints/src/lib.deprecated.rs create mode 100644 clippy_lints/src/lib.mods.rs create mode 100644 clippy_lints/src/lib.register_all.rs create mode 100644 clippy_lints/src/lib.register_cargo.rs create mode 100644 clippy_lints/src/lib.register_complexity.rs create mode 100644 clippy_lints/src/lib.register_correctness.rs create mode 100644 clippy_lints/src/lib.register_internal.rs create mode 100644 clippy_lints/src/lib.register_lints.rs create mode 100644 clippy_lints/src/lib.register_nursery.rs create mode 100644 clippy_lints/src/lib.register_pedantic.rs create mode 100644 clippy_lints/src/lib.register_perf.rs create mode 100644 clippy_lints/src/lib.register_restriction.rs create mode 100644 clippy_lints/src/lib.register_style.rs create mode 100644 clippy_lints/src/lib.register_suspicious.rs (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lib.rs b/clippy_dev/src/lib.rs index e05db7af586..8f0356c028b 100644 --- a/clippy_dev/src/lib.rs +++ b/clippy_dev/src/lib.rs @@ -100,11 +100,24 @@ impl Lint { /// Generates the Vec items for `register_lint_group` calls in `clippy_lints/src/lib.rs`. #[must_use] -pub fn gen_lint_group_list<'a>(lints: impl Iterator) -> Vec { - lints - .map(|l| format!(" LintId::of({}::{}),", l.module, l.name.to_uppercase())) - .sorted() - .collect::>() +pub fn gen_lint_group_list<'a>(group_name: &str, lints: impl Iterator) -> Vec { + let header = format!( + r#"store.register_group(true, "clippy::{0}", Some("clippy_{0}"), vec!["#, + group_name + ); + let footer = "])".to_string(); + + let mut result = vec![header]; + + result.extend( + lints + .map(|l| format!("LintId::of({}::{}),", l.module, l.name.to_uppercase())) + .sorted(), + ); + + result.push(footer); + + result } /// Generates the `pub mod module_name` list in `clippy_lints/src/lib.rs`. @@ -130,21 +143,22 @@ pub fn gen_changelog_lint_list<'a>(lints: impl Iterator) -> Vec /// Generates the `register_removed` code in `./clippy_lints/src/lib.rs`. #[must_use] pub fn gen_deprecated<'a>(lints: impl Iterator) -> Vec { - lints - .flat_map(|l| { - l.deprecation - .clone() - .map(|depr_text| { - vec![ - " store.register_removed(".to_string(), - format!(" \"clippy::{}\",", l.name), - format!(" \"{}\",", depr_text), - " );".to_string(), - ] - }) - .expect("only deprecated lints should be passed") - }) - .collect::>() + let mut result = vec!["{".to_string()]; + result.extend(lints.flat_map(|l| { + l.deprecation + .clone() + .map(|depr_text| { + vec![ + " store.register_removed(".to_string(), + format!(" \"clippy::{}\",", l.name), + format!(" \"{}\",", depr_text), + " );".to_string(), + ] + }) + .expect("only deprecated lints should be passed") + })); + result.push("}".to_string()); + result } #[must_use] @@ -153,7 +167,7 @@ pub fn gen_register_lint_list<'a>( usable_lints: impl Iterator, ) -> Vec { let header = " store.register_lints(&[".to_string(); - let footer = " ]);".to_string(); + let footer = " ])".to_string(); let internal_lints = internal_lints .sorted_by_key(|l| format!(" {}::{},", l.module, l.name.to_uppercase())) .map(|l| { @@ -511,6 +525,7 @@ fn test_gen_deprecated() { ), ]; let expected: Vec = vec![ + "{", " store.register_removed(", " \"clippy::should_assert_eq\",", " \"has been superseded by should_assert_eq2\",", @@ -519,6 +534,7 @@ fn test_gen_deprecated() { " \"clippy::another_deprecated\",", " \"will be removed\",", " );", + "}", ] .into_iter() .map(String::from) @@ -551,9 +567,11 @@ fn test_gen_lint_group_list() { Lint::new("internal", "internal_style", "abc", None, "module_name"), ]; let expected = vec![ - " LintId::of(module_name::ABC),".to_string(), - " LintId::of(module_name::INTERNAL),".to_string(), - " LintId::of(module_name::SHOULD_ASSERT_EQ),".to_string(), + "store.register_group(true, \"clippy::group1\", Some(\"clippy_group1\"), vec![", + "LintId::of(module_name::ABC),", + "LintId::of(module_name::INTERNAL),", + "LintId::of(module_name::SHOULD_ASSERT_EQ),", + "])", ]; - assert_eq!(expected, gen_lint_group_list(lints.iter())); + assert_eq!(expected, gen_lint_group_list("group1", lints.iter())); } diff --git a/clippy_dev/src/update_lints.rs b/clippy_dev/src/update_lints.rs index db467c26f15..ba550d492fc 100644 --- a/clippy_dev/src/update_lints.rs +++ b/clippy_dev/src/update_lints.rs @@ -2,6 +2,7 @@ use crate::{ gather_all, gen_changelog_lint_list, gen_deprecated, gen_lint_group_list, gen_modules_list, gen_register_lint_list, replace_region_in_file, Lint, DOCS_LINK, }; +use std::fs; use std::path::Path; #[derive(Clone, Copy, PartialEq)] @@ -10,6 +11,15 @@ pub enum UpdateMode { Change, } +/// Runs the `update_lints` command. +/// +/// This updates various generated values from the lint source code. +/// +/// `update_mode` indicates if the files should be updated or if updates should be checked for. +/// +/// # Panics +/// +/// Panics if a file path could not read from or then written to #[allow(clippy::too_many_lines)] pub fn run(update_mode: UpdateMode) { let lint_list: Vec = gather_all().collect(); @@ -52,45 +62,18 @@ pub fn run(update_mode: UpdateMode) { ) .changed; - file_change |= replace_region_in_file( - Path::new("clippy_lints/src/lib.rs"), - "begin deprecated lints", - "end deprecated lints", - false, - update_mode == UpdateMode::Change, - || gen_deprecated(deprecated_lints.iter()), - ) - .changed; - - file_change |= replace_region_in_file( - Path::new("clippy_lints/src/lib.rs"), - "begin register lints", - "end register lints", - false, - update_mode == UpdateMode::Change, - || gen_register_lint_list(internal_lints.iter(), usable_lints.iter()), - ) - .changed; - - file_change |= replace_region_in_file( - Path::new("clippy_lints/src/lib.rs"), - "begin lints modules", - "end lints modules", - false, - update_mode == UpdateMode::Change, - || gen_modules_list(usable_lints.iter()), - ) - .changed; + if file_change && update_mode == UpdateMode::Check { + exit_with_failure(); + } - // Generate lists of lints in the clippy::all lint group - file_change |= replace_region_in_file( - Path::new("clippy_lints/src/lib.rs"), - r#"store.register_group\(true, "clippy::all""#, - r#"\]\);"#, - false, - update_mode == UpdateMode::Change, - || { - // clippy::all should only include the following lint groups: + for (name, lines) in [ + ("mods", gen_modules_list(usable_lints.iter())), + ("deprecated", gen_deprecated(deprecated_lints.iter())), + ( + "register_lints", + gen_register_lint_list(internal_lints.iter(), usable_lints.iter()), + ), + ("register_all", { let all_group_lints = usable_lints.iter().filter(|l| { matches!( &*l.group, @@ -98,30 +81,18 @@ pub fn run(update_mode: UpdateMode) { ) }); - gen_lint_group_list(all_group_lints) - }, - ) - .changed; - - // Generate the list of lints for all other lint groups - for (lint_group, lints) in Lint::by_lint_group(usable_lints.into_iter().chain(internal_lints)) { - file_change |= replace_region_in_file( - Path::new("clippy_lints/src/lib.rs"), - &format!("store.register_group\\(true, \"clippy::{}\"", lint_group), - r#"\]\);"#, - false, - update_mode == UpdateMode::Change, - || gen_lint_group_list(lints.iter()), - ) - .changed; + gen_lint_group_list("all", all_group_lints) + }), + ] { + process_file(&format!("clippy_lints/src/lib.{}.rs", name), update_mode, &lines[..]); } - if update_mode == UpdateMode::Check && file_change { - println!( - "Not all lints defined properly. \ - Please run `cargo dev update_lints` to make sure all lints are defined properly." + for (lint_group, lints) in Lint::by_lint_group(usable_lints.into_iter().chain(internal_lints)) { + process_file( + &format!("clippy_lints/src/lib.register_{}.rs", lint_group), + update_mode, + &gen_lint_group_list(&lints.get(0).expect("group non-empty").group, lints.iter())[..], ); - std::process::exit(1); } } @@ -150,3 +121,30 @@ pub fn print_lints() { fn round_to_fifty(count: usize) -> usize { count / 50 * 50 } + +fn process_file(path: impl AsRef, update_mode: UpdateMode, new_lines: &[String]) { + let mut new_content = "// This file was generated by `cargo dev update_lints`.\n\ + // Use that command to update this file and do not edit by hand.\n\ + // Manual edits will be overwritten.\n\n" + .to_string(); + new_content.push_str(&new_lines.join("\n")); + + if update_mode == UpdateMode::Check { + let old_content = + fs::read_to_string(&path).unwrap_or_else(|e| panic!("Cannot read from {}: {}", path.as_ref().display(), e)); + if new_content != old_content { + exit_with_failure(); + } + } else { + fs::write(&path, new_content.as_bytes()) + .unwrap_or_else(|e| panic!("Cannot write to {}: {}", path.as_ref().display(), e)); + } +} + +fn exit_with_failure() { + println!( + "Not all lints defined properly. \ + Please run `cargo dev update_lints` to make sure all lints are defined properly." + ); + std::process::exit(1); +} diff --git a/clippy_lints/src/lib.deprecated.rs b/clippy_lints/src/lib.deprecated.rs new file mode 100644 index 00000000000..f5134a0a80a --- /dev/null +++ b/clippy_lints/src/lib.deprecated.rs @@ -0,0 +1,70 @@ +// This file was generated by `cargo dev update_lints`. +// Use that command to update this file and do not edit by hand. +// Manual edits will be overwritten. + +{ + store.register_removed( + "clippy::should_assert_eq", + "`assert!()` will be more flexible with RFC 2011", + ); + store.register_removed( + "clippy::extend_from_slice", + "`.extend_from_slice(_)` is a faster way to extend a Vec by a slice", + ); + store.register_removed( + "clippy::range_step_by_zero", + "`iterator.step_by(0)` panics nowadays", + ); + store.register_removed( + "clippy::unstable_as_slice", + "`Vec::as_slice` has been stabilized in 1.7", + ); + store.register_removed( + "clippy::unstable_as_mut_slice", + "`Vec::as_mut_slice` has been stabilized in 1.7", + ); + store.register_removed( + "clippy::misaligned_transmute", + "this lint has been split into cast_ptr_alignment and transmute_ptr_to_ptr", + ); + store.register_removed( + "clippy::assign_ops", + "using compound assignment operators (e.g., `+=`) is harmless", + ); + store.register_removed( + "clippy::if_let_redundant_pattern_matching", + "this lint has been changed to redundant_pattern_matching", + ); + store.register_removed( + "clippy::unsafe_vector_initialization", + "the replacement suggested by this lint had substantially different behavior", + ); + store.register_removed( + "clippy::unused_collect", + "`collect` has been marked as #[must_use] in rustc and that covers all cases of this lint", + ); + store.register_removed( + "clippy::replace_consts", + "associated-constants `MIN`/`MAX` of integers are preferred to `{min,max}_value()` and module constants", + ); + store.register_removed( + "clippy::regex_macro", + "the regex! macro has been removed from the regex crate in 2018", + ); + store.register_removed( + "clippy::find_map", + "this lint has been replaced by `manual_find_map`, a more specific lint", + ); + store.register_removed( + "clippy::filter_map", + "this lint has been replaced by `manual_filter_map`, a more specific lint", + ); + store.register_removed( + "clippy::pub_enum_variant_names", + "set the `avoid-breaking-exported-api` config option to `false` to enable the `enum_variant_names` lint for public items", + ); + store.register_removed( + "clippy::wrong_pub_self_convention", + "set the `avoid-breaking-exported-api` config option to `false` to enable the `wrong_self_convention` lint for public items", + ); +} \ No newline at end of file diff --git a/clippy_lints/src/lib.mods.rs b/clippy_lints/src/lib.mods.rs new file mode 100644 index 00000000000..49f445c3531 --- /dev/null +++ b/clippy_lints/src/lib.mods.rs @@ -0,0 +1,232 @@ +// This file was generated by `cargo dev update_lints`. +// Use that command to update this file and do not edit by hand. +// Manual edits will be overwritten. + +mod absurd_extreme_comparisons; +mod approx_const; +mod arithmetic; +mod as_conversions; +mod asm_syntax; +mod assertions_on_constants; +mod assign_ops; +mod async_yields_async; +mod attrs; +mod await_holding_invalid; +mod bit_mask; +mod blacklisted_name; +mod blocks_in_if_conditions; +mod bool_assert_comparison; +mod booleans; +mod bytecount; +mod cargo_common_metadata; +mod case_sensitive_file_extension_comparisons; +mod casts; +mod checked_conversions; +mod cognitive_complexity; +mod collapsible_if; +mod collapsible_match; +mod comparison_chain; +mod copies; +mod copy_iterator; +mod create_dir; +mod dbg_macro; +mod default; +mod default_numeric_fallback; +mod dereference; +mod derivable_impls; +mod derive; +mod disallowed_method; +mod disallowed_script_idents; +mod disallowed_type; +mod doc; +mod double_comparison; +mod double_parens; +mod drop_forget_ref; +mod duration_subsec; +mod else_if_without_else; +mod empty_enum; +mod entry; +mod enum_clike; +mod enum_variants; +mod eq_op; +mod erasing_op; +mod escape; +mod eta_reduction; +mod eval_order_dependence; +mod excessive_bools; +mod exhaustive_items; +mod exit; +mod explicit_write; +mod fallible_impl_from; +mod feature_name; +mod float_equality_without_abs; +mod float_literal; +mod floating_point_arithmetic; +mod format; +mod formatting; +mod from_over_into; +mod from_str_radix_10; +mod functions; +mod future_not_send; +mod get_last_with_len; +mod identity_op; +mod if_let_mutex; +mod if_not_else; +mod if_then_panic; +mod if_then_some_else_none; +mod implicit_hasher; +mod implicit_return; +mod implicit_saturating_sub; +mod inconsistent_struct_constructor; +mod indexing_slicing; +mod infinite_iter; +mod inherent_impl; +mod inherent_to_string; +mod inline_fn_without_body; +mod int_plus_one; +mod integer_division; +mod invalid_upcast_comparisons; +mod items_after_statements; +mod iter_not_returning_iterator; +mod large_const_arrays; +mod large_enum_variant; +mod large_stack_arrays; +mod len_zero; +mod let_if_seq; +mod let_underscore; +mod lifetimes; +mod literal_representation; +mod loops; +mod macro_use; +mod main_recursion; +mod manual_async_fn; +mod manual_map; +mod manual_non_exhaustive; +mod manual_ok_or; +mod manual_strip; +mod manual_unwrap_or; +mod map_clone; +mod map_err_ignore; +mod map_unit_fn; +mod match_on_vec_items; +mod match_result_ok; +mod matches; +mod mem_discriminant; +mod mem_forget; +mod mem_replace; +mod methods; +mod minmax; +mod misc; +mod misc_early; +mod missing_const_for_fn; +mod missing_doc; +mod missing_enforced_import_rename; +mod missing_inline; +mod module_style; +mod modulo_arithmetic; +mod multiple_crate_versions; +mod mut_key; +mod mut_mut; +mod mut_mutex_lock; +mod mut_reference; +mod mutable_debug_assertion; +mod mutex_atomic; +mod needless_arbitrary_self_type; +mod needless_bitwise_bool; +mod needless_bool; +mod needless_borrow; +mod needless_borrowed_ref; +mod needless_continue; +mod needless_for_each; +mod needless_option_as_deref; +mod needless_pass_by_value; +mod needless_question_mark; +mod needless_update; +mod neg_cmp_op_on_partial_ord; +mod neg_multiply; +mod new_without_default; +mod no_effect; +mod non_copy_const; +mod non_expressive_names; +mod non_octal_unix_permissions; +mod nonstandard_macro_braces; +mod open_options; +mod option_env_unwrap; +mod option_if_let_else; +mod overflow_check_conditional; +mod panic_in_result_fn; +mod panic_unimplemented; +mod partialeq_ne_impl; +mod pass_by_ref_or_value; +mod path_buf_push_overwrite; +mod pattern_type_mismatch; +mod precedence; +mod ptr; +mod ptr_eq; +mod ptr_offset_with_cast; +mod question_mark; +mod ranges; +mod redundant_clone; +mod redundant_closure_call; +mod redundant_else; +mod redundant_field_names; +mod redundant_pub_crate; +mod redundant_slicing; +mod redundant_static_lifetimes; +mod ref_option_ref; +mod reference; +mod regex; +mod repeat_once; +mod returns; +mod same_name_method; +mod self_assignment; +mod self_named_constructors; +mod semicolon_if_nothing_returned; +mod serde_api; +mod shadow; +mod single_component_path_imports; +mod size_of_in_element_count; +mod slow_vector_initialization; +mod stable_sort_primitive; +mod strings; +mod strlen_on_c_strings; +mod suspicious_operation_groupings; +mod suspicious_trait_impl; +mod swap; +mod tabs_in_doc_comments; +mod temporary_assignment; +mod to_digit_is_some; +mod to_string_in_display; +mod trait_bounds; +mod transmute; +mod transmuting_null; +mod try_err; +mod types; +mod undropped_manually_drops; +mod unicode; +mod unit_return_expecting_ord; +mod unit_types; +mod unnamed_address; +mod unnecessary_self_imports; +mod unnecessary_sort_by; +mod unnecessary_wraps; +mod unnested_or_patterns; +mod unsafe_removed_from_name; +mod unused_async; +mod unused_io_amount; +mod unused_self; +mod unused_unit; +mod unwrap; +mod unwrap_in_result; +mod upper_case_acronyms; +mod use_self; +mod useless_conversion; +mod vec; +mod vec_init_then_push; +mod vec_resize_to_zero; +mod verbose_file_reads; +mod wildcard_dependencies; +mod wildcard_imports; +mod write; +mod zero_div_zero; +mod zero_sized_map_values; \ No newline at end of file diff --git a/clippy_lints/src/lib.register_all.rs b/clippy_lints/src/lib.register_all.rs new file mode 100644 index 00000000000..7a77303b834 --- /dev/null +++ b/clippy_lints/src/lib.register_all.rs @@ -0,0 +1,304 @@ +// This file was generated by `cargo dev update_lints`. +// Use that command to update this file and do not edit by hand. +// Manual edits will be overwritten. + +store.register_group(true, "clippy::all", Some("clippy_all"), vec![ +LintId::of(absurd_extreme_comparisons::ABSURD_EXTREME_COMPARISONS), +LintId::of(approx_const::APPROX_CONSTANT), +LintId::of(assertions_on_constants::ASSERTIONS_ON_CONSTANTS), +LintId::of(assign_ops::ASSIGN_OP_PATTERN), +LintId::of(assign_ops::MISREFACTORED_ASSIGN_OP), +LintId::of(async_yields_async::ASYNC_YIELDS_ASYNC), +LintId::of(attrs::BLANKET_CLIPPY_RESTRICTION_LINTS), +LintId::of(attrs::DEPRECATED_CFG_ATTR), +LintId::of(attrs::DEPRECATED_SEMVER), +LintId::of(attrs::MISMATCHED_TARGET_OS), +LintId::of(attrs::USELESS_ATTRIBUTE), +LintId::of(bit_mask::BAD_BIT_MASK), +LintId::of(bit_mask::INEFFECTIVE_BIT_MASK), +LintId::of(blacklisted_name::BLACKLISTED_NAME), +LintId::of(blocks_in_if_conditions::BLOCKS_IN_IF_CONDITIONS), +LintId::of(bool_assert_comparison::BOOL_ASSERT_COMPARISON), +LintId::of(booleans::LOGIC_BUG), +LintId::of(booleans::NONMINIMAL_BOOL), +LintId::of(casts::CAST_REF_TO_MUT), +LintId::of(casts::CHAR_LIT_AS_U8), +LintId::of(casts::FN_TO_NUMERIC_CAST), +LintId::of(casts::FN_TO_NUMERIC_CAST_WITH_TRUNCATION), +LintId::of(casts::UNNECESSARY_CAST), +LintId::of(collapsible_if::COLLAPSIBLE_ELSE_IF), +LintId::of(collapsible_if::COLLAPSIBLE_IF), +LintId::of(collapsible_match::COLLAPSIBLE_MATCH), +LintId::of(comparison_chain::COMPARISON_CHAIN), +LintId::of(copies::IFS_SAME_COND), +LintId::of(copies::IF_SAME_THEN_ELSE), +LintId::of(default::FIELD_REASSIGN_WITH_DEFAULT), +LintId::of(derivable_impls::DERIVABLE_IMPLS), +LintId::of(derive::DERIVE_HASH_XOR_EQ), +LintId::of(derive::DERIVE_ORD_XOR_PARTIAL_ORD), +LintId::of(doc::MISSING_SAFETY_DOC), +LintId::of(doc::NEEDLESS_DOCTEST_MAIN), +LintId::of(double_comparison::DOUBLE_COMPARISONS), +LintId::of(double_parens::DOUBLE_PARENS), +LintId::of(drop_forget_ref::DROP_COPY), +LintId::of(drop_forget_ref::DROP_REF), +LintId::of(drop_forget_ref::FORGET_COPY), +LintId::of(drop_forget_ref::FORGET_REF), +LintId::of(duration_subsec::DURATION_SUBSEC), +LintId::of(entry::MAP_ENTRY), +LintId::of(enum_clike::ENUM_CLIKE_UNPORTABLE_VARIANT), +LintId::of(enum_variants::ENUM_VARIANT_NAMES), +LintId::of(enum_variants::MODULE_INCEPTION), +LintId::of(eq_op::EQ_OP), +LintId::of(eq_op::OP_REF), +LintId::of(erasing_op::ERASING_OP), +LintId::of(escape::BOXED_LOCAL), +LintId::of(eta_reduction::REDUNDANT_CLOSURE), +LintId::of(eval_order_dependence::DIVERGING_SUB_EXPRESSION), +LintId::of(eval_order_dependence::EVAL_ORDER_DEPENDENCE), +LintId::of(explicit_write::EXPLICIT_WRITE), +LintId::of(float_equality_without_abs::FLOAT_EQUALITY_WITHOUT_ABS), +LintId::of(float_literal::EXCESSIVE_PRECISION), +LintId::of(format::USELESS_FORMAT), +LintId::of(formatting::POSSIBLE_MISSING_COMMA), +LintId::of(formatting::SUSPICIOUS_ASSIGNMENT_FORMATTING), +LintId::of(formatting::SUSPICIOUS_ELSE_FORMATTING), +LintId::of(formatting::SUSPICIOUS_UNARY_OP_FORMATTING), +LintId::of(from_over_into::FROM_OVER_INTO), +LintId::of(from_str_radix_10::FROM_STR_RADIX_10), +LintId::of(functions::DOUBLE_MUST_USE), +LintId::of(functions::MUST_USE_UNIT), +LintId::of(functions::NOT_UNSAFE_PTR_ARG_DEREF), +LintId::of(functions::RESULT_UNIT_ERR), +LintId::of(functions::TOO_MANY_ARGUMENTS), +LintId::of(get_last_with_len::GET_LAST_WITH_LEN), +LintId::of(identity_op::IDENTITY_OP), +LintId::of(if_let_mutex::IF_LET_MUTEX), +LintId::of(if_then_panic::IF_THEN_PANIC), +LintId::of(indexing_slicing::OUT_OF_BOUNDS_INDEXING), +LintId::of(infinite_iter::INFINITE_ITER), +LintId::of(inherent_to_string::INHERENT_TO_STRING), +LintId::of(inherent_to_string::INHERENT_TO_STRING_SHADOW_DISPLAY), +LintId::of(inline_fn_without_body::INLINE_FN_WITHOUT_BODY), +LintId::of(int_plus_one::INT_PLUS_ONE), +LintId::of(large_const_arrays::LARGE_CONST_ARRAYS), +LintId::of(large_enum_variant::LARGE_ENUM_VARIANT), +LintId::of(len_zero::COMPARISON_TO_EMPTY), +LintId::of(len_zero::LEN_WITHOUT_IS_EMPTY), +LintId::of(len_zero::LEN_ZERO), +LintId::of(let_underscore::LET_UNDERSCORE_LOCK), +LintId::of(lifetimes::EXTRA_UNUSED_LIFETIMES), +LintId::of(lifetimes::NEEDLESS_LIFETIMES), +LintId::of(literal_representation::INCONSISTENT_DIGIT_GROUPING), +LintId::of(literal_representation::MISTYPED_LITERAL_SUFFIXES), +LintId::of(literal_representation::UNUSUAL_BYTE_GROUPINGS), +LintId::of(loops::EMPTY_LOOP), +LintId::of(loops::EXPLICIT_COUNTER_LOOP), +LintId::of(loops::FOR_KV_MAP), +LintId::of(loops::FOR_LOOPS_OVER_FALLIBLES), +LintId::of(loops::ITER_NEXT_LOOP), +LintId::of(loops::MANUAL_FLATTEN), +LintId::of(loops::MANUAL_MEMCPY), +LintId::of(loops::MUT_RANGE_BOUND), +LintId::of(loops::NEEDLESS_COLLECT), +LintId::of(loops::NEEDLESS_RANGE_LOOP), +LintId::of(loops::NEVER_LOOP), +LintId::of(loops::SAME_ITEM_PUSH), +LintId::of(loops::SINGLE_ELEMENT_LOOP), +LintId::of(loops::WHILE_IMMUTABLE_CONDITION), +LintId::of(loops::WHILE_LET_LOOP), +LintId::of(loops::WHILE_LET_ON_ITERATOR), +LintId::of(main_recursion::MAIN_RECURSION), +LintId::of(manual_async_fn::MANUAL_ASYNC_FN), +LintId::of(manual_map::MANUAL_MAP), +LintId::of(manual_non_exhaustive::MANUAL_NON_EXHAUSTIVE), +LintId::of(manual_strip::MANUAL_STRIP), +LintId::of(manual_unwrap_or::MANUAL_UNWRAP_OR), +LintId::of(map_clone::MAP_CLONE), +LintId::of(map_unit_fn::OPTION_MAP_UNIT_FN), +LintId::of(map_unit_fn::RESULT_MAP_UNIT_FN), +LintId::of(match_result_ok::MATCH_RESULT_OK), +LintId::of(matches::INFALLIBLE_DESTRUCTURING_MATCH), +LintId::of(matches::MATCH_AS_REF), +LintId::of(matches::MATCH_LIKE_MATCHES_MACRO), +LintId::of(matches::MATCH_OVERLAPPING_ARM), +LintId::of(matches::MATCH_REF_PATS), +LintId::of(matches::MATCH_SINGLE_BINDING), +LintId::of(matches::REDUNDANT_PATTERN_MATCHING), +LintId::of(matches::SINGLE_MATCH), +LintId::of(matches::WILDCARD_IN_OR_PATTERNS), +LintId::of(mem_discriminant::MEM_DISCRIMINANT_NON_ENUM), +LintId::of(mem_replace::MEM_REPLACE_OPTION_WITH_NONE), +LintId::of(mem_replace::MEM_REPLACE_WITH_DEFAULT), +LintId::of(mem_replace::MEM_REPLACE_WITH_UNINIT), +LintId::of(methods::BIND_INSTEAD_OF_MAP), +LintId::of(methods::BYTES_NTH), +LintId::of(methods::CHARS_LAST_CMP), +LintId::of(methods::CHARS_NEXT_CMP), +LintId::of(methods::CLONE_DOUBLE_REF), +LintId::of(methods::CLONE_ON_COPY), +LintId::of(methods::EXPECT_FUN_CALL), +LintId::of(methods::EXTEND_WITH_DRAIN), +LintId::of(methods::FILTER_MAP_IDENTITY), +LintId::of(methods::FILTER_NEXT), +LintId::of(methods::FLAT_MAP_IDENTITY), +LintId::of(methods::INSPECT_FOR_EACH), +LintId::of(methods::INTO_ITER_ON_REF), +LintId::of(methods::ITERATOR_STEP_BY_ZERO), +LintId::of(methods::ITER_CLONED_COLLECT), +LintId::of(methods::ITER_COUNT), +LintId::of(methods::ITER_NEXT_SLICE), +LintId::of(methods::ITER_NTH), +LintId::of(methods::ITER_NTH_ZERO), +LintId::of(methods::ITER_SKIP_NEXT), +LintId::of(methods::MANUAL_FILTER_MAP), +LintId::of(methods::MANUAL_FIND_MAP), +LintId::of(methods::MANUAL_SATURATING_ARITHMETIC), +LintId::of(methods::MANUAL_SPLIT_ONCE), +LintId::of(methods::MANUAL_STR_REPEAT), +LintId::of(methods::MAP_COLLECT_RESULT_UNIT), +LintId::of(methods::MAP_IDENTITY), +LintId::of(methods::NEW_RET_NO_SELF), +LintId::of(methods::OK_EXPECT), +LintId::of(methods::OPTION_AS_REF_DEREF), +LintId::of(methods::OPTION_FILTER_MAP), +LintId::of(methods::OPTION_MAP_OR_NONE), +LintId::of(methods::OR_FUN_CALL), +LintId::of(methods::RESULT_MAP_OR_INTO_OPTION), +LintId::of(methods::SEARCH_IS_SOME), +LintId::of(methods::SHOULD_IMPLEMENT_TRAIT), +LintId::of(methods::SINGLE_CHAR_ADD_STR), +LintId::of(methods::SINGLE_CHAR_PATTERN), +LintId::of(methods::SKIP_WHILE_NEXT), +LintId::of(methods::STRING_EXTEND_CHARS), +LintId::of(methods::SUSPICIOUS_MAP), +LintId::of(methods::SUSPICIOUS_SPLITN), +LintId::of(methods::UNINIT_ASSUMED_INIT), +LintId::of(methods::UNNECESSARY_FILTER_MAP), +LintId::of(methods::UNNECESSARY_FOLD), +LintId::of(methods::UNNECESSARY_LAZY_EVALUATIONS), +LintId::of(methods::UNWRAP_OR_ELSE_DEFAULT), +LintId::of(methods::USELESS_ASREF), +LintId::of(methods::WRONG_SELF_CONVENTION), +LintId::of(methods::ZST_OFFSET), +LintId::of(minmax::MIN_MAX), +LintId::of(misc::CMP_NAN), +LintId::of(misc::CMP_OWNED), +LintId::of(misc::MODULO_ONE), +LintId::of(misc::SHORT_CIRCUIT_STATEMENT), +LintId::of(misc::TOPLEVEL_REF_ARG), +LintId::of(misc::ZERO_PTR), +LintId::of(misc_early::BUILTIN_TYPE_SHADOW), +LintId::of(misc_early::DOUBLE_NEG), +LintId::of(misc_early::DUPLICATE_UNDERSCORE_ARGUMENT), +LintId::of(misc_early::MIXED_CASE_HEX_LITERALS), +LintId::of(misc_early::REDUNDANT_PATTERN), +LintId::of(misc_early::UNNEEDED_WILDCARD_PATTERN), +LintId::of(misc_early::ZERO_PREFIXED_LITERAL), +LintId::of(mut_key::MUTABLE_KEY_TYPE), +LintId::of(mut_mutex_lock::MUT_MUTEX_LOCK), +LintId::of(mut_reference::UNNECESSARY_MUT_PASSED), +LintId::of(mutex_atomic::MUTEX_ATOMIC), +LintId::of(needless_arbitrary_self_type::NEEDLESS_ARBITRARY_SELF_TYPE), +LintId::of(needless_bool::BOOL_COMPARISON), +LintId::of(needless_bool::NEEDLESS_BOOL), +LintId::of(needless_borrow::NEEDLESS_BORROW), +LintId::of(needless_borrowed_ref::NEEDLESS_BORROWED_REFERENCE), +LintId::of(needless_option_as_deref::NEEDLESS_OPTION_AS_DEREF), +LintId::of(needless_question_mark::NEEDLESS_QUESTION_MARK), +LintId::of(needless_update::NEEDLESS_UPDATE), +LintId::of(neg_cmp_op_on_partial_ord::NEG_CMP_OP_ON_PARTIAL_ORD), +LintId::of(neg_multiply::NEG_MULTIPLY), +LintId::of(new_without_default::NEW_WITHOUT_DEFAULT), +LintId::of(no_effect::NO_EFFECT), +LintId::of(no_effect::UNNECESSARY_OPERATION), +LintId::of(non_copy_const::BORROW_INTERIOR_MUTABLE_CONST), +LintId::of(non_copy_const::DECLARE_INTERIOR_MUTABLE_CONST), +LintId::of(non_expressive_names::JUST_UNDERSCORES_AND_DIGITS), +LintId::of(non_octal_unix_permissions::NON_OCTAL_UNIX_PERMISSIONS), +LintId::of(open_options::NONSENSICAL_OPEN_OPTIONS), +LintId::of(option_env_unwrap::OPTION_ENV_UNWRAP), +LintId::of(overflow_check_conditional::OVERFLOW_CHECK_CONDITIONAL), +LintId::of(partialeq_ne_impl::PARTIALEQ_NE_IMPL), +LintId::of(precedence::PRECEDENCE), +LintId::of(ptr::CMP_NULL), +LintId::of(ptr::INVALID_NULL_PTR_USAGE), +LintId::of(ptr::MUT_FROM_REF), +LintId::of(ptr::PTR_ARG), +LintId::of(ptr_eq::PTR_EQ), +LintId::of(ptr_offset_with_cast::PTR_OFFSET_WITH_CAST), +LintId::of(question_mark::QUESTION_MARK), +LintId::of(ranges::MANUAL_RANGE_CONTAINS), +LintId::of(ranges::RANGE_ZIP_WITH_LEN), +LintId::of(ranges::REVERSED_EMPTY_RANGES), +LintId::of(redundant_clone::REDUNDANT_CLONE), +LintId::of(redundant_closure_call::REDUNDANT_CLOSURE_CALL), +LintId::of(redundant_field_names::REDUNDANT_FIELD_NAMES), +LintId::of(redundant_slicing::REDUNDANT_SLICING), +LintId::of(redundant_static_lifetimes::REDUNDANT_STATIC_LIFETIMES), +LintId::of(reference::DEREF_ADDROF), +LintId::of(reference::REF_IN_DEREF), +LintId::of(regex::INVALID_REGEX), +LintId::of(repeat_once::REPEAT_ONCE), +LintId::of(returns::LET_AND_RETURN), +LintId::of(returns::NEEDLESS_RETURN), +LintId::of(self_assignment::SELF_ASSIGNMENT), +LintId::of(self_named_constructors::SELF_NAMED_CONSTRUCTORS), +LintId::of(serde_api::SERDE_API_MISUSE), +LintId::of(single_component_path_imports::SINGLE_COMPONENT_PATH_IMPORTS), +LintId::of(size_of_in_element_count::SIZE_OF_IN_ELEMENT_COUNT), +LintId::of(slow_vector_initialization::SLOW_VECTOR_INITIALIZATION), +LintId::of(stable_sort_primitive::STABLE_SORT_PRIMITIVE), +LintId::of(strings::STRING_FROM_UTF8_AS_BYTES), +LintId::of(strlen_on_c_strings::STRLEN_ON_C_STRINGS), +LintId::of(suspicious_trait_impl::SUSPICIOUS_ARITHMETIC_IMPL), +LintId::of(suspicious_trait_impl::SUSPICIOUS_OP_ASSIGN_IMPL), +LintId::of(swap::ALMOST_SWAPPED), +LintId::of(swap::MANUAL_SWAP), +LintId::of(tabs_in_doc_comments::TABS_IN_DOC_COMMENTS), +LintId::of(temporary_assignment::TEMPORARY_ASSIGNMENT), +LintId::of(to_digit_is_some::TO_DIGIT_IS_SOME), +LintId::of(to_string_in_display::TO_STRING_IN_DISPLAY), +LintId::of(transmute::CROSSPOINTER_TRANSMUTE), +LintId::of(transmute::TRANSMUTES_EXPRESSIBLE_AS_PTR_CASTS), +LintId::of(transmute::TRANSMUTE_BYTES_TO_STR), +LintId::of(transmute::TRANSMUTE_FLOAT_TO_INT), +LintId::of(transmute::TRANSMUTE_INT_TO_BOOL), +LintId::of(transmute::TRANSMUTE_INT_TO_CHAR), +LintId::of(transmute::TRANSMUTE_INT_TO_FLOAT), +LintId::of(transmute::TRANSMUTE_PTR_TO_REF), +LintId::of(transmute::UNSOUND_COLLECTION_TRANSMUTE), +LintId::of(transmute::WRONG_TRANSMUTE), +LintId::of(transmuting_null::TRANSMUTING_NULL), +LintId::of(try_err::TRY_ERR), +LintId::of(types::BORROWED_BOX), +LintId::of(types::BOX_COLLECTION), +LintId::of(types::REDUNDANT_ALLOCATION), +LintId::of(types::TYPE_COMPLEXITY), +LintId::of(types::VEC_BOX), +LintId::of(undropped_manually_drops::UNDROPPED_MANUALLY_DROPS), +LintId::of(unicode::INVISIBLE_CHARACTERS), +LintId::of(unit_return_expecting_ord::UNIT_RETURN_EXPECTING_ORD), +LintId::of(unit_types::UNIT_ARG), +LintId::of(unit_types::UNIT_CMP), +LintId::of(unnamed_address::FN_ADDRESS_COMPARISONS), +LintId::of(unnamed_address::VTABLE_ADDRESS_COMPARISONS), +LintId::of(unnecessary_sort_by::UNNECESSARY_SORT_BY), +LintId::of(unsafe_removed_from_name::UNSAFE_REMOVED_FROM_NAME), +LintId::of(unused_io_amount::UNUSED_IO_AMOUNT), +LintId::of(unused_unit::UNUSED_UNIT), +LintId::of(unwrap::PANICKING_UNWRAP), +LintId::of(unwrap::UNNECESSARY_UNWRAP), +LintId::of(upper_case_acronyms::UPPER_CASE_ACRONYMS), +LintId::of(useless_conversion::USELESS_CONVERSION), +LintId::of(vec::USELESS_VEC), +LintId::of(vec_init_then_push::VEC_INIT_THEN_PUSH), +LintId::of(vec_resize_to_zero::VEC_RESIZE_TO_ZERO), +LintId::of(write::PRINTLN_EMPTY_STRING), +LintId::of(write::PRINT_LITERAL), +LintId::of(write::PRINT_WITH_NEWLINE), +LintId::of(write::WRITELN_EMPTY_STRING), +LintId::of(write::WRITE_LITERAL), +LintId::of(write::WRITE_WITH_NEWLINE), +LintId::of(zero_div_zero::ZERO_DIVIDED_BY_ZERO), +]) \ No newline at end of file diff --git a/clippy_lints/src/lib.register_cargo.rs b/clippy_lints/src/lib.register_cargo.rs new file mode 100644 index 00000000000..21d070728e4 --- /dev/null +++ b/clippy_lints/src/lib.register_cargo.rs @@ -0,0 +1,11 @@ +// This file was generated by `cargo dev update_lints`. +// Use that command to update this file and do not edit by hand. +// Manual edits will be overwritten. + +store.register_group(true, "clippy::cargo", Some("clippy_cargo"), vec![ +LintId::of(cargo_common_metadata::CARGO_COMMON_METADATA), +LintId::of(feature_name::NEGATIVE_FEATURE_NAMES), +LintId::of(feature_name::REDUNDANT_FEATURE_NAMES), +LintId::of(multiple_crate_versions::MULTIPLE_CRATE_VERSIONS), +LintId::of(wildcard_dependencies::WILDCARD_DEPENDENCIES), +]) \ No newline at end of file diff --git a/clippy_lints/src/lib.register_complexity.rs b/clippy_lints/src/lib.register_complexity.rs new file mode 100644 index 00000000000..515afe54c86 --- /dev/null +++ b/clippy_lints/src/lib.register_complexity.rs @@ -0,0 +1,94 @@ +// This file was generated by `cargo dev update_lints`. +// Use that command to update this file and do not edit by hand. +// Manual edits will be overwritten. + +store.register_group(true, "clippy::complexity", Some("clippy_complexity"), vec![ +LintId::of(attrs::DEPRECATED_CFG_ATTR), +LintId::of(booleans::NONMINIMAL_BOOL), +LintId::of(casts::CHAR_LIT_AS_U8), +LintId::of(casts::UNNECESSARY_CAST), +LintId::of(derivable_impls::DERIVABLE_IMPLS), +LintId::of(double_comparison::DOUBLE_COMPARISONS), +LintId::of(double_parens::DOUBLE_PARENS), +LintId::of(duration_subsec::DURATION_SUBSEC), +LintId::of(eval_order_dependence::DIVERGING_SUB_EXPRESSION), +LintId::of(explicit_write::EXPLICIT_WRITE), +LintId::of(format::USELESS_FORMAT), +LintId::of(functions::TOO_MANY_ARGUMENTS), +LintId::of(get_last_with_len::GET_LAST_WITH_LEN), +LintId::of(identity_op::IDENTITY_OP), +LintId::of(int_plus_one::INT_PLUS_ONE), +LintId::of(lifetimes::EXTRA_UNUSED_LIFETIMES), +LintId::of(lifetimes::NEEDLESS_LIFETIMES), +LintId::of(loops::EXPLICIT_COUNTER_LOOP), +LintId::of(loops::MANUAL_FLATTEN), +LintId::of(loops::SINGLE_ELEMENT_LOOP), +LintId::of(loops::WHILE_LET_LOOP), +LintId::of(manual_strip::MANUAL_STRIP), +LintId::of(manual_unwrap_or::MANUAL_UNWRAP_OR), +LintId::of(map_unit_fn::OPTION_MAP_UNIT_FN), +LintId::of(map_unit_fn::RESULT_MAP_UNIT_FN), +LintId::of(matches::MATCH_AS_REF), +LintId::of(matches::MATCH_SINGLE_BINDING), +LintId::of(matches::WILDCARD_IN_OR_PATTERNS), +LintId::of(methods::BIND_INSTEAD_OF_MAP), +LintId::of(methods::CLONE_ON_COPY), +LintId::of(methods::FILTER_MAP_IDENTITY), +LintId::of(methods::FILTER_NEXT), +LintId::of(methods::FLAT_MAP_IDENTITY), +LintId::of(methods::INSPECT_FOR_EACH), +LintId::of(methods::ITER_COUNT), +LintId::of(methods::MANUAL_FILTER_MAP), +LintId::of(methods::MANUAL_FIND_MAP), +LintId::of(methods::MANUAL_SPLIT_ONCE), +LintId::of(methods::MAP_IDENTITY), +LintId::of(methods::OPTION_AS_REF_DEREF), +LintId::of(methods::OPTION_FILTER_MAP), +LintId::of(methods::SEARCH_IS_SOME), +LintId::of(methods::SKIP_WHILE_NEXT), +LintId::of(methods::UNNECESSARY_FILTER_MAP), +LintId::of(methods::USELESS_ASREF), +LintId::of(misc::SHORT_CIRCUIT_STATEMENT), +LintId::of(misc_early::UNNEEDED_WILDCARD_PATTERN), +LintId::of(misc_early::ZERO_PREFIXED_LITERAL), +LintId::of(needless_arbitrary_self_type::NEEDLESS_ARBITRARY_SELF_TYPE), +LintId::of(needless_bool::BOOL_COMPARISON), +LintId::of(needless_bool::NEEDLESS_BOOL), +LintId::of(needless_borrowed_ref::NEEDLESS_BORROWED_REFERENCE), +LintId::of(needless_option_as_deref::NEEDLESS_OPTION_AS_DEREF), +LintId::of(needless_question_mark::NEEDLESS_QUESTION_MARK), +LintId::of(needless_update::NEEDLESS_UPDATE), +LintId::of(neg_cmp_op_on_partial_ord::NEG_CMP_OP_ON_PARTIAL_ORD), +LintId::of(no_effect::NO_EFFECT), +LintId::of(no_effect::UNNECESSARY_OPERATION), +LintId::of(overflow_check_conditional::OVERFLOW_CHECK_CONDITIONAL), +LintId::of(partialeq_ne_impl::PARTIALEQ_NE_IMPL), +LintId::of(precedence::PRECEDENCE), +LintId::of(ptr_offset_with_cast::PTR_OFFSET_WITH_CAST), +LintId::of(ranges::RANGE_ZIP_WITH_LEN), +LintId::of(redundant_closure_call::REDUNDANT_CLOSURE_CALL), +LintId::of(redundant_slicing::REDUNDANT_SLICING), +LintId::of(reference::DEREF_ADDROF), +LintId::of(reference::REF_IN_DEREF), +LintId::of(repeat_once::REPEAT_ONCE), +LintId::of(strings::STRING_FROM_UTF8_AS_BYTES), +LintId::of(strlen_on_c_strings::STRLEN_ON_C_STRINGS), +LintId::of(swap::MANUAL_SWAP), +LintId::of(temporary_assignment::TEMPORARY_ASSIGNMENT), +LintId::of(transmute::CROSSPOINTER_TRANSMUTE), +LintId::of(transmute::TRANSMUTES_EXPRESSIBLE_AS_PTR_CASTS), +LintId::of(transmute::TRANSMUTE_BYTES_TO_STR), +LintId::of(transmute::TRANSMUTE_FLOAT_TO_INT), +LintId::of(transmute::TRANSMUTE_INT_TO_BOOL), +LintId::of(transmute::TRANSMUTE_INT_TO_CHAR), +LintId::of(transmute::TRANSMUTE_INT_TO_FLOAT), +LintId::of(transmute::TRANSMUTE_PTR_TO_REF), +LintId::of(types::BORROWED_BOX), +LintId::of(types::TYPE_COMPLEXITY), +LintId::of(types::VEC_BOX), +LintId::of(unit_types::UNIT_ARG), +LintId::of(unnecessary_sort_by::UNNECESSARY_SORT_BY), +LintId::of(unwrap::UNNECESSARY_UNWRAP), +LintId::of(useless_conversion::USELESS_CONVERSION), +LintId::of(zero_div_zero::ZERO_DIVIDED_BY_ZERO), +]) \ No newline at end of file diff --git a/clippy_lints/src/lib.register_correctness.rs b/clippy_lints/src/lib.register_correctness.rs new file mode 100644 index 00000000000..ef42f930a96 --- /dev/null +++ b/clippy_lints/src/lib.register_correctness.rs @@ -0,0 +1,73 @@ +// This file was generated by `cargo dev update_lints`. +// Use that command to update this file and do not edit by hand. +// Manual edits will be overwritten. + +store.register_group(true, "clippy::correctness", Some("clippy_correctness"), vec![ +LintId::of(absurd_extreme_comparisons::ABSURD_EXTREME_COMPARISONS), +LintId::of(approx_const::APPROX_CONSTANT), +LintId::of(async_yields_async::ASYNC_YIELDS_ASYNC), +LintId::of(attrs::DEPRECATED_SEMVER), +LintId::of(attrs::MISMATCHED_TARGET_OS), +LintId::of(attrs::USELESS_ATTRIBUTE), +LintId::of(bit_mask::BAD_BIT_MASK), +LintId::of(bit_mask::INEFFECTIVE_BIT_MASK), +LintId::of(booleans::LOGIC_BUG), +LintId::of(casts::CAST_REF_TO_MUT), +LintId::of(copies::IFS_SAME_COND), +LintId::of(copies::IF_SAME_THEN_ELSE), +LintId::of(derive::DERIVE_HASH_XOR_EQ), +LintId::of(derive::DERIVE_ORD_XOR_PARTIAL_ORD), +LintId::of(drop_forget_ref::DROP_COPY), +LintId::of(drop_forget_ref::DROP_REF), +LintId::of(drop_forget_ref::FORGET_COPY), +LintId::of(drop_forget_ref::FORGET_REF), +LintId::of(enum_clike::ENUM_CLIKE_UNPORTABLE_VARIANT), +LintId::of(eq_op::EQ_OP), +LintId::of(erasing_op::ERASING_OP), +LintId::of(formatting::POSSIBLE_MISSING_COMMA), +LintId::of(functions::NOT_UNSAFE_PTR_ARG_DEREF), +LintId::of(if_let_mutex::IF_LET_MUTEX), +LintId::of(indexing_slicing::OUT_OF_BOUNDS_INDEXING), +LintId::of(infinite_iter::INFINITE_ITER), +LintId::of(inherent_to_string::INHERENT_TO_STRING_SHADOW_DISPLAY), +LintId::of(inline_fn_without_body::INLINE_FN_WITHOUT_BODY), +LintId::of(let_underscore::LET_UNDERSCORE_LOCK), +LintId::of(literal_representation::MISTYPED_LITERAL_SUFFIXES), +LintId::of(loops::ITER_NEXT_LOOP), +LintId::of(loops::NEVER_LOOP), +LintId::of(loops::WHILE_IMMUTABLE_CONDITION), +LintId::of(mem_discriminant::MEM_DISCRIMINANT_NON_ENUM), +LintId::of(mem_replace::MEM_REPLACE_WITH_UNINIT), +LintId::of(methods::CLONE_DOUBLE_REF), +LintId::of(methods::ITERATOR_STEP_BY_ZERO), +LintId::of(methods::SUSPICIOUS_SPLITN), +LintId::of(methods::UNINIT_ASSUMED_INIT), +LintId::of(methods::ZST_OFFSET), +LintId::of(minmax::MIN_MAX), +LintId::of(misc::CMP_NAN), +LintId::of(misc::MODULO_ONE), +LintId::of(non_octal_unix_permissions::NON_OCTAL_UNIX_PERMISSIONS), +LintId::of(open_options::NONSENSICAL_OPEN_OPTIONS), +LintId::of(option_env_unwrap::OPTION_ENV_UNWRAP), +LintId::of(ptr::INVALID_NULL_PTR_USAGE), +LintId::of(ptr::MUT_FROM_REF), +LintId::of(ranges::REVERSED_EMPTY_RANGES), +LintId::of(regex::INVALID_REGEX), +LintId::of(self_assignment::SELF_ASSIGNMENT), +LintId::of(serde_api::SERDE_API_MISUSE), +LintId::of(size_of_in_element_count::SIZE_OF_IN_ELEMENT_COUNT), +LintId::of(swap::ALMOST_SWAPPED), +LintId::of(to_string_in_display::TO_STRING_IN_DISPLAY), +LintId::of(transmute::UNSOUND_COLLECTION_TRANSMUTE), +LintId::of(transmute::WRONG_TRANSMUTE), +LintId::of(transmuting_null::TRANSMUTING_NULL), +LintId::of(undropped_manually_drops::UNDROPPED_MANUALLY_DROPS), +LintId::of(unicode::INVISIBLE_CHARACTERS), +LintId::of(unit_return_expecting_ord::UNIT_RETURN_EXPECTING_ORD), +LintId::of(unit_types::UNIT_CMP), +LintId::of(unnamed_address::FN_ADDRESS_COMPARISONS), +LintId::of(unnamed_address::VTABLE_ADDRESS_COMPARISONS), +LintId::of(unused_io_amount::UNUSED_IO_AMOUNT), +LintId::of(unwrap::PANICKING_UNWRAP), +LintId::of(vec_resize_to_zero::VEC_RESIZE_TO_ZERO), +]) \ No newline at end of file diff --git a/clippy_lints/src/lib.register_internal.rs b/clippy_lints/src/lib.register_internal.rs new file mode 100644 index 00000000000..7d43e2196cd --- /dev/null +++ b/clippy_lints/src/lib.register_internal.rs @@ -0,0 +1,18 @@ +// This file was generated by `cargo dev update_lints`. +// Use that command to update this file and do not edit by hand. +// Manual edits will be overwritten. + +store.register_group(true, "clippy::internal", Some("clippy_internal"), vec![ +LintId::of(utils::internal_lints::CLIPPY_LINTS_INTERNAL), +LintId::of(utils::internal_lints::COLLAPSIBLE_SPAN_LINT_CALLS), +LintId::of(utils::internal_lints::COMPILER_LINT_FUNCTIONS), +LintId::of(utils::internal_lints::DEFAULT_LINT), +LintId::of(utils::internal_lints::IF_CHAIN_STYLE), +LintId::of(utils::internal_lints::INTERNING_DEFINED_SYMBOL), +LintId::of(utils::internal_lints::INVALID_PATHS), +LintId::of(utils::internal_lints::LINT_WITHOUT_LINT_PASS), +LintId::of(utils::internal_lints::MATCH_TYPE_ON_DIAGNOSTIC_ITEM), +LintId::of(utils::internal_lints::OUTER_EXPN_EXPN_DATA), +LintId::of(utils::internal_lints::PRODUCE_ICE), +LintId::of(utils::internal_lints::UNNECESSARY_SYMBOL_STR), +]) \ No newline at end of file diff --git a/clippy_lints/src/lib.register_lints.rs b/clippy_lints/src/lib.register_lints.rs new file mode 100644 index 00000000000..ed0de60c284 --- /dev/null +++ b/clippy_lints/src/lib.register_lints.rs @@ -0,0 +1,508 @@ +// This file was generated by `cargo dev update_lints`. +// Use that command to update this file and do not edit by hand. +// Manual edits will be overwritten. + + store.register_lints(&[ + #[cfg(feature = "internal-lints")] + utils::internal_lints::CLIPPY_LINTS_INTERNAL, + #[cfg(feature = "internal-lints")] + utils::internal_lints::COLLAPSIBLE_SPAN_LINT_CALLS, + #[cfg(feature = "internal-lints")] + utils::internal_lints::COMPILER_LINT_FUNCTIONS, + #[cfg(feature = "internal-lints")] + utils::internal_lints::DEFAULT_LINT, + #[cfg(feature = "internal-lints")] + utils::internal_lints::IF_CHAIN_STYLE, + #[cfg(feature = "internal-lints")] + utils::internal_lints::INTERNING_DEFINED_SYMBOL, + #[cfg(feature = "internal-lints")] + utils::internal_lints::INVALID_PATHS, + #[cfg(feature = "internal-lints")] + utils::internal_lints::LINT_WITHOUT_LINT_PASS, + #[cfg(feature = "internal-lints")] + utils::internal_lints::MATCH_TYPE_ON_DIAGNOSTIC_ITEM, + #[cfg(feature = "internal-lints")] + utils::internal_lints::OUTER_EXPN_EXPN_DATA, + #[cfg(feature = "internal-lints")] + utils::internal_lints::PRODUCE_ICE, + #[cfg(feature = "internal-lints")] + utils::internal_lints::UNNECESSARY_SYMBOL_STR, + absurd_extreme_comparisons::ABSURD_EXTREME_COMPARISONS, + approx_const::APPROX_CONSTANT, + arithmetic::FLOAT_ARITHMETIC, + arithmetic::INTEGER_ARITHMETIC, + as_conversions::AS_CONVERSIONS, + asm_syntax::INLINE_ASM_X86_ATT_SYNTAX, + asm_syntax::INLINE_ASM_X86_INTEL_SYNTAX, + assertions_on_constants::ASSERTIONS_ON_CONSTANTS, + assign_ops::ASSIGN_OP_PATTERN, + assign_ops::MISREFACTORED_ASSIGN_OP, + async_yields_async::ASYNC_YIELDS_ASYNC, + attrs::BLANKET_CLIPPY_RESTRICTION_LINTS, + attrs::DEPRECATED_CFG_ATTR, + attrs::DEPRECATED_SEMVER, + attrs::EMPTY_LINE_AFTER_OUTER_ATTR, + attrs::INLINE_ALWAYS, + attrs::MISMATCHED_TARGET_OS, + attrs::USELESS_ATTRIBUTE, + await_holding_invalid::AWAIT_HOLDING_LOCK, + await_holding_invalid::AWAIT_HOLDING_REFCELL_REF, + bit_mask::BAD_BIT_MASK, + bit_mask::INEFFECTIVE_BIT_MASK, + bit_mask::VERBOSE_BIT_MASK, + blacklisted_name::BLACKLISTED_NAME, + blocks_in_if_conditions::BLOCKS_IN_IF_CONDITIONS, + bool_assert_comparison::BOOL_ASSERT_COMPARISON, + booleans::LOGIC_BUG, + booleans::NONMINIMAL_BOOL, + bytecount::NAIVE_BYTECOUNT, + cargo_common_metadata::CARGO_COMMON_METADATA, + case_sensitive_file_extension_comparisons::CASE_SENSITIVE_FILE_EXTENSION_COMPARISONS, + casts::CAST_LOSSLESS, + casts::CAST_POSSIBLE_TRUNCATION, + casts::CAST_POSSIBLE_WRAP, + casts::CAST_PRECISION_LOSS, + casts::CAST_PTR_ALIGNMENT, + casts::CAST_REF_TO_MUT, + casts::CAST_SIGN_LOSS, + casts::CHAR_LIT_AS_U8, + casts::FN_TO_NUMERIC_CAST, + casts::FN_TO_NUMERIC_CAST_WITH_TRUNCATION, + casts::PTR_AS_PTR, + casts::UNNECESSARY_CAST, + checked_conversions::CHECKED_CONVERSIONS, + cognitive_complexity::COGNITIVE_COMPLEXITY, + collapsible_if::COLLAPSIBLE_ELSE_IF, + collapsible_if::COLLAPSIBLE_IF, + collapsible_match::COLLAPSIBLE_MATCH, + comparison_chain::COMPARISON_CHAIN, + copies::BRANCHES_SHARING_CODE, + copies::IFS_SAME_COND, + copies::IF_SAME_THEN_ELSE, + copies::SAME_FUNCTIONS_IN_IF_CONDITION, + copy_iterator::COPY_ITERATOR, + create_dir::CREATE_DIR, + dbg_macro::DBG_MACRO, + default::DEFAULT_TRAIT_ACCESS, + default::FIELD_REASSIGN_WITH_DEFAULT, + default_numeric_fallback::DEFAULT_NUMERIC_FALLBACK, + dereference::EXPLICIT_DEREF_METHODS, + derivable_impls::DERIVABLE_IMPLS, + derive::DERIVE_HASH_XOR_EQ, + derive::DERIVE_ORD_XOR_PARTIAL_ORD, + derive::EXPL_IMPL_CLONE_ON_COPY, + derive::UNSAFE_DERIVE_DESERIALIZE, + disallowed_method::DISALLOWED_METHOD, + disallowed_script_idents::DISALLOWED_SCRIPT_IDENTS, + disallowed_type::DISALLOWED_TYPE, + doc::DOC_MARKDOWN, + doc::MISSING_ERRORS_DOC, + doc::MISSING_PANICS_DOC, + doc::MISSING_SAFETY_DOC, + doc::NEEDLESS_DOCTEST_MAIN, + double_comparison::DOUBLE_COMPARISONS, + double_parens::DOUBLE_PARENS, + drop_forget_ref::DROP_COPY, + drop_forget_ref::DROP_REF, + drop_forget_ref::FORGET_COPY, + drop_forget_ref::FORGET_REF, + duration_subsec::DURATION_SUBSEC, + else_if_without_else::ELSE_IF_WITHOUT_ELSE, + empty_enum::EMPTY_ENUM, + entry::MAP_ENTRY, + enum_clike::ENUM_CLIKE_UNPORTABLE_VARIANT, + enum_variants::ENUM_VARIANT_NAMES, + enum_variants::MODULE_INCEPTION, + enum_variants::MODULE_NAME_REPETITIONS, + eq_op::EQ_OP, + eq_op::OP_REF, + erasing_op::ERASING_OP, + escape::BOXED_LOCAL, + eta_reduction::REDUNDANT_CLOSURE, + eta_reduction::REDUNDANT_CLOSURE_FOR_METHOD_CALLS, + eval_order_dependence::DIVERGING_SUB_EXPRESSION, + eval_order_dependence::EVAL_ORDER_DEPENDENCE, + excessive_bools::FN_PARAMS_EXCESSIVE_BOOLS, + excessive_bools::STRUCT_EXCESSIVE_BOOLS, + exhaustive_items::EXHAUSTIVE_ENUMS, + exhaustive_items::EXHAUSTIVE_STRUCTS, + exit::EXIT, + explicit_write::EXPLICIT_WRITE, + fallible_impl_from::FALLIBLE_IMPL_FROM, + feature_name::NEGATIVE_FEATURE_NAMES, + feature_name::REDUNDANT_FEATURE_NAMES, + float_equality_without_abs::FLOAT_EQUALITY_WITHOUT_ABS, + float_literal::EXCESSIVE_PRECISION, + float_literal::LOSSY_FLOAT_LITERAL, + floating_point_arithmetic::IMPRECISE_FLOPS, + floating_point_arithmetic::SUBOPTIMAL_FLOPS, + format::USELESS_FORMAT, + formatting::POSSIBLE_MISSING_COMMA, + formatting::SUSPICIOUS_ASSIGNMENT_FORMATTING, + formatting::SUSPICIOUS_ELSE_FORMATTING, + formatting::SUSPICIOUS_UNARY_OP_FORMATTING, + from_over_into::FROM_OVER_INTO, + from_str_radix_10::FROM_STR_RADIX_10, + functions::DOUBLE_MUST_USE, + functions::MUST_USE_CANDIDATE, + functions::MUST_USE_UNIT, + functions::NOT_UNSAFE_PTR_ARG_DEREF, + functions::RESULT_UNIT_ERR, + functions::TOO_MANY_ARGUMENTS, + functions::TOO_MANY_LINES, + future_not_send::FUTURE_NOT_SEND, + get_last_with_len::GET_LAST_WITH_LEN, + identity_op::IDENTITY_OP, + if_let_mutex::IF_LET_MUTEX, + if_not_else::IF_NOT_ELSE, + if_then_panic::IF_THEN_PANIC, + if_then_some_else_none::IF_THEN_SOME_ELSE_NONE, + implicit_hasher::IMPLICIT_HASHER, + implicit_return::IMPLICIT_RETURN, + implicit_saturating_sub::IMPLICIT_SATURATING_SUB, + inconsistent_struct_constructor::INCONSISTENT_STRUCT_CONSTRUCTOR, + indexing_slicing::INDEXING_SLICING, + indexing_slicing::OUT_OF_BOUNDS_INDEXING, + infinite_iter::INFINITE_ITER, + infinite_iter::MAYBE_INFINITE_ITER, + inherent_impl::MULTIPLE_INHERENT_IMPL, + inherent_to_string::INHERENT_TO_STRING, + inherent_to_string::INHERENT_TO_STRING_SHADOW_DISPLAY, + inline_fn_without_body::INLINE_FN_WITHOUT_BODY, + int_plus_one::INT_PLUS_ONE, + integer_division::INTEGER_DIVISION, + invalid_upcast_comparisons::INVALID_UPCAST_COMPARISONS, + items_after_statements::ITEMS_AFTER_STATEMENTS, + iter_not_returning_iterator::ITER_NOT_RETURNING_ITERATOR, + large_const_arrays::LARGE_CONST_ARRAYS, + large_enum_variant::LARGE_ENUM_VARIANT, + large_stack_arrays::LARGE_STACK_ARRAYS, + len_zero::COMPARISON_TO_EMPTY, + len_zero::LEN_WITHOUT_IS_EMPTY, + len_zero::LEN_ZERO, + let_if_seq::USELESS_LET_IF_SEQ, + let_underscore::LET_UNDERSCORE_DROP, + let_underscore::LET_UNDERSCORE_LOCK, + let_underscore::LET_UNDERSCORE_MUST_USE, + lifetimes::EXTRA_UNUSED_LIFETIMES, + lifetimes::NEEDLESS_LIFETIMES, + literal_representation::DECIMAL_LITERAL_REPRESENTATION, + literal_representation::INCONSISTENT_DIGIT_GROUPING, + literal_representation::LARGE_DIGIT_GROUPS, + literal_representation::MISTYPED_LITERAL_SUFFIXES, + literal_representation::UNREADABLE_LITERAL, + literal_representation::UNUSUAL_BYTE_GROUPINGS, + loops::EMPTY_LOOP, + loops::EXPLICIT_COUNTER_LOOP, + loops::EXPLICIT_INTO_ITER_LOOP, + loops::EXPLICIT_ITER_LOOP, + loops::FOR_KV_MAP, + loops::FOR_LOOPS_OVER_FALLIBLES, + loops::ITER_NEXT_LOOP, + loops::MANUAL_FLATTEN, + loops::MANUAL_MEMCPY, + loops::MUT_RANGE_BOUND, + loops::NEEDLESS_COLLECT, + loops::NEEDLESS_RANGE_LOOP, + loops::NEVER_LOOP, + loops::SAME_ITEM_PUSH, + loops::SINGLE_ELEMENT_LOOP, + loops::WHILE_IMMUTABLE_CONDITION, + loops::WHILE_LET_LOOP, + loops::WHILE_LET_ON_ITERATOR, + macro_use::MACRO_USE_IMPORTS, + main_recursion::MAIN_RECURSION, + manual_async_fn::MANUAL_ASYNC_FN, + manual_map::MANUAL_MAP, + manual_non_exhaustive::MANUAL_NON_EXHAUSTIVE, + manual_ok_or::MANUAL_OK_OR, + manual_strip::MANUAL_STRIP, + manual_unwrap_or::MANUAL_UNWRAP_OR, + map_clone::MAP_CLONE, + map_err_ignore::MAP_ERR_IGNORE, + map_unit_fn::OPTION_MAP_UNIT_FN, + map_unit_fn::RESULT_MAP_UNIT_FN, + match_on_vec_items::MATCH_ON_VEC_ITEMS, + match_result_ok::MATCH_RESULT_OK, + matches::INFALLIBLE_DESTRUCTURING_MATCH, + matches::MATCH_AS_REF, + matches::MATCH_BOOL, + matches::MATCH_LIKE_MATCHES_MACRO, + matches::MATCH_OVERLAPPING_ARM, + matches::MATCH_REF_PATS, + matches::MATCH_SAME_ARMS, + matches::MATCH_SINGLE_BINDING, + matches::MATCH_WILDCARD_FOR_SINGLE_VARIANTS, + matches::MATCH_WILD_ERR_ARM, + matches::REDUNDANT_PATTERN_MATCHING, + matches::REST_PAT_IN_FULLY_BOUND_STRUCTS, + matches::SINGLE_MATCH, + matches::SINGLE_MATCH_ELSE, + matches::WILDCARD_ENUM_MATCH_ARM, + matches::WILDCARD_IN_OR_PATTERNS, + mem_discriminant::MEM_DISCRIMINANT_NON_ENUM, + mem_forget::MEM_FORGET, + mem_replace::MEM_REPLACE_OPTION_WITH_NONE, + mem_replace::MEM_REPLACE_WITH_DEFAULT, + mem_replace::MEM_REPLACE_WITH_UNINIT, + methods::BIND_INSTEAD_OF_MAP, + methods::BYTES_NTH, + methods::CHARS_LAST_CMP, + methods::CHARS_NEXT_CMP, + methods::CLONED_INSTEAD_OF_COPIED, + methods::CLONE_DOUBLE_REF, + methods::CLONE_ON_COPY, + methods::CLONE_ON_REF_PTR, + methods::EXPECT_FUN_CALL, + methods::EXPECT_USED, + methods::EXTEND_WITH_DRAIN, + methods::FILETYPE_IS_FILE, + methods::FILTER_MAP_IDENTITY, + methods::FILTER_MAP_NEXT, + methods::FILTER_NEXT, + methods::FLAT_MAP_IDENTITY, + methods::FLAT_MAP_OPTION, + methods::FROM_ITER_INSTEAD_OF_COLLECT, + methods::GET_UNWRAP, + methods::IMPLICIT_CLONE, + methods::INEFFICIENT_TO_STRING, + methods::INSPECT_FOR_EACH, + methods::INTO_ITER_ON_REF, + methods::ITERATOR_STEP_BY_ZERO, + methods::ITER_CLONED_COLLECT, + methods::ITER_COUNT, + methods::ITER_NEXT_SLICE, + methods::ITER_NTH, + methods::ITER_NTH_ZERO, + methods::ITER_SKIP_NEXT, + methods::MANUAL_FILTER_MAP, + methods::MANUAL_FIND_MAP, + methods::MANUAL_SATURATING_ARITHMETIC, + methods::MANUAL_SPLIT_ONCE, + methods::MANUAL_STR_REPEAT, + methods::MAP_COLLECT_RESULT_UNIT, + methods::MAP_FLATTEN, + methods::MAP_IDENTITY, + methods::MAP_UNWRAP_OR, + methods::NEW_RET_NO_SELF, + methods::OK_EXPECT, + methods::OPTION_AS_REF_DEREF, + methods::OPTION_FILTER_MAP, + methods::OPTION_MAP_OR_NONE, + methods::OR_FUN_CALL, + methods::RESULT_MAP_OR_INTO_OPTION, + methods::SEARCH_IS_SOME, + methods::SHOULD_IMPLEMENT_TRAIT, + methods::SINGLE_CHAR_ADD_STR, + methods::SINGLE_CHAR_PATTERN, + methods::SKIP_WHILE_NEXT, + methods::STRING_EXTEND_CHARS, + methods::SUSPICIOUS_MAP, + methods::SUSPICIOUS_SPLITN, + methods::UNINIT_ASSUMED_INIT, + methods::UNNECESSARY_FILTER_MAP, + methods::UNNECESSARY_FOLD, + methods::UNNECESSARY_LAZY_EVALUATIONS, + methods::UNWRAP_OR_ELSE_DEFAULT, + methods::UNWRAP_USED, + methods::USELESS_ASREF, + methods::WRONG_SELF_CONVENTION, + methods::ZST_OFFSET, + minmax::MIN_MAX, + misc::CMP_NAN, + misc::CMP_OWNED, + misc::FLOAT_CMP, + misc::FLOAT_CMP_CONST, + misc::MODULO_ONE, + misc::SHORT_CIRCUIT_STATEMENT, + misc::TOPLEVEL_REF_ARG, + misc::USED_UNDERSCORE_BINDING, + misc::ZERO_PTR, + misc_early::BUILTIN_TYPE_SHADOW, + misc_early::DOUBLE_NEG, + misc_early::DUPLICATE_UNDERSCORE_ARGUMENT, + misc_early::MIXED_CASE_HEX_LITERALS, + misc_early::REDUNDANT_PATTERN, + misc_early::UNNEEDED_FIELD_PATTERN, + misc_early::UNNEEDED_WILDCARD_PATTERN, + misc_early::UNSEPARATED_LITERAL_SUFFIX, + misc_early::ZERO_PREFIXED_LITERAL, + missing_const_for_fn::MISSING_CONST_FOR_FN, + missing_doc::MISSING_DOCS_IN_PRIVATE_ITEMS, + missing_enforced_import_rename::MISSING_ENFORCED_IMPORT_RENAMES, + missing_inline::MISSING_INLINE_IN_PUBLIC_ITEMS, + module_style::MOD_MODULE_FILES, + module_style::SELF_NAMED_MODULE_FILES, + modulo_arithmetic::MODULO_ARITHMETIC, + multiple_crate_versions::MULTIPLE_CRATE_VERSIONS, + mut_key::MUTABLE_KEY_TYPE, + mut_mut::MUT_MUT, + mut_mutex_lock::MUT_MUTEX_LOCK, + mut_reference::UNNECESSARY_MUT_PASSED, + mutable_debug_assertion::DEBUG_ASSERT_WITH_MUT_CALL, + mutex_atomic::MUTEX_ATOMIC, + mutex_atomic::MUTEX_INTEGER, + needless_arbitrary_self_type::NEEDLESS_ARBITRARY_SELF_TYPE, + needless_bitwise_bool::NEEDLESS_BITWISE_BOOL, + needless_bool::BOOL_COMPARISON, + needless_bool::NEEDLESS_BOOL, + needless_borrow::NEEDLESS_BORROW, + needless_borrow::REF_BINDING_TO_REFERENCE, + needless_borrowed_ref::NEEDLESS_BORROWED_REFERENCE, + needless_continue::NEEDLESS_CONTINUE, + needless_for_each::NEEDLESS_FOR_EACH, + needless_option_as_deref::NEEDLESS_OPTION_AS_DEREF, + needless_pass_by_value::NEEDLESS_PASS_BY_VALUE, + needless_question_mark::NEEDLESS_QUESTION_MARK, + needless_update::NEEDLESS_UPDATE, + neg_cmp_op_on_partial_ord::NEG_CMP_OP_ON_PARTIAL_ORD, + neg_multiply::NEG_MULTIPLY, + new_without_default::NEW_WITHOUT_DEFAULT, + no_effect::NO_EFFECT, + no_effect::UNNECESSARY_OPERATION, + non_copy_const::BORROW_INTERIOR_MUTABLE_CONST, + non_copy_const::DECLARE_INTERIOR_MUTABLE_CONST, + non_expressive_names::JUST_UNDERSCORES_AND_DIGITS, + non_expressive_names::MANY_SINGLE_CHAR_NAMES, + non_expressive_names::SIMILAR_NAMES, + non_octal_unix_permissions::NON_OCTAL_UNIX_PERMISSIONS, + nonstandard_macro_braces::NONSTANDARD_MACRO_BRACES, + open_options::NONSENSICAL_OPEN_OPTIONS, + option_env_unwrap::OPTION_ENV_UNWRAP, + option_if_let_else::OPTION_IF_LET_ELSE, + overflow_check_conditional::OVERFLOW_CHECK_CONDITIONAL, + panic_in_result_fn::PANIC_IN_RESULT_FN, + panic_unimplemented::PANIC, + panic_unimplemented::TODO, + panic_unimplemented::UNIMPLEMENTED, + panic_unimplemented::UNREACHABLE, + partialeq_ne_impl::PARTIALEQ_NE_IMPL, + pass_by_ref_or_value::LARGE_TYPES_PASSED_BY_VALUE, + pass_by_ref_or_value::TRIVIALLY_COPY_PASS_BY_REF, + path_buf_push_overwrite::PATH_BUF_PUSH_OVERWRITE, + pattern_type_mismatch::PATTERN_TYPE_MISMATCH, + precedence::PRECEDENCE, + ptr::CMP_NULL, + ptr::INVALID_NULL_PTR_USAGE, + ptr::MUT_FROM_REF, + ptr::PTR_ARG, + ptr_eq::PTR_EQ, + ptr_offset_with_cast::PTR_OFFSET_WITH_CAST, + question_mark::QUESTION_MARK, + ranges::MANUAL_RANGE_CONTAINS, + ranges::RANGE_MINUS_ONE, + ranges::RANGE_PLUS_ONE, + ranges::RANGE_ZIP_WITH_LEN, + ranges::REVERSED_EMPTY_RANGES, + redundant_clone::REDUNDANT_CLONE, + redundant_closure_call::REDUNDANT_CLOSURE_CALL, + redundant_else::REDUNDANT_ELSE, + redundant_field_names::REDUNDANT_FIELD_NAMES, + redundant_pub_crate::REDUNDANT_PUB_CRATE, + redundant_slicing::REDUNDANT_SLICING, + redundant_static_lifetimes::REDUNDANT_STATIC_LIFETIMES, + ref_option_ref::REF_OPTION_REF, + reference::DEREF_ADDROF, + reference::REF_IN_DEREF, + regex::INVALID_REGEX, + regex::TRIVIAL_REGEX, + repeat_once::REPEAT_ONCE, + returns::LET_AND_RETURN, + returns::NEEDLESS_RETURN, + same_name_method::SAME_NAME_METHOD, + self_assignment::SELF_ASSIGNMENT, + self_named_constructors::SELF_NAMED_CONSTRUCTORS, + semicolon_if_nothing_returned::SEMICOLON_IF_NOTHING_RETURNED, + serde_api::SERDE_API_MISUSE, + shadow::SHADOW_REUSE, + shadow::SHADOW_SAME, + shadow::SHADOW_UNRELATED, + single_component_path_imports::SINGLE_COMPONENT_PATH_IMPORTS, + size_of_in_element_count::SIZE_OF_IN_ELEMENT_COUNT, + slow_vector_initialization::SLOW_VECTOR_INITIALIZATION, + stable_sort_primitive::STABLE_SORT_PRIMITIVE, + strings::STRING_ADD, + strings::STRING_ADD_ASSIGN, + strings::STRING_FROM_UTF8_AS_BYTES, + strings::STRING_LIT_AS_BYTES, + strings::STRING_TO_STRING, + strings::STR_TO_STRING, + strlen_on_c_strings::STRLEN_ON_C_STRINGS, + suspicious_operation_groupings::SUSPICIOUS_OPERATION_GROUPINGS, + suspicious_trait_impl::SUSPICIOUS_ARITHMETIC_IMPL, + suspicious_trait_impl::SUSPICIOUS_OP_ASSIGN_IMPL, + swap::ALMOST_SWAPPED, + swap::MANUAL_SWAP, + tabs_in_doc_comments::TABS_IN_DOC_COMMENTS, + temporary_assignment::TEMPORARY_ASSIGNMENT, + to_digit_is_some::TO_DIGIT_IS_SOME, + to_string_in_display::TO_STRING_IN_DISPLAY, + trait_bounds::TRAIT_DUPLICATION_IN_BOUNDS, + trait_bounds::TYPE_REPETITION_IN_BOUNDS, + transmute::CROSSPOINTER_TRANSMUTE, + transmute::TRANSMUTES_EXPRESSIBLE_AS_PTR_CASTS, + transmute::TRANSMUTE_BYTES_TO_STR, + transmute::TRANSMUTE_FLOAT_TO_INT, + transmute::TRANSMUTE_INT_TO_BOOL, + transmute::TRANSMUTE_INT_TO_CHAR, + transmute::TRANSMUTE_INT_TO_FLOAT, + transmute::TRANSMUTE_PTR_TO_PTR, + transmute::TRANSMUTE_PTR_TO_REF, + transmute::UNSOUND_COLLECTION_TRANSMUTE, + transmute::USELESS_TRANSMUTE, + transmute::WRONG_TRANSMUTE, + transmuting_null::TRANSMUTING_NULL, + try_err::TRY_ERR, + types::BORROWED_BOX, + types::BOX_COLLECTION, + types::LINKEDLIST, + types::OPTION_OPTION, + types::RC_BUFFER, + types::RC_MUTEX, + types::REDUNDANT_ALLOCATION, + types::TYPE_COMPLEXITY, + types::VEC_BOX, + undropped_manually_drops::UNDROPPED_MANUALLY_DROPS, + unicode::INVISIBLE_CHARACTERS, + unicode::NON_ASCII_LITERAL, + unicode::UNICODE_NOT_NFC, + unit_return_expecting_ord::UNIT_RETURN_EXPECTING_ORD, + unit_types::LET_UNIT_VALUE, + unit_types::UNIT_ARG, + unit_types::UNIT_CMP, + unnamed_address::FN_ADDRESS_COMPARISONS, + unnamed_address::VTABLE_ADDRESS_COMPARISONS, + unnecessary_self_imports::UNNECESSARY_SELF_IMPORTS, + unnecessary_sort_by::UNNECESSARY_SORT_BY, + unnecessary_wraps::UNNECESSARY_WRAPS, + unnested_or_patterns::UNNESTED_OR_PATTERNS, + unsafe_removed_from_name::UNSAFE_REMOVED_FROM_NAME, + unused_async::UNUSED_ASYNC, + unused_io_amount::UNUSED_IO_AMOUNT, + unused_self::UNUSED_SELF, + unused_unit::UNUSED_UNIT, + unwrap::PANICKING_UNWRAP, + unwrap::UNNECESSARY_UNWRAP, + unwrap_in_result::UNWRAP_IN_RESULT, + upper_case_acronyms::UPPER_CASE_ACRONYMS, + use_self::USE_SELF, + useless_conversion::USELESS_CONVERSION, + vec::USELESS_VEC, + vec_init_then_push::VEC_INIT_THEN_PUSH, + vec_resize_to_zero::VEC_RESIZE_TO_ZERO, + verbose_file_reads::VERBOSE_FILE_READS, + wildcard_dependencies::WILDCARD_DEPENDENCIES, + wildcard_imports::ENUM_GLOB_USE, + wildcard_imports::WILDCARD_IMPORTS, + write::PRINTLN_EMPTY_STRING, + write::PRINT_LITERAL, + write::PRINT_STDERR, + write::PRINT_STDOUT, + write::PRINT_WITH_NEWLINE, + write::USE_DEBUG, + write::WRITELN_EMPTY_STRING, + write::WRITE_LITERAL, + write::WRITE_WITH_NEWLINE, + zero_div_zero::ZERO_DIVIDED_BY_ZERO, + zero_sized_map_values::ZERO_SIZED_MAP_VALUES, + ]) \ No newline at end of file diff --git a/clippy_lints/src/lib.register_nursery.rs b/clippy_lints/src/lib.register_nursery.rs new file mode 100644 index 00000000000..72a09fcfe25 --- /dev/null +++ b/clippy_lints/src/lib.register_nursery.rs @@ -0,0 +1,28 @@ +// This file was generated by `cargo dev update_lints`. +// Use that command to update this file and do not edit by hand. +// Manual edits will be overwritten. + +store.register_group(true, "clippy::nursery", Some("clippy_nursery"), vec![ +LintId::of(attrs::EMPTY_LINE_AFTER_OUTER_ATTR), +LintId::of(cognitive_complexity::COGNITIVE_COMPLEXITY), +LintId::of(copies::BRANCHES_SHARING_CODE), +LintId::of(disallowed_method::DISALLOWED_METHOD), +LintId::of(disallowed_type::DISALLOWED_TYPE), +LintId::of(fallible_impl_from::FALLIBLE_IMPL_FROM), +LintId::of(floating_point_arithmetic::IMPRECISE_FLOPS), +LintId::of(floating_point_arithmetic::SUBOPTIMAL_FLOPS), +LintId::of(future_not_send::FUTURE_NOT_SEND), +LintId::of(let_if_seq::USELESS_LET_IF_SEQ), +LintId::of(missing_const_for_fn::MISSING_CONST_FOR_FN), +LintId::of(mutable_debug_assertion::DEBUG_ASSERT_WITH_MUT_CALL), +LintId::of(mutex_atomic::MUTEX_INTEGER), +LintId::of(nonstandard_macro_braces::NONSTANDARD_MACRO_BRACES), +LintId::of(option_if_let_else::OPTION_IF_LET_ELSE), +LintId::of(path_buf_push_overwrite::PATH_BUF_PUSH_OVERWRITE), +LintId::of(redundant_pub_crate::REDUNDANT_PUB_CRATE), +LintId::of(regex::TRIVIAL_REGEX), +LintId::of(strings::STRING_LIT_AS_BYTES), +LintId::of(suspicious_operation_groupings::SUSPICIOUS_OPERATION_GROUPINGS), +LintId::of(transmute::USELESS_TRANSMUTE), +LintId::of(use_self::USE_SELF), +]) \ No newline at end of file diff --git a/clippy_lints/src/lib.register_pedantic.rs b/clippy_lints/src/lib.register_pedantic.rs new file mode 100644 index 00000000000..8356198d80d --- /dev/null +++ b/clippy_lints/src/lib.register_pedantic.rs @@ -0,0 +1,101 @@ +// This file was generated by `cargo dev update_lints`. +// Use that command to update this file and do not edit by hand. +// Manual edits will be overwritten. + +store.register_group(true, "clippy::pedantic", Some("clippy_pedantic"), vec![ +LintId::of(attrs::INLINE_ALWAYS), +LintId::of(await_holding_invalid::AWAIT_HOLDING_LOCK), +LintId::of(await_holding_invalid::AWAIT_HOLDING_REFCELL_REF), +LintId::of(bit_mask::VERBOSE_BIT_MASK), +LintId::of(bytecount::NAIVE_BYTECOUNT), +LintId::of(case_sensitive_file_extension_comparisons::CASE_SENSITIVE_FILE_EXTENSION_COMPARISONS), +LintId::of(casts::CAST_LOSSLESS), +LintId::of(casts::CAST_POSSIBLE_TRUNCATION), +LintId::of(casts::CAST_POSSIBLE_WRAP), +LintId::of(casts::CAST_PRECISION_LOSS), +LintId::of(casts::CAST_PTR_ALIGNMENT), +LintId::of(casts::CAST_SIGN_LOSS), +LintId::of(casts::PTR_AS_PTR), +LintId::of(checked_conversions::CHECKED_CONVERSIONS), +LintId::of(copies::SAME_FUNCTIONS_IN_IF_CONDITION), +LintId::of(copy_iterator::COPY_ITERATOR), +LintId::of(default::DEFAULT_TRAIT_ACCESS), +LintId::of(dereference::EXPLICIT_DEREF_METHODS), +LintId::of(derive::EXPL_IMPL_CLONE_ON_COPY), +LintId::of(derive::UNSAFE_DERIVE_DESERIALIZE), +LintId::of(doc::DOC_MARKDOWN), +LintId::of(doc::MISSING_ERRORS_DOC), +LintId::of(doc::MISSING_PANICS_DOC), +LintId::of(empty_enum::EMPTY_ENUM), +LintId::of(enum_variants::MODULE_NAME_REPETITIONS), +LintId::of(eta_reduction::REDUNDANT_CLOSURE_FOR_METHOD_CALLS), +LintId::of(excessive_bools::FN_PARAMS_EXCESSIVE_BOOLS), +LintId::of(excessive_bools::STRUCT_EXCESSIVE_BOOLS), +LintId::of(functions::MUST_USE_CANDIDATE), +LintId::of(functions::TOO_MANY_LINES), +LintId::of(if_not_else::IF_NOT_ELSE), +LintId::of(implicit_hasher::IMPLICIT_HASHER), +LintId::of(implicit_saturating_sub::IMPLICIT_SATURATING_SUB), +LintId::of(inconsistent_struct_constructor::INCONSISTENT_STRUCT_CONSTRUCTOR), +LintId::of(infinite_iter::MAYBE_INFINITE_ITER), +LintId::of(invalid_upcast_comparisons::INVALID_UPCAST_COMPARISONS), +LintId::of(items_after_statements::ITEMS_AFTER_STATEMENTS), +LintId::of(iter_not_returning_iterator::ITER_NOT_RETURNING_ITERATOR), +LintId::of(large_stack_arrays::LARGE_STACK_ARRAYS), +LintId::of(let_underscore::LET_UNDERSCORE_DROP), +LintId::of(literal_representation::LARGE_DIGIT_GROUPS), +LintId::of(literal_representation::UNREADABLE_LITERAL), +LintId::of(loops::EXPLICIT_INTO_ITER_LOOP), +LintId::of(loops::EXPLICIT_ITER_LOOP), +LintId::of(macro_use::MACRO_USE_IMPORTS), +LintId::of(manual_ok_or::MANUAL_OK_OR), +LintId::of(match_on_vec_items::MATCH_ON_VEC_ITEMS), +LintId::of(matches::MATCH_BOOL), +LintId::of(matches::MATCH_SAME_ARMS), +LintId::of(matches::MATCH_WILDCARD_FOR_SINGLE_VARIANTS), +LintId::of(matches::MATCH_WILD_ERR_ARM), +LintId::of(matches::SINGLE_MATCH_ELSE), +LintId::of(methods::CLONED_INSTEAD_OF_COPIED), +LintId::of(methods::FILTER_MAP_NEXT), +LintId::of(methods::FLAT_MAP_OPTION), +LintId::of(methods::FROM_ITER_INSTEAD_OF_COLLECT), +LintId::of(methods::IMPLICIT_CLONE), +LintId::of(methods::INEFFICIENT_TO_STRING), +LintId::of(methods::MAP_FLATTEN), +LintId::of(methods::MAP_UNWRAP_OR), +LintId::of(misc::FLOAT_CMP), +LintId::of(misc::USED_UNDERSCORE_BINDING), +LintId::of(misc_early::UNSEPARATED_LITERAL_SUFFIX), +LintId::of(mut_mut::MUT_MUT), +LintId::of(needless_bitwise_bool::NEEDLESS_BITWISE_BOOL), +LintId::of(needless_borrow::REF_BINDING_TO_REFERENCE), +LintId::of(needless_continue::NEEDLESS_CONTINUE), +LintId::of(needless_for_each::NEEDLESS_FOR_EACH), +LintId::of(needless_pass_by_value::NEEDLESS_PASS_BY_VALUE), +LintId::of(non_expressive_names::MANY_SINGLE_CHAR_NAMES), +LintId::of(non_expressive_names::SIMILAR_NAMES), +LintId::of(pass_by_ref_or_value::LARGE_TYPES_PASSED_BY_VALUE), +LintId::of(pass_by_ref_or_value::TRIVIALLY_COPY_PASS_BY_REF), +LintId::of(ranges::RANGE_MINUS_ONE), +LintId::of(ranges::RANGE_PLUS_ONE), +LintId::of(redundant_else::REDUNDANT_ELSE), +LintId::of(ref_option_ref::REF_OPTION_REF), +LintId::of(semicolon_if_nothing_returned::SEMICOLON_IF_NOTHING_RETURNED), +LintId::of(shadow::SHADOW_UNRELATED), +LintId::of(strings::STRING_ADD_ASSIGN), +LintId::of(trait_bounds::TRAIT_DUPLICATION_IN_BOUNDS), +LintId::of(trait_bounds::TYPE_REPETITION_IN_BOUNDS), +LintId::of(transmute::TRANSMUTE_PTR_TO_PTR), +LintId::of(types::LINKEDLIST), +LintId::of(types::OPTION_OPTION), +LintId::of(unicode::NON_ASCII_LITERAL), +LintId::of(unicode::UNICODE_NOT_NFC), +LintId::of(unit_types::LET_UNIT_VALUE), +LintId::of(unnecessary_wraps::UNNECESSARY_WRAPS), +LintId::of(unnested_or_patterns::UNNESTED_OR_PATTERNS), +LintId::of(unused_async::UNUSED_ASYNC), +LintId::of(unused_self::UNUSED_SELF), +LintId::of(wildcard_imports::ENUM_GLOB_USE), +LintId::of(wildcard_imports::WILDCARD_IMPORTS), +LintId::of(zero_sized_map_values::ZERO_SIZED_MAP_VALUES), +]) \ No newline at end of file diff --git a/clippy_lints/src/lib.register_perf.rs b/clippy_lints/src/lib.register_perf.rs new file mode 100644 index 00000000000..610309dd893 --- /dev/null +++ b/clippy_lints/src/lib.register_perf.rs @@ -0,0 +1,27 @@ +// This file was generated by `cargo dev update_lints`. +// Use that command to update this file and do not edit by hand. +// Manual edits will be overwritten. + +store.register_group(true, "clippy::perf", Some("clippy_perf"), vec![ +LintId::of(entry::MAP_ENTRY), +LintId::of(escape::BOXED_LOCAL), +LintId::of(large_const_arrays::LARGE_CONST_ARRAYS), +LintId::of(large_enum_variant::LARGE_ENUM_VARIANT), +LintId::of(loops::MANUAL_MEMCPY), +LintId::of(loops::NEEDLESS_COLLECT), +LintId::of(methods::EXPECT_FUN_CALL), +LintId::of(methods::EXTEND_WITH_DRAIN), +LintId::of(methods::ITER_NTH), +LintId::of(methods::MANUAL_STR_REPEAT), +LintId::of(methods::OR_FUN_CALL), +LintId::of(methods::SINGLE_CHAR_PATTERN), +LintId::of(misc::CMP_OWNED), +LintId::of(mutex_atomic::MUTEX_ATOMIC), +LintId::of(redundant_clone::REDUNDANT_CLONE), +LintId::of(slow_vector_initialization::SLOW_VECTOR_INITIALIZATION), +LintId::of(stable_sort_primitive::STABLE_SORT_PRIMITIVE), +LintId::of(types::BOX_COLLECTION), +LintId::of(types::REDUNDANT_ALLOCATION), +LintId::of(vec::USELESS_VEC), +LintId::of(vec_init_then_push::VEC_INIT_THEN_PUSH), +]) \ No newline at end of file diff --git a/clippy_lints/src/lib.register_restriction.rs b/clippy_lints/src/lib.register_restriction.rs new file mode 100644 index 00000000000..8f181fe2e78 --- /dev/null +++ b/clippy_lints/src/lib.register_restriction.rs @@ -0,0 +1,64 @@ +// This file was generated by `cargo dev update_lints`. +// Use that command to update this file and do not edit by hand. +// Manual edits will be overwritten. + +store.register_group(true, "clippy::restriction", Some("clippy_restriction"), vec![ +LintId::of(arithmetic::FLOAT_ARITHMETIC), +LintId::of(arithmetic::INTEGER_ARITHMETIC), +LintId::of(as_conversions::AS_CONVERSIONS), +LintId::of(asm_syntax::INLINE_ASM_X86_ATT_SYNTAX), +LintId::of(asm_syntax::INLINE_ASM_X86_INTEL_SYNTAX), +LintId::of(create_dir::CREATE_DIR), +LintId::of(dbg_macro::DBG_MACRO), +LintId::of(default_numeric_fallback::DEFAULT_NUMERIC_FALLBACK), +LintId::of(disallowed_script_idents::DISALLOWED_SCRIPT_IDENTS), +LintId::of(else_if_without_else::ELSE_IF_WITHOUT_ELSE), +LintId::of(exhaustive_items::EXHAUSTIVE_ENUMS), +LintId::of(exhaustive_items::EXHAUSTIVE_STRUCTS), +LintId::of(exit::EXIT), +LintId::of(float_literal::LOSSY_FLOAT_LITERAL), +LintId::of(if_then_some_else_none::IF_THEN_SOME_ELSE_NONE), +LintId::of(implicit_return::IMPLICIT_RETURN), +LintId::of(indexing_slicing::INDEXING_SLICING), +LintId::of(inherent_impl::MULTIPLE_INHERENT_IMPL), +LintId::of(integer_division::INTEGER_DIVISION), +LintId::of(let_underscore::LET_UNDERSCORE_MUST_USE), +LintId::of(literal_representation::DECIMAL_LITERAL_REPRESENTATION), +LintId::of(map_err_ignore::MAP_ERR_IGNORE), +LintId::of(matches::REST_PAT_IN_FULLY_BOUND_STRUCTS), +LintId::of(matches::WILDCARD_ENUM_MATCH_ARM), +LintId::of(mem_forget::MEM_FORGET), +LintId::of(methods::CLONE_ON_REF_PTR), +LintId::of(methods::EXPECT_USED), +LintId::of(methods::FILETYPE_IS_FILE), +LintId::of(methods::GET_UNWRAP), +LintId::of(methods::UNWRAP_USED), +LintId::of(misc::FLOAT_CMP_CONST), +LintId::of(misc_early::UNNEEDED_FIELD_PATTERN), +LintId::of(missing_doc::MISSING_DOCS_IN_PRIVATE_ITEMS), +LintId::of(missing_enforced_import_rename::MISSING_ENFORCED_IMPORT_RENAMES), +LintId::of(missing_inline::MISSING_INLINE_IN_PUBLIC_ITEMS), +LintId::of(module_style::MOD_MODULE_FILES), +LintId::of(module_style::SELF_NAMED_MODULE_FILES), +LintId::of(modulo_arithmetic::MODULO_ARITHMETIC), +LintId::of(panic_in_result_fn::PANIC_IN_RESULT_FN), +LintId::of(panic_unimplemented::PANIC), +LintId::of(panic_unimplemented::TODO), +LintId::of(panic_unimplemented::UNIMPLEMENTED), +LintId::of(panic_unimplemented::UNREACHABLE), +LintId::of(pattern_type_mismatch::PATTERN_TYPE_MISMATCH), +LintId::of(same_name_method::SAME_NAME_METHOD), +LintId::of(shadow::SHADOW_REUSE), +LintId::of(shadow::SHADOW_SAME), +LintId::of(strings::STRING_ADD), +LintId::of(strings::STRING_TO_STRING), +LintId::of(strings::STR_TO_STRING), +LintId::of(types::RC_BUFFER), +LintId::of(types::RC_MUTEX), +LintId::of(unnecessary_self_imports::UNNECESSARY_SELF_IMPORTS), +LintId::of(unwrap_in_result::UNWRAP_IN_RESULT), +LintId::of(verbose_file_reads::VERBOSE_FILE_READS), +LintId::of(write::PRINT_STDERR), +LintId::of(write::PRINT_STDOUT), +LintId::of(write::USE_DEBUG), +]) \ No newline at end of file diff --git a/clippy_lints/src/lib.register_style.rs b/clippy_lints/src/lib.register_style.rs new file mode 100644 index 00000000000..cd563907b77 --- /dev/null +++ b/clippy_lints/src/lib.register_style.rs @@ -0,0 +1,114 @@ +// This file was generated by `cargo dev update_lints`. +// Use that command to update this file and do not edit by hand. +// Manual edits will be overwritten. + +store.register_group(true, "clippy::style", Some("clippy_style"), vec![ +LintId::of(assertions_on_constants::ASSERTIONS_ON_CONSTANTS), +LintId::of(assign_ops::ASSIGN_OP_PATTERN), +LintId::of(blacklisted_name::BLACKLISTED_NAME), +LintId::of(blocks_in_if_conditions::BLOCKS_IN_IF_CONDITIONS), +LintId::of(bool_assert_comparison::BOOL_ASSERT_COMPARISON), +LintId::of(casts::FN_TO_NUMERIC_CAST), +LintId::of(casts::FN_TO_NUMERIC_CAST_WITH_TRUNCATION), +LintId::of(collapsible_if::COLLAPSIBLE_ELSE_IF), +LintId::of(collapsible_if::COLLAPSIBLE_IF), +LintId::of(collapsible_match::COLLAPSIBLE_MATCH), +LintId::of(comparison_chain::COMPARISON_CHAIN), +LintId::of(default::FIELD_REASSIGN_WITH_DEFAULT), +LintId::of(doc::MISSING_SAFETY_DOC), +LintId::of(doc::NEEDLESS_DOCTEST_MAIN), +LintId::of(enum_variants::ENUM_VARIANT_NAMES), +LintId::of(enum_variants::MODULE_INCEPTION), +LintId::of(eq_op::OP_REF), +LintId::of(eta_reduction::REDUNDANT_CLOSURE), +LintId::of(float_literal::EXCESSIVE_PRECISION), +LintId::of(from_over_into::FROM_OVER_INTO), +LintId::of(from_str_radix_10::FROM_STR_RADIX_10), +LintId::of(functions::DOUBLE_MUST_USE), +LintId::of(functions::MUST_USE_UNIT), +LintId::of(functions::RESULT_UNIT_ERR), +LintId::of(if_then_panic::IF_THEN_PANIC), +LintId::of(inherent_to_string::INHERENT_TO_STRING), +LintId::of(len_zero::COMPARISON_TO_EMPTY), +LintId::of(len_zero::LEN_WITHOUT_IS_EMPTY), +LintId::of(len_zero::LEN_ZERO), +LintId::of(literal_representation::INCONSISTENT_DIGIT_GROUPING), +LintId::of(literal_representation::UNUSUAL_BYTE_GROUPINGS), +LintId::of(loops::FOR_KV_MAP), +LintId::of(loops::NEEDLESS_RANGE_LOOP), +LintId::of(loops::SAME_ITEM_PUSH), +LintId::of(loops::WHILE_LET_ON_ITERATOR), +LintId::of(main_recursion::MAIN_RECURSION), +LintId::of(manual_async_fn::MANUAL_ASYNC_FN), +LintId::of(manual_map::MANUAL_MAP), +LintId::of(manual_non_exhaustive::MANUAL_NON_EXHAUSTIVE), +LintId::of(map_clone::MAP_CLONE), +LintId::of(match_result_ok::MATCH_RESULT_OK), +LintId::of(matches::INFALLIBLE_DESTRUCTURING_MATCH), +LintId::of(matches::MATCH_LIKE_MATCHES_MACRO), +LintId::of(matches::MATCH_OVERLAPPING_ARM), +LintId::of(matches::MATCH_REF_PATS), +LintId::of(matches::REDUNDANT_PATTERN_MATCHING), +LintId::of(matches::SINGLE_MATCH), +LintId::of(mem_replace::MEM_REPLACE_OPTION_WITH_NONE), +LintId::of(mem_replace::MEM_REPLACE_WITH_DEFAULT), +LintId::of(methods::BYTES_NTH), +LintId::of(methods::CHARS_LAST_CMP), +LintId::of(methods::CHARS_NEXT_CMP), +LintId::of(methods::INTO_ITER_ON_REF), +LintId::of(methods::ITER_CLONED_COLLECT), +LintId::of(methods::ITER_NEXT_SLICE), +LintId::of(methods::ITER_NTH_ZERO), +LintId::of(methods::ITER_SKIP_NEXT), +LintId::of(methods::MANUAL_SATURATING_ARITHMETIC), +LintId::of(methods::MAP_COLLECT_RESULT_UNIT), +LintId::of(methods::NEW_RET_NO_SELF), +LintId::of(methods::OK_EXPECT), +LintId::of(methods::OPTION_MAP_OR_NONE), +LintId::of(methods::RESULT_MAP_OR_INTO_OPTION), +LintId::of(methods::SHOULD_IMPLEMENT_TRAIT), +LintId::of(methods::SINGLE_CHAR_ADD_STR), +LintId::of(methods::STRING_EXTEND_CHARS), +LintId::of(methods::UNNECESSARY_FOLD), +LintId::of(methods::UNNECESSARY_LAZY_EVALUATIONS), +LintId::of(methods::UNWRAP_OR_ELSE_DEFAULT), +LintId::of(methods::WRONG_SELF_CONVENTION), +LintId::of(misc::TOPLEVEL_REF_ARG), +LintId::of(misc::ZERO_PTR), +LintId::of(misc_early::BUILTIN_TYPE_SHADOW), +LintId::of(misc_early::DOUBLE_NEG), +LintId::of(misc_early::DUPLICATE_UNDERSCORE_ARGUMENT), +LintId::of(misc_early::MIXED_CASE_HEX_LITERALS), +LintId::of(misc_early::REDUNDANT_PATTERN), +LintId::of(mut_mutex_lock::MUT_MUTEX_LOCK), +LintId::of(mut_reference::UNNECESSARY_MUT_PASSED), +LintId::of(needless_borrow::NEEDLESS_BORROW), +LintId::of(neg_multiply::NEG_MULTIPLY), +LintId::of(new_without_default::NEW_WITHOUT_DEFAULT), +LintId::of(non_copy_const::BORROW_INTERIOR_MUTABLE_CONST), +LintId::of(non_copy_const::DECLARE_INTERIOR_MUTABLE_CONST), +LintId::of(non_expressive_names::JUST_UNDERSCORES_AND_DIGITS), +LintId::of(ptr::CMP_NULL), +LintId::of(ptr::PTR_ARG), +LintId::of(ptr_eq::PTR_EQ), +LintId::of(question_mark::QUESTION_MARK), +LintId::of(ranges::MANUAL_RANGE_CONTAINS), +LintId::of(redundant_field_names::REDUNDANT_FIELD_NAMES), +LintId::of(redundant_static_lifetimes::REDUNDANT_STATIC_LIFETIMES), +LintId::of(returns::LET_AND_RETURN), +LintId::of(returns::NEEDLESS_RETURN), +LintId::of(self_named_constructors::SELF_NAMED_CONSTRUCTORS), +LintId::of(single_component_path_imports::SINGLE_COMPONENT_PATH_IMPORTS), +LintId::of(tabs_in_doc_comments::TABS_IN_DOC_COMMENTS), +LintId::of(to_digit_is_some::TO_DIGIT_IS_SOME), +LintId::of(try_err::TRY_ERR), +LintId::of(unsafe_removed_from_name::UNSAFE_REMOVED_FROM_NAME), +LintId::of(unused_unit::UNUSED_UNIT), +LintId::of(upper_case_acronyms::UPPER_CASE_ACRONYMS), +LintId::of(write::PRINTLN_EMPTY_STRING), +LintId::of(write::PRINT_LITERAL), +LintId::of(write::PRINT_WITH_NEWLINE), +LintId::of(write::WRITELN_EMPTY_STRING), +LintId::of(write::WRITE_LITERAL), +LintId::of(write::WRITE_WITH_NEWLINE), +]) \ No newline at end of file diff --git a/clippy_lints/src/lib.register_suspicious.rs b/clippy_lints/src/lib.register_suspicious.rs new file mode 100644 index 00000000000..c424efe69b3 --- /dev/null +++ b/clippy_lints/src/lib.register_suspicious.rs @@ -0,0 +1,20 @@ +// This file was generated by `cargo dev update_lints`. +// Use that command to update this file and do not edit by hand. +// Manual edits will be overwritten. + +store.register_group(true, "clippy::suspicious", Some("clippy_suspicious"), vec![ +LintId::of(assign_ops::MISREFACTORED_ASSIGN_OP), +LintId::of(attrs::BLANKET_CLIPPY_RESTRICTION_LINTS), +LintId::of(eval_order_dependence::EVAL_ORDER_DEPENDENCE), +LintId::of(float_equality_without_abs::FLOAT_EQUALITY_WITHOUT_ABS), +LintId::of(formatting::SUSPICIOUS_ASSIGNMENT_FORMATTING), +LintId::of(formatting::SUSPICIOUS_ELSE_FORMATTING), +LintId::of(formatting::SUSPICIOUS_UNARY_OP_FORMATTING), +LintId::of(loops::EMPTY_LOOP), +LintId::of(loops::FOR_LOOPS_OVER_FALLIBLES), +LintId::of(loops::MUT_RANGE_BOUND), +LintId::of(methods::SUSPICIOUS_MAP), +LintId::of(mut_key::MUTABLE_KEY_TYPE), +LintId::of(suspicious_trait_impl::SUSPICIOUS_ARITHMETIC_IMPL), +LintId::of(suspicious_trait_impl::SUSPICIOUS_OP_ASSIGN_IMPL), +]) \ No newline at end of file diff --git a/clippy_lints/src/lib.rs b/clippy_lints/src/lib.rs index 89724917482..d43ce4a87c6 100644 --- a/clippy_lints/src/lib.rs +++ b/clippy_lints/src/lib.rs @@ -155,236 +155,7 @@ macro_rules! declare_clippy_lint { mod deprecated_lints; mod utils; -// begin lints modules, do not remove this comment, it’s used in `update_lints` -mod absurd_extreme_comparisons; -mod approx_const; -mod arithmetic; -mod as_conversions; -mod asm_syntax; -mod assertions_on_constants; -mod assign_ops; -mod async_yields_async; -mod attrs; -mod await_holding_invalid; -mod bit_mask; -mod blacklisted_name; -mod blocks_in_if_conditions; -mod bool_assert_comparison; -mod booleans; -mod bytecount; -mod cargo_common_metadata; -mod case_sensitive_file_extension_comparisons; -mod casts; -mod checked_conversions; -mod cognitive_complexity; -mod collapsible_if; -mod collapsible_match; -mod comparison_chain; -mod copies; -mod copy_iterator; -mod create_dir; -mod dbg_macro; -mod default; -mod default_numeric_fallback; -mod dereference; -mod derivable_impls; -mod derive; -mod disallowed_method; -mod disallowed_script_idents; -mod disallowed_type; -mod doc; -mod double_comparison; -mod double_parens; -mod drop_forget_ref; -mod duration_subsec; -mod else_if_without_else; -mod empty_enum; -mod entry; -mod enum_clike; -mod enum_variants; -mod eq_op; -mod erasing_op; -mod escape; -mod eta_reduction; -mod eval_order_dependence; -mod excessive_bools; -mod exhaustive_items; -mod exit; -mod explicit_write; -mod fallible_impl_from; -mod feature_name; -mod float_equality_without_abs; -mod float_literal; -mod floating_point_arithmetic; -mod format; -mod formatting; -mod from_over_into; -mod from_str_radix_10; -mod functions; -mod future_not_send; -mod get_last_with_len; -mod identity_op; -mod if_let_mutex; -mod if_not_else; -mod if_then_panic; -mod if_then_some_else_none; -mod implicit_hasher; -mod implicit_return; -mod implicit_saturating_sub; -mod inconsistent_struct_constructor; -mod indexing_slicing; -mod infinite_iter; -mod inherent_impl; -mod inherent_to_string; -mod inline_fn_without_body; -mod int_plus_one; -mod integer_division; -mod invalid_upcast_comparisons; -mod items_after_statements; -mod iter_not_returning_iterator; -mod large_const_arrays; -mod large_enum_variant; -mod large_stack_arrays; -mod len_zero; -mod let_if_seq; -mod let_underscore; -mod lifetimes; -mod literal_representation; -mod loops; -mod macro_use; -mod main_recursion; -mod manual_async_fn; -mod manual_map; -mod manual_non_exhaustive; -mod manual_ok_or; -mod manual_strip; -mod manual_unwrap_or; -mod map_clone; -mod map_err_ignore; -mod map_unit_fn; -mod match_on_vec_items; -mod match_result_ok; -mod matches; -mod mem_discriminant; -mod mem_forget; -mod mem_replace; -mod methods; -mod minmax; -mod misc; -mod misc_early; -mod missing_const_for_fn; -mod missing_doc; -mod missing_enforced_import_rename; -mod missing_inline; -mod module_style; -mod modulo_arithmetic; -mod multiple_crate_versions; -mod mut_key; -mod mut_mut; -mod mut_mutex_lock; -mod mut_reference; -mod mutable_debug_assertion; -mod mutex_atomic; -mod needless_arbitrary_self_type; -mod needless_bitwise_bool; -mod needless_bool; -mod needless_borrow; -mod needless_borrowed_ref; -mod needless_continue; -mod needless_for_each; -mod needless_option_as_deref; -mod needless_pass_by_value; -mod needless_question_mark; -mod needless_update; -mod neg_cmp_op_on_partial_ord; -mod neg_multiply; -mod new_without_default; -mod no_effect; -mod non_copy_const; -mod non_expressive_names; -mod non_octal_unix_permissions; -mod nonstandard_macro_braces; -mod open_options; -mod option_env_unwrap; -mod option_if_let_else; -mod overflow_check_conditional; -mod panic_in_result_fn; -mod panic_unimplemented; -mod partialeq_ne_impl; -mod pass_by_ref_or_value; -mod path_buf_push_overwrite; -mod pattern_type_mismatch; -mod precedence; -mod ptr; -mod ptr_eq; -mod ptr_offset_with_cast; -mod question_mark; -mod ranges; -mod redundant_clone; -mod redundant_closure_call; -mod redundant_else; -mod redundant_field_names; -mod redundant_pub_crate; -mod redundant_slicing; -mod redundant_static_lifetimes; -mod ref_option_ref; -mod reference; -mod regex; -mod repeat_once; -mod returns; -mod same_name_method; -mod self_assignment; -mod self_named_constructors; -mod semicolon_if_nothing_returned; -mod serde_api; -mod shadow; -mod single_component_path_imports; -mod size_of_in_element_count; -mod slow_vector_initialization; -mod stable_sort_primitive; -mod strings; -mod strlen_on_c_strings; -mod suspicious_operation_groupings; -mod suspicious_trait_impl; -mod swap; -mod tabs_in_doc_comments; -mod temporary_assignment; -mod to_digit_is_some; -mod to_string_in_display; -mod trait_bounds; -mod transmute; -mod transmuting_null; -mod try_err; -mod types; -mod undropped_manually_drops; -mod unicode; -mod unit_return_expecting_ord; -mod unit_types; -mod unnamed_address; -mod unnecessary_self_imports; -mod unnecessary_sort_by; -mod unnecessary_wraps; -mod unnested_or_patterns; -mod unsafe_removed_from_name; -mod unused_async; -mod unused_io_amount; -mod unused_self; -mod unused_unit; -mod unwrap; -mod unwrap_in_result; -mod upper_case_acronyms; -mod use_self; -mod useless_conversion; -mod vec; -mod vec_init_then_push; -mod vec_resize_to_zero; -mod verbose_file_reads; -mod wildcard_dependencies; -mod wildcard_imports; -mod write; -mod zero_div_zero; -mod zero_sized_map_values; -// end lints modules, do not remove this comment, it’s used in `update_lints` +include!("lib.mods.rs"); pub use crate::utils::conf::Conf; use crate::utils::conf::TryConf; @@ -438,1401 +209,23 @@ pub fn read_conf(sess: &Session) -> Conf { pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf: &Conf) { register_removed_non_tool_lints(store); - // begin deprecated lints, do not remove this comment, it’s used in `update_lints` - store.register_removed( - "clippy::should_assert_eq", - "`assert!()` will be more flexible with RFC 2011", - ); - store.register_removed( - "clippy::extend_from_slice", - "`.extend_from_slice(_)` is a faster way to extend a Vec by a slice", - ); - store.register_removed( - "clippy::range_step_by_zero", - "`iterator.step_by(0)` panics nowadays", - ); - store.register_removed( - "clippy::unstable_as_slice", - "`Vec::as_slice` has been stabilized in 1.7", - ); - store.register_removed( - "clippy::unstable_as_mut_slice", - "`Vec::as_mut_slice` has been stabilized in 1.7", - ); - store.register_removed( - "clippy::misaligned_transmute", - "this lint has been split into cast_ptr_alignment and transmute_ptr_to_ptr", - ); - store.register_removed( - "clippy::assign_ops", - "using compound assignment operators (e.g., `+=`) is harmless", - ); - store.register_removed( - "clippy::if_let_redundant_pattern_matching", - "this lint has been changed to redundant_pattern_matching", - ); - store.register_removed( - "clippy::unsafe_vector_initialization", - "the replacement suggested by this lint had substantially different behavior", - ); - store.register_removed( - "clippy::unused_collect", - "`collect` has been marked as #[must_use] in rustc and that covers all cases of this lint", - ); - store.register_removed( - "clippy::replace_consts", - "associated-constants `MIN`/`MAX` of integers are preferred to `{min,max}_value()` and module constants", - ); - store.register_removed( - "clippy::regex_macro", - "the regex! macro has been removed from the regex crate in 2018", - ); - store.register_removed( - "clippy::find_map", - "this lint has been replaced by `manual_find_map`, a more specific lint", - ); - store.register_removed( - "clippy::filter_map", - "this lint has been replaced by `manual_filter_map`, a more specific lint", - ); - store.register_removed( - "clippy::pub_enum_variant_names", - "set the `avoid-breaking-exported-api` config option to `false` to enable the `enum_variant_names` lint for public items", - ); - store.register_removed( - "clippy::wrong_pub_self_convention", - "set the `avoid-breaking-exported-api` config option to `false` to enable the `wrong_self_convention` lint for public items", - ); - // end deprecated lints, do not remove this comment, it’s used in `update_lints` - - // begin register lints, do not remove this comment, it’s used in `update_lints` - store.register_lints(&[ - #[cfg(feature = "internal-lints")] - utils::internal_lints::CLIPPY_LINTS_INTERNAL, - #[cfg(feature = "internal-lints")] - utils::internal_lints::COLLAPSIBLE_SPAN_LINT_CALLS, - #[cfg(feature = "internal-lints")] - utils::internal_lints::COMPILER_LINT_FUNCTIONS, - #[cfg(feature = "internal-lints")] - utils::internal_lints::DEFAULT_LINT, - #[cfg(feature = "internal-lints")] - utils::internal_lints::IF_CHAIN_STYLE, - #[cfg(feature = "internal-lints")] - utils::internal_lints::INTERNING_DEFINED_SYMBOL, - #[cfg(feature = "internal-lints")] - utils::internal_lints::INVALID_PATHS, - #[cfg(feature = "internal-lints")] - utils::internal_lints::LINT_WITHOUT_LINT_PASS, - #[cfg(feature = "internal-lints")] - utils::internal_lints::MATCH_TYPE_ON_DIAGNOSTIC_ITEM, - #[cfg(feature = "internal-lints")] - utils::internal_lints::OUTER_EXPN_EXPN_DATA, - #[cfg(feature = "internal-lints")] - utils::internal_lints::PRODUCE_ICE, - #[cfg(feature = "internal-lints")] - utils::internal_lints::UNNECESSARY_SYMBOL_STR, - absurd_extreme_comparisons::ABSURD_EXTREME_COMPARISONS, - approx_const::APPROX_CONSTANT, - arithmetic::FLOAT_ARITHMETIC, - arithmetic::INTEGER_ARITHMETIC, - as_conversions::AS_CONVERSIONS, - asm_syntax::INLINE_ASM_X86_ATT_SYNTAX, - asm_syntax::INLINE_ASM_X86_INTEL_SYNTAX, - assertions_on_constants::ASSERTIONS_ON_CONSTANTS, - assign_ops::ASSIGN_OP_PATTERN, - assign_ops::MISREFACTORED_ASSIGN_OP, - async_yields_async::ASYNC_YIELDS_ASYNC, - attrs::BLANKET_CLIPPY_RESTRICTION_LINTS, - attrs::DEPRECATED_CFG_ATTR, - attrs::DEPRECATED_SEMVER, - attrs::EMPTY_LINE_AFTER_OUTER_ATTR, - attrs::INLINE_ALWAYS, - attrs::MISMATCHED_TARGET_OS, - attrs::USELESS_ATTRIBUTE, - await_holding_invalid::AWAIT_HOLDING_LOCK, - await_holding_invalid::AWAIT_HOLDING_REFCELL_REF, - bit_mask::BAD_BIT_MASK, - bit_mask::INEFFECTIVE_BIT_MASK, - bit_mask::VERBOSE_BIT_MASK, - blacklisted_name::BLACKLISTED_NAME, - blocks_in_if_conditions::BLOCKS_IN_IF_CONDITIONS, - bool_assert_comparison::BOOL_ASSERT_COMPARISON, - booleans::LOGIC_BUG, - booleans::NONMINIMAL_BOOL, - bytecount::NAIVE_BYTECOUNT, - cargo_common_metadata::CARGO_COMMON_METADATA, - case_sensitive_file_extension_comparisons::CASE_SENSITIVE_FILE_EXTENSION_COMPARISONS, - casts::CAST_LOSSLESS, - casts::CAST_POSSIBLE_TRUNCATION, - casts::CAST_POSSIBLE_WRAP, - casts::CAST_PRECISION_LOSS, - casts::CAST_PTR_ALIGNMENT, - casts::CAST_REF_TO_MUT, - casts::CAST_SIGN_LOSS, - casts::CHAR_LIT_AS_U8, - casts::FN_TO_NUMERIC_CAST, - casts::FN_TO_NUMERIC_CAST_WITH_TRUNCATION, - casts::PTR_AS_PTR, - casts::UNNECESSARY_CAST, - checked_conversions::CHECKED_CONVERSIONS, - cognitive_complexity::COGNITIVE_COMPLEXITY, - collapsible_if::COLLAPSIBLE_ELSE_IF, - collapsible_if::COLLAPSIBLE_IF, - collapsible_match::COLLAPSIBLE_MATCH, - comparison_chain::COMPARISON_CHAIN, - copies::BRANCHES_SHARING_CODE, - copies::IFS_SAME_COND, - copies::IF_SAME_THEN_ELSE, - copies::SAME_FUNCTIONS_IN_IF_CONDITION, - copy_iterator::COPY_ITERATOR, - create_dir::CREATE_DIR, - dbg_macro::DBG_MACRO, - default::DEFAULT_TRAIT_ACCESS, - default::FIELD_REASSIGN_WITH_DEFAULT, - default_numeric_fallback::DEFAULT_NUMERIC_FALLBACK, - dereference::EXPLICIT_DEREF_METHODS, - derivable_impls::DERIVABLE_IMPLS, - derive::DERIVE_HASH_XOR_EQ, - derive::DERIVE_ORD_XOR_PARTIAL_ORD, - derive::EXPL_IMPL_CLONE_ON_COPY, - derive::UNSAFE_DERIVE_DESERIALIZE, - disallowed_method::DISALLOWED_METHOD, - disallowed_script_idents::DISALLOWED_SCRIPT_IDENTS, - disallowed_type::DISALLOWED_TYPE, - doc::DOC_MARKDOWN, - doc::MISSING_ERRORS_DOC, - doc::MISSING_PANICS_DOC, - doc::MISSING_SAFETY_DOC, - doc::NEEDLESS_DOCTEST_MAIN, - double_comparison::DOUBLE_COMPARISONS, - double_parens::DOUBLE_PARENS, - drop_forget_ref::DROP_COPY, - drop_forget_ref::DROP_REF, - drop_forget_ref::FORGET_COPY, - drop_forget_ref::FORGET_REF, - duration_subsec::DURATION_SUBSEC, - else_if_without_else::ELSE_IF_WITHOUT_ELSE, - empty_enum::EMPTY_ENUM, - entry::MAP_ENTRY, - enum_clike::ENUM_CLIKE_UNPORTABLE_VARIANT, - enum_variants::ENUM_VARIANT_NAMES, - enum_variants::MODULE_INCEPTION, - enum_variants::MODULE_NAME_REPETITIONS, - eq_op::EQ_OP, - eq_op::OP_REF, - erasing_op::ERASING_OP, - escape::BOXED_LOCAL, - eta_reduction::REDUNDANT_CLOSURE, - eta_reduction::REDUNDANT_CLOSURE_FOR_METHOD_CALLS, - eval_order_dependence::DIVERGING_SUB_EXPRESSION, - eval_order_dependence::EVAL_ORDER_DEPENDENCE, - excessive_bools::FN_PARAMS_EXCESSIVE_BOOLS, - excessive_bools::STRUCT_EXCESSIVE_BOOLS, - exhaustive_items::EXHAUSTIVE_ENUMS, - exhaustive_items::EXHAUSTIVE_STRUCTS, - exit::EXIT, - explicit_write::EXPLICIT_WRITE, - fallible_impl_from::FALLIBLE_IMPL_FROM, - feature_name::NEGATIVE_FEATURE_NAMES, - feature_name::REDUNDANT_FEATURE_NAMES, - float_equality_without_abs::FLOAT_EQUALITY_WITHOUT_ABS, - float_literal::EXCESSIVE_PRECISION, - float_literal::LOSSY_FLOAT_LITERAL, - floating_point_arithmetic::IMPRECISE_FLOPS, - floating_point_arithmetic::SUBOPTIMAL_FLOPS, - format::USELESS_FORMAT, - formatting::POSSIBLE_MISSING_COMMA, - formatting::SUSPICIOUS_ASSIGNMENT_FORMATTING, - formatting::SUSPICIOUS_ELSE_FORMATTING, - formatting::SUSPICIOUS_UNARY_OP_FORMATTING, - from_over_into::FROM_OVER_INTO, - from_str_radix_10::FROM_STR_RADIX_10, - functions::DOUBLE_MUST_USE, - functions::MUST_USE_CANDIDATE, - functions::MUST_USE_UNIT, - functions::NOT_UNSAFE_PTR_ARG_DEREF, - functions::RESULT_UNIT_ERR, - functions::TOO_MANY_ARGUMENTS, - functions::TOO_MANY_LINES, - future_not_send::FUTURE_NOT_SEND, - get_last_with_len::GET_LAST_WITH_LEN, - identity_op::IDENTITY_OP, - if_let_mutex::IF_LET_MUTEX, - if_not_else::IF_NOT_ELSE, - if_then_panic::IF_THEN_PANIC, - if_then_some_else_none::IF_THEN_SOME_ELSE_NONE, - implicit_hasher::IMPLICIT_HASHER, - implicit_return::IMPLICIT_RETURN, - implicit_saturating_sub::IMPLICIT_SATURATING_SUB, - inconsistent_struct_constructor::INCONSISTENT_STRUCT_CONSTRUCTOR, - indexing_slicing::INDEXING_SLICING, - indexing_slicing::OUT_OF_BOUNDS_INDEXING, - infinite_iter::INFINITE_ITER, - infinite_iter::MAYBE_INFINITE_ITER, - inherent_impl::MULTIPLE_INHERENT_IMPL, - inherent_to_string::INHERENT_TO_STRING, - inherent_to_string::INHERENT_TO_STRING_SHADOW_DISPLAY, - inline_fn_without_body::INLINE_FN_WITHOUT_BODY, - int_plus_one::INT_PLUS_ONE, - integer_division::INTEGER_DIVISION, - invalid_upcast_comparisons::INVALID_UPCAST_COMPARISONS, - items_after_statements::ITEMS_AFTER_STATEMENTS, - iter_not_returning_iterator::ITER_NOT_RETURNING_ITERATOR, - large_const_arrays::LARGE_CONST_ARRAYS, - large_enum_variant::LARGE_ENUM_VARIANT, - large_stack_arrays::LARGE_STACK_ARRAYS, - len_zero::COMPARISON_TO_EMPTY, - len_zero::LEN_WITHOUT_IS_EMPTY, - len_zero::LEN_ZERO, - let_if_seq::USELESS_LET_IF_SEQ, - let_underscore::LET_UNDERSCORE_DROP, - let_underscore::LET_UNDERSCORE_LOCK, - let_underscore::LET_UNDERSCORE_MUST_USE, - lifetimes::EXTRA_UNUSED_LIFETIMES, - lifetimes::NEEDLESS_LIFETIMES, - literal_representation::DECIMAL_LITERAL_REPRESENTATION, - literal_representation::INCONSISTENT_DIGIT_GROUPING, - literal_representation::LARGE_DIGIT_GROUPS, - literal_representation::MISTYPED_LITERAL_SUFFIXES, - literal_representation::UNREADABLE_LITERAL, - literal_representation::UNUSUAL_BYTE_GROUPINGS, - loops::EMPTY_LOOP, - loops::EXPLICIT_COUNTER_LOOP, - loops::EXPLICIT_INTO_ITER_LOOP, - loops::EXPLICIT_ITER_LOOP, - loops::FOR_KV_MAP, - loops::FOR_LOOPS_OVER_FALLIBLES, - loops::ITER_NEXT_LOOP, - loops::MANUAL_FLATTEN, - loops::MANUAL_MEMCPY, - loops::MUT_RANGE_BOUND, - loops::NEEDLESS_COLLECT, - loops::NEEDLESS_RANGE_LOOP, - loops::NEVER_LOOP, - loops::SAME_ITEM_PUSH, - loops::SINGLE_ELEMENT_LOOP, - loops::WHILE_IMMUTABLE_CONDITION, - loops::WHILE_LET_LOOP, - loops::WHILE_LET_ON_ITERATOR, - macro_use::MACRO_USE_IMPORTS, - main_recursion::MAIN_RECURSION, - manual_async_fn::MANUAL_ASYNC_FN, - manual_map::MANUAL_MAP, - manual_non_exhaustive::MANUAL_NON_EXHAUSTIVE, - manual_ok_or::MANUAL_OK_OR, - manual_strip::MANUAL_STRIP, - manual_unwrap_or::MANUAL_UNWRAP_OR, - map_clone::MAP_CLONE, - map_err_ignore::MAP_ERR_IGNORE, - map_unit_fn::OPTION_MAP_UNIT_FN, - map_unit_fn::RESULT_MAP_UNIT_FN, - match_on_vec_items::MATCH_ON_VEC_ITEMS, - match_result_ok::MATCH_RESULT_OK, - matches::INFALLIBLE_DESTRUCTURING_MATCH, - matches::MATCH_AS_REF, - matches::MATCH_BOOL, - matches::MATCH_LIKE_MATCHES_MACRO, - matches::MATCH_OVERLAPPING_ARM, - matches::MATCH_REF_PATS, - matches::MATCH_SAME_ARMS, - matches::MATCH_SINGLE_BINDING, - matches::MATCH_WILDCARD_FOR_SINGLE_VARIANTS, - matches::MATCH_WILD_ERR_ARM, - matches::REDUNDANT_PATTERN_MATCHING, - matches::REST_PAT_IN_FULLY_BOUND_STRUCTS, - matches::SINGLE_MATCH, - matches::SINGLE_MATCH_ELSE, - matches::WILDCARD_ENUM_MATCH_ARM, - matches::WILDCARD_IN_OR_PATTERNS, - mem_discriminant::MEM_DISCRIMINANT_NON_ENUM, - mem_forget::MEM_FORGET, - mem_replace::MEM_REPLACE_OPTION_WITH_NONE, - mem_replace::MEM_REPLACE_WITH_DEFAULT, - mem_replace::MEM_REPLACE_WITH_UNINIT, - methods::BIND_INSTEAD_OF_MAP, - methods::BYTES_NTH, - methods::CHARS_LAST_CMP, - methods::CHARS_NEXT_CMP, - methods::CLONED_INSTEAD_OF_COPIED, - methods::CLONE_DOUBLE_REF, - methods::CLONE_ON_COPY, - methods::CLONE_ON_REF_PTR, - methods::EXPECT_FUN_CALL, - methods::EXPECT_USED, - methods::EXTEND_WITH_DRAIN, - methods::FILETYPE_IS_FILE, - methods::FILTER_MAP_IDENTITY, - methods::FILTER_MAP_NEXT, - methods::FILTER_NEXT, - methods::FLAT_MAP_IDENTITY, - methods::FLAT_MAP_OPTION, - methods::FROM_ITER_INSTEAD_OF_COLLECT, - methods::GET_UNWRAP, - methods::IMPLICIT_CLONE, - methods::INEFFICIENT_TO_STRING, - methods::INSPECT_FOR_EACH, - methods::INTO_ITER_ON_REF, - methods::ITERATOR_STEP_BY_ZERO, - methods::ITER_CLONED_COLLECT, - methods::ITER_COUNT, - methods::ITER_NEXT_SLICE, - methods::ITER_NTH, - methods::ITER_NTH_ZERO, - methods::ITER_SKIP_NEXT, - methods::MANUAL_FILTER_MAP, - methods::MANUAL_FIND_MAP, - methods::MANUAL_SATURATING_ARITHMETIC, - methods::MANUAL_SPLIT_ONCE, - methods::MANUAL_STR_REPEAT, - methods::MAP_COLLECT_RESULT_UNIT, - methods::MAP_FLATTEN, - methods::MAP_IDENTITY, - methods::MAP_UNWRAP_OR, - methods::NEW_RET_NO_SELF, - methods::OK_EXPECT, - methods::OPTION_AS_REF_DEREF, - methods::OPTION_FILTER_MAP, - methods::OPTION_MAP_OR_NONE, - methods::OR_FUN_CALL, - methods::RESULT_MAP_OR_INTO_OPTION, - methods::SEARCH_IS_SOME, - methods::SHOULD_IMPLEMENT_TRAIT, - methods::SINGLE_CHAR_ADD_STR, - methods::SINGLE_CHAR_PATTERN, - methods::SKIP_WHILE_NEXT, - methods::STRING_EXTEND_CHARS, - methods::SUSPICIOUS_MAP, - methods::SUSPICIOUS_SPLITN, - methods::UNINIT_ASSUMED_INIT, - methods::UNNECESSARY_FILTER_MAP, - methods::UNNECESSARY_FOLD, - methods::UNNECESSARY_LAZY_EVALUATIONS, - methods::UNWRAP_OR_ELSE_DEFAULT, - methods::UNWRAP_USED, - methods::USELESS_ASREF, - methods::WRONG_SELF_CONVENTION, - methods::ZST_OFFSET, - minmax::MIN_MAX, - misc::CMP_NAN, - misc::CMP_OWNED, - misc::FLOAT_CMP, - misc::FLOAT_CMP_CONST, - misc::MODULO_ONE, - misc::SHORT_CIRCUIT_STATEMENT, - misc::TOPLEVEL_REF_ARG, - misc::USED_UNDERSCORE_BINDING, - misc::ZERO_PTR, - misc_early::BUILTIN_TYPE_SHADOW, - misc_early::DOUBLE_NEG, - misc_early::DUPLICATE_UNDERSCORE_ARGUMENT, - misc_early::MIXED_CASE_HEX_LITERALS, - misc_early::REDUNDANT_PATTERN, - misc_early::UNNEEDED_FIELD_PATTERN, - misc_early::UNNEEDED_WILDCARD_PATTERN, - misc_early::UNSEPARATED_LITERAL_SUFFIX, - misc_early::ZERO_PREFIXED_LITERAL, - missing_const_for_fn::MISSING_CONST_FOR_FN, - missing_doc::MISSING_DOCS_IN_PRIVATE_ITEMS, - missing_enforced_import_rename::MISSING_ENFORCED_IMPORT_RENAMES, - missing_inline::MISSING_INLINE_IN_PUBLIC_ITEMS, - module_style::MOD_MODULE_FILES, - module_style::SELF_NAMED_MODULE_FILES, - modulo_arithmetic::MODULO_ARITHMETIC, - multiple_crate_versions::MULTIPLE_CRATE_VERSIONS, - mut_key::MUTABLE_KEY_TYPE, - mut_mut::MUT_MUT, - mut_mutex_lock::MUT_MUTEX_LOCK, - mut_reference::UNNECESSARY_MUT_PASSED, - mutable_debug_assertion::DEBUG_ASSERT_WITH_MUT_CALL, - mutex_atomic::MUTEX_ATOMIC, - mutex_atomic::MUTEX_INTEGER, - needless_arbitrary_self_type::NEEDLESS_ARBITRARY_SELF_TYPE, - needless_bitwise_bool::NEEDLESS_BITWISE_BOOL, - needless_bool::BOOL_COMPARISON, - needless_bool::NEEDLESS_BOOL, - needless_borrow::NEEDLESS_BORROW, - needless_borrow::REF_BINDING_TO_REFERENCE, - needless_borrowed_ref::NEEDLESS_BORROWED_REFERENCE, - needless_continue::NEEDLESS_CONTINUE, - needless_for_each::NEEDLESS_FOR_EACH, - needless_option_as_deref::NEEDLESS_OPTION_AS_DEREF, - needless_pass_by_value::NEEDLESS_PASS_BY_VALUE, - needless_question_mark::NEEDLESS_QUESTION_MARK, - needless_update::NEEDLESS_UPDATE, - neg_cmp_op_on_partial_ord::NEG_CMP_OP_ON_PARTIAL_ORD, - neg_multiply::NEG_MULTIPLY, - new_without_default::NEW_WITHOUT_DEFAULT, - no_effect::NO_EFFECT, - no_effect::UNNECESSARY_OPERATION, - non_copy_const::BORROW_INTERIOR_MUTABLE_CONST, - non_copy_const::DECLARE_INTERIOR_MUTABLE_CONST, - non_expressive_names::JUST_UNDERSCORES_AND_DIGITS, - non_expressive_names::MANY_SINGLE_CHAR_NAMES, - non_expressive_names::SIMILAR_NAMES, - non_octal_unix_permissions::NON_OCTAL_UNIX_PERMISSIONS, - nonstandard_macro_braces::NONSTANDARD_MACRO_BRACES, - open_options::NONSENSICAL_OPEN_OPTIONS, - option_env_unwrap::OPTION_ENV_UNWRAP, - option_if_let_else::OPTION_IF_LET_ELSE, - overflow_check_conditional::OVERFLOW_CHECK_CONDITIONAL, - panic_in_result_fn::PANIC_IN_RESULT_FN, - panic_unimplemented::PANIC, - panic_unimplemented::TODO, - panic_unimplemented::UNIMPLEMENTED, - panic_unimplemented::UNREACHABLE, - partialeq_ne_impl::PARTIALEQ_NE_IMPL, - pass_by_ref_or_value::LARGE_TYPES_PASSED_BY_VALUE, - pass_by_ref_or_value::TRIVIALLY_COPY_PASS_BY_REF, - path_buf_push_overwrite::PATH_BUF_PUSH_OVERWRITE, - pattern_type_mismatch::PATTERN_TYPE_MISMATCH, - precedence::PRECEDENCE, - ptr::CMP_NULL, - ptr::INVALID_NULL_PTR_USAGE, - ptr::MUT_FROM_REF, - ptr::PTR_ARG, - ptr_eq::PTR_EQ, - ptr_offset_with_cast::PTR_OFFSET_WITH_CAST, - question_mark::QUESTION_MARK, - ranges::MANUAL_RANGE_CONTAINS, - ranges::RANGE_MINUS_ONE, - ranges::RANGE_PLUS_ONE, - ranges::RANGE_ZIP_WITH_LEN, - ranges::REVERSED_EMPTY_RANGES, - redundant_clone::REDUNDANT_CLONE, - redundant_closure_call::REDUNDANT_CLOSURE_CALL, - redundant_else::REDUNDANT_ELSE, - redundant_field_names::REDUNDANT_FIELD_NAMES, - redundant_pub_crate::REDUNDANT_PUB_CRATE, - redundant_slicing::REDUNDANT_SLICING, - redundant_static_lifetimes::REDUNDANT_STATIC_LIFETIMES, - ref_option_ref::REF_OPTION_REF, - reference::DEREF_ADDROF, - reference::REF_IN_DEREF, - regex::INVALID_REGEX, - regex::TRIVIAL_REGEX, - repeat_once::REPEAT_ONCE, - returns::LET_AND_RETURN, - returns::NEEDLESS_RETURN, - same_name_method::SAME_NAME_METHOD, - self_assignment::SELF_ASSIGNMENT, - self_named_constructors::SELF_NAMED_CONSTRUCTORS, - semicolon_if_nothing_returned::SEMICOLON_IF_NOTHING_RETURNED, - serde_api::SERDE_API_MISUSE, - shadow::SHADOW_REUSE, - shadow::SHADOW_SAME, - shadow::SHADOW_UNRELATED, - single_component_path_imports::SINGLE_COMPONENT_PATH_IMPORTS, - size_of_in_element_count::SIZE_OF_IN_ELEMENT_COUNT, - slow_vector_initialization::SLOW_VECTOR_INITIALIZATION, - stable_sort_primitive::STABLE_SORT_PRIMITIVE, - strings::STRING_ADD, - strings::STRING_ADD_ASSIGN, - strings::STRING_FROM_UTF8_AS_BYTES, - strings::STRING_LIT_AS_BYTES, - strings::STRING_TO_STRING, - strings::STR_TO_STRING, - strlen_on_c_strings::STRLEN_ON_C_STRINGS, - suspicious_operation_groupings::SUSPICIOUS_OPERATION_GROUPINGS, - suspicious_trait_impl::SUSPICIOUS_ARITHMETIC_IMPL, - suspicious_trait_impl::SUSPICIOUS_OP_ASSIGN_IMPL, - swap::ALMOST_SWAPPED, - swap::MANUAL_SWAP, - tabs_in_doc_comments::TABS_IN_DOC_COMMENTS, - temporary_assignment::TEMPORARY_ASSIGNMENT, - to_digit_is_some::TO_DIGIT_IS_SOME, - to_string_in_display::TO_STRING_IN_DISPLAY, - trait_bounds::TRAIT_DUPLICATION_IN_BOUNDS, - trait_bounds::TYPE_REPETITION_IN_BOUNDS, - transmute::CROSSPOINTER_TRANSMUTE, - transmute::TRANSMUTES_EXPRESSIBLE_AS_PTR_CASTS, - transmute::TRANSMUTE_BYTES_TO_STR, - transmute::TRANSMUTE_FLOAT_TO_INT, - transmute::TRANSMUTE_INT_TO_BOOL, - transmute::TRANSMUTE_INT_TO_CHAR, - transmute::TRANSMUTE_INT_TO_FLOAT, - transmute::TRANSMUTE_PTR_TO_PTR, - transmute::TRANSMUTE_PTR_TO_REF, - transmute::UNSOUND_COLLECTION_TRANSMUTE, - transmute::USELESS_TRANSMUTE, - transmute::WRONG_TRANSMUTE, - transmuting_null::TRANSMUTING_NULL, - try_err::TRY_ERR, - types::BORROWED_BOX, - types::BOX_COLLECTION, - types::LINKEDLIST, - types::OPTION_OPTION, - types::RC_BUFFER, - types::RC_MUTEX, - types::REDUNDANT_ALLOCATION, - types::TYPE_COMPLEXITY, - types::VEC_BOX, - undropped_manually_drops::UNDROPPED_MANUALLY_DROPS, - unicode::INVISIBLE_CHARACTERS, - unicode::NON_ASCII_LITERAL, - unicode::UNICODE_NOT_NFC, - unit_return_expecting_ord::UNIT_RETURN_EXPECTING_ORD, - unit_types::LET_UNIT_VALUE, - unit_types::UNIT_ARG, - unit_types::UNIT_CMP, - unnamed_address::FN_ADDRESS_COMPARISONS, - unnamed_address::VTABLE_ADDRESS_COMPARISONS, - unnecessary_self_imports::UNNECESSARY_SELF_IMPORTS, - unnecessary_sort_by::UNNECESSARY_SORT_BY, - unnecessary_wraps::UNNECESSARY_WRAPS, - unnested_or_patterns::UNNESTED_OR_PATTERNS, - unsafe_removed_from_name::UNSAFE_REMOVED_FROM_NAME, - unused_async::UNUSED_ASYNC, - unused_io_amount::UNUSED_IO_AMOUNT, - unused_self::UNUSED_SELF, - unused_unit::UNUSED_UNIT, - unwrap::PANICKING_UNWRAP, - unwrap::UNNECESSARY_UNWRAP, - unwrap_in_result::UNWRAP_IN_RESULT, - upper_case_acronyms::UPPER_CASE_ACRONYMS, - use_self::USE_SELF, - useless_conversion::USELESS_CONVERSION, - vec::USELESS_VEC, - vec_init_then_push::VEC_INIT_THEN_PUSH, - vec_resize_to_zero::VEC_RESIZE_TO_ZERO, - verbose_file_reads::VERBOSE_FILE_READS, - wildcard_dependencies::WILDCARD_DEPENDENCIES, - wildcard_imports::ENUM_GLOB_USE, - wildcard_imports::WILDCARD_IMPORTS, - write::PRINTLN_EMPTY_STRING, - write::PRINT_LITERAL, - write::PRINT_STDERR, - write::PRINT_STDOUT, - write::PRINT_WITH_NEWLINE, - write::USE_DEBUG, - write::WRITELN_EMPTY_STRING, - write::WRITE_LITERAL, - write::WRITE_WITH_NEWLINE, - zero_div_zero::ZERO_DIVIDED_BY_ZERO, - zero_sized_map_values::ZERO_SIZED_MAP_VALUES, - ]); - // end register lints, do not remove this comment, it’s used in `update_lints` + include!("lib.deprecated.rs"); - store.register_group(true, "clippy::restriction", Some("clippy_restriction"), vec![ - LintId::of(arithmetic::FLOAT_ARITHMETIC), - LintId::of(arithmetic::INTEGER_ARITHMETIC), - LintId::of(as_conversions::AS_CONVERSIONS), - LintId::of(asm_syntax::INLINE_ASM_X86_ATT_SYNTAX), - LintId::of(asm_syntax::INLINE_ASM_X86_INTEL_SYNTAX), - LintId::of(create_dir::CREATE_DIR), - LintId::of(dbg_macro::DBG_MACRO), - LintId::of(default_numeric_fallback::DEFAULT_NUMERIC_FALLBACK), - LintId::of(disallowed_script_idents::DISALLOWED_SCRIPT_IDENTS), - LintId::of(else_if_without_else::ELSE_IF_WITHOUT_ELSE), - LintId::of(exhaustive_items::EXHAUSTIVE_ENUMS), - LintId::of(exhaustive_items::EXHAUSTIVE_STRUCTS), - LintId::of(exit::EXIT), - LintId::of(float_literal::LOSSY_FLOAT_LITERAL), - LintId::of(if_then_some_else_none::IF_THEN_SOME_ELSE_NONE), - LintId::of(implicit_return::IMPLICIT_RETURN), - LintId::of(indexing_slicing::INDEXING_SLICING), - LintId::of(inherent_impl::MULTIPLE_INHERENT_IMPL), - LintId::of(integer_division::INTEGER_DIVISION), - LintId::of(let_underscore::LET_UNDERSCORE_MUST_USE), - LintId::of(literal_representation::DECIMAL_LITERAL_REPRESENTATION), - LintId::of(map_err_ignore::MAP_ERR_IGNORE), - LintId::of(matches::REST_PAT_IN_FULLY_BOUND_STRUCTS), - LintId::of(matches::WILDCARD_ENUM_MATCH_ARM), - LintId::of(mem_forget::MEM_FORGET), - LintId::of(methods::CLONE_ON_REF_PTR), - LintId::of(methods::EXPECT_USED), - LintId::of(methods::FILETYPE_IS_FILE), - LintId::of(methods::GET_UNWRAP), - LintId::of(methods::UNWRAP_USED), - LintId::of(misc::FLOAT_CMP_CONST), - LintId::of(misc_early::UNNEEDED_FIELD_PATTERN), - LintId::of(missing_doc::MISSING_DOCS_IN_PRIVATE_ITEMS), - LintId::of(missing_enforced_import_rename::MISSING_ENFORCED_IMPORT_RENAMES), - LintId::of(missing_inline::MISSING_INLINE_IN_PUBLIC_ITEMS), - LintId::of(module_style::MOD_MODULE_FILES), - LintId::of(module_style::SELF_NAMED_MODULE_FILES), - LintId::of(modulo_arithmetic::MODULO_ARITHMETIC), - LintId::of(panic_in_result_fn::PANIC_IN_RESULT_FN), - LintId::of(panic_unimplemented::PANIC), - LintId::of(panic_unimplemented::TODO), - LintId::of(panic_unimplemented::UNIMPLEMENTED), - LintId::of(panic_unimplemented::UNREACHABLE), - LintId::of(pattern_type_mismatch::PATTERN_TYPE_MISMATCH), - LintId::of(same_name_method::SAME_NAME_METHOD), - LintId::of(shadow::SHADOW_REUSE), - LintId::of(shadow::SHADOW_SAME), - LintId::of(strings::STRING_ADD), - LintId::of(strings::STRING_TO_STRING), - LintId::of(strings::STR_TO_STRING), - LintId::of(types::RC_BUFFER), - LintId::of(types::RC_MUTEX), - LintId::of(unnecessary_self_imports::UNNECESSARY_SELF_IMPORTS), - LintId::of(unwrap_in_result::UNWRAP_IN_RESULT), - LintId::of(verbose_file_reads::VERBOSE_FILE_READS), - LintId::of(write::PRINT_STDERR), - LintId::of(write::PRINT_STDOUT), - LintId::of(write::USE_DEBUG), - ]); - - store.register_group(true, "clippy::pedantic", Some("clippy_pedantic"), vec![ - LintId::of(attrs::INLINE_ALWAYS), - LintId::of(await_holding_invalid::AWAIT_HOLDING_LOCK), - LintId::of(await_holding_invalid::AWAIT_HOLDING_REFCELL_REF), - LintId::of(bit_mask::VERBOSE_BIT_MASK), - LintId::of(bytecount::NAIVE_BYTECOUNT), - LintId::of(case_sensitive_file_extension_comparisons::CASE_SENSITIVE_FILE_EXTENSION_COMPARISONS), - LintId::of(casts::CAST_LOSSLESS), - LintId::of(casts::CAST_POSSIBLE_TRUNCATION), - LintId::of(casts::CAST_POSSIBLE_WRAP), - LintId::of(casts::CAST_PRECISION_LOSS), - LintId::of(casts::CAST_PTR_ALIGNMENT), - LintId::of(casts::CAST_SIGN_LOSS), - LintId::of(casts::PTR_AS_PTR), - LintId::of(checked_conversions::CHECKED_CONVERSIONS), - LintId::of(copies::SAME_FUNCTIONS_IN_IF_CONDITION), - LintId::of(copy_iterator::COPY_ITERATOR), - LintId::of(default::DEFAULT_TRAIT_ACCESS), - LintId::of(dereference::EXPLICIT_DEREF_METHODS), - LintId::of(derive::EXPL_IMPL_CLONE_ON_COPY), - LintId::of(derive::UNSAFE_DERIVE_DESERIALIZE), - LintId::of(doc::DOC_MARKDOWN), - LintId::of(doc::MISSING_ERRORS_DOC), - LintId::of(doc::MISSING_PANICS_DOC), - LintId::of(empty_enum::EMPTY_ENUM), - LintId::of(enum_variants::MODULE_NAME_REPETITIONS), - LintId::of(eta_reduction::REDUNDANT_CLOSURE_FOR_METHOD_CALLS), - LintId::of(excessive_bools::FN_PARAMS_EXCESSIVE_BOOLS), - LintId::of(excessive_bools::STRUCT_EXCESSIVE_BOOLS), - LintId::of(functions::MUST_USE_CANDIDATE), - LintId::of(functions::TOO_MANY_LINES), - LintId::of(if_not_else::IF_NOT_ELSE), - LintId::of(implicit_hasher::IMPLICIT_HASHER), - LintId::of(implicit_saturating_sub::IMPLICIT_SATURATING_SUB), - LintId::of(inconsistent_struct_constructor::INCONSISTENT_STRUCT_CONSTRUCTOR), - LintId::of(infinite_iter::MAYBE_INFINITE_ITER), - LintId::of(invalid_upcast_comparisons::INVALID_UPCAST_COMPARISONS), - LintId::of(items_after_statements::ITEMS_AFTER_STATEMENTS), - LintId::of(iter_not_returning_iterator::ITER_NOT_RETURNING_ITERATOR), - LintId::of(large_stack_arrays::LARGE_STACK_ARRAYS), - LintId::of(let_underscore::LET_UNDERSCORE_DROP), - LintId::of(literal_representation::LARGE_DIGIT_GROUPS), - LintId::of(literal_representation::UNREADABLE_LITERAL), - LintId::of(loops::EXPLICIT_INTO_ITER_LOOP), - LintId::of(loops::EXPLICIT_ITER_LOOP), - LintId::of(macro_use::MACRO_USE_IMPORTS), - LintId::of(manual_ok_or::MANUAL_OK_OR), - LintId::of(match_on_vec_items::MATCH_ON_VEC_ITEMS), - LintId::of(matches::MATCH_BOOL), - LintId::of(matches::MATCH_SAME_ARMS), - LintId::of(matches::MATCH_WILDCARD_FOR_SINGLE_VARIANTS), - LintId::of(matches::MATCH_WILD_ERR_ARM), - LintId::of(matches::SINGLE_MATCH_ELSE), - LintId::of(methods::CLONED_INSTEAD_OF_COPIED), - LintId::of(methods::FILTER_MAP_NEXT), - LintId::of(methods::FLAT_MAP_OPTION), - LintId::of(methods::FROM_ITER_INSTEAD_OF_COLLECT), - LintId::of(methods::IMPLICIT_CLONE), - LintId::of(methods::INEFFICIENT_TO_STRING), - LintId::of(methods::MAP_FLATTEN), - LintId::of(methods::MAP_UNWRAP_OR), - LintId::of(misc::FLOAT_CMP), - LintId::of(misc::USED_UNDERSCORE_BINDING), - LintId::of(misc_early::UNSEPARATED_LITERAL_SUFFIX), - LintId::of(mut_mut::MUT_MUT), - LintId::of(needless_bitwise_bool::NEEDLESS_BITWISE_BOOL), - LintId::of(needless_borrow::REF_BINDING_TO_REFERENCE), - LintId::of(needless_continue::NEEDLESS_CONTINUE), - LintId::of(needless_for_each::NEEDLESS_FOR_EACH), - LintId::of(needless_pass_by_value::NEEDLESS_PASS_BY_VALUE), - LintId::of(non_expressive_names::MANY_SINGLE_CHAR_NAMES), - LintId::of(non_expressive_names::SIMILAR_NAMES), - LintId::of(pass_by_ref_or_value::LARGE_TYPES_PASSED_BY_VALUE), - LintId::of(pass_by_ref_or_value::TRIVIALLY_COPY_PASS_BY_REF), - LintId::of(ranges::RANGE_MINUS_ONE), - LintId::of(ranges::RANGE_PLUS_ONE), - LintId::of(redundant_else::REDUNDANT_ELSE), - LintId::of(ref_option_ref::REF_OPTION_REF), - LintId::of(semicolon_if_nothing_returned::SEMICOLON_IF_NOTHING_RETURNED), - LintId::of(shadow::SHADOW_UNRELATED), - LintId::of(strings::STRING_ADD_ASSIGN), - LintId::of(trait_bounds::TRAIT_DUPLICATION_IN_BOUNDS), - LintId::of(trait_bounds::TYPE_REPETITION_IN_BOUNDS), - LintId::of(transmute::TRANSMUTE_PTR_TO_PTR), - LintId::of(types::LINKEDLIST), - LintId::of(types::OPTION_OPTION), - LintId::of(unicode::NON_ASCII_LITERAL), - LintId::of(unicode::UNICODE_NOT_NFC), - LintId::of(unit_types::LET_UNIT_VALUE), - LintId::of(unnecessary_wraps::UNNECESSARY_WRAPS), - LintId::of(unnested_or_patterns::UNNESTED_OR_PATTERNS), - LintId::of(unused_async::UNUSED_ASYNC), - LintId::of(unused_self::UNUSED_SELF), - LintId::of(wildcard_imports::ENUM_GLOB_USE), - LintId::of(wildcard_imports::WILDCARD_IMPORTS), - LintId::of(zero_sized_map_values::ZERO_SIZED_MAP_VALUES), - ]); + include!("lib.register_lints.rs"); + include!("lib.register_restriction.rs"); + include!("lib.register_pedantic.rs"); #[cfg(feature = "internal-lints")] - store.register_group(true, "clippy::internal", Some("clippy_internal"), vec![ - LintId::of(utils::internal_lints::CLIPPY_LINTS_INTERNAL), - LintId::of(utils::internal_lints::COLLAPSIBLE_SPAN_LINT_CALLS), - LintId::of(utils::internal_lints::COMPILER_LINT_FUNCTIONS), - LintId::of(utils::internal_lints::DEFAULT_LINT), - LintId::of(utils::internal_lints::IF_CHAIN_STYLE), - LintId::of(utils::internal_lints::INTERNING_DEFINED_SYMBOL), - LintId::of(utils::internal_lints::INVALID_PATHS), - LintId::of(utils::internal_lints::LINT_WITHOUT_LINT_PASS), - LintId::of(utils::internal_lints::MATCH_TYPE_ON_DIAGNOSTIC_ITEM), - LintId::of(utils::internal_lints::OUTER_EXPN_EXPN_DATA), - LintId::of(utils::internal_lints::PRODUCE_ICE), - LintId::of(utils::internal_lints::UNNECESSARY_SYMBOL_STR), - ]); - - store.register_group(true, "clippy::all", Some("clippy"), vec![ - LintId::of(absurd_extreme_comparisons::ABSURD_EXTREME_COMPARISONS), - LintId::of(approx_const::APPROX_CONSTANT), - LintId::of(assertions_on_constants::ASSERTIONS_ON_CONSTANTS), - LintId::of(assign_ops::ASSIGN_OP_PATTERN), - LintId::of(assign_ops::MISREFACTORED_ASSIGN_OP), - LintId::of(async_yields_async::ASYNC_YIELDS_ASYNC), - LintId::of(attrs::BLANKET_CLIPPY_RESTRICTION_LINTS), - LintId::of(attrs::DEPRECATED_CFG_ATTR), - LintId::of(attrs::DEPRECATED_SEMVER), - LintId::of(attrs::MISMATCHED_TARGET_OS), - LintId::of(attrs::USELESS_ATTRIBUTE), - LintId::of(bit_mask::BAD_BIT_MASK), - LintId::of(bit_mask::INEFFECTIVE_BIT_MASK), - LintId::of(blacklisted_name::BLACKLISTED_NAME), - LintId::of(blocks_in_if_conditions::BLOCKS_IN_IF_CONDITIONS), - LintId::of(bool_assert_comparison::BOOL_ASSERT_COMPARISON), - LintId::of(booleans::LOGIC_BUG), - LintId::of(booleans::NONMINIMAL_BOOL), - LintId::of(casts::CAST_REF_TO_MUT), - LintId::of(casts::CHAR_LIT_AS_U8), - LintId::of(casts::FN_TO_NUMERIC_CAST), - LintId::of(casts::FN_TO_NUMERIC_CAST_WITH_TRUNCATION), - LintId::of(casts::UNNECESSARY_CAST), - LintId::of(collapsible_if::COLLAPSIBLE_ELSE_IF), - LintId::of(collapsible_if::COLLAPSIBLE_IF), - LintId::of(collapsible_match::COLLAPSIBLE_MATCH), - LintId::of(comparison_chain::COMPARISON_CHAIN), - LintId::of(copies::IFS_SAME_COND), - LintId::of(copies::IF_SAME_THEN_ELSE), - LintId::of(default::FIELD_REASSIGN_WITH_DEFAULT), - LintId::of(derivable_impls::DERIVABLE_IMPLS), - LintId::of(derive::DERIVE_HASH_XOR_EQ), - LintId::of(derive::DERIVE_ORD_XOR_PARTIAL_ORD), - LintId::of(doc::MISSING_SAFETY_DOC), - LintId::of(doc::NEEDLESS_DOCTEST_MAIN), - LintId::of(double_comparison::DOUBLE_COMPARISONS), - LintId::of(double_parens::DOUBLE_PARENS), - LintId::of(drop_forget_ref::DROP_COPY), - LintId::of(drop_forget_ref::DROP_REF), - LintId::of(drop_forget_ref::FORGET_COPY), - LintId::of(drop_forget_ref::FORGET_REF), - LintId::of(duration_subsec::DURATION_SUBSEC), - LintId::of(entry::MAP_ENTRY), - LintId::of(enum_clike::ENUM_CLIKE_UNPORTABLE_VARIANT), - LintId::of(enum_variants::ENUM_VARIANT_NAMES), - LintId::of(enum_variants::MODULE_INCEPTION), - LintId::of(eq_op::EQ_OP), - LintId::of(eq_op::OP_REF), - LintId::of(erasing_op::ERASING_OP), - LintId::of(escape::BOXED_LOCAL), - LintId::of(eta_reduction::REDUNDANT_CLOSURE), - LintId::of(eval_order_dependence::DIVERGING_SUB_EXPRESSION), - LintId::of(eval_order_dependence::EVAL_ORDER_DEPENDENCE), - LintId::of(explicit_write::EXPLICIT_WRITE), - LintId::of(float_equality_without_abs::FLOAT_EQUALITY_WITHOUT_ABS), - LintId::of(float_literal::EXCESSIVE_PRECISION), - LintId::of(format::USELESS_FORMAT), - LintId::of(formatting::POSSIBLE_MISSING_COMMA), - LintId::of(formatting::SUSPICIOUS_ASSIGNMENT_FORMATTING), - LintId::of(formatting::SUSPICIOUS_ELSE_FORMATTING), - LintId::of(formatting::SUSPICIOUS_UNARY_OP_FORMATTING), - LintId::of(from_over_into::FROM_OVER_INTO), - LintId::of(from_str_radix_10::FROM_STR_RADIX_10), - LintId::of(functions::DOUBLE_MUST_USE), - LintId::of(functions::MUST_USE_UNIT), - LintId::of(functions::NOT_UNSAFE_PTR_ARG_DEREF), - LintId::of(functions::RESULT_UNIT_ERR), - LintId::of(functions::TOO_MANY_ARGUMENTS), - LintId::of(get_last_with_len::GET_LAST_WITH_LEN), - LintId::of(identity_op::IDENTITY_OP), - LintId::of(if_let_mutex::IF_LET_MUTEX), - LintId::of(if_then_panic::IF_THEN_PANIC), - LintId::of(indexing_slicing::OUT_OF_BOUNDS_INDEXING), - LintId::of(infinite_iter::INFINITE_ITER), - LintId::of(inherent_to_string::INHERENT_TO_STRING), - LintId::of(inherent_to_string::INHERENT_TO_STRING_SHADOW_DISPLAY), - LintId::of(inline_fn_without_body::INLINE_FN_WITHOUT_BODY), - LintId::of(int_plus_one::INT_PLUS_ONE), - LintId::of(large_const_arrays::LARGE_CONST_ARRAYS), - LintId::of(large_enum_variant::LARGE_ENUM_VARIANT), - LintId::of(len_zero::COMPARISON_TO_EMPTY), - LintId::of(len_zero::LEN_WITHOUT_IS_EMPTY), - LintId::of(len_zero::LEN_ZERO), - LintId::of(let_underscore::LET_UNDERSCORE_LOCK), - LintId::of(lifetimes::EXTRA_UNUSED_LIFETIMES), - LintId::of(lifetimes::NEEDLESS_LIFETIMES), - LintId::of(literal_representation::INCONSISTENT_DIGIT_GROUPING), - LintId::of(literal_representation::MISTYPED_LITERAL_SUFFIXES), - LintId::of(literal_representation::UNUSUAL_BYTE_GROUPINGS), - LintId::of(loops::EMPTY_LOOP), - LintId::of(loops::EXPLICIT_COUNTER_LOOP), - LintId::of(loops::FOR_KV_MAP), - LintId::of(loops::FOR_LOOPS_OVER_FALLIBLES), - LintId::of(loops::ITER_NEXT_LOOP), - LintId::of(loops::MANUAL_FLATTEN), - LintId::of(loops::MANUAL_MEMCPY), - LintId::of(loops::MUT_RANGE_BOUND), - LintId::of(loops::NEEDLESS_COLLECT), - LintId::of(loops::NEEDLESS_RANGE_LOOP), - LintId::of(loops::NEVER_LOOP), - LintId::of(loops::SAME_ITEM_PUSH), - LintId::of(loops::SINGLE_ELEMENT_LOOP), - LintId::of(loops::WHILE_IMMUTABLE_CONDITION), - LintId::of(loops::WHILE_LET_LOOP), - LintId::of(loops::WHILE_LET_ON_ITERATOR), - LintId::of(main_recursion::MAIN_RECURSION), - LintId::of(manual_async_fn::MANUAL_ASYNC_FN), - LintId::of(manual_map::MANUAL_MAP), - LintId::of(manual_non_exhaustive::MANUAL_NON_EXHAUSTIVE), - LintId::of(manual_strip::MANUAL_STRIP), - LintId::of(manual_unwrap_or::MANUAL_UNWRAP_OR), - LintId::of(map_clone::MAP_CLONE), - LintId::of(map_unit_fn::OPTION_MAP_UNIT_FN), - LintId::of(map_unit_fn::RESULT_MAP_UNIT_FN), - LintId::of(match_result_ok::MATCH_RESULT_OK), - LintId::of(matches::INFALLIBLE_DESTRUCTURING_MATCH), - LintId::of(matches::MATCH_AS_REF), - LintId::of(matches::MATCH_LIKE_MATCHES_MACRO), - LintId::of(matches::MATCH_OVERLAPPING_ARM), - LintId::of(matches::MATCH_REF_PATS), - LintId::of(matches::MATCH_SINGLE_BINDING), - LintId::of(matches::REDUNDANT_PATTERN_MATCHING), - LintId::of(matches::SINGLE_MATCH), - LintId::of(matches::WILDCARD_IN_OR_PATTERNS), - LintId::of(mem_discriminant::MEM_DISCRIMINANT_NON_ENUM), - LintId::of(mem_replace::MEM_REPLACE_OPTION_WITH_NONE), - LintId::of(mem_replace::MEM_REPLACE_WITH_DEFAULT), - LintId::of(mem_replace::MEM_REPLACE_WITH_UNINIT), - LintId::of(methods::BIND_INSTEAD_OF_MAP), - LintId::of(methods::BYTES_NTH), - LintId::of(methods::CHARS_LAST_CMP), - LintId::of(methods::CHARS_NEXT_CMP), - LintId::of(methods::CLONE_DOUBLE_REF), - LintId::of(methods::CLONE_ON_COPY), - LintId::of(methods::EXPECT_FUN_CALL), - LintId::of(methods::EXTEND_WITH_DRAIN), - LintId::of(methods::FILTER_MAP_IDENTITY), - LintId::of(methods::FILTER_NEXT), - LintId::of(methods::FLAT_MAP_IDENTITY), - LintId::of(methods::INSPECT_FOR_EACH), - LintId::of(methods::INTO_ITER_ON_REF), - LintId::of(methods::ITERATOR_STEP_BY_ZERO), - LintId::of(methods::ITER_CLONED_COLLECT), - LintId::of(methods::ITER_COUNT), - LintId::of(methods::ITER_NEXT_SLICE), - LintId::of(methods::ITER_NTH), - LintId::of(methods::ITER_NTH_ZERO), - LintId::of(methods::ITER_SKIP_NEXT), - LintId::of(methods::MANUAL_FILTER_MAP), - LintId::of(methods::MANUAL_FIND_MAP), - LintId::of(methods::MANUAL_SATURATING_ARITHMETIC), - LintId::of(methods::MANUAL_SPLIT_ONCE), - LintId::of(methods::MANUAL_STR_REPEAT), - LintId::of(methods::MAP_COLLECT_RESULT_UNIT), - LintId::of(methods::MAP_IDENTITY), - LintId::of(methods::NEW_RET_NO_SELF), - LintId::of(methods::OK_EXPECT), - LintId::of(methods::OPTION_AS_REF_DEREF), - LintId::of(methods::OPTION_FILTER_MAP), - LintId::of(methods::OPTION_MAP_OR_NONE), - LintId::of(methods::OR_FUN_CALL), - LintId::of(methods::RESULT_MAP_OR_INTO_OPTION), - LintId::of(methods::SEARCH_IS_SOME), - LintId::of(methods::SHOULD_IMPLEMENT_TRAIT), - LintId::of(methods::SINGLE_CHAR_ADD_STR), - LintId::of(methods::SINGLE_CHAR_PATTERN), - LintId::of(methods::SKIP_WHILE_NEXT), - LintId::of(methods::STRING_EXTEND_CHARS), - LintId::of(methods::SUSPICIOUS_MAP), - LintId::of(methods::SUSPICIOUS_SPLITN), - LintId::of(methods::UNINIT_ASSUMED_INIT), - LintId::of(methods::UNNECESSARY_FILTER_MAP), - LintId::of(methods::UNNECESSARY_FOLD), - LintId::of(methods::UNNECESSARY_LAZY_EVALUATIONS), - LintId::of(methods::UNWRAP_OR_ELSE_DEFAULT), - LintId::of(methods::USELESS_ASREF), - LintId::of(methods::WRONG_SELF_CONVENTION), - LintId::of(methods::ZST_OFFSET), - LintId::of(minmax::MIN_MAX), - LintId::of(misc::CMP_NAN), - LintId::of(misc::CMP_OWNED), - LintId::of(misc::MODULO_ONE), - LintId::of(misc::SHORT_CIRCUIT_STATEMENT), - LintId::of(misc::TOPLEVEL_REF_ARG), - LintId::of(misc::ZERO_PTR), - LintId::of(misc_early::BUILTIN_TYPE_SHADOW), - LintId::of(misc_early::DOUBLE_NEG), - LintId::of(misc_early::DUPLICATE_UNDERSCORE_ARGUMENT), - LintId::of(misc_early::MIXED_CASE_HEX_LITERALS), - LintId::of(misc_early::REDUNDANT_PATTERN), - LintId::of(misc_early::UNNEEDED_WILDCARD_PATTERN), - LintId::of(misc_early::ZERO_PREFIXED_LITERAL), - LintId::of(mut_key::MUTABLE_KEY_TYPE), - LintId::of(mut_mutex_lock::MUT_MUTEX_LOCK), - LintId::of(mut_reference::UNNECESSARY_MUT_PASSED), - LintId::of(mutex_atomic::MUTEX_ATOMIC), - LintId::of(needless_arbitrary_self_type::NEEDLESS_ARBITRARY_SELF_TYPE), - LintId::of(needless_bool::BOOL_COMPARISON), - LintId::of(needless_bool::NEEDLESS_BOOL), - LintId::of(needless_borrow::NEEDLESS_BORROW), - LintId::of(needless_borrowed_ref::NEEDLESS_BORROWED_REFERENCE), - LintId::of(needless_option_as_deref::NEEDLESS_OPTION_AS_DEREF), - LintId::of(needless_question_mark::NEEDLESS_QUESTION_MARK), - LintId::of(needless_update::NEEDLESS_UPDATE), - LintId::of(neg_cmp_op_on_partial_ord::NEG_CMP_OP_ON_PARTIAL_ORD), - LintId::of(neg_multiply::NEG_MULTIPLY), - LintId::of(new_without_default::NEW_WITHOUT_DEFAULT), - LintId::of(no_effect::NO_EFFECT), - LintId::of(no_effect::UNNECESSARY_OPERATION), - LintId::of(non_copy_const::BORROW_INTERIOR_MUTABLE_CONST), - LintId::of(non_copy_const::DECLARE_INTERIOR_MUTABLE_CONST), - LintId::of(non_expressive_names::JUST_UNDERSCORES_AND_DIGITS), - LintId::of(non_octal_unix_permissions::NON_OCTAL_UNIX_PERMISSIONS), - LintId::of(open_options::NONSENSICAL_OPEN_OPTIONS), - LintId::of(option_env_unwrap::OPTION_ENV_UNWRAP), - LintId::of(overflow_check_conditional::OVERFLOW_CHECK_CONDITIONAL), - LintId::of(partialeq_ne_impl::PARTIALEQ_NE_IMPL), - LintId::of(precedence::PRECEDENCE), - LintId::of(ptr::CMP_NULL), - LintId::of(ptr::INVALID_NULL_PTR_USAGE), - LintId::of(ptr::MUT_FROM_REF), - LintId::of(ptr::PTR_ARG), - LintId::of(ptr_eq::PTR_EQ), - LintId::of(ptr_offset_with_cast::PTR_OFFSET_WITH_CAST), - LintId::of(question_mark::QUESTION_MARK), - LintId::of(ranges::MANUAL_RANGE_CONTAINS), - LintId::of(ranges::RANGE_ZIP_WITH_LEN), - LintId::of(ranges::REVERSED_EMPTY_RANGES), - LintId::of(redundant_clone::REDUNDANT_CLONE), - LintId::of(redundant_closure_call::REDUNDANT_CLOSURE_CALL), - LintId::of(redundant_field_names::REDUNDANT_FIELD_NAMES), - LintId::of(redundant_slicing::REDUNDANT_SLICING), - LintId::of(redundant_static_lifetimes::REDUNDANT_STATIC_LIFETIMES), - LintId::of(reference::DEREF_ADDROF), - LintId::of(reference::REF_IN_DEREF), - LintId::of(regex::INVALID_REGEX), - LintId::of(repeat_once::REPEAT_ONCE), - LintId::of(returns::LET_AND_RETURN), - LintId::of(returns::NEEDLESS_RETURN), - LintId::of(self_assignment::SELF_ASSIGNMENT), - LintId::of(self_named_constructors::SELF_NAMED_CONSTRUCTORS), - LintId::of(serde_api::SERDE_API_MISUSE), - LintId::of(single_component_path_imports::SINGLE_COMPONENT_PATH_IMPORTS), - LintId::of(size_of_in_element_count::SIZE_OF_IN_ELEMENT_COUNT), - LintId::of(slow_vector_initialization::SLOW_VECTOR_INITIALIZATION), - LintId::of(stable_sort_primitive::STABLE_SORT_PRIMITIVE), - LintId::of(strings::STRING_FROM_UTF8_AS_BYTES), - LintId::of(strlen_on_c_strings::STRLEN_ON_C_STRINGS), - LintId::of(suspicious_trait_impl::SUSPICIOUS_ARITHMETIC_IMPL), - LintId::of(suspicious_trait_impl::SUSPICIOUS_OP_ASSIGN_IMPL), - LintId::of(swap::ALMOST_SWAPPED), - LintId::of(swap::MANUAL_SWAP), - LintId::of(tabs_in_doc_comments::TABS_IN_DOC_COMMENTS), - LintId::of(temporary_assignment::TEMPORARY_ASSIGNMENT), - LintId::of(to_digit_is_some::TO_DIGIT_IS_SOME), - LintId::of(to_string_in_display::TO_STRING_IN_DISPLAY), - LintId::of(transmute::CROSSPOINTER_TRANSMUTE), - LintId::of(transmute::TRANSMUTES_EXPRESSIBLE_AS_PTR_CASTS), - LintId::of(transmute::TRANSMUTE_BYTES_TO_STR), - LintId::of(transmute::TRANSMUTE_FLOAT_TO_INT), - LintId::of(transmute::TRANSMUTE_INT_TO_BOOL), - LintId::of(transmute::TRANSMUTE_INT_TO_CHAR), - LintId::of(transmute::TRANSMUTE_INT_TO_FLOAT), - LintId::of(transmute::TRANSMUTE_PTR_TO_REF), - LintId::of(transmute::UNSOUND_COLLECTION_TRANSMUTE), - LintId::of(transmute::WRONG_TRANSMUTE), - LintId::of(transmuting_null::TRANSMUTING_NULL), - LintId::of(try_err::TRY_ERR), - LintId::of(types::BORROWED_BOX), - LintId::of(types::BOX_COLLECTION), - LintId::of(types::REDUNDANT_ALLOCATION), - LintId::of(types::TYPE_COMPLEXITY), - LintId::of(types::VEC_BOX), - LintId::of(undropped_manually_drops::UNDROPPED_MANUALLY_DROPS), - LintId::of(unicode::INVISIBLE_CHARACTERS), - LintId::of(unit_return_expecting_ord::UNIT_RETURN_EXPECTING_ORD), - LintId::of(unit_types::UNIT_ARG), - LintId::of(unit_types::UNIT_CMP), - LintId::of(unnamed_address::FN_ADDRESS_COMPARISONS), - LintId::of(unnamed_address::VTABLE_ADDRESS_COMPARISONS), - LintId::of(unnecessary_sort_by::UNNECESSARY_SORT_BY), - LintId::of(unsafe_removed_from_name::UNSAFE_REMOVED_FROM_NAME), - LintId::of(unused_io_amount::UNUSED_IO_AMOUNT), - LintId::of(unused_unit::UNUSED_UNIT), - LintId::of(unwrap::PANICKING_UNWRAP), - LintId::of(unwrap::UNNECESSARY_UNWRAP), - LintId::of(upper_case_acronyms::UPPER_CASE_ACRONYMS), - LintId::of(useless_conversion::USELESS_CONVERSION), - LintId::of(vec::USELESS_VEC), - LintId::of(vec_init_then_push::VEC_INIT_THEN_PUSH), - LintId::of(vec_resize_to_zero::VEC_RESIZE_TO_ZERO), - LintId::of(write::PRINTLN_EMPTY_STRING), - LintId::of(write::PRINT_LITERAL), - LintId::of(write::PRINT_WITH_NEWLINE), - LintId::of(write::WRITELN_EMPTY_STRING), - LintId::of(write::WRITE_LITERAL), - LintId::of(write::WRITE_WITH_NEWLINE), - LintId::of(zero_div_zero::ZERO_DIVIDED_BY_ZERO), - ]); - - store.register_group(true, "clippy::style", Some("clippy_style"), vec![ - LintId::of(assertions_on_constants::ASSERTIONS_ON_CONSTANTS), - LintId::of(assign_ops::ASSIGN_OP_PATTERN), - LintId::of(blacklisted_name::BLACKLISTED_NAME), - LintId::of(blocks_in_if_conditions::BLOCKS_IN_IF_CONDITIONS), - LintId::of(bool_assert_comparison::BOOL_ASSERT_COMPARISON), - LintId::of(casts::FN_TO_NUMERIC_CAST), - LintId::of(casts::FN_TO_NUMERIC_CAST_WITH_TRUNCATION), - LintId::of(collapsible_if::COLLAPSIBLE_ELSE_IF), - LintId::of(collapsible_if::COLLAPSIBLE_IF), - LintId::of(collapsible_match::COLLAPSIBLE_MATCH), - LintId::of(comparison_chain::COMPARISON_CHAIN), - LintId::of(default::FIELD_REASSIGN_WITH_DEFAULT), - LintId::of(doc::MISSING_SAFETY_DOC), - LintId::of(doc::NEEDLESS_DOCTEST_MAIN), - LintId::of(enum_variants::ENUM_VARIANT_NAMES), - LintId::of(enum_variants::MODULE_INCEPTION), - LintId::of(eq_op::OP_REF), - LintId::of(eta_reduction::REDUNDANT_CLOSURE), - LintId::of(float_literal::EXCESSIVE_PRECISION), - LintId::of(from_over_into::FROM_OVER_INTO), - LintId::of(from_str_radix_10::FROM_STR_RADIX_10), - LintId::of(functions::DOUBLE_MUST_USE), - LintId::of(functions::MUST_USE_UNIT), - LintId::of(functions::RESULT_UNIT_ERR), - LintId::of(if_then_panic::IF_THEN_PANIC), - LintId::of(inherent_to_string::INHERENT_TO_STRING), - LintId::of(len_zero::COMPARISON_TO_EMPTY), - LintId::of(len_zero::LEN_WITHOUT_IS_EMPTY), - LintId::of(len_zero::LEN_ZERO), - LintId::of(literal_representation::INCONSISTENT_DIGIT_GROUPING), - LintId::of(literal_representation::UNUSUAL_BYTE_GROUPINGS), - LintId::of(loops::FOR_KV_MAP), - LintId::of(loops::NEEDLESS_RANGE_LOOP), - LintId::of(loops::SAME_ITEM_PUSH), - LintId::of(loops::WHILE_LET_ON_ITERATOR), - LintId::of(main_recursion::MAIN_RECURSION), - LintId::of(manual_async_fn::MANUAL_ASYNC_FN), - LintId::of(manual_map::MANUAL_MAP), - LintId::of(manual_non_exhaustive::MANUAL_NON_EXHAUSTIVE), - LintId::of(map_clone::MAP_CLONE), - LintId::of(match_result_ok::MATCH_RESULT_OK), - LintId::of(matches::INFALLIBLE_DESTRUCTURING_MATCH), - LintId::of(matches::MATCH_LIKE_MATCHES_MACRO), - LintId::of(matches::MATCH_OVERLAPPING_ARM), - LintId::of(matches::MATCH_REF_PATS), - LintId::of(matches::REDUNDANT_PATTERN_MATCHING), - LintId::of(matches::SINGLE_MATCH), - LintId::of(mem_replace::MEM_REPLACE_OPTION_WITH_NONE), - LintId::of(mem_replace::MEM_REPLACE_WITH_DEFAULT), - LintId::of(methods::BYTES_NTH), - LintId::of(methods::CHARS_LAST_CMP), - LintId::of(methods::CHARS_NEXT_CMP), - LintId::of(methods::INTO_ITER_ON_REF), - LintId::of(methods::ITER_CLONED_COLLECT), - LintId::of(methods::ITER_NEXT_SLICE), - LintId::of(methods::ITER_NTH_ZERO), - LintId::of(methods::ITER_SKIP_NEXT), - LintId::of(methods::MANUAL_SATURATING_ARITHMETIC), - LintId::of(methods::MAP_COLLECT_RESULT_UNIT), - LintId::of(methods::NEW_RET_NO_SELF), - LintId::of(methods::OK_EXPECT), - LintId::of(methods::OPTION_MAP_OR_NONE), - LintId::of(methods::RESULT_MAP_OR_INTO_OPTION), - LintId::of(methods::SHOULD_IMPLEMENT_TRAIT), - LintId::of(methods::SINGLE_CHAR_ADD_STR), - LintId::of(methods::STRING_EXTEND_CHARS), - LintId::of(methods::UNNECESSARY_FOLD), - LintId::of(methods::UNNECESSARY_LAZY_EVALUATIONS), - LintId::of(methods::UNWRAP_OR_ELSE_DEFAULT), - LintId::of(methods::WRONG_SELF_CONVENTION), - LintId::of(misc::TOPLEVEL_REF_ARG), - LintId::of(misc::ZERO_PTR), - LintId::of(misc_early::BUILTIN_TYPE_SHADOW), - LintId::of(misc_early::DOUBLE_NEG), - LintId::of(misc_early::DUPLICATE_UNDERSCORE_ARGUMENT), - LintId::of(misc_early::MIXED_CASE_HEX_LITERALS), - LintId::of(misc_early::REDUNDANT_PATTERN), - LintId::of(mut_mutex_lock::MUT_MUTEX_LOCK), - LintId::of(mut_reference::UNNECESSARY_MUT_PASSED), - LintId::of(needless_borrow::NEEDLESS_BORROW), - LintId::of(neg_multiply::NEG_MULTIPLY), - LintId::of(new_without_default::NEW_WITHOUT_DEFAULT), - LintId::of(non_copy_const::BORROW_INTERIOR_MUTABLE_CONST), - LintId::of(non_copy_const::DECLARE_INTERIOR_MUTABLE_CONST), - LintId::of(non_expressive_names::JUST_UNDERSCORES_AND_DIGITS), - LintId::of(ptr::CMP_NULL), - LintId::of(ptr::PTR_ARG), - LintId::of(ptr_eq::PTR_EQ), - LintId::of(question_mark::QUESTION_MARK), - LintId::of(ranges::MANUAL_RANGE_CONTAINS), - LintId::of(redundant_field_names::REDUNDANT_FIELD_NAMES), - LintId::of(redundant_static_lifetimes::REDUNDANT_STATIC_LIFETIMES), - LintId::of(returns::LET_AND_RETURN), - LintId::of(returns::NEEDLESS_RETURN), - LintId::of(self_named_constructors::SELF_NAMED_CONSTRUCTORS), - LintId::of(single_component_path_imports::SINGLE_COMPONENT_PATH_IMPORTS), - LintId::of(tabs_in_doc_comments::TABS_IN_DOC_COMMENTS), - LintId::of(to_digit_is_some::TO_DIGIT_IS_SOME), - LintId::of(try_err::TRY_ERR), - LintId::of(unsafe_removed_from_name::UNSAFE_REMOVED_FROM_NAME), - LintId::of(unused_unit::UNUSED_UNIT), - LintId::of(upper_case_acronyms::UPPER_CASE_ACRONYMS), - LintId::of(write::PRINTLN_EMPTY_STRING), - LintId::of(write::PRINT_LITERAL), - LintId::of(write::PRINT_WITH_NEWLINE), - LintId::of(write::WRITELN_EMPTY_STRING), - LintId::of(write::WRITE_LITERAL), - LintId::of(write::WRITE_WITH_NEWLINE), - ]); - - store.register_group(true, "clippy::complexity", Some("clippy_complexity"), vec![ - LintId::of(attrs::DEPRECATED_CFG_ATTR), - LintId::of(booleans::NONMINIMAL_BOOL), - LintId::of(casts::CHAR_LIT_AS_U8), - LintId::of(casts::UNNECESSARY_CAST), - LintId::of(derivable_impls::DERIVABLE_IMPLS), - LintId::of(double_comparison::DOUBLE_COMPARISONS), - LintId::of(double_parens::DOUBLE_PARENS), - LintId::of(duration_subsec::DURATION_SUBSEC), - LintId::of(eval_order_dependence::DIVERGING_SUB_EXPRESSION), - LintId::of(explicit_write::EXPLICIT_WRITE), - LintId::of(format::USELESS_FORMAT), - LintId::of(functions::TOO_MANY_ARGUMENTS), - LintId::of(get_last_with_len::GET_LAST_WITH_LEN), - LintId::of(identity_op::IDENTITY_OP), - LintId::of(int_plus_one::INT_PLUS_ONE), - LintId::of(lifetimes::EXTRA_UNUSED_LIFETIMES), - LintId::of(lifetimes::NEEDLESS_LIFETIMES), - LintId::of(loops::EXPLICIT_COUNTER_LOOP), - LintId::of(loops::MANUAL_FLATTEN), - LintId::of(loops::SINGLE_ELEMENT_LOOP), - LintId::of(loops::WHILE_LET_LOOP), - LintId::of(manual_strip::MANUAL_STRIP), - LintId::of(manual_unwrap_or::MANUAL_UNWRAP_OR), - LintId::of(map_unit_fn::OPTION_MAP_UNIT_FN), - LintId::of(map_unit_fn::RESULT_MAP_UNIT_FN), - LintId::of(matches::MATCH_AS_REF), - LintId::of(matches::MATCH_SINGLE_BINDING), - LintId::of(matches::WILDCARD_IN_OR_PATTERNS), - LintId::of(methods::BIND_INSTEAD_OF_MAP), - LintId::of(methods::CLONE_ON_COPY), - LintId::of(methods::FILTER_MAP_IDENTITY), - LintId::of(methods::FILTER_NEXT), - LintId::of(methods::FLAT_MAP_IDENTITY), - LintId::of(methods::INSPECT_FOR_EACH), - LintId::of(methods::ITER_COUNT), - LintId::of(methods::MANUAL_FILTER_MAP), - LintId::of(methods::MANUAL_FIND_MAP), - LintId::of(methods::MANUAL_SPLIT_ONCE), - LintId::of(methods::MAP_IDENTITY), - LintId::of(methods::OPTION_AS_REF_DEREF), - LintId::of(methods::OPTION_FILTER_MAP), - LintId::of(methods::SEARCH_IS_SOME), - LintId::of(methods::SKIP_WHILE_NEXT), - LintId::of(methods::UNNECESSARY_FILTER_MAP), - LintId::of(methods::USELESS_ASREF), - LintId::of(misc::SHORT_CIRCUIT_STATEMENT), - LintId::of(misc_early::UNNEEDED_WILDCARD_PATTERN), - LintId::of(misc_early::ZERO_PREFIXED_LITERAL), - LintId::of(needless_arbitrary_self_type::NEEDLESS_ARBITRARY_SELF_TYPE), - LintId::of(needless_bool::BOOL_COMPARISON), - LintId::of(needless_bool::NEEDLESS_BOOL), - LintId::of(needless_borrowed_ref::NEEDLESS_BORROWED_REFERENCE), - LintId::of(needless_option_as_deref::NEEDLESS_OPTION_AS_DEREF), - LintId::of(needless_question_mark::NEEDLESS_QUESTION_MARK), - LintId::of(needless_update::NEEDLESS_UPDATE), - LintId::of(neg_cmp_op_on_partial_ord::NEG_CMP_OP_ON_PARTIAL_ORD), - LintId::of(no_effect::NO_EFFECT), - LintId::of(no_effect::UNNECESSARY_OPERATION), - LintId::of(overflow_check_conditional::OVERFLOW_CHECK_CONDITIONAL), - LintId::of(partialeq_ne_impl::PARTIALEQ_NE_IMPL), - LintId::of(precedence::PRECEDENCE), - LintId::of(ptr_offset_with_cast::PTR_OFFSET_WITH_CAST), - LintId::of(ranges::RANGE_ZIP_WITH_LEN), - LintId::of(redundant_closure_call::REDUNDANT_CLOSURE_CALL), - LintId::of(redundant_slicing::REDUNDANT_SLICING), - LintId::of(reference::DEREF_ADDROF), - LintId::of(reference::REF_IN_DEREF), - LintId::of(repeat_once::REPEAT_ONCE), - LintId::of(strings::STRING_FROM_UTF8_AS_BYTES), - LintId::of(strlen_on_c_strings::STRLEN_ON_C_STRINGS), - LintId::of(swap::MANUAL_SWAP), - LintId::of(temporary_assignment::TEMPORARY_ASSIGNMENT), - LintId::of(transmute::CROSSPOINTER_TRANSMUTE), - LintId::of(transmute::TRANSMUTES_EXPRESSIBLE_AS_PTR_CASTS), - LintId::of(transmute::TRANSMUTE_BYTES_TO_STR), - LintId::of(transmute::TRANSMUTE_FLOAT_TO_INT), - LintId::of(transmute::TRANSMUTE_INT_TO_BOOL), - LintId::of(transmute::TRANSMUTE_INT_TO_CHAR), - LintId::of(transmute::TRANSMUTE_INT_TO_FLOAT), - LintId::of(transmute::TRANSMUTE_PTR_TO_REF), - LintId::of(types::BORROWED_BOX), - LintId::of(types::TYPE_COMPLEXITY), - LintId::of(types::VEC_BOX), - LintId::of(unit_types::UNIT_ARG), - LintId::of(unnecessary_sort_by::UNNECESSARY_SORT_BY), - LintId::of(unwrap::UNNECESSARY_UNWRAP), - LintId::of(useless_conversion::USELESS_CONVERSION), - LintId::of(zero_div_zero::ZERO_DIVIDED_BY_ZERO), - ]); - - store.register_group(true, "clippy::correctness", Some("clippy_correctness"), vec![ - LintId::of(absurd_extreme_comparisons::ABSURD_EXTREME_COMPARISONS), - LintId::of(approx_const::APPROX_CONSTANT), - LintId::of(async_yields_async::ASYNC_YIELDS_ASYNC), - LintId::of(attrs::DEPRECATED_SEMVER), - LintId::of(attrs::MISMATCHED_TARGET_OS), - LintId::of(attrs::USELESS_ATTRIBUTE), - LintId::of(bit_mask::BAD_BIT_MASK), - LintId::of(bit_mask::INEFFECTIVE_BIT_MASK), - LintId::of(booleans::LOGIC_BUG), - LintId::of(casts::CAST_REF_TO_MUT), - LintId::of(copies::IFS_SAME_COND), - LintId::of(copies::IF_SAME_THEN_ELSE), - LintId::of(derive::DERIVE_HASH_XOR_EQ), - LintId::of(derive::DERIVE_ORD_XOR_PARTIAL_ORD), - LintId::of(drop_forget_ref::DROP_COPY), - LintId::of(drop_forget_ref::DROP_REF), - LintId::of(drop_forget_ref::FORGET_COPY), - LintId::of(drop_forget_ref::FORGET_REF), - LintId::of(enum_clike::ENUM_CLIKE_UNPORTABLE_VARIANT), - LintId::of(eq_op::EQ_OP), - LintId::of(erasing_op::ERASING_OP), - LintId::of(formatting::POSSIBLE_MISSING_COMMA), - LintId::of(functions::NOT_UNSAFE_PTR_ARG_DEREF), - LintId::of(if_let_mutex::IF_LET_MUTEX), - LintId::of(indexing_slicing::OUT_OF_BOUNDS_INDEXING), - LintId::of(infinite_iter::INFINITE_ITER), - LintId::of(inherent_to_string::INHERENT_TO_STRING_SHADOW_DISPLAY), - LintId::of(inline_fn_without_body::INLINE_FN_WITHOUT_BODY), - LintId::of(let_underscore::LET_UNDERSCORE_LOCK), - LintId::of(literal_representation::MISTYPED_LITERAL_SUFFIXES), - LintId::of(loops::ITER_NEXT_LOOP), - LintId::of(loops::NEVER_LOOP), - LintId::of(loops::WHILE_IMMUTABLE_CONDITION), - LintId::of(mem_discriminant::MEM_DISCRIMINANT_NON_ENUM), - LintId::of(mem_replace::MEM_REPLACE_WITH_UNINIT), - LintId::of(methods::CLONE_DOUBLE_REF), - LintId::of(methods::ITERATOR_STEP_BY_ZERO), - LintId::of(methods::SUSPICIOUS_SPLITN), - LintId::of(methods::UNINIT_ASSUMED_INIT), - LintId::of(methods::ZST_OFFSET), - LintId::of(minmax::MIN_MAX), - LintId::of(misc::CMP_NAN), - LintId::of(misc::MODULO_ONE), - LintId::of(non_octal_unix_permissions::NON_OCTAL_UNIX_PERMISSIONS), - LintId::of(open_options::NONSENSICAL_OPEN_OPTIONS), - LintId::of(option_env_unwrap::OPTION_ENV_UNWRAP), - LintId::of(ptr::INVALID_NULL_PTR_USAGE), - LintId::of(ptr::MUT_FROM_REF), - LintId::of(ranges::REVERSED_EMPTY_RANGES), - LintId::of(regex::INVALID_REGEX), - LintId::of(self_assignment::SELF_ASSIGNMENT), - LintId::of(serde_api::SERDE_API_MISUSE), - LintId::of(size_of_in_element_count::SIZE_OF_IN_ELEMENT_COUNT), - LintId::of(swap::ALMOST_SWAPPED), - LintId::of(to_string_in_display::TO_STRING_IN_DISPLAY), - LintId::of(transmute::UNSOUND_COLLECTION_TRANSMUTE), - LintId::of(transmute::WRONG_TRANSMUTE), - LintId::of(transmuting_null::TRANSMUTING_NULL), - LintId::of(undropped_manually_drops::UNDROPPED_MANUALLY_DROPS), - LintId::of(unicode::INVISIBLE_CHARACTERS), - LintId::of(unit_return_expecting_ord::UNIT_RETURN_EXPECTING_ORD), - LintId::of(unit_types::UNIT_CMP), - LintId::of(unnamed_address::FN_ADDRESS_COMPARISONS), - LintId::of(unnamed_address::VTABLE_ADDRESS_COMPARISONS), - LintId::of(unused_io_amount::UNUSED_IO_AMOUNT), - LintId::of(unwrap::PANICKING_UNWRAP), - LintId::of(vec_resize_to_zero::VEC_RESIZE_TO_ZERO), - ]); - - store.register_group(true, "clippy::suspicious", None, vec![ - LintId::of(assign_ops::MISREFACTORED_ASSIGN_OP), - LintId::of(attrs::BLANKET_CLIPPY_RESTRICTION_LINTS), - LintId::of(eval_order_dependence::EVAL_ORDER_DEPENDENCE), - LintId::of(float_equality_without_abs::FLOAT_EQUALITY_WITHOUT_ABS), - LintId::of(formatting::SUSPICIOUS_ASSIGNMENT_FORMATTING), - LintId::of(formatting::SUSPICIOUS_ELSE_FORMATTING), - LintId::of(formatting::SUSPICIOUS_UNARY_OP_FORMATTING), - LintId::of(loops::EMPTY_LOOP), - LintId::of(loops::FOR_LOOPS_OVER_FALLIBLES), - LintId::of(loops::MUT_RANGE_BOUND), - LintId::of(methods::SUSPICIOUS_MAP), - LintId::of(mut_key::MUTABLE_KEY_TYPE), - LintId::of(suspicious_trait_impl::SUSPICIOUS_ARITHMETIC_IMPL), - LintId::of(suspicious_trait_impl::SUSPICIOUS_OP_ASSIGN_IMPL), - ]); - - store.register_group(true, "clippy::perf", Some("clippy_perf"), vec![ - LintId::of(entry::MAP_ENTRY), - LintId::of(escape::BOXED_LOCAL), - LintId::of(large_const_arrays::LARGE_CONST_ARRAYS), - LintId::of(large_enum_variant::LARGE_ENUM_VARIANT), - LintId::of(loops::MANUAL_MEMCPY), - LintId::of(loops::NEEDLESS_COLLECT), - LintId::of(methods::EXPECT_FUN_CALL), - LintId::of(methods::EXTEND_WITH_DRAIN), - LintId::of(methods::ITER_NTH), - LintId::of(methods::MANUAL_STR_REPEAT), - LintId::of(methods::OR_FUN_CALL), - LintId::of(methods::SINGLE_CHAR_PATTERN), - LintId::of(misc::CMP_OWNED), - LintId::of(mutex_atomic::MUTEX_ATOMIC), - LintId::of(redundant_clone::REDUNDANT_CLONE), - LintId::of(slow_vector_initialization::SLOW_VECTOR_INITIALIZATION), - LintId::of(stable_sort_primitive::STABLE_SORT_PRIMITIVE), - LintId::of(types::BOX_COLLECTION), - LintId::of(types::REDUNDANT_ALLOCATION), - LintId::of(vec::USELESS_VEC), - LintId::of(vec_init_then_push::VEC_INIT_THEN_PUSH), - ]); - - store.register_group(true, "clippy::cargo", Some("clippy_cargo"), vec![ - LintId::of(cargo_common_metadata::CARGO_COMMON_METADATA), - LintId::of(feature_name::NEGATIVE_FEATURE_NAMES), - LintId::of(feature_name::REDUNDANT_FEATURE_NAMES), - LintId::of(multiple_crate_versions::MULTIPLE_CRATE_VERSIONS), - LintId::of(wildcard_dependencies::WILDCARD_DEPENDENCIES), - ]); - - store.register_group(true, "clippy::nursery", Some("clippy_nursery"), vec![ - LintId::of(attrs::EMPTY_LINE_AFTER_OUTER_ATTR), - LintId::of(cognitive_complexity::COGNITIVE_COMPLEXITY), - LintId::of(copies::BRANCHES_SHARING_CODE), - LintId::of(disallowed_method::DISALLOWED_METHOD), - LintId::of(disallowed_type::DISALLOWED_TYPE), - LintId::of(fallible_impl_from::FALLIBLE_IMPL_FROM), - LintId::of(floating_point_arithmetic::IMPRECISE_FLOPS), - LintId::of(floating_point_arithmetic::SUBOPTIMAL_FLOPS), - LintId::of(future_not_send::FUTURE_NOT_SEND), - LintId::of(let_if_seq::USELESS_LET_IF_SEQ), - LintId::of(missing_const_for_fn::MISSING_CONST_FOR_FN), - LintId::of(mutable_debug_assertion::DEBUG_ASSERT_WITH_MUT_CALL), - LintId::of(mutex_atomic::MUTEX_INTEGER), - LintId::of(nonstandard_macro_braces::NONSTANDARD_MACRO_BRACES), - LintId::of(option_if_let_else::OPTION_IF_LET_ELSE), - LintId::of(path_buf_push_overwrite::PATH_BUF_PUSH_OVERWRITE), - LintId::of(redundant_pub_crate::REDUNDANT_PUB_CRATE), - LintId::of(regex::TRIVIAL_REGEX), - LintId::of(strings::STRING_LIT_AS_BYTES), - LintId::of(suspicious_operation_groupings::SUSPICIOUS_OPERATION_GROUPINGS), - LintId::of(transmute::USELESS_TRANSMUTE), - LintId::of(use_self::USE_SELF), - ]); + include!("lib.register_internal.rs"); + + include!("lib.register_all.rs"); + include!("lib.register_style.rs"); + include!("lib.register_complexity.rs"); + include!("lib.register_correctness.rs"); + include!("lib.register_suspicious.rs"); + include!("lib.register_perf.rs"); + include!("lib.register_cargo.rs"); + include!("lib.register_nursery.rs"); #[cfg(feature = "metadata-collector-lint")] { -- cgit 1.4.1-3-g733a5 From e6747df5cd4232d26747a556c263d0a5d9c72414 Mon Sep 17 00:00:00 2001 From: Michael Wright Date: Sat, 18 Sep 2021 06:43:39 +0200 Subject: Fix lint register code format Also change the generation functions to return `String` instead of `Vec`. This makes sense now as the updates aren't line oriented anymore. --- clippy_dev/src/lib.rs | 188 ++--- clippy_dev/src/update_lints.rs | 59 +- clippy_lints/src/lib.deprecated.rs | 2 +- clippy_lints/src/lib.mods.rs | 2 +- clippy_lints/src/lib.register_all.rs | 598 +++++++-------- clippy_lints/src/lib.register_cargo.rs | 12 +- clippy_lints/src/lib.register_complexity.rs | 178 ++--- clippy_lints/src/lib.register_correctness.rs | 136 ++-- clippy_lints/src/lib.register_internal.rs | 26 +- clippy_lints/src/lib.register_lints.rs | 1008 +++++++++++++------------- clippy_lints/src/lib.register_nursery.rs | 46 +- clippy_lints/src/lib.register_pedantic.rs | 192 ++--- clippy_lints/src/lib.register_perf.rs | 44 +- clippy_lints/src/lib.register_restriction.rs | 118 +-- clippy_lints/src/lib.register_style.rs | 218 +++--- clippy_lints/src/lib.register_suspicious.rs | 30 +- 16 files changed, 1433 insertions(+), 1424 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lib.rs b/clippy_dev/src/lib.rs index 8f0356c028b..7dba808b418 100644 --- a/clippy_dev/src/lib.rs +++ b/clippy_dev/src/lib.rs @@ -5,7 +5,7 @@ use itertools::Itertools; use regex::Regex; -use std::collections::HashMap; +use std::collections::{BTreeSet, HashMap}; use std::ffi::OsStr; use std::fs; use std::lazy::SyncLazy; @@ -19,6 +19,10 @@ pub mod serve; pub mod setup; pub mod update_lints; +const GENERATED_FILE_COMMENT: &str = "// This file was generated by `cargo dev update_lints`.\n\ + // Use that command to update this file and do not edit by hand.\n\ + // Manual edits will be overwritten.\n\n"; + static DEC_CLIPPY_LINT_RE: SyncLazy = SyncLazy::new(|| { Regex::new( r#"(?x) @@ -98,37 +102,35 @@ impl Lint { } } -/// Generates the Vec items for `register_lint_group` calls in `clippy_lints/src/lib.rs`. -#[must_use] -pub fn gen_lint_group_list<'a>(group_name: &str, lints: impl Iterator) -> Vec { - let header = format!( - r#"store.register_group(true, "clippy::{0}", Some("clippy_{0}"), vec!["#, - group_name - ); - let footer = "])".to_string(); - - let mut result = vec![header]; +/// Generates the code for registering a group +pub fn gen_lint_group_list<'a>(group_name: &str, lints: impl Iterator) -> String { + let mut details: Vec<_> = lints.map(|l| (&l.module, l.name.to_uppercase())).collect(); + details.sort_unstable(); - result.extend( - lints - .map(|l| format!("LintId::of({}::{}),", l.module, l.name.to_uppercase())) - .sorted(), - ); + let mut output = GENERATED_FILE_COMMENT.to_string(); - result.push(footer); + output.push_str(&format!( + "store.register_group(true, \"clippy::{0}\", Some(\"clippy_{0}\"), vec![\n", + group_name + )); + for (module, name) in details { + output.push_str(&format!(" LintId::of({}::{}),\n", module, name)); + } + output.push_str("])\n"); - result + output } -/// Generates the `pub mod module_name` list in `clippy_lints/src/lib.rs`. +/// Generates the module declarations for `lints` #[must_use] -pub fn gen_modules_list<'a>(lints: impl Iterator) -> Vec { - lints - .map(|l| &l.module) - .unique() - .map(|module| format!("mod {};", module)) - .sorted() - .collect::>() +pub fn gen_modules_list<'a>(lints: impl Iterator) -> String { + let module_names: BTreeSet<_> = lints.map(|l| &l.module).collect(); + + let mut output = GENERATED_FILE_COMMENT.to_string(); + for name in module_names { + output.push_str(&format!("mod {};\n", name)); + } + output } /// Generates the list of lint links at the bottom of the README @@ -140,52 +142,52 @@ pub fn gen_changelog_lint_list<'a>(lints: impl Iterator) -> Vec .collect() } -/// Generates the `register_removed` code in `./clippy_lints/src/lib.rs`. +/// Generates the `register_removed` code #[must_use] -pub fn gen_deprecated<'a>(lints: impl Iterator) -> Vec { - let mut result = vec!["{".to_string()]; - result.extend(lints.flat_map(|l| { - l.deprecation - .clone() - .map(|depr_text| { - vec![ - " store.register_removed(".to_string(), - format!(" \"clippy::{}\",", l.name), - format!(" \"{}\",", depr_text), - " );".to_string(), - ] - }) - .expect("only deprecated lints should be passed") - })); - result.push("}".to_string()); - result +pub fn gen_deprecated<'a>(lints: impl Iterator) -> String { + let mut output = GENERATED_FILE_COMMENT.to_string(); + output.push_str("{\n"); + for Lint { name, deprecation, .. } in lints { + output.push_str(&format!( + concat!( + " store.register_removed(\n", + " \"clippy::{}\",\n", + " \"{}\",\n", + " );\n" + ), + name, + deprecation.as_ref().expect("`lints` are deprecated") + )); + } + output.push_str("}\n"); + + output } +/// Generates the code for registering lints #[must_use] pub fn gen_register_lint_list<'a>( internal_lints: impl Iterator, usable_lints: impl Iterator, -) -> Vec { - let header = " store.register_lints(&[".to_string(); - let footer = " ])".to_string(); - let internal_lints = internal_lints - .sorted_by_key(|l| format!(" {}::{},", l.module, l.name.to_uppercase())) - .map(|l| { - format!( - " #[cfg(feature = \"internal-lints\")]\n {}::{},", - l.module, - l.name.to_uppercase() - ) - }); - let other_lints = usable_lints - .sorted_by_key(|l| format!(" {}::{},", l.module, l.name.to_uppercase())) - .map(|l| format!(" {}::{},", l.module, l.name.to_uppercase())) - .sorted(); - let mut lint_list = vec![header]; - lint_list.extend(internal_lints); - lint_list.extend(other_lints); - lint_list.push(footer); - lint_list +) -> String { + let mut details: Vec<_> = internal_lints + .map(|l| (false, &l.module, l.name.to_uppercase())) + .chain(usable_lints.map(|l| (true, &l.module, l.name.to_uppercase()))) + .collect(); + details.sort_unstable(); + + let mut output = GENERATED_FILE_COMMENT.to_string(); + output.push_str("store.register_lints(&[\n"); + + for (is_public, module_name, lint_name) in details { + if !is_public { + output.push_str(" #[cfg(feature = \"internal-lints\")]\n"); + } + output.push_str(&format!(" {}::{},\n", module_name, lint_name)); + } + output.push_str("])\n"); + + output } /// Gathers all files in `src/clippy_lints` and gathers all lints inside @@ -524,21 +526,23 @@ fn test_gen_deprecated() { "module_name", ), ]; - let expected: Vec = vec![ - "{", - " store.register_removed(", - " \"clippy::should_assert_eq\",", - " \"has been superseded by should_assert_eq2\",", - " );", - " store.register_removed(", - " \"clippy::another_deprecated\",", - " \"will be removed\",", - " );", - "}", - ] - .into_iter() - .map(String::from) - .collect(); + + let expected = GENERATED_FILE_COMMENT.to_string() + + &[ + "{", + " store.register_removed(", + " \"clippy::should_assert_eq\",", + " \"has been superseded by should_assert_eq2\",", + " );", + " store.register_removed(", + " \"clippy::another_deprecated\",", + " \"will be removed\",", + " );", + "}", + ] + .join("\n") + + "\n"; + assert_eq!(expected, gen_deprecated(lints.iter())); } @@ -555,7 +559,7 @@ fn test_gen_modules_list() { Lint::new("should_assert_eq", "group1", "abc", None, "module_name"), Lint::new("incorrect_stuff", "group3", "abc", None, "another_module"), ]; - let expected = vec!["mod another_module;".to_string(), "mod module_name;".to_string()]; + let expected = GENERATED_FILE_COMMENT.to_string() + &["mod another_module;", "mod module_name;"].join("\n") + "\n"; assert_eq!(expected, gen_modules_list(lints.iter())); } @@ -566,12 +570,18 @@ fn test_gen_lint_group_list() { Lint::new("should_assert_eq", "group1", "abc", None, "module_name"), Lint::new("internal", "internal_style", "abc", None, "module_name"), ]; - let expected = vec![ - "store.register_group(true, \"clippy::group1\", Some(\"clippy_group1\"), vec![", - "LintId::of(module_name::ABC),", - "LintId::of(module_name::INTERNAL),", - "LintId::of(module_name::SHOULD_ASSERT_EQ),", - "])", - ]; - assert_eq!(expected, gen_lint_group_list("group1", lints.iter())); + let expected = GENERATED_FILE_COMMENT.to_string() + + &[ + "store.register_group(true, \"clippy::group1\", Some(\"clippy_group1\"), vec![", + " LintId::of(module_name::ABC),", + " LintId::of(module_name::INTERNAL),", + " LintId::of(module_name::SHOULD_ASSERT_EQ),", + "])", + ] + .join("\n") + + "\n"; + + let result = gen_lint_group_list("group1", lints.iter()); + + assert_eq!(expected, result); } diff --git a/clippy_dev/src/update_lints.rs b/clippy_dev/src/update_lints.rs index ba550d492fc..f393a8d1de1 100644 --- a/clippy_dev/src/update_lints.rs +++ b/clippy_dev/src/update_lints.rs @@ -66,32 +66,37 @@ pub fn run(update_mode: UpdateMode) { exit_with_failure(); } - for (name, lines) in [ - ("mods", gen_modules_list(usable_lints.iter())), - ("deprecated", gen_deprecated(deprecated_lints.iter())), - ( - "register_lints", - gen_register_lint_list(internal_lints.iter(), usable_lints.iter()), - ), - ("register_all", { - let all_group_lints = usable_lints.iter().filter(|l| { - matches!( - &*l.group, - "correctness" | "suspicious" | "style" | "complexity" | "perf" - ) - }); - - gen_lint_group_list("all", all_group_lints) - }), - ] { - process_file(&format!("clippy_lints/src/lib.{}.rs", name), update_mode, &lines[..]); - } + process_file( + "clippy_lints/src/lib.register_lints.rs", + update_mode, + &gen_register_lint_list(internal_lints.iter(), usable_lints.iter()), + ); + process_file( + "clippy_lints/src/lib.deprecated.rs", + update_mode, + &gen_deprecated(deprecated_lints.iter()), + ); + process_file( + "clippy_lints/src/lib.mods.rs", + update_mode, + &gen_modules_list(usable_lints.iter()), + ); + + let all_group_lints = usable_lints.iter().filter(|l| { + matches!( + &*l.group, + "correctness" | "suspicious" | "style" | "complexity" | "perf" + ) + }); + let content = gen_lint_group_list("all", all_group_lints); + process_file("clippy_lints/src/lib.register_all.rs", update_mode, &content); for (lint_group, lints) in Lint::by_lint_group(usable_lints.into_iter().chain(internal_lints)) { + let content = gen_lint_group_list(&lint_group, lints.iter()); process_file( &format!("clippy_lints/src/lib.register_{}.rs", lint_group), update_mode, - &gen_lint_group_list(&lints.get(0).expect("group non-empty").group, lints.iter())[..], + &content, ); } } @@ -122,21 +127,15 @@ fn round_to_fifty(count: usize) -> usize { count / 50 * 50 } -fn process_file(path: impl AsRef, update_mode: UpdateMode, new_lines: &[String]) { - let mut new_content = "// This file was generated by `cargo dev update_lints`.\n\ - // Use that command to update this file and do not edit by hand.\n\ - // Manual edits will be overwritten.\n\n" - .to_string(); - new_content.push_str(&new_lines.join("\n")); - +fn process_file(path: impl AsRef, update_mode: UpdateMode, content: &str) { if update_mode == UpdateMode::Check { let old_content = fs::read_to_string(&path).unwrap_or_else(|e| panic!("Cannot read from {}: {}", path.as_ref().display(), e)); - if new_content != old_content { + if content != old_content { exit_with_failure(); } } else { - fs::write(&path, new_content.as_bytes()) + fs::write(&path, content.as_bytes()) .unwrap_or_else(|e| panic!("Cannot write to {}: {}", path.as_ref().display(), e)); } } diff --git a/clippy_lints/src/lib.deprecated.rs b/clippy_lints/src/lib.deprecated.rs index f5134a0a80a..80bde1b1138 100644 --- a/clippy_lints/src/lib.deprecated.rs +++ b/clippy_lints/src/lib.deprecated.rs @@ -67,4 +67,4 @@ "clippy::wrong_pub_self_convention", "set the `avoid-breaking-exported-api` config option to `false` to enable the `wrong_self_convention` lint for public items", ); -} \ No newline at end of file +} diff --git a/clippy_lints/src/lib.mods.rs b/clippy_lints/src/lib.mods.rs index 49f445c3531..2718604f905 100644 --- a/clippy_lints/src/lib.mods.rs +++ b/clippy_lints/src/lib.mods.rs @@ -229,4 +229,4 @@ mod wildcard_dependencies; mod wildcard_imports; mod write; mod zero_div_zero; -mod zero_sized_map_values; \ No newline at end of file +mod zero_sized_map_values; diff --git a/clippy_lints/src/lib.register_all.rs b/clippy_lints/src/lib.register_all.rs index 7a77303b834..3e6e0244754 100644 --- a/clippy_lints/src/lib.register_all.rs +++ b/clippy_lints/src/lib.register_all.rs @@ -3,302 +3,302 @@ // Manual edits will be overwritten. store.register_group(true, "clippy::all", Some("clippy_all"), vec![ -LintId::of(absurd_extreme_comparisons::ABSURD_EXTREME_COMPARISONS), -LintId::of(approx_const::APPROX_CONSTANT), -LintId::of(assertions_on_constants::ASSERTIONS_ON_CONSTANTS), -LintId::of(assign_ops::ASSIGN_OP_PATTERN), -LintId::of(assign_ops::MISREFACTORED_ASSIGN_OP), -LintId::of(async_yields_async::ASYNC_YIELDS_ASYNC), -LintId::of(attrs::BLANKET_CLIPPY_RESTRICTION_LINTS), -LintId::of(attrs::DEPRECATED_CFG_ATTR), -LintId::of(attrs::DEPRECATED_SEMVER), -LintId::of(attrs::MISMATCHED_TARGET_OS), -LintId::of(attrs::USELESS_ATTRIBUTE), -LintId::of(bit_mask::BAD_BIT_MASK), -LintId::of(bit_mask::INEFFECTIVE_BIT_MASK), -LintId::of(blacklisted_name::BLACKLISTED_NAME), -LintId::of(blocks_in_if_conditions::BLOCKS_IN_IF_CONDITIONS), -LintId::of(bool_assert_comparison::BOOL_ASSERT_COMPARISON), -LintId::of(booleans::LOGIC_BUG), -LintId::of(booleans::NONMINIMAL_BOOL), -LintId::of(casts::CAST_REF_TO_MUT), -LintId::of(casts::CHAR_LIT_AS_U8), -LintId::of(casts::FN_TO_NUMERIC_CAST), -LintId::of(casts::FN_TO_NUMERIC_CAST_WITH_TRUNCATION), -LintId::of(casts::UNNECESSARY_CAST), -LintId::of(collapsible_if::COLLAPSIBLE_ELSE_IF), -LintId::of(collapsible_if::COLLAPSIBLE_IF), -LintId::of(collapsible_match::COLLAPSIBLE_MATCH), -LintId::of(comparison_chain::COMPARISON_CHAIN), -LintId::of(copies::IFS_SAME_COND), -LintId::of(copies::IF_SAME_THEN_ELSE), -LintId::of(default::FIELD_REASSIGN_WITH_DEFAULT), -LintId::of(derivable_impls::DERIVABLE_IMPLS), -LintId::of(derive::DERIVE_HASH_XOR_EQ), -LintId::of(derive::DERIVE_ORD_XOR_PARTIAL_ORD), -LintId::of(doc::MISSING_SAFETY_DOC), -LintId::of(doc::NEEDLESS_DOCTEST_MAIN), -LintId::of(double_comparison::DOUBLE_COMPARISONS), -LintId::of(double_parens::DOUBLE_PARENS), -LintId::of(drop_forget_ref::DROP_COPY), -LintId::of(drop_forget_ref::DROP_REF), -LintId::of(drop_forget_ref::FORGET_COPY), -LintId::of(drop_forget_ref::FORGET_REF), -LintId::of(duration_subsec::DURATION_SUBSEC), -LintId::of(entry::MAP_ENTRY), -LintId::of(enum_clike::ENUM_CLIKE_UNPORTABLE_VARIANT), -LintId::of(enum_variants::ENUM_VARIANT_NAMES), -LintId::of(enum_variants::MODULE_INCEPTION), -LintId::of(eq_op::EQ_OP), -LintId::of(eq_op::OP_REF), -LintId::of(erasing_op::ERASING_OP), -LintId::of(escape::BOXED_LOCAL), -LintId::of(eta_reduction::REDUNDANT_CLOSURE), -LintId::of(eval_order_dependence::DIVERGING_SUB_EXPRESSION), -LintId::of(eval_order_dependence::EVAL_ORDER_DEPENDENCE), -LintId::of(explicit_write::EXPLICIT_WRITE), -LintId::of(float_equality_without_abs::FLOAT_EQUALITY_WITHOUT_ABS), -LintId::of(float_literal::EXCESSIVE_PRECISION), -LintId::of(format::USELESS_FORMAT), -LintId::of(formatting::POSSIBLE_MISSING_COMMA), -LintId::of(formatting::SUSPICIOUS_ASSIGNMENT_FORMATTING), -LintId::of(formatting::SUSPICIOUS_ELSE_FORMATTING), -LintId::of(formatting::SUSPICIOUS_UNARY_OP_FORMATTING), -LintId::of(from_over_into::FROM_OVER_INTO), -LintId::of(from_str_radix_10::FROM_STR_RADIX_10), -LintId::of(functions::DOUBLE_MUST_USE), -LintId::of(functions::MUST_USE_UNIT), -LintId::of(functions::NOT_UNSAFE_PTR_ARG_DEREF), -LintId::of(functions::RESULT_UNIT_ERR), -LintId::of(functions::TOO_MANY_ARGUMENTS), -LintId::of(get_last_with_len::GET_LAST_WITH_LEN), -LintId::of(identity_op::IDENTITY_OP), -LintId::of(if_let_mutex::IF_LET_MUTEX), -LintId::of(if_then_panic::IF_THEN_PANIC), -LintId::of(indexing_slicing::OUT_OF_BOUNDS_INDEXING), -LintId::of(infinite_iter::INFINITE_ITER), -LintId::of(inherent_to_string::INHERENT_TO_STRING), -LintId::of(inherent_to_string::INHERENT_TO_STRING_SHADOW_DISPLAY), -LintId::of(inline_fn_without_body::INLINE_FN_WITHOUT_BODY), -LintId::of(int_plus_one::INT_PLUS_ONE), -LintId::of(large_const_arrays::LARGE_CONST_ARRAYS), -LintId::of(large_enum_variant::LARGE_ENUM_VARIANT), -LintId::of(len_zero::COMPARISON_TO_EMPTY), -LintId::of(len_zero::LEN_WITHOUT_IS_EMPTY), -LintId::of(len_zero::LEN_ZERO), -LintId::of(let_underscore::LET_UNDERSCORE_LOCK), -LintId::of(lifetimes::EXTRA_UNUSED_LIFETIMES), -LintId::of(lifetimes::NEEDLESS_LIFETIMES), -LintId::of(literal_representation::INCONSISTENT_DIGIT_GROUPING), -LintId::of(literal_representation::MISTYPED_LITERAL_SUFFIXES), -LintId::of(literal_representation::UNUSUAL_BYTE_GROUPINGS), -LintId::of(loops::EMPTY_LOOP), -LintId::of(loops::EXPLICIT_COUNTER_LOOP), -LintId::of(loops::FOR_KV_MAP), -LintId::of(loops::FOR_LOOPS_OVER_FALLIBLES), -LintId::of(loops::ITER_NEXT_LOOP), -LintId::of(loops::MANUAL_FLATTEN), -LintId::of(loops::MANUAL_MEMCPY), -LintId::of(loops::MUT_RANGE_BOUND), -LintId::of(loops::NEEDLESS_COLLECT), -LintId::of(loops::NEEDLESS_RANGE_LOOP), -LintId::of(loops::NEVER_LOOP), -LintId::of(loops::SAME_ITEM_PUSH), -LintId::of(loops::SINGLE_ELEMENT_LOOP), -LintId::of(loops::WHILE_IMMUTABLE_CONDITION), -LintId::of(loops::WHILE_LET_LOOP), -LintId::of(loops::WHILE_LET_ON_ITERATOR), -LintId::of(main_recursion::MAIN_RECURSION), -LintId::of(manual_async_fn::MANUAL_ASYNC_FN), -LintId::of(manual_map::MANUAL_MAP), -LintId::of(manual_non_exhaustive::MANUAL_NON_EXHAUSTIVE), -LintId::of(manual_strip::MANUAL_STRIP), -LintId::of(manual_unwrap_or::MANUAL_UNWRAP_OR), -LintId::of(map_clone::MAP_CLONE), -LintId::of(map_unit_fn::OPTION_MAP_UNIT_FN), -LintId::of(map_unit_fn::RESULT_MAP_UNIT_FN), -LintId::of(match_result_ok::MATCH_RESULT_OK), -LintId::of(matches::INFALLIBLE_DESTRUCTURING_MATCH), -LintId::of(matches::MATCH_AS_REF), -LintId::of(matches::MATCH_LIKE_MATCHES_MACRO), -LintId::of(matches::MATCH_OVERLAPPING_ARM), -LintId::of(matches::MATCH_REF_PATS), -LintId::of(matches::MATCH_SINGLE_BINDING), -LintId::of(matches::REDUNDANT_PATTERN_MATCHING), -LintId::of(matches::SINGLE_MATCH), -LintId::of(matches::WILDCARD_IN_OR_PATTERNS), -LintId::of(mem_discriminant::MEM_DISCRIMINANT_NON_ENUM), -LintId::of(mem_replace::MEM_REPLACE_OPTION_WITH_NONE), -LintId::of(mem_replace::MEM_REPLACE_WITH_DEFAULT), -LintId::of(mem_replace::MEM_REPLACE_WITH_UNINIT), -LintId::of(methods::BIND_INSTEAD_OF_MAP), -LintId::of(methods::BYTES_NTH), -LintId::of(methods::CHARS_LAST_CMP), -LintId::of(methods::CHARS_NEXT_CMP), -LintId::of(methods::CLONE_DOUBLE_REF), -LintId::of(methods::CLONE_ON_COPY), -LintId::of(methods::EXPECT_FUN_CALL), -LintId::of(methods::EXTEND_WITH_DRAIN), -LintId::of(methods::FILTER_MAP_IDENTITY), -LintId::of(methods::FILTER_NEXT), -LintId::of(methods::FLAT_MAP_IDENTITY), -LintId::of(methods::INSPECT_FOR_EACH), -LintId::of(methods::INTO_ITER_ON_REF), -LintId::of(methods::ITERATOR_STEP_BY_ZERO), -LintId::of(methods::ITER_CLONED_COLLECT), -LintId::of(methods::ITER_COUNT), -LintId::of(methods::ITER_NEXT_SLICE), -LintId::of(methods::ITER_NTH), -LintId::of(methods::ITER_NTH_ZERO), -LintId::of(methods::ITER_SKIP_NEXT), -LintId::of(methods::MANUAL_FILTER_MAP), -LintId::of(methods::MANUAL_FIND_MAP), -LintId::of(methods::MANUAL_SATURATING_ARITHMETIC), -LintId::of(methods::MANUAL_SPLIT_ONCE), -LintId::of(methods::MANUAL_STR_REPEAT), -LintId::of(methods::MAP_COLLECT_RESULT_UNIT), -LintId::of(methods::MAP_IDENTITY), -LintId::of(methods::NEW_RET_NO_SELF), -LintId::of(methods::OK_EXPECT), -LintId::of(methods::OPTION_AS_REF_DEREF), -LintId::of(methods::OPTION_FILTER_MAP), -LintId::of(methods::OPTION_MAP_OR_NONE), -LintId::of(methods::OR_FUN_CALL), -LintId::of(methods::RESULT_MAP_OR_INTO_OPTION), -LintId::of(methods::SEARCH_IS_SOME), -LintId::of(methods::SHOULD_IMPLEMENT_TRAIT), -LintId::of(methods::SINGLE_CHAR_ADD_STR), -LintId::of(methods::SINGLE_CHAR_PATTERN), -LintId::of(methods::SKIP_WHILE_NEXT), -LintId::of(methods::STRING_EXTEND_CHARS), -LintId::of(methods::SUSPICIOUS_MAP), -LintId::of(methods::SUSPICIOUS_SPLITN), -LintId::of(methods::UNINIT_ASSUMED_INIT), -LintId::of(methods::UNNECESSARY_FILTER_MAP), -LintId::of(methods::UNNECESSARY_FOLD), -LintId::of(methods::UNNECESSARY_LAZY_EVALUATIONS), -LintId::of(methods::UNWRAP_OR_ELSE_DEFAULT), -LintId::of(methods::USELESS_ASREF), -LintId::of(methods::WRONG_SELF_CONVENTION), -LintId::of(methods::ZST_OFFSET), -LintId::of(minmax::MIN_MAX), -LintId::of(misc::CMP_NAN), -LintId::of(misc::CMP_OWNED), -LintId::of(misc::MODULO_ONE), -LintId::of(misc::SHORT_CIRCUIT_STATEMENT), -LintId::of(misc::TOPLEVEL_REF_ARG), -LintId::of(misc::ZERO_PTR), -LintId::of(misc_early::BUILTIN_TYPE_SHADOW), -LintId::of(misc_early::DOUBLE_NEG), -LintId::of(misc_early::DUPLICATE_UNDERSCORE_ARGUMENT), -LintId::of(misc_early::MIXED_CASE_HEX_LITERALS), -LintId::of(misc_early::REDUNDANT_PATTERN), -LintId::of(misc_early::UNNEEDED_WILDCARD_PATTERN), -LintId::of(misc_early::ZERO_PREFIXED_LITERAL), -LintId::of(mut_key::MUTABLE_KEY_TYPE), -LintId::of(mut_mutex_lock::MUT_MUTEX_LOCK), -LintId::of(mut_reference::UNNECESSARY_MUT_PASSED), -LintId::of(mutex_atomic::MUTEX_ATOMIC), -LintId::of(needless_arbitrary_self_type::NEEDLESS_ARBITRARY_SELF_TYPE), -LintId::of(needless_bool::BOOL_COMPARISON), -LintId::of(needless_bool::NEEDLESS_BOOL), -LintId::of(needless_borrow::NEEDLESS_BORROW), -LintId::of(needless_borrowed_ref::NEEDLESS_BORROWED_REFERENCE), -LintId::of(needless_option_as_deref::NEEDLESS_OPTION_AS_DEREF), -LintId::of(needless_question_mark::NEEDLESS_QUESTION_MARK), -LintId::of(needless_update::NEEDLESS_UPDATE), -LintId::of(neg_cmp_op_on_partial_ord::NEG_CMP_OP_ON_PARTIAL_ORD), -LintId::of(neg_multiply::NEG_MULTIPLY), -LintId::of(new_without_default::NEW_WITHOUT_DEFAULT), -LintId::of(no_effect::NO_EFFECT), -LintId::of(no_effect::UNNECESSARY_OPERATION), -LintId::of(non_copy_const::BORROW_INTERIOR_MUTABLE_CONST), -LintId::of(non_copy_const::DECLARE_INTERIOR_MUTABLE_CONST), -LintId::of(non_expressive_names::JUST_UNDERSCORES_AND_DIGITS), -LintId::of(non_octal_unix_permissions::NON_OCTAL_UNIX_PERMISSIONS), -LintId::of(open_options::NONSENSICAL_OPEN_OPTIONS), -LintId::of(option_env_unwrap::OPTION_ENV_UNWRAP), -LintId::of(overflow_check_conditional::OVERFLOW_CHECK_CONDITIONAL), -LintId::of(partialeq_ne_impl::PARTIALEQ_NE_IMPL), -LintId::of(precedence::PRECEDENCE), -LintId::of(ptr::CMP_NULL), -LintId::of(ptr::INVALID_NULL_PTR_USAGE), -LintId::of(ptr::MUT_FROM_REF), -LintId::of(ptr::PTR_ARG), -LintId::of(ptr_eq::PTR_EQ), -LintId::of(ptr_offset_with_cast::PTR_OFFSET_WITH_CAST), -LintId::of(question_mark::QUESTION_MARK), -LintId::of(ranges::MANUAL_RANGE_CONTAINS), -LintId::of(ranges::RANGE_ZIP_WITH_LEN), -LintId::of(ranges::REVERSED_EMPTY_RANGES), -LintId::of(redundant_clone::REDUNDANT_CLONE), -LintId::of(redundant_closure_call::REDUNDANT_CLOSURE_CALL), -LintId::of(redundant_field_names::REDUNDANT_FIELD_NAMES), -LintId::of(redundant_slicing::REDUNDANT_SLICING), -LintId::of(redundant_static_lifetimes::REDUNDANT_STATIC_LIFETIMES), -LintId::of(reference::DEREF_ADDROF), -LintId::of(reference::REF_IN_DEREF), -LintId::of(regex::INVALID_REGEX), -LintId::of(repeat_once::REPEAT_ONCE), -LintId::of(returns::LET_AND_RETURN), -LintId::of(returns::NEEDLESS_RETURN), -LintId::of(self_assignment::SELF_ASSIGNMENT), -LintId::of(self_named_constructors::SELF_NAMED_CONSTRUCTORS), -LintId::of(serde_api::SERDE_API_MISUSE), -LintId::of(single_component_path_imports::SINGLE_COMPONENT_PATH_IMPORTS), -LintId::of(size_of_in_element_count::SIZE_OF_IN_ELEMENT_COUNT), -LintId::of(slow_vector_initialization::SLOW_VECTOR_INITIALIZATION), -LintId::of(stable_sort_primitive::STABLE_SORT_PRIMITIVE), -LintId::of(strings::STRING_FROM_UTF8_AS_BYTES), -LintId::of(strlen_on_c_strings::STRLEN_ON_C_STRINGS), -LintId::of(suspicious_trait_impl::SUSPICIOUS_ARITHMETIC_IMPL), -LintId::of(suspicious_trait_impl::SUSPICIOUS_OP_ASSIGN_IMPL), -LintId::of(swap::ALMOST_SWAPPED), -LintId::of(swap::MANUAL_SWAP), -LintId::of(tabs_in_doc_comments::TABS_IN_DOC_COMMENTS), -LintId::of(temporary_assignment::TEMPORARY_ASSIGNMENT), -LintId::of(to_digit_is_some::TO_DIGIT_IS_SOME), -LintId::of(to_string_in_display::TO_STRING_IN_DISPLAY), -LintId::of(transmute::CROSSPOINTER_TRANSMUTE), -LintId::of(transmute::TRANSMUTES_EXPRESSIBLE_AS_PTR_CASTS), -LintId::of(transmute::TRANSMUTE_BYTES_TO_STR), -LintId::of(transmute::TRANSMUTE_FLOAT_TO_INT), -LintId::of(transmute::TRANSMUTE_INT_TO_BOOL), -LintId::of(transmute::TRANSMUTE_INT_TO_CHAR), -LintId::of(transmute::TRANSMUTE_INT_TO_FLOAT), -LintId::of(transmute::TRANSMUTE_PTR_TO_REF), -LintId::of(transmute::UNSOUND_COLLECTION_TRANSMUTE), -LintId::of(transmute::WRONG_TRANSMUTE), -LintId::of(transmuting_null::TRANSMUTING_NULL), -LintId::of(try_err::TRY_ERR), -LintId::of(types::BORROWED_BOX), -LintId::of(types::BOX_COLLECTION), -LintId::of(types::REDUNDANT_ALLOCATION), -LintId::of(types::TYPE_COMPLEXITY), -LintId::of(types::VEC_BOX), -LintId::of(undropped_manually_drops::UNDROPPED_MANUALLY_DROPS), -LintId::of(unicode::INVISIBLE_CHARACTERS), -LintId::of(unit_return_expecting_ord::UNIT_RETURN_EXPECTING_ORD), -LintId::of(unit_types::UNIT_ARG), -LintId::of(unit_types::UNIT_CMP), -LintId::of(unnamed_address::FN_ADDRESS_COMPARISONS), -LintId::of(unnamed_address::VTABLE_ADDRESS_COMPARISONS), -LintId::of(unnecessary_sort_by::UNNECESSARY_SORT_BY), -LintId::of(unsafe_removed_from_name::UNSAFE_REMOVED_FROM_NAME), -LintId::of(unused_io_amount::UNUSED_IO_AMOUNT), -LintId::of(unused_unit::UNUSED_UNIT), -LintId::of(unwrap::PANICKING_UNWRAP), -LintId::of(unwrap::UNNECESSARY_UNWRAP), -LintId::of(upper_case_acronyms::UPPER_CASE_ACRONYMS), -LintId::of(useless_conversion::USELESS_CONVERSION), -LintId::of(vec::USELESS_VEC), -LintId::of(vec_init_then_push::VEC_INIT_THEN_PUSH), -LintId::of(vec_resize_to_zero::VEC_RESIZE_TO_ZERO), -LintId::of(write::PRINTLN_EMPTY_STRING), -LintId::of(write::PRINT_LITERAL), -LintId::of(write::PRINT_WITH_NEWLINE), -LintId::of(write::WRITELN_EMPTY_STRING), -LintId::of(write::WRITE_LITERAL), -LintId::of(write::WRITE_WITH_NEWLINE), -LintId::of(zero_div_zero::ZERO_DIVIDED_BY_ZERO), -]) \ No newline at end of file + LintId::of(absurd_extreme_comparisons::ABSURD_EXTREME_COMPARISONS), + LintId::of(approx_const::APPROX_CONSTANT), + LintId::of(assertions_on_constants::ASSERTIONS_ON_CONSTANTS), + LintId::of(assign_ops::ASSIGN_OP_PATTERN), + LintId::of(assign_ops::MISREFACTORED_ASSIGN_OP), + LintId::of(async_yields_async::ASYNC_YIELDS_ASYNC), + LintId::of(attrs::BLANKET_CLIPPY_RESTRICTION_LINTS), + LintId::of(attrs::DEPRECATED_CFG_ATTR), + LintId::of(attrs::DEPRECATED_SEMVER), + LintId::of(attrs::MISMATCHED_TARGET_OS), + LintId::of(attrs::USELESS_ATTRIBUTE), + LintId::of(bit_mask::BAD_BIT_MASK), + LintId::of(bit_mask::INEFFECTIVE_BIT_MASK), + LintId::of(blacklisted_name::BLACKLISTED_NAME), + LintId::of(blocks_in_if_conditions::BLOCKS_IN_IF_CONDITIONS), + LintId::of(bool_assert_comparison::BOOL_ASSERT_COMPARISON), + LintId::of(booleans::LOGIC_BUG), + LintId::of(booleans::NONMINIMAL_BOOL), + LintId::of(casts::CAST_REF_TO_MUT), + LintId::of(casts::CHAR_LIT_AS_U8), + LintId::of(casts::FN_TO_NUMERIC_CAST), + LintId::of(casts::FN_TO_NUMERIC_CAST_WITH_TRUNCATION), + LintId::of(casts::UNNECESSARY_CAST), + LintId::of(collapsible_if::COLLAPSIBLE_ELSE_IF), + LintId::of(collapsible_if::COLLAPSIBLE_IF), + LintId::of(collapsible_match::COLLAPSIBLE_MATCH), + LintId::of(comparison_chain::COMPARISON_CHAIN), + LintId::of(copies::IFS_SAME_COND), + LintId::of(copies::IF_SAME_THEN_ELSE), + LintId::of(default::FIELD_REASSIGN_WITH_DEFAULT), + LintId::of(derivable_impls::DERIVABLE_IMPLS), + LintId::of(derive::DERIVE_HASH_XOR_EQ), + LintId::of(derive::DERIVE_ORD_XOR_PARTIAL_ORD), + LintId::of(doc::MISSING_SAFETY_DOC), + LintId::of(doc::NEEDLESS_DOCTEST_MAIN), + LintId::of(double_comparison::DOUBLE_COMPARISONS), + LintId::of(double_parens::DOUBLE_PARENS), + LintId::of(drop_forget_ref::DROP_COPY), + LintId::of(drop_forget_ref::DROP_REF), + LintId::of(drop_forget_ref::FORGET_COPY), + LintId::of(drop_forget_ref::FORGET_REF), + LintId::of(duration_subsec::DURATION_SUBSEC), + LintId::of(entry::MAP_ENTRY), + LintId::of(enum_clike::ENUM_CLIKE_UNPORTABLE_VARIANT), + LintId::of(enum_variants::ENUM_VARIANT_NAMES), + LintId::of(enum_variants::MODULE_INCEPTION), + LintId::of(eq_op::EQ_OP), + LintId::of(eq_op::OP_REF), + LintId::of(erasing_op::ERASING_OP), + LintId::of(escape::BOXED_LOCAL), + LintId::of(eta_reduction::REDUNDANT_CLOSURE), + LintId::of(eval_order_dependence::DIVERGING_SUB_EXPRESSION), + LintId::of(eval_order_dependence::EVAL_ORDER_DEPENDENCE), + LintId::of(explicit_write::EXPLICIT_WRITE), + LintId::of(float_equality_without_abs::FLOAT_EQUALITY_WITHOUT_ABS), + LintId::of(float_literal::EXCESSIVE_PRECISION), + LintId::of(format::USELESS_FORMAT), + LintId::of(formatting::POSSIBLE_MISSING_COMMA), + LintId::of(formatting::SUSPICIOUS_ASSIGNMENT_FORMATTING), + LintId::of(formatting::SUSPICIOUS_ELSE_FORMATTING), + LintId::of(formatting::SUSPICIOUS_UNARY_OP_FORMATTING), + LintId::of(from_over_into::FROM_OVER_INTO), + LintId::of(from_str_radix_10::FROM_STR_RADIX_10), + LintId::of(functions::DOUBLE_MUST_USE), + LintId::of(functions::MUST_USE_UNIT), + LintId::of(functions::NOT_UNSAFE_PTR_ARG_DEREF), + LintId::of(functions::RESULT_UNIT_ERR), + LintId::of(functions::TOO_MANY_ARGUMENTS), + LintId::of(get_last_with_len::GET_LAST_WITH_LEN), + LintId::of(identity_op::IDENTITY_OP), + LintId::of(if_let_mutex::IF_LET_MUTEX), + LintId::of(if_then_panic::IF_THEN_PANIC), + LintId::of(indexing_slicing::OUT_OF_BOUNDS_INDEXING), + LintId::of(infinite_iter::INFINITE_ITER), + LintId::of(inherent_to_string::INHERENT_TO_STRING), + LintId::of(inherent_to_string::INHERENT_TO_STRING_SHADOW_DISPLAY), + LintId::of(inline_fn_without_body::INLINE_FN_WITHOUT_BODY), + LintId::of(int_plus_one::INT_PLUS_ONE), + LintId::of(large_const_arrays::LARGE_CONST_ARRAYS), + LintId::of(large_enum_variant::LARGE_ENUM_VARIANT), + LintId::of(len_zero::COMPARISON_TO_EMPTY), + LintId::of(len_zero::LEN_WITHOUT_IS_EMPTY), + LintId::of(len_zero::LEN_ZERO), + LintId::of(let_underscore::LET_UNDERSCORE_LOCK), + LintId::of(lifetimes::EXTRA_UNUSED_LIFETIMES), + LintId::of(lifetimes::NEEDLESS_LIFETIMES), + LintId::of(literal_representation::INCONSISTENT_DIGIT_GROUPING), + LintId::of(literal_representation::MISTYPED_LITERAL_SUFFIXES), + LintId::of(literal_representation::UNUSUAL_BYTE_GROUPINGS), + LintId::of(loops::EMPTY_LOOP), + LintId::of(loops::EXPLICIT_COUNTER_LOOP), + LintId::of(loops::FOR_KV_MAP), + LintId::of(loops::FOR_LOOPS_OVER_FALLIBLES), + LintId::of(loops::ITER_NEXT_LOOP), + LintId::of(loops::MANUAL_FLATTEN), + LintId::of(loops::MANUAL_MEMCPY), + LintId::of(loops::MUT_RANGE_BOUND), + LintId::of(loops::NEEDLESS_COLLECT), + LintId::of(loops::NEEDLESS_RANGE_LOOP), + LintId::of(loops::NEVER_LOOP), + LintId::of(loops::SAME_ITEM_PUSH), + LintId::of(loops::SINGLE_ELEMENT_LOOP), + LintId::of(loops::WHILE_IMMUTABLE_CONDITION), + LintId::of(loops::WHILE_LET_LOOP), + LintId::of(loops::WHILE_LET_ON_ITERATOR), + LintId::of(main_recursion::MAIN_RECURSION), + LintId::of(manual_async_fn::MANUAL_ASYNC_FN), + LintId::of(manual_map::MANUAL_MAP), + LintId::of(manual_non_exhaustive::MANUAL_NON_EXHAUSTIVE), + LintId::of(manual_strip::MANUAL_STRIP), + LintId::of(manual_unwrap_or::MANUAL_UNWRAP_OR), + LintId::of(map_clone::MAP_CLONE), + LintId::of(map_unit_fn::OPTION_MAP_UNIT_FN), + LintId::of(map_unit_fn::RESULT_MAP_UNIT_FN), + LintId::of(match_result_ok::MATCH_RESULT_OK), + LintId::of(matches::INFALLIBLE_DESTRUCTURING_MATCH), + LintId::of(matches::MATCH_AS_REF), + LintId::of(matches::MATCH_LIKE_MATCHES_MACRO), + LintId::of(matches::MATCH_OVERLAPPING_ARM), + LintId::of(matches::MATCH_REF_PATS), + LintId::of(matches::MATCH_SINGLE_BINDING), + LintId::of(matches::REDUNDANT_PATTERN_MATCHING), + LintId::of(matches::SINGLE_MATCH), + LintId::of(matches::WILDCARD_IN_OR_PATTERNS), + LintId::of(mem_discriminant::MEM_DISCRIMINANT_NON_ENUM), + LintId::of(mem_replace::MEM_REPLACE_OPTION_WITH_NONE), + LintId::of(mem_replace::MEM_REPLACE_WITH_DEFAULT), + LintId::of(mem_replace::MEM_REPLACE_WITH_UNINIT), + LintId::of(methods::BIND_INSTEAD_OF_MAP), + LintId::of(methods::BYTES_NTH), + LintId::of(methods::CHARS_LAST_CMP), + LintId::of(methods::CHARS_NEXT_CMP), + LintId::of(methods::CLONE_DOUBLE_REF), + LintId::of(methods::CLONE_ON_COPY), + LintId::of(methods::EXPECT_FUN_CALL), + LintId::of(methods::EXTEND_WITH_DRAIN), + LintId::of(methods::FILTER_MAP_IDENTITY), + LintId::of(methods::FILTER_NEXT), + LintId::of(methods::FLAT_MAP_IDENTITY), + LintId::of(methods::INSPECT_FOR_EACH), + LintId::of(methods::INTO_ITER_ON_REF), + LintId::of(methods::ITERATOR_STEP_BY_ZERO), + LintId::of(methods::ITER_CLONED_COLLECT), + LintId::of(methods::ITER_COUNT), + LintId::of(methods::ITER_NEXT_SLICE), + LintId::of(methods::ITER_NTH), + LintId::of(methods::ITER_NTH_ZERO), + LintId::of(methods::ITER_SKIP_NEXT), + LintId::of(methods::MANUAL_FILTER_MAP), + LintId::of(methods::MANUAL_FIND_MAP), + LintId::of(methods::MANUAL_SATURATING_ARITHMETIC), + LintId::of(methods::MANUAL_SPLIT_ONCE), + LintId::of(methods::MANUAL_STR_REPEAT), + LintId::of(methods::MAP_COLLECT_RESULT_UNIT), + LintId::of(methods::MAP_IDENTITY), + LintId::of(methods::NEW_RET_NO_SELF), + LintId::of(methods::OK_EXPECT), + LintId::of(methods::OPTION_AS_REF_DEREF), + LintId::of(methods::OPTION_FILTER_MAP), + LintId::of(methods::OPTION_MAP_OR_NONE), + LintId::of(methods::OR_FUN_CALL), + LintId::of(methods::RESULT_MAP_OR_INTO_OPTION), + LintId::of(methods::SEARCH_IS_SOME), + LintId::of(methods::SHOULD_IMPLEMENT_TRAIT), + LintId::of(methods::SINGLE_CHAR_ADD_STR), + LintId::of(methods::SINGLE_CHAR_PATTERN), + LintId::of(methods::SKIP_WHILE_NEXT), + LintId::of(methods::STRING_EXTEND_CHARS), + LintId::of(methods::SUSPICIOUS_MAP), + LintId::of(methods::SUSPICIOUS_SPLITN), + LintId::of(methods::UNINIT_ASSUMED_INIT), + LintId::of(methods::UNNECESSARY_FILTER_MAP), + LintId::of(methods::UNNECESSARY_FOLD), + LintId::of(methods::UNNECESSARY_LAZY_EVALUATIONS), + LintId::of(methods::UNWRAP_OR_ELSE_DEFAULT), + LintId::of(methods::USELESS_ASREF), + LintId::of(methods::WRONG_SELF_CONVENTION), + LintId::of(methods::ZST_OFFSET), + LintId::of(minmax::MIN_MAX), + LintId::of(misc::CMP_NAN), + LintId::of(misc::CMP_OWNED), + LintId::of(misc::MODULO_ONE), + LintId::of(misc::SHORT_CIRCUIT_STATEMENT), + LintId::of(misc::TOPLEVEL_REF_ARG), + LintId::of(misc::ZERO_PTR), + LintId::of(misc_early::BUILTIN_TYPE_SHADOW), + LintId::of(misc_early::DOUBLE_NEG), + LintId::of(misc_early::DUPLICATE_UNDERSCORE_ARGUMENT), + LintId::of(misc_early::MIXED_CASE_HEX_LITERALS), + LintId::of(misc_early::REDUNDANT_PATTERN), + LintId::of(misc_early::UNNEEDED_WILDCARD_PATTERN), + LintId::of(misc_early::ZERO_PREFIXED_LITERAL), + LintId::of(mut_key::MUTABLE_KEY_TYPE), + LintId::of(mut_mutex_lock::MUT_MUTEX_LOCK), + LintId::of(mut_reference::UNNECESSARY_MUT_PASSED), + LintId::of(mutex_atomic::MUTEX_ATOMIC), + LintId::of(needless_arbitrary_self_type::NEEDLESS_ARBITRARY_SELF_TYPE), + LintId::of(needless_bool::BOOL_COMPARISON), + LintId::of(needless_bool::NEEDLESS_BOOL), + LintId::of(needless_borrow::NEEDLESS_BORROW), + LintId::of(needless_borrowed_ref::NEEDLESS_BORROWED_REFERENCE), + LintId::of(needless_option_as_deref::NEEDLESS_OPTION_AS_DEREF), + LintId::of(needless_question_mark::NEEDLESS_QUESTION_MARK), + LintId::of(needless_update::NEEDLESS_UPDATE), + LintId::of(neg_cmp_op_on_partial_ord::NEG_CMP_OP_ON_PARTIAL_ORD), + LintId::of(neg_multiply::NEG_MULTIPLY), + LintId::of(new_without_default::NEW_WITHOUT_DEFAULT), + LintId::of(no_effect::NO_EFFECT), + LintId::of(no_effect::UNNECESSARY_OPERATION), + LintId::of(non_copy_const::BORROW_INTERIOR_MUTABLE_CONST), + LintId::of(non_copy_const::DECLARE_INTERIOR_MUTABLE_CONST), + LintId::of(non_expressive_names::JUST_UNDERSCORES_AND_DIGITS), + LintId::of(non_octal_unix_permissions::NON_OCTAL_UNIX_PERMISSIONS), + LintId::of(open_options::NONSENSICAL_OPEN_OPTIONS), + LintId::of(option_env_unwrap::OPTION_ENV_UNWRAP), + LintId::of(overflow_check_conditional::OVERFLOW_CHECK_CONDITIONAL), + LintId::of(partialeq_ne_impl::PARTIALEQ_NE_IMPL), + LintId::of(precedence::PRECEDENCE), + LintId::of(ptr::CMP_NULL), + LintId::of(ptr::INVALID_NULL_PTR_USAGE), + LintId::of(ptr::MUT_FROM_REF), + LintId::of(ptr::PTR_ARG), + LintId::of(ptr_eq::PTR_EQ), + LintId::of(ptr_offset_with_cast::PTR_OFFSET_WITH_CAST), + LintId::of(question_mark::QUESTION_MARK), + LintId::of(ranges::MANUAL_RANGE_CONTAINS), + LintId::of(ranges::RANGE_ZIP_WITH_LEN), + LintId::of(ranges::REVERSED_EMPTY_RANGES), + LintId::of(redundant_clone::REDUNDANT_CLONE), + LintId::of(redundant_closure_call::REDUNDANT_CLOSURE_CALL), + LintId::of(redundant_field_names::REDUNDANT_FIELD_NAMES), + LintId::of(redundant_slicing::REDUNDANT_SLICING), + LintId::of(redundant_static_lifetimes::REDUNDANT_STATIC_LIFETIMES), + LintId::of(reference::DEREF_ADDROF), + LintId::of(reference::REF_IN_DEREF), + LintId::of(regex::INVALID_REGEX), + LintId::of(repeat_once::REPEAT_ONCE), + LintId::of(returns::LET_AND_RETURN), + LintId::of(returns::NEEDLESS_RETURN), + LintId::of(self_assignment::SELF_ASSIGNMENT), + LintId::of(self_named_constructors::SELF_NAMED_CONSTRUCTORS), + LintId::of(serde_api::SERDE_API_MISUSE), + LintId::of(single_component_path_imports::SINGLE_COMPONENT_PATH_IMPORTS), + LintId::of(size_of_in_element_count::SIZE_OF_IN_ELEMENT_COUNT), + LintId::of(slow_vector_initialization::SLOW_VECTOR_INITIALIZATION), + LintId::of(stable_sort_primitive::STABLE_SORT_PRIMITIVE), + LintId::of(strings::STRING_FROM_UTF8_AS_BYTES), + LintId::of(strlen_on_c_strings::STRLEN_ON_C_STRINGS), + LintId::of(suspicious_trait_impl::SUSPICIOUS_ARITHMETIC_IMPL), + LintId::of(suspicious_trait_impl::SUSPICIOUS_OP_ASSIGN_IMPL), + LintId::of(swap::ALMOST_SWAPPED), + LintId::of(swap::MANUAL_SWAP), + LintId::of(tabs_in_doc_comments::TABS_IN_DOC_COMMENTS), + LintId::of(temporary_assignment::TEMPORARY_ASSIGNMENT), + LintId::of(to_digit_is_some::TO_DIGIT_IS_SOME), + LintId::of(to_string_in_display::TO_STRING_IN_DISPLAY), + LintId::of(transmute::CROSSPOINTER_TRANSMUTE), + LintId::of(transmute::TRANSMUTES_EXPRESSIBLE_AS_PTR_CASTS), + LintId::of(transmute::TRANSMUTE_BYTES_TO_STR), + LintId::of(transmute::TRANSMUTE_FLOAT_TO_INT), + LintId::of(transmute::TRANSMUTE_INT_TO_BOOL), + LintId::of(transmute::TRANSMUTE_INT_TO_CHAR), + LintId::of(transmute::TRANSMUTE_INT_TO_FLOAT), + LintId::of(transmute::TRANSMUTE_PTR_TO_REF), + LintId::of(transmute::UNSOUND_COLLECTION_TRANSMUTE), + LintId::of(transmute::WRONG_TRANSMUTE), + LintId::of(transmuting_null::TRANSMUTING_NULL), + LintId::of(try_err::TRY_ERR), + LintId::of(types::BORROWED_BOX), + LintId::of(types::BOX_COLLECTION), + LintId::of(types::REDUNDANT_ALLOCATION), + LintId::of(types::TYPE_COMPLEXITY), + LintId::of(types::VEC_BOX), + LintId::of(undropped_manually_drops::UNDROPPED_MANUALLY_DROPS), + LintId::of(unicode::INVISIBLE_CHARACTERS), + LintId::of(unit_return_expecting_ord::UNIT_RETURN_EXPECTING_ORD), + LintId::of(unit_types::UNIT_ARG), + LintId::of(unit_types::UNIT_CMP), + LintId::of(unnamed_address::FN_ADDRESS_COMPARISONS), + LintId::of(unnamed_address::VTABLE_ADDRESS_COMPARISONS), + LintId::of(unnecessary_sort_by::UNNECESSARY_SORT_BY), + LintId::of(unsafe_removed_from_name::UNSAFE_REMOVED_FROM_NAME), + LintId::of(unused_io_amount::UNUSED_IO_AMOUNT), + LintId::of(unused_unit::UNUSED_UNIT), + LintId::of(unwrap::PANICKING_UNWRAP), + LintId::of(unwrap::UNNECESSARY_UNWRAP), + LintId::of(upper_case_acronyms::UPPER_CASE_ACRONYMS), + LintId::of(useless_conversion::USELESS_CONVERSION), + LintId::of(vec::USELESS_VEC), + LintId::of(vec_init_then_push::VEC_INIT_THEN_PUSH), + LintId::of(vec_resize_to_zero::VEC_RESIZE_TO_ZERO), + LintId::of(write::PRINTLN_EMPTY_STRING), + LintId::of(write::PRINT_LITERAL), + LintId::of(write::PRINT_WITH_NEWLINE), + LintId::of(write::WRITELN_EMPTY_STRING), + LintId::of(write::WRITE_LITERAL), + LintId::of(write::WRITE_WITH_NEWLINE), + LintId::of(zero_div_zero::ZERO_DIVIDED_BY_ZERO), +]) diff --git a/clippy_lints/src/lib.register_cargo.rs b/clippy_lints/src/lib.register_cargo.rs index 21d070728e4..1809f2cc7d4 100644 --- a/clippy_lints/src/lib.register_cargo.rs +++ b/clippy_lints/src/lib.register_cargo.rs @@ -3,9 +3,9 @@ // Manual edits will be overwritten. store.register_group(true, "clippy::cargo", Some("clippy_cargo"), vec![ -LintId::of(cargo_common_metadata::CARGO_COMMON_METADATA), -LintId::of(feature_name::NEGATIVE_FEATURE_NAMES), -LintId::of(feature_name::REDUNDANT_FEATURE_NAMES), -LintId::of(multiple_crate_versions::MULTIPLE_CRATE_VERSIONS), -LintId::of(wildcard_dependencies::WILDCARD_DEPENDENCIES), -]) \ No newline at end of file + LintId::of(cargo_common_metadata::CARGO_COMMON_METADATA), + LintId::of(feature_name::NEGATIVE_FEATURE_NAMES), + LintId::of(feature_name::REDUNDANT_FEATURE_NAMES), + LintId::of(multiple_crate_versions::MULTIPLE_CRATE_VERSIONS), + LintId::of(wildcard_dependencies::WILDCARD_DEPENDENCIES), +]) diff --git a/clippy_lints/src/lib.register_complexity.rs b/clippy_lints/src/lib.register_complexity.rs index 515afe54c86..64b82fc0faa 100644 --- a/clippy_lints/src/lib.register_complexity.rs +++ b/clippy_lints/src/lib.register_complexity.rs @@ -3,92 +3,92 @@ // Manual edits will be overwritten. store.register_group(true, "clippy::complexity", Some("clippy_complexity"), vec![ -LintId::of(attrs::DEPRECATED_CFG_ATTR), -LintId::of(booleans::NONMINIMAL_BOOL), -LintId::of(casts::CHAR_LIT_AS_U8), -LintId::of(casts::UNNECESSARY_CAST), -LintId::of(derivable_impls::DERIVABLE_IMPLS), -LintId::of(double_comparison::DOUBLE_COMPARISONS), -LintId::of(double_parens::DOUBLE_PARENS), -LintId::of(duration_subsec::DURATION_SUBSEC), -LintId::of(eval_order_dependence::DIVERGING_SUB_EXPRESSION), -LintId::of(explicit_write::EXPLICIT_WRITE), -LintId::of(format::USELESS_FORMAT), -LintId::of(functions::TOO_MANY_ARGUMENTS), -LintId::of(get_last_with_len::GET_LAST_WITH_LEN), -LintId::of(identity_op::IDENTITY_OP), -LintId::of(int_plus_one::INT_PLUS_ONE), -LintId::of(lifetimes::EXTRA_UNUSED_LIFETIMES), -LintId::of(lifetimes::NEEDLESS_LIFETIMES), -LintId::of(loops::EXPLICIT_COUNTER_LOOP), -LintId::of(loops::MANUAL_FLATTEN), -LintId::of(loops::SINGLE_ELEMENT_LOOP), -LintId::of(loops::WHILE_LET_LOOP), -LintId::of(manual_strip::MANUAL_STRIP), -LintId::of(manual_unwrap_or::MANUAL_UNWRAP_OR), -LintId::of(map_unit_fn::OPTION_MAP_UNIT_FN), -LintId::of(map_unit_fn::RESULT_MAP_UNIT_FN), -LintId::of(matches::MATCH_AS_REF), -LintId::of(matches::MATCH_SINGLE_BINDING), -LintId::of(matches::WILDCARD_IN_OR_PATTERNS), -LintId::of(methods::BIND_INSTEAD_OF_MAP), -LintId::of(methods::CLONE_ON_COPY), -LintId::of(methods::FILTER_MAP_IDENTITY), -LintId::of(methods::FILTER_NEXT), -LintId::of(methods::FLAT_MAP_IDENTITY), -LintId::of(methods::INSPECT_FOR_EACH), -LintId::of(methods::ITER_COUNT), -LintId::of(methods::MANUAL_FILTER_MAP), -LintId::of(methods::MANUAL_FIND_MAP), -LintId::of(methods::MANUAL_SPLIT_ONCE), -LintId::of(methods::MAP_IDENTITY), -LintId::of(methods::OPTION_AS_REF_DEREF), -LintId::of(methods::OPTION_FILTER_MAP), -LintId::of(methods::SEARCH_IS_SOME), -LintId::of(methods::SKIP_WHILE_NEXT), -LintId::of(methods::UNNECESSARY_FILTER_MAP), -LintId::of(methods::USELESS_ASREF), -LintId::of(misc::SHORT_CIRCUIT_STATEMENT), -LintId::of(misc_early::UNNEEDED_WILDCARD_PATTERN), -LintId::of(misc_early::ZERO_PREFIXED_LITERAL), -LintId::of(needless_arbitrary_self_type::NEEDLESS_ARBITRARY_SELF_TYPE), -LintId::of(needless_bool::BOOL_COMPARISON), -LintId::of(needless_bool::NEEDLESS_BOOL), -LintId::of(needless_borrowed_ref::NEEDLESS_BORROWED_REFERENCE), -LintId::of(needless_option_as_deref::NEEDLESS_OPTION_AS_DEREF), -LintId::of(needless_question_mark::NEEDLESS_QUESTION_MARK), -LintId::of(needless_update::NEEDLESS_UPDATE), -LintId::of(neg_cmp_op_on_partial_ord::NEG_CMP_OP_ON_PARTIAL_ORD), -LintId::of(no_effect::NO_EFFECT), -LintId::of(no_effect::UNNECESSARY_OPERATION), -LintId::of(overflow_check_conditional::OVERFLOW_CHECK_CONDITIONAL), -LintId::of(partialeq_ne_impl::PARTIALEQ_NE_IMPL), -LintId::of(precedence::PRECEDENCE), -LintId::of(ptr_offset_with_cast::PTR_OFFSET_WITH_CAST), -LintId::of(ranges::RANGE_ZIP_WITH_LEN), -LintId::of(redundant_closure_call::REDUNDANT_CLOSURE_CALL), -LintId::of(redundant_slicing::REDUNDANT_SLICING), -LintId::of(reference::DEREF_ADDROF), -LintId::of(reference::REF_IN_DEREF), -LintId::of(repeat_once::REPEAT_ONCE), -LintId::of(strings::STRING_FROM_UTF8_AS_BYTES), -LintId::of(strlen_on_c_strings::STRLEN_ON_C_STRINGS), -LintId::of(swap::MANUAL_SWAP), -LintId::of(temporary_assignment::TEMPORARY_ASSIGNMENT), -LintId::of(transmute::CROSSPOINTER_TRANSMUTE), -LintId::of(transmute::TRANSMUTES_EXPRESSIBLE_AS_PTR_CASTS), -LintId::of(transmute::TRANSMUTE_BYTES_TO_STR), -LintId::of(transmute::TRANSMUTE_FLOAT_TO_INT), -LintId::of(transmute::TRANSMUTE_INT_TO_BOOL), -LintId::of(transmute::TRANSMUTE_INT_TO_CHAR), -LintId::of(transmute::TRANSMUTE_INT_TO_FLOAT), -LintId::of(transmute::TRANSMUTE_PTR_TO_REF), -LintId::of(types::BORROWED_BOX), -LintId::of(types::TYPE_COMPLEXITY), -LintId::of(types::VEC_BOX), -LintId::of(unit_types::UNIT_ARG), -LintId::of(unnecessary_sort_by::UNNECESSARY_SORT_BY), -LintId::of(unwrap::UNNECESSARY_UNWRAP), -LintId::of(useless_conversion::USELESS_CONVERSION), -LintId::of(zero_div_zero::ZERO_DIVIDED_BY_ZERO), -]) \ No newline at end of file + LintId::of(attrs::DEPRECATED_CFG_ATTR), + LintId::of(booleans::NONMINIMAL_BOOL), + LintId::of(casts::CHAR_LIT_AS_U8), + LintId::of(casts::UNNECESSARY_CAST), + LintId::of(derivable_impls::DERIVABLE_IMPLS), + LintId::of(double_comparison::DOUBLE_COMPARISONS), + LintId::of(double_parens::DOUBLE_PARENS), + LintId::of(duration_subsec::DURATION_SUBSEC), + LintId::of(eval_order_dependence::DIVERGING_SUB_EXPRESSION), + LintId::of(explicit_write::EXPLICIT_WRITE), + LintId::of(format::USELESS_FORMAT), + LintId::of(functions::TOO_MANY_ARGUMENTS), + LintId::of(get_last_with_len::GET_LAST_WITH_LEN), + LintId::of(identity_op::IDENTITY_OP), + LintId::of(int_plus_one::INT_PLUS_ONE), + LintId::of(lifetimes::EXTRA_UNUSED_LIFETIMES), + LintId::of(lifetimes::NEEDLESS_LIFETIMES), + LintId::of(loops::EXPLICIT_COUNTER_LOOP), + LintId::of(loops::MANUAL_FLATTEN), + LintId::of(loops::SINGLE_ELEMENT_LOOP), + LintId::of(loops::WHILE_LET_LOOP), + LintId::of(manual_strip::MANUAL_STRIP), + LintId::of(manual_unwrap_or::MANUAL_UNWRAP_OR), + LintId::of(map_unit_fn::OPTION_MAP_UNIT_FN), + LintId::of(map_unit_fn::RESULT_MAP_UNIT_FN), + LintId::of(matches::MATCH_AS_REF), + LintId::of(matches::MATCH_SINGLE_BINDING), + LintId::of(matches::WILDCARD_IN_OR_PATTERNS), + LintId::of(methods::BIND_INSTEAD_OF_MAP), + LintId::of(methods::CLONE_ON_COPY), + LintId::of(methods::FILTER_MAP_IDENTITY), + LintId::of(methods::FILTER_NEXT), + LintId::of(methods::FLAT_MAP_IDENTITY), + LintId::of(methods::INSPECT_FOR_EACH), + LintId::of(methods::ITER_COUNT), + LintId::of(methods::MANUAL_FILTER_MAP), + LintId::of(methods::MANUAL_FIND_MAP), + LintId::of(methods::MANUAL_SPLIT_ONCE), + LintId::of(methods::MAP_IDENTITY), + LintId::of(methods::OPTION_AS_REF_DEREF), + LintId::of(methods::OPTION_FILTER_MAP), + LintId::of(methods::SEARCH_IS_SOME), + LintId::of(methods::SKIP_WHILE_NEXT), + LintId::of(methods::UNNECESSARY_FILTER_MAP), + LintId::of(methods::USELESS_ASREF), + LintId::of(misc::SHORT_CIRCUIT_STATEMENT), + LintId::of(misc_early::UNNEEDED_WILDCARD_PATTERN), + LintId::of(misc_early::ZERO_PREFIXED_LITERAL), + LintId::of(needless_arbitrary_self_type::NEEDLESS_ARBITRARY_SELF_TYPE), + LintId::of(needless_bool::BOOL_COMPARISON), + LintId::of(needless_bool::NEEDLESS_BOOL), + LintId::of(needless_borrowed_ref::NEEDLESS_BORROWED_REFERENCE), + LintId::of(needless_option_as_deref::NEEDLESS_OPTION_AS_DEREF), + LintId::of(needless_question_mark::NEEDLESS_QUESTION_MARK), + LintId::of(needless_update::NEEDLESS_UPDATE), + LintId::of(neg_cmp_op_on_partial_ord::NEG_CMP_OP_ON_PARTIAL_ORD), + LintId::of(no_effect::NO_EFFECT), + LintId::of(no_effect::UNNECESSARY_OPERATION), + LintId::of(overflow_check_conditional::OVERFLOW_CHECK_CONDITIONAL), + LintId::of(partialeq_ne_impl::PARTIALEQ_NE_IMPL), + LintId::of(precedence::PRECEDENCE), + LintId::of(ptr_offset_with_cast::PTR_OFFSET_WITH_CAST), + LintId::of(ranges::RANGE_ZIP_WITH_LEN), + LintId::of(redundant_closure_call::REDUNDANT_CLOSURE_CALL), + LintId::of(redundant_slicing::REDUNDANT_SLICING), + LintId::of(reference::DEREF_ADDROF), + LintId::of(reference::REF_IN_DEREF), + LintId::of(repeat_once::REPEAT_ONCE), + LintId::of(strings::STRING_FROM_UTF8_AS_BYTES), + LintId::of(strlen_on_c_strings::STRLEN_ON_C_STRINGS), + LintId::of(swap::MANUAL_SWAP), + LintId::of(temporary_assignment::TEMPORARY_ASSIGNMENT), + LintId::of(transmute::CROSSPOINTER_TRANSMUTE), + LintId::of(transmute::TRANSMUTES_EXPRESSIBLE_AS_PTR_CASTS), + LintId::of(transmute::TRANSMUTE_BYTES_TO_STR), + LintId::of(transmute::TRANSMUTE_FLOAT_TO_INT), + LintId::of(transmute::TRANSMUTE_INT_TO_BOOL), + LintId::of(transmute::TRANSMUTE_INT_TO_CHAR), + LintId::of(transmute::TRANSMUTE_INT_TO_FLOAT), + LintId::of(transmute::TRANSMUTE_PTR_TO_REF), + LintId::of(types::BORROWED_BOX), + LintId::of(types::TYPE_COMPLEXITY), + LintId::of(types::VEC_BOX), + LintId::of(unit_types::UNIT_ARG), + LintId::of(unnecessary_sort_by::UNNECESSARY_SORT_BY), + LintId::of(unwrap::UNNECESSARY_UNWRAP), + LintId::of(useless_conversion::USELESS_CONVERSION), + LintId::of(zero_div_zero::ZERO_DIVIDED_BY_ZERO), +]) diff --git a/clippy_lints/src/lib.register_correctness.rs b/clippy_lints/src/lib.register_correctness.rs index ef42f930a96..e0ef7b3b8af 100644 --- a/clippy_lints/src/lib.register_correctness.rs +++ b/clippy_lints/src/lib.register_correctness.rs @@ -3,71 +3,71 @@ // Manual edits will be overwritten. store.register_group(true, "clippy::correctness", Some("clippy_correctness"), vec![ -LintId::of(absurd_extreme_comparisons::ABSURD_EXTREME_COMPARISONS), -LintId::of(approx_const::APPROX_CONSTANT), -LintId::of(async_yields_async::ASYNC_YIELDS_ASYNC), -LintId::of(attrs::DEPRECATED_SEMVER), -LintId::of(attrs::MISMATCHED_TARGET_OS), -LintId::of(attrs::USELESS_ATTRIBUTE), -LintId::of(bit_mask::BAD_BIT_MASK), -LintId::of(bit_mask::INEFFECTIVE_BIT_MASK), -LintId::of(booleans::LOGIC_BUG), -LintId::of(casts::CAST_REF_TO_MUT), -LintId::of(copies::IFS_SAME_COND), -LintId::of(copies::IF_SAME_THEN_ELSE), -LintId::of(derive::DERIVE_HASH_XOR_EQ), -LintId::of(derive::DERIVE_ORD_XOR_PARTIAL_ORD), -LintId::of(drop_forget_ref::DROP_COPY), -LintId::of(drop_forget_ref::DROP_REF), -LintId::of(drop_forget_ref::FORGET_COPY), -LintId::of(drop_forget_ref::FORGET_REF), -LintId::of(enum_clike::ENUM_CLIKE_UNPORTABLE_VARIANT), -LintId::of(eq_op::EQ_OP), -LintId::of(erasing_op::ERASING_OP), -LintId::of(formatting::POSSIBLE_MISSING_COMMA), -LintId::of(functions::NOT_UNSAFE_PTR_ARG_DEREF), -LintId::of(if_let_mutex::IF_LET_MUTEX), -LintId::of(indexing_slicing::OUT_OF_BOUNDS_INDEXING), -LintId::of(infinite_iter::INFINITE_ITER), -LintId::of(inherent_to_string::INHERENT_TO_STRING_SHADOW_DISPLAY), -LintId::of(inline_fn_without_body::INLINE_FN_WITHOUT_BODY), -LintId::of(let_underscore::LET_UNDERSCORE_LOCK), -LintId::of(literal_representation::MISTYPED_LITERAL_SUFFIXES), -LintId::of(loops::ITER_NEXT_LOOP), -LintId::of(loops::NEVER_LOOP), -LintId::of(loops::WHILE_IMMUTABLE_CONDITION), -LintId::of(mem_discriminant::MEM_DISCRIMINANT_NON_ENUM), -LintId::of(mem_replace::MEM_REPLACE_WITH_UNINIT), -LintId::of(methods::CLONE_DOUBLE_REF), -LintId::of(methods::ITERATOR_STEP_BY_ZERO), -LintId::of(methods::SUSPICIOUS_SPLITN), -LintId::of(methods::UNINIT_ASSUMED_INIT), -LintId::of(methods::ZST_OFFSET), -LintId::of(minmax::MIN_MAX), -LintId::of(misc::CMP_NAN), -LintId::of(misc::MODULO_ONE), -LintId::of(non_octal_unix_permissions::NON_OCTAL_UNIX_PERMISSIONS), -LintId::of(open_options::NONSENSICAL_OPEN_OPTIONS), -LintId::of(option_env_unwrap::OPTION_ENV_UNWRAP), -LintId::of(ptr::INVALID_NULL_PTR_USAGE), -LintId::of(ptr::MUT_FROM_REF), -LintId::of(ranges::REVERSED_EMPTY_RANGES), -LintId::of(regex::INVALID_REGEX), -LintId::of(self_assignment::SELF_ASSIGNMENT), -LintId::of(serde_api::SERDE_API_MISUSE), -LintId::of(size_of_in_element_count::SIZE_OF_IN_ELEMENT_COUNT), -LintId::of(swap::ALMOST_SWAPPED), -LintId::of(to_string_in_display::TO_STRING_IN_DISPLAY), -LintId::of(transmute::UNSOUND_COLLECTION_TRANSMUTE), -LintId::of(transmute::WRONG_TRANSMUTE), -LintId::of(transmuting_null::TRANSMUTING_NULL), -LintId::of(undropped_manually_drops::UNDROPPED_MANUALLY_DROPS), -LintId::of(unicode::INVISIBLE_CHARACTERS), -LintId::of(unit_return_expecting_ord::UNIT_RETURN_EXPECTING_ORD), -LintId::of(unit_types::UNIT_CMP), -LintId::of(unnamed_address::FN_ADDRESS_COMPARISONS), -LintId::of(unnamed_address::VTABLE_ADDRESS_COMPARISONS), -LintId::of(unused_io_amount::UNUSED_IO_AMOUNT), -LintId::of(unwrap::PANICKING_UNWRAP), -LintId::of(vec_resize_to_zero::VEC_RESIZE_TO_ZERO), -]) \ No newline at end of file + LintId::of(absurd_extreme_comparisons::ABSURD_EXTREME_COMPARISONS), + LintId::of(approx_const::APPROX_CONSTANT), + LintId::of(async_yields_async::ASYNC_YIELDS_ASYNC), + LintId::of(attrs::DEPRECATED_SEMVER), + LintId::of(attrs::MISMATCHED_TARGET_OS), + LintId::of(attrs::USELESS_ATTRIBUTE), + LintId::of(bit_mask::BAD_BIT_MASK), + LintId::of(bit_mask::INEFFECTIVE_BIT_MASK), + LintId::of(booleans::LOGIC_BUG), + LintId::of(casts::CAST_REF_TO_MUT), + LintId::of(copies::IFS_SAME_COND), + LintId::of(copies::IF_SAME_THEN_ELSE), + LintId::of(derive::DERIVE_HASH_XOR_EQ), + LintId::of(derive::DERIVE_ORD_XOR_PARTIAL_ORD), + LintId::of(drop_forget_ref::DROP_COPY), + LintId::of(drop_forget_ref::DROP_REF), + LintId::of(drop_forget_ref::FORGET_COPY), + LintId::of(drop_forget_ref::FORGET_REF), + LintId::of(enum_clike::ENUM_CLIKE_UNPORTABLE_VARIANT), + LintId::of(eq_op::EQ_OP), + LintId::of(erasing_op::ERASING_OP), + LintId::of(formatting::POSSIBLE_MISSING_COMMA), + LintId::of(functions::NOT_UNSAFE_PTR_ARG_DEREF), + LintId::of(if_let_mutex::IF_LET_MUTEX), + LintId::of(indexing_slicing::OUT_OF_BOUNDS_INDEXING), + LintId::of(infinite_iter::INFINITE_ITER), + LintId::of(inherent_to_string::INHERENT_TO_STRING_SHADOW_DISPLAY), + LintId::of(inline_fn_without_body::INLINE_FN_WITHOUT_BODY), + LintId::of(let_underscore::LET_UNDERSCORE_LOCK), + LintId::of(literal_representation::MISTYPED_LITERAL_SUFFIXES), + LintId::of(loops::ITER_NEXT_LOOP), + LintId::of(loops::NEVER_LOOP), + LintId::of(loops::WHILE_IMMUTABLE_CONDITION), + LintId::of(mem_discriminant::MEM_DISCRIMINANT_NON_ENUM), + LintId::of(mem_replace::MEM_REPLACE_WITH_UNINIT), + LintId::of(methods::CLONE_DOUBLE_REF), + LintId::of(methods::ITERATOR_STEP_BY_ZERO), + LintId::of(methods::SUSPICIOUS_SPLITN), + LintId::of(methods::UNINIT_ASSUMED_INIT), + LintId::of(methods::ZST_OFFSET), + LintId::of(minmax::MIN_MAX), + LintId::of(misc::CMP_NAN), + LintId::of(misc::MODULO_ONE), + LintId::of(non_octal_unix_permissions::NON_OCTAL_UNIX_PERMISSIONS), + LintId::of(open_options::NONSENSICAL_OPEN_OPTIONS), + LintId::of(option_env_unwrap::OPTION_ENV_UNWRAP), + LintId::of(ptr::INVALID_NULL_PTR_USAGE), + LintId::of(ptr::MUT_FROM_REF), + LintId::of(ranges::REVERSED_EMPTY_RANGES), + LintId::of(regex::INVALID_REGEX), + LintId::of(self_assignment::SELF_ASSIGNMENT), + LintId::of(serde_api::SERDE_API_MISUSE), + LintId::of(size_of_in_element_count::SIZE_OF_IN_ELEMENT_COUNT), + LintId::of(swap::ALMOST_SWAPPED), + LintId::of(to_string_in_display::TO_STRING_IN_DISPLAY), + LintId::of(transmute::UNSOUND_COLLECTION_TRANSMUTE), + LintId::of(transmute::WRONG_TRANSMUTE), + LintId::of(transmuting_null::TRANSMUTING_NULL), + LintId::of(undropped_manually_drops::UNDROPPED_MANUALLY_DROPS), + LintId::of(unicode::INVISIBLE_CHARACTERS), + LintId::of(unit_return_expecting_ord::UNIT_RETURN_EXPECTING_ORD), + LintId::of(unit_types::UNIT_CMP), + LintId::of(unnamed_address::FN_ADDRESS_COMPARISONS), + LintId::of(unnamed_address::VTABLE_ADDRESS_COMPARISONS), + LintId::of(unused_io_amount::UNUSED_IO_AMOUNT), + LintId::of(unwrap::PANICKING_UNWRAP), + LintId::of(vec_resize_to_zero::VEC_RESIZE_TO_ZERO), +]) diff --git a/clippy_lints/src/lib.register_internal.rs b/clippy_lints/src/lib.register_internal.rs index 7d43e2196cd..c8c1e0262ab 100644 --- a/clippy_lints/src/lib.register_internal.rs +++ b/clippy_lints/src/lib.register_internal.rs @@ -3,16 +3,16 @@ // Manual edits will be overwritten. store.register_group(true, "clippy::internal", Some("clippy_internal"), vec![ -LintId::of(utils::internal_lints::CLIPPY_LINTS_INTERNAL), -LintId::of(utils::internal_lints::COLLAPSIBLE_SPAN_LINT_CALLS), -LintId::of(utils::internal_lints::COMPILER_LINT_FUNCTIONS), -LintId::of(utils::internal_lints::DEFAULT_LINT), -LintId::of(utils::internal_lints::IF_CHAIN_STYLE), -LintId::of(utils::internal_lints::INTERNING_DEFINED_SYMBOL), -LintId::of(utils::internal_lints::INVALID_PATHS), -LintId::of(utils::internal_lints::LINT_WITHOUT_LINT_PASS), -LintId::of(utils::internal_lints::MATCH_TYPE_ON_DIAGNOSTIC_ITEM), -LintId::of(utils::internal_lints::OUTER_EXPN_EXPN_DATA), -LintId::of(utils::internal_lints::PRODUCE_ICE), -LintId::of(utils::internal_lints::UNNECESSARY_SYMBOL_STR), -]) \ No newline at end of file + LintId::of(utils::internal_lints::CLIPPY_LINTS_INTERNAL), + LintId::of(utils::internal_lints::COLLAPSIBLE_SPAN_LINT_CALLS), + LintId::of(utils::internal_lints::COMPILER_LINT_FUNCTIONS), + LintId::of(utils::internal_lints::DEFAULT_LINT), + LintId::of(utils::internal_lints::IF_CHAIN_STYLE), + LintId::of(utils::internal_lints::INTERNING_DEFINED_SYMBOL), + LintId::of(utils::internal_lints::INVALID_PATHS), + LintId::of(utils::internal_lints::LINT_WITHOUT_LINT_PASS), + LintId::of(utils::internal_lints::MATCH_TYPE_ON_DIAGNOSTIC_ITEM), + LintId::of(utils::internal_lints::OUTER_EXPN_EXPN_DATA), + LintId::of(utils::internal_lints::PRODUCE_ICE), + LintId::of(utils::internal_lints::UNNECESSARY_SYMBOL_STR), +]) diff --git a/clippy_lints/src/lib.register_lints.rs b/clippy_lints/src/lib.register_lints.rs index ed0de60c284..1ad27870b1a 100644 --- a/clippy_lints/src/lib.register_lints.rs +++ b/clippy_lints/src/lib.register_lints.rs @@ -2,507 +2,507 @@ // Use that command to update this file and do not edit by hand. // Manual edits will be overwritten. - store.register_lints(&[ - #[cfg(feature = "internal-lints")] - utils::internal_lints::CLIPPY_LINTS_INTERNAL, - #[cfg(feature = "internal-lints")] - utils::internal_lints::COLLAPSIBLE_SPAN_LINT_CALLS, - #[cfg(feature = "internal-lints")] - utils::internal_lints::COMPILER_LINT_FUNCTIONS, - #[cfg(feature = "internal-lints")] - utils::internal_lints::DEFAULT_LINT, - #[cfg(feature = "internal-lints")] - utils::internal_lints::IF_CHAIN_STYLE, - #[cfg(feature = "internal-lints")] - utils::internal_lints::INTERNING_DEFINED_SYMBOL, - #[cfg(feature = "internal-lints")] - utils::internal_lints::INVALID_PATHS, - #[cfg(feature = "internal-lints")] - utils::internal_lints::LINT_WITHOUT_LINT_PASS, - #[cfg(feature = "internal-lints")] - utils::internal_lints::MATCH_TYPE_ON_DIAGNOSTIC_ITEM, - #[cfg(feature = "internal-lints")] - utils::internal_lints::OUTER_EXPN_EXPN_DATA, - #[cfg(feature = "internal-lints")] - utils::internal_lints::PRODUCE_ICE, - #[cfg(feature = "internal-lints")] - utils::internal_lints::UNNECESSARY_SYMBOL_STR, - absurd_extreme_comparisons::ABSURD_EXTREME_COMPARISONS, - approx_const::APPROX_CONSTANT, - arithmetic::FLOAT_ARITHMETIC, - arithmetic::INTEGER_ARITHMETIC, - as_conversions::AS_CONVERSIONS, - asm_syntax::INLINE_ASM_X86_ATT_SYNTAX, - asm_syntax::INLINE_ASM_X86_INTEL_SYNTAX, - assertions_on_constants::ASSERTIONS_ON_CONSTANTS, - assign_ops::ASSIGN_OP_PATTERN, - assign_ops::MISREFACTORED_ASSIGN_OP, - async_yields_async::ASYNC_YIELDS_ASYNC, - attrs::BLANKET_CLIPPY_RESTRICTION_LINTS, - attrs::DEPRECATED_CFG_ATTR, - attrs::DEPRECATED_SEMVER, - attrs::EMPTY_LINE_AFTER_OUTER_ATTR, - attrs::INLINE_ALWAYS, - attrs::MISMATCHED_TARGET_OS, - attrs::USELESS_ATTRIBUTE, - await_holding_invalid::AWAIT_HOLDING_LOCK, - await_holding_invalid::AWAIT_HOLDING_REFCELL_REF, - bit_mask::BAD_BIT_MASK, - bit_mask::INEFFECTIVE_BIT_MASK, - bit_mask::VERBOSE_BIT_MASK, - blacklisted_name::BLACKLISTED_NAME, - blocks_in_if_conditions::BLOCKS_IN_IF_CONDITIONS, - bool_assert_comparison::BOOL_ASSERT_COMPARISON, - booleans::LOGIC_BUG, - booleans::NONMINIMAL_BOOL, - bytecount::NAIVE_BYTECOUNT, - cargo_common_metadata::CARGO_COMMON_METADATA, - case_sensitive_file_extension_comparisons::CASE_SENSITIVE_FILE_EXTENSION_COMPARISONS, - casts::CAST_LOSSLESS, - casts::CAST_POSSIBLE_TRUNCATION, - casts::CAST_POSSIBLE_WRAP, - casts::CAST_PRECISION_LOSS, - casts::CAST_PTR_ALIGNMENT, - casts::CAST_REF_TO_MUT, - casts::CAST_SIGN_LOSS, - casts::CHAR_LIT_AS_U8, - casts::FN_TO_NUMERIC_CAST, - casts::FN_TO_NUMERIC_CAST_WITH_TRUNCATION, - casts::PTR_AS_PTR, - casts::UNNECESSARY_CAST, - checked_conversions::CHECKED_CONVERSIONS, - cognitive_complexity::COGNITIVE_COMPLEXITY, - collapsible_if::COLLAPSIBLE_ELSE_IF, - collapsible_if::COLLAPSIBLE_IF, - collapsible_match::COLLAPSIBLE_MATCH, - comparison_chain::COMPARISON_CHAIN, - copies::BRANCHES_SHARING_CODE, - copies::IFS_SAME_COND, - copies::IF_SAME_THEN_ELSE, - copies::SAME_FUNCTIONS_IN_IF_CONDITION, - copy_iterator::COPY_ITERATOR, - create_dir::CREATE_DIR, - dbg_macro::DBG_MACRO, - default::DEFAULT_TRAIT_ACCESS, - default::FIELD_REASSIGN_WITH_DEFAULT, - default_numeric_fallback::DEFAULT_NUMERIC_FALLBACK, - dereference::EXPLICIT_DEREF_METHODS, - derivable_impls::DERIVABLE_IMPLS, - derive::DERIVE_HASH_XOR_EQ, - derive::DERIVE_ORD_XOR_PARTIAL_ORD, - derive::EXPL_IMPL_CLONE_ON_COPY, - derive::UNSAFE_DERIVE_DESERIALIZE, - disallowed_method::DISALLOWED_METHOD, - disallowed_script_idents::DISALLOWED_SCRIPT_IDENTS, - disallowed_type::DISALLOWED_TYPE, - doc::DOC_MARKDOWN, - doc::MISSING_ERRORS_DOC, - doc::MISSING_PANICS_DOC, - doc::MISSING_SAFETY_DOC, - doc::NEEDLESS_DOCTEST_MAIN, - double_comparison::DOUBLE_COMPARISONS, - double_parens::DOUBLE_PARENS, - drop_forget_ref::DROP_COPY, - drop_forget_ref::DROP_REF, - drop_forget_ref::FORGET_COPY, - drop_forget_ref::FORGET_REF, - duration_subsec::DURATION_SUBSEC, - else_if_without_else::ELSE_IF_WITHOUT_ELSE, - empty_enum::EMPTY_ENUM, - entry::MAP_ENTRY, - enum_clike::ENUM_CLIKE_UNPORTABLE_VARIANT, - enum_variants::ENUM_VARIANT_NAMES, - enum_variants::MODULE_INCEPTION, - enum_variants::MODULE_NAME_REPETITIONS, - eq_op::EQ_OP, - eq_op::OP_REF, - erasing_op::ERASING_OP, - escape::BOXED_LOCAL, - eta_reduction::REDUNDANT_CLOSURE, - eta_reduction::REDUNDANT_CLOSURE_FOR_METHOD_CALLS, - eval_order_dependence::DIVERGING_SUB_EXPRESSION, - eval_order_dependence::EVAL_ORDER_DEPENDENCE, - excessive_bools::FN_PARAMS_EXCESSIVE_BOOLS, - excessive_bools::STRUCT_EXCESSIVE_BOOLS, - exhaustive_items::EXHAUSTIVE_ENUMS, - exhaustive_items::EXHAUSTIVE_STRUCTS, - exit::EXIT, - explicit_write::EXPLICIT_WRITE, - fallible_impl_from::FALLIBLE_IMPL_FROM, - feature_name::NEGATIVE_FEATURE_NAMES, - feature_name::REDUNDANT_FEATURE_NAMES, - float_equality_without_abs::FLOAT_EQUALITY_WITHOUT_ABS, - float_literal::EXCESSIVE_PRECISION, - float_literal::LOSSY_FLOAT_LITERAL, - floating_point_arithmetic::IMPRECISE_FLOPS, - floating_point_arithmetic::SUBOPTIMAL_FLOPS, - format::USELESS_FORMAT, - formatting::POSSIBLE_MISSING_COMMA, - formatting::SUSPICIOUS_ASSIGNMENT_FORMATTING, - formatting::SUSPICIOUS_ELSE_FORMATTING, - formatting::SUSPICIOUS_UNARY_OP_FORMATTING, - from_over_into::FROM_OVER_INTO, - from_str_radix_10::FROM_STR_RADIX_10, - functions::DOUBLE_MUST_USE, - functions::MUST_USE_CANDIDATE, - functions::MUST_USE_UNIT, - functions::NOT_UNSAFE_PTR_ARG_DEREF, - functions::RESULT_UNIT_ERR, - functions::TOO_MANY_ARGUMENTS, - functions::TOO_MANY_LINES, - future_not_send::FUTURE_NOT_SEND, - get_last_with_len::GET_LAST_WITH_LEN, - identity_op::IDENTITY_OP, - if_let_mutex::IF_LET_MUTEX, - if_not_else::IF_NOT_ELSE, - if_then_panic::IF_THEN_PANIC, - if_then_some_else_none::IF_THEN_SOME_ELSE_NONE, - implicit_hasher::IMPLICIT_HASHER, - implicit_return::IMPLICIT_RETURN, - implicit_saturating_sub::IMPLICIT_SATURATING_SUB, - inconsistent_struct_constructor::INCONSISTENT_STRUCT_CONSTRUCTOR, - indexing_slicing::INDEXING_SLICING, - indexing_slicing::OUT_OF_BOUNDS_INDEXING, - infinite_iter::INFINITE_ITER, - infinite_iter::MAYBE_INFINITE_ITER, - inherent_impl::MULTIPLE_INHERENT_IMPL, - inherent_to_string::INHERENT_TO_STRING, - inherent_to_string::INHERENT_TO_STRING_SHADOW_DISPLAY, - inline_fn_without_body::INLINE_FN_WITHOUT_BODY, - int_plus_one::INT_PLUS_ONE, - integer_division::INTEGER_DIVISION, - invalid_upcast_comparisons::INVALID_UPCAST_COMPARISONS, - items_after_statements::ITEMS_AFTER_STATEMENTS, - iter_not_returning_iterator::ITER_NOT_RETURNING_ITERATOR, - large_const_arrays::LARGE_CONST_ARRAYS, - large_enum_variant::LARGE_ENUM_VARIANT, - large_stack_arrays::LARGE_STACK_ARRAYS, - len_zero::COMPARISON_TO_EMPTY, - len_zero::LEN_WITHOUT_IS_EMPTY, - len_zero::LEN_ZERO, - let_if_seq::USELESS_LET_IF_SEQ, - let_underscore::LET_UNDERSCORE_DROP, - let_underscore::LET_UNDERSCORE_LOCK, - let_underscore::LET_UNDERSCORE_MUST_USE, - lifetimes::EXTRA_UNUSED_LIFETIMES, - lifetimes::NEEDLESS_LIFETIMES, - literal_representation::DECIMAL_LITERAL_REPRESENTATION, - literal_representation::INCONSISTENT_DIGIT_GROUPING, - literal_representation::LARGE_DIGIT_GROUPS, - literal_representation::MISTYPED_LITERAL_SUFFIXES, - literal_representation::UNREADABLE_LITERAL, - literal_representation::UNUSUAL_BYTE_GROUPINGS, - loops::EMPTY_LOOP, - loops::EXPLICIT_COUNTER_LOOP, - loops::EXPLICIT_INTO_ITER_LOOP, - loops::EXPLICIT_ITER_LOOP, - loops::FOR_KV_MAP, - loops::FOR_LOOPS_OVER_FALLIBLES, - loops::ITER_NEXT_LOOP, - loops::MANUAL_FLATTEN, - loops::MANUAL_MEMCPY, - loops::MUT_RANGE_BOUND, - loops::NEEDLESS_COLLECT, - loops::NEEDLESS_RANGE_LOOP, - loops::NEVER_LOOP, - loops::SAME_ITEM_PUSH, - loops::SINGLE_ELEMENT_LOOP, - loops::WHILE_IMMUTABLE_CONDITION, - loops::WHILE_LET_LOOP, - loops::WHILE_LET_ON_ITERATOR, - macro_use::MACRO_USE_IMPORTS, - main_recursion::MAIN_RECURSION, - manual_async_fn::MANUAL_ASYNC_FN, - manual_map::MANUAL_MAP, - manual_non_exhaustive::MANUAL_NON_EXHAUSTIVE, - manual_ok_or::MANUAL_OK_OR, - manual_strip::MANUAL_STRIP, - manual_unwrap_or::MANUAL_UNWRAP_OR, - map_clone::MAP_CLONE, - map_err_ignore::MAP_ERR_IGNORE, - map_unit_fn::OPTION_MAP_UNIT_FN, - map_unit_fn::RESULT_MAP_UNIT_FN, - match_on_vec_items::MATCH_ON_VEC_ITEMS, - match_result_ok::MATCH_RESULT_OK, - matches::INFALLIBLE_DESTRUCTURING_MATCH, - matches::MATCH_AS_REF, - matches::MATCH_BOOL, - matches::MATCH_LIKE_MATCHES_MACRO, - matches::MATCH_OVERLAPPING_ARM, - matches::MATCH_REF_PATS, - matches::MATCH_SAME_ARMS, - matches::MATCH_SINGLE_BINDING, - matches::MATCH_WILDCARD_FOR_SINGLE_VARIANTS, - matches::MATCH_WILD_ERR_ARM, - matches::REDUNDANT_PATTERN_MATCHING, - matches::REST_PAT_IN_FULLY_BOUND_STRUCTS, - matches::SINGLE_MATCH, - matches::SINGLE_MATCH_ELSE, - matches::WILDCARD_ENUM_MATCH_ARM, - matches::WILDCARD_IN_OR_PATTERNS, - mem_discriminant::MEM_DISCRIMINANT_NON_ENUM, - mem_forget::MEM_FORGET, - mem_replace::MEM_REPLACE_OPTION_WITH_NONE, - mem_replace::MEM_REPLACE_WITH_DEFAULT, - mem_replace::MEM_REPLACE_WITH_UNINIT, - methods::BIND_INSTEAD_OF_MAP, - methods::BYTES_NTH, - methods::CHARS_LAST_CMP, - methods::CHARS_NEXT_CMP, - methods::CLONED_INSTEAD_OF_COPIED, - methods::CLONE_DOUBLE_REF, - methods::CLONE_ON_COPY, - methods::CLONE_ON_REF_PTR, - methods::EXPECT_FUN_CALL, - methods::EXPECT_USED, - methods::EXTEND_WITH_DRAIN, - methods::FILETYPE_IS_FILE, - methods::FILTER_MAP_IDENTITY, - methods::FILTER_MAP_NEXT, - methods::FILTER_NEXT, - methods::FLAT_MAP_IDENTITY, - methods::FLAT_MAP_OPTION, - methods::FROM_ITER_INSTEAD_OF_COLLECT, - methods::GET_UNWRAP, - methods::IMPLICIT_CLONE, - methods::INEFFICIENT_TO_STRING, - methods::INSPECT_FOR_EACH, - methods::INTO_ITER_ON_REF, - methods::ITERATOR_STEP_BY_ZERO, - methods::ITER_CLONED_COLLECT, - methods::ITER_COUNT, - methods::ITER_NEXT_SLICE, - methods::ITER_NTH, - methods::ITER_NTH_ZERO, - methods::ITER_SKIP_NEXT, - methods::MANUAL_FILTER_MAP, - methods::MANUAL_FIND_MAP, - methods::MANUAL_SATURATING_ARITHMETIC, - methods::MANUAL_SPLIT_ONCE, - methods::MANUAL_STR_REPEAT, - methods::MAP_COLLECT_RESULT_UNIT, - methods::MAP_FLATTEN, - methods::MAP_IDENTITY, - methods::MAP_UNWRAP_OR, - methods::NEW_RET_NO_SELF, - methods::OK_EXPECT, - methods::OPTION_AS_REF_DEREF, - methods::OPTION_FILTER_MAP, - methods::OPTION_MAP_OR_NONE, - methods::OR_FUN_CALL, - methods::RESULT_MAP_OR_INTO_OPTION, - methods::SEARCH_IS_SOME, - methods::SHOULD_IMPLEMENT_TRAIT, - methods::SINGLE_CHAR_ADD_STR, - methods::SINGLE_CHAR_PATTERN, - methods::SKIP_WHILE_NEXT, - methods::STRING_EXTEND_CHARS, - methods::SUSPICIOUS_MAP, - methods::SUSPICIOUS_SPLITN, - methods::UNINIT_ASSUMED_INIT, - methods::UNNECESSARY_FILTER_MAP, - methods::UNNECESSARY_FOLD, - methods::UNNECESSARY_LAZY_EVALUATIONS, - methods::UNWRAP_OR_ELSE_DEFAULT, - methods::UNWRAP_USED, - methods::USELESS_ASREF, - methods::WRONG_SELF_CONVENTION, - methods::ZST_OFFSET, - minmax::MIN_MAX, - misc::CMP_NAN, - misc::CMP_OWNED, - misc::FLOAT_CMP, - misc::FLOAT_CMP_CONST, - misc::MODULO_ONE, - misc::SHORT_CIRCUIT_STATEMENT, - misc::TOPLEVEL_REF_ARG, - misc::USED_UNDERSCORE_BINDING, - misc::ZERO_PTR, - misc_early::BUILTIN_TYPE_SHADOW, - misc_early::DOUBLE_NEG, - misc_early::DUPLICATE_UNDERSCORE_ARGUMENT, - misc_early::MIXED_CASE_HEX_LITERALS, - misc_early::REDUNDANT_PATTERN, - misc_early::UNNEEDED_FIELD_PATTERN, - misc_early::UNNEEDED_WILDCARD_PATTERN, - misc_early::UNSEPARATED_LITERAL_SUFFIX, - misc_early::ZERO_PREFIXED_LITERAL, - missing_const_for_fn::MISSING_CONST_FOR_FN, - missing_doc::MISSING_DOCS_IN_PRIVATE_ITEMS, - missing_enforced_import_rename::MISSING_ENFORCED_IMPORT_RENAMES, - missing_inline::MISSING_INLINE_IN_PUBLIC_ITEMS, - module_style::MOD_MODULE_FILES, - module_style::SELF_NAMED_MODULE_FILES, - modulo_arithmetic::MODULO_ARITHMETIC, - multiple_crate_versions::MULTIPLE_CRATE_VERSIONS, - mut_key::MUTABLE_KEY_TYPE, - mut_mut::MUT_MUT, - mut_mutex_lock::MUT_MUTEX_LOCK, - mut_reference::UNNECESSARY_MUT_PASSED, - mutable_debug_assertion::DEBUG_ASSERT_WITH_MUT_CALL, - mutex_atomic::MUTEX_ATOMIC, - mutex_atomic::MUTEX_INTEGER, - needless_arbitrary_self_type::NEEDLESS_ARBITRARY_SELF_TYPE, - needless_bitwise_bool::NEEDLESS_BITWISE_BOOL, - needless_bool::BOOL_COMPARISON, - needless_bool::NEEDLESS_BOOL, - needless_borrow::NEEDLESS_BORROW, - needless_borrow::REF_BINDING_TO_REFERENCE, - needless_borrowed_ref::NEEDLESS_BORROWED_REFERENCE, - needless_continue::NEEDLESS_CONTINUE, - needless_for_each::NEEDLESS_FOR_EACH, - needless_option_as_deref::NEEDLESS_OPTION_AS_DEREF, - needless_pass_by_value::NEEDLESS_PASS_BY_VALUE, - needless_question_mark::NEEDLESS_QUESTION_MARK, - needless_update::NEEDLESS_UPDATE, - neg_cmp_op_on_partial_ord::NEG_CMP_OP_ON_PARTIAL_ORD, - neg_multiply::NEG_MULTIPLY, - new_without_default::NEW_WITHOUT_DEFAULT, - no_effect::NO_EFFECT, - no_effect::UNNECESSARY_OPERATION, - non_copy_const::BORROW_INTERIOR_MUTABLE_CONST, - non_copy_const::DECLARE_INTERIOR_MUTABLE_CONST, - non_expressive_names::JUST_UNDERSCORES_AND_DIGITS, - non_expressive_names::MANY_SINGLE_CHAR_NAMES, - non_expressive_names::SIMILAR_NAMES, - non_octal_unix_permissions::NON_OCTAL_UNIX_PERMISSIONS, - nonstandard_macro_braces::NONSTANDARD_MACRO_BRACES, - open_options::NONSENSICAL_OPEN_OPTIONS, - option_env_unwrap::OPTION_ENV_UNWRAP, - option_if_let_else::OPTION_IF_LET_ELSE, - overflow_check_conditional::OVERFLOW_CHECK_CONDITIONAL, - panic_in_result_fn::PANIC_IN_RESULT_FN, - panic_unimplemented::PANIC, - panic_unimplemented::TODO, - panic_unimplemented::UNIMPLEMENTED, - panic_unimplemented::UNREACHABLE, - partialeq_ne_impl::PARTIALEQ_NE_IMPL, - pass_by_ref_or_value::LARGE_TYPES_PASSED_BY_VALUE, - pass_by_ref_or_value::TRIVIALLY_COPY_PASS_BY_REF, - path_buf_push_overwrite::PATH_BUF_PUSH_OVERWRITE, - pattern_type_mismatch::PATTERN_TYPE_MISMATCH, - precedence::PRECEDENCE, - ptr::CMP_NULL, - ptr::INVALID_NULL_PTR_USAGE, - ptr::MUT_FROM_REF, - ptr::PTR_ARG, - ptr_eq::PTR_EQ, - ptr_offset_with_cast::PTR_OFFSET_WITH_CAST, - question_mark::QUESTION_MARK, - ranges::MANUAL_RANGE_CONTAINS, - ranges::RANGE_MINUS_ONE, - ranges::RANGE_PLUS_ONE, - ranges::RANGE_ZIP_WITH_LEN, - ranges::REVERSED_EMPTY_RANGES, - redundant_clone::REDUNDANT_CLONE, - redundant_closure_call::REDUNDANT_CLOSURE_CALL, - redundant_else::REDUNDANT_ELSE, - redundant_field_names::REDUNDANT_FIELD_NAMES, - redundant_pub_crate::REDUNDANT_PUB_CRATE, - redundant_slicing::REDUNDANT_SLICING, - redundant_static_lifetimes::REDUNDANT_STATIC_LIFETIMES, - ref_option_ref::REF_OPTION_REF, - reference::DEREF_ADDROF, - reference::REF_IN_DEREF, - regex::INVALID_REGEX, - regex::TRIVIAL_REGEX, - repeat_once::REPEAT_ONCE, - returns::LET_AND_RETURN, - returns::NEEDLESS_RETURN, - same_name_method::SAME_NAME_METHOD, - self_assignment::SELF_ASSIGNMENT, - self_named_constructors::SELF_NAMED_CONSTRUCTORS, - semicolon_if_nothing_returned::SEMICOLON_IF_NOTHING_RETURNED, - serde_api::SERDE_API_MISUSE, - shadow::SHADOW_REUSE, - shadow::SHADOW_SAME, - shadow::SHADOW_UNRELATED, - single_component_path_imports::SINGLE_COMPONENT_PATH_IMPORTS, - size_of_in_element_count::SIZE_OF_IN_ELEMENT_COUNT, - slow_vector_initialization::SLOW_VECTOR_INITIALIZATION, - stable_sort_primitive::STABLE_SORT_PRIMITIVE, - strings::STRING_ADD, - strings::STRING_ADD_ASSIGN, - strings::STRING_FROM_UTF8_AS_BYTES, - strings::STRING_LIT_AS_BYTES, - strings::STRING_TO_STRING, - strings::STR_TO_STRING, - strlen_on_c_strings::STRLEN_ON_C_STRINGS, - suspicious_operation_groupings::SUSPICIOUS_OPERATION_GROUPINGS, - suspicious_trait_impl::SUSPICIOUS_ARITHMETIC_IMPL, - suspicious_trait_impl::SUSPICIOUS_OP_ASSIGN_IMPL, - swap::ALMOST_SWAPPED, - swap::MANUAL_SWAP, - tabs_in_doc_comments::TABS_IN_DOC_COMMENTS, - temporary_assignment::TEMPORARY_ASSIGNMENT, - to_digit_is_some::TO_DIGIT_IS_SOME, - to_string_in_display::TO_STRING_IN_DISPLAY, - trait_bounds::TRAIT_DUPLICATION_IN_BOUNDS, - trait_bounds::TYPE_REPETITION_IN_BOUNDS, - transmute::CROSSPOINTER_TRANSMUTE, - transmute::TRANSMUTES_EXPRESSIBLE_AS_PTR_CASTS, - transmute::TRANSMUTE_BYTES_TO_STR, - transmute::TRANSMUTE_FLOAT_TO_INT, - transmute::TRANSMUTE_INT_TO_BOOL, - transmute::TRANSMUTE_INT_TO_CHAR, - transmute::TRANSMUTE_INT_TO_FLOAT, - transmute::TRANSMUTE_PTR_TO_PTR, - transmute::TRANSMUTE_PTR_TO_REF, - transmute::UNSOUND_COLLECTION_TRANSMUTE, - transmute::USELESS_TRANSMUTE, - transmute::WRONG_TRANSMUTE, - transmuting_null::TRANSMUTING_NULL, - try_err::TRY_ERR, - types::BORROWED_BOX, - types::BOX_COLLECTION, - types::LINKEDLIST, - types::OPTION_OPTION, - types::RC_BUFFER, - types::RC_MUTEX, - types::REDUNDANT_ALLOCATION, - types::TYPE_COMPLEXITY, - types::VEC_BOX, - undropped_manually_drops::UNDROPPED_MANUALLY_DROPS, - unicode::INVISIBLE_CHARACTERS, - unicode::NON_ASCII_LITERAL, - unicode::UNICODE_NOT_NFC, - unit_return_expecting_ord::UNIT_RETURN_EXPECTING_ORD, - unit_types::LET_UNIT_VALUE, - unit_types::UNIT_ARG, - unit_types::UNIT_CMP, - unnamed_address::FN_ADDRESS_COMPARISONS, - unnamed_address::VTABLE_ADDRESS_COMPARISONS, - unnecessary_self_imports::UNNECESSARY_SELF_IMPORTS, - unnecessary_sort_by::UNNECESSARY_SORT_BY, - unnecessary_wraps::UNNECESSARY_WRAPS, - unnested_or_patterns::UNNESTED_OR_PATTERNS, - unsafe_removed_from_name::UNSAFE_REMOVED_FROM_NAME, - unused_async::UNUSED_ASYNC, - unused_io_amount::UNUSED_IO_AMOUNT, - unused_self::UNUSED_SELF, - unused_unit::UNUSED_UNIT, - unwrap::PANICKING_UNWRAP, - unwrap::UNNECESSARY_UNWRAP, - unwrap_in_result::UNWRAP_IN_RESULT, - upper_case_acronyms::UPPER_CASE_ACRONYMS, - use_self::USE_SELF, - useless_conversion::USELESS_CONVERSION, - vec::USELESS_VEC, - vec_init_then_push::VEC_INIT_THEN_PUSH, - vec_resize_to_zero::VEC_RESIZE_TO_ZERO, - verbose_file_reads::VERBOSE_FILE_READS, - wildcard_dependencies::WILDCARD_DEPENDENCIES, - wildcard_imports::ENUM_GLOB_USE, - wildcard_imports::WILDCARD_IMPORTS, - write::PRINTLN_EMPTY_STRING, - write::PRINT_LITERAL, - write::PRINT_STDERR, - write::PRINT_STDOUT, - write::PRINT_WITH_NEWLINE, - write::USE_DEBUG, - write::WRITELN_EMPTY_STRING, - write::WRITE_LITERAL, - write::WRITE_WITH_NEWLINE, - zero_div_zero::ZERO_DIVIDED_BY_ZERO, - zero_sized_map_values::ZERO_SIZED_MAP_VALUES, - ]) \ No newline at end of file +store.register_lints(&[ + #[cfg(feature = "internal-lints")] + utils::internal_lints::CLIPPY_LINTS_INTERNAL, + #[cfg(feature = "internal-lints")] + utils::internal_lints::COLLAPSIBLE_SPAN_LINT_CALLS, + #[cfg(feature = "internal-lints")] + utils::internal_lints::COMPILER_LINT_FUNCTIONS, + #[cfg(feature = "internal-lints")] + utils::internal_lints::DEFAULT_LINT, + #[cfg(feature = "internal-lints")] + utils::internal_lints::IF_CHAIN_STYLE, + #[cfg(feature = "internal-lints")] + utils::internal_lints::INTERNING_DEFINED_SYMBOL, + #[cfg(feature = "internal-lints")] + utils::internal_lints::INVALID_PATHS, + #[cfg(feature = "internal-lints")] + utils::internal_lints::LINT_WITHOUT_LINT_PASS, + #[cfg(feature = "internal-lints")] + utils::internal_lints::MATCH_TYPE_ON_DIAGNOSTIC_ITEM, + #[cfg(feature = "internal-lints")] + utils::internal_lints::OUTER_EXPN_EXPN_DATA, + #[cfg(feature = "internal-lints")] + utils::internal_lints::PRODUCE_ICE, + #[cfg(feature = "internal-lints")] + utils::internal_lints::UNNECESSARY_SYMBOL_STR, + absurd_extreme_comparisons::ABSURD_EXTREME_COMPARISONS, + approx_const::APPROX_CONSTANT, + arithmetic::FLOAT_ARITHMETIC, + arithmetic::INTEGER_ARITHMETIC, + as_conversions::AS_CONVERSIONS, + asm_syntax::INLINE_ASM_X86_ATT_SYNTAX, + asm_syntax::INLINE_ASM_X86_INTEL_SYNTAX, + assertions_on_constants::ASSERTIONS_ON_CONSTANTS, + assign_ops::ASSIGN_OP_PATTERN, + assign_ops::MISREFACTORED_ASSIGN_OP, + async_yields_async::ASYNC_YIELDS_ASYNC, + attrs::BLANKET_CLIPPY_RESTRICTION_LINTS, + attrs::DEPRECATED_CFG_ATTR, + attrs::DEPRECATED_SEMVER, + attrs::EMPTY_LINE_AFTER_OUTER_ATTR, + attrs::INLINE_ALWAYS, + attrs::MISMATCHED_TARGET_OS, + attrs::USELESS_ATTRIBUTE, + await_holding_invalid::AWAIT_HOLDING_LOCK, + await_holding_invalid::AWAIT_HOLDING_REFCELL_REF, + bit_mask::BAD_BIT_MASK, + bit_mask::INEFFECTIVE_BIT_MASK, + bit_mask::VERBOSE_BIT_MASK, + blacklisted_name::BLACKLISTED_NAME, + blocks_in_if_conditions::BLOCKS_IN_IF_CONDITIONS, + bool_assert_comparison::BOOL_ASSERT_COMPARISON, + booleans::LOGIC_BUG, + booleans::NONMINIMAL_BOOL, + bytecount::NAIVE_BYTECOUNT, + cargo_common_metadata::CARGO_COMMON_METADATA, + case_sensitive_file_extension_comparisons::CASE_SENSITIVE_FILE_EXTENSION_COMPARISONS, + casts::CAST_LOSSLESS, + casts::CAST_POSSIBLE_TRUNCATION, + casts::CAST_POSSIBLE_WRAP, + casts::CAST_PRECISION_LOSS, + casts::CAST_PTR_ALIGNMENT, + casts::CAST_REF_TO_MUT, + casts::CAST_SIGN_LOSS, + casts::CHAR_LIT_AS_U8, + casts::FN_TO_NUMERIC_CAST, + casts::FN_TO_NUMERIC_CAST_WITH_TRUNCATION, + casts::PTR_AS_PTR, + casts::UNNECESSARY_CAST, + checked_conversions::CHECKED_CONVERSIONS, + cognitive_complexity::COGNITIVE_COMPLEXITY, + collapsible_if::COLLAPSIBLE_ELSE_IF, + collapsible_if::COLLAPSIBLE_IF, + collapsible_match::COLLAPSIBLE_MATCH, + comparison_chain::COMPARISON_CHAIN, + copies::BRANCHES_SHARING_CODE, + copies::IFS_SAME_COND, + copies::IF_SAME_THEN_ELSE, + copies::SAME_FUNCTIONS_IN_IF_CONDITION, + copy_iterator::COPY_ITERATOR, + create_dir::CREATE_DIR, + dbg_macro::DBG_MACRO, + default::DEFAULT_TRAIT_ACCESS, + default::FIELD_REASSIGN_WITH_DEFAULT, + default_numeric_fallback::DEFAULT_NUMERIC_FALLBACK, + dereference::EXPLICIT_DEREF_METHODS, + derivable_impls::DERIVABLE_IMPLS, + derive::DERIVE_HASH_XOR_EQ, + derive::DERIVE_ORD_XOR_PARTIAL_ORD, + derive::EXPL_IMPL_CLONE_ON_COPY, + derive::UNSAFE_DERIVE_DESERIALIZE, + disallowed_method::DISALLOWED_METHOD, + disallowed_script_idents::DISALLOWED_SCRIPT_IDENTS, + disallowed_type::DISALLOWED_TYPE, + doc::DOC_MARKDOWN, + doc::MISSING_ERRORS_DOC, + doc::MISSING_PANICS_DOC, + doc::MISSING_SAFETY_DOC, + doc::NEEDLESS_DOCTEST_MAIN, + double_comparison::DOUBLE_COMPARISONS, + double_parens::DOUBLE_PARENS, + drop_forget_ref::DROP_COPY, + drop_forget_ref::DROP_REF, + drop_forget_ref::FORGET_COPY, + drop_forget_ref::FORGET_REF, + duration_subsec::DURATION_SUBSEC, + else_if_without_else::ELSE_IF_WITHOUT_ELSE, + empty_enum::EMPTY_ENUM, + entry::MAP_ENTRY, + enum_clike::ENUM_CLIKE_UNPORTABLE_VARIANT, + enum_variants::ENUM_VARIANT_NAMES, + enum_variants::MODULE_INCEPTION, + enum_variants::MODULE_NAME_REPETITIONS, + eq_op::EQ_OP, + eq_op::OP_REF, + erasing_op::ERASING_OP, + escape::BOXED_LOCAL, + eta_reduction::REDUNDANT_CLOSURE, + eta_reduction::REDUNDANT_CLOSURE_FOR_METHOD_CALLS, + eval_order_dependence::DIVERGING_SUB_EXPRESSION, + eval_order_dependence::EVAL_ORDER_DEPENDENCE, + excessive_bools::FN_PARAMS_EXCESSIVE_BOOLS, + excessive_bools::STRUCT_EXCESSIVE_BOOLS, + exhaustive_items::EXHAUSTIVE_ENUMS, + exhaustive_items::EXHAUSTIVE_STRUCTS, + exit::EXIT, + explicit_write::EXPLICIT_WRITE, + fallible_impl_from::FALLIBLE_IMPL_FROM, + feature_name::NEGATIVE_FEATURE_NAMES, + feature_name::REDUNDANT_FEATURE_NAMES, + float_equality_without_abs::FLOAT_EQUALITY_WITHOUT_ABS, + float_literal::EXCESSIVE_PRECISION, + float_literal::LOSSY_FLOAT_LITERAL, + floating_point_arithmetic::IMPRECISE_FLOPS, + floating_point_arithmetic::SUBOPTIMAL_FLOPS, + format::USELESS_FORMAT, + formatting::POSSIBLE_MISSING_COMMA, + formatting::SUSPICIOUS_ASSIGNMENT_FORMATTING, + formatting::SUSPICIOUS_ELSE_FORMATTING, + formatting::SUSPICIOUS_UNARY_OP_FORMATTING, + from_over_into::FROM_OVER_INTO, + from_str_radix_10::FROM_STR_RADIX_10, + functions::DOUBLE_MUST_USE, + functions::MUST_USE_CANDIDATE, + functions::MUST_USE_UNIT, + functions::NOT_UNSAFE_PTR_ARG_DEREF, + functions::RESULT_UNIT_ERR, + functions::TOO_MANY_ARGUMENTS, + functions::TOO_MANY_LINES, + future_not_send::FUTURE_NOT_SEND, + get_last_with_len::GET_LAST_WITH_LEN, + identity_op::IDENTITY_OP, + if_let_mutex::IF_LET_MUTEX, + if_not_else::IF_NOT_ELSE, + if_then_panic::IF_THEN_PANIC, + if_then_some_else_none::IF_THEN_SOME_ELSE_NONE, + implicit_hasher::IMPLICIT_HASHER, + implicit_return::IMPLICIT_RETURN, + implicit_saturating_sub::IMPLICIT_SATURATING_SUB, + inconsistent_struct_constructor::INCONSISTENT_STRUCT_CONSTRUCTOR, + indexing_slicing::INDEXING_SLICING, + indexing_slicing::OUT_OF_BOUNDS_INDEXING, + infinite_iter::INFINITE_ITER, + infinite_iter::MAYBE_INFINITE_ITER, + inherent_impl::MULTIPLE_INHERENT_IMPL, + inherent_to_string::INHERENT_TO_STRING, + inherent_to_string::INHERENT_TO_STRING_SHADOW_DISPLAY, + inline_fn_without_body::INLINE_FN_WITHOUT_BODY, + int_plus_one::INT_PLUS_ONE, + integer_division::INTEGER_DIVISION, + invalid_upcast_comparisons::INVALID_UPCAST_COMPARISONS, + items_after_statements::ITEMS_AFTER_STATEMENTS, + iter_not_returning_iterator::ITER_NOT_RETURNING_ITERATOR, + large_const_arrays::LARGE_CONST_ARRAYS, + large_enum_variant::LARGE_ENUM_VARIANT, + large_stack_arrays::LARGE_STACK_ARRAYS, + len_zero::COMPARISON_TO_EMPTY, + len_zero::LEN_WITHOUT_IS_EMPTY, + len_zero::LEN_ZERO, + let_if_seq::USELESS_LET_IF_SEQ, + let_underscore::LET_UNDERSCORE_DROP, + let_underscore::LET_UNDERSCORE_LOCK, + let_underscore::LET_UNDERSCORE_MUST_USE, + lifetimes::EXTRA_UNUSED_LIFETIMES, + lifetimes::NEEDLESS_LIFETIMES, + literal_representation::DECIMAL_LITERAL_REPRESENTATION, + literal_representation::INCONSISTENT_DIGIT_GROUPING, + literal_representation::LARGE_DIGIT_GROUPS, + literal_representation::MISTYPED_LITERAL_SUFFIXES, + literal_representation::UNREADABLE_LITERAL, + literal_representation::UNUSUAL_BYTE_GROUPINGS, + loops::EMPTY_LOOP, + loops::EXPLICIT_COUNTER_LOOP, + loops::EXPLICIT_INTO_ITER_LOOP, + loops::EXPLICIT_ITER_LOOP, + loops::FOR_KV_MAP, + loops::FOR_LOOPS_OVER_FALLIBLES, + loops::ITER_NEXT_LOOP, + loops::MANUAL_FLATTEN, + loops::MANUAL_MEMCPY, + loops::MUT_RANGE_BOUND, + loops::NEEDLESS_COLLECT, + loops::NEEDLESS_RANGE_LOOP, + loops::NEVER_LOOP, + loops::SAME_ITEM_PUSH, + loops::SINGLE_ELEMENT_LOOP, + loops::WHILE_IMMUTABLE_CONDITION, + loops::WHILE_LET_LOOP, + loops::WHILE_LET_ON_ITERATOR, + macro_use::MACRO_USE_IMPORTS, + main_recursion::MAIN_RECURSION, + manual_async_fn::MANUAL_ASYNC_FN, + manual_map::MANUAL_MAP, + manual_non_exhaustive::MANUAL_NON_EXHAUSTIVE, + manual_ok_or::MANUAL_OK_OR, + manual_strip::MANUAL_STRIP, + manual_unwrap_or::MANUAL_UNWRAP_OR, + map_clone::MAP_CLONE, + map_err_ignore::MAP_ERR_IGNORE, + map_unit_fn::OPTION_MAP_UNIT_FN, + map_unit_fn::RESULT_MAP_UNIT_FN, + match_on_vec_items::MATCH_ON_VEC_ITEMS, + match_result_ok::MATCH_RESULT_OK, + matches::INFALLIBLE_DESTRUCTURING_MATCH, + matches::MATCH_AS_REF, + matches::MATCH_BOOL, + matches::MATCH_LIKE_MATCHES_MACRO, + matches::MATCH_OVERLAPPING_ARM, + matches::MATCH_REF_PATS, + matches::MATCH_SAME_ARMS, + matches::MATCH_SINGLE_BINDING, + matches::MATCH_WILDCARD_FOR_SINGLE_VARIANTS, + matches::MATCH_WILD_ERR_ARM, + matches::REDUNDANT_PATTERN_MATCHING, + matches::REST_PAT_IN_FULLY_BOUND_STRUCTS, + matches::SINGLE_MATCH, + matches::SINGLE_MATCH_ELSE, + matches::WILDCARD_ENUM_MATCH_ARM, + matches::WILDCARD_IN_OR_PATTERNS, + mem_discriminant::MEM_DISCRIMINANT_NON_ENUM, + mem_forget::MEM_FORGET, + mem_replace::MEM_REPLACE_OPTION_WITH_NONE, + mem_replace::MEM_REPLACE_WITH_DEFAULT, + mem_replace::MEM_REPLACE_WITH_UNINIT, + methods::BIND_INSTEAD_OF_MAP, + methods::BYTES_NTH, + methods::CHARS_LAST_CMP, + methods::CHARS_NEXT_CMP, + methods::CLONED_INSTEAD_OF_COPIED, + methods::CLONE_DOUBLE_REF, + methods::CLONE_ON_COPY, + methods::CLONE_ON_REF_PTR, + methods::EXPECT_FUN_CALL, + methods::EXPECT_USED, + methods::EXTEND_WITH_DRAIN, + methods::FILETYPE_IS_FILE, + methods::FILTER_MAP_IDENTITY, + methods::FILTER_MAP_NEXT, + methods::FILTER_NEXT, + methods::FLAT_MAP_IDENTITY, + methods::FLAT_MAP_OPTION, + methods::FROM_ITER_INSTEAD_OF_COLLECT, + methods::GET_UNWRAP, + methods::IMPLICIT_CLONE, + methods::INEFFICIENT_TO_STRING, + methods::INSPECT_FOR_EACH, + methods::INTO_ITER_ON_REF, + methods::ITERATOR_STEP_BY_ZERO, + methods::ITER_CLONED_COLLECT, + methods::ITER_COUNT, + methods::ITER_NEXT_SLICE, + methods::ITER_NTH, + methods::ITER_NTH_ZERO, + methods::ITER_SKIP_NEXT, + methods::MANUAL_FILTER_MAP, + methods::MANUAL_FIND_MAP, + methods::MANUAL_SATURATING_ARITHMETIC, + methods::MANUAL_SPLIT_ONCE, + methods::MANUAL_STR_REPEAT, + methods::MAP_COLLECT_RESULT_UNIT, + methods::MAP_FLATTEN, + methods::MAP_IDENTITY, + methods::MAP_UNWRAP_OR, + methods::NEW_RET_NO_SELF, + methods::OK_EXPECT, + methods::OPTION_AS_REF_DEREF, + methods::OPTION_FILTER_MAP, + methods::OPTION_MAP_OR_NONE, + methods::OR_FUN_CALL, + methods::RESULT_MAP_OR_INTO_OPTION, + methods::SEARCH_IS_SOME, + methods::SHOULD_IMPLEMENT_TRAIT, + methods::SINGLE_CHAR_ADD_STR, + methods::SINGLE_CHAR_PATTERN, + methods::SKIP_WHILE_NEXT, + methods::STRING_EXTEND_CHARS, + methods::SUSPICIOUS_MAP, + methods::SUSPICIOUS_SPLITN, + methods::UNINIT_ASSUMED_INIT, + methods::UNNECESSARY_FILTER_MAP, + methods::UNNECESSARY_FOLD, + methods::UNNECESSARY_LAZY_EVALUATIONS, + methods::UNWRAP_OR_ELSE_DEFAULT, + methods::UNWRAP_USED, + methods::USELESS_ASREF, + methods::WRONG_SELF_CONVENTION, + methods::ZST_OFFSET, + minmax::MIN_MAX, + misc::CMP_NAN, + misc::CMP_OWNED, + misc::FLOAT_CMP, + misc::FLOAT_CMP_CONST, + misc::MODULO_ONE, + misc::SHORT_CIRCUIT_STATEMENT, + misc::TOPLEVEL_REF_ARG, + misc::USED_UNDERSCORE_BINDING, + misc::ZERO_PTR, + misc_early::BUILTIN_TYPE_SHADOW, + misc_early::DOUBLE_NEG, + misc_early::DUPLICATE_UNDERSCORE_ARGUMENT, + misc_early::MIXED_CASE_HEX_LITERALS, + misc_early::REDUNDANT_PATTERN, + misc_early::UNNEEDED_FIELD_PATTERN, + misc_early::UNNEEDED_WILDCARD_PATTERN, + misc_early::UNSEPARATED_LITERAL_SUFFIX, + misc_early::ZERO_PREFIXED_LITERAL, + missing_const_for_fn::MISSING_CONST_FOR_FN, + missing_doc::MISSING_DOCS_IN_PRIVATE_ITEMS, + missing_enforced_import_rename::MISSING_ENFORCED_IMPORT_RENAMES, + missing_inline::MISSING_INLINE_IN_PUBLIC_ITEMS, + module_style::MOD_MODULE_FILES, + module_style::SELF_NAMED_MODULE_FILES, + modulo_arithmetic::MODULO_ARITHMETIC, + multiple_crate_versions::MULTIPLE_CRATE_VERSIONS, + mut_key::MUTABLE_KEY_TYPE, + mut_mut::MUT_MUT, + mut_mutex_lock::MUT_MUTEX_LOCK, + mut_reference::UNNECESSARY_MUT_PASSED, + mutable_debug_assertion::DEBUG_ASSERT_WITH_MUT_CALL, + mutex_atomic::MUTEX_ATOMIC, + mutex_atomic::MUTEX_INTEGER, + needless_arbitrary_self_type::NEEDLESS_ARBITRARY_SELF_TYPE, + needless_bitwise_bool::NEEDLESS_BITWISE_BOOL, + needless_bool::BOOL_COMPARISON, + needless_bool::NEEDLESS_BOOL, + needless_borrow::NEEDLESS_BORROW, + needless_borrow::REF_BINDING_TO_REFERENCE, + needless_borrowed_ref::NEEDLESS_BORROWED_REFERENCE, + needless_continue::NEEDLESS_CONTINUE, + needless_for_each::NEEDLESS_FOR_EACH, + needless_option_as_deref::NEEDLESS_OPTION_AS_DEREF, + needless_pass_by_value::NEEDLESS_PASS_BY_VALUE, + needless_question_mark::NEEDLESS_QUESTION_MARK, + needless_update::NEEDLESS_UPDATE, + neg_cmp_op_on_partial_ord::NEG_CMP_OP_ON_PARTIAL_ORD, + neg_multiply::NEG_MULTIPLY, + new_without_default::NEW_WITHOUT_DEFAULT, + no_effect::NO_EFFECT, + no_effect::UNNECESSARY_OPERATION, + non_copy_const::BORROW_INTERIOR_MUTABLE_CONST, + non_copy_const::DECLARE_INTERIOR_MUTABLE_CONST, + non_expressive_names::JUST_UNDERSCORES_AND_DIGITS, + non_expressive_names::MANY_SINGLE_CHAR_NAMES, + non_expressive_names::SIMILAR_NAMES, + non_octal_unix_permissions::NON_OCTAL_UNIX_PERMISSIONS, + nonstandard_macro_braces::NONSTANDARD_MACRO_BRACES, + open_options::NONSENSICAL_OPEN_OPTIONS, + option_env_unwrap::OPTION_ENV_UNWRAP, + option_if_let_else::OPTION_IF_LET_ELSE, + overflow_check_conditional::OVERFLOW_CHECK_CONDITIONAL, + panic_in_result_fn::PANIC_IN_RESULT_FN, + panic_unimplemented::PANIC, + panic_unimplemented::TODO, + panic_unimplemented::UNIMPLEMENTED, + panic_unimplemented::UNREACHABLE, + partialeq_ne_impl::PARTIALEQ_NE_IMPL, + pass_by_ref_or_value::LARGE_TYPES_PASSED_BY_VALUE, + pass_by_ref_or_value::TRIVIALLY_COPY_PASS_BY_REF, + path_buf_push_overwrite::PATH_BUF_PUSH_OVERWRITE, + pattern_type_mismatch::PATTERN_TYPE_MISMATCH, + precedence::PRECEDENCE, + ptr::CMP_NULL, + ptr::INVALID_NULL_PTR_USAGE, + ptr::MUT_FROM_REF, + ptr::PTR_ARG, + ptr_eq::PTR_EQ, + ptr_offset_with_cast::PTR_OFFSET_WITH_CAST, + question_mark::QUESTION_MARK, + ranges::MANUAL_RANGE_CONTAINS, + ranges::RANGE_MINUS_ONE, + ranges::RANGE_PLUS_ONE, + ranges::RANGE_ZIP_WITH_LEN, + ranges::REVERSED_EMPTY_RANGES, + redundant_clone::REDUNDANT_CLONE, + redundant_closure_call::REDUNDANT_CLOSURE_CALL, + redundant_else::REDUNDANT_ELSE, + redundant_field_names::REDUNDANT_FIELD_NAMES, + redundant_pub_crate::REDUNDANT_PUB_CRATE, + redundant_slicing::REDUNDANT_SLICING, + redundant_static_lifetimes::REDUNDANT_STATIC_LIFETIMES, + ref_option_ref::REF_OPTION_REF, + reference::DEREF_ADDROF, + reference::REF_IN_DEREF, + regex::INVALID_REGEX, + regex::TRIVIAL_REGEX, + repeat_once::REPEAT_ONCE, + returns::LET_AND_RETURN, + returns::NEEDLESS_RETURN, + same_name_method::SAME_NAME_METHOD, + self_assignment::SELF_ASSIGNMENT, + self_named_constructors::SELF_NAMED_CONSTRUCTORS, + semicolon_if_nothing_returned::SEMICOLON_IF_NOTHING_RETURNED, + serde_api::SERDE_API_MISUSE, + shadow::SHADOW_REUSE, + shadow::SHADOW_SAME, + shadow::SHADOW_UNRELATED, + single_component_path_imports::SINGLE_COMPONENT_PATH_IMPORTS, + size_of_in_element_count::SIZE_OF_IN_ELEMENT_COUNT, + slow_vector_initialization::SLOW_VECTOR_INITIALIZATION, + stable_sort_primitive::STABLE_SORT_PRIMITIVE, + strings::STRING_ADD, + strings::STRING_ADD_ASSIGN, + strings::STRING_FROM_UTF8_AS_BYTES, + strings::STRING_LIT_AS_BYTES, + strings::STRING_TO_STRING, + strings::STR_TO_STRING, + strlen_on_c_strings::STRLEN_ON_C_STRINGS, + suspicious_operation_groupings::SUSPICIOUS_OPERATION_GROUPINGS, + suspicious_trait_impl::SUSPICIOUS_ARITHMETIC_IMPL, + suspicious_trait_impl::SUSPICIOUS_OP_ASSIGN_IMPL, + swap::ALMOST_SWAPPED, + swap::MANUAL_SWAP, + tabs_in_doc_comments::TABS_IN_DOC_COMMENTS, + temporary_assignment::TEMPORARY_ASSIGNMENT, + to_digit_is_some::TO_DIGIT_IS_SOME, + to_string_in_display::TO_STRING_IN_DISPLAY, + trait_bounds::TRAIT_DUPLICATION_IN_BOUNDS, + trait_bounds::TYPE_REPETITION_IN_BOUNDS, + transmute::CROSSPOINTER_TRANSMUTE, + transmute::TRANSMUTES_EXPRESSIBLE_AS_PTR_CASTS, + transmute::TRANSMUTE_BYTES_TO_STR, + transmute::TRANSMUTE_FLOAT_TO_INT, + transmute::TRANSMUTE_INT_TO_BOOL, + transmute::TRANSMUTE_INT_TO_CHAR, + transmute::TRANSMUTE_INT_TO_FLOAT, + transmute::TRANSMUTE_PTR_TO_PTR, + transmute::TRANSMUTE_PTR_TO_REF, + transmute::UNSOUND_COLLECTION_TRANSMUTE, + transmute::USELESS_TRANSMUTE, + transmute::WRONG_TRANSMUTE, + transmuting_null::TRANSMUTING_NULL, + try_err::TRY_ERR, + types::BORROWED_BOX, + types::BOX_COLLECTION, + types::LINKEDLIST, + types::OPTION_OPTION, + types::RC_BUFFER, + types::RC_MUTEX, + types::REDUNDANT_ALLOCATION, + types::TYPE_COMPLEXITY, + types::VEC_BOX, + undropped_manually_drops::UNDROPPED_MANUALLY_DROPS, + unicode::INVISIBLE_CHARACTERS, + unicode::NON_ASCII_LITERAL, + unicode::UNICODE_NOT_NFC, + unit_return_expecting_ord::UNIT_RETURN_EXPECTING_ORD, + unit_types::LET_UNIT_VALUE, + unit_types::UNIT_ARG, + unit_types::UNIT_CMP, + unnamed_address::FN_ADDRESS_COMPARISONS, + unnamed_address::VTABLE_ADDRESS_COMPARISONS, + unnecessary_self_imports::UNNECESSARY_SELF_IMPORTS, + unnecessary_sort_by::UNNECESSARY_SORT_BY, + unnecessary_wraps::UNNECESSARY_WRAPS, + unnested_or_patterns::UNNESTED_OR_PATTERNS, + unsafe_removed_from_name::UNSAFE_REMOVED_FROM_NAME, + unused_async::UNUSED_ASYNC, + unused_io_amount::UNUSED_IO_AMOUNT, + unused_self::UNUSED_SELF, + unused_unit::UNUSED_UNIT, + unwrap::PANICKING_UNWRAP, + unwrap::UNNECESSARY_UNWRAP, + unwrap_in_result::UNWRAP_IN_RESULT, + upper_case_acronyms::UPPER_CASE_ACRONYMS, + use_self::USE_SELF, + useless_conversion::USELESS_CONVERSION, + vec::USELESS_VEC, + vec_init_then_push::VEC_INIT_THEN_PUSH, + vec_resize_to_zero::VEC_RESIZE_TO_ZERO, + verbose_file_reads::VERBOSE_FILE_READS, + wildcard_dependencies::WILDCARD_DEPENDENCIES, + wildcard_imports::ENUM_GLOB_USE, + wildcard_imports::WILDCARD_IMPORTS, + write::PRINTLN_EMPTY_STRING, + write::PRINT_LITERAL, + write::PRINT_STDERR, + write::PRINT_STDOUT, + write::PRINT_WITH_NEWLINE, + write::USE_DEBUG, + write::WRITELN_EMPTY_STRING, + write::WRITE_LITERAL, + write::WRITE_WITH_NEWLINE, + zero_div_zero::ZERO_DIVIDED_BY_ZERO, + zero_sized_map_values::ZERO_SIZED_MAP_VALUES, +]) diff --git a/clippy_lints/src/lib.register_nursery.rs b/clippy_lints/src/lib.register_nursery.rs index 72a09fcfe25..b082f577a52 100644 --- a/clippy_lints/src/lib.register_nursery.rs +++ b/clippy_lints/src/lib.register_nursery.rs @@ -3,26 +3,26 @@ // Manual edits will be overwritten. store.register_group(true, "clippy::nursery", Some("clippy_nursery"), vec![ -LintId::of(attrs::EMPTY_LINE_AFTER_OUTER_ATTR), -LintId::of(cognitive_complexity::COGNITIVE_COMPLEXITY), -LintId::of(copies::BRANCHES_SHARING_CODE), -LintId::of(disallowed_method::DISALLOWED_METHOD), -LintId::of(disallowed_type::DISALLOWED_TYPE), -LintId::of(fallible_impl_from::FALLIBLE_IMPL_FROM), -LintId::of(floating_point_arithmetic::IMPRECISE_FLOPS), -LintId::of(floating_point_arithmetic::SUBOPTIMAL_FLOPS), -LintId::of(future_not_send::FUTURE_NOT_SEND), -LintId::of(let_if_seq::USELESS_LET_IF_SEQ), -LintId::of(missing_const_for_fn::MISSING_CONST_FOR_FN), -LintId::of(mutable_debug_assertion::DEBUG_ASSERT_WITH_MUT_CALL), -LintId::of(mutex_atomic::MUTEX_INTEGER), -LintId::of(nonstandard_macro_braces::NONSTANDARD_MACRO_BRACES), -LintId::of(option_if_let_else::OPTION_IF_LET_ELSE), -LintId::of(path_buf_push_overwrite::PATH_BUF_PUSH_OVERWRITE), -LintId::of(redundant_pub_crate::REDUNDANT_PUB_CRATE), -LintId::of(regex::TRIVIAL_REGEX), -LintId::of(strings::STRING_LIT_AS_BYTES), -LintId::of(suspicious_operation_groupings::SUSPICIOUS_OPERATION_GROUPINGS), -LintId::of(transmute::USELESS_TRANSMUTE), -LintId::of(use_self::USE_SELF), -]) \ No newline at end of file + LintId::of(attrs::EMPTY_LINE_AFTER_OUTER_ATTR), + LintId::of(cognitive_complexity::COGNITIVE_COMPLEXITY), + LintId::of(copies::BRANCHES_SHARING_CODE), + LintId::of(disallowed_method::DISALLOWED_METHOD), + LintId::of(disallowed_type::DISALLOWED_TYPE), + LintId::of(fallible_impl_from::FALLIBLE_IMPL_FROM), + LintId::of(floating_point_arithmetic::IMPRECISE_FLOPS), + LintId::of(floating_point_arithmetic::SUBOPTIMAL_FLOPS), + LintId::of(future_not_send::FUTURE_NOT_SEND), + LintId::of(let_if_seq::USELESS_LET_IF_SEQ), + LintId::of(missing_const_for_fn::MISSING_CONST_FOR_FN), + LintId::of(mutable_debug_assertion::DEBUG_ASSERT_WITH_MUT_CALL), + LintId::of(mutex_atomic::MUTEX_INTEGER), + LintId::of(nonstandard_macro_braces::NONSTANDARD_MACRO_BRACES), + LintId::of(option_if_let_else::OPTION_IF_LET_ELSE), + LintId::of(path_buf_push_overwrite::PATH_BUF_PUSH_OVERWRITE), + LintId::of(redundant_pub_crate::REDUNDANT_PUB_CRATE), + LintId::of(regex::TRIVIAL_REGEX), + LintId::of(strings::STRING_LIT_AS_BYTES), + LintId::of(suspicious_operation_groupings::SUSPICIOUS_OPERATION_GROUPINGS), + LintId::of(transmute::USELESS_TRANSMUTE), + LintId::of(use_self::USE_SELF), +]) diff --git a/clippy_lints/src/lib.register_pedantic.rs b/clippy_lints/src/lib.register_pedantic.rs index 8356198d80d..334e058c4ae 100644 --- a/clippy_lints/src/lib.register_pedantic.rs +++ b/clippy_lints/src/lib.register_pedantic.rs @@ -3,99 +3,99 @@ // Manual edits will be overwritten. store.register_group(true, "clippy::pedantic", Some("clippy_pedantic"), vec![ -LintId::of(attrs::INLINE_ALWAYS), -LintId::of(await_holding_invalid::AWAIT_HOLDING_LOCK), -LintId::of(await_holding_invalid::AWAIT_HOLDING_REFCELL_REF), -LintId::of(bit_mask::VERBOSE_BIT_MASK), -LintId::of(bytecount::NAIVE_BYTECOUNT), -LintId::of(case_sensitive_file_extension_comparisons::CASE_SENSITIVE_FILE_EXTENSION_COMPARISONS), -LintId::of(casts::CAST_LOSSLESS), -LintId::of(casts::CAST_POSSIBLE_TRUNCATION), -LintId::of(casts::CAST_POSSIBLE_WRAP), -LintId::of(casts::CAST_PRECISION_LOSS), -LintId::of(casts::CAST_PTR_ALIGNMENT), -LintId::of(casts::CAST_SIGN_LOSS), -LintId::of(casts::PTR_AS_PTR), -LintId::of(checked_conversions::CHECKED_CONVERSIONS), -LintId::of(copies::SAME_FUNCTIONS_IN_IF_CONDITION), -LintId::of(copy_iterator::COPY_ITERATOR), -LintId::of(default::DEFAULT_TRAIT_ACCESS), -LintId::of(dereference::EXPLICIT_DEREF_METHODS), -LintId::of(derive::EXPL_IMPL_CLONE_ON_COPY), -LintId::of(derive::UNSAFE_DERIVE_DESERIALIZE), -LintId::of(doc::DOC_MARKDOWN), -LintId::of(doc::MISSING_ERRORS_DOC), -LintId::of(doc::MISSING_PANICS_DOC), -LintId::of(empty_enum::EMPTY_ENUM), -LintId::of(enum_variants::MODULE_NAME_REPETITIONS), -LintId::of(eta_reduction::REDUNDANT_CLOSURE_FOR_METHOD_CALLS), -LintId::of(excessive_bools::FN_PARAMS_EXCESSIVE_BOOLS), -LintId::of(excessive_bools::STRUCT_EXCESSIVE_BOOLS), -LintId::of(functions::MUST_USE_CANDIDATE), -LintId::of(functions::TOO_MANY_LINES), -LintId::of(if_not_else::IF_NOT_ELSE), -LintId::of(implicit_hasher::IMPLICIT_HASHER), -LintId::of(implicit_saturating_sub::IMPLICIT_SATURATING_SUB), -LintId::of(inconsistent_struct_constructor::INCONSISTENT_STRUCT_CONSTRUCTOR), -LintId::of(infinite_iter::MAYBE_INFINITE_ITER), -LintId::of(invalid_upcast_comparisons::INVALID_UPCAST_COMPARISONS), -LintId::of(items_after_statements::ITEMS_AFTER_STATEMENTS), -LintId::of(iter_not_returning_iterator::ITER_NOT_RETURNING_ITERATOR), -LintId::of(large_stack_arrays::LARGE_STACK_ARRAYS), -LintId::of(let_underscore::LET_UNDERSCORE_DROP), -LintId::of(literal_representation::LARGE_DIGIT_GROUPS), -LintId::of(literal_representation::UNREADABLE_LITERAL), -LintId::of(loops::EXPLICIT_INTO_ITER_LOOP), -LintId::of(loops::EXPLICIT_ITER_LOOP), -LintId::of(macro_use::MACRO_USE_IMPORTS), -LintId::of(manual_ok_or::MANUAL_OK_OR), -LintId::of(match_on_vec_items::MATCH_ON_VEC_ITEMS), -LintId::of(matches::MATCH_BOOL), -LintId::of(matches::MATCH_SAME_ARMS), -LintId::of(matches::MATCH_WILDCARD_FOR_SINGLE_VARIANTS), -LintId::of(matches::MATCH_WILD_ERR_ARM), -LintId::of(matches::SINGLE_MATCH_ELSE), -LintId::of(methods::CLONED_INSTEAD_OF_COPIED), -LintId::of(methods::FILTER_MAP_NEXT), -LintId::of(methods::FLAT_MAP_OPTION), -LintId::of(methods::FROM_ITER_INSTEAD_OF_COLLECT), -LintId::of(methods::IMPLICIT_CLONE), -LintId::of(methods::INEFFICIENT_TO_STRING), -LintId::of(methods::MAP_FLATTEN), -LintId::of(methods::MAP_UNWRAP_OR), -LintId::of(misc::FLOAT_CMP), -LintId::of(misc::USED_UNDERSCORE_BINDING), -LintId::of(misc_early::UNSEPARATED_LITERAL_SUFFIX), -LintId::of(mut_mut::MUT_MUT), -LintId::of(needless_bitwise_bool::NEEDLESS_BITWISE_BOOL), -LintId::of(needless_borrow::REF_BINDING_TO_REFERENCE), -LintId::of(needless_continue::NEEDLESS_CONTINUE), -LintId::of(needless_for_each::NEEDLESS_FOR_EACH), -LintId::of(needless_pass_by_value::NEEDLESS_PASS_BY_VALUE), -LintId::of(non_expressive_names::MANY_SINGLE_CHAR_NAMES), -LintId::of(non_expressive_names::SIMILAR_NAMES), -LintId::of(pass_by_ref_or_value::LARGE_TYPES_PASSED_BY_VALUE), -LintId::of(pass_by_ref_or_value::TRIVIALLY_COPY_PASS_BY_REF), -LintId::of(ranges::RANGE_MINUS_ONE), -LintId::of(ranges::RANGE_PLUS_ONE), -LintId::of(redundant_else::REDUNDANT_ELSE), -LintId::of(ref_option_ref::REF_OPTION_REF), -LintId::of(semicolon_if_nothing_returned::SEMICOLON_IF_NOTHING_RETURNED), -LintId::of(shadow::SHADOW_UNRELATED), -LintId::of(strings::STRING_ADD_ASSIGN), -LintId::of(trait_bounds::TRAIT_DUPLICATION_IN_BOUNDS), -LintId::of(trait_bounds::TYPE_REPETITION_IN_BOUNDS), -LintId::of(transmute::TRANSMUTE_PTR_TO_PTR), -LintId::of(types::LINKEDLIST), -LintId::of(types::OPTION_OPTION), -LintId::of(unicode::NON_ASCII_LITERAL), -LintId::of(unicode::UNICODE_NOT_NFC), -LintId::of(unit_types::LET_UNIT_VALUE), -LintId::of(unnecessary_wraps::UNNECESSARY_WRAPS), -LintId::of(unnested_or_patterns::UNNESTED_OR_PATTERNS), -LintId::of(unused_async::UNUSED_ASYNC), -LintId::of(unused_self::UNUSED_SELF), -LintId::of(wildcard_imports::ENUM_GLOB_USE), -LintId::of(wildcard_imports::WILDCARD_IMPORTS), -LintId::of(zero_sized_map_values::ZERO_SIZED_MAP_VALUES), -]) \ No newline at end of file + LintId::of(attrs::INLINE_ALWAYS), + LintId::of(await_holding_invalid::AWAIT_HOLDING_LOCK), + LintId::of(await_holding_invalid::AWAIT_HOLDING_REFCELL_REF), + LintId::of(bit_mask::VERBOSE_BIT_MASK), + LintId::of(bytecount::NAIVE_BYTECOUNT), + LintId::of(case_sensitive_file_extension_comparisons::CASE_SENSITIVE_FILE_EXTENSION_COMPARISONS), + LintId::of(casts::CAST_LOSSLESS), + LintId::of(casts::CAST_POSSIBLE_TRUNCATION), + LintId::of(casts::CAST_POSSIBLE_WRAP), + LintId::of(casts::CAST_PRECISION_LOSS), + LintId::of(casts::CAST_PTR_ALIGNMENT), + LintId::of(casts::CAST_SIGN_LOSS), + LintId::of(casts::PTR_AS_PTR), + LintId::of(checked_conversions::CHECKED_CONVERSIONS), + LintId::of(copies::SAME_FUNCTIONS_IN_IF_CONDITION), + LintId::of(copy_iterator::COPY_ITERATOR), + LintId::of(default::DEFAULT_TRAIT_ACCESS), + LintId::of(dereference::EXPLICIT_DEREF_METHODS), + LintId::of(derive::EXPL_IMPL_CLONE_ON_COPY), + LintId::of(derive::UNSAFE_DERIVE_DESERIALIZE), + LintId::of(doc::DOC_MARKDOWN), + LintId::of(doc::MISSING_ERRORS_DOC), + LintId::of(doc::MISSING_PANICS_DOC), + LintId::of(empty_enum::EMPTY_ENUM), + LintId::of(enum_variants::MODULE_NAME_REPETITIONS), + LintId::of(eta_reduction::REDUNDANT_CLOSURE_FOR_METHOD_CALLS), + LintId::of(excessive_bools::FN_PARAMS_EXCESSIVE_BOOLS), + LintId::of(excessive_bools::STRUCT_EXCESSIVE_BOOLS), + LintId::of(functions::MUST_USE_CANDIDATE), + LintId::of(functions::TOO_MANY_LINES), + LintId::of(if_not_else::IF_NOT_ELSE), + LintId::of(implicit_hasher::IMPLICIT_HASHER), + LintId::of(implicit_saturating_sub::IMPLICIT_SATURATING_SUB), + LintId::of(inconsistent_struct_constructor::INCONSISTENT_STRUCT_CONSTRUCTOR), + LintId::of(infinite_iter::MAYBE_INFINITE_ITER), + LintId::of(invalid_upcast_comparisons::INVALID_UPCAST_COMPARISONS), + LintId::of(items_after_statements::ITEMS_AFTER_STATEMENTS), + LintId::of(iter_not_returning_iterator::ITER_NOT_RETURNING_ITERATOR), + LintId::of(large_stack_arrays::LARGE_STACK_ARRAYS), + LintId::of(let_underscore::LET_UNDERSCORE_DROP), + LintId::of(literal_representation::LARGE_DIGIT_GROUPS), + LintId::of(literal_representation::UNREADABLE_LITERAL), + LintId::of(loops::EXPLICIT_INTO_ITER_LOOP), + LintId::of(loops::EXPLICIT_ITER_LOOP), + LintId::of(macro_use::MACRO_USE_IMPORTS), + LintId::of(manual_ok_or::MANUAL_OK_OR), + LintId::of(match_on_vec_items::MATCH_ON_VEC_ITEMS), + LintId::of(matches::MATCH_BOOL), + LintId::of(matches::MATCH_SAME_ARMS), + LintId::of(matches::MATCH_WILDCARD_FOR_SINGLE_VARIANTS), + LintId::of(matches::MATCH_WILD_ERR_ARM), + LintId::of(matches::SINGLE_MATCH_ELSE), + LintId::of(methods::CLONED_INSTEAD_OF_COPIED), + LintId::of(methods::FILTER_MAP_NEXT), + LintId::of(methods::FLAT_MAP_OPTION), + LintId::of(methods::FROM_ITER_INSTEAD_OF_COLLECT), + LintId::of(methods::IMPLICIT_CLONE), + LintId::of(methods::INEFFICIENT_TO_STRING), + LintId::of(methods::MAP_FLATTEN), + LintId::of(methods::MAP_UNWRAP_OR), + LintId::of(misc::FLOAT_CMP), + LintId::of(misc::USED_UNDERSCORE_BINDING), + LintId::of(misc_early::UNSEPARATED_LITERAL_SUFFIX), + LintId::of(mut_mut::MUT_MUT), + LintId::of(needless_bitwise_bool::NEEDLESS_BITWISE_BOOL), + LintId::of(needless_borrow::REF_BINDING_TO_REFERENCE), + LintId::of(needless_continue::NEEDLESS_CONTINUE), + LintId::of(needless_for_each::NEEDLESS_FOR_EACH), + LintId::of(needless_pass_by_value::NEEDLESS_PASS_BY_VALUE), + LintId::of(non_expressive_names::MANY_SINGLE_CHAR_NAMES), + LintId::of(non_expressive_names::SIMILAR_NAMES), + LintId::of(pass_by_ref_or_value::LARGE_TYPES_PASSED_BY_VALUE), + LintId::of(pass_by_ref_or_value::TRIVIALLY_COPY_PASS_BY_REF), + LintId::of(ranges::RANGE_MINUS_ONE), + LintId::of(ranges::RANGE_PLUS_ONE), + LintId::of(redundant_else::REDUNDANT_ELSE), + LintId::of(ref_option_ref::REF_OPTION_REF), + LintId::of(semicolon_if_nothing_returned::SEMICOLON_IF_NOTHING_RETURNED), + LintId::of(shadow::SHADOW_UNRELATED), + LintId::of(strings::STRING_ADD_ASSIGN), + LintId::of(trait_bounds::TRAIT_DUPLICATION_IN_BOUNDS), + LintId::of(trait_bounds::TYPE_REPETITION_IN_BOUNDS), + LintId::of(transmute::TRANSMUTE_PTR_TO_PTR), + LintId::of(types::LINKEDLIST), + LintId::of(types::OPTION_OPTION), + LintId::of(unicode::NON_ASCII_LITERAL), + LintId::of(unicode::UNICODE_NOT_NFC), + LintId::of(unit_types::LET_UNIT_VALUE), + LintId::of(unnecessary_wraps::UNNECESSARY_WRAPS), + LintId::of(unnested_or_patterns::UNNESTED_OR_PATTERNS), + LintId::of(unused_async::UNUSED_ASYNC), + LintId::of(unused_self::UNUSED_SELF), + LintId::of(wildcard_imports::ENUM_GLOB_USE), + LintId::of(wildcard_imports::WILDCARD_IMPORTS), + LintId::of(zero_sized_map_values::ZERO_SIZED_MAP_VALUES), +]) diff --git a/clippy_lints/src/lib.register_perf.rs b/clippy_lints/src/lib.register_perf.rs index 610309dd893..5432345760b 100644 --- a/clippy_lints/src/lib.register_perf.rs +++ b/clippy_lints/src/lib.register_perf.rs @@ -3,25 +3,25 @@ // Manual edits will be overwritten. store.register_group(true, "clippy::perf", Some("clippy_perf"), vec![ -LintId::of(entry::MAP_ENTRY), -LintId::of(escape::BOXED_LOCAL), -LintId::of(large_const_arrays::LARGE_CONST_ARRAYS), -LintId::of(large_enum_variant::LARGE_ENUM_VARIANT), -LintId::of(loops::MANUAL_MEMCPY), -LintId::of(loops::NEEDLESS_COLLECT), -LintId::of(methods::EXPECT_FUN_CALL), -LintId::of(methods::EXTEND_WITH_DRAIN), -LintId::of(methods::ITER_NTH), -LintId::of(methods::MANUAL_STR_REPEAT), -LintId::of(methods::OR_FUN_CALL), -LintId::of(methods::SINGLE_CHAR_PATTERN), -LintId::of(misc::CMP_OWNED), -LintId::of(mutex_atomic::MUTEX_ATOMIC), -LintId::of(redundant_clone::REDUNDANT_CLONE), -LintId::of(slow_vector_initialization::SLOW_VECTOR_INITIALIZATION), -LintId::of(stable_sort_primitive::STABLE_SORT_PRIMITIVE), -LintId::of(types::BOX_COLLECTION), -LintId::of(types::REDUNDANT_ALLOCATION), -LintId::of(vec::USELESS_VEC), -LintId::of(vec_init_then_push::VEC_INIT_THEN_PUSH), -]) \ No newline at end of file + LintId::of(entry::MAP_ENTRY), + LintId::of(escape::BOXED_LOCAL), + LintId::of(large_const_arrays::LARGE_CONST_ARRAYS), + LintId::of(large_enum_variant::LARGE_ENUM_VARIANT), + LintId::of(loops::MANUAL_MEMCPY), + LintId::of(loops::NEEDLESS_COLLECT), + LintId::of(methods::EXPECT_FUN_CALL), + LintId::of(methods::EXTEND_WITH_DRAIN), + LintId::of(methods::ITER_NTH), + LintId::of(methods::MANUAL_STR_REPEAT), + LintId::of(methods::OR_FUN_CALL), + LintId::of(methods::SINGLE_CHAR_PATTERN), + LintId::of(misc::CMP_OWNED), + LintId::of(mutex_atomic::MUTEX_ATOMIC), + LintId::of(redundant_clone::REDUNDANT_CLONE), + LintId::of(slow_vector_initialization::SLOW_VECTOR_INITIALIZATION), + LintId::of(stable_sort_primitive::STABLE_SORT_PRIMITIVE), + LintId::of(types::BOX_COLLECTION), + LintId::of(types::REDUNDANT_ALLOCATION), + LintId::of(vec::USELESS_VEC), + LintId::of(vec_init_then_push::VEC_INIT_THEN_PUSH), +]) diff --git a/clippy_lints/src/lib.register_restriction.rs b/clippy_lints/src/lib.register_restriction.rs index 8f181fe2e78..530662dfc0c 100644 --- a/clippy_lints/src/lib.register_restriction.rs +++ b/clippy_lints/src/lib.register_restriction.rs @@ -3,62 +3,62 @@ // Manual edits will be overwritten. store.register_group(true, "clippy::restriction", Some("clippy_restriction"), vec![ -LintId::of(arithmetic::FLOAT_ARITHMETIC), -LintId::of(arithmetic::INTEGER_ARITHMETIC), -LintId::of(as_conversions::AS_CONVERSIONS), -LintId::of(asm_syntax::INLINE_ASM_X86_ATT_SYNTAX), -LintId::of(asm_syntax::INLINE_ASM_X86_INTEL_SYNTAX), -LintId::of(create_dir::CREATE_DIR), -LintId::of(dbg_macro::DBG_MACRO), -LintId::of(default_numeric_fallback::DEFAULT_NUMERIC_FALLBACK), -LintId::of(disallowed_script_idents::DISALLOWED_SCRIPT_IDENTS), -LintId::of(else_if_without_else::ELSE_IF_WITHOUT_ELSE), -LintId::of(exhaustive_items::EXHAUSTIVE_ENUMS), -LintId::of(exhaustive_items::EXHAUSTIVE_STRUCTS), -LintId::of(exit::EXIT), -LintId::of(float_literal::LOSSY_FLOAT_LITERAL), -LintId::of(if_then_some_else_none::IF_THEN_SOME_ELSE_NONE), -LintId::of(implicit_return::IMPLICIT_RETURN), -LintId::of(indexing_slicing::INDEXING_SLICING), -LintId::of(inherent_impl::MULTIPLE_INHERENT_IMPL), -LintId::of(integer_division::INTEGER_DIVISION), -LintId::of(let_underscore::LET_UNDERSCORE_MUST_USE), -LintId::of(literal_representation::DECIMAL_LITERAL_REPRESENTATION), -LintId::of(map_err_ignore::MAP_ERR_IGNORE), -LintId::of(matches::REST_PAT_IN_FULLY_BOUND_STRUCTS), -LintId::of(matches::WILDCARD_ENUM_MATCH_ARM), -LintId::of(mem_forget::MEM_FORGET), -LintId::of(methods::CLONE_ON_REF_PTR), -LintId::of(methods::EXPECT_USED), -LintId::of(methods::FILETYPE_IS_FILE), -LintId::of(methods::GET_UNWRAP), -LintId::of(methods::UNWRAP_USED), -LintId::of(misc::FLOAT_CMP_CONST), -LintId::of(misc_early::UNNEEDED_FIELD_PATTERN), -LintId::of(missing_doc::MISSING_DOCS_IN_PRIVATE_ITEMS), -LintId::of(missing_enforced_import_rename::MISSING_ENFORCED_IMPORT_RENAMES), -LintId::of(missing_inline::MISSING_INLINE_IN_PUBLIC_ITEMS), -LintId::of(module_style::MOD_MODULE_FILES), -LintId::of(module_style::SELF_NAMED_MODULE_FILES), -LintId::of(modulo_arithmetic::MODULO_ARITHMETIC), -LintId::of(panic_in_result_fn::PANIC_IN_RESULT_FN), -LintId::of(panic_unimplemented::PANIC), -LintId::of(panic_unimplemented::TODO), -LintId::of(panic_unimplemented::UNIMPLEMENTED), -LintId::of(panic_unimplemented::UNREACHABLE), -LintId::of(pattern_type_mismatch::PATTERN_TYPE_MISMATCH), -LintId::of(same_name_method::SAME_NAME_METHOD), -LintId::of(shadow::SHADOW_REUSE), -LintId::of(shadow::SHADOW_SAME), -LintId::of(strings::STRING_ADD), -LintId::of(strings::STRING_TO_STRING), -LintId::of(strings::STR_TO_STRING), -LintId::of(types::RC_BUFFER), -LintId::of(types::RC_MUTEX), -LintId::of(unnecessary_self_imports::UNNECESSARY_SELF_IMPORTS), -LintId::of(unwrap_in_result::UNWRAP_IN_RESULT), -LintId::of(verbose_file_reads::VERBOSE_FILE_READS), -LintId::of(write::PRINT_STDERR), -LintId::of(write::PRINT_STDOUT), -LintId::of(write::USE_DEBUG), -]) \ No newline at end of file + LintId::of(arithmetic::FLOAT_ARITHMETIC), + LintId::of(arithmetic::INTEGER_ARITHMETIC), + LintId::of(as_conversions::AS_CONVERSIONS), + LintId::of(asm_syntax::INLINE_ASM_X86_ATT_SYNTAX), + LintId::of(asm_syntax::INLINE_ASM_X86_INTEL_SYNTAX), + LintId::of(create_dir::CREATE_DIR), + LintId::of(dbg_macro::DBG_MACRO), + LintId::of(default_numeric_fallback::DEFAULT_NUMERIC_FALLBACK), + LintId::of(disallowed_script_idents::DISALLOWED_SCRIPT_IDENTS), + LintId::of(else_if_without_else::ELSE_IF_WITHOUT_ELSE), + LintId::of(exhaustive_items::EXHAUSTIVE_ENUMS), + LintId::of(exhaustive_items::EXHAUSTIVE_STRUCTS), + LintId::of(exit::EXIT), + LintId::of(float_literal::LOSSY_FLOAT_LITERAL), + LintId::of(if_then_some_else_none::IF_THEN_SOME_ELSE_NONE), + LintId::of(implicit_return::IMPLICIT_RETURN), + LintId::of(indexing_slicing::INDEXING_SLICING), + LintId::of(inherent_impl::MULTIPLE_INHERENT_IMPL), + LintId::of(integer_division::INTEGER_DIVISION), + LintId::of(let_underscore::LET_UNDERSCORE_MUST_USE), + LintId::of(literal_representation::DECIMAL_LITERAL_REPRESENTATION), + LintId::of(map_err_ignore::MAP_ERR_IGNORE), + LintId::of(matches::REST_PAT_IN_FULLY_BOUND_STRUCTS), + LintId::of(matches::WILDCARD_ENUM_MATCH_ARM), + LintId::of(mem_forget::MEM_FORGET), + LintId::of(methods::CLONE_ON_REF_PTR), + LintId::of(methods::EXPECT_USED), + LintId::of(methods::FILETYPE_IS_FILE), + LintId::of(methods::GET_UNWRAP), + LintId::of(methods::UNWRAP_USED), + LintId::of(misc::FLOAT_CMP_CONST), + LintId::of(misc_early::UNNEEDED_FIELD_PATTERN), + LintId::of(missing_doc::MISSING_DOCS_IN_PRIVATE_ITEMS), + LintId::of(missing_enforced_import_rename::MISSING_ENFORCED_IMPORT_RENAMES), + LintId::of(missing_inline::MISSING_INLINE_IN_PUBLIC_ITEMS), + LintId::of(module_style::MOD_MODULE_FILES), + LintId::of(module_style::SELF_NAMED_MODULE_FILES), + LintId::of(modulo_arithmetic::MODULO_ARITHMETIC), + LintId::of(panic_in_result_fn::PANIC_IN_RESULT_FN), + LintId::of(panic_unimplemented::PANIC), + LintId::of(panic_unimplemented::TODO), + LintId::of(panic_unimplemented::UNIMPLEMENTED), + LintId::of(panic_unimplemented::UNREACHABLE), + LintId::of(pattern_type_mismatch::PATTERN_TYPE_MISMATCH), + LintId::of(same_name_method::SAME_NAME_METHOD), + LintId::of(shadow::SHADOW_REUSE), + LintId::of(shadow::SHADOW_SAME), + LintId::of(strings::STRING_ADD), + LintId::of(strings::STRING_TO_STRING), + LintId::of(strings::STR_TO_STRING), + LintId::of(types::RC_BUFFER), + LintId::of(types::RC_MUTEX), + LintId::of(unnecessary_self_imports::UNNECESSARY_SELF_IMPORTS), + LintId::of(unwrap_in_result::UNWRAP_IN_RESULT), + LintId::of(verbose_file_reads::VERBOSE_FILE_READS), + LintId::of(write::PRINT_STDERR), + LintId::of(write::PRINT_STDOUT), + LintId::of(write::USE_DEBUG), +]) diff --git a/clippy_lints/src/lib.register_style.rs b/clippy_lints/src/lib.register_style.rs index cd563907b77..a39c111c574 100644 --- a/clippy_lints/src/lib.register_style.rs +++ b/clippy_lints/src/lib.register_style.rs @@ -3,112 +3,112 @@ // Manual edits will be overwritten. store.register_group(true, "clippy::style", Some("clippy_style"), vec![ -LintId::of(assertions_on_constants::ASSERTIONS_ON_CONSTANTS), -LintId::of(assign_ops::ASSIGN_OP_PATTERN), -LintId::of(blacklisted_name::BLACKLISTED_NAME), -LintId::of(blocks_in_if_conditions::BLOCKS_IN_IF_CONDITIONS), -LintId::of(bool_assert_comparison::BOOL_ASSERT_COMPARISON), -LintId::of(casts::FN_TO_NUMERIC_CAST), -LintId::of(casts::FN_TO_NUMERIC_CAST_WITH_TRUNCATION), -LintId::of(collapsible_if::COLLAPSIBLE_ELSE_IF), -LintId::of(collapsible_if::COLLAPSIBLE_IF), -LintId::of(collapsible_match::COLLAPSIBLE_MATCH), -LintId::of(comparison_chain::COMPARISON_CHAIN), -LintId::of(default::FIELD_REASSIGN_WITH_DEFAULT), -LintId::of(doc::MISSING_SAFETY_DOC), -LintId::of(doc::NEEDLESS_DOCTEST_MAIN), -LintId::of(enum_variants::ENUM_VARIANT_NAMES), -LintId::of(enum_variants::MODULE_INCEPTION), -LintId::of(eq_op::OP_REF), -LintId::of(eta_reduction::REDUNDANT_CLOSURE), -LintId::of(float_literal::EXCESSIVE_PRECISION), -LintId::of(from_over_into::FROM_OVER_INTO), -LintId::of(from_str_radix_10::FROM_STR_RADIX_10), -LintId::of(functions::DOUBLE_MUST_USE), -LintId::of(functions::MUST_USE_UNIT), -LintId::of(functions::RESULT_UNIT_ERR), -LintId::of(if_then_panic::IF_THEN_PANIC), -LintId::of(inherent_to_string::INHERENT_TO_STRING), -LintId::of(len_zero::COMPARISON_TO_EMPTY), -LintId::of(len_zero::LEN_WITHOUT_IS_EMPTY), -LintId::of(len_zero::LEN_ZERO), -LintId::of(literal_representation::INCONSISTENT_DIGIT_GROUPING), -LintId::of(literal_representation::UNUSUAL_BYTE_GROUPINGS), -LintId::of(loops::FOR_KV_MAP), -LintId::of(loops::NEEDLESS_RANGE_LOOP), -LintId::of(loops::SAME_ITEM_PUSH), -LintId::of(loops::WHILE_LET_ON_ITERATOR), -LintId::of(main_recursion::MAIN_RECURSION), -LintId::of(manual_async_fn::MANUAL_ASYNC_FN), -LintId::of(manual_map::MANUAL_MAP), -LintId::of(manual_non_exhaustive::MANUAL_NON_EXHAUSTIVE), -LintId::of(map_clone::MAP_CLONE), -LintId::of(match_result_ok::MATCH_RESULT_OK), -LintId::of(matches::INFALLIBLE_DESTRUCTURING_MATCH), -LintId::of(matches::MATCH_LIKE_MATCHES_MACRO), -LintId::of(matches::MATCH_OVERLAPPING_ARM), -LintId::of(matches::MATCH_REF_PATS), -LintId::of(matches::REDUNDANT_PATTERN_MATCHING), -LintId::of(matches::SINGLE_MATCH), -LintId::of(mem_replace::MEM_REPLACE_OPTION_WITH_NONE), -LintId::of(mem_replace::MEM_REPLACE_WITH_DEFAULT), -LintId::of(methods::BYTES_NTH), -LintId::of(methods::CHARS_LAST_CMP), -LintId::of(methods::CHARS_NEXT_CMP), -LintId::of(methods::INTO_ITER_ON_REF), -LintId::of(methods::ITER_CLONED_COLLECT), -LintId::of(methods::ITER_NEXT_SLICE), -LintId::of(methods::ITER_NTH_ZERO), -LintId::of(methods::ITER_SKIP_NEXT), -LintId::of(methods::MANUAL_SATURATING_ARITHMETIC), -LintId::of(methods::MAP_COLLECT_RESULT_UNIT), -LintId::of(methods::NEW_RET_NO_SELF), -LintId::of(methods::OK_EXPECT), -LintId::of(methods::OPTION_MAP_OR_NONE), -LintId::of(methods::RESULT_MAP_OR_INTO_OPTION), -LintId::of(methods::SHOULD_IMPLEMENT_TRAIT), -LintId::of(methods::SINGLE_CHAR_ADD_STR), -LintId::of(methods::STRING_EXTEND_CHARS), -LintId::of(methods::UNNECESSARY_FOLD), -LintId::of(methods::UNNECESSARY_LAZY_EVALUATIONS), -LintId::of(methods::UNWRAP_OR_ELSE_DEFAULT), -LintId::of(methods::WRONG_SELF_CONVENTION), -LintId::of(misc::TOPLEVEL_REF_ARG), -LintId::of(misc::ZERO_PTR), -LintId::of(misc_early::BUILTIN_TYPE_SHADOW), -LintId::of(misc_early::DOUBLE_NEG), -LintId::of(misc_early::DUPLICATE_UNDERSCORE_ARGUMENT), -LintId::of(misc_early::MIXED_CASE_HEX_LITERALS), -LintId::of(misc_early::REDUNDANT_PATTERN), -LintId::of(mut_mutex_lock::MUT_MUTEX_LOCK), -LintId::of(mut_reference::UNNECESSARY_MUT_PASSED), -LintId::of(needless_borrow::NEEDLESS_BORROW), -LintId::of(neg_multiply::NEG_MULTIPLY), -LintId::of(new_without_default::NEW_WITHOUT_DEFAULT), -LintId::of(non_copy_const::BORROW_INTERIOR_MUTABLE_CONST), -LintId::of(non_copy_const::DECLARE_INTERIOR_MUTABLE_CONST), -LintId::of(non_expressive_names::JUST_UNDERSCORES_AND_DIGITS), -LintId::of(ptr::CMP_NULL), -LintId::of(ptr::PTR_ARG), -LintId::of(ptr_eq::PTR_EQ), -LintId::of(question_mark::QUESTION_MARK), -LintId::of(ranges::MANUAL_RANGE_CONTAINS), -LintId::of(redundant_field_names::REDUNDANT_FIELD_NAMES), -LintId::of(redundant_static_lifetimes::REDUNDANT_STATIC_LIFETIMES), -LintId::of(returns::LET_AND_RETURN), -LintId::of(returns::NEEDLESS_RETURN), -LintId::of(self_named_constructors::SELF_NAMED_CONSTRUCTORS), -LintId::of(single_component_path_imports::SINGLE_COMPONENT_PATH_IMPORTS), -LintId::of(tabs_in_doc_comments::TABS_IN_DOC_COMMENTS), -LintId::of(to_digit_is_some::TO_DIGIT_IS_SOME), -LintId::of(try_err::TRY_ERR), -LintId::of(unsafe_removed_from_name::UNSAFE_REMOVED_FROM_NAME), -LintId::of(unused_unit::UNUSED_UNIT), -LintId::of(upper_case_acronyms::UPPER_CASE_ACRONYMS), -LintId::of(write::PRINTLN_EMPTY_STRING), -LintId::of(write::PRINT_LITERAL), -LintId::of(write::PRINT_WITH_NEWLINE), -LintId::of(write::WRITELN_EMPTY_STRING), -LintId::of(write::WRITE_LITERAL), -LintId::of(write::WRITE_WITH_NEWLINE), -]) \ No newline at end of file + LintId::of(assertions_on_constants::ASSERTIONS_ON_CONSTANTS), + LintId::of(assign_ops::ASSIGN_OP_PATTERN), + LintId::of(blacklisted_name::BLACKLISTED_NAME), + LintId::of(blocks_in_if_conditions::BLOCKS_IN_IF_CONDITIONS), + LintId::of(bool_assert_comparison::BOOL_ASSERT_COMPARISON), + LintId::of(casts::FN_TO_NUMERIC_CAST), + LintId::of(casts::FN_TO_NUMERIC_CAST_WITH_TRUNCATION), + LintId::of(collapsible_if::COLLAPSIBLE_ELSE_IF), + LintId::of(collapsible_if::COLLAPSIBLE_IF), + LintId::of(collapsible_match::COLLAPSIBLE_MATCH), + LintId::of(comparison_chain::COMPARISON_CHAIN), + LintId::of(default::FIELD_REASSIGN_WITH_DEFAULT), + LintId::of(doc::MISSING_SAFETY_DOC), + LintId::of(doc::NEEDLESS_DOCTEST_MAIN), + LintId::of(enum_variants::ENUM_VARIANT_NAMES), + LintId::of(enum_variants::MODULE_INCEPTION), + LintId::of(eq_op::OP_REF), + LintId::of(eta_reduction::REDUNDANT_CLOSURE), + LintId::of(float_literal::EXCESSIVE_PRECISION), + LintId::of(from_over_into::FROM_OVER_INTO), + LintId::of(from_str_radix_10::FROM_STR_RADIX_10), + LintId::of(functions::DOUBLE_MUST_USE), + LintId::of(functions::MUST_USE_UNIT), + LintId::of(functions::RESULT_UNIT_ERR), + LintId::of(if_then_panic::IF_THEN_PANIC), + LintId::of(inherent_to_string::INHERENT_TO_STRING), + LintId::of(len_zero::COMPARISON_TO_EMPTY), + LintId::of(len_zero::LEN_WITHOUT_IS_EMPTY), + LintId::of(len_zero::LEN_ZERO), + LintId::of(literal_representation::INCONSISTENT_DIGIT_GROUPING), + LintId::of(literal_representation::UNUSUAL_BYTE_GROUPINGS), + LintId::of(loops::FOR_KV_MAP), + LintId::of(loops::NEEDLESS_RANGE_LOOP), + LintId::of(loops::SAME_ITEM_PUSH), + LintId::of(loops::WHILE_LET_ON_ITERATOR), + LintId::of(main_recursion::MAIN_RECURSION), + LintId::of(manual_async_fn::MANUAL_ASYNC_FN), + LintId::of(manual_map::MANUAL_MAP), + LintId::of(manual_non_exhaustive::MANUAL_NON_EXHAUSTIVE), + LintId::of(map_clone::MAP_CLONE), + LintId::of(match_result_ok::MATCH_RESULT_OK), + LintId::of(matches::INFALLIBLE_DESTRUCTURING_MATCH), + LintId::of(matches::MATCH_LIKE_MATCHES_MACRO), + LintId::of(matches::MATCH_OVERLAPPING_ARM), + LintId::of(matches::MATCH_REF_PATS), + LintId::of(matches::REDUNDANT_PATTERN_MATCHING), + LintId::of(matches::SINGLE_MATCH), + LintId::of(mem_replace::MEM_REPLACE_OPTION_WITH_NONE), + LintId::of(mem_replace::MEM_REPLACE_WITH_DEFAULT), + LintId::of(methods::BYTES_NTH), + LintId::of(methods::CHARS_LAST_CMP), + LintId::of(methods::CHARS_NEXT_CMP), + LintId::of(methods::INTO_ITER_ON_REF), + LintId::of(methods::ITER_CLONED_COLLECT), + LintId::of(methods::ITER_NEXT_SLICE), + LintId::of(methods::ITER_NTH_ZERO), + LintId::of(methods::ITER_SKIP_NEXT), + LintId::of(methods::MANUAL_SATURATING_ARITHMETIC), + LintId::of(methods::MAP_COLLECT_RESULT_UNIT), + LintId::of(methods::NEW_RET_NO_SELF), + LintId::of(methods::OK_EXPECT), + LintId::of(methods::OPTION_MAP_OR_NONE), + LintId::of(methods::RESULT_MAP_OR_INTO_OPTION), + LintId::of(methods::SHOULD_IMPLEMENT_TRAIT), + LintId::of(methods::SINGLE_CHAR_ADD_STR), + LintId::of(methods::STRING_EXTEND_CHARS), + LintId::of(methods::UNNECESSARY_FOLD), + LintId::of(methods::UNNECESSARY_LAZY_EVALUATIONS), + LintId::of(methods::UNWRAP_OR_ELSE_DEFAULT), + LintId::of(methods::WRONG_SELF_CONVENTION), + LintId::of(misc::TOPLEVEL_REF_ARG), + LintId::of(misc::ZERO_PTR), + LintId::of(misc_early::BUILTIN_TYPE_SHADOW), + LintId::of(misc_early::DOUBLE_NEG), + LintId::of(misc_early::DUPLICATE_UNDERSCORE_ARGUMENT), + LintId::of(misc_early::MIXED_CASE_HEX_LITERALS), + LintId::of(misc_early::REDUNDANT_PATTERN), + LintId::of(mut_mutex_lock::MUT_MUTEX_LOCK), + LintId::of(mut_reference::UNNECESSARY_MUT_PASSED), + LintId::of(needless_borrow::NEEDLESS_BORROW), + LintId::of(neg_multiply::NEG_MULTIPLY), + LintId::of(new_without_default::NEW_WITHOUT_DEFAULT), + LintId::of(non_copy_const::BORROW_INTERIOR_MUTABLE_CONST), + LintId::of(non_copy_const::DECLARE_INTERIOR_MUTABLE_CONST), + LintId::of(non_expressive_names::JUST_UNDERSCORES_AND_DIGITS), + LintId::of(ptr::CMP_NULL), + LintId::of(ptr::PTR_ARG), + LintId::of(ptr_eq::PTR_EQ), + LintId::of(question_mark::QUESTION_MARK), + LintId::of(ranges::MANUAL_RANGE_CONTAINS), + LintId::of(redundant_field_names::REDUNDANT_FIELD_NAMES), + LintId::of(redundant_static_lifetimes::REDUNDANT_STATIC_LIFETIMES), + LintId::of(returns::LET_AND_RETURN), + LintId::of(returns::NEEDLESS_RETURN), + LintId::of(self_named_constructors::SELF_NAMED_CONSTRUCTORS), + LintId::of(single_component_path_imports::SINGLE_COMPONENT_PATH_IMPORTS), + LintId::of(tabs_in_doc_comments::TABS_IN_DOC_COMMENTS), + LintId::of(to_digit_is_some::TO_DIGIT_IS_SOME), + LintId::of(try_err::TRY_ERR), + LintId::of(unsafe_removed_from_name::UNSAFE_REMOVED_FROM_NAME), + LintId::of(unused_unit::UNUSED_UNIT), + LintId::of(upper_case_acronyms::UPPER_CASE_ACRONYMS), + LintId::of(write::PRINTLN_EMPTY_STRING), + LintId::of(write::PRINT_LITERAL), + LintId::of(write::PRINT_WITH_NEWLINE), + LintId::of(write::WRITELN_EMPTY_STRING), + LintId::of(write::WRITE_LITERAL), + LintId::of(write::WRITE_WITH_NEWLINE), +]) diff --git a/clippy_lints/src/lib.register_suspicious.rs b/clippy_lints/src/lib.register_suspicious.rs index c424efe69b3..8859787fbc8 100644 --- a/clippy_lints/src/lib.register_suspicious.rs +++ b/clippy_lints/src/lib.register_suspicious.rs @@ -3,18 +3,18 @@ // Manual edits will be overwritten. store.register_group(true, "clippy::suspicious", Some("clippy_suspicious"), vec![ -LintId::of(assign_ops::MISREFACTORED_ASSIGN_OP), -LintId::of(attrs::BLANKET_CLIPPY_RESTRICTION_LINTS), -LintId::of(eval_order_dependence::EVAL_ORDER_DEPENDENCE), -LintId::of(float_equality_without_abs::FLOAT_EQUALITY_WITHOUT_ABS), -LintId::of(formatting::SUSPICIOUS_ASSIGNMENT_FORMATTING), -LintId::of(formatting::SUSPICIOUS_ELSE_FORMATTING), -LintId::of(formatting::SUSPICIOUS_UNARY_OP_FORMATTING), -LintId::of(loops::EMPTY_LOOP), -LintId::of(loops::FOR_LOOPS_OVER_FALLIBLES), -LintId::of(loops::MUT_RANGE_BOUND), -LintId::of(methods::SUSPICIOUS_MAP), -LintId::of(mut_key::MUTABLE_KEY_TYPE), -LintId::of(suspicious_trait_impl::SUSPICIOUS_ARITHMETIC_IMPL), -LintId::of(suspicious_trait_impl::SUSPICIOUS_OP_ASSIGN_IMPL), -]) \ No newline at end of file + LintId::of(assign_ops::MISREFACTORED_ASSIGN_OP), + LintId::of(attrs::BLANKET_CLIPPY_RESTRICTION_LINTS), + LintId::of(eval_order_dependence::EVAL_ORDER_DEPENDENCE), + LintId::of(float_equality_without_abs::FLOAT_EQUALITY_WITHOUT_ABS), + LintId::of(formatting::SUSPICIOUS_ASSIGNMENT_FORMATTING), + LintId::of(formatting::SUSPICIOUS_ELSE_FORMATTING), + LintId::of(formatting::SUSPICIOUS_UNARY_OP_FORMATTING), + LintId::of(loops::EMPTY_LOOP), + LintId::of(loops::FOR_LOOPS_OVER_FALLIBLES), + LintId::of(loops::MUT_RANGE_BOUND), + LintId::of(methods::SUSPICIOUS_MAP), + LintId::of(mut_key::MUTABLE_KEY_TYPE), + LintId::of(suspicious_trait_impl::SUSPICIOUS_ARITHMETIC_IMPL), + LintId::of(suspicious_trait_impl::SUSPICIOUS_OP_ASSIGN_IMPL), +]) -- cgit 1.4.1-3-g733a5 From 3f804ca6d3de8b9c42f55d33c0024f5437ecd6fa Mon Sep 17 00:00:00 2001 From: Michael Wright Date: Sat, 18 Sep 2021 06:43:39 +0200 Subject: Move `update_lints` specific code out of `lib` --- clippy_dev/src/lib.rs | 551 +--------------------------------------- clippy_dev/src/update_lints.rs | 554 ++++++++++++++++++++++++++++++++++++++++- 2 files changed, 551 insertions(+), 554 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lib.rs b/clippy_dev/src/lib.rs index 7dba808b418..5538f62c8e7 100644 --- a/clippy_dev/src/lib.rs +++ b/clippy_dev/src/lib.rs @@ -3,14 +3,7 @@ // warn on lints, that are included in `rust-lang/rust`s bootstrap #![warn(rust_2018_idioms, unused_lifetimes)] -use itertools::Itertools; -use regex::Regex; -use std::collections::{BTreeSet, HashMap}; -use std::ffi::OsStr; -use std::fs; -use std::lazy::SyncLazy; -use std::path::{Path, PathBuf}; -use walkdir::WalkDir; +use std::path::PathBuf; pub mod bless; pub mod fmt; @@ -19,339 +12,6 @@ pub mod serve; pub mod setup; pub mod update_lints; -const GENERATED_FILE_COMMENT: &str = "// This file was generated by `cargo dev update_lints`.\n\ - // Use that command to update this file and do not edit by hand.\n\ - // Manual edits will be overwritten.\n\n"; - -static DEC_CLIPPY_LINT_RE: SyncLazy = SyncLazy::new(|| { - Regex::new( - r#"(?x) - declare_clippy_lint!\s*[\{(] - (?:\s+///.*)* - \s+pub\s+(?P[A-Z_][A-Z_0-9]*)\s*,\s* - (?P[a-z_]+)\s*,\s* - "(?P(?:[^"\\]+|\\(?s).(?-s))*)"\s*[})] -"#, - ) - .unwrap() -}); - -static DEC_DEPRECATED_LINT_RE: SyncLazy = SyncLazy::new(|| { - Regex::new( - r#"(?x) - declare_deprecated_lint!\s*[{(]\s* - (?:\s+///.*)* - \s+pub\s+(?P[A-Z_][A-Z_0-9]*)\s*,\s* - "(?P(?:[^"\\]+|\\(?s).(?-s))*)"\s*[})] -"#, - ) - .unwrap() -}); -static NL_ESCAPE_RE: SyncLazy = SyncLazy::new(|| Regex::new(r#"\\\n\s*"#).unwrap()); - -pub static DOCS_LINK: &str = "https://rust-lang.github.io/rust-clippy/master/index.html"; - -/// Lint data parsed from the Clippy source code. -#[derive(Clone, PartialEq, Debug)] -pub struct Lint { - pub name: String, - pub group: String, - pub desc: String, - pub deprecation: Option, - pub module: String, -} - -impl Lint { - #[must_use] - pub fn new(name: &str, group: &str, desc: &str, deprecation: Option<&str>, module: &str) -> Self { - Self { - name: name.to_lowercase(), - group: group.to_string(), - desc: NL_ESCAPE_RE.replace(&desc.replace("\\\"", "\""), "").to_string(), - deprecation: deprecation.map(ToString::to_string), - module: module.to_string(), - } - } - - /// Returns all non-deprecated lints and non-internal lints - #[must_use] - pub fn usable_lints(lints: &[Self]) -> Vec { - lints - .iter() - .filter(|l| l.deprecation.is_none() && !l.group.starts_with("internal")) - .cloned() - .collect() - } - - /// Returns all internal lints (not `internal_warn` lints) - #[must_use] - pub fn internal_lints(lints: &[Self]) -> Vec { - lints.iter().filter(|l| l.group == "internal").cloned().collect() - } - - /// Returns all deprecated lints - #[must_use] - pub fn deprecated_lints(lints: &[Self]) -> Vec { - lints.iter().filter(|l| l.deprecation.is_some()).cloned().collect() - } - - /// Returns the lints in a `HashMap`, grouped by the different lint groups - #[must_use] - pub fn by_lint_group(lints: impl Iterator) -> HashMap> { - lints.map(|lint| (lint.group.to_string(), lint)).into_group_map() - } -} - -/// Generates the code for registering a group -pub fn gen_lint_group_list<'a>(group_name: &str, lints: impl Iterator) -> String { - let mut details: Vec<_> = lints.map(|l| (&l.module, l.name.to_uppercase())).collect(); - details.sort_unstable(); - - let mut output = GENERATED_FILE_COMMENT.to_string(); - - output.push_str(&format!( - "store.register_group(true, \"clippy::{0}\", Some(\"clippy_{0}\"), vec![\n", - group_name - )); - for (module, name) in details { - output.push_str(&format!(" LintId::of({}::{}),\n", module, name)); - } - output.push_str("])\n"); - - output -} - -/// Generates the module declarations for `lints` -#[must_use] -pub fn gen_modules_list<'a>(lints: impl Iterator) -> String { - let module_names: BTreeSet<_> = lints.map(|l| &l.module).collect(); - - let mut output = GENERATED_FILE_COMMENT.to_string(); - for name in module_names { - output.push_str(&format!("mod {};\n", name)); - } - output -} - -/// Generates the list of lint links at the bottom of the README -#[must_use] -pub fn gen_changelog_lint_list<'a>(lints: impl Iterator) -> Vec { - lints - .sorted_by_key(|l| &l.name) - .map(|l| format!("[`{}`]: {}#{}", l.name, DOCS_LINK, l.name)) - .collect() -} - -/// Generates the `register_removed` code -#[must_use] -pub fn gen_deprecated<'a>(lints: impl Iterator) -> String { - let mut output = GENERATED_FILE_COMMENT.to_string(); - output.push_str("{\n"); - for Lint { name, deprecation, .. } in lints { - output.push_str(&format!( - concat!( - " store.register_removed(\n", - " \"clippy::{}\",\n", - " \"{}\",\n", - " );\n" - ), - name, - deprecation.as_ref().expect("`lints` are deprecated") - )); - } - output.push_str("}\n"); - - output -} - -/// Generates the code for registering lints -#[must_use] -pub fn gen_register_lint_list<'a>( - internal_lints: impl Iterator, - usable_lints: impl Iterator, -) -> String { - let mut details: Vec<_> = internal_lints - .map(|l| (false, &l.module, l.name.to_uppercase())) - .chain(usable_lints.map(|l| (true, &l.module, l.name.to_uppercase()))) - .collect(); - details.sort_unstable(); - - let mut output = GENERATED_FILE_COMMENT.to_string(); - output.push_str("store.register_lints(&[\n"); - - for (is_public, module_name, lint_name) in details { - if !is_public { - output.push_str(" #[cfg(feature = \"internal-lints\")]\n"); - } - output.push_str(&format!(" {}::{},\n", module_name, lint_name)); - } - output.push_str("])\n"); - - output -} - -/// Gathers all files in `src/clippy_lints` and gathers all lints inside -pub fn gather_all() -> impl Iterator { - lint_files().flat_map(|f| gather_from_file(&f)) -} - -fn gather_from_file(dir_entry: &walkdir::DirEntry) -> impl Iterator { - let content = fs::read_to_string(dir_entry.path()).unwrap(); - let path = dir_entry.path(); - let filename = path.file_stem().unwrap(); - let path_buf = path.with_file_name(filename); - let mut rel_path = path_buf - .strip_prefix(clippy_project_root().join("clippy_lints/src")) - .expect("only files in `clippy_lints/src` should be looked at"); - // If the lints are stored in mod.rs, we get the module name from - // the containing directory: - if filename == "mod" { - rel_path = rel_path.parent().unwrap(); - } - - let module = rel_path - .components() - .map(|c| c.as_os_str().to_str().unwrap()) - .collect::>() - .join("::"); - - parse_contents(&content, &module) -} - -fn parse_contents(content: &str, module: &str) -> impl Iterator { - let lints = DEC_CLIPPY_LINT_RE - .captures_iter(content) - .map(|m| Lint::new(&m["name"], &m["cat"], &m["desc"], None, module)); - let deprecated = DEC_DEPRECATED_LINT_RE - .captures_iter(content) - .map(|m| Lint::new(&m["name"], "Deprecated", &m["desc"], Some(&m["desc"]), module)); - // Removing the `.collect::>().into_iter()` causes some lifetime issues due to the map - lints.chain(deprecated).collect::>().into_iter() -} - -/// Collects all .rs files in the `clippy_lints/src` directory -fn lint_files() -> impl Iterator { - // We use `WalkDir` instead of `fs::read_dir` here in order to recurse into subdirectories. - // Otherwise we would not collect all the lints, for example in `clippy_lints/src/methods/`. - let path = clippy_project_root().join("clippy_lints/src"); - WalkDir::new(path) - .into_iter() - .filter_map(Result::ok) - .filter(|f| f.path().extension() == Some(OsStr::new("rs"))) -} - -/// Whether a file has had its text changed or not -#[derive(PartialEq, Debug)] -pub struct FileChange { - pub changed: bool, - pub new_lines: String, -} - -/// Replaces a region in a file delimited by two lines matching regexes. -/// -/// `path` is the relative path to the file on which you want to perform the replacement. -/// -/// See `replace_region_in_text` for documentation of the other options. -/// -/// # Panics -/// -/// Panics if the path could not read or then written -pub fn replace_region_in_file( - path: &Path, - start: &str, - end: &str, - replace_start: bool, - write_back: bool, - replacements: F, -) -> FileChange -where - F: FnOnce() -> Vec, -{ - let contents = fs::read_to_string(path).unwrap_or_else(|e| panic!("Cannot read from {}: {}", path.display(), e)); - let file_change = replace_region_in_text(&contents, start, end, replace_start, replacements); - - if write_back { - if let Err(e) = fs::write(path, file_change.new_lines.as_bytes()) { - panic!("Cannot write to {}: {}", path.display(), e); - } - } - file_change -} - -/// Replaces a region in a text delimited by two lines matching regexes. -/// -/// * `text` is the input text on which you want to perform the replacement -/// * `start` is a `&str` that describes the delimiter line before the region you want to replace. -/// As the `&str` will be converted to a `Regex`, this can contain regex syntax, too. -/// * `end` is a `&str` that describes the delimiter line until where the replacement should happen. -/// As the `&str` will be converted to a `Regex`, this can contain regex syntax, too. -/// * If `replace_start` is true, the `start` delimiter line is replaced as well. The `end` -/// delimiter line is never replaced. -/// * `replacements` is a closure that has to return a `Vec` which contains the new text. -/// -/// If you want to perform the replacement on files instead of already parsed text, -/// use `replace_region_in_file`. -/// -/// # Example -/// -/// ``` -/// let the_text = "replace_start\nsome text\nthat will be replaced\nreplace_end"; -/// let result = -/// clippy_dev::replace_region_in_text(the_text, "replace_start", "replace_end", false, || { -/// vec!["a different".to_string(), "text".to_string()] -/// }) -/// .new_lines; -/// assert_eq!("replace_start\na different\ntext\nreplace_end", result); -/// ``` -/// -/// # Panics -/// -/// Panics if start or end is not valid regex -pub fn replace_region_in_text(text: &str, start: &str, end: &str, replace_start: bool, replacements: F) -> FileChange -where - F: FnOnce() -> Vec, -{ - let replace_it = replacements(); - let mut in_old_region = false; - let mut found = false; - let mut new_lines = vec![]; - let start = Regex::new(start).unwrap(); - let end = Regex::new(end).unwrap(); - - for line in text.lines() { - if in_old_region { - if end.is_match(line) { - in_old_region = false; - new_lines.extend(replace_it.clone()); - new_lines.push(line.to_string()); - } - } else if start.is_match(line) { - if !replace_start { - new_lines.push(line.to_string()); - } - in_old_region = true; - found = true; - } else { - new_lines.push(line.to_string()); - } - } - - if !found { - // This happens if the provided regex in `clippy_dev/src/main.rs` does not match in the - // given text or file. Most likely this is an error on the programmer's side and the Regex - // is incorrect. - eprintln!("error: regex \n{:?}\ndoesn't match. You may have to update it.", start); - std::process::exit(1); - } - - let mut new_lines = new_lines.join("\n"); - if text.ends_with('\n') { - new_lines.push('\n'); - } - let changed = new_lines != text; - FileChange { changed, new_lines } -} - /// Returns the path to the Clippy project directory /// /// # Panics @@ -376,212 +36,3 @@ pub fn clippy_project_root() -> PathBuf { } panic!("error: Can't determine root of project. Please run inside a Clippy working dir."); } - -#[test] -fn test_parse_contents() { - let result: Vec = parse_contents( - r#" -declare_clippy_lint! { - pub PTR_ARG, - style, - "really long \ - text" -} - -declare_clippy_lint!{ - pub DOC_MARKDOWN, - pedantic, - "single line" -} - -/// some doc comment -declare_deprecated_lint! { - pub SHOULD_ASSERT_EQ, - "`assert!()` will be more flexible with RFC 2011" -} - "#, - "module_name", - ) - .collect(); - - let expected = vec![ - Lint::new("ptr_arg", "style", "really long text", None, "module_name"), - Lint::new("doc_markdown", "pedantic", "single line", None, "module_name"), - Lint::new( - "should_assert_eq", - "Deprecated", - "`assert!()` will be more flexible with RFC 2011", - Some("`assert!()` will be more flexible with RFC 2011"), - "module_name", - ), - ]; - assert_eq!(expected, result); -} - -#[test] -fn test_replace_region() { - let text = "\nabc\n123\n789\ndef\nghi"; - let expected = FileChange { - changed: true, - new_lines: "\nabc\nhello world\ndef\nghi".to_string(), - }; - let result = replace_region_in_text(text, r#"^\s*abc$"#, r#"^\s*def"#, false, || { - vec!["hello world".to_string()] - }); - assert_eq!(expected, result); -} - -#[test] -fn test_replace_region_with_start() { - let text = "\nabc\n123\n789\ndef\nghi"; - let expected = FileChange { - changed: true, - new_lines: "\nhello world\ndef\nghi".to_string(), - }; - let result = replace_region_in_text(text, r#"^\s*abc$"#, r#"^\s*def"#, true, || { - vec!["hello world".to_string()] - }); - assert_eq!(expected, result); -} - -#[test] -fn test_replace_region_no_changes() { - let text = "123\n456\n789"; - let expected = FileChange { - changed: false, - new_lines: "123\n456\n789".to_string(), - }; - let result = replace_region_in_text(text, r#"^\s*123$"#, r#"^\s*456"#, false, Vec::new); - assert_eq!(expected, result); -} - -#[test] -fn test_usable_lints() { - let lints = vec![ - Lint::new("should_assert_eq", "Deprecated", "abc", Some("Reason"), "module_name"), - Lint::new("should_assert_eq2", "Not Deprecated", "abc", None, "module_name"), - Lint::new("should_assert_eq2", "internal", "abc", None, "module_name"), - Lint::new("should_assert_eq2", "internal_style", "abc", None, "module_name"), - ]; - let expected = vec![Lint::new( - "should_assert_eq2", - "Not Deprecated", - "abc", - None, - "module_name", - )]; - assert_eq!(expected, Lint::usable_lints(&lints)); -} - -#[test] -fn test_by_lint_group() { - let lints = vec![ - Lint::new("should_assert_eq", "group1", "abc", None, "module_name"), - Lint::new("should_assert_eq2", "group2", "abc", None, "module_name"), - Lint::new("incorrect_match", "group1", "abc", None, "module_name"), - ]; - let mut expected: HashMap> = HashMap::new(); - expected.insert( - "group1".to_string(), - vec![ - Lint::new("should_assert_eq", "group1", "abc", None, "module_name"), - Lint::new("incorrect_match", "group1", "abc", None, "module_name"), - ], - ); - expected.insert( - "group2".to_string(), - vec![Lint::new("should_assert_eq2", "group2", "abc", None, "module_name")], - ); - assert_eq!(expected, Lint::by_lint_group(lints.into_iter())); -} - -#[test] -fn test_gen_changelog_lint_list() { - let lints = vec![ - Lint::new("should_assert_eq", "group1", "abc", None, "module_name"), - Lint::new("should_assert_eq2", "group2", "abc", None, "module_name"), - ]; - let expected = vec![ - format!("[`should_assert_eq`]: {}#should_assert_eq", DOCS_LINK.to_string()), - format!("[`should_assert_eq2`]: {}#should_assert_eq2", DOCS_LINK.to_string()), - ]; - assert_eq!(expected, gen_changelog_lint_list(lints.iter())); -} - -#[test] -fn test_gen_deprecated() { - let lints = vec![ - Lint::new( - "should_assert_eq", - "group1", - "abc", - Some("has been superseded by should_assert_eq2"), - "module_name", - ), - Lint::new( - "another_deprecated", - "group2", - "abc", - Some("will be removed"), - "module_name", - ), - ]; - - let expected = GENERATED_FILE_COMMENT.to_string() - + &[ - "{", - " store.register_removed(", - " \"clippy::should_assert_eq\",", - " \"has been superseded by should_assert_eq2\",", - " );", - " store.register_removed(", - " \"clippy::another_deprecated\",", - " \"will be removed\",", - " );", - "}", - ] - .join("\n") - + "\n"; - - assert_eq!(expected, gen_deprecated(lints.iter())); -} - -#[test] -#[should_panic] -fn test_gen_deprecated_fail() { - let lints = vec![Lint::new("should_assert_eq2", "group2", "abc", None, "module_name")]; - let _deprecated_lints = gen_deprecated(lints.iter()); -} - -#[test] -fn test_gen_modules_list() { - let lints = vec![ - Lint::new("should_assert_eq", "group1", "abc", None, "module_name"), - Lint::new("incorrect_stuff", "group3", "abc", None, "another_module"), - ]; - let expected = GENERATED_FILE_COMMENT.to_string() + &["mod another_module;", "mod module_name;"].join("\n") + "\n"; - assert_eq!(expected, gen_modules_list(lints.iter())); -} - -#[test] -fn test_gen_lint_group_list() { - let lints = vec![ - Lint::new("abc", "group1", "abc", None, "module_name"), - Lint::new("should_assert_eq", "group1", "abc", None, "module_name"), - Lint::new("internal", "internal_style", "abc", None, "module_name"), - ]; - let expected = GENERATED_FILE_COMMENT.to_string() - + &[ - "store.register_group(true, \"clippy::group1\", Some(\"clippy_group1\"), vec![", - " LintId::of(module_name::ABC),", - " LintId::of(module_name::INTERNAL),", - " LintId::of(module_name::SHOULD_ASSERT_EQ),", - "])", - ] - .join("\n") - + "\n"; - - let result = gen_lint_group_list("group1", lints.iter()); - - assert_eq!(expected, result); -} diff --git a/clippy_dev/src/update_lints.rs b/clippy_dev/src/update_lints.rs index f393a8d1de1..f713f3c6da0 100644 --- a/clippy_dev/src/update_lints.rs +++ b/clippy_dev/src/update_lints.rs @@ -1,9 +1,45 @@ -use crate::{ - gather_all, gen_changelog_lint_list, gen_deprecated, gen_lint_group_list, gen_modules_list, gen_register_lint_list, - replace_region_in_file, Lint, DOCS_LINK, -}; +use itertools::Itertools; +use regex::Regex; +use std::collections::{BTreeSet, HashMap}; +use std::ffi::OsStr; use std::fs; +use std::lazy::SyncLazy; use std::path::Path; +use walkdir::WalkDir; + +use crate::clippy_project_root; + +const GENERATED_FILE_COMMENT: &str = "// This file was generated by `cargo dev update_lints`.\n\ + // Use that command to update this file and do not edit by hand.\n\ + // Manual edits will be overwritten.\n\n"; + +static DEC_CLIPPY_LINT_RE: SyncLazy = SyncLazy::new(|| { + Regex::new( + r#"(?x) + declare_clippy_lint!\s*[\{(] + (?:\s+///.*)* + \s+pub\s+(?P[A-Z_][A-Z_0-9]*)\s*,\s* + (?P[a-z_]+)\s*,\s* + "(?P(?:[^"\\]+|\\(?s).(?-s))*)"\s*[})] +"#, + ) + .unwrap() +}); + +static DEC_DEPRECATED_LINT_RE: SyncLazy = SyncLazy::new(|| { + Regex::new( + r#"(?x) + declare_deprecated_lint!\s*[{(]\s* + (?:\s+///.*)* + \s+pub\s+(?P[A-Z_][A-Z_0-9]*)\s*,\s* + "(?P(?:[^"\\]+|\\(?s).(?-s))*)"\s*[})] +"#, + ) + .unwrap() +}); +static NL_ESCAPE_RE: SyncLazy = SyncLazy::new(|| Regex::new(r#"\\\n\s*"#).unwrap()); + +static DOCS_LINK: &str = "https://rust-lang.github.io/rust-clippy/master/index.html"; #[derive(Clone, Copy, PartialEq)] pub enum UpdateMode { @@ -147,3 +183,513 @@ fn exit_with_failure() { ); std::process::exit(1); } + +/// Lint data parsed from the Clippy source code. +#[derive(Clone, PartialEq, Debug)] +struct Lint { + name: String, + group: String, + desc: String, + deprecation: Option, + module: String, +} + +impl Lint { + #[must_use] + fn new(name: &str, group: &str, desc: &str, deprecation: Option<&str>, module: &str) -> Self { + Self { + name: name.to_lowercase(), + group: group.to_string(), + desc: NL_ESCAPE_RE.replace(&desc.replace("\\\"", "\""), "").to_string(), + deprecation: deprecation.map(ToString::to_string), + module: module.to_string(), + } + } + + /// Returns all non-deprecated lints and non-internal lints + #[must_use] + fn usable_lints(lints: &[Self]) -> Vec { + lints + .iter() + .filter(|l| l.deprecation.is_none() && !l.group.starts_with("internal")) + .cloned() + .collect() + } + + /// Returns all internal lints (not `internal_warn` lints) + #[must_use] + fn internal_lints(lints: &[Self]) -> Vec { + lints.iter().filter(|l| l.group == "internal").cloned().collect() + } + + /// Returns all deprecated lints + #[must_use] + fn deprecated_lints(lints: &[Self]) -> Vec { + lints.iter().filter(|l| l.deprecation.is_some()).cloned().collect() + } + + /// Returns the lints in a `HashMap`, grouped by the different lint groups + #[must_use] + fn by_lint_group(lints: impl Iterator) -> HashMap> { + lints.map(|lint| (lint.group.to_string(), lint)).into_group_map() + } +} + +/// Generates the code for registering a group +fn gen_lint_group_list<'a>(group_name: &str, lints: impl Iterator) -> String { + let mut details: Vec<_> = lints.map(|l| (&l.module, l.name.to_uppercase())).collect(); + details.sort_unstable(); + + let mut output = GENERATED_FILE_COMMENT.to_string(); + + output.push_str(&format!( + "store.register_group(true, \"clippy::{0}\", Some(\"clippy_{0}\"), vec![\n", + group_name + )); + for (module, name) in details { + output.push_str(&format!(" LintId::of({}::{}),\n", module, name)); + } + output.push_str("])\n"); + + output +} + +/// Generates the module declarations for `lints` +#[must_use] +fn gen_modules_list<'a>(lints: impl Iterator) -> String { + let module_names: BTreeSet<_> = lints.map(|l| &l.module).collect(); + + let mut output = GENERATED_FILE_COMMENT.to_string(); + for name in module_names { + output.push_str(&format!("mod {};\n", name)); + } + output +} + +/// Generates the list of lint links at the bottom of the README +#[must_use] +fn gen_changelog_lint_list<'a>(lints: impl Iterator) -> Vec { + lints + .sorted_by_key(|l| &l.name) + .map(|l| format!("[`{}`]: {}#{}", l.name, DOCS_LINK, l.name)) + .collect() +} + +/// Generates the `register_removed` code +#[must_use] +fn gen_deprecated<'a>(lints: impl Iterator) -> String { + let mut output = GENERATED_FILE_COMMENT.to_string(); + output.push_str("{\n"); + for Lint { name, deprecation, .. } in lints { + output.push_str(&format!( + concat!( + " store.register_removed(\n", + " \"clippy::{}\",\n", + " \"{}\",\n", + " );\n" + ), + name, + deprecation.as_ref().expect("`lints` are deprecated") + )); + } + output.push_str("}\n"); + + output +} + +/// Generates the code for registering lints +#[must_use] +fn gen_register_lint_list<'a>( + internal_lints: impl Iterator, + usable_lints: impl Iterator, +) -> String { + let mut details: Vec<_> = internal_lints + .map(|l| (false, &l.module, l.name.to_uppercase())) + .chain(usable_lints.map(|l| (true, &l.module, l.name.to_uppercase()))) + .collect(); + details.sort_unstable(); + + let mut output = GENERATED_FILE_COMMENT.to_string(); + output.push_str("store.register_lints(&[\n"); + + for (is_public, module_name, lint_name) in details { + if !is_public { + output.push_str(" #[cfg(feature = \"internal-lints\")]\n"); + } + output.push_str(&format!(" {}::{},\n", module_name, lint_name)); + } + output.push_str("])\n"); + + output +} + +/// Gathers all files in `src/clippy_lints` and gathers all lints inside +fn gather_all() -> impl Iterator { + lint_files().flat_map(|f| gather_from_file(&f)) +} + +fn gather_from_file(dir_entry: &walkdir::DirEntry) -> impl Iterator { + let content = fs::read_to_string(dir_entry.path()).unwrap(); + let path = dir_entry.path(); + let filename = path.file_stem().unwrap(); + let path_buf = path.with_file_name(filename); + let mut rel_path = path_buf + .strip_prefix(clippy_project_root().join("clippy_lints/src")) + .expect("only files in `clippy_lints/src` should be looked at"); + // If the lints are stored in mod.rs, we get the module name from + // the containing directory: + if filename == "mod" { + rel_path = rel_path.parent().unwrap(); + } + + let module = rel_path + .components() + .map(|c| c.as_os_str().to_str().unwrap()) + .collect::>() + .join("::"); + + parse_contents(&content, &module) +} + +fn parse_contents(content: &str, module: &str) -> impl Iterator { + let lints = DEC_CLIPPY_LINT_RE + .captures_iter(content) + .map(|m| Lint::new(&m["name"], &m["cat"], &m["desc"], None, module)); + let deprecated = DEC_DEPRECATED_LINT_RE + .captures_iter(content) + .map(|m| Lint::new(&m["name"], "Deprecated", &m["desc"], Some(&m["desc"]), module)); + // Removing the `.collect::>().into_iter()` causes some lifetime issues due to the map + lints.chain(deprecated).collect::>().into_iter() +} + +/// Collects all .rs files in the `clippy_lints/src` directory +fn lint_files() -> impl Iterator { + // We use `WalkDir` instead of `fs::read_dir` here in order to recurse into subdirectories. + // Otherwise we would not collect all the lints, for example in `clippy_lints/src/methods/`. + let path = clippy_project_root().join("clippy_lints/src"); + WalkDir::new(path) + .into_iter() + .filter_map(Result::ok) + .filter(|f| f.path().extension() == Some(OsStr::new("rs"))) +} + +/// Whether a file has had its text changed or not +#[derive(PartialEq, Debug)] +struct FileChange { + changed: bool, + new_lines: String, +} + +/// Replaces a region in a file delimited by two lines matching regexes. +/// +/// `path` is the relative path to the file on which you want to perform the replacement. +/// +/// See `replace_region_in_text` for documentation of the other options. +/// +/// # Panics +/// +/// Panics if the path could not read or then written +fn replace_region_in_file( + path: &Path, + start: &str, + end: &str, + replace_start: bool, + write_back: bool, + replacements: F, +) -> FileChange +where + F: FnOnce() -> Vec, +{ + let contents = fs::read_to_string(path).unwrap_or_else(|e| panic!("Cannot read from {}: {}", path.display(), e)); + let file_change = replace_region_in_text(&contents, start, end, replace_start, replacements); + + if write_back { + if let Err(e) = fs::write(path, file_change.new_lines.as_bytes()) { + panic!("Cannot write to {}: {}", path.display(), e); + } + } + file_change +} + +/// Replaces a region in a text delimited by two lines matching regexes. +/// +/// * `text` is the input text on which you want to perform the replacement +/// * `start` is a `&str` that describes the delimiter line before the region you want to replace. +/// As the `&str` will be converted to a `Regex`, this can contain regex syntax, too. +/// * `end` is a `&str` that describes the delimiter line until where the replacement should happen. +/// As the `&str` will be converted to a `Regex`, this can contain regex syntax, too. +/// * If `replace_start` is true, the `start` delimiter line is replaced as well. The `end` +/// delimiter line is never replaced. +/// * `replacements` is a closure that has to return a `Vec` which contains the new text. +/// +/// If you want to perform the replacement on files instead of already parsed text, +/// use `replace_region_in_file`. +/// +/// # Example +/// +/// ```ignore +/// let the_text = "replace_start\nsome text\nthat will be replaced\nreplace_end"; +/// let result = +/// replace_region_in_text(the_text, "replace_start", "replace_end", false, || { +/// vec!["a different".to_string(), "text".to_string()] +/// }) +/// .new_lines; +/// assert_eq!("replace_start\na different\ntext\nreplace_end", result); +/// ``` +/// +/// # Panics +/// +/// Panics if start or end is not valid regex +fn replace_region_in_text(text: &str, start: &str, end: &str, replace_start: bool, replacements: F) -> FileChange +where + F: FnOnce() -> Vec, +{ + let replace_it = replacements(); + let mut in_old_region = false; + let mut found = false; + let mut new_lines = vec![]; + let start = Regex::new(start).unwrap(); + let end = Regex::new(end).unwrap(); + + for line in text.lines() { + if in_old_region { + if end.is_match(line) { + in_old_region = false; + new_lines.extend(replace_it.clone()); + new_lines.push(line.to_string()); + } + } else if start.is_match(line) { + if !replace_start { + new_lines.push(line.to_string()); + } + in_old_region = true; + found = true; + } else { + new_lines.push(line.to_string()); + } + } + + if !found { + // This happens if the provided regex in `clippy_dev/src/main.rs` does not match in the + // given text or file. Most likely this is an error on the programmer's side and the Regex + // is incorrect. + eprintln!("error: regex \n{:?}\ndoesn't match. You may have to update it.", start); + std::process::exit(1); + } + + let mut new_lines = new_lines.join("\n"); + if text.ends_with('\n') { + new_lines.push('\n'); + } + let changed = new_lines != text; + FileChange { changed, new_lines } +} + +#[test] +fn test_parse_contents() { + let result: Vec = parse_contents( + r#" +declare_clippy_lint! { + pub PTR_ARG, + style, + "really long \ + text" +} + +declare_clippy_lint!{ + pub DOC_MARKDOWN, + pedantic, + "single line" +} + +/// some doc comment +declare_deprecated_lint! { + pub SHOULD_ASSERT_EQ, + "`assert!()` will be more flexible with RFC 2011" +} + "#, + "module_name", + ) + .collect(); + + let expected = vec![ + Lint::new("ptr_arg", "style", "really long text", None, "module_name"), + Lint::new("doc_markdown", "pedantic", "single line", None, "module_name"), + Lint::new( + "should_assert_eq", + "Deprecated", + "`assert!()` will be more flexible with RFC 2011", + Some("`assert!()` will be more flexible with RFC 2011"), + "module_name", + ), + ]; + assert_eq!(expected, result); +} + +#[test] +fn test_replace_region() { + let text = "\nabc\n123\n789\ndef\nghi"; + let expected = FileChange { + changed: true, + new_lines: "\nabc\nhello world\ndef\nghi".to_string(), + }; + let result = replace_region_in_text(text, r#"^\s*abc$"#, r#"^\s*def"#, false, || { + vec!["hello world".to_string()] + }); + assert_eq!(expected, result); +} + +#[test] +fn test_replace_region_with_start() { + let text = "\nabc\n123\n789\ndef\nghi"; + let expected = FileChange { + changed: true, + new_lines: "\nhello world\ndef\nghi".to_string(), + }; + let result = replace_region_in_text(text, r#"^\s*abc$"#, r#"^\s*def"#, true, || { + vec!["hello world".to_string()] + }); + assert_eq!(expected, result); +} + +#[test] +fn test_replace_region_no_changes() { + let text = "123\n456\n789"; + let expected = FileChange { + changed: false, + new_lines: "123\n456\n789".to_string(), + }; + let result = replace_region_in_text(text, r#"^\s*123$"#, r#"^\s*456"#, false, Vec::new); + assert_eq!(expected, result); +} + +#[test] +fn test_usable_lints() { + let lints = vec![ + Lint::new("should_assert_eq", "Deprecated", "abc", Some("Reason"), "module_name"), + Lint::new("should_assert_eq2", "Not Deprecated", "abc", None, "module_name"), + Lint::new("should_assert_eq2", "internal", "abc", None, "module_name"), + Lint::new("should_assert_eq2", "internal_style", "abc", None, "module_name"), + ]; + let expected = vec![Lint::new( + "should_assert_eq2", + "Not Deprecated", + "abc", + None, + "module_name", + )]; + assert_eq!(expected, Lint::usable_lints(&lints)); +} + +#[test] +fn test_by_lint_group() { + let lints = vec![ + Lint::new("should_assert_eq", "group1", "abc", None, "module_name"), + Lint::new("should_assert_eq2", "group2", "abc", None, "module_name"), + Lint::new("incorrect_match", "group1", "abc", None, "module_name"), + ]; + let mut expected: HashMap> = HashMap::new(); + expected.insert( + "group1".to_string(), + vec![ + Lint::new("should_assert_eq", "group1", "abc", None, "module_name"), + Lint::new("incorrect_match", "group1", "abc", None, "module_name"), + ], + ); + expected.insert( + "group2".to_string(), + vec![Lint::new("should_assert_eq2", "group2", "abc", None, "module_name")], + ); + assert_eq!(expected, Lint::by_lint_group(lints.into_iter())); +} + +#[test] +fn test_gen_changelog_lint_list() { + let lints = vec![ + Lint::new("should_assert_eq", "group1", "abc", None, "module_name"), + Lint::new("should_assert_eq2", "group2", "abc", None, "module_name"), + ]; + let expected = vec![ + format!("[`should_assert_eq`]: {}#should_assert_eq", DOCS_LINK.to_string()), + format!("[`should_assert_eq2`]: {}#should_assert_eq2", DOCS_LINK.to_string()), + ]; + assert_eq!(expected, gen_changelog_lint_list(lints.iter())); +} + +#[test] +fn test_gen_deprecated() { + let lints = vec![ + Lint::new( + "should_assert_eq", + "group1", + "abc", + Some("has been superseded by should_assert_eq2"), + "module_name", + ), + Lint::new( + "another_deprecated", + "group2", + "abc", + Some("will be removed"), + "module_name", + ), + ]; + + let expected = GENERATED_FILE_COMMENT.to_string() + + &[ + "{", + " store.register_removed(", + " \"clippy::should_assert_eq\",", + " \"has been superseded by should_assert_eq2\",", + " );", + " store.register_removed(", + " \"clippy::another_deprecated\",", + " \"will be removed\",", + " );", + "}", + ] + .join("\n") + + "\n"; + + assert_eq!(expected, gen_deprecated(lints.iter())); +} + +#[test] +#[should_panic] +fn test_gen_deprecated_fail() { + let lints = vec![Lint::new("should_assert_eq2", "group2", "abc", None, "module_name")]; + let _deprecated_lints = gen_deprecated(lints.iter()); +} + +#[test] +fn test_gen_modules_list() { + let lints = vec![ + Lint::new("should_assert_eq", "group1", "abc", None, "module_name"), + Lint::new("incorrect_stuff", "group3", "abc", None, "another_module"), + ]; + let expected = GENERATED_FILE_COMMENT.to_string() + &["mod another_module;", "mod module_name;"].join("\n") + "\n"; + assert_eq!(expected, gen_modules_list(lints.iter())); +} + +#[test] +fn test_gen_lint_group_list() { + let lints = vec![ + Lint::new("abc", "group1", "abc", None, "module_name"), + Lint::new("should_assert_eq", "group1", "abc", None, "module_name"), + Lint::new("internal", "internal_style", "abc", None, "module_name"), + ]; + let expected = GENERATED_FILE_COMMENT.to_string() + + &[ + "store.register_group(true, \"clippy::group1\", Some(\"clippy_group1\"), vec![", + " LintId::of(module_name::ABC),", + " LintId::of(module_name::INTERNAL),", + " LintId::of(module_name::SHOULD_ASSERT_EQ),", + "])", + ] + .join("\n") + + "\n"; + + let result = gen_lint_group_list("group1", lints.iter()); + + assert_eq!(expected, result); +} -- cgit 1.4.1-3-g733a5 From 20abbd93f982de15e4cc7ab1e64505ca6dec1f43 Mon Sep 17 00:00:00 2001 From: Michael Wright Date: Sat, 18 Sep 2021 06:43:39 +0200 Subject: Add test module for `update_lints` --- clippy_dev/src/update_lints.rs | 316 +++++++++++++++++++++-------------------- 1 file changed, 161 insertions(+), 155 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/update_lints.rs b/clippy_dev/src/update_lints.rs index f713f3c6da0..edcdc04b68d 100644 --- a/clippy_dev/src/update_lints.rs +++ b/clippy_dev/src/update_lints.rs @@ -526,170 +526,176 @@ declare_deprecated_lint! { assert_eq!(expected, result); } -#[test] -fn test_replace_region() { - let text = "\nabc\n123\n789\ndef\nghi"; - let expected = FileChange { - changed: true, - new_lines: "\nabc\nhello world\ndef\nghi".to_string(), - }; - let result = replace_region_in_text(text, r#"^\s*abc$"#, r#"^\s*def"#, false, || { - vec!["hello world".to_string()] - }); - assert_eq!(expected, result); -} +#[cfg(test)] +mod tests { + use super::*; + + #[test] + fn test_replace_region() { + let text = "\nabc\n123\n789\ndef\nghi"; + let expected = FileChange { + changed: true, + new_lines: "\nabc\nhello world\ndef\nghi".to_string(), + }; + let result = replace_region_in_text(text, r#"^\s*abc$"#, r#"^\s*def"#, false, || { + vec!["hello world".to_string()] + }); + assert_eq!(expected, result); + } -#[test] -fn test_replace_region_with_start() { - let text = "\nabc\n123\n789\ndef\nghi"; - let expected = FileChange { - changed: true, - new_lines: "\nhello world\ndef\nghi".to_string(), - }; - let result = replace_region_in_text(text, r#"^\s*abc$"#, r#"^\s*def"#, true, || { - vec!["hello world".to_string()] - }); - assert_eq!(expected, result); -} + #[test] + fn test_replace_region_with_start() { + let text = "\nabc\n123\n789\ndef\nghi"; + let expected = FileChange { + changed: true, + new_lines: "\nhello world\ndef\nghi".to_string(), + }; + let result = replace_region_in_text(text, r#"^\s*abc$"#, r#"^\s*def"#, true, || { + vec!["hello world".to_string()] + }); + assert_eq!(expected, result); + } -#[test] -fn test_replace_region_no_changes() { - let text = "123\n456\n789"; - let expected = FileChange { - changed: false, - new_lines: "123\n456\n789".to_string(), - }; - let result = replace_region_in_text(text, r#"^\s*123$"#, r#"^\s*456"#, false, Vec::new); - assert_eq!(expected, result); -} + #[test] + fn test_replace_region_no_changes() { + let text = "123\n456\n789"; + let expected = FileChange { + changed: false, + new_lines: "123\n456\n789".to_string(), + }; + let result = replace_region_in_text(text, r#"^\s*123$"#, r#"^\s*456"#, false, Vec::new); + assert_eq!(expected, result); + } -#[test] -fn test_usable_lints() { - let lints = vec![ - Lint::new("should_assert_eq", "Deprecated", "abc", Some("Reason"), "module_name"), - Lint::new("should_assert_eq2", "Not Deprecated", "abc", None, "module_name"), - Lint::new("should_assert_eq2", "internal", "abc", None, "module_name"), - Lint::new("should_assert_eq2", "internal_style", "abc", None, "module_name"), - ]; - let expected = vec![Lint::new( - "should_assert_eq2", - "Not Deprecated", - "abc", - None, - "module_name", - )]; - assert_eq!(expected, Lint::usable_lints(&lints)); -} + #[test] + fn test_usable_lints() { + let lints = vec![ + Lint::new("should_assert_eq", "Deprecated", "abc", Some("Reason"), "module_name"), + Lint::new("should_assert_eq2", "Not Deprecated", "abc", None, "module_name"), + Lint::new("should_assert_eq2", "internal", "abc", None, "module_name"), + Lint::new("should_assert_eq2", "internal_style", "abc", None, "module_name"), + ]; + let expected = vec![Lint::new( + "should_assert_eq2", + "Not Deprecated", + "abc", + None, + "module_name", + )]; + assert_eq!(expected, Lint::usable_lints(&lints)); + } -#[test] -fn test_by_lint_group() { - let lints = vec![ - Lint::new("should_assert_eq", "group1", "abc", None, "module_name"), - Lint::new("should_assert_eq2", "group2", "abc", None, "module_name"), - Lint::new("incorrect_match", "group1", "abc", None, "module_name"), - ]; - let mut expected: HashMap> = HashMap::new(); - expected.insert( - "group1".to_string(), - vec![ + #[test] + fn test_by_lint_group() { + let lints = vec![ Lint::new("should_assert_eq", "group1", "abc", None, "module_name"), + Lint::new("should_assert_eq2", "group2", "abc", None, "module_name"), Lint::new("incorrect_match", "group1", "abc", None, "module_name"), - ], - ); - expected.insert( - "group2".to_string(), - vec![Lint::new("should_assert_eq2", "group2", "abc", None, "module_name")], - ); - assert_eq!(expected, Lint::by_lint_group(lints.into_iter())); -} - -#[test] -fn test_gen_changelog_lint_list() { - let lints = vec![ - Lint::new("should_assert_eq", "group1", "abc", None, "module_name"), - Lint::new("should_assert_eq2", "group2", "abc", None, "module_name"), - ]; - let expected = vec![ - format!("[`should_assert_eq`]: {}#should_assert_eq", DOCS_LINK.to_string()), - format!("[`should_assert_eq2`]: {}#should_assert_eq2", DOCS_LINK.to_string()), - ]; - assert_eq!(expected, gen_changelog_lint_list(lints.iter())); -} - -#[test] -fn test_gen_deprecated() { - let lints = vec![ - Lint::new( - "should_assert_eq", - "group1", - "abc", - Some("has been superseded by should_assert_eq2"), - "module_name", - ), - Lint::new( - "another_deprecated", - "group2", - "abc", - Some("will be removed"), - "module_name", - ), - ]; + ]; + let mut expected: HashMap> = HashMap::new(); + expected.insert( + "group1".to_string(), + vec![ + Lint::new("should_assert_eq", "group1", "abc", None, "module_name"), + Lint::new("incorrect_match", "group1", "abc", None, "module_name"), + ], + ); + expected.insert( + "group2".to_string(), + vec![Lint::new("should_assert_eq2", "group2", "abc", None, "module_name")], + ); + assert_eq!(expected, Lint::by_lint_group(lints.into_iter())); + } - let expected = GENERATED_FILE_COMMENT.to_string() - + &[ - "{", - " store.register_removed(", - " \"clippy::should_assert_eq\",", - " \"has been superseded by should_assert_eq2\",", - " );", - " store.register_removed(", - " \"clippy::another_deprecated\",", - " \"will be removed\",", - " );", - "}", - ] - .join("\n") - + "\n"; - - assert_eq!(expected, gen_deprecated(lints.iter())); -} + #[test] + fn test_gen_changelog_lint_list() { + let lints = vec![ + Lint::new("should_assert_eq", "group1", "abc", None, "module_name"), + Lint::new("should_assert_eq2", "group2", "abc", None, "module_name"), + ]; + let expected = vec![ + format!("[`should_assert_eq`]: {}#should_assert_eq", DOCS_LINK.to_string()), + format!("[`should_assert_eq2`]: {}#should_assert_eq2", DOCS_LINK.to_string()), + ]; + assert_eq!(expected, gen_changelog_lint_list(lints.iter())); + } -#[test] -#[should_panic] -fn test_gen_deprecated_fail() { - let lints = vec![Lint::new("should_assert_eq2", "group2", "abc", None, "module_name")]; - let _deprecated_lints = gen_deprecated(lints.iter()); -} + #[test] + fn test_gen_deprecated() { + let lints = vec![ + Lint::new( + "should_assert_eq", + "group1", + "abc", + Some("has been superseded by should_assert_eq2"), + "module_name", + ), + Lint::new( + "another_deprecated", + "group2", + "abc", + Some("will be removed"), + "module_name", + ), + ]; + + let expected = GENERATED_FILE_COMMENT.to_string() + + &[ + "{", + " store.register_removed(", + " \"clippy::should_assert_eq\",", + " \"has been superseded by should_assert_eq2\",", + " );", + " store.register_removed(", + " \"clippy::another_deprecated\",", + " \"will be removed\",", + " );", + "}", + ] + .join("\n") + + "\n"; + + assert_eq!(expected, gen_deprecated(lints.iter())); + } -#[test] -fn test_gen_modules_list() { - let lints = vec![ - Lint::new("should_assert_eq", "group1", "abc", None, "module_name"), - Lint::new("incorrect_stuff", "group3", "abc", None, "another_module"), - ]; - let expected = GENERATED_FILE_COMMENT.to_string() + &["mod another_module;", "mod module_name;"].join("\n") + "\n"; - assert_eq!(expected, gen_modules_list(lints.iter())); -} + #[test] + #[should_panic] + fn test_gen_deprecated_fail() { + let lints = vec![Lint::new("should_assert_eq2", "group2", "abc", None, "module_name")]; + let _deprecated_lints = gen_deprecated(lints.iter()); + } -#[test] -fn test_gen_lint_group_list() { - let lints = vec![ - Lint::new("abc", "group1", "abc", None, "module_name"), - Lint::new("should_assert_eq", "group1", "abc", None, "module_name"), - Lint::new("internal", "internal_style", "abc", None, "module_name"), - ]; - let expected = GENERATED_FILE_COMMENT.to_string() - + &[ - "store.register_group(true, \"clippy::group1\", Some(\"clippy_group1\"), vec![", - " LintId::of(module_name::ABC),", - " LintId::of(module_name::INTERNAL),", - " LintId::of(module_name::SHOULD_ASSERT_EQ),", - "])", - ] - .join("\n") - + "\n"; - - let result = gen_lint_group_list("group1", lints.iter()); + #[test] + fn test_gen_modules_list() { + let lints = vec![ + Lint::new("should_assert_eq", "group1", "abc", None, "module_name"), + Lint::new("incorrect_stuff", "group3", "abc", None, "another_module"), + ]; + let expected = + GENERATED_FILE_COMMENT.to_string() + &["mod another_module;", "mod module_name;"].join("\n") + "\n"; + assert_eq!(expected, gen_modules_list(lints.iter())); + } - assert_eq!(expected, result); + #[test] + fn test_gen_lint_group_list() { + let lints = vec![ + Lint::new("abc", "group1", "abc", None, "module_name"), + Lint::new("should_assert_eq", "group1", "abc", None, "module_name"), + Lint::new("internal", "internal_style", "abc", None, "module_name"), + ]; + let expected = GENERATED_FILE_COMMENT.to_string() + + &[ + "store.register_group(true, \"clippy::group1\", Some(\"clippy_group1\"), vec![", + " LintId::of(module_name::ABC),", + " LintId::of(module_name::INTERNAL),", + " LintId::of(module_name::SHOULD_ASSERT_EQ),", + "])", + ] + .join("\n") + + "\n"; + + let result = gen_lint_group_list("group1", lints.iter()); + + assert_eq!(expected, result); + } } -- cgit 1.4.1-3-g733a5 From debb1f027428eab9abbf4f962e3c1840492808b8 Mon Sep 17 00:00:00 2001 From: mikerite <33983332+mikerite@users.noreply.github.com> Date: Thu, 30 Sep 2021 05:11:39 +0200 Subject: Fix comment in `update_lints` Co-authored-by: Takayuki Nakata --- clippy_dev/src/update_lints.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/update_lints.rs b/clippy_dev/src/update_lints.rs index edcdc04b68d..1ab8ad9b920 100644 --- a/clippy_dev/src/update_lints.rs +++ b/clippy_dev/src/update_lints.rs @@ -266,7 +266,7 @@ fn gen_modules_list<'a>(lints: impl Iterator) -> String { output } -/// Generates the list of lint links at the bottom of the README +/// Generates the list of lint links at the bottom of the CHANGELOG #[must_use] fn gen_changelog_lint_list<'a>(lints: impl Iterator) -> Vec { lints -- cgit 1.4.1-3-g733a5 From 0e481b94520a0a084325f38e49b28904829e1759 Mon Sep 17 00:00:00 2001 From: Manish Goregaokar Date: Wed, 6 Oct 2021 00:12:38 -0700 Subject: Return to generating mod declarations in lib.rs --- clippy_dev/src/update_lints.rs | 16 +++++++++++----- 1 file changed, 11 insertions(+), 5 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/update_lints.rs b/clippy_dev/src/update_lints.rs index 1ab8ad9b920..6ec812909f2 100644 --- a/clippy_dev/src/update_lints.rs +++ b/clippy_dev/src/update_lints.rs @@ -98,6 +98,17 @@ pub fn run(update_mode: UpdateMode) { ) .changed; + // This has to be in lib.rs, otherwise rustfmt doesn't work + file_change |= replace_region_in_file( + Path::new("clippy_lints/src/lib.rs"), + "begin lints modules", + "end lints modules", + false, + update_mode == UpdateMode::Change, + || vec![gen_modules_list(usable_lints.iter())], + ) + .changed; + if file_change && update_mode == UpdateMode::Check { exit_with_failure(); } @@ -112,11 +123,6 @@ pub fn run(update_mode: UpdateMode) { update_mode, &gen_deprecated(deprecated_lints.iter()), ); - process_file( - "clippy_lints/src/lib.mods.rs", - update_mode, - &gen_modules_list(usable_lints.iter()), - ); let all_group_lints = usable_lints.iter().filter(|l| { matches!( -- cgit 1.4.1-3-g733a5 From 8f075ec961bea50074f96d48be851eccd94a065f Mon Sep 17 00:00:00 2001 From: Michael Wright Date: Thu, 7 Oct 2021 06:37:56 +0200 Subject: Revert `update_lints` module list generating code This commit reverts the module list generation code to what it was before the change to `include!` it and generates better output. --- clippy_dev/src/update_lints.rs | 22 ++++++++++------------ clippy_lints/src/lib.rs | 5 ----- 2 files changed, 10 insertions(+), 17 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/update_lints.rs b/clippy_dev/src/update_lints.rs index 6ec812909f2..10d859988f6 100644 --- a/clippy_dev/src/update_lints.rs +++ b/clippy_dev/src/update_lints.rs @@ -1,6 +1,6 @@ use itertools::Itertools; use regex::Regex; -use std::collections::{BTreeSet, HashMap}; +use std::collections::HashMap; use std::ffi::OsStr; use std::fs; use std::lazy::SyncLazy; @@ -105,7 +105,7 @@ pub fn run(update_mode: UpdateMode) { "end lints modules", false, update_mode == UpdateMode::Change, - || vec![gen_modules_list(usable_lints.iter())], + || gen_modules_list(usable_lints.iter()), ) .changed; @@ -262,14 +262,13 @@ fn gen_lint_group_list<'a>(group_name: &str, lints: impl Iterator(lints: impl Iterator) -> String { - let module_names: BTreeSet<_> = lints.map(|l| &l.module).collect(); - - let mut output = GENERATED_FILE_COMMENT.to_string(); - for name in module_names { - output.push_str(&format!("mod {};\n", name)); - } - output +fn gen_modules_list<'a>(lints: impl Iterator) -> Vec { + lints + .map(|l| &l.module) + .unique() + .map(|module| format!("mod {};", module)) + .sorted() + .collect::>() } /// Generates the list of lint links at the bottom of the CHANGELOG @@ -677,8 +676,7 @@ mod tests { Lint::new("should_assert_eq", "group1", "abc", None, "module_name"), Lint::new("incorrect_stuff", "group3", "abc", None, "another_module"), ]; - let expected = - GENERATED_FILE_COMMENT.to_string() + &["mod another_module;", "mod module_name;"].join("\n") + "\n"; + let expected = vec!["mod another_module;".to_string(), "mod module_name;".to_string()]; assert_eq!(expected, gen_modules_list(lints.iter())); } diff --git a/clippy_lints/src/lib.rs b/clippy_lints/src/lib.rs index c2376575cb8..9fc6a9e0ccc 100644 --- a/clippy_lints/src/lib.rs +++ b/clippy_lints/src/lib.rs @@ -156,10 +156,6 @@ mod deprecated_lints; mod utils; // begin lints modules, do not remove this comment, it’s used in `update_lints` -// This file was generated by `cargo dev update_lints`. -// Use that command to update this file and do not edit by hand. -// Manual edits will be overwritten. - mod absurd_extreme_comparisons; mod approx_const; mod arithmetic; @@ -390,7 +386,6 @@ mod wildcard_imports; mod write; mod zero_div_zero; mod zero_sized_map_values; - // end lints modules, do not remove this comment, it’s used in `update_lints` pub use crate::utils::conf::Conf; -- cgit 1.4.1-3-g733a5 From da76c06209451fa01d5248374869b689116ae05e Mon Sep 17 00:00:00 2001 From: Michael Wright Date: Sat, 9 Oct 2021 05:58:05 +0200 Subject: Add `--msrv` option to `new_lint` command --- clippy_dev/src/main.rs | 6 +++ clippy_dev/src/new_lint.rs | 108 ++++++++++++++++++++++++++++++++++++++------- 2 files changed, 98 insertions(+), 16 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index 8fdeba9842a..b5c04efce3b 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -28,6 +28,7 @@ fn main() { matches.value_of("pass"), matches.value_of("name"), matches.value_of("category"), + matches.is_present("msrv"), ) { Ok(_) => update_lints::run(update_lints::UpdateMode::Change), Err(e) => eprintln!("Unable to create lint: {}", e), @@ -147,6 +148,11 @@ fn get_clap_config<'a>() -> ArgMatches<'a> { "internal_warn", ]) .takes_value(true), + ) + .arg( + Arg::with_name("msrv") + .long("msrv") + .help("Add MSRV config code to the lint"), ), ) .subcommand( diff --git a/clippy_dev/src/new_lint.rs b/clippy_dev/src/new_lint.rs index 3a81aaba6de..ebbe26c46f7 100644 --- a/clippy_dev/src/new_lint.rs +++ b/clippy_dev/src/new_lint.rs @@ -32,7 +32,7 @@ impl Context for io::Result { /// # Errors /// /// This function errors out if the files couldn't be created or written to. -pub fn create(pass: Option<&str>, lint_name: Option<&str>, category: Option<&str>) -> io::Result<()> { +pub fn create(pass: Option<&str>, lint_name: Option<&str>, category: Option<&str>, msrv: bool) -> io::Result<()> { let lint = LintData { pass: pass.expect("`pass` argument is validated by clap"), name: lint_name.expect("`name` argument is validated by clap"), @@ -40,11 +40,11 @@ pub fn create(pass: Option<&str>, lint_name: Option<&str>, category: Option<&str project_root: clippy_project_root(), }; - create_lint(&lint).context("Unable to create lint implementation")?; + create_lint(&lint, msrv).context("Unable to create lint implementation")?; create_test(&lint).context("Unable to create a test for the new lint") } -fn create_lint(lint: &LintData<'_>) -> io::Result<()> { +fn create_lint(lint: &LintData<'_>, enable_msrv: bool) -> io::Result<()> { let (pass_type, pass_lifetimes, pass_import, context_import) = match lint.pass { "early" => ("EarlyLintPass", "", "use rustc_ast::ast::*;", "EarlyContext"), "late" => ("LateLintPass", "<'_>", "use rustc_hir::*;", "LateContext"), @@ -55,6 +55,7 @@ fn create_lint(lint: &LintData<'_>) -> io::Result<()> { let camel_case_name = to_camel_case(lint.name); let lint_contents = get_lint_file_contents( + lint.pass, pass_type, pass_lifetimes, lint.name, @@ -62,6 +63,7 @@ fn create_lint(lint: &LintData<'_>) -> io::Result<()> { lint.category, pass_import, context_import, + enable_msrv, ); let lint_path = format!("clippy_lints/src/{}.rs", lint.name); @@ -155,6 +157,7 @@ publish = false } fn get_lint_file_contents( + pass_name: &str, pass_type: &str, pass_lifetimes: &str, lint_name: &str, @@ -162,13 +165,41 @@ fn get_lint_file_contents( category: &str, pass_import: &str, context_import: &str, + enable_msrv: bool, ) -> String { - format!( - "use rustc_lint::{{{type}, {context_import}}}; -use rustc_session::{{declare_lint_pass, declare_tool_lint}}; + let mut result = String::new(); + + let name_camel = camel_case_name; + let name_upper = lint_name.to_uppercase(); + + result.push_str(&if enable_msrv { + format!( + "use clippy_utils::msrvs; {pass_import} +use rustc_lint::{{{context_import}, {pass_type}, LintContext}}; +use rustc_semver::RustcVersion; +use rustc_session::{{declare_tool_lint, impl_lint_pass}}; + +", + pass_type = pass_type, + pass_import = pass_import, + context_import = context_import, + ) + } else { + format!( + "{pass_import} +use rustc_lint::{{{context_import}, {pass_type}}}; +use rustc_session::{{declare_lint_pass, declare_tool_lint}}; + +", + pass_import = pass_import, + pass_type = pass_type, + context_import = context_import + ) + }); -declare_clippy_lint! {{ + result.push_str(&format!( + "declare_clippy_lint! {{ /// ### What it does /// /// ### Why is this bad? @@ -184,20 +215,65 @@ declare_clippy_lint! {{ pub {name_upper}, {category}, \"default lint description\" +}}", + name_upper = name_upper, + category = category, + )); + + result.push_str(&if enable_msrv { + format!( + " +pub struct {name_camel} {{ + msrv: Option, +}} + +impl {name_camel} {{ + #[must_use] + pub fn new(msrv: Option) -> Self {{ + Self {{ msrv }} + }} +}} + +impl_lint_pass!({name_camel} => [{name_upper}]); + +impl {pass_type}{pass_lifetimes} for {name_camel} {{ + extract_msrv_attr!({context_import}); }} +// TODO: Register the lint pass in `clippy_lints/src/lib.rs`, +// e.g. store.register_{pass_name}_pass(move || Box::new({module_name}::{name_camel}::new(msrv))); +// TODO: Add MSRV level to `clippy_utils/src/msrvs.rs` if needed. +// TODO: Add MSRV test to `tests/ui/min_rust_version_attr.rs`. +// TODO: Update msrv config comment in `clippy_lints/src/utils/conf.rs` +", + pass_type = pass_type, + pass_lifetimes = pass_lifetimes, + pass_name = pass_name, + name_upper = name_upper, + name_camel = name_camel, + module_name = lint_name, + context_import = context_import, + ) + } else { + format!( + " declare_lint_pass!({name_camel} => [{name_upper}]); -impl {type}{lifetimes} for {name_camel} {{}} +impl {pass_type}{pass_lifetimes} for {name_camel} {{}} +// +// TODO: Register the lint pass in `clippy_lints/src/lib.rs`, +// e.g. store.register_{pass_name}_pass(|| Box::new({module_name}::{name_camel})); ", - type=pass_type, - lifetimes=pass_lifetimes, - name_upper=lint_name.to_uppercase(), - name_camel=camel_case_name, - category=category, - pass_import=pass_import, - context_import=context_import - ) + pass_type = pass_type, + pass_lifetimes = pass_lifetimes, + pass_name = pass_name, + name_upper = name_upper, + name_camel = name_camel, + module_name = lint_name, + ) + }); + + result } #[test] -- cgit 1.4.1-3-g733a5 From b8782257ae54674101b08caeee59c0d51ff760c6 Mon Sep 17 00:00:00 2001 From: Michael Wright Date: Sat, 9 Oct 2021 05:58:05 +0200 Subject: Fix `clippy::too-many-arguments` violation --- clippy_dev/src/new_lint.rs | 46 ++++++++++++++-------------------------------- 1 file changed, 14 insertions(+), 32 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/new_lint.rs b/clippy_dev/src/new_lint.rs index ebbe26c46f7..50297efde21 100644 --- a/clippy_dev/src/new_lint.rs +++ b/clippy_dev/src/new_lint.rs @@ -45,26 +45,7 @@ pub fn create(pass: Option<&str>, lint_name: Option<&str>, category: Option<&str } fn create_lint(lint: &LintData<'_>, enable_msrv: bool) -> io::Result<()> { - let (pass_type, pass_lifetimes, pass_import, context_import) = match lint.pass { - "early" => ("EarlyLintPass", "", "use rustc_ast::ast::*;", "EarlyContext"), - "late" => ("LateLintPass", "<'_>", "use rustc_hir::*;", "LateContext"), - _ => { - unreachable!("`pass_type` should only ever be `early` or `late`!"); - }, - }; - - let camel_case_name = to_camel_case(lint.name); - let lint_contents = get_lint_file_contents( - lint.pass, - pass_type, - pass_lifetimes, - lint.name, - &camel_case_name, - lint.category, - pass_import, - context_import, - enable_msrv, - ); + let lint_contents = get_lint_file_contents(lint, enable_msrv); let lint_path = format!("clippy_lints/src/{}.rs", lint.name); write_file(lint.project_root.join(&lint_path), lint_contents.as_bytes()) @@ -156,20 +137,21 @@ publish = false ) } -fn get_lint_file_contents( - pass_name: &str, - pass_type: &str, - pass_lifetimes: &str, - lint_name: &str, - camel_case_name: &str, - category: &str, - pass_import: &str, - context_import: &str, - enable_msrv: bool, -) -> String { +fn get_lint_file_contents(lint: &LintData<'_>, enable_msrv: bool) -> String { let mut result = String::new(); - let name_camel = camel_case_name; + let (pass_type, pass_lifetimes, pass_import, context_import) = match lint.pass { + "early" => ("EarlyLintPass", "", "use rustc_ast::ast::*;", "EarlyContext"), + "late" => ("LateLintPass", "<'_>", "use rustc_hir::*;", "LateContext"), + _ => { + unreachable!("`pass_type` should only ever be `early` or `late`!"); + }, + }; + + let lint_name = lint.name; + let pass_name = lint.pass; + let category = lint.category; + let name_camel = to_camel_case(lint.name); let name_upper = lint_name.to_uppercase(); result.push_str(&if enable_msrv { -- cgit 1.4.1-3-g733a5 From 7d9b21b90bc77ab26c8afefc78d6087aff34e4ad Mon Sep 17 00:00:00 2001 From: Michael Wright Date: Sat, 9 Oct 2021 05:58:05 +0200 Subject: Use `indoc` for formatting --- clippy_dev/Cargo.toml | 1 + clippy_dev/src/new_lint.rs | 152 +++++++++++++++++++++++---------------------- 2 files changed, 80 insertions(+), 73 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/Cargo.toml b/clippy_dev/Cargo.toml index 4a13a452409..affb283017c 100644 --- a/clippy_dev/Cargo.toml +++ b/clippy_dev/Cargo.toml @@ -6,6 +6,7 @@ edition = "2021" [dependencies] bytecount = "0.6" clap = "2.33" +indoc = "1.0" itertools = "0.10" opener = "0.5" regex = "1.5" diff --git a/clippy_dev/src/new_lint.rs b/clippy_dev/src/new_lint.rs index 50297efde21..25320907bb4 100644 --- a/clippy_dev/src/new_lint.rs +++ b/clippy_dev/src/new_lint.rs @@ -1,4 +1,5 @@ use crate::clippy_project_root; +use indoc::indoc; use std::fs::{self, OpenOptions}; use std::io::prelude::*; use std::io::{self, ErrorKind}; @@ -105,12 +106,13 @@ fn to_camel_case(name: &str) -> String { fn get_test_file_contents(lint_name: &str, header_commands: Option<&str>) -> String { let mut contents = format!( - "#![warn(clippy::{})] + indoc! {" + #![warn(clippy::{})] -fn main() {{ - // test code goes here -}} -", + fn main() {{ + // test code goes here + }} + "}, lint_name ); @@ -123,16 +125,16 @@ fn main() {{ fn get_manifest_contents(lint_name: &str, hint: &str) -> String { format!( - r#" -# {} + indoc! {r#" + # {} -[package] -name = "{}" -version = "0.1.0" -publish = false + [package] + name = "{}" + version = "0.1.0" + publish = false -[workspace] -"#, + [workspace] + "#}, hint, lint_name ) } @@ -156,24 +158,26 @@ fn get_lint_file_contents(lint: &LintData<'_>, enable_msrv: bool) -> String { result.push_str(&if enable_msrv { format!( - "use clippy_utils::msrvs; -{pass_import} -use rustc_lint::{{{context_import}, {pass_type}, LintContext}}; -use rustc_semver::RustcVersion; -use rustc_session::{{declare_tool_lint, impl_lint_pass}}; - -", + indoc! {" + use clippy_utils::msrvs; + {pass_import} + use rustc_lint::{{{context_import}, {pass_type}, LintContext}}; + use rustc_semver::RustcVersion; + use rustc_session::{{declare_tool_lint, impl_lint_pass}}; + + "}, pass_type = pass_type, pass_import = pass_import, context_import = context_import, ) } else { format!( - "{pass_import} -use rustc_lint::{{{context_import}, {pass_type}}}; -use rustc_session::{{declare_lint_pass, declare_tool_lint}}; + indoc! {" + {pass_import} + use rustc_lint::{{{context_import}, {pass_type}}}; + use rustc_session::{{declare_lint_pass, declare_tool_lint}}; -", + "}, pass_import = pass_import, pass_type = pass_type, context_import = context_import @@ -181,53 +185,55 @@ use rustc_session::{{declare_lint_pass, declare_tool_lint}}; }); result.push_str(&format!( - "declare_clippy_lint! {{ - /// ### What it does - /// - /// ### Why is this bad? - /// - /// ### Example - /// ```rust - /// // example code where clippy issues a warning - /// ``` - /// Use instead: - /// ```rust - /// // example code which does not raise clippy warning - /// ``` - pub {name_upper}, - {category}, - \"default lint description\" -}}", + indoc! {" + declare_clippy_lint! {{ + /// ### What it does + /// + /// ### Why is this bad? + /// + /// ### Example + /// ```rust + /// // example code where clippy issues a warning + /// ``` + /// Use instead: + /// ```rust + /// // example code which does not raise clippy warning + /// ``` + pub {name_upper}, + {category}, + \"default lint description\" + }} + "}, name_upper = name_upper, category = category, )); result.push_str(&if enable_msrv { format!( - " -pub struct {name_camel} {{ - msrv: Option, -}} - -impl {name_camel} {{ - #[must_use] - pub fn new(msrv: Option) -> Self {{ - Self {{ msrv }} - }} -}} - -impl_lint_pass!({name_camel} => [{name_upper}]); - -impl {pass_type}{pass_lifetimes} for {name_camel} {{ - extract_msrv_attr!({context_import}); -}} - -// TODO: Register the lint pass in `clippy_lints/src/lib.rs`, -// e.g. store.register_{pass_name}_pass(move || Box::new({module_name}::{name_camel}::new(msrv))); -// TODO: Add MSRV level to `clippy_utils/src/msrvs.rs` if needed. -// TODO: Add MSRV test to `tests/ui/min_rust_version_attr.rs`. -// TODO: Update msrv config comment in `clippy_lints/src/utils/conf.rs` -", + indoc! {" + pub struct {name_camel} {{ + msrv: Option, + }} + + impl {name_camel} {{ + #[must_use] + pub fn new(msrv: Option) -> Self {{ + Self {{ msrv }} + }} + }} + + impl_lint_pass!({name_camel} => [{name_upper}]); + + impl {pass_type}{pass_lifetimes} for {name_camel} {{ + extract_msrv_attr!({context_import}); + }} + + // TODO: Register the lint pass in `clippy_lints/src/lib.rs`, + // e.g. store.register_{pass_name}_pass(move || Box::new({module_name}::{name_camel}::new(msrv))); + // TODO: Add MSRV level to `clippy_utils/src/msrvs.rs` if needed. + // TODO: Add MSRV test to `tests/ui/min_rust_version_attr.rs`. + // TODO: Update msrv config comment in `clippy_lints/src/utils/conf.rs` + "}, pass_type = pass_type, pass_lifetimes = pass_lifetimes, pass_name = pass_name, @@ -238,14 +244,14 @@ impl {pass_type}{pass_lifetimes} for {name_camel} {{ ) } else { format!( - " -declare_lint_pass!({name_camel} => [{name_upper}]); - -impl {pass_type}{pass_lifetimes} for {name_camel} {{}} -// -// TODO: Register the lint pass in `clippy_lints/src/lib.rs`, -// e.g. store.register_{pass_name}_pass(|| Box::new({module_name}::{name_camel})); -", + indoc! {" + declare_lint_pass!({name_camel} => [{name_upper}]); + + impl {pass_type}{pass_lifetimes} for {name_camel} {{}} + // + // TODO: Register the lint pass in `clippy_lints/src/lib.rs`, + // e.g. store.register_{pass_name}_pass(|| Box::new({module_name}::{name_camel})); + "}, pass_type = pass_type, pass_lifetimes = pass_lifetimes, pass_name = pass_name, -- cgit 1.4.1-3-g733a5 From 75e9f8cbd6d8c704ec89d12e3ddc382402a13119 Mon Sep 17 00:00:00 2001 From: "Samuel E. Moelius III" Date: Thu, 30 Sep 2021 07:38:03 -0400 Subject: Remove redundant `to_string`s --- clippy_dev/src/update_lints.rs | 4 ++-- clippy_lints/src/if_then_panic.rs | 4 ++-- clippy_lints/src/inherent_to_string.rs | 8 ++++---- clippy_lints/src/suspicious_operation_groupings.rs | 2 +- clippy_lints/src/transmute/transmute_int_to_char.rs | 2 +- clippy_lints/src/transmute/transmute_int_to_float.rs | 2 +- clippy_lints/src/transmute/transmute_num_to_bytes.rs | 2 +- 7 files changed, 12 insertions(+), 12 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/update_lints.rs b/clippy_dev/src/update_lints.rs index 10d859988f6..23f58bc4915 100644 --- a/clippy_dev/src/update_lints.rs +++ b/clippy_dev/src/update_lints.rs @@ -619,8 +619,8 @@ mod tests { Lint::new("should_assert_eq2", "group2", "abc", None, "module_name"), ]; let expected = vec![ - format!("[`should_assert_eq`]: {}#should_assert_eq", DOCS_LINK.to_string()), - format!("[`should_assert_eq2`]: {}#should_assert_eq2", DOCS_LINK.to_string()), + format!("[`should_assert_eq`]: {}#should_assert_eq", DOCS_LINK), + format!("[`should_assert_eq2`]: {}#should_assert_eq2", DOCS_LINK), ]; assert_eq!(expected, gen_changelog_lint_list(lints.iter())); } diff --git a/clippy_lints/src/if_then_panic.rs b/clippy_lints/src/if_then_panic.rs index 10bca59e6d0..e8cea5529e8 100644 --- a/clippy_lints/src/if_then_panic.rs +++ b/clippy_lints/src/if_then_panic.rs @@ -78,10 +78,10 @@ impl LateLintPass<'_> for IfThenPanic { if let Expr{kind: ExprKind::Unary(UnOp::Not, not_expr), ..} = e { sugg::Sugg::hir_with_applicability(cx, not_expr, "..", &mut applicability).maybe_par().to_string() } else { - format!("!{}", sugg::Sugg::hir_with_applicability(cx, e, "..", &mut applicability).maybe_par().to_string()) + format!("!{}", sugg::Sugg::hir_with_applicability(cx, e, "..", &mut applicability).maybe_par()) } } else { - format!("!{}", sugg::Sugg::hir_with_applicability(cx, cond, "..", &mut applicability).maybe_par().to_string()) + format!("!{}", sugg::Sugg::hir_with_applicability(cx, cond, "..", &mut applicability).maybe_par()) }; span_lint_and_sugg( diff --git a/clippy_lints/src/inherent_to_string.rs b/clippy_lints/src/inherent_to_string.rs index 3c40ca50a09..61dd0eb4af7 100644 --- a/clippy_lints/src/inherent_to_string.rs +++ b/clippy_lints/src/inherent_to_string.rs @@ -138,10 +138,10 @@ fn show_lint(cx: &LateContext<'_>, item: &ImplItem<'_>) { item.span, &format!( "type `{}` implements inherent method `to_string(&self) -> String` which shadows the implementation of `Display`", - self_type.to_string() + self_type ), None, - &format!("remove the inherent method from type `{}`", self_type.to_string()), + &format!("remove the inherent method from type `{}`", self_type), ); } else { span_lint_and_help( @@ -150,10 +150,10 @@ fn show_lint(cx: &LateContext<'_>, item: &ImplItem<'_>) { item.span, &format!( "implementation of inherent method `to_string(&self) -> String` for type `{}`", - self_type.to_string() + self_type ), None, - &format!("implement trait `Display` for type `{}` instead", self_type.to_string()), + &format!("implement trait `Display` for type `{}` instead", self_type), ); } } diff --git a/clippy_lints/src/suspicious_operation_groupings.rs b/clippy_lints/src/suspicious_operation_groupings.rs index 44d5ff0b63a..201aa067824 100644 --- a/clippy_lints/src/suspicious_operation_groupings.rs +++ b/clippy_lints/src/suspicious_operation_groupings.rs @@ -678,7 +678,7 @@ fn suggestion_with_swapped_ident( Some(format!( "{}{}{}", snippet_with_applicability(cx, expr.span.with_hi(current_ident.span.lo()), "..", applicability), - new_ident.to_string(), + new_ident, snippet_with_applicability(cx, expr.span.with_lo(current_ident.span.hi()), "..", applicability), )) }) diff --git a/clippy_lints/src/transmute/transmute_int_to_char.rs b/clippy_lints/src/transmute/transmute_int_to_char.rs index 8f884e6a4a1..e83d2e06b9a 100644 --- a/clippy_lints/src/transmute/transmute_int_to_char.rs +++ b/clippy_lints/src/transmute/transmute_int_to_char.rs @@ -33,7 +33,7 @@ pub(super) fn check<'tcx>( diag.span_suggestion( e.span, "consider using", - format!("std::char::from_u32({}).unwrap()", arg.to_string()), + format!("std::char::from_u32({}).unwrap()", arg), Applicability::Unspecified, ); }, diff --git a/clippy_lints/src/transmute/transmute_int_to_float.rs b/clippy_lints/src/transmute/transmute_int_to_float.rs index 2b6a4cff81e..05eee380d6f 100644 --- a/clippy_lints/src/transmute/transmute_int_to_float.rs +++ b/clippy_lints/src/transmute/transmute_int_to_float.rs @@ -36,7 +36,7 @@ pub(super) fn check<'tcx>( diag.span_suggestion( e.span, "consider using", - format!("{}::from_bits({})", to_ty, arg.to_string()), + format!("{}::from_bits({})", to_ty, arg), Applicability::Unspecified, ); }, diff --git a/clippy_lints/src/transmute/transmute_num_to_bytes.rs b/clippy_lints/src/transmute/transmute_num_to_bytes.rs index dd5ded1c91a..5ba58a76494 100644 --- a/clippy_lints/src/transmute/transmute_num_to_bytes.rs +++ b/clippy_lints/src/transmute/transmute_num_to_bytes.rs @@ -37,7 +37,7 @@ pub(super) fn check<'tcx>( diag.span_suggestion( e.span, "consider using `to_ne_bytes()`", - format!("{}.to_ne_bytes()", arg.to_string()), + format!("{}.to_ne_bytes()", arg), Applicability::Unspecified, ); }, -- cgit 1.4.1-3-g733a5 From bd778e216d3c58049fe0259ce5c8e8fd45cfcbd6 Mon Sep 17 00:00:00 2001 From: Alex Macleod Date: Mon, 25 Oct 2021 18:14:54 +0100 Subject: Register the generated lints from `cargo dev new_lint` --- clippy_dev/src/new_lint.rs | 40 +++++++++++++++++++++++++++++----------- clippy_lints/src/lib.rs | 2 +- doc/adding_lints.md | 45 ++++++++++++++++++++++++--------------------- 3 files changed, 54 insertions(+), 33 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/new_lint.rs b/clippy_dev/src/new_lint.rs index 25320907bb4..43a478ee77d 100644 --- a/clippy_dev/src/new_lint.rs +++ b/clippy_dev/src/new_lint.rs @@ -42,7 +42,8 @@ pub fn create(pass: Option<&str>, lint_name: Option<&str>, category: Option<&str }; create_lint(&lint, msrv).context("Unable to create lint implementation")?; - create_test(&lint).context("Unable to create a test for the new lint") + create_test(&lint).context("Unable to create a test for the new lint")?; + add_lint(&lint, msrv).context("Unable to add lint to clippy_lints/src/lib.rs") } fn create_lint(lint: &LintData<'_>, enable_msrv: bool) -> io::Result<()> { @@ -80,6 +81,33 @@ fn create_test(lint: &LintData<'_>) -> io::Result<()> { } } +fn add_lint(lint: &LintData<'_>, enable_msrv: bool) -> io::Result<()> { + let path = "clippy_lints/src/lib.rs"; + let mut lib_rs = fs::read_to_string(path).context("reading")?; + + let comment_start = lib_rs.find("// add lints here,").expect("Couldn't find comment"); + + let new_lint = if enable_msrv { + format!( + "store.register_{lint_pass}_pass(move || Box::new({module_name}::{camel_name}::new(msrv)));\n ", + lint_pass = lint.pass, + module_name = lint.name, + camel_name = to_camel_case(lint.name), + ) + } else { + format!( + "store.register_{lint_pass}_pass(|| Box::new({module_name}::{camel_name}));\n ", + lint_pass = lint.pass, + module_name = lint.name, + camel_name = to_camel_case(lint.name), + ) + }; + + lib_rs.insert_str(comment_start, &new_lint); + + fs::write(path, lib_rs).context("writing") +} + fn write_file, C: AsRef<[u8]>>(path: P, contents: C) -> io::Result<()> { fn inner(path: &Path, contents: &[u8]) -> io::Result<()> { OpenOptions::new() @@ -151,7 +179,6 @@ fn get_lint_file_contents(lint: &LintData<'_>, enable_msrv: bool) -> String { }; let lint_name = lint.name; - let pass_name = lint.pass; let category = lint.category; let name_camel = to_camel_case(lint.name); let name_upper = lint_name.to_uppercase(); @@ -228,18 +255,14 @@ fn get_lint_file_contents(lint: &LintData<'_>, enable_msrv: bool) -> String { extract_msrv_attr!({context_import}); }} - // TODO: Register the lint pass in `clippy_lints/src/lib.rs`, - // e.g. store.register_{pass_name}_pass(move || Box::new({module_name}::{name_camel}::new(msrv))); // TODO: Add MSRV level to `clippy_utils/src/msrvs.rs` if needed. // TODO: Add MSRV test to `tests/ui/min_rust_version_attr.rs`. // TODO: Update msrv config comment in `clippy_lints/src/utils/conf.rs` "}, pass_type = pass_type, pass_lifetimes = pass_lifetimes, - pass_name = pass_name, name_upper = name_upper, name_camel = name_camel, - module_name = lint_name, context_import = context_import, ) } else { @@ -248,16 +271,11 @@ fn get_lint_file_contents(lint: &LintData<'_>, enable_msrv: bool) -> String { declare_lint_pass!({name_camel} => [{name_upper}]); impl {pass_type}{pass_lifetimes} for {name_camel} {{}} - // - // TODO: Register the lint pass in `clippy_lints/src/lib.rs`, - // e.g. store.register_{pass_name}_pass(|| Box::new({module_name}::{name_camel})); "}, pass_type = pass_type, pass_lifetimes = pass_lifetimes, - pass_name = pass_name, name_upper = name_upper, name_camel = name_camel, - module_name = lint_name, ) }); diff --git a/clippy_lints/src/lib.rs b/clippy_lints/src/lib.rs index ed7e8277023..86f9d75c06f 100644 --- a/clippy_lints/src/lib.rs +++ b/clippy_lints/src/lib.rs @@ -777,7 +777,7 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf: store.register_late_pass(|| Box::new(match_str_case_mismatch::MatchStrCaseMismatch)); store.register_late_pass(move || Box::new(format_args::FormatArgs)); store.register_late_pass(|| Box::new(trailing_empty_array::TrailingEmptyArray)); - + // add lints here, do not remove this comment, it's used in `new_lint` } #[rustfmt::skip] diff --git a/doc/adding_lints.md b/doc/adding_lints.md index 004eb28b446..0e112e37cbc 100644 --- a/doc/adding_lints.md +++ b/doc/adding_lints.md @@ -16,6 +16,7 @@ because that's clearly a non-descriptive name. - [Edition 2018 tests](#edition-2018-tests) - [Testing manually](#testing-manually) - [Lint declaration](#lint-declaration) + - [Lint registration](#lint-registration) - [Lint passes](#lint-passes) - [Emitting a lint](#emitting-a-lint) - [Adding the lint logic](#adding-the-lint-logic) @@ -43,9 +44,9 @@ take a look at our [lint naming guidelines][lint_naming]. To get started on this lint you can run `cargo dev new_lint --name=foo_functions --pass=early --category=pedantic` (category will default to nursery if not provided). This command will create two files: `tests/ui/foo_functions.rs` and -`clippy_lints/src/foo_functions.rs`, as well as run `cargo dev update_lints` to -register the new lint. For cargo lints, two project hierarchies (fail/pass) will -be created by default under `tests/ui-cargo`. +`clippy_lints/src/foo_functions.rs`, as well as +[registering the lint](#lint-registration). For cargo lints, two project +hierarchies (fail/pass) will be created by default under `tests/ui-cargo`. Next, we'll open up these files and add our lint! @@ -220,32 +221,34 @@ declare_lint_pass!(FooFunctions => [FOO_FUNCTIONS]); impl EarlyLintPass for FooFunctions {} ``` -Normally after declaring the lint, we have to run `cargo dev update_lints`, -which updates some files, so Clippy knows about the new lint. Since we used -`cargo dev new_lint ...` to generate the lint declaration, this was done -automatically. While `update_lints` automates most of the things, it doesn't -automate everything. We will have to register our lint pass manually in the -`register_plugins` function in `clippy_lints/src/lib.rs`: +[declare_clippy_lint]: https://github.com/rust-lang/rust-clippy/blob/557f6848bd5b7183f55c1e1522a326e9e1df6030/clippy_lints/src/lib.rs#L60 +[example_lint_page]: https://rust-lang.github.io/rust-clippy/master/index.html#redundant_closure +[lint_naming]: https://rust-lang.github.io/rfcs/0344-conventions-galore.html#lints +[category_level_mapping]: https://github.com/rust-lang/rust-clippy/blob/557f6848bd5b7183f55c1e1522a326e9e1df6030/clippy_lints/src/lib.rs#L110 + +## Lint registration + +When using `cargo dev new_lint`, the lint is automatically registered and +nothing more has to be done. + +When declaring a new lint by hand and `cargo dev update_lints` is used, the lint +pass may have to be registered manually in the `register_plugins` function in +`clippy_lints/src/lib.rs`: ```rust -store.register_early_pass(|| box foo_functions::FooFunctions); +store.register_early_pass(|| Box::new(foo_functions::FooFunctions)); ``` As one may expect, there is a corresponding `register_late_pass` method available as well. Without a call to one of `register_early_pass` or `register_late_pass`, the lint pass in question will not be run. -One reason that `cargo dev` does not automate this step is that multiple lints -can use the same lint pass, so registering the lint pass may already be done -when adding a new lint. Another reason that this step is not automated is that -the order that the passes are registered determines the order the passes -actually run, which in turn affects the order that any emitted lints are output -in. - -[declare_clippy_lint]: https://github.com/rust-lang/rust-clippy/blob/557f6848bd5b7183f55c1e1522a326e9e1df6030/clippy_lints/src/lib.rs#L60 -[example_lint_page]: https://rust-lang.github.io/rust-clippy/master/index.html#redundant_closure -[lint_naming]: https://rust-lang.github.io/rfcs/0344-conventions-galore.html#lints -[category_level_mapping]: https://github.com/rust-lang/rust-clippy/blob/557f6848bd5b7183f55c1e1522a326e9e1df6030/clippy_lints/src/lib.rs#L110 +One reason that `cargo dev update_lints` does not automate this step is that +multiple lints can use the same lint pass, so registering the lint pass may +already be done when adding a new lint. Another reason that this step is not +automated is that the order that the passes are registered determines the order +the passes actually run, which in turn affects the order that any emitted lints +are output in. ## Lint passes -- cgit 1.4.1-3-g733a5 From b5bae091849dc02b7aded5026cf1e2b5497db318 Mon Sep 17 00:00:00 2001 From: Alex Macleod Date: Tue, 2 Nov 2021 13:21:27 +0000 Subject: Add `cargo dev lint` to manually run clippy on a file I found the manual run command really useful, this makes it a bit easier to type --- clippy_dev/src/lib.rs | 1 + clippy_dev/src/lint.rs | 20 ++++++++++++++++++++ clippy_dev/src/main.rs | 15 ++++++++++++++- doc/adding_lints.md | 2 +- 4 files changed, 36 insertions(+), 2 deletions(-) create mode 100644 clippy_dev/src/lint.rs (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lib.rs b/clippy_dev/src/lib.rs index 5538f62c8e7..59fde447547 100644 --- a/clippy_dev/src/lib.rs +++ b/clippy_dev/src/lib.rs @@ -7,6 +7,7 @@ use std::path::PathBuf; pub mod bless; pub mod fmt; +pub mod lint; pub mod new_lint; pub mod serve; pub mod setup; diff --git a/clippy_dev/src/lint.rs b/clippy_dev/src/lint.rs new file mode 100644 index 00000000000..dfd16f71054 --- /dev/null +++ b/clippy_dev/src/lint.rs @@ -0,0 +1,20 @@ +use std::process::{self, Command}; + +pub fn run(filename: &str) { + let code = Command::new("cargo") + .args(["run", "--bin", "clippy-driver", "--"]) + .args(["-L", "./target/debug"]) + .args(["-Z", "no-codegen"]) + .args(["--edition", "2021"]) + .arg(filename) + .env("__CLIPPY_INTERNAL_TESTS", "true") + .status() + .expect("failed to run cargo") + .code(); + + if code.is_none() { + eprintln!("Killed by signal"); + } + + process::exit(code.unwrap_or(1)); +} diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index b5c04efce3b..30a241c8ba1 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -3,7 +3,7 @@ #![warn(rust_2018_idioms, unused_lifetimes)] use clap::{App, AppSettings, Arg, ArgMatches, SubCommand}; -use clippy_dev::{bless, fmt, new_lint, serve, setup, update_lints}; +use clippy_dev::{bless, fmt, lint, new_lint, serve, setup, update_lints}; fn main() { let matches = get_clap_config(); @@ -55,6 +55,10 @@ fn main() { let lint = matches.value_of("lint"); serve::run(port, lint); }, + ("lint", Some(matches)) => { + let filename = matches.value_of("filename").unwrap(); + lint::run(filename); + }, _ => {}, } } @@ -219,5 +223,14 @@ fn get_clap_config<'a>() -> ArgMatches<'a> { ) .arg(Arg::with_name("lint").help("Which lint's page to load initially (optional)")), ) + .subcommand( + SubCommand::with_name("lint") + .about("Manually run clippy on a file") + .arg( + Arg::with_name("filename") + .required(true) + .help("The path to a file to lint"), + ), + ) .get_matches() } diff --git a/doc/adding_lints.md b/doc/adding_lints.md index bd32696d6db..380adcaafc1 100644 --- a/doc/adding_lints.md +++ b/doc/adding_lints.md @@ -157,7 +157,7 @@ Manually testing against an example file can be useful if you have added some your local modifications, run ``` -env __CLIPPY_INTERNAL_TESTS=true cargo run --bin clippy-driver -- -L ./target/debug input.rs +cargo dev lint input.rs ``` from the working copy root. With tests in place, let's have a look at -- cgit 1.4.1-3-g733a5 From 8565fc468e97d7ab4d350532474c36127960f8ee Mon Sep 17 00:00:00 2001 From: xFrednet Date: Tue, 12 Oct 2021 23:01:44 +0200 Subject: Add clippy version to Clippy's lint list --- clippy_dev/src/update_lints.rs | 1 + clippy_lints/src/utils/internal_lints/metadata_collector.rs | 2 +- util/gh-pages/index.html | 5 ++++- 3 files changed, 6 insertions(+), 2 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/update_lints.rs b/clippy_dev/src/update_lints.rs index 23f58bc4915..f615f74e6de 100644 --- a/clippy_dev/src/update_lints.rs +++ b/clippy_dev/src/update_lints.rs @@ -18,6 +18,7 @@ static DEC_CLIPPY_LINT_RE: SyncLazy = SyncLazy::new(|| { r#"(?x) declare_clippy_lint!\s*[\{(] (?:\s+///.*)* + (?:\s*\#\[clippy::version\s*=\s*"[^"]*"\])? \s+pub\s+(?P[A-Z_][A-Z_0-9]*)\s*,\s* (?P[a-z_]+)\s*,\s* "(?P(?:[^"\\]+|\\(?s).(?-s))*)"\s*[})] diff --git a/clippy_lints/src/utils/internal_lints/metadata_collector.rs b/clippy_lints/src/utils/internal_lints/metadata_collector.rs index d7a023fada2..70c3169c78e 100644 --- a/clippy_lints/src/utils/internal_lints/metadata_collector.rs +++ b/clippy_lints/src/utils/internal_lints/metadata_collector.rs @@ -146,7 +146,7 @@ declare_clippy_lint! { /// "docs": " ### What it does\nCollects metadata about clippy lints for the website. [...] " /// } /// ``` - #[clippy::version = "0.1.56"] + #[clippy::version = "1.56.0"] pub INTERNAL_METADATA_COLLECTOR, internal_warn, "A busy bee collection metadata about lints" diff --git a/util/gh-pages/index.html b/util/gh-pages/index.html index 48421150a54..cf8828a6bf4 100644 --- a/util/gh-pages/index.html +++ b/util/gh-pages/index.html @@ -339,7 +339,10 @@ Otherwise, have a great day =^.^= {{lint.applicability.applicability}} (?) - + +
+ Rust version: {{lint.version}} +
Related Issues -- cgit 1.4.1-3-g733a5 From 23ed79260baa31c24610a42470d379dd434b025a Mon Sep 17 00:00:00 2001 From: xFrednet Date: Sun, 17 Oct 2021 15:02:12 +0200 Subject: Document new `clippy::version` attribute and make it mandatory --- clippy_dev/Cargo.toml | 1 + clippy_dev/src/new_lint.rs | 21 ++++++++++++++++++--- clippy_dev/src/update_lints.rs | 5 ++++- doc/adding_lints.md | 6 ++++++ 4 files changed, 29 insertions(+), 4 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/Cargo.toml b/clippy_dev/Cargo.toml index affb283017c..08cf756c77c 100644 --- a/clippy_dev/Cargo.toml +++ b/clippy_dev/Cargo.toml @@ -12,6 +12,7 @@ opener = "0.5" regex = "1.5" shell-escape = "0.1" walkdir = "2.3" +cargo_metadata = "0.12" [features] deny-warnings = [] diff --git a/clippy_dev/src/new_lint.rs b/clippy_dev/src/new_lint.rs index 43a478ee77d..a14dc360138 100644 --- a/clippy_dev/src/new_lint.rs +++ b/clippy_dev/src/new_lint.rs @@ -132,6 +132,18 @@ fn to_camel_case(name: &str) -> String { .collect() } +fn get_stabilisation_version() -> String { + let mut command = cargo_metadata::MetadataCommand::new(); + command.no_deps(); + if let Ok(metadata) = command.exec() { + if let Some(pkg) = metadata.packages.iter().find(|pkg| pkg.name == "clippy") { + return format!("{}.{}.0", pkg.version.minor, pkg.version.patch); + } + } + + String::from(") -> String { let mut contents = format!( indoc! {" @@ -178,6 +190,7 @@ fn get_lint_file_contents(lint: &LintData<'_>, enable_msrv: bool) -> String { }, }; + let version = get_stabilisation_version(); let lint_name = lint.name; let category = lint.category; let name_camel = to_camel_case(lint.name); @@ -212,7 +225,7 @@ fn get_lint_file_contents(lint: &LintData<'_>, enable_msrv: bool) -> String { }); result.push_str(&format!( - indoc! {" + indoc! {r#" declare_clippy_lint! {{ /// ### What it does /// @@ -226,11 +239,13 @@ fn get_lint_file_contents(lint: &LintData<'_>, enable_msrv: bool) -> String { /// ```rust /// // example code which does not raise clippy warning /// ``` + #[clippy::version = "{version}"] pub {name_upper}, {category}, - \"default lint description\" + "default lint description" }} - "}, + "#}, + version = version, name_upper = name_upper, category = category, )); diff --git a/clippy_dev/src/update_lints.rs b/clippy_dev/src/update_lints.rs index f615f74e6de..21b2b3b66f4 100644 --- a/clippy_dev/src/update_lints.rs +++ b/clippy_dev/src/update_lints.rs @@ -18,7 +18,7 @@ static DEC_CLIPPY_LINT_RE: SyncLazy = SyncLazy::new(|| { r#"(?x) declare_clippy_lint!\s*[\{(] (?:\s+///.*)* - (?:\s*\#\[clippy::version\s*=\s*"[^"]*"\])? + (?:\s*\#\[clippy::version\s*=\s*"[^"]*"\]) \s+pub\s+(?P[A-Z_][A-Z_0-9]*)\s*,\s* (?P[a-z_]+)\s*,\s* "(?P(?:[^"\\]+|\\(?s).(?-s))*)"\s*[})] @@ -496,6 +496,7 @@ fn test_parse_contents() { let result: Vec = parse_contents( r#" declare_clippy_lint! { + #[clippy::version = "Hello Clippy!"] pub PTR_ARG, style, "really long \ @@ -503,6 +504,7 @@ declare_clippy_lint! { } declare_clippy_lint!{ + #[clippy::version = "Test version"] pub DOC_MARKDOWN, pedantic, "single line" @@ -510,6 +512,7 @@ declare_clippy_lint!{ /// some doc comment declare_deprecated_lint! { + #[clippy::version = "I'm a version"] pub SHOULD_ASSERT_EQ, "`assert!()` will be more flexible with RFC 2011" } diff --git a/doc/adding_lints.md b/doc/adding_lints.md index 26d06d334cd..cf16a1d5d3d 100644 --- a/doc/adding_lints.md +++ b/doc/adding_lints.md @@ -189,6 +189,7 @@ declare_clippy_lint! { /// ```rust /// // example code /// ``` + #[clippy::version = "1.29.0"] pub FOO_FUNCTIONS, pedantic, "function named `foo`, which is not a descriptive name" @@ -199,6 +200,10 @@ declare_clippy_lint! { section. This is the default documentation style and will be displayed [like this][example_lint_page]. To render and open this documentation locally in a browser, run `cargo dev serve`. +* The `#[clippy::version]` attribute will be rendered as part of the lint documentation. + The value should be set to the current Rust version that the lint is developed in, + it can be retrieved by running `rustc -vV` in the rust-clippy directory. The version + is listed under *release*. (Use the version without the `-nightly`) suffix. * `FOO_FUNCTIONS` is the name of our lint. Be sure to follow the [lint naming guidelines][lint_naming] here when naming your lint. In short, the name should state the thing that is being checked for and @@ -503,6 +508,7 @@ declare_clippy_lint! { /// // Good /// Insert a short example of improved code that doesn't trigger the lint /// ``` + #[clippy::version = "1.29.0"] pub FOO_FUNCTIONS, pedantic, "function named `foo`, which is not a descriptive name" -- cgit 1.4.1-3-g733a5 From 63cb41098bf1d9f1948492dd4c53e33ba2db828a Mon Sep 17 00:00:00 2001 From: xFrednet Date: Sun, 17 Oct 2021 16:57:13 +0200 Subject: Manually add `clippy::version` attribute to deprecated lints --- clippy_dev/src/update_lints.rs | 3 ++- clippy_lints/src/deprecated_lints.rs | 16 ++++++++++++++++ 2 files changed, 18 insertions(+), 1 deletion(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/update_lints.rs b/clippy_dev/src/update_lints.rs index 21b2b3b66f4..8dd073ef405 100644 --- a/clippy_dev/src/update_lints.rs +++ b/clippy_dev/src/update_lints.rs @@ -18,7 +18,7 @@ static DEC_CLIPPY_LINT_RE: SyncLazy = SyncLazy::new(|| { r#"(?x) declare_clippy_lint!\s*[\{(] (?:\s+///.*)* - (?:\s*\#\[clippy::version\s*=\s*"[^"]*"\]) + (?:\s*\#\[clippy::version\s*=\s*"[^"]*"\])? \s+pub\s+(?P[A-Z_][A-Z_0-9]*)\s*,\s* (?P[a-z_]+)\s*,\s* "(?P(?:[^"\\]+|\\(?s).(?-s))*)"\s*[})] @@ -32,6 +32,7 @@ static DEC_DEPRECATED_LINT_RE: SyncLazy = SyncLazy::new(|| { r#"(?x) declare_deprecated_lint!\s*[{(]\s* (?:\s+///.*)* + (?:\s*\#\[clippy::version\s*=\s*"[^"]*"\])? \s+pub\s+(?P[A-Z_][A-Z_0-9]*)\s*,\s* "(?P(?:[^"\\]+|\\(?s).(?-s))*)"\s*[})] "#, diff --git a/clippy_lints/src/deprecated_lints.rs b/clippy_lints/src/deprecated_lints.rs index 9d8524ec91c..bba27576c89 100644 --- a/clippy_lints/src/deprecated_lints.rs +++ b/clippy_lints/src/deprecated_lints.rs @@ -21,6 +21,7 @@ declare_deprecated_lint! { /// ### Deprecation reason /// This used to check for `assert!(a == b)` and recommend /// replacement with `assert_eq!(a, b)`, but this is no longer needed after RFC 2011. + #[clippy::version = "pre 1.29.0"] pub SHOULD_ASSERT_EQ, "`assert!()` will be more flexible with RFC 2011" } @@ -32,6 +33,7 @@ declare_deprecated_lint! { /// ### Deprecation reason /// This used to check for `Vec::extend`, which was slower than /// `Vec::extend_from_slice`. Thanks to specialization, this is no longer true. + #[clippy::version = "pre 1.29.0"] pub EXTEND_FROM_SLICE, "`.extend_from_slice(_)` is a faster way to extend a Vec by a slice" } @@ -45,6 +47,7 @@ declare_deprecated_lint! { /// an infinite iterator, which is better expressed by `iter::repeat`, /// but the method has been removed for `Iterator::step_by` which panics /// if given a zero + #[clippy::version = "pre 1.29.0"] pub RANGE_STEP_BY_ZERO, "`iterator.step_by(0)` panics nowadays" } @@ -56,6 +59,7 @@ declare_deprecated_lint! { /// ### Deprecation reason /// This used to check for `Vec::as_slice`, which was unstable with good /// stable alternatives. `Vec::as_slice` has now been stabilized. + #[clippy::version = "pre 1.29.0"] pub UNSTABLE_AS_SLICE, "`Vec::as_slice` has been stabilized in 1.7" } @@ -67,6 +71,7 @@ declare_deprecated_lint! { /// ### Deprecation reason /// This used to check for `Vec::as_mut_slice`, which was unstable with good /// stable alternatives. `Vec::as_mut_slice` has now been stabilized. + #[clippy::version = "pre 1.29.0"] pub UNSTABLE_AS_MUT_SLICE, "`Vec::as_mut_slice` has been stabilized in 1.7" } @@ -80,6 +85,7 @@ declare_deprecated_lint! { /// between non-pointer types of differing alignment is well-defined behavior (it's semantically /// equivalent to a memcpy). This lint has thus been refactored into two separate lints: /// cast_ptr_alignment and transmute_ptr_to_ptr. + #[clippy::version = "pre 1.29.0"] pub MISALIGNED_TRANSMUTE, "this lint has been split into cast_ptr_alignment and transmute_ptr_to_ptr" } @@ -92,6 +98,7 @@ declare_deprecated_lint! { /// This lint is too subjective, not having a good reason for being in clippy. /// Additionally, compound assignment operators may be overloaded separately from their non-assigning /// counterparts, so this lint may suggest a change in behavior or the code may not compile. + #[clippy::version = "1.30.0"] pub ASSIGN_OPS, "using compound assignment operators (e.g., `+=`) is harmless" } @@ -104,6 +111,7 @@ declare_deprecated_lint! { /// The original rule will only lint for `if let`. After /// making it support to lint `match`, naming as `if let` is not suitable for it. /// So, this lint is deprecated. + #[clippy::version = "pre 1.29.0"] pub IF_LET_REDUNDANT_PATTERN_MATCHING, "this lint has been changed to redundant_pattern_matching" } @@ -117,6 +125,7 @@ declare_deprecated_lint! { /// Vec::with_capacity(n); vec.set_len(n);` with `let vec = vec![0; n];`. The /// replacement has very different performance characteristics so the lint is /// deprecated. + #[clippy::version = "pre 1.29.0"] pub UNSAFE_VECTOR_INITIALIZATION, "the replacement suggested by this lint had substantially different behavior" } @@ -127,6 +136,7 @@ declare_deprecated_lint! { /// /// ### Deprecation reason /// This lint has been superseded by #[must_use] in rustc. + #[clippy::version = "1.39.0"] pub UNUSED_COLLECT, "`collect` has been marked as #[must_use] in rustc and that covers all cases of this lint" } @@ -137,6 +147,7 @@ declare_deprecated_lint! { /// /// ### Deprecation reason /// Associated-constants are now preferred. + #[clippy::version = "1.44.0"] pub REPLACE_CONSTS, "associated-constants `MIN`/`MAX` of integers are preferred to `{min,max}_value()` and module constants" } @@ -147,6 +158,7 @@ declare_deprecated_lint! { /// /// ### Deprecation reason /// The regex! macro does not exist anymore. + #[clippy::version = "1.47.0"] pub REGEX_MACRO, "the regex! macro has been removed from the regex crate in 2018" } @@ -158,6 +170,7 @@ declare_deprecated_lint! { /// ### Deprecation reason /// This lint has been replaced by `manual_find_map`, a /// more specific lint. + #[clippy::version = "1.51.0"] pub FIND_MAP, "this lint has been replaced by `manual_find_map`, a more specific lint" } @@ -169,6 +182,7 @@ declare_deprecated_lint! { /// ### Deprecation reason /// This lint has been replaced by `manual_filter_map`, a /// more specific lint. + #[clippy::version = "1.53.0"] pub FILTER_MAP, "this lint has been replaced by `manual_filter_map`, a more specific lint" } @@ -181,6 +195,7 @@ declare_deprecated_lint! { /// The `avoid_breaking_exported_api` config option was added, which /// enables the `enum_variant_names` lint for public items. /// ``` + #[clippy::version = "1.54.0"] pub PUB_ENUM_VARIANT_NAMES, "set the `avoid-breaking-exported-api` config option to `false` to enable the `enum_variant_names` lint for public items" } @@ -192,6 +207,7 @@ declare_deprecated_lint! { /// ### Deprecation reason /// The `avoid_breaking_exported_api` config option was added, which /// enables the `wrong_self_conversion` lint for public items. + #[clippy::version = "1.54.0"] pub WRONG_PUB_SELF_CONVENTION, "set the `avoid-breaking-exported-api` config option to `false` to enable the `wrong_self_convention` lint for public items" } -- cgit 1.4.1-3-g733a5 From 94bc0a1c78f306186c830f716903e021c8ab7088 Mon Sep 17 00:00:00 2001 From: xFrednet Date: Wed, 10 Nov 2021 20:08:38 +0100 Subject: Address review feedback --- clippy_dev/Cargo.toml | 2 +- clippy_dev/src/new_lint.rs | 2 +- clippy_lints/src/utils/internal_lints.rs | 20 ++++++-------------- 3 files changed, 8 insertions(+), 16 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/Cargo.toml b/clippy_dev/Cargo.toml index 08cf756c77c..d350d9a0018 100644 --- a/clippy_dev/Cargo.toml +++ b/clippy_dev/Cargo.toml @@ -12,7 +12,7 @@ opener = "0.5" regex = "1.5" shell-escape = "0.1" walkdir = "2.3" -cargo_metadata = "0.12" +cargo_metadata = "0.14" [features] deny-warnings = [] diff --git a/clippy_dev/src/new_lint.rs b/clippy_dev/src/new_lint.rs index a14dc360138..59658b42c79 100644 --- a/clippy_dev/src/new_lint.rs +++ b/clippy_dev/src/new_lint.rs @@ -141,7 +141,7 @@ fn get_stabilisation_version() -> String { } } - String::from("") } fn get_test_file_contents(lint_name: &str, header_commands: Option<&str>) -> String { diff --git a/clippy_lints/src/utils/internal_lints.rs b/clippy_lints/src/utils/internal_lints.rs index aa722758859..c20bd4ca38f 100644 --- a/clippy_lints/src/utils/internal_lints.rs +++ b/clippy_lints/src/utils/internal_lints.rs @@ -318,19 +318,11 @@ declare_clippy_lint! { declare_clippy_lint! { /// ### What it does - /// Checks for invalid `clippy::version` attributes + /// Checks for invalid `clippy::version` attributes. /// - /// ```txt - /// +-------------------------------+ - /// | Valid values are: | - /// | * "pre 1.29.0" | - /// | * any valid semantic version | - /// +-------------------------------+ - /// \ - /// \ (^v^) - /// <( )> - /// w w - /// ``` + /// Valid values are: + /// * "pre 1.29.0" + /// * any valid semantic version pub INVALID_CLIPPY_VERSION_ATTRIBUTE, internal, "found an invalid `clippy::version` attribute" @@ -484,8 +476,8 @@ fn is_lint_ref_type<'tcx>(cx: &LateContext<'tcx>, ty: &Ty<'_>) -> bool { fn check_invalid_clippy_version_attribute(cx: &LateContext<'_>, item: &'_ Item<'_>) { if let Some(value) = extract_clippy_version_value(cx, item) { - // The `sym!` macro doesn't work as it only expects a single token. I think - // It's better to keep it this way and have a direct `Symbol::intern` call here :) + // The `sym!` macro doesn't work as it only expects a single token. + // It's better to keep it this way and have a direct `Symbol::intern` call here. if value == Symbol::intern("pre 1.29.0") { return; } -- cgit 1.4.1-3-g733a5 From 24d561f0081b047d3a54f70dbff2a1b621f62749 Mon Sep 17 00:00:00 2001 From: Jason Newcomb Date: Thu, 11 Nov 2021 21:14:40 -0500 Subject: Use rustfmt version from `rust-toolchain` --- clippy_dev/src/fmt.rs | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/fmt.rs b/clippy_dev/src/fmt.rs index c81eb40d52f..bdca75e609f 100644 --- a/clippy_dev/src/fmt.rs +++ b/clippy_dev/src/fmt.rs @@ -149,7 +149,7 @@ fn exec( } fn cargo_fmt(context: &FmtContext, path: &Path) -> Result { - let mut args = vec!["+nightly", "fmt", "--all"]; + let mut args = vec!["fmt", "--all"]; if context.check { args.push("--"); args.push("--check"); @@ -162,7 +162,7 @@ fn cargo_fmt(context: &FmtContext, path: &Path) -> Result { fn rustfmt_test(context: &FmtContext) -> Result<(), CliError> { let program = "rustfmt"; let dir = std::env::current_dir()?; - let args = &["+nightly", "--version"]; + let args = &["--version"]; if context.verbose { println!("{}", format_command(&program, &dir, args)); @@ -186,7 +186,7 @@ fn rustfmt_test(context: &FmtContext) -> Result<(), CliError> { } fn rustfmt(context: &FmtContext, path: &Path) -> Result { - let mut args = vec!["+nightly".as_ref(), path.as_os_str()]; + let mut args = vec![path.as_os_str()]; if context.check { args.push("--check".as_ref()); } -- cgit 1.4.1-3-g733a5 From 507030f7c429f24ce7e2030e9633803da0c80bf4 Mon Sep 17 00:00:00 2001 From: Alex Macleod Date: Fri, 12 Nov 2021 16:41:08 +0000 Subject: Run rustfmt on batches of multiple files --- clippy_dev/src/fmt.rs | 40 ++++++++++++++++++++++++---------------- 1 file changed, 24 insertions(+), 16 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/fmt.rs b/clippy_dev/src/fmt.rs index bdca75e609f..9ceadee58ea 100644 --- a/clippy_dev/src/fmt.rs +++ b/clippy_dev/src/fmt.rs @@ -1,6 +1,7 @@ use crate::clippy_project_root; +use itertools::Itertools; use shell_escape::escape; -use std::ffi::OsStr; +use std::ffi::{OsStr, OsString}; use std::path::Path; use std::process::{self, Command}; use std::{fs, io}; @@ -56,15 +57,22 @@ pub fn run(check: bool, verbose: bool) { success &= cargo_fmt(context, &project_root.join("rustc_tools_util"))?; success &= cargo_fmt(context, &project_root.join("lintcheck"))?; - for entry in WalkDir::new(project_root.join("tests")) { - let entry = entry?; - let path = entry.path(); - - if path.extension() != Some("rs".as_ref()) || entry.file_name() == "ice-3891.rs" { - continue; - } - - success &= rustfmt(context, path)?; + let chunks = WalkDir::new(project_root.join("tests")) + .into_iter() + .filter_map(|entry| { + let entry = entry.expect("failed to find tests"); + let path = entry.path(); + + if path.extension() != Some("rs".as_ref()) || entry.file_name() == "ice-3891.rs" { + None + } else { + Some(entry.into_path().into_os_string()) + } + }) + .chunks(250); + + for chunk in &chunks { + success &= rustfmt(context, chunk)?; } Ok(success) @@ -185,14 +193,14 @@ fn rustfmt_test(context: &FmtContext) -> Result<(), CliError> { } } -fn rustfmt(context: &FmtContext, path: &Path) -> Result { - let mut args = vec![path.as_os_str()]; +fn rustfmt(context: &FmtContext, paths: impl Iterator) -> Result { + let mut args = Vec::new(); if context.check { - args.push("--check".as_ref()); + args.push(OsString::from("--check")); } + args.extend(paths); + let success = exec(context, "rustfmt", std::env::current_dir()?, &args)?; - if !success { - eprintln!("rustfmt failed on {}", path.display()); - } + Ok(success) } -- cgit 1.4.1-3-g733a5 From e2ce4f9462c1d65b4dce084186c0e532c27fe5a3 Mon Sep 17 00:00:00 2001 From: Cameron Steffen Date: Sun, 9 Jan 2022 18:22:38 -0600 Subject: Combine internal features in clippy_lints --- .cargo/config.toml | 2 +- .github/workflows/clippy.yml | 6 ++--- .github/workflows/clippy_bors.yml | 6 ++--- Cargo.toml | 3 +-- clippy_dev/src/update_lints.rs | 2 +- clippy_lints/Cargo.toml | 3 +-- clippy_lints/src/lib.register_lints.rs | 28 +++++++++++----------- clippy_lints/src/lib.rs | 13 ++++------ clippy_lints/src/utils/conf.rs | 2 +- clippy_lints/src/utils/internal_lints.rs | 2 +- .../src/utils/internal_lints/metadata_collector.rs | 3 +-- clippy_lints/src/utils/mod.rs | 2 +- tests/compile-test.rs | 2 +- tests/dogfood.rs | 10 ++++---- 14 files changed, 39 insertions(+), 45 deletions(-) (limited to 'clippy_dev/src') diff --git a/.cargo/config.toml b/.cargo/config.toml index c9ae0a961b6..f3dd9275a42 100644 --- a/.cargo/config.toml +++ b/.cargo/config.toml @@ -2,7 +2,7 @@ uitest = "test --test compile-test" dev = "run --package clippy_dev --bin clippy_dev --manifest-path clippy_dev/Cargo.toml --" lintcheck = "run --package lintcheck --bin lintcheck --manifest-path lintcheck/Cargo.toml -- " -collect-metadata = "test --test dogfood --features metadata-collector-lint -- run_metadata_collection_lint --ignored" +collect-metadata = "test --test dogfood --features internal -- run_metadata_collection_lint --ignored" [build] # -Zbinary-dep-depinfo allows us to track which rlib files to use for compiling UI tests diff --git a/.github/workflows/clippy.yml b/.github/workflows/clippy.yml index a14e530df4e..8b5e814b177 100644 --- a/.github/workflows/clippy.yml +++ b/.github/workflows/clippy.yml @@ -49,13 +49,13 @@ jobs: echo "LD_LIBRARY_PATH=${SYSROOT}/lib${LD_LIBRARY_PATH+:${LD_LIBRARY_PATH}}" >> $GITHUB_ENV - name: Build - run: cargo build --features deny-warnings,internal-lints,metadata-collector-lint + run: cargo build --features deny-warnings,internal - name: Test - run: cargo test --features deny-warnings,internal-lints,metadata-collector-lint + run: cargo test --features deny-warnings,internal - name: Test clippy_lints - run: cargo test --features deny-warnings,internal-lints,metadata-collector-lint + run: cargo test --features deny-warnings,internal working-directory: clippy_lints - name: Test clippy_utils diff --git a/.github/workflows/clippy_bors.yml b/.github/workflows/clippy_bors.yml index 06522606347..eb045ec30dc 100644 --- a/.github/workflows/clippy_bors.yml +++ b/.github/workflows/clippy_bors.yml @@ -112,13 +112,13 @@ jobs: echo "$SYSROOT/bin" >> $GITHUB_PATH - name: Build - run: cargo build --features deny-warnings,internal-lints,metadata-collector-lint + run: cargo build --features deny-warnings,internal - name: Test - run: cargo test --features deny-warnings,internal-lints,metadata-collector-lint + run: cargo test --features deny-warnings,internal - name: Test clippy_lints - run: cargo test --features deny-warnings,internal-lints,metadata-collector-lint + run: cargo test --features deny-warnings,internal working-directory: clippy_lints - name: Test clippy_utils diff --git a/Cargo.toml b/Cargo.toml index 79a7ec92071..cb49dd84c39 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -57,8 +57,7 @@ rustc_tools_util = { version = "0.2", path = "rustc_tools_util" } [features] deny-warnings = ["clippy_lints/deny-warnings"] integration = ["tempfile"] -internal-lints = ["clippy_lints/internal-lints"] -metadata-collector-lint = ["internal-lints", "clippy_lints/metadata-collector-lint"] +internal = ["clippy_lints/internal"] [package.metadata.rust-analyzer] # This package uses #[feature(rustc_private)] diff --git a/clippy_dev/src/update_lints.rs b/clippy_dev/src/update_lints.rs index 8dd073ef405..d368ef1f46a 100644 --- a/clippy_dev/src/update_lints.rs +++ b/clippy_dev/src/update_lints.rs @@ -321,7 +321,7 @@ fn gen_register_lint_list<'a>( for (is_public, module_name, lint_name) in details { if !is_public { - output.push_str(" #[cfg(feature = \"internal-lints\")]\n"); + output.push_str(" #[cfg(feature = \"internal\")]\n"); } output.push_str(&format!(" {}::{},\n", module_name, lint_name)); } diff --git a/clippy_lints/Cargo.toml b/clippy_lints/Cargo.toml index 639138ac9c5..e9f87b60ece 100644 --- a/clippy_lints/Cargo.toml +++ b/clippy_lints/Cargo.toml @@ -30,8 +30,7 @@ url = { version = "2.2", features = ["serde"] } [features] deny-warnings = ["clippy_utils/deny-warnings"] # build clippy with internal lints enabled, off by default -internal-lints = ["clippy_utils/internal"] -metadata-collector-lint = ["serde_json", "clippy_utils/internal"] +internal = ["clippy_utils/internal", "serde_json"] [package.metadata.rust-analyzer] # This crate uses #[feature(rustc_private)] diff --git a/clippy_lints/src/lib.register_lints.rs b/clippy_lints/src/lib.register_lints.rs index f9241d943b2..832178c2db5 100644 --- a/clippy_lints/src/lib.register_lints.rs +++ b/clippy_lints/src/lib.register_lints.rs @@ -3,33 +3,33 @@ // Manual edits will be overwritten. store.register_lints(&[ - #[cfg(feature = "internal-lints")] + #[cfg(feature = "internal")] utils::internal_lints::CLIPPY_LINTS_INTERNAL, - #[cfg(feature = "internal-lints")] + #[cfg(feature = "internal")] utils::internal_lints::COLLAPSIBLE_SPAN_LINT_CALLS, - #[cfg(feature = "internal-lints")] + #[cfg(feature = "internal")] utils::internal_lints::COMPILER_LINT_FUNCTIONS, - #[cfg(feature = "internal-lints")] + #[cfg(feature = "internal")] utils::internal_lints::DEFAULT_LINT, - #[cfg(feature = "internal-lints")] + #[cfg(feature = "internal")] utils::internal_lints::IF_CHAIN_STYLE, - #[cfg(feature = "internal-lints")] + #[cfg(feature = "internal")] utils::internal_lints::INTERNING_DEFINED_SYMBOL, - #[cfg(feature = "internal-lints")] + #[cfg(feature = "internal")] utils::internal_lints::INVALID_CLIPPY_VERSION_ATTRIBUTE, - #[cfg(feature = "internal-lints")] + #[cfg(feature = "internal")] utils::internal_lints::INVALID_PATHS, - #[cfg(feature = "internal-lints")] + #[cfg(feature = "internal")] utils::internal_lints::LINT_WITHOUT_LINT_PASS, - #[cfg(feature = "internal-lints")] + #[cfg(feature = "internal")] utils::internal_lints::MATCH_TYPE_ON_DIAGNOSTIC_ITEM, - #[cfg(feature = "internal-lints")] + #[cfg(feature = "internal")] utils::internal_lints::MISSING_CLIPPY_VERSION_ATTRIBUTE, - #[cfg(feature = "internal-lints")] + #[cfg(feature = "internal")] utils::internal_lints::OUTER_EXPN_EXPN_DATA, - #[cfg(feature = "internal-lints")] + #[cfg(feature = "internal")] utils::internal_lints::PRODUCE_ICE, - #[cfg(feature = "internal-lints")] + #[cfg(feature = "internal")] utils::internal_lints::UNNECESSARY_SYMBOL_STR, absurd_extreme_comparisons::ABSURD_EXTREME_COMPARISONS, approx_const::APPROX_CONSTANT, diff --git a/clippy_lints/src/lib.rs b/clippy_lints/src/lib.rs index c31acb5f4ef..0d765c2bcde 100644 --- a/clippy_lints/src/lib.rs +++ b/clippy_lints/src/lib.rs @@ -153,12 +153,9 @@ macro_rules! declare_clippy_lint { }; } -#[cfg(feature = "metadata-collector-lint")] +#[cfg(feature = "internal")] mod deprecated_lints; -#[cfg_attr( - any(feature = "internal-lints", feature = "metadata-collector-lint"), - allow(clippy::missing_clippy_version_attribute) -)] +#[cfg_attr(feature = "internal", allow(clippy::missing_clippy_version_attribute))] mod utils; // begin lints modules, do not remove this comment, it’s used in `update_lints` @@ -472,7 +469,7 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf: include!("lib.register_restriction.rs"); include!("lib.register_pedantic.rs"); - #[cfg(feature = "internal-lints")] + #[cfg(feature = "internal")] include!("lib.register_internal.rs"); include!("lib.register_all.rs"); @@ -484,7 +481,7 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf: include!("lib.register_cargo.rs"); include!("lib.register_nursery.rs"); - #[cfg(feature = "metadata-collector-lint")] + #[cfg(feature = "internal")] { if std::env::var("ENABLE_METADATA_COLLECTION").eq(&Ok("1".to_string())) { store.register_late_pass(|| Box::new(utils::internal_lints::metadata_collector::MetadataCollector::new())); @@ -493,7 +490,7 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf: } // all the internal lints - #[cfg(feature = "internal-lints")] + #[cfg(feature = "internal")] { store.register_early_pass(|| Box::new(utils::internal_lints::ClippyLintsInternal)); store.register_early_pass(|| Box::new(utils::internal_lints::ProduceIce)); diff --git a/clippy_lints/src/utils/conf.rs b/clippy_lints/src/utils/conf.rs index 9c83d30eb9c..4e1c538c1c2 100644 --- a/clippy_lints/src/utils/conf.rs +++ b/clippy_lints/src/utils/conf.rs @@ -113,7 +113,7 @@ macro_rules! define_Conf { } } - #[cfg(feature = "metadata-collector-lint")] + #[cfg(feature = "internal")] pub mod metadata { use crate::utils::internal_lints::metadata_collector::ClippyConfiguration; diff --git a/clippy_lints/src/utils/internal_lints.rs b/clippy_lints/src/utils/internal_lints.rs index 165004e5b41..67faca70d5c 100644 --- a/clippy_lints/src/utils/internal_lints.rs +++ b/clippy_lints/src/utils/internal_lints.rs @@ -35,7 +35,7 @@ use rustc_typeck::hir_ty_to_ty; use std::borrow::{Borrow, Cow}; -#[cfg(feature = "metadata-collector-lint")] +#[cfg(feature = "internal")] pub mod metadata_collector; declare_clippy_lint! { diff --git a/clippy_lints/src/utils/internal_lints/metadata_collector.rs b/clippy_lints/src/utils/internal_lints/metadata_collector.rs index 7707eebd622..02f5d45cc18 100644 --- a/clippy_lints/src/utils/internal_lints/metadata_collector.rs +++ b/clippy_lints/src/utils/internal_lints/metadata_collector.rs @@ -1,8 +1,7 @@ //! This lint is used to collect metadata about clippy lints. This metadata is exported as a json //! file and then used to generate the [clippy lint list](https://rust-lang.github.io/rust-clippy/master/index.html) //! -//! This module and therefor the entire lint is guarded by a feature flag called -//! `metadata-collector-lint` +//! This module and therefore the entire lint is guarded by a feature flag called `internal` //! //! The module transforms all lint names to ascii lowercase to ensure that we don't have mismatches //! during any comparison or mapping. (Please take care of this, it's not fun to spend time on such diff --git a/clippy_lints/src/utils/mod.rs b/clippy_lints/src/utils/mod.rs index b67448e3a57..dc385ebacba 100644 --- a/clippy_lints/src/utils/mod.rs +++ b/clippy_lints/src/utils/mod.rs @@ -1,5 +1,5 @@ pub mod author; pub mod conf; pub mod inspector; -#[cfg(any(feature = "internal-lints", feature = "metadata-collector-lint"))] +#[cfg(feature = "internal")] pub mod internal_lints; diff --git a/tests/compile-test.rs b/tests/compile-test.rs index d602d2042ee..762b67fc585 100644 --- a/tests/compile-test.rs +++ b/tests/compile-test.rs @@ -15,7 +15,7 @@ use std::path::{Path, PathBuf}; mod cargo; // whether to run internal tests or not -const RUN_INTERNAL_TESTS: bool = cfg!(feature = "internal-lints"); +const RUN_INTERNAL_TESTS: bool = cfg!(feature = "internal"); /// All crates used in UI tests are listed here static TEST_DEPENDENCIES: &[&str] = &[ diff --git a/tests/dogfood.rs b/tests/dogfood.rs index a37cdfed126..6f7de9c67a9 100644 --- a/tests/dogfood.rs +++ b/tests/dogfood.rs @@ -42,8 +42,8 @@ fn dogfood_clippy() { .args(&["-D", "clippy::pedantic"]) .arg("-Cdebuginfo=0"); // disable debuginfo to generate less data in the target dir - // internal lints only exist if we build with the internal-lints feature - if cfg!(feature = "internal-lints") { + // internal lints only exist if we build with the internal feature + if cfg!(feature = "internal") { command.args(&["-D", "clippy::internal"]); } @@ -180,7 +180,7 @@ fn dogfood_subprojects() { #[test] #[ignore] -#[cfg(feature = "metadata-collector-lint")] +#[cfg(feature = "internal")] fn run_metadata_collection_lint() { use std::fs::File; use std::time::SystemTime; @@ -233,8 +233,8 @@ fn run_clippy_for_project(project: &str) { .args(&["-D", "clippy::pedantic"]) .arg("-Cdebuginfo=0"); // disable debuginfo to generate less data in the target dir - // internal lints only exist if we build with the internal-lints feature - if cfg!(feature = "internal-lints") { + // internal lints only exist if we build with the internal feature + if cfg!(feature = "internal") { command.args(&["-D", "clippy::internal"]); } -- cgit 1.4.1-3-g733a5 From 7cf4f44e561acd2c69b9a4fd1b5e97ff59a6bbbe Mon Sep 17 00:00:00 2001 From: Cameron Steffen Date: Mon, 10 Jan 2022 14:30:45 -0600 Subject: Fix output capturing --- clippy_dev/src/fmt.rs | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/fmt.rs b/clippy_dev/src/fmt.rs index 9ceadee58ea..625fef23afb 100644 --- a/clippy_dev/src/fmt.rs +++ b/clippy_dev/src/fmt.rs @@ -141,8 +141,11 @@ fn exec( println!("{}", format_command(&program, &dir, args)); } - let child = Command::new(&program).current_dir(&dir).args(args.iter()).spawn()?; - let output = child.wait_with_output()?; + let output = Command::new(&program) + .current_dir(&dir) + .args(args.iter()) + .output() + .unwrap(); let success = output.status.success(); if !context.check && !success { -- cgit 1.4.1-3-g733a5 From d356fb9fa20198d770fc7e05bb71aea00875b3ea Mon Sep 17 00:00:00 2001 From: Cameron Steffen Date: Mon, 10 Jan 2022 13:53:02 -0600 Subject: Use `rustup which rustfmt` --- clippy_dev/src/fmt.rs | 25 +++++++++++++++++++++---- 1 file changed, 21 insertions(+), 4 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/fmt.rs b/clippy_dev/src/fmt.rs index 625fef23afb..d513a229b7e 100644 --- a/clippy_dev/src/fmt.rs +++ b/clippy_dev/src/fmt.rs @@ -3,7 +3,7 @@ use itertools::Itertools; use shell_escape::escape; use std::ffi::{OsStr, OsString}; use std::path::Path; -use std::process::{self, Command}; +use std::process::{self, Command, Stdio}; use std::{fs, io}; use walkdir::WalkDir; @@ -31,6 +31,7 @@ impl From for CliError { struct FmtContext { check: bool, verbose: bool, + rustfmt_path: String, } // the "main" function of cargo dev fmt @@ -102,7 +103,23 @@ Please revert the changes to Cargo.tomls first." } } - let context = FmtContext { check, verbose }; + let output = Command::new("rustup") + .args(["which", "rustfmt"]) + .stderr(Stdio::inherit()) + .output() + .expect("error running `rustup which rustfmt`"); + if !output.status.success() { + eprintln!("`rustup which rustfmt` did not execute successfully"); + process::exit(1); + } + let mut rustfmt_path = String::from_utf8(output.stdout).expect("invalid rustfmt path"); + rustfmt_path.truncate(rustfmt_path.trim_end().len()); + + let context = FmtContext { + check, + verbose, + rustfmt_path, + }; let result = try_run(&context); let code = match result { Ok(true) => 0, @@ -142,6 +159,7 @@ fn exec( } let output = Command::new(&program) + .env("RUSTFMT", &context.rustfmt_path) .current_dir(&dir) .args(args.iter()) .output() @@ -162,7 +180,6 @@ fn exec( fn cargo_fmt(context: &FmtContext, path: &Path) -> Result { let mut args = vec!["fmt", "--all"]; if context.check { - args.push("--"); args.push("--check"); } let success = exec(context, "cargo", path, &args)?; @@ -203,7 +220,7 @@ fn rustfmt(context: &FmtContext, paths: impl Iterator) -> Resul } args.extend(paths); - let success = exec(context, "rustfmt", std::env::current_dir()?, &args)?; + let success = exec(context, &context.rustfmt_path, std::env::current_dir()?, &args)?; Ok(success) } -- cgit 1.4.1-3-g733a5 From 3afbae33ab55f7206460ad34196c816aa2ac8909 Mon Sep 17 00:00:00 2001 From: Cameron Steffen Date: Wed, 12 Jan 2022 13:27:51 -0600 Subject: Remove __CLIPPY_INTERNAL_TESTS env var --- clippy_dev/src/lint.rs | 1 - src/driver.rs | 3 +-- tests/compile-test.rs | 8 +------- 3 files changed, 2 insertions(+), 10 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lint.rs b/clippy_dev/src/lint.rs index dfd16f71054..b8287980a4b 100644 --- a/clippy_dev/src/lint.rs +++ b/clippy_dev/src/lint.rs @@ -7,7 +7,6 @@ pub fn run(filename: &str) { .args(["-Z", "no-codegen"]) .args(["--edition", "2021"]) .arg(filename) - .env("__CLIPPY_INTERNAL_TESTS", "true") .status() .expect("failed to run cargo") .code(); diff --git a/src/driver.rs b/src/driver.rs index a8aa3a76abc..8f8f1140a3d 100644 --- a/src/driver.rs +++ b/src/driver.rs @@ -331,11 +331,10 @@ pub fn main() { // - IF Clippy is run on the main crate, not on deps (`!cap_lints_allow`) THEN // - IF `--no-deps` is not set (`!no_deps`) OR // - IF `--no-deps` is set and Clippy is run on the specified primary package - let clippy_tests_set = env::var("__CLIPPY_INTERNAL_TESTS").map_or(false, |val| val == "true"); let cap_lints_allow = arg_value(&orig_args, "--cap-lints", |val| val == "allow").is_some(); let in_primary_package = env::var("CARGO_PRIMARY_PACKAGE").is_ok(); - let clippy_enabled = clippy_tests_set || (!cap_lints_allow && (!no_deps || in_primary_package)); + let clippy_enabled = !cap_lints_allow && (!no_deps || in_primary_package); if clippy_enabled { args.extend(clippy_args); } diff --git a/tests/compile-test.rs b/tests/compile-test.rs index 531890c863f..6505028db9f 100644 --- a/tests/compile-test.rs +++ b/tests/compile-test.rs @@ -328,15 +328,9 @@ fn run_ui_cargo(config: &mut compiletest::Config) { } } -fn prepare_env() { - set_var("CLIPPY_DISABLE_DOCS_LINKS", "true"); - set_var("__CLIPPY_INTERNAL_TESTS", "true"); - //set_var("RUST_BACKTRACE", "0"); -} - #[test] fn compile_test() { - prepare_env(); + set_var("CLIPPY_DISABLE_DOCS_LINKS", "true"); let mut config = default_config(); run_ui(&mut config); run_ui_test(&mut config); -- cgit 1.4.1-3-g733a5 From 7ed29c0051c5c46261644d8098793fd08efddb4c Mon Sep 17 00:00:00 2001 From: Jason Newcomb Date: Fri, 21 Jan 2022 23:11:32 -0500 Subject: Don't bless outdated files on windows --- clippy_dev/src/bless.rs | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/bless.rs b/clippy_dev/src/bless.rs index daf0fcc993b..dcc2502e4c5 100644 --- a/clippy_dev/src/bless.rs +++ b/clippy_dev/src/bless.rs @@ -9,9 +9,14 @@ use walkdir::WalkDir; use crate::clippy_project_root; +#[cfg(not(windows))] +static CARGO_CLIPPY_EXE: &str = "cargo-clippy"; +#[cfg(windows)] +static CARGO_CLIPPY_EXE: &str = "cargo-clippy.exe"; + static CLIPPY_BUILD_TIME: SyncLazy> = SyncLazy::new(|| { let mut path = std::env::current_exe().unwrap(); - path.set_file_name("cargo-clippy"); + path.set_file_name(CARGO_CLIPPY_EXE); fs::metadata(path).ok()?.modified().ok() }); -- cgit 1.4.1-3-g733a5 From 04dce4aed45540db007a2d1f70c5c02af8e64422 Mon Sep 17 00:00:00 2001 From: Alex Macleod Date: Sun, 30 Jan 2022 16:39:30 +0000 Subject: Support `cargo dev bless` for tests with revisions --- clippy_dev/src/bless.rs | 65 ++++++++--------------------- tests/compile-test.rs | 81 +++++++++++++++++------------------- tests/ui/non_expressive_names.stdout | 0 3 files changed, 56 insertions(+), 90 deletions(-) delete mode 100644 tests/ui/non_expressive_names.stdout (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/bless.rs b/clippy_dev/src/bless.rs index dcc2502e4c5..b0fb39e8169 100644 --- a/clippy_dev/src/bless.rs +++ b/clippy_dev/src/bless.rs @@ -5,9 +5,7 @@ use std::ffi::OsStr; use std::fs; use std::lazy::SyncLazy; use std::path::{Path, PathBuf}; -use walkdir::WalkDir; - -use crate::clippy_project_root; +use walkdir::{DirEntry, WalkDir}; #[cfg(not(windows))] static CARGO_CLIPPY_EXE: &str = "cargo-clippy"; @@ -24,43 +22,25 @@ static CLIPPY_BUILD_TIME: SyncLazy> = SyncLazy::ne /// /// Panics if the path to a test file is broken pub fn bless(ignore_timestamp: bool) { - let test_suite_dirs = [ - clippy_project_root().join("tests").join("ui"), - clippy_project_root().join("tests").join("ui-internal"), - clippy_project_root().join("tests").join("ui-toml"), - clippy_project_root().join("tests").join("ui-cargo"), - ]; - for test_suite_dir in &test_suite_dirs { - WalkDir::new(test_suite_dir) - .into_iter() - .filter_map(Result::ok) - .filter(|f| f.path().extension() == Some(OsStr::new("rs"))) - .for_each(|f| { - let test_name = f.path().strip_prefix(test_suite_dir).unwrap(); - for &ext in &["stdout", "stderr", "fixed"] { - let test_name_ext = format!("stage-id.{}", ext); - update_reference_file( - f.path().with_extension(ext), - test_name.with_extension(test_name_ext), - ignore_timestamp, - ); - } - }); - } + let extensions = ["stdout", "stderr", "fixed"].map(OsStr::new); + + WalkDir::new(build_dir()) + .into_iter() + .map(Result::unwrap) + .filter(|entry| entry.path().extension().map_or(false, |ext| extensions.contains(&ext))) + .for_each(|entry| update_reference_file(&entry, ignore_timestamp)); } -fn update_reference_file(reference_file_path: PathBuf, test_name: PathBuf, ignore_timestamp: bool) { - let test_output_path = build_dir().join(test_name); - let relative_reference_file_path = reference_file_path.strip_prefix(clippy_project_root()).unwrap(); +fn update_reference_file(test_output_entry: &DirEntry, ignore_timestamp: bool) { + let test_output_path = test_output_entry.path(); - // If compiletest did not write any changes during the test run, - // we don't have to update anything - if !test_output_path.exists() { - return; - } + let reference_file_name = test_output_entry.file_name().to_str().unwrap().replace(".stage-id", ""); + let reference_file_path = Path::new("tests") + .join(test_output_path.strip_prefix(build_dir()).unwrap()) + .with_file_name(reference_file_name); // If the test output was not updated since the last clippy build, it may be outdated - if !ignore_timestamp && !updated_since_clippy_build(&test_output_path).unwrap_or(true) { + if !ignore_timestamp && !updated_since_clippy_build(test_output_entry).unwrap_or(true) { return; } @@ -69,23 +49,14 @@ fn update_reference_file(reference_file_path: PathBuf, test_name: PathBuf, ignor if test_output_file != reference_file { // If a test run caused an output file to change, update the reference file - println!("updating {}", &relative_reference_file_path.display()); + println!("updating {}", reference_file_path.display()); fs::copy(test_output_path, &reference_file_path).expect("Could not update reference file"); - - // We need to re-read the file now because it was potentially updated from copying - let reference_file = fs::read(&reference_file_path).unwrap_or_default(); - - if reference_file.is_empty() { - // If we copied over an empty output file, we remove the now empty reference file - println!("removing {}", &relative_reference_file_path.display()); - fs::remove_file(reference_file_path).expect("Could not remove reference file"); - } } } -fn updated_since_clippy_build(path: &Path) -> Option { +fn updated_since_clippy_build(entry: &DirEntry) -> Option { let clippy_build_time = (*CLIPPY_BUILD_TIME)?; - let modified = fs::metadata(path).ok()?.modified().ok()?; + let modified = entry.metadata().ok()?.modified().ok()?; Some(modified >= clippy_build_time) } diff --git a/tests/compile-test.rs b/tests/compile-test.rs index 6505028db9f..ab7e2540405 100644 --- a/tests/compile-test.rs +++ b/tests/compile-test.rs @@ -11,6 +11,7 @@ use std::env::{self, remove_var, set_var, var_os}; use std::ffi::{OsStr, OsString}; use std::fs; use std::io; +use std::lazy::SyncLazy; use std::path::{Path, PathBuf}; use test_utils::IS_RUSTC_TEST_SUITE; @@ -64,11 +65,11 @@ extern crate tokio; /// dependencies must be added to Cargo.toml at the project root. Test /// dependencies that are not *directly* used by this test module require an /// `extern crate` declaration. -fn extern_flags() -> String { +static EXTERN_FLAGS: SyncLazy = SyncLazy::new(|| { let current_exe_depinfo = { let mut path = env::current_exe().unwrap(); path.set_extension("d"); - std::fs::read_to_string(path).unwrap() + fs::read_to_string(path).unwrap() }; let mut crates: HashMap<&str, &str> = HashMap::with_capacity(TEST_DEPENDENCIES.len()); for line in current_exe_depinfo.lines() { @@ -112,16 +113,17 @@ fn extern_flags() -> String { .into_iter() .map(|(name, path)| format!(" --extern {}={}", name, path)) .collect() -} +}); -fn default_config() -> compiletest::Config { +fn base_config(test_dir: &str) -> compiletest::Config { let mut config = compiletest::Config { edition: Some("2021".into()), + mode: TestMode::Ui, ..compiletest::Config::default() }; if let Ok(filters) = env::var("TESTNAME") { - config.filters = filters.split(',').map(std::string::ToString::to_string).collect(); + config.filters = filters.split(',').map(ToString::to_string).collect(); } if let Some(path) = option_env!("RUSTC_LIB_PATH") { @@ -129,7 +131,7 @@ fn default_config() -> compiletest::Config { config.run_lib_path = path.clone(); config.compile_lib_path = path; } - let current_exe_path = std::env::current_exe().unwrap(); + let current_exe_path = env::current_exe().unwrap(); let deps_path = current_exe_path.parent().unwrap(); let profile_path = deps_path.parent().unwrap(); @@ -143,10 +145,11 @@ fn default_config() -> compiletest::Config { "--emit=metadata -Dwarnings -Zui-testing -L dependency={}{}{}", deps_path.display(), host_libs, - extern_flags(), + &*EXTERN_FLAGS, )); - config.build_base = profile_path.join("test"); + config.src_base = Path::new("tests").join(test_dir); + config.build_base = profile_path.join("test").join(test_dir); config.rustc_path = profile_path.join(if cfg!(windows) { "clippy-driver.exe" } else { @@ -155,38 +158,31 @@ fn default_config() -> compiletest::Config { config } -fn run_ui(cfg: &mut compiletest::Config) { - cfg.mode = TestMode::Ui; - cfg.src_base = Path::new("tests").join("ui"); +fn run_ui() { + let config = base_config("ui"); // use tests/clippy.toml - let _g = VarGuard::set("CARGO_MANIFEST_DIR", std::fs::canonicalize("tests").unwrap()); - compiletest::run_tests(cfg); + let _g = VarGuard::set("CARGO_MANIFEST_DIR", fs::canonicalize("tests").unwrap()); + compiletest::run_tests(&config); } -fn run_ui_test(cfg: &mut compiletest::Config) { - cfg.mode = TestMode::Ui; - cfg.src_base = Path::new("tests").join("ui_test"); - let _g = VarGuard::set("CARGO_MANIFEST_DIR", std::fs::canonicalize("tests").unwrap()); - let rustcflags = cfg.target_rustcflags.get_or_insert_with(Default::default); - let len = rustcflags.len(); +fn run_ui_test() { + let mut config = base_config("ui_test"); + let _g = VarGuard::set("CARGO_MANIFEST_DIR", fs::canonicalize("tests").unwrap()); + let rustcflags = config.target_rustcflags.get_or_insert_with(Default::default); rustcflags.push_str(" --test"); - compiletest::run_tests(cfg); - if let Some(ref mut flags) = &mut cfg.target_rustcflags { - flags.truncate(len); - } + compiletest::run_tests(&config); } -fn run_internal_tests(cfg: &mut compiletest::Config) { +fn run_internal_tests() { // only run internal tests with the internal-tests feature if !RUN_INTERNAL_TESTS { return; } - cfg.mode = TestMode::Ui; - cfg.src_base = Path::new("tests").join("ui-internal"); - compiletest::run_tests(cfg); + let config = base_config("ui-internal"); + compiletest::run_tests(&config); } -fn run_ui_toml(config: &mut compiletest::Config) { +fn run_ui_toml() { fn run_tests(config: &compiletest::Config, mut tests: Vec) -> Result { let mut result = true; let opts = compiletest::test_opts(config); @@ -222,12 +218,12 @@ fn run_ui_toml(config: &mut compiletest::Config) { Ok(result) } - config.mode = TestMode::Ui; - config.src_base = Path::new("tests").join("ui-toml").canonicalize().unwrap(); + let mut config = base_config("ui-toml"); + config.src_base = config.src_base.canonicalize().unwrap(); - let tests = compiletest::make_tests(config); + let tests = compiletest::make_tests(&config); - let res = run_tests(config, tests); + let res = run_tests(&config, tests); match res { Ok(true) => {}, Ok(false) => panic!("Some tests failed"), @@ -237,7 +233,7 @@ fn run_ui_toml(config: &mut compiletest::Config) { } } -fn run_ui_cargo(config: &mut compiletest::Config) { +fn run_ui_cargo() { fn run_tests( config: &compiletest::Config, filters: &[String], @@ -310,13 +306,13 @@ fn run_ui_cargo(config: &mut compiletest::Config) { return; } - config.mode = TestMode::Ui; - config.src_base = Path::new("tests").join("ui-cargo").canonicalize().unwrap(); + let mut config = base_config("ui-cargo"); + config.src_base = config.src_base.canonicalize().unwrap(); - let tests = compiletest::make_tests(config); + let tests = compiletest::make_tests(&config); let current_dir = env::current_dir().unwrap(); - let res = run_tests(config, &config.filters, tests); + let res = run_tests(&config, &config.filters, tests); env::set_current_dir(current_dir).unwrap(); match res { @@ -331,12 +327,11 @@ fn run_ui_cargo(config: &mut compiletest::Config) { #[test] fn compile_test() { set_var("CLIPPY_DISABLE_DOCS_LINKS", "true"); - let mut config = default_config(); - run_ui(&mut config); - run_ui_test(&mut config); - run_ui_toml(&mut config); - run_ui_cargo(&mut config); - run_internal_tests(&mut config); + run_ui(); + run_ui_test(); + run_ui_toml(); + run_ui_cargo(); + run_internal_tests(); } /// Restores an env var on drop diff --git a/tests/ui/non_expressive_names.stdout b/tests/ui/non_expressive_names.stdout deleted file mode 100644 index e69de29bb2d..00000000000 -- cgit 1.4.1-3-g733a5 From 9a02386fd8f95303c4319bb3a18f8777e7908bcb Mon Sep 17 00:00:00 2001 From: Alex Macleod Date: Tue, 29 Mar 2022 18:36:38 +0100 Subject: Allow running `cargo dev lint` on a package directory --- clippy_dev/Cargo.toml | 1 + clippy_dev/src/bless.rs | 13 +++------- clippy_dev/src/lib.rs | 13 ++++++++++ clippy_dev/src/lint.rs | 63 +++++++++++++++++++++++++++++++++++++------------ clippy_dev/src/main.rs | 20 ++++++++++++---- 5 files changed, 80 insertions(+), 30 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/Cargo.toml b/clippy_dev/Cargo.toml index d133e8cddab..449ab1e9c7a 100644 --- a/clippy_dev/Cargo.toml +++ b/clippy_dev/Cargo.toml @@ -11,6 +11,7 @@ itertools = "0.10.1" opener = "0.5" regex = "1.5" shell-escape = "0.1" +tempfile = "3.3" walkdir = "2.3" cargo_metadata = "0.14" diff --git a/clippy_dev/src/bless.rs b/clippy_dev/src/bless.rs index b0fb39e8169..8e5c739afe0 100644 --- a/clippy_dev/src/bless.rs +++ b/clippy_dev/src/bless.rs @@ -1,22 +1,15 @@ //! `bless` updates the reference files in the repo with changed output files //! from the last test run. +use crate::cargo_clippy_path; use std::ffi::OsStr; use std::fs; use std::lazy::SyncLazy; use std::path::{Path, PathBuf}; use walkdir::{DirEntry, WalkDir}; -#[cfg(not(windows))] -static CARGO_CLIPPY_EXE: &str = "cargo-clippy"; -#[cfg(windows)] -static CARGO_CLIPPY_EXE: &str = "cargo-clippy.exe"; - -static CLIPPY_BUILD_TIME: SyncLazy> = SyncLazy::new(|| { - let mut path = std::env::current_exe().unwrap(); - path.set_file_name(CARGO_CLIPPY_EXE); - fs::metadata(path).ok()?.modified().ok() -}); +static CLIPPY_BUILD_TIME: SyncLazy> = + SyncLazy::new(|| cargo_clippy_path().metadata().ok()?.modified().ok()); /// # Panics /// diff --git a/clippy_dev/src/lib.rs b/clippy_dev/src/lib.rs index 59fde447547..72d01db2738 100644 --- a/clippy_dev/src/lib.rs +++ b/clippy_dev/src/lib.rs @@ -13,6 +13,19 @@ pub mod serve; pub mod setup; pub mod update_lints; +#[cfg(not(windows))] +static CARGO_CLIPPY_EXE: &str = "cargo-clippy"; +#[cfg(windows)] +static CARGO_CLIPPY_EXE: &str = "cargo-clippy.exe"; + +/// Returns the path to the `cargo-clippy` binary +#[must_use] +pub fn cargo_clippy_path() -> PathBuf { + let mut path = std::env::current_exe().expect("failed to get current executable name"); + path.set_file_name(CARGO_CLIPPY_EXE); + path +} + /// Returns the path to the Clippy project directory /// /// # Panics diff --git a/clippy_dev/src/lint.rs b/clippy_dev/src/lint.rs index b8287980a4b..1bc1a39542d 100644 --- a/clippy_dev/src/lint.rs +++ b/clippy_dev/src/lint.rs @@ -1,19 +1,52 @@ -use std::process::{self, Command}; +use crate::cargo_clippy_path; +use std::process::{self, Command, ExitStatus}; +use std::{fs, io}; -pub fn run(filename: &str) { - let code = Command::new("cargo") - .args(["run", "--bin", "clippy-driver", "--"]) - .args(["-L", "./target/debug"]) - .args(["-Z", "no-codegen"]) - .args(["--edition", "2021"]) - .arg(filename) - .status() - .expect("failed to run cargo") - .code(); - - if code.is_none() { - eprintln!("Killed by signal"); +fn exit_if_err(status: io::Result) { + match status.expect("failed to run command").code() { + Some(0) => {}, + Some(n) => process::exit(n), + None => { + eprintln!("Killed by signal"); + process::exit(1); + }, } +} + +pub fn run(path: &str) { + let is_file = match fs::metadata(path) { + Ok(metadata) => metadata.is_file(), + Err(e) => { + eprintln!("Failed to read {path}: {e:?}"); + process::exit(1); + }, + }; + + if is_file { + exit_if_err( + Command::new("cargo") + .args(["run", "--bin", "clippy-driver", "--"]) + .args(["-L", "./target/debug"]) + .args(["-Z", "no-codegen"]) + .args(["--edition", "2021"]) + .arg(path) + .status(), + ); + } else { + exit_if_err(Command::new("cargo").arg("build").status()); - process::exit(code.unwrap_or(1)); + // Run in a tempdir as changes to clippy do not retrigger linting + let target = tempfile::Builder::new() + .prefix("clippy") + .tempdir() + .expect("failed to create tempdir"); + + let status = Command::new(cargo_clippy_path()) + .current_dir(path) + .env("CARGO_TARGET_DIR", target.as_ref()) + .status(); + + target.close().expect("failed to remove tempdir"); + exit_if_err(status); + } } diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index 30a241c8ba1..b1fe35a0243 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -4,6 +4,7 @@ use clap::{App, AppSettings, Arg, ArgMatches, SubCommand}; use clippy_dev::{bless, fmt, lint, new_lint, serve, setup, update_lints}; +use indoc::indoc; fn main() { let matches = get_clap_config(); @@ -56,8 +57,8 @@ fn main() { serve::run(port, lint); }, ("lint", Some(matches)) => { - let filename = matches.value_of("filename").unwrap(); - lint::run(filename); + let path = matches.value_of("path").unwrap(); + lint::run(path); }, _ => {}, } @@ -225,11 +226,20 @@ fn get_clap_config<'a>() -> ArgMatches<'a> { ) .subcommand( SubCommand::with_name("lint") - .about("Manually run clippy on a file") + .about("Manually run clippy on a file or package") + .after_help(indoc! {" + EXAMPLES + Lint a single file: + cargo dev lint tests/ui/attrs.rs + + Lint a package directory: + cargo dev lint tests/ui-cargo/wildcard_dependencies/fail + cargo dev lint ~/my-project + "}) .arg( - Arg::with_name("filename") + Arg::with_name("path") .required(true) - .help("The path to a file to lint"), + .help("The path to a file or package directory to lint"), ), ) .get_matches() -- cgit 1.4.1-3-g733a5 From b3f8415032a4b86f72aa7a99c7fe62a25c302927 Mon Sep 17 00:00:00 2001 From: Jason Newcomb Date: Mon, 28 Mar 2022 22:08:04 -0400 Subject: Remove regex dependency from clippy_dev --- clippy_dev/Cargo.toml | 6 +- clippy_dev/src/lib.rs | 3 + clippy_dev/src/update_lints.rs | 651 +++++++++++++++++------------------------ 3 files changed, 279 insertions(+), 381 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/Cargo.toml b/clippy_dev/Cargo.toml index d133e8cddab..80423ea624f 100644 --- a/clippy_dev/Cargo.toml +++ b/clippy_dev/Cargo.toml @@ -9,10 +9,14 @@ clap = "2.33" indoc = "1.0" itertools = "0.10.1" opener = "0.5" -regex = "1.5" shell-escape = "0.1" walkdir = "2.3" cargo_metadata = "0.14" + [features] deny-warnings = [] + +[package.metadata.rust-analyzer] +# This package uses #[feature(rustc_private)] +rustc_private = true diff --git a/clippy_dev/src/lib.rs b/clippy_dev/src/lib.rs index 59fde447547..f9e0f2ff69c 100644 --- a/clippy_dev/src/lib.rs +++ b/clippy_dev/src/lib.rs @@ -1,8 +1,11 @@ #![feature(once_cell)] +#![feature(rustc_private)] #![cfg_attr(feature = "deny-warnings", deny(warnings))] // warn on lints, that are included in `rust-lang/rust`s bootstrap #![warn(rust_2018_idioms, unused_lifetimes)] +extern crate rustc_lexer; + use std::path::PathBuf; pub mod bless; diff --git a/clippy_dev/src/update_lints.rs b/clippy_dev/src/update_lints.rs index d368ef1f46a..4e48b670457 100644 --- a/clippy_dev/src/update_lints.rs +++ b/clippy_dev/src/update_lints.rs @@ -1,9 +1,9 @@ +use core::fmt::Write; use itertools::Itertools; -use regex::Regex; +use rustc_lexer::{tokenize, unescape, LiteralKind, TokenKind}; use std::collections::HashMap; use std::ffi::OsStr; use std::fs; -use std::lazy::SyncLazy; use std::path::Path; use walkdir::WalkDir; @@ -13,35 +13,7 @@ const GENERATED_FILE_COMMENT: &str = "// This file was generated by `cargo dev u // Use that command to update this file and do not edit by hand.\n\ // Manual edits will be overwritten.\n\n"; -static DEC_CLIPPY_LINT_RE: SyncLazy = SyncLazy::new(|| { - Regex::new( - r#"(?x) - declare_clippy_lint!\s*[\{(] - (?:\s+///.*)* - (?:\s*\#\[clippy::version\s*=\s*"[^"]*"\])? - \s+pub\s+(?P[A-Z_][A-Z_0-9]*)\s*,\s* - (?P[a-z_]+)\s*,\s* - "(?P(?:[^"\\]+|\\(?s).(?-s))*)"\s*[})] -"#, - ) - .unwrap() -}); - -static DEC_DEPRECATED_LINT_RE: SyncLazy = SyncLazy::new(|| { - Regex::new( - r#"(?x) - declare_deprecated_lint!\s*[{(]\s* - (?:\s+///.*)* - (?:\s*\#\[clippy::version\s*=\s*"[^"]*"\])? - \s+pub\s+(?P[A-Z_][A-Z_0-9]*)\s*,\s* - "(?P(?:[^"\\]+|\\(?s).(?-s))*)"\s*[})] -"#, - ) - .unwrap() -}); -static NL_ESCAPE_RE: SyncLazy = SyncLazy::new(|| Regex::new(r#"\\\n\s*"#).unwrap()); - -static DOCS_LINK: &str = "https://rust-lang.github.io/rust-clippy/master/index.html"; +const DOCS_LINK: &str = "https://rust-lang.github.io/rust-clippy/master/index.html"; #[derive(Clone, Copy, PartialEq)] pub enum UpdateMode { @@ -60,60 +32,52 @@ pub enum UpdateMode { /// Panics if a file path could not read from or then written to #[allow(clippy::too_many_lines)] pub fn run(update_mode: UpdateMode) { - let lint_list: Vec = gather_all().collect(); + let (lints, deprecated_lints) = gather_all(); - let internal_lints = Lint::internal_lints(&lint_list); - let deprecated_lints = Lint::deprecated_lints(&lint_list); - let usable_lints = Lint::usable_lints(&lint_list); + let internal_lints = Lint::internal_lints(&lints); + let usable_lints = Lint::usable_lints(&lints); let mut sorted_usable_lints = usable_lints.clone(); sorted_usable_lints.sort_by_key(|lint| lint.name.clone()); - let usable_lint_count = round_to_fifty(usable_lints.len()); - - let mut file_change = false; - - file_change |= replace_region_in_file( + replace_region_in_file( + update_mode, Path::new("README.md"), - &format!( - r#"\[There are over \d+ lints included in this crate!\]\({}\)"#, - DOCS_LINK - ), - "", - true, - update_mode == UpdateMode::Change, - || { - vec![format!( - "[There are over {} lints included in this crate!]({})", - usable_lint_count, DOCS_LINK - )] + "[There are over ", + " lints included in this crate!]", + |res| { + write!(res, "{}", round_to_fifty(usable_lints.len())).unwrap(); }, - ) - .changed; + ); - file_change |= replace_region_in_file( + replace_region_in_file( + update_mode, Path::new("CHANGELOG.md"), - "", + "\n", "", - false, - update_mode == UpdateMode::Change, - || gen_changelog_lint_list(usable_lints.iter().chain(deprecated_lints.iter())), - ) - .changed; + |res| { + for lint in usable_lints + .iter() + .map(|l| &l.name) + .chain(deprecated_lints.iter().map(|l| &l.name)) + .sorted() + { + writeln!(res, "[`{}`]: {}#{}", lint, DOCS_LINK, lint).unwrap(); + } + }, + ); // This has to be in lib.rs, otherwise rustfmt doesn't work - file_change |= replace_region_in_file( + replace_region_in_file( + update_mode, Path::new("clippy_lints/src/lib.rs"), - "begin lints modules", - "end lints modules", - false, - update_mode == UpdateMode::Change, - || gen_modules_list(usable_lints.iter()), - ) - .changed; - - if file_change && update_mode == UpdateMode::Check { - exit_with_failure(); - } + "// begin lints modules, do not remove this comment, it’s used in `update_lints`\n", + "// end lints modules, do not remove this comment, it’s used in `update_lints`", + |res| { + for lint_mod in usable_lints.iter().map(|l| &l.module).unique().sorted() { + writeln!(res, "mod {};", lint_mod).unwrap(); + } + }, + ); process_file( "clippy_lints/src/lib.register_lints.rs", @@ -123,7 +87,7 @@ pub fn run(update_mode: UpdateMode) { process_file( "clippy_lints/src/lib.deprecated.rs", update_mode, - &gen_deprecated(deprecated_lints.iter()), + &gen_deprecated(&deprecated_lints), ); let all_group_lints = usable_lints.iter().filter(|l| { @@ -146,15 +110,12 @@ pub fn run(update_mode: UpdateMode) { } pub fn print_lints() { - let lint_list: Vec = gather_all().collect(); + let (lint_list, _) = gather_all(); let usable_lints = Lint::usable_lints(&lint_list); let usable_lint_count = usable_lints.len(); let grouped_by_lint_group = Lint::by_lint_group(usable_lints.into_iter()); for (lint_group, mut lints) in grouped_by_lint_group { - if lint_group == "Deprecated" { - continue; - } println!("\n## {}", lint_group); lints.sort_by_key(|l| l.name.clone()); @@ -198,19 +159,17 @@ struct Lint { name: String, group: String, desc: String, - deprecation: Option, module: String, } impl Lint { #[must_use] - fn new(name: &str, group: &str, desc: &str, deprecation: Option<&str>, module: &str) -> Self { + fn new(name: &str, group: &str, desc: &str, module: &str) -> Self { Self { name: name.to_lowercase(), - group: group.to_string(), - desc: NL_ESCAPE_RE.replace(&desc.replace("\\\"", "\""), "").to_string(), - deprecation: deprecation.map(ToString::to_string), - module: module.to_string(), + group: group.into(), + desc: remove_line_splices(desc), + module: module.into(), } } @@ -219,7 +178,7 @@ impl Lint { fn usable_lints(lints: &[Self]) -> Vec { lints .iter() - .filter(|l| l.deprecation.is_none() && !l.group.starts_with("internal")) + .filter(|l| !l.group.starts_with("internal")) .cloned() .collect() } @@ -230,12 +189,6 @@ impl Lint { lints.iter().filter(|l| l.group == "internal").cloned().collect() } - /// Returns all deprecated lints - #[must_use] - fn deprecated_lints(lints: &[Self]) -> Vec { - lints.iter().filter(|l| l.deprecation.is_some()).cloned().collect() - } - /// Returns the lints in a `HashMap`, grouped by the different lint groups #[must_use] fn by_lint_group(lints: impl Iterator) -> HashMap> { @@ -243,6 +196,20 @@ impl Lint { } } +#[derive(Clone, PartialEq, Debug)] +struct DeprecatedLint { + name: String, + reason: String, +} +impl DeprecatedLint { + fn new(name: &str, reason: &str) -> Self { + Self { + name: name.to_lowercase(), + reason: remove_line_splices(reason), + } + } +} + /// Generates the code for registering a group fn gen_lint_group_list<'a>(group_name: &str, lints: impl Iterator) -> String { let mut details: Vec<_> = lints.map(|l| (&l.module, l.name.to_uppercase())).collect(); @@ -262,32 +229,12 @@ fn gen_lint_group_list<'a>(group_name: &str, lints: impl Iterator(lints: impl Iterator) -> Vec { - lints - .map(|l| &l.module) - .unique() - .map(|module| format!("mod {};", module)) - .sorted() - .collect::>() -} - -/// Generates the list of lint links at the bottom of the CHANGELOG -#[must_use] -fn gen_changelog_lint_list<'a>(lints: impl Iterator) -> Vec { - lints - .sorted_by_key(|l| &l.name) - .map(|l| format!("[`{}`]: {}#{}", l.name, DOCS_LINK, l.name)) - .collect() -} - /// Generates the `register_removed` code #[must_use] -fn gen_deprecated<'a>(lints: impl Iterator) -> String { +fn gen_deprecated(lints: &[DeprecatedLint]) -> String { let mut output = GENERATED_FILE_COMMENT.to_string(); output.push_str("{\n"); - for Lint { name, deprecation, .. } in lints { + for lint in lints { output.push_str(&format!( concat!( " store.register_removed(\n", @@ -295,8 +242,7 @@ fn gen_deprecated<'a>(lints: impl Iterator) -> String { " \"{}\",\n", " );\n" ), - name, - deprecation.as_ref().expect("`lints` are deprecated") + lint.name, lint.reason, )); } output.push_str("}\n"); @@ -330,61 +276,133 @@ fn gen_register_lint_list<'a>( output } -/// Gathers all files in `src/clippy_lints` and gathers all lints inside -fn gather_all() -> impl Iterator { - lint_files().flat_map(|f| gather_from_file(&f)) -} +/// Gathers all lints defined in `clippy_lints/src` +fn gather_all() -> (Vec, Vec) { + let mut lints = Vec::with_capacity(1000); + let mut deprecated_lints = Vec::with_capacity(50); + let root_path = clippy_project_root().join("clippy_lints/src"); -fn gather_from_file(dir_entry: &walkdir::DirEntry) -> impl Iterator { - let content = fs::read_to_string(dir_entry.path()).unwrap(); - let path = dir_entry.path(); - let filename = path.file_stem().unwrap(); - let path_buf = path.with_file_name(filename); - let mut rel_path = path_buf - .strip_prefix(clippy_project_root().join("clippy_lints/src")) - .expect("only files in `clippy_lints/src` should be looked at"); - // If the lints are stored in mod.rs, we get the module name from - // the containing directory: - if filename == "mod" { - rel_path = rel_path.parent().unwrap(); - } + for (rel_path, file) in WalkDir::new(&root_path) + .into_iter() + .map(Result::unwrap) + .filter(|f| f.path().extension() == Some(OsStr::new("rs"))) + .map(|f| (f.path().strip_prefix(&root_path).unwrap().to_path_buf(), f)) + { + let path = file.path(); + let contents = + fs::read_to_string(path).unwrap_or_else(|e| panic!("Cannot read from `{}`: {}", path.display(), e)); + let module = rel_path + .components() + .map(|c| c.as_os_str().to_str().unwrap()) + .collect::>() + .join("::"); + + // If the lints are stored in mod.rs, we get the module name from + // the containing directory: + let module = if let Some(module) = module.strip_suffix("::mod.rs") { + module + } else { + module.strip_suffix(".rs").unwrap_or(&module) + }; - let module = rel_path - .components() - .map(|c| c.as_os_str().to_str().unwrap()) - .collect::>() - .join("::"); + if module == "deprecated_lints" { + parse_deprecated_contents(&contents, &mut deprecated_lints); + } else { + parse_contents(&contents, module, &mut lints); + } + } + (lints, deprecated_lints) +} - parse_contents(&content, &module) +macro_rules! match_tokens { + ($iter:ident, $($token:ident $({$($fields:tt)*})? $(($capture:ident))?)*) => { + { + $($(let $capture =)? if let Some((TokenKind::$token $({$($fields)*})?, _x)) = $iter.next() { + _x + } else { + continue; + };)* + #[allow(clippy::unused_unit)] + { ($($($capture,)?)*) } + } + } } -fn parse_contents(content: &str, module: &str) -> impl Iterator { - let lints = DEC_CLIPPY_LINT_RE - .captures_iter(content) - .map(|m| Lint::new(&m["name"], &m["cat"], &m["desc"], None, module)); - let deprecated = DEC_DEPRECATED_LINT_RE - .captures_iter(content) - .map(|m| Lint::new(&m["name"], "Deprecated", &m["desc"], Some(&m["desc"]), module)); - // Removing the `.collect::>().into_iter()` causes some lifetime issues due to the map - lints.chain(deprecated).collect::>().into_iter() +/// Parse a source file looking for `declare_clippy_lint` macro invocations. +fn parse_contents(contents: &str, module: &str, lints: &mut Vec) { + let mut offset = 0usize; + let mut iter = tokenize(contents).map(|t| { + let range = offset..offset + t.len; + offset = range.end; + (t.kind, &contents[range]) + }); + + while iter.any(|(kind, s)| kind == TokenKind::Ident && s == "declare_clippy_lint") { + let mut iter = iter + .by_ref() + .filter(|&(kind, _)| !matches!(kind, TokenKind::Whitespace | TokenKind::LineComment { .. })); + // matches `!{` + match_tokens!(iter, Bang OpenBrace); + match iter.next() { + // #[clippy::version = "version"] pub + Some((TokenKind::Pound, _)) => { + match_tokens!(iter, OpenBracket Ident Colon Colon Ident Eq Literal{..} CloseBracket Ident); + }, + // pub + Some((TokenKind::Ident, _)) => (), + _ => continue, + } + let (name, group, desc) = match_tokens!( + iter, + // LINT_NAME + Ident(name) Comma + // group, + Ident(group) Comma + // "description" } + Literal{kind: LiteralKind::Str{..}, ..}(desc) CloseBrace + ); + lints.push(Lint::new(name, group, desc, module)); + } } -/// Collects all .rs files in the `clippy_lints/src` directory -fn lint_files() -> impl Iterator { - // We use `WalkDir` instead of `fs::read_dir` here in order to recurse into subdirectories. - // Otherwise we would not collect all the lints, for example in `clippy_lints/src/methods/`. - let path = clippy_project_root().join("clippy_lints/src"); - WalkDir::new(path) - .into_iter() - .filter_map(Result::ok) - .filter(|f| f.path().extension() == Some(OsStr::new("rs"))) +/// Parse a source file looking for `declare_deprecated_lint` macro invocations. +fn parse_deprecated_contents(contents: &str, lints: &mut Vec) { + let mut offset = 0usize; + let mut iter = tokenize(contents).map(|t| { + let range = offset..offset + t.len; + offset = range.end; + (t.kind, &contents[range]) + }); + while iter.any(|(kind, s)| kind == TokenKind::Ident && s == "declare_deprecated_lint") { + let mut iter = iter + .by_ref() + .filter(|&(kind, _)| !matches!(kind, TokenKind::Whitespace | TokenKind::LineComment { .. })); + let (name, reason) = match_tokens!( + iter, + // !{ + Bang OpenBrace + // #[clippy::version = "version"] + Pound OpenBracket Ident Colon Colon Ident Eq Literal{..} CloseBracket + // pub LINT_NAME, + Ident Ident(name) Comma + // "description" + Literal{kind: LiteralKind::Str{..},..}(reason) + // } + CloseBrace + ); + lints.push(DeprecatedLint::new(name, reason)); + } } -/// Whether a file has had its text changed or not -#[derive(PartialEq, Debug)] -struct FileChange { - changed: bool, - new_lines: String, +/// Removes the line splices and surrounding quotes from a string literal +fn remove_line_splices(s: &str) -> String { + let s = s + .strip_prefix('"') + .and_then(|s| s.strip_suffix('"')) + .unwrap_or_else(|| panic!("expected quoted string, found `{}`", s)); + let mut res = String::with_capacity(s.len()); + unescape::unescape_literal(s, unescape::Mode::Str, &mut |range, _| res.push_str(&s[range])); + res } /// Replaces a region in a file delimited by two lines matching regexes. @@ -396,144 +414,49 @@ struct FileChange { /// # Panics /// /// Panics if the path could not read or then written -fn replace_region_in_file( +fn replace_region_in_file( + update_mode: UpdateMode, path: &Path, start: &str, end: &str, - replace_start: bool, - write_back: bool, - replacements: F, -) -> FileChange -where - F: FnOnce() -> Vec, -{ - let contents = fs::read_to_string(path).unwrap_or_else(|e| panic!("Cannot read from {}: {}", path.display(), e)); - let file_change = replace_region_in_text(&contents, start, end, replace_start, replacements); - - if write_back { - if let Err(e) = fs::write(path, file_change.new_lines.as_bytes()) { - panic!("Cannot write to {}: {}", path.display(), e); - } - } - file_change -} - -/// Replaces a region in a text delimited by two lines matching regexes. -/// -/// * `text` is the input text on which you want to perform the replacement -/// * `start` is a `&str` that describes the delimiter line before the region you want to replace. -/// As the `&str` will be converted to a `Regex`, this can contain regex syntax, too. -/// * `end` is a `&str` that describes the delimiter line until where the replacement should happen. -/// As the `&str` will be converted to a `Regex`, this can contain regex syntax, too. -/// * If `replace_start` is true, the `start` delimiter line is replaced as well. The `end` -/// delimiter line is never replaced. -/// * `replacements` is a closure that has to return a `Vec` which contains the new text. -/// -/// If you want to perform the replacement on files instead of already parsed text, -/// use `replace_region_in_file`. -/// -/// # Example -/// -/// ```ignore -/// let the_text = "replace_start\nsome text\nthat will be replaced\nreplace_end"; -/// let result = -/// replace_region_in_text(the_text, "replace_start", "replace_end", false, || { -/// vec!["a different".to_string(), "text".to_string()] -/// }) -/// .new_lines; -/// assert_eq!("replace_start\na different\ntext\nreplace_end", result); -/// ``` -/// -/// # Panics -/// -/// Panics if start or end is not valid regex -fn replace_region_in_text(text: &str, start: &str, end: &str, replace_start: bool, replacements: F) -> FileChange -where - F: FnOnce() -> Vec, -{ - let replace_it = replacements(); - let mut in_old_region = false; - let mut found = false; - let mut new_lines = vec![]; - let start = Regex::new(start).unwrap(); - let end = Regex::new(end).unwrap(); - - for line in text.lines() { - if in_old_region { - if end.is_match(line) { - in_old_region = false; - new_lines.extend(replace_it.clone()); - new_lines.push(line.to_string()); - } - } else if start.is_match(line) { - if !replace_start { - new_lines.push(line.to_string()); + write_replacement: impl FnMut(&mut String), +) { + let contents = fs::read_to_string(path).unwrap_or_else(|e| panic!("Cannot read from `{}`: {}", path.display(), e)); + let new_contents = match replace_region_in_text(&contents, start, end, write_replacement) { + Ok(x) => x, + Err(delim) => panic!("Couldn't find `{}` in file `{}`", delim, path.display()), + }; + + match update_mode { + UpdateMode::Check if contents != new_contents => exit_with_failure(), + UpdateMode::Check => (), + UpdateMode::Change => { + if let Err(e) = fs::write(path, new_contents.as_bytes()) { + panic!("Cannot write to `{}`: {}", path.display(), e); } - in_old_region = true; - found = true; - } else { - new_lines.push(line.to_string()); - } - } - - if !found { - // This happens if the provided regex in `clippy_dev/src/main.rs` does not match in the - // given text or file. Most likely this is an error on the programmer's side and the Regex - // is incorrect. - eprintln!("error: regex \n{:?}\ndoesn't match. You may have to update it.", start); - std::process::exit(1); - } - - let mut new_lines = new_lines.join("\n"); - if text.ends_with('\n') { - new_lines.push('\n'); + }, } - let changed = new_lines != text; - FileChange { changed, new_lines } -} - -#[test] -fn test_parse_contents() { - let result: Vec = parse_contents( - r#" -declare_clippy_lint! { - #[clippy::version = "Hello Clippy!"] - pub PTR_ARG, - style, - "really long \ - text" } -declare_clippy_lint!{ - #[clippy::version = "Test version"] - pub DOC_MARKDOWN, - pedantic, - "single line" -} - -/// some doc comment -declare_deprecated_lint! { - #[clippy::version = "I'm a version"] - pub SHOULD_ASSERT_EQ, - "`assert!()` will be more flexible with RFC 2011" -} - "#, - "module_name", - ) - .collect(); - - let expected = vec![ - Lint::new("ptr_arg", "style", "really long text", None, "module_name"), - Lint::new("doc_markdown", "pedantic", "single line", None, "module_name"), - Lint::new( - "should_assert_eq", - "Deprecated", - "`assert!()` will be more flexible with RFC 2011", - Some("`assert!()` will be more flexible with RFC 2011"), - "module_name", - ), - ]; - assert_eq!(expected, result); +/// Replaces a region in a text delimited by two strings. Returns the new text if both delimiters +/// were found, or the missing delimiter if not. +fn replace_region_in_text<'a>( + text: &str, + start: &'a str, + end: &'a str, + mut write_replacement: impl FnMut(&mut String), +) -> Result { + let (text_start, rest) = text.split_once(start).ok_or(start)?; + let (_, text_end) = rest.split_once(end).ok_or(end)?; + + let mut res = String::with_capacity(text.len() + 4096); + res.push_str(text_start); + res.push_str(start); + write_replacement(&mut res); + res.push_str(end); + res.push_str(text_end); + + Ok(res) } #[cfg(test)] @@ -541,55 +464,65 @@ mod tests { use super::*; #[test] - fn test_replace_region() { - let text = "\nabc\n123\n789\ndef\nghi"; - let expected = FileChange { - changed: true, - new_lines: "\nabc\nhello world\ndef\nghi".to_string(), - }; - let result = replace_region_in_text(text, r#"^\s*abc$"#, r#"^\s*def"#, false, || { - vec!["hello world".to_string()] - }); - assert_eq!(expected, result); - } + fn test_parse_contents() { + static CONTENTS: &str = r#" + declare_clippy_lint! { + #[clippy::version = "Hello Clippy!"] + pub PTR_ARG, + style, + "really long \ + text" + } - #[test] - fn test_replace_region_with_start() { - let text = "\nabc\n123\n789\ndef\nghi"; - let expected = FileChange { - changed: true, - new_lines: "\nhello world\ndef\nghi".to_string(), - }; - let result = replace_region_in_text(text, r#"^\s*abc$"#, r#"^\s*def"#, true, || { - vec!["hello world".to_string()] - }); + declare_clippy_lint!{ + #[clippy::version = "Test version"] + pub DOC_MARKDOWN, + pedantic, + "single line" + } + "#; + let mut result = Vec::new(); + parse_contents(CONTENTS, "module_name", &mut result); + + let expected = vec![ + Lint::new("ptr_arg", "style", "\"really long text\"", "module_name"), + Lint::new("doc_markdown", "pedantic", "\"single line\"", "module_name"), + ]; assert_eq!(expected, result); } #[test] - fn test_replace_region_no_changes() { - let text = "123\n456\n789"; - let expected = FileChange { - changed: false, - new_lines: "123\n456\n789".to_string(), - }; - let result = replace_region_in_text(text, r#"^\s*123$"#, r#"^\s*456"#, false, Vec::new); + fn test_parse_deprecated_contents() { + static DEPRECATED_CONTENTS: &str = r#" + /// some doc comment + declare_deprecated_lint! { + #[clippy::version = "I'm a version"] + pub SHOULD_ASSERT_EQ, + "`assert!()` will be more flexible with RFC 2011" + } + "#; + + let mut result = Vec::new(); + parse_deprecated_contents(DEPRECATED_CONTENTS, &mut result); + + let expected = vec![DeprecatedLint::new( + "should_assert_eq", + "\"`assert!()` will be more flexible with RFC 2011\"", + )]; assert_eq!(expected, result); } #[test] fn test_usable_lints() { let lints = vec![ - Lint::new("should_assert_eq", "Deprecated", "abc", Some("Reason"), "module_name"), - Lint::new("should_assert_eq2", "Not Deprecated", "abc", None, "module_name"), - Lint::new("should_assert_eq2", "internal", "abc", None, "module_name"), - Lint::new("should_assert_eq2", "internal_style", "abc", None, "module_name"), + Lint::new("should_assert_eq2", "Not Deprecated", "\"abc\"", "module_name"), + Lint::new("should_assert_eq2", "internal", "\"abc\"", "module_name"), + Lint::new("should_assert_eq2", "internal_style", "\"abc\"", "module_name"), ]; let expected = vec![Lint::new( "should_assert_eq2", "Not Deprecated", - "abc", - None, + "\"abc\"", "module_name", )]; assert_eq!(expected, Lint::usable_lints(&lints)); @@ -598,55 +531,30 @@ mod tests { #[test] fn test_by_lint_group() { let lints = vec![ - Lint::new("should_assert_eq", "group1", "abc", None, "module_name"), - Lint::new("should_assert_eq2", "group2", "abc", None, "module_name"), - Lint::new("incorrect_match", "group1", "abc", None, "module_name"), + Lint::new("should_assert_eq", "group1", "\"abc\"", "module_name"), + Lint::new("should_assert_eq2", "group2", "\"abc\"", "module_name"), + Lint::new("incorrect_match", "group1", "\"abc\"", "module_name"), ]; let mut expected: HashMap> = HashMap::new(); expected.insert( "group1".to_string(), vec![ - Lint::new("should_assert_eq", "group1", "abc", None, "module_name"), - Lint::new("incorrect_match", "group1", "abc", None, "module_name"), + Lint::new("should_assert_eq", "group1", "\"abc\"", "module_name"), + Lint::new("incorrect_match", "group1", "\"abc\"", "module_name"), ], ); expected.insert( "group2".to_string(), - vec![Lint::new("should_assert_eq2", "group2", "abc", None, "module_name")], + vec![Lint::new("should_assert_eq2", "group2", "\"abc\"", "module_name")], ); assert_eq!(expected, Lint::by_lint_group(lints.into_iter())); } - #[test] - fn test_gen_changelog_lint_list() { - let lints = vec![ - Lint::new("should_assert_eq", "group1", "abc", None, "module_name"), - Lint::new("should_assert_eq2", "group2", "abc", None, "module_name"), - ]; - let expected = vec![ - format!("[`should_assert_eq`]: {}#should_assert_eq", DOCS_LINK), - format!("[`should_assert_eq2`]: {}#should_assert_eq2", DOCS_LINK), - ]; - assert_eq!(expected, gen_changelog_lint_list(lints.iter())); - } - #[test] fn test_gen_deprecated() { let lints = vec![ - Lint::new( - "should_assert_eq", - "group1", - "abc", - Some("has been superseded by should_assert_eq2"), - "module_name", - ), - Lint::new( - "another_deprecated", - "group2", - "abc", - Some("will be removed"), - "module_name", - ), + DeprecatedLint::new("should_assert_eq", "\"has been superseded by should_assert_eq2\""), + DeprecatedLint::new("another_deprecated", "\"will be removed\""), ]; let expected = GENERATED_FILE_COMMENT.to_string() @@ -665,32 +573,15 @@ mod tests { .join("\n") + "\n"; - assert_eq!(expected, gen_deprecated(lints.iter())); - } - - #[test] - #[should_panic] - fn test_gen_deprecated_fail() { - let lints = vec![Lint::new("should_assert_eq2", "group2", "abc", None, "module_name")]; - let _deprecated_lints = gen_deprecated(lints.iter()); - } - - #[test] - fn test_gen_modules_list() { - let lints = vec![ - Lint::new("should_assert_eq", "group1", "abc", None, "module_name"), - Lint::new("incorrect_stuff", "group3", "abc", None, "another_module"), - ]; - let expected = vec!["mod another_module;".to_string(), "mod module_name;".to_string()]; - assert_eq!(expected, gen_modules_list(lints.iter())); + assert_eq!(expected, gen_deprecated(&lints)); } #[test] fn test_gen_lint_group_list() { let lints = vec![ - Lint::new("abc", "group1", "abc", None, "module_name"), - Lint::new("should_assert_eq", "group1", "abc", None, "module_name"), - Lint::new("internal", "internal_style", "abc", None, "module_name"), + Lint::new("abc", "group1", "\"abc\"", "module_name"), + Lint::new("should_assert_eq", "group1", "\"abc\"", "module_name"), + Lint::new("internal", "internal_style", "\"abc\"", "module_name"), ]; let expected = GENERATED_FILE_COMMENT.to_string() + &[ -- cgit 1.4.1-3-g733a5 From 7025283f3ec649f0041c81a7e8269d38e0fc21ba Mon Sep 17 00:00:00 2001 From: Jason Newcomb Date: Tue, 29 Mar 2022 08:32:12 -0400 Subject: Remove cargo_metadata dependency from clippy_dev --- clippy_dev/Cargo.toml | 3 --- clippy_dev/src/lib.rs | 1 + clippy_dev/src/new_lint.rs | 24 ++++++++++++++++-------- 3 files changed, 17 insertions(+), 11 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/Cargo.toml b/clippy_dev/Cargo.toml index 80423ea624f..1f2d8adecee 100644 --- a/clippy_dev/Cargo.toml +++ b/clippy_dev/Cargo.toml @@ -4,15 +4,12 @@ version = "0.0.1" edition = "2021" [dependencies] -bytecount = "0.6" clap = "2.33" indoc = "1.0" itertools = "0.10.1" opener = "0.5" shell-escape = "0.1" walkdir = "2.3" -cargo_metadata = "0.14" - [features] deny-warnings = [] diff --git a/clippy_dev/src/lib.rs b/clippy_dev/src/lib.rs index f9e0f2ff69c..414b403827d 100644 --- a/clippy_dev/src/lib.rs +++ b/clippy_dev/src/lib.rs @@ -1,3 +1,4 @@ +#![feature(let_else)] #![feature(once_cell)] #![feature(rustc_private)] #![cfg_attr(feature = "deny-warnings", deny(warnings))] diff --git a/clippy_dev/src/new_lint.rs b/clippy_dev/src/new_lint.rs index 59658b42c79..7a3fd131761 100644 --- a/clippy_dev/src/new_lint.rs +++ b/clippy_dev/src/new_lint.rs @@ -133,15 +133,23 @@ fn to_camel_case(name: &str) -> String { } fn get_stabilisation_version() -> String { - let mut command = cargo_metadata::MetadataCommand::new(); - command.no_deps(); - if let Ok(metadata) = command.exec() { - if let Some(pkg) = metadata.packages.iter().find(|pkg| pkg.name == "clippy") { - return format!("{}.{}.0", pkg.version.minor, pkg.version.patch); - } + fn parse_manifest(contents: &str) -> Option { + let version = contents + .lines() + .filter_map(|l| l.split_once('=')) + .find_map(|(k, v)| (k.trim() == "version").then(|| v.trim()))?; + let Some(("0", version)) = version.get(1..version.len() - 1)?.split_once('.') else { + return None; + }; + let (minor, patch) = version.split_once('.')?; + Some(format!( + "{}.{}.0", + minor.parse::().ok()?, + patch.parse::().ok()? + )) } - - String::from("") + let contents = fs::read_to_string("Cargo.toml").expect("Unable to read `Cargo.toml`"); + parse_manifest(&contents).expect("Unable to find package version in `Cargo.toml`") } fn get_test_file_contents(lint_name: &str, header_commands: Option<&str>) -> String { -- cgit 1.4.1-3-g733a5 From 422741151359b8ad4b4f1f4a545aef27f5722c82 Mon Sep 17 00:00:00 2001 From: Jason Newcomb Date: Sat, 2 Apr 2022 16:57:09 -0400 Subject: Generate deprecated lints test --- clippy_dev/src/update_lints.rs | 12 ++++++++++++ tests/ui/deprecated.rs | 4 ++++ tests/ui/deprecated.stderr | 32 ++++++++++++++++---------------- 3 files changed, 32 insertions(+), 16 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/update_lints.rs b/clippy_dev/src/update_lints.rs index 4e48b670457..b010149626c 100644 --- a/clippy_dev/src/update_lints.rs +++ b/clippy_dev/src/update_lints.rs @@ -107,6 +107,9 @@ pub fn run(update_mode: UpdateMode) { &content, ); } + + let content = gen_deprecated_lints_test(&deprecated_lints); + process_file("tests/ui/deprecated.rs", update_mode, &content); } pub fn print_lints() { @@ -276,6 +279,15 @@ fn gen_register_lint_list<'a>( output } +fn gen_deprecated_lints_test(lints: &[DeprecatedLint]) -> String { + let mut res: String = GENERATED_FILE_COMMENT.into(); + for lint in lints { + writeln!(res, "#![warn(clippy::{})]", lint.name).unwrap(); + } + res.push_str("\nfn main() {}\n"); + res +} + /// Gathers all lints defined in `clippy_lints/src` fn gather_all() -> (Vec, Vec) { let mut lints = Vec::with_capacity(1000); diff --git a/tests/ui/deprecated.rs b/tests/ui/deprecated.rs index 39a2601fee9..07270bd7636 100644 --- a/tests/ui/deprecated.rs +++ b/tests/ui/deprecated.rs @@ -1,3 +1,7 @@ +// This file was generated by `cargo dev update_lints`. +// Use that command to update this file and do not edit by hand. +// Manual edits will be overwritten. + #![warn(clippy::should_assert_eq)] #![warn(clippy::extend_from_slice)] #![warn(clippy::range_step_by_zero)] diff --git a/tests/ui/deprecated.stderr b/tests/ui/deprecated.stderr index 6095f134d55..0e142ac8f20 100644 --- a/tests/ui/deprecated.stderr +++ b/tests/ui/deprecated.stderr @@ -1,5 +1,5 @@ error: lint `clippy::should_assert_eq` has been removed: `assert!()` will be more flexible with RFC 2011 - --> $DIR/deprecated.rs:1:9 + --> $DIR/deprecated.rs:5:9 | LL | #![warn(clippy::should_assert_eq)] | ^^^^^^^^^^^^^^^^^^^^^^^^ @@ -7,91 +7,91 @@ LL | #![warn(clippy::should_assert_eq)] = note: `-D renamed-and-removed-lints` implied by `-D warnings` error: lint `clippy::extend_from_slice` has been removed: `.extend_from_slice(_)` is a faster way to extend a Vec by a slice - --> $DIR/deprecated.rs:2:9 + --> $DIR/deprecated.rs:6:9 | LL | #![warn(clippy::extend_from_slice)] | ^^^^^^^^^^^^^^^^^^^^^^^^^ error: lint `clippy::range_step_by_zero` has been removed: `iterator.step_by(0)` panics nowadays - --> $DIR/deprecated.rs:3:9 + --> $DIR/deprecated.rs:7:9 | LL | #![warn(clippy::range_step_by_zero)] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ error: lint `clippy::unstable_as_slice` has been removed: `Vec::as_slice` has been stabilized in 1.7 - --> $DIR/deprecated.rs:4:9 + --> $DIR/deprecated.rs:8:9 | LL | #![warn(clippy::unstable_as_slice)] | ^^^^^^^^^^^^^^^^^^^^^^^^^ error: lint `clippy::unstable_as_mut_slice` has been removed: `Vec::as_mut_slice` has been stabilized in 1.7 - --> $DIR/deprecated.rs:5:9 + --> $DIR/deprecated.rs:9:9 | LL | #![warn(clippy::unstable_as_mut_slice)] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ error: lint `clippy::misaligned_transmute` has been removed: this lint has been split into cast_ptr_alignment and transmute_ptr_to_ptr - --> $DIR/deprecated.rs:6:9 + --> $DIR/deprecated.rs:10:9 | LL | #![warn(clippy::misaligned_transmute)] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ error: lint `clippy::assign_ops` has been removed: using compound assignment operators (e.g., `+=`) is harmless - --> $DIR/deprecated.rs:7:9 + --> $DIR/deprecated.rs:11:9 | LL | #![warn(clippy::assign_ops)] | ^^^^^^^^^^^^^^^^^^ error: lint `clippy::if_let_redundant_pattern_matching` has been removed: this lint has been changed to redundant_pattern_matching - --> $DIR/deprecated.rs:8:9 + --> $DIR/deprecated.rs:12:9 | LL | #![warn(clippy::if_let_redundant_pattern_matching)] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ error: lint `clippy::unsafe_vector_initialization` has been removed: the replacement suggested by this lint had substantially different behavior - --> $DIR/deprecated.rs:9:9 + --> $DIR/deprecated.rs:13:9 | LL | #![warn(clippy::unsafe_vector_initialization)] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ error: lint `clippy::unused_collect` has been removed: `collect` has been marked as #[must_use] in rustc and that covers all cases of this lint - --> $DIR/deprecated.rs:10:9 + --> $DIR/deprecated.rs:14:9 | LL | #![warn(clippy::unused_collect)] | ^^^^^^^^^^^^^^^^^^^^^^ error: lint `clippy::replace_consts` has been removed: associated-constants `MIN`/`MAX` of integers are preferred to `{min,max}_value()` and module constants - --> $DIR/deprecated.rs:11:9 + --> $DIR/deprecated.rs:15:9 | LL | #![warn(clippy::replace_consts)] | ^^^^^^^^^^^^^^^^^^^^^^ error: lint `clippy::regex_macro` has been removed: the regex! macro has been removed from the regex crate in 2018 - --> $DIR/deprecated.rs:12:9 + --> $DIR/deprecated.rs:16:9 | LL | #![warn(clippy::regex_macro)] | ^^^^^^^^^^^^^^^^^^^ error: lint `clippy::find_map` has been removed: this lint has been replaced by `manual_find_map`, a more specific lint - --> $DIR/deprecated.rs:13:9 + --> $DIR/deprecated.rs:17:9 | LL | #![warn(clippy::find_map)] | ^^^^^^^^^^^^^^^^ error: lint `clippy::filter_map` has been removed: this lint has been replaced by `manual_filter_map`, a more specific lint - --> $DIR/deprecated.rs:14:9 + --> $DIR/deprecated.rs:18:9 | LL | #![warn(clippy::filter_map)] | ^^^^^^^^^^^^^^^^^^ error: lint `clippy::pub_enum_variant_names` has been removed: set the `avoid-breaking-exported-api` config option to `false` to enable the `enum_variant_names` lint for public items - --> $DIR/deprecated.rs:15:9 + --> $DIR/deprecated.rs:19:9 | LL | #![warn(clippy::pub_enum_variant_names)] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ error: lint `clippy::wrong_pub_self_convention` has been removed: set the `avoid-breaking-exported-api` config option to `false` to enable the `wrong_self_convention` lint for public items - --> $DIR/deprecated.rs:16:9 + --> $DIR/deprecated.rs:20:9 | LL | #![warn(clippy::wrong_pub_self_convention)] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ -- cgit 1.4.1-3-g733a5 From d5ef542d376877380fda93ac7c457b5b8ba66833 Mon Sep 17 00:00:00 2001 From: Jason Newcomb Date: Sun, 3 Apr 2022 08:51:17 -0400 Subject: Generate renamed lint test --- clippy_dev/src/update_lints.rs | 73 ++++++++++++++++++++++++++++++++++----- clippy_lints/src/lib.rs | 42 +++------------------- clippy_lints/src/renamed_lints.rs | 37 ++++++++++++++++++++ tests/ui/rename.fixed | 15 ++++---- tests/ui/rename.rs | 15 ++++---- tests/ui/rename.stderr | 30 ++++++++-------- 6 files changed, 135 insertions(+), 77 deletions(-) create mode 100644 clippy_lints/src/renamed_lints.rs (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/update_lints.rs b/clippy_dev/src/update_lints.rs index b010149626c..f15b00ecad1 100644 --- a/clippy_dev/src/update_lints.rs +++ b/clippy_dev/src/update_lints.rs @@ -1,7 +1,7 @@ use core::fmt::Write; use itertools::Itertools; use rustc_lexer::{tokenize, unescape, LiteralKind, TokenKind}; -use std::collections::HashMap; +use std::collections::{HashMap, HashSet}; use std::ffi::OsStr; use std::fs; use std::path::Path; @@ -32,7 +32,7 @@ pub enum UpdateMode { /// Panics if a file path could not read from or then written to #[allow(clippy::too_many_lines)] pub fn run(update_mode: UpdateMode) { - let (lints, deprecated_lints) = gather_all(); + let (lints, deprecated_lints, renamed_lints) = gather_all(); let internal_lints = Lint::internal_lints(&lints); let usable_lints = Lint::usable_lints(&lints); @@ -110,10 +110,13 @@ pub fn run(update_mode: UpdateMode) { let content = gen_deprecated_lints_test(&deprecated_lints); process_file("tests/ui/deprecated.rs", update_mode, &content); + + let content = gen_renamed_lints_test(&renamed_lints); + process_file("tests/ui/rename.rs", update_mode, &content); } pub fn print_lints() { - let (lint_list, _) = gather_all(); + let (lint_list, _, _) = gather_all(); let usable_lints = Lint::usable_lints(&lint_list); let usable_lint_count = usable_lints.len(); let grouped_by_lint_group = Lint::by_lint_group(usable_lints.into_iter()); @@ -213,6 +216,19 @@ impl DeprecatedLint { } } +struct RenamedLint { + old_name: String, + new_name: String, +} +impl RenamedLint { + fn new(old_name: &str, new_name: &str) -> Self { + Self { + old_name: remove_line_splices(old_name), + new_name: remove_line_splices(new_name), + } + } +} + /// Generates the code for registering a group fn gen_lint_group_list<'a>(group_name: &str, lints: impl Iterator) -> String { let mut details: Vec<_> = lints.map(|l| (&l.module, l.name.to_uppercase())).collect(); @@ -288,10 +304,30 @@ fn gen_deprecated_lints_test(lints: &[DeprecatedLint]) -> String { res } +fn gen_renamed_lints_test(lints: &[RenamedLint]) -> String { + let mut seen_lints = HashSet::new(); + let mut res: String = GENERATED_FILE_COMMENT.into(); + res.push_str("// run-rustfix\n\n"); + for lint in lints { + if seen_lints.insert(&lint.new_name) { + writeln!(res, "#![allow({})]", lint.new_name).unwrap(); + } + } + seen_lints.clear(); + for lint in lints { + if seen_lints.insert(&lint.old_name) { + writeln!(res, "#![warn({})]", lint.old_name).unwrap(); + } + } + res.push_str("\nfn main() {}\n"); + res +} + /// Gathers all lints defined in `clippy_lints/src` -fn gather_all() -> (Vec, Vec) { +fn gather_all() -> (Vec, Vec, Vec) { let mut lints = Vec::with_capacity(1000); let mut deprecated_lints = Vec::with_capacity(50); + let mut renamed_lints = Vec::with_capacity(50); let root_path = clippy_project_root().join("clippy_lints/src"); for (rel_path, file) in WalkDir::new(&root_path) @@ -317,13 +353,13 @@ fn gather_all() -> (Vec, Vec) { module.strip_suffix(".rs").unwrap_or(&module) }; - if module == "deprecated_lints" { - parse_deprecated_contents(&contents, &mut deprecated_lints); - } else { - parse_contents(&contents, module, &mut lints); + match module { + "deprecated_lints" => parse_deprecated_contents(&contents, &mut deprecated_lints), + "renamed_lints" => parse_renamed_contents(&contents, &mut renamed_lints), + _ => parse_contents(&contents, module, &mut lints), } } - (lints, deprecated_lints) + (lints, deprecated_lints, renamed_lints) } macro_rules! match_tokens { @@ -406,6 +442,25 @@ fn parse_deprecated_contents(contents: &str, lints: &mut Vec) { } } +fn parse_renamed_contents(contents: &str, lints: &mut Vec) { + for line in contents.lines() { + let mut offset = 0usize; + let mut iter = tokenize(line).map(|t| { + let range = offset..offset + t.len; + offset = range.end; + (t.kind, &line[range]) + }); + let (old_name, new_name) = match_tokens!( + iter, + // ("old_name", + Whitespace OpenParen Literal{kind: LiteralKind::Str{..},..}(old_name) Comma + // "new_name"), + Whitespace Literal{kind: LiteralKind::Str{..},..}(new_name) CloseParen Comma + ); + lints.push(RenamedLint::new(old_name, new_name)); + } +} + /// Removes the line splices and surrounding quotes from a string literal fn remove_line_splices(s: &str) -> String { let s = s diff --git a/clippy_lints/src/lib.rs b/clippy_lints/src/lib.rs index c8b57956b1b..9812cfde3ec 100644 --- a/clippy_lints/src/lib.rs +++ b/clippy_lints/src/lib.rs @@ -162,6 +162,8 @@ mod deprecated_lints; #[cfg_attr(feature = "internal", allow(clippy::missing_clippy_version_attribute))] mod utils; +mod renamed_lints; + // begin lints modules, do not remove this comment, it’s used in `update_lints` mod absurd_extreme_comparisons; mod approx_const; @@ -920,43 +922,9 @@ fn register_removed_non_tool_lints(store: &mut rustc_lint::LintStore) { /// /// Used in `./src/driver.rs`. pub fn register_renamed(ls: &mut rustc_lint::LintStore) { - // NOTE: when renaming a lint, add a corresponding test to tests/ui/rename.rs - ls.register_renamed("clippy::stutter", "clippy::module_name_repetitions"); - ls.register_renamed("clippy::new_without_default_derive", "clippy::new_without_default"); - ls.register_renamed("clippy::cyclomatic_complexity", "clippy::cognitive_complexity"); - ls.register_renamed("clippy::const_static_lifetime", "clippy::redundant_static_lifetimes"); - ls.register_renamed("clippy::option_and_then_some", "clippy::bind_instead_of_map"); - ls.register_renamed("clippy::box_vec", "clippy::box_collection"); - ls.register_renamed("clippy::block_in_if_condition_expr", "clippy::blocks_in_if_conditions"); - ls.register_renamed("clippy::block_in_if_condition_stmt", "clippy::blocks_in_if_conditions"); - ls.register_renamed("clippy::option_map_unwrap_or", "clippy::map_unwrap_or"); - ls.register_renamed("clippy::option_map_unwrap_or_else", "clippy::map_unwrap_or"); - ls.register_renamed("clippy::result_map_unwrap_or_else", "clippy::map_unwrap_or"); - ls.register_renamed("clippy::option_unwrap_used", "clippy::unwrap_used"); - ls.register_renamed("clippy::result_unwrap_used", "clippy::unwrap_used"); - ls.register_renamed("clippy::option_expect_used", "clippy::expect_used"); - ls.register_renamed("clippy::result_expect_used", "clippy::expect_used"); - ls.register_renamed("clippy::for_loop_over_option", "clippy::for_loops_over_fallibles"); - ls.register_renamed("clippy::for_loop_over_result", "clippy::for_loops_over_fallibles"); - ls.register_renamed("clippy::identity_conversion", "clippy::useless_conversion"); - ls.register_renamed("clippy::zero_width_space", "clippy::invisible_characters"); - ls.register_renamed("clippy::single_char_push_str", "clippy::single_char_add_str"); - ls.register_renamed("clippy::if_let_some_result", "clippy::match_result_ok"); - ls.register_renamed("clippy::disallowed_type", "clippy::disallowed_types"); - ls.register_renamed("clippy::disallowed_method", "clippy::disallowed_methods"); - ls.register_renamed("clippy::ref_in_deref", "clippy::needless_borrow"); - ls.register_renamed("clippy::to_string_in_display", "clippy::recursive_format_impl"); - - // uplifted lints - ls.register_renamed("clippy::invalid_ref", "invalid_value"); - ls.register_renamed("clippy::into_iter_on_array", "array_into_iter"); - ls.register_renamed("clippy::unused_label", "unused_labels"); - ls.register_renamed("clippy::drop_bounds", "drop_bounds"); - ls.register_renamed("clippy::temporary_cstring_as_ptr", "temporary_cstring_as_ptr"); - ls.register_renamed("clippy::panic_params", "non_fmt_panics"); - ls.register_renamed("clippy::unknown_clippy_lints", "unknown_lints"); - ls.register_renamed("clippy::invalid_atomic_ordering", "invalid_atomic_ordering"); - ls.register_renamed("clippy::mem_discriminant_non_enum", "enum_intrinsics_non_enums"); + for (old_name, new_name) in renamed_lints::RENAMED_LINTS { + ls.register_renamed(old_name, new_name); + } } // only exists to let the dogfood integration test works. diff --git a/clippy_lints/src/renamed_lints.rs b/clippy_lints/src/renamed_lints.rs new file mode 100644 index 00000000000..e10dc0e1bfe --- /dev/null +++ b/clippy_lints/src/renamed_lints.rs @@ -0,0 +1,37 @@ +pub static RENAMED_LINTS: &[(&str, &str)] = &[ + ("clippy::stutter", "clippy::module_name_repetitions"), + ("clippy::new_without_default_derive", "clippy::new_without_default"), + ("clippy::cyclomatic_complexity", "clippy::cognitive_complexity"), + ("clippy::const_static_lifetime", "clippy::redundant_static_lifetimes"), + ("clippy::option_and_then_some", "clippy::bind_instead_of_map"), + ("clippy::box_vec", "clippy::box_collection"), + ("clippy::block_in_if_condition_expr", "clippy::blocks_in_if_conditions"), + ("clippy::block_in_if_condition_stmt", "clippy::blocks_in_if_conditions"), + ("clippy::option_map_unwrap_or", "clippy::map_unwrap_or"), + ("clippy::option_map_unwrap_or_else", "clippy::map_unwrap_or"), + ("clippy::result_map_unwrap_or_else", "clippy::map_unwrap_or"), + ("clippy::option_unwrap_used", "clippy::unwrap_used"), + ("clippy::result_unwrap_used", "clippy::unwrap_used"), + ("clippy::option_expect_used", "clippy::expect_used"), + ("clippy::result_expect_used", "clippy::expect_used"), + ("clippy::for_loop_over_option", "clippy::for_loops_over_fallibles"), + ("clippy::for_loop_over_result", "clippy::for_loops_over_fallibles"), + ("clippy::identity_conversion", "clippy::useless_conversion"), + ("clippy::zero_width_space", "clippy::invisible_characters"), + ("clippy::single_char_push_str", "clippy::single_char_add_str"), + ("clippy::if_let_some_result", "clippy::match_result_ok"), + ("clippy::disallowed_type", "clippy::disallowed_types"), + ("clippy::disallowed_method", "clippy::disallowed_methods"), + ("clippy::ref_in_deref", "clippy::needless_borrow"), + ("clippy::to_string_in_display", "clippy::recursive_format_impl"), + // uplifted lints + ("clippy::invalid_ref", "invalid_value"), + ("clippy::into_iter_on_array", "array_into_iter"), + ("clippy::unused_label", "unused_labels"), + ("clippy::drop_bounds", "drop_bounds"), + ("clippy::temporary_cstring_as_ptr", "temporary_cstring_as_ptr"), + ("clippy::panic_params", "non_fmt_panics"), + ("clippy::unknown_clippy_lints", "unknown_lints"), + ("clippy::invalid_atomic_ordering", "invalid_atomic_ordering"), + ("clippy::mem_discriminant_non_enum", "enum_intrinsics_non_enums"), +]; diff --git a/tests/ui/rename.fixed b/tests/ui/rename.fixed index 24a0c812291..325f63a64dd 100644 --- a/tests/ui/rename.fixed +++ b/tests/ui/rename.fixed @@ -1,12 +1,13 @@ -//! Test for Clippy lint renames. +// This file was generated by `cargo dev update_lints`. +// Use that command to update this file and do not edit by hand. +// Manual edits will be overwritten. + // run-rustfix -#![allow(dead_code)] -// allow the new lint name here, to test if the new name works #![allow(clippy::module_name_repetitions)] #![allow(clippy::new_without_default)] -#![allow(clippy::redundant_static_lifetimes)] #![allow(clippy::cognitive_complexity)] +#![allow(clippy::redundant_static_lifetimes)] #![allow(clippy::bind_instead_of_map)] #![allow(clippy::box_collection)] #![allow(clippy::blocks_in_if_conditions)] @@ -20,8 +21,8 @@ #![allow(clippy::match_result_ok)] #![allow(clippy::disallowed_types)] #![allow(clippy::disallowed_methods)] +#![allow(clippy::needless_borrow)] #![allow(clippy::recursive_format_impl)] -// uplifted lints #![allow(invalid_value)] #![allow(array_into_iter)] #![allow(unused_labels)] @@ -31,11 +32,10 @@ #![allow(unknown_lints)] #![allow(invalid_atomic_ordering)] #![allow(enum_intrinsics_non_enums)] -// warn for the old lint name here, to test if the renaming worked #![warn(clippy::module_name_repetitions)] #![warn(clippy::new_without_default)] -#![warn(clippy::redundant_static_lifetimes)] #![warn(clippy::cognitive_complexity)] +#![warn(clippy::redundant_static_lifetimes)] #![warn(clippy::bind_instead_of_map)] #![warn(clippy::box_collection)] #![warn(clippy::blocks_in_if_conditions)] @@ -57,7 +57,6 @@ #![warn(clippy::disallowed_methods)] #![warn(clippy::needless_borrow)] #![warn(clippy::recursive_format_impl)] -// uplifted lints #![warn(invalid_value)] #![warn(array_into_iter)] #![warn(unused_labels)] diff --git a/tests/ui/rename.rs b/tests/ui/rename.rs index ea64234c680..a21b4a24288 100644 --- a/tests/ui/rename.rs +++ b/tests/ui/rename.rs @@ -1,12 +1,13 @@ -//! Test for Clippy lint renames. +// This file was generated by `cargo dev update_lints`. +// Use that command to update this file and do not edit by hand. +// Manual edits will be overwritten. + // run-rustfix -#![allow(dead_code)] -// allow the new lint name here, to test if the new name works #![allow(clippy::module_name_repetitions)] #![allow(clippy::new_without_default)] -#![allow(clippy::redundant_static_lifetimes)] #![allow(clippy::cognitive_complexity)] +#![allow(clippy::redundant_static_lifetimes)] #![allow(clippy::bind_instead_of_map)] #![allow(clippy::box_collection)] #![allow(clippy::blocks_in_if_conditions)] @@ -20,8 +21,8 @@ #![allow(clippy::match_result_ok)] #![allow(clippy::disallowed_types)] #![allow(clippy::disallowed_methods)] +#![allow(clippy::needless_borrow)] #![allow(clippy::recursive_format_impl)] -// uplifted lints #![allow(invalid_value)] #![allow(array_into_iter)] #![allow(unused_labels)] @@ -31,11 +32,10 @@ #![allow(unknown_lints)] #![allow(invalid_atomic_ordering)] #![allow(enum_intrinsics_non_enums)] -// warn for the old lint name here, to test if the renaming worked #![warn(clippy::stutter)] #![warn(clippy::new_without_default_derive)] -#![warn(clippy::const_static_lifetime)] #![warn(clippy::cyclomatic_complexity)] +#![warn(clippy::const_static_lifetime)] #![warn(clippy::option_and_then_some)] #![warn(clippy::box_vec)] #![warn(clippy::block_in_if_condition_expr)] @@ -57,7 +57,6 @@ #![warn(clippy::disallowed_method)] #![warn(clippy::ref_in_deref)] #![warn(clippy::to_string_in_display)] -// uplifted lints #![warn(clippy::invalid_ref)] #![warn(clippy::into_iter_on_array)] #![warn(clippy::unused_label)] diff --git a/tests/ui/rename.stderr b/tests/ui/rename.stderr index 8b132a78384..54e12d5fae5 100644 --- a/tests/ui/rename.stderr +++ b/tests/ui/rename.stderr @@ -12,17 +12,17 @@ error: lint `clippy::new_without_default_derive` has been renamed to `clippy::ne LL | #![warn(clippy::new_without_default_derive)] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::new_without_default` -error: lint `clippy::const_static_lifetime` has been renamed to `clippy::redundant_static_lifetimes` +error: lint `clippy::cyclomatic_complexity` has been renamed to `clippy::cognitive_complexity` --> $DIR/rename.rs:37:9 | -LL | #![warn(clippy::const_static_lifetime)] - | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::redundant_static_lifetimes` +LL | #![warn(clippy::cyclomatic_complexity)] + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::cognitive_complexity` -error: lint `clippy::cyclomatic_complexity` has been renamed to `clippy::cognitive_complexity` +error: lint `clippy::const_static_lifetime` has been renamed to `clippy::redundant_static_lifetimes` --> $DIR/rename.rs:38:9 | -LL | #![warn(clippy::cyclomatic_complexity)] - | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::cognitive_complexity` +LL | #![warn(clippy::const_static_lifetime)] + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::redundant_static_lifetimes` error: lint `clippy::option_and_then_some` has been renamed to `clippy::bind_instead_of_map` --> $DIR/rename.rs:39:9 @@ -151,55 +151,55 @@ LL | #![warn(clippy::to_string_in_display)] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::recursive_format_impl` error: lint `clippy::invalid_ref` has been renamed to `invalid_value` - --> $DIR/rename.rs:61:9 + --> $DIR/rename.rs:60:9 | LL | #![warn(clippy::invalid_ref)] | ^^^^^^^^^^^^^^^^^^^ help: use the new name: `invalid_value` error: lint `clippy::into_iter_on_array` has been renamed to `array_into_iter` - --> $DIR/rename.rs:62:9 + --> $DIR/rename.rs:61:9 | LL | #![warn(clippy::into_iter_on_array)] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `array_into_iter` error: lint `clippy::unused_label` has been renamed to `unused_labels` - --> $DIR/rename.rs:63:9 + --> $DIR/rename.rs:62:9 | LL | #![warn(clippy::unused_label)] | ^^^^^^^^^^^^^^^^^^^^ help: use the new name: `unused_labels` error: lint `clippy::drop_bounds` has been renamed to `drop_bounds` - --> $DIR/rename.rs:64:9 + --> $DIR/rename.rs:63:9 | LL | #![warn(clippy::drop_bounds)] | ^^^^^^^^^^^^^^^^^^^ help: use the new name: `drop_bounds` error: lint `clippy::temporary_cstring_as_ptr` has been renamed to `temporary_cstring_as_ptr` - --> $DIR/rename.rs:65:9 + --> $DIR/rename.rs:64:9 | LL | #![warn(clippy::temporary_cstring_as_ptr)] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `temporary_cstring_as_ptr` error: lint `clippy::panic_params` has been renamed to `non_fmt_panics` - --> $DIR/rename.rs:66:9 + --> $DIR/rename.rs:65:9 | LL | #![warn(clippy::panic_params)] | ^^^^^^^^^^^^^^^^^^^^ help: use the new name: `non_fmt_panics` error: lint `clippy::unknown_clippy_lints` has been renamed to `unknown_lints` - --> $DIR/rename.rs:67:9 + --> $DIR/rename.rs:66:9 | LL | #![warn(clippy::unknown_clippy_lints)] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `unknown_lints` error: lint `clippy::invalid_atomic_ordering` has been renamed to `invalid_atomic_ordering` - --> $DIR/rename.rs:68:9 + --> $DIR/rename.rs:67:9 | LL | #![warn(clippy::invalid_atomic_ordering)] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `invalid_atomic_ordering` error: lint `clippy::mem_discriminant_non_enum` has been renamed to `enum_intrinsics_non_enums` - --> $DIR/rename.rs:69:9 + --> $DIR/rename.rs:68:9 | LL | #![warn(clippy::mem_discriminant_non_enum)] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `enum_intrinsics_non_enums` -- cgit 1.4.1-3-g733a5 From 6ab4508350add2549b2f4b7b052057992a804128 Mon Sep 17 00:00:00 2001 From: flip1995 Date: Thu, 7 Apr 2022 18:05:20 +0100 Subject: Allow raw lint descriptions update_lints now understands raw strings in declare_clippy_lint descriptions. Co-authored-by: Alex Macleod --- CHANGELOG.md | 1 + clippy_dev/src/update_lints.rs | 5 ++++- clippy_lints/src/lib.register_all.rs | 1 + clippy_lints/src/lib.register_lints.rs | 1 + clippy_lints/src/lib.register_style.rs | 1 + 5 files changed, 8 insertions(+), 1 deletion(-) (limited to 'clippy_dev/src') diff --git a/CHANGELOG.md b/CHANGELOG.md index 918f0b48e50..b4097ea86a5 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3272,6 +3272,7 @@ Released 2018-09-13 [`eq_op`]: https://rust-lang.github.io/rust-clippy/master/index.html#eq_op [`equatable_if_let`]: https://rust-lang.github.io/rust-clippy/master/index.html#equatable_if_let [`erasing_op`]: https://rust-lang.github.io/rust-clippy/master/index.html#erasing_op +[`err_expect`]: https://rust-lang.github.io/rust-clippy/master/index.html#err_expect [`eval_order_dependence`]: https://rust-lang.github.io/rust-clippy/master/index.html#eval_order_dependence [`excessive_precision`]: https://rust-lang.github.io/rust-clippy/master/index.html#excessive_precision [`exhaustive_enums`]: https://rust-lang.github.io/rust-clippy/master/index.html#exhaustive_enums diff --git a/clippy_dev/src/update_lints.rs b/clippy_dev/src/update_lints.rs index 4e48b670457..59db51fbfac 100644 --- a/clippy_dev/src/update_lints.rs +++ b/clippy_dev/src/update_lints.rs @@ -359,7 +359,7 @@ fn parse_contents(contents: &str, module: &str, lints: &mut Vec) { // group, Ident(group) Comma // "description" } - Literal{kind: LiteralKind::Str{..}, ..}(desc) CloseBrace + Literal{..}(desc) CloseBrace ); lints.push(Lint::new(name, group, desc, module)); } @@ -397,6 +397,9 @@ fn parse_deprecated_contents(contents: &str, lints: &mut Vec) { /// Removes the line splices and surrounding quotes from a string literal fn remove_line_splices(s: &str) -> String { let s = s + .strip_prefix('r') + .unwrap_or(s) + .trim_matches('#') .strip_prefix('"') .and_then(|s| s.strip_suffix('"')) .unwrap_or_else(|| panic!("expected quoted string, found `{}`", s)); diff --git a/clippy_lints/src/lib.register_all.rs b/clippy_lints/src/lib.register_all.rs index c95b791f43e..14ca93b5f3c 100644 --- a/clippy_lints/src/lib.register_all.rs +++ b/clippy_lints/src/lib.register_all.rs @@ -157,6 +157,7 @@ store.register_group(true, "clippy::all", Some("clippy_all"), vec![ LintId::of(methods::CHARS_NEXT_CMP), LintId::of(methods::CLONE_DOUBLE_REF), LintId::of(methods::CLONE_ON_COPY), + LintId::of(methods::ERR_EXPECT), LintId::of(methods::EXPECT_FUN_CALL), LintId::of(methods::EXTEND_WITH_DRAIN), LintId::of(methods::FILTER_MAP_IDENTITY), diff --git a/clippy_lints/src/lib.register_lints.rs b/clippy_lints/src/lib.register_lints.rs index 1c4ccc15e83..532590aaa5a 100644 --- a/clippy_lints/src/lib.register_lints.rs +++ b/clippy_lints/src/lib.register_lints.rs @@ -286,6 +286,7 @@ store.register_lints(&[ methods::CLONE_DOUBLE_REF, methods::CLONE_ON_COPY, methods::CLONE_ON_REF_PTR, + methods::ERR_EXPECT, methods::EXPECT_FUN_CALL, methods::EXPECT_USED, methods::EXTEND_WITH_DRAIN, diff --git a/clippy_lints/src/lib.register_style.rs b/clippy_lints/src/lib.register_style.rs index dcf399cf956..3114afac886 100644 --- a/clippy_lints/src/lib.register_style.rs +++ b/clippy_lints/src/lib.register_style.rs @@ -59,6 +59,7 @@ store.register_group(true, "clippy::style", Some("clippy_style"), vec![ LintId::of(methods::BYTES_NTH), LintId::of(methods::CHARS_LAST_CMP), LintId::of(methods::CHARS_NEXT_CMP), + LintId::of(methods::ERR_EXPECT), LintId::of(methods::INTO_ITER_ON_REF), LintId::of(methods::ITER_CLONED_COLLECT), LintId::of(methods::ITER_NEXT_SLICE), -- cgit 1.4.1-3-g733a5 From ffde78b4564301888fcb4d5b970d8e9475bd33e9 Mon Sep 17 00:00:00 2001 From: Yoav Lavi Date: Fri, 8 Apr 2022 15:02:49 +0200 Subject: Allow passing --remove to `cargo dev setup ` add missing args unque name not needed more descriptive help formatting fixes missing quote --- clippy_dev/src/main.rs | 51 +++++++++++++++++++++++++++++++++++++++++++------- 1 file changed, 44 insertions(+), 7 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index b1fe35a0243..833b7393ff8 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -36,13 +36,31 @@ fn main() { } }, ("setup", Some(sub_command)) => match sub_command.subcommand() { - ("intellij", Some(matches)) => setup::intellij::setup_rustc_src( - matches - .value_of("rustc-repo-path") - .expect("this field is mandatory and therefore always valid"), - ), - ("git-hook", Some(matches)) => setup::git_hook::install_hook(matches.is_present("force-override")), - ("vscode-tasks", Some(matches)) => setup::vscode::install_tasks(matches.is_present("force-override")), + ("intellij", Some(matches)) => { + if matches.is_present("remove") { + setup::intellij::remove_rustc_src(); + } else { + setup::intellij::setup_rustc_src( + matches + .value_of("rustc-repo-path") + .expect("this field is mandatory and therefore always valid"), + ); + } + }, + ("git-hook", Some(matches)) => { + if matches.is_present("remove") { + setup::git_hook::remove_hook(); + } else { + setup::git_hook::install_hook(matches.is_present("force-override")); + } + }, + ("vscode-tasks", Some(matches)) => { + if matches.is_present("remove") { + setup::vscode::remove_tasks(); + } else { + setup::vscode::install_tasks(matches.is_present("force-override")); + } + }, _ => {}, }, ("remove", Some(sub_command)) => match sub_command.subcommand() { @@ -167,6 +185,12 @@ fn get_clap_config<'a>() -> ArgMatches<'a> { .subcommand( SubCommand::with_name("intellij") .about("Alter dependencies so Intellij Rust can find rustc internals") + .arg( + Arg::with_name("remove") + .long("remove") + .help("Remove the dependencies added with 'cargo dev setup intellij'") + .required(false), + ) .arg( Arg::with_name("rustc-repo-path") .long("repo-path") @@ -174,12 +198,19 @@ fn get_clap_config<'a>() -> ArgMatches<'a> { .help("The path to a rustc repo that will be used for setting the dependencies") .takes_value(true) .value_name("path") + .conflicts_with("remove") .required(true), ), ) .subcommand( SubCommand::with_name("git-hook") .about("Add a pre-commit git hook that formats your code to make it look pretty") + .arg( + Arg::with_name("remove") + .long("remove") + .help("Remove the pre-commit hook added with 'cargo dev setup git-hook'") + .required(false), + ) .arg( Arg::with_name("force-override") .long("force-override") @@ -191,6 +222,12 @@ fn get_clap_config<'a>() -> ArgMatches<'a> { .subcommand( SubCommand::with_name("vscode-tasks") .about("Add several tasks to vscode for formatting, validation and testing") + .arg( + Arg::with_name("remove") + .long("remove") + .help("Remove the tasks added with 'cargo dev setup vscode-tasks'") + .required(false), + ) .arg( Arg::with_name("force-override") .long("force-override") -- cgit 1.4.1-3-g733a5 From 67badbeef6ce5452cc47f2463d7146048ce64625 Mon Sep 17 00:00:00 2001 From: Peter Jaszkowiak Date: Sun, 3 Apr 2022 21:40:58 -0600 Subject: New lint `format_add_strings` --- CHANGELOG.md | 1 + clippy_dev/src/new_lint.rs | 6 +- clippy_dev/src/update_lints.rs | 16 +++-- clippy_lints/src/format_push_string.rs | 77 ++++++++++++++++++++++ .../src/inconsistent_struct_constructor.rs | 3 +- clippy_lints/src/lib.register_all.rs | 1 + clippy_lints/src/lib.register_lints.rs | 1 + clippy_lints/src/lib.register_perf.rs | 1 + clippy_lints/src/lib.rs | 2 + clippy_lints/src/trait_bounds.rs | 9 +-- clippy_utils/src/sugg.rs | 10 ++- lintcheck/src/main.rs | 15 +++-- tests/ui/format_push_string.rs | 7 ++ tests/ui/format_push_string.stderr | 19 ++++++ tests/ui/identity_op.rs | 4 +- tests/ui/identity_op.stderr | 36 +++++----- 16 files changed, 163 insertions(+), 45 deletions(-) create mode 100644 clippy_lints/src/format_push_string.rs create mode 100644 tests/ui/format_push_string.rs create mode 100644 tests/ui/format_push_string.stderr (limited to 'clippy_dev/src') diff --git a/CHANGELOG.md b/CHANGELOG.md index ef21dbac820..39786c08156 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3314,6 +3314,7 @@ Released 2018-09-13 [`forget_non_drop`]: https://rust-lang.github.io/rust-clippy/master/index.html#forget_non_drop [`forget_ref`]: https://rust-lang.github.io/rust-clippy/master/index.html#forget_ref [`format_in_format_args`]: https://rust-lang.github.io/rust-clippy/master/index.html#format_in_format_args +[`format_push_string`]: https://rust-lang.github.io/rust-clippy/master/index.html#format_push_string [`from_iter_instead_of_collect`]: https://rust-lang.github.io/rust-clippy/master/index.html#from_iter_instead_of_collect [`from_over_into`]: https://rust-lang.github.io/rust-clippy/master/index.html#from_over_into [`from_str_radix_10`]: https://rust-lang.github.io/rust-clippy/master/index.html#from_str_radix_10 diff --git a/clippy_dev/src/new_lint.rs b/clippy_dev/src/new_lint.rs index 7a3fd131761..10f67d301f8 100644 --- a/clippy_dev/src/new_lint.rs +++ b/clippy_dev/src/new_lint.rs @@ -1,5 +1,6 @@ use crate::clippy_project_root; use indoc::indoc; +use std::fmt::Write as _; use std::fs::{self, OpenOptions}; use std::io::prelude::*; use std::io::{self, ErrorKind}; @@ -232,7 +233,8 @@ fn get_lint_file_contents(lint: &LintData<'_>, enable_msrv: bool) -> String { ) }); - result.push_str(&format!( + let _ = write!( + result, indoc! {r#" declare_clippy_lint! {{ /// ### What it does @@ -256,7 +258,7 @@ fn get_lint_file_contents(lint: &LintData<'_>, enable_msrv: bool) -> String { version = version, name_upper = name_upper, category = category, - )); + ); result.push_str(&if enable_msrv { format!( diff --git a/clippy_dev/src/update_lints.rs b/clippy_dev/src/update_lints.rs index 59db51fbfac..d25e42f2468 100644 --- a/clippy_dev/src/update_lints.rs +++ b/clippy_dev/src/update_lints.rs @@ -217,12 +217,13 @@ fn gen_lint_group_list<'a>(group_name: &str, lints: impl Iterator String { let mut output = GENERATED_FILE_COMMENT.to_string(); output.push_str("{\n"); for lint in lints { - output.push_str(&format!( + let _ = write!( + output, concat!( " store.register_removed(\n", " \"clippy::{}\",\n", @@ -243,7 +245,7 @@ fn gen_deprecated(lints: &[DeprecatedLint]) -> String { " );\n" ), lint.name, lint.reason, - )); + ); } output.push_str("}\n"); @@ -269,7 +271,7 @@ fn gen_register_lint_list<'a>( if !is_public { output.push_str(" #[cfg(feature = \"internal\")]\n"); } - output.push_str(&format!(" {}::{},\n", module_name, lint_name)); + let _ = writeln!(output, " {}::{},", module_name, lint_name); } output.push_str("])\n"); diff --git a/clippy_lints/src/format_push_string.rs b/clippy_lints/src/format_push_string.rs new file mode 100644 index 00000000000..ee15ae9f59a --- /dev/null +++ b/clippy_lints/src/format_push_string.rs @@ -0,0 +1,77 @@ +use clippy_utils::diagnostics::span_lint_and_help; +use clippy_utils::ty::is_type_diagnostic_item; +use clippy_utils::{match_def_path, paths, peel_hir_expr_refs}; +use rustc_hir::{BinOpKind, Expr, ExprKind}; +use rustc_lint::{LateContext, LateLintPass}; +use rustc_session::{declare_lint_pass, declare_tool_lint}; +use rustc_span::sym; + +declare_clippy_lint! { + /// ### What it does + /// Detects cases where the result of a `format!` call is + /// appended to an existing `String`. + /// + /// ### Why is this bad? + /// Introduces an extra, avoidable heap allocation. + /// + /// ### Example + /// ```rust + /// let mut s = String::new(); + /// s += &format!("0x{:X}", 1024); + /// s.push_str(&format!("0x{:X}", 1024)); + /// ``` + /// Use instead: + /// ```rust + /// use std::fmt::Write as _; // import without risk of name clashing + /// + /// let mut s = String::new(); + /// let _ = write!(s, "0x{:X}", 1024); + /// ``` + #[clippy::version = "1.61.0"] + pub FORMAT_PUSH_STRING, + perf, + "`format!(..)` appended to existing `String`" +} +declare_lint_pass!(FormatPushString => [FORMAT_PUSH_STRING]); + +fn is_string(cx: &LateContext<'_>, e: &Expr<'_>) -> bool { + is_type_diagnostic_item(cx, cx.typeck_results().expr_ty(e).peel_refs(), sym::String) +} +fn is_format(cx: &LateContext<'_>, e: &Expr<'_>) -> bool { + if let Some(macro_def_id) = e.span.ctxt().outer_expn_data().macro_def_id { + cx.tcx.get_diagnostic_name(macro_def_id) == Some(sym::format_macro) + } else { + false + } +} + +impl<'tcx> LateLintPass<'tcx> for FormatPushString { + fn check_expr(&mut self, cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) { + let arg = match expr.kind { + ExprKind::MethodCall(_, [_, arg], _) => { + if let Some(fn_def_id) = cx.typeck_results().type_dependent_def_id(expr.hir_id) && + match_def_path(cx, fn_def_id, &paths::PUSH_STR) { + arg + } else { + return; + } + } + ExprKind::AssignOp(op, left, arg) + if op.node == BinOpKind::Add && is_string(cx, left) => { + arg + }, + _ => return, + }; + let (arg, _) = peel_hir_expr_refs(arg); + if is_format(cx, arg) { + span_lint_and_help( + cx, + FORMAT_PUSH_STRING, + expr.span, + "`format!(..)` appended to existing `String`", + None, + "consider using `write!` to avoid the extra allocation", + ); + } + } +} diff --git a/clippy_lints/src/inconsistent_struct_constructor.rs b/clippy_lints/src/inconsistent_struct_constructor.rs index c8ec2f45137..14b22d2b50d 100644 --- a/clippy_lints/src/inconsistent_struct_constructor.rs +++ b/clippy_lints/src/inconsistent_struct_constructor.rs @@ -7,6 +7,7 @@ use rustc_hir::{self as hir, ExprKind}; use rustc_lint::{LateContext, LateLintPass}; use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::symbol::Symbol; +use std::fmt::Write as _; declare_clippy_lint! { /// ### What it does @@ -89,7 +90,7 @@ impl<'tcx> LateLintPass<'tcx> for InconsistentStructConstructor { let mut fields_snippet = String::new(); let (last_ident, idents) = ordered_fields.split_last().unwrap(); for ident in idents { - fields_snippet.push_str(&format!("{}, ", ident)); + let _ = write!(fields_snippet, "{}, ", ident); } fields_snippet.push_str(&last_ident.to_string()); diff --git a/clippy_lints/src/lib.register_all.rs b/clippy_lints/src/lib.register_all.rs index 52c440de9dd..2fa59733365 100644 --- a/clippy_lints/src/lib.register_all.rs +++ b/clippy_lints/src/lib.register_all.rs @@ -77,6 +77,7 @@ store.register_group(true, "clippy::all", Some("clippy_all"), vec![ LintId::of(format_args::TO_STRING_IN_FORMAT_ARGS), LintId::of(format_impl::PRINT_IN_FORMAT_IMPL), LintId::of(format_impl::RECURSIVE_FORMAT_IMPL), + LintId::of(format_push_string::FORMAT_PUSH_STRING), LintId::of(formatting::POSSIBLE_MISSING_COMMA), LintId::of(formatting::SUSPICIOUS_ASSIGNMENT_FORMATTING), LintId::of(formatting::SUSPICIOUS_ELSE_FORMATTING), diff --git a/clippy_lints/src/lib.register_lints.rs b/clippy_lints/src/lib.register_lints.rs index 9820b7727af..c608f634291 100644 --- a/clippy_lints/src/lib.register_lints.rs +++ b/clippy_lints/src/lib.register_lints.rs @@ -165,6 +165,7 @@ store.register_lints(&[ format_args::TO_STRING_IN_FORMAT_ARGS, format_impl::PRINT_IN_FORMAT_IMPL, format_impl::RECURSIVE_FORMAT_IMPL, + format_push_string::FORMAT_PUSH_STRING, formatting::POSSIBLE_MISSING_COMMA, formatting::SUSPICIOUS_ASSIGNMENT_FORMATTING, formatting::SUSPICIOUS_ELSE_FORMATTING, diff --git a/clippy_lints/src/lib.register_perf.rs b/clippy_lints/src/lib.register_perf.rs index f2f5c988d8f..8f361fdad4a 100644 --- a/clippy_lints/src/lib.register_perf.rs +++ b/clippy_lints/src/lib.register_perf.rs @@ -7,6 +7,7 @@ store.register_group(true, "clippy::perf", Some("clippy_perf"), vec![ LintId::of(escape::BOXED_LOCAL), LintId::of(format_args::FORMAT_IN_FORMAT_ARGS), LintId::of(format_args::TO_STRING_IN_FORMAT_ARGS), + LintId::of(format_push_string::FORMAT_PUSH_STRING), LintId::of(large_const_arrays::LARGE_CONST_ARRAYS), LintId::of(large_enum_variant::LARGE_ENUM_VARIANT), LintId::of(loops::MANUAL_MEMCPY), diff --git a/clippy_lints/src/lib.rs b/clippy_lints/src/lib.rs index 604bd44c6c5..88e8a0cc2af 100644 --- a/clippy_lints/src/lib.rs +++ b/clippy_lints/src/lib.rs @@ -231,6 +231,7 @@ mod floating_point_arithmetic; mod format; mod format_args; mod format_impl; +mod format_push_string; mod formatting; mod from_over_into; mod from_str_radix_10; @@ -873,6 +874,7 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf: store.register_early_pass(|| Box::new(empty_structs_with_brackets::EmptyStructsWithBrackets)); store.register_late_pass(|| Box::new(unnecessary_owned_empty_strings::UnnecessaryOwnedEmptyStrings)); store.register_early_pass(|| Box::new(pub_use::PubUse)); + store.register_late_pass(|| Box::new(format_push_string::FormatPushString)); // add lints here, do not remove this comment, it's used in `new_lint` } diff --git a/clippy_lints/src/trait_bounds.rs b/clippy_lints/src/trait_bounds.rs index 43e0132a7ec..1551d0ecb74 100644 --- a/clippy_lints/src/trait_bounds.rs +++ b/clippy_lints/src/trait_bounds.rs @@ -14,6 +14,7 @@ use rustc_hir::{ use rustc_lint::{LateContext, LateLintPass}; use rustc_session::{declare_tool_lint, impl_lint_pass}; use rustc_span::Span; +use std::fmt::Write as _; declare_clippy_lint! { /// ### What it does @@ -184,19 +185,19 @@ impl TraitBounds { for b in v.iter() { if let GenericBound::Trait(ref poly_trait_ref, _) = b { let path = &poly_trait_ref.trait_ref.path; - hint_string.push_str(&format!( + let _ = write!(hint_string, " {} +", snippet_with_applicability(cx, path.span, "..", &mut applicability) - )); + ); } } for b in p.bounds.iter() { if let GenericBound::Trait(ref poly_trait_ref, _) = b { let path = &poly_trait_ref.trait_ref.path; - hint_string.push_str(&format!( + let _ = write!(hint_string, " {} +", snippet_with_applicability(cx, path.span, "..", &mut applicability) - )); + ); } } hint_string.truncate(hint_string.len() - 2); diff --git a/clippy_utils/src/sugg.rs b/clippy_utils/src/sugg.rs index 1fc9979f3dd..ffd2b5aabcf 100644 --- a/clippy_utils/src/sugg.rs +++ b/clippy_utils/src/sugg.rs @@ -18,7 +18,7 @@ use rustc_span::source_map::{BytePos, CharPos, Pos, Span, SyntaxContext}; use rustc_typeck::expr_use_visitor::{Delegate, ExprUseVisitor, PlaceBase, PlaceWithHirId}; use std::borrow::Cow; use std::convert::TryInto; -use std::fmt::Display; +use std::fmt::{Display, Write as _}; use std::iter; use std::ops::{Add, Neg, Not, Sub}; @@ -901,7 +901,7 @@ impl<'tcx> Delegate<'tcx> for DerefDelegate<'_, 'tcx> { if cmt.place.projections.is_empty() { // handle item without any projection, that needs an explicit borrowing // i.e.: suggest `&x` instead of `x` - self.suggestion_start.push_str(&format!("{}&{}", start_snip, ident_str)); + let _ = write!(self.suggestion_start, "{}&{}", start_snip, ident_str); } else { // cases where a parent `Call` or `MethodCall` is using the item // i.e.: suggest `.contains(&x)` for `.find(|x| [1, 2, 3].contains(x)).is_none()` @@ -916,8 +916,7 @@ impl<'tcx> Delegate<'tcx> for DerefDelegate<'_, 'tcx> { // given expression is the self argument and will be handled completely by the compiler // i.e.: `|x| x.is_something()` ExprKind::MethodCall(_, [self_expr, ..], _) if self_expr.hir_id == cmt.hir_id => { - self.suggestion_start - .push_str(&format!("{}{}", start_snip, ident_str_with_proj)); + let _ = write!(self.suggestion_start, "{}{}", start_snip, ident_str_with_proj); self.next_pos = span.hi(); return; }, @@ -1025,8 +1024,7 @@ impl<'tcx> Delegate<'tcx> for DerefDelegate<'_, 'tcx> { } } - self.suggestion_start - .push_str(&format!("{}{}", start_snip, replacement_str)); + let _ = write!(self.suggestion_start, "{}{}", start_snip, replacement_str); } self.next_pos = span.hi(); } diff --git a/lintcheck/src/main.rs b/lintcheck/src/main.rs index 9af8dcc7726..16cf728e3cb 100644 --- a/lintcheck/src/main.rs +++ b/lintcheck/src/main.rs @@ -8,6 +8,7 @@ #![allow(clippy::collapsible_else_if)] use std::ffi::OsStr; +use std::fmt::Write as _; use std::process::Command; use std::sync::atomic::{AtomicUsize, Ordering}; use std::{collections::HashMap, io::ErrorKind}; @@ -110,11 +111,12 @@ impl ClippyWarning { let lint = format!("`{}`", self.linttype); let mut output = String::from("| "); - output.push_str(&format!( + let _ = write!( + output, "[`{}`](../target/lintcheck/sources/{}#L{})", file_with_pos, file, self.line - )); - output.push_str(&format!(r#" | {:<50} | "{}" |"#, lint, self.message)); + ); + let _ = write!(output, r#" | {:<50} | "{}" |"#, lint, self.message); output.push('\n'); output } else { @@ -835,10 +837,11 @@ pub fn main() { text.push_str("| file | lint | message |\n"); text.push_str("| --- | --- | --- |\n"); } - text.push_str(&format!("{}", all_msgs.join(""))); + write!(text, "{}", all_msgs.join("")); text.push_str("\n\n### ICEs:\n"); - ices.iter() - .for_each(|(cratename, msg)| text.push_str(&format!("{}: '{}'", cratename, msg))); + for (cratename, msg) in ices.iter() { + let _ = write!(text, "{}: '{}'", cratename, msg); + } println!("Writing logs to {}", config.lintcheck_results_path.display()); std::fs::create_dir_all(config.lintcheck_results_path.parent().unwrap()).unwrap(); diff --git a/tests/ui/format_push_string.rs b/tests/ui/format_push_string.rs new file mode 100644 index 00000000000..4db13d650eb --- /dev/null +++ b/tests/ui/format_push_string.rs @@ -0,0 +1,7 @@ +#![warn(clippy::format_push_string)] + +fn main() { + let mut string = String::new(); + string += &format!("{:?}", 1234); + string.push_str(&format!("{:?}", 5678)); +} diff --git a/tests/ui/format_push_string.stderr b/tests/ui/format_push_string.stderr new file mode 100644 index 00000000000..953784bcc06 --- /dev/null +++ b/tests/ui/format_push_string.stderr @@ -0,0 +1,19 @@ +error: `format!(..)` appended to existing `String` + --> $DIR/format_push_string.rs:5:5 + | +LL | string += &format!("{:?}", 1234); + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + | + = note: `-D clippy::format-push-string` implied by `-D warnings` + = help: consider using `write!` to avoid the extra allocation + +error: `format!(..)` appended to existing `String` + --> $DIR/format_push_string.rs:6:5 + | +LL | string.push_str(&format!("{:?}", 5678)); + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ + | + = help: consider using `write!` to avoid the extra allocation + +error: aborting due to 2 previous errors + diff --git a/tests/ui/identity_op.rs b/tests/ui/identity_op.rs index edc3fe1aec1..9d39d769635 100644 --- a/tests/ui/identity_op.rs +++ b/tests/ui/identity_op.rs @@ -1,3 +1,5 @@ +use std::fmt::Write as _; + const ONE: i64 = 1; const NEG_ONE: i64 = -1; const ZERO: i64 = 0; @@ -7,7 +9,7 @@ struct A(String); impl std::ops::Shl for A { type Output = A; fn shl(mut self, other: i32) -> Self { - self.0.push_str(&format!("{}", other)); + let _ = write!(self.0, "{}", other); self } } diff --git a/tests/ui/identity_op.stderr b/tests/ui/identity_op.stderr index 706f01a3dd6..e3c156b5429 100644 --- a/tests/ui/identity_op.stderr +++ b/tests/ui/identity_op.stderr @@ -1,5 +1,5 @@ error: the operation is ineffective. Consider reducing it to `x` - --> $DIR/identity_op.rs:37:5 + --> $DIR/identity_op.rs:39:5 | LL | x + 0; | ^^^^^ @@ -7,103 +7,103 @@ LL | x + 0; = note: `-D clippy::identity-op` implied by `-D warnings` error: the operation is ineffective. Consider reducing it to `x` - --> $DIR/identity_op.rs:38:5 + --> $DIR/identity_op.rs:40:5 | LL | x + (1 - 1); | ^^^^^^^^^^^ error: the operation is ineffective. Consider reducing it to `x` - --> $DIR/identity_op.rs:40:5 + --> $DIR/identity_op.rs:42:5 | LL | 0 + x; | ^^^^^ error: the operation is ineffective. Consider reducing it to `x` - --> $DIR/identity_op.rs:43:5 + --> $DIR/identity_op.rs:45:5 | LL | x | (0); | ^^^^^^^ error: the operation is ineffective. Consider reducing it to `x` - --> $DIR/identity_op.rs:46:5 + --> $DIR/identity_op.rs:48:5 | LL | x * 1; | ^^^^^ error: the operation is ineffective. Consider reducing it to `x` - --> $DIR/identity_op.rs:47:5 + --> $DIR/identity_op.rs:49:5 | LL | 1 * x; | ^^^^^ error: the operation is ineffective. Consider reducing it to `x` - --> $DIR/identity_op.rs:53:5 + --> $DIR/identity_op.rs:55:5 | LL | -1 & x; | ^^^^^^ error: the operation is ineffective. Consider reducing it to `u` - --> $DIR/identity_op.rs:56:5 + --> $DIR/identity_op.rs:58:5 | LL | u & 255; | ^^^^^^^ error: the operation is ineffective. Consider reducing it to `42` - --> $DIR/identity_op.rs:59:5 + --> $DIR/identity_op.rs:61:5 | LL | 42 << 0; | ^^^^^^^ error: the operation is ineffective. Consider reducing it to `1` - --> $DIR/identity_op.rs:60:5 + --> $DIR/identity_op.rs:62:5 | LL | 1 >> 0; | ^^^^^^ error: the operation is ineffective. Consider reducing it to `42` - --> $DIR/identity_op.rs:61:5 + --> $DIR/identity_op.rs:63:5 | LL | 42 >> 0; | ^^^^^^^ error: the operation is ineffective. Consider reducing it to `&x` - --> $DIR/identity_op.rs:62:5 + --> $DIR/identity_op.rs:64:5 | LL | &x >> 0; | ^^^^^^^ error: the operation is ineffective. Consider reducing it to `x` - --> $DIR/identity_op.rs:63:5 + --> $DIR/identity_op.rs:65:5 | LL | x >> &0; | ^^^^^^^ error: the operation is ineffective. Consider reducing it to `2` - --> $DIR/identity_op.rs:70:5 + --> $DIR/identity_op.rs:72:5 | LL | 2 % 3; | ^^^^^ error: the operation is ineffective. Consider reducing it to `-2` - --> $DIR/identity_op.rs:71:5 + --> $DIR/identity_op.rs:73:5 | LL | -2 % 3; | ^^^^^^ error: the operation is ineffective. Consider reducing it to `2` - --> $DIR/identity_op.rs:72:5 + --> $DIR/identity_op.rs:74:5 | LL | 2 % -3 + x; | ^^^^^^ error: the operation is ineffective. Consider reducing it to `-2` - --> $DIR/identity_op.rs:73:5 + --> $DIR/identity_op.rs:75:5 | LL | -2 % -3 + x; | ^^^^^^^ error: the operation is ineffective. Consider reducing it to `1` - --> $DIR/identity_op.rs:74:9 + --> $DIR/identity_op.rs:76:9 | LL | x + 1 % 3; | ^^^^^ -- cgit 1.4.1-3-g733a5 From 29ef80c78a0f9c58607944e50d3240eee2b7cdc7 Mon Sep 17 00:00:00 2001 From: whodi Date: Fri, 15 Apr 2022 14:25:55 -0400 Subject: adding spell checking --- .github/ISSUE_TEMPLATE/blank_issue.yml | 2 +- .github/ISSUE_TEMPLATE/false_negative.yml | 2 +- .github/ISSUE_TEMPLATE/false_positive.yml | 2 +- .github/workflows/clippy.yml | 4 ++-- clippy_dev/src/setup/git_hook.rs | 2 +- clippy_dev/src/setup/mod.rs | 4 ++-- clippy_lints/src/casts/mod.rs | 2 +- clippy_lints/src/empty_structs_with_brackets.rs | 2 +- clippy_lints/src/index_refutable_slice.rs | 2 +- clippy_lints/src/match_result_ok.rs | 4 ++-- clippy_lints/src/matches/match_same_arms.rs | 4 ++-- clippy_lints/src/matches/mod.rs | 4 ++-- clippy_lints/src/matches/needless_match.rs | 2 +- clippy_lints/src/methods/mod.rs | 4 ++-- clippy_lints/src/missing_inline.rs | 2 +- clippy_lints/src/needless_bitwise_bool.rs | 4 ++-- clippy_lints/src/needless_late_init.rs | 6 +++--- clippy_lints/src/octal_escapes.rs | 2 +- clippy_lints/src/option_if_let_else.rs | 8 ++++---- clippy_lints/src/suspicious_operation_groupings.rs | 2 +- clippy_lints/src/transmute/utils.rs | 2 +- clippy_lints/src/types/mod.rs | 2 +- clippy_lints/src/unnested_or_patterns.rs | 2 +- clippy_lints/src/use_self.rs | 2 +- clippy_lints/src/utils/author.rs | 2 +- clippy_lints/src/utils/internal_lints.rs | 4 ++-- clippy_lints/src/utils/internal_lints/metadata_collector.rs | 6 +++--- clippy_utils/src/macros.rs | 2 +- clippy_utils/src/source.rs | 2 +- tests/lint_message_convention.rs | 2 +- tests/ui/auxiliary/proc_macro_derive.rs | 2 +- 31 files changed, 46 insertions(+), 46 deletions(-) (limited to 'clippy_dev/src') diff --git a/.github/ISSUE_TEMPLATE/blank_issue.yml b/.github/ISSUE_TEMPLATE/blank_issue.yml index d610e8c7bc4..89884bfc859 100644 --- a/.github/ISSUE_TEMPLATE/blank_issue.yml +++ b/.github/ISSUE_TEMPLATE/blank_issue.yml @@ -9,7 +9,7 @@ body: attributes: label: Description description: > - Please provide a discription of the issue, along with any information + Please provide a description of the issue, along with any information you feel relevant to replicate it. validations: required: true diff --git a/.github/ISSUE_TEMPLATE/false_negative.yml b/.github/ISSUE_TEMPLATE/false_negative.yml index 9357ccc4f4e..25e436d30b9 100644 --- a/.github/ISSUE_TEMPLATE/false_negative.yml +++ b/.github/ISSUE_TEMPLATE/false_negative.yml @@ -23,7 +23,7 @@ body: id: reproducer attributes: label: Reproducer - description: Please provide the code and steps to repoduce the bug + description: Please provide the code and steps to reproduce the bug value: | I tried this code: diff --git a/.github/ISSUE_TEMPLATE/false_positive.yml b/.github/ISSUE_TEMPLATE/false_positive.yml index b7dd400ee73..561b65c93a7 100644 --- a/.github/ISSUE_TEMPLATE/false_positive.yml +++ b/.github/ISSUE_TEMPLATE/false_positive.yml @@ -24,7 +24,7 @@ body: attributes: label: Reproducer description: > - Please provide the code and steps to repoduce the bug together with the + Please provide the code and steps to reproduce the bug together with the output from Clippy. value: | I tried this code: diff --git a/.github/workflows/clippy.yml b/.github/workflows/clippy.yml index cd83bc9642b..4292949a02d 100644 --- a/.github/workflows/clippy.yml +++ b/.github/workflows/clippy.yml @@ -6,14 +6,14 @@ on: branches-ignore: - auto - try - # Don't run Clippy tests, when only textfiles were modified + # Don't run Clippy tests, when only text files were modified paths-ignore: - 'COPYRIGHT' - 'LICENSE-*' - '**.md' - '**.txt' pull_request: - # Don't run Clippy tests, when only textfiles were modified + # Don't run Clippy tests, when only text files were modified paths-ignore: - 'COPYRIGHT' - 'LICENSE-*' diff --git a/clippy_dev/src/setup/git_hook.rs b/clippy_dev/src/setup/git_hook.rs index 3fbb77d5923..ad4b96f7ff3 100644 --- a/clippy_dev/src/setup/git_hook.rs +++ b/clippy_dev/src/setup/git_hook.rs @@ -18,7 +18,7 @@ pub fn install_hook(force_override: bool) { // So a little bit of a funny story. Git on unix requires the pre-commit file // to have the `execute` permission to be set. The Rust functions for modifying - // these flags doesn't seem to work when executed with normal user permissions. + // these flags doesn't seem to work when executed with normal user permissions. // // However, there is a little hack that is also being used by Rust itself in their // setup script. Git saves the `execute` flag when syncing files. This means diff --git a/clippy_dev/src/setup/mod.rs b/clippy_dev/src/setup/mod.rs index a1e4dd103b8..f691ae4fa45 100644 --- a/clippy_dev/src/setup/mod.rs +++ b/clippy_dev/src/setup/mod.rs @@ -7,7 +7,7 @@ use std::path::Path; const CLIPPY_DEV_DIR: &str = "clippy_dev"; /// This function verifies that the tool is being executed in the clippy directory. -/// This is useful to ensure that setups only modify Clippys resources. The verification +/// This is useful to ensure that setups only modify Clippy's resources. The verification /// is done by checking that `clippy_dev` is a sub directory of the current directory. /// /// It will print an error message and return `false` if the directory could not be @@ -17,7 +17,7 @@ fn verify_inside_clippy_dir() -> bool { if path.exists() && path.is_dir() { true } else { - eprintln!("error: unable to verify that the working directory is clippys directory"); + eprintln!("error: unable to verify that the working directory is clippy's directory"); false } } diff --git a/clippy_lints/src/casts/mod.rs b/clippy_lints/src/casts/mod.rs index 55c1f085657..f05315a7d0c 100644 --- a/clippy_lints/src/casts/mod.rs +++ b/clippy_lints/src/casts/mod.rs @@ -270,7 +270,7 @@ declare_clippy_lint! { /// /// ### Why is this bad? /// Casting a function pointer to an integer can have surprising results and can occur - /// accidentally if parantheses are omitted from a function call. If you aren't doing anything + /// accidentally if parentheses are omitted from a function call. If you aren't doing anything /// low-level with function pointers then you can opt-out of casting functions to integers in /// order to avoid mistakes. Alternatively, you can use this lint to audit all uses of function /// pointer casts in your code. diff --git a/clippy_lints/src/empty_structs_with_brackets.rs b/clippy_lints/src/empty_structs_with_brackets.rs index fdeac8d8255..8430e7b4c82 100644 --- a/clippy_lints/src/empty_structs_with_brackets.rs +++ b/clippy_lints/src/empty_structs_with_brackets.rs @@ -66,7 +66,7 @@ fn has_no_fields(cx: &EarlyContext<'_>, var_data: &VariantData, braces_span: Spa } // there might still be field declarations hidden from the AST - // (conditionaly compiled code using #[cfg(..)]) + // (conditionally compiled code using #[cfg(..)]) let Some(braces_span_str) = snippet_opt(cx, braces_span) else { return false; diff --git a/clippy_lints/src/index_refutable_slice.rs b/clippy_lints/src/index_refutable_slice.rs index 6b62748ffef..8a84513b779 100644 --- a/clippy_lints/src/index_refutable_slice.rs +++ b/clippy_lints/src/index_refutable_slice.rs @@ -116,7 +116,7 @@ fn find_slice_values(cx: &LateContext<'_>, pat: &hir::Pat<'_>) -> FxIndexMap LateLintPass<'tcx> for MatchResultOk { if_chain! { if let ExprKind::MethodCall(ok_path, [ref result_types_0, ..], _) = let_expr.kind; //check is expr.ok() has type Result.ok(, _) if let PatKind::TupleStruct(QPath::Resolved(_, x), y, _) = let_pat.kind; //get operation - if method_chain_args(let_expr, &["ok"]).is_some(); //test to see if using ok() methoduse std::marker::Sized; + if method_chain_args(let_expr, &["ok"]).is_some(); //test to see if using ok() method use std::marker::Sized; if is_type_diagnostic_item(cx, cx.typeck_results().expr_ty(result_types_0), sym::Result); if rustc_hir_pretty::to_string(rustc_hir_pretty::NO_ANN, |s| s.print_path(x, false)) == "Some"; diff --git a/clippy_lints/src/matches/match_same_arms.rs b/clippy_lints/src/matches/match_same_arms.rs index b8591fe0db0..9b7344fb8b0 100644 --- a/clippy_lints/src/matches/match_same_arms.rs +++ b/clippy_lints/src/matches/match_same_arms.rs @@ -30,7 +30,7 @@ pub(super) fn check<'tcx>(cx: &LateContext<'tcx>, arms: &'tcx [Arm<'_>]) { .map(|a| NormalizedPat::from_pat(cx, &arena, a.pat)) .collect(); - // The furthast forwards a pattern can move without semantic changes + // The furthest forwards a pattern can move without semantic changes let forwards_blocking_idxs: Vec<_> = normalized_pats .iter() .enumerate() @@ -43,7 +43,7 @@ pub(super) fn check<'tcx>(cx: &LateContext<'tcx>, arms: &'tcx [Arm<'_>]) { }) .collect(); - // The furthast backwards a pattern can move without semantic changes + // The furthest backwards a pattern can move without semantic changes let backwards_blocking_idxs: Vec<_> = normalized_pats .iter() .enumerate() diff --git a/clippy_lints/src/matches/mod.rs b/clippy_lints/src/matches/mod.rs index 854cf06ed81..401ecef460c 100644 --- a/clippy_lints/src/matches/mod.rs +++ b/clippy_lints/src/matches/mod.rs @@ -7,7 +7,7 @@ use rustc_semver::RustcVersion; use rustc_session::{declare_tool_lint, impl_lint_pass}; use rustc_span::{Span, SpanData, SyntaxContext}; -mod infalliable_detructuring_match; +mod infallible_destructuring_match; mod match_as_ref; mod match_bool; mod match_like_matches; @@ -694,7 +694,7 @@ impl<'tcx> LateLintPass<'tcx> for Matches { } fn check_local(&mut self, cx: &LateContext<'tcx>, local: &'tcx Local<'_>) { - self.infallible_destructuring_match_linted |= infalliable_detructuring_match::check(cx, local); + self.infallible_destructuring_match_linted |= infallible_destructuring_match::check(cx, local); } fn check_pat(&mut self, cx: &LateContext<'tcx>, pat: &'tcx Pat<'_>) { diff --git a/clippy_lints/src/matches/needless_match.rs b/clippy_lints/src/matches/needless_match.rs index d6c8e472552..0abe6ddda65 100644 --- a/clippy_lints/src/matches/needless_match.rs +++ b/clippy_lints/src/matches/needless_match.rs @@ -118,7 +118,7 @@ fn strip_return<'hir>(expr: &'hir Expr<'hir>) -> &'hir Expr<'hir> { } /// Manually check for coercion casting by checking if the type of the match operand or let expr -/// differs with the assigned local variable or the funtion return type. +/// differs with the assigned local variable or the function return type. fn expr_ty_matches_p_ty(cx: &LateContext<'_>, expr: &Expr<'_>, p_expr: &Expr<'_>) -> bool { if let Some(p_node) = get_parent_node(cx.tcx, p_expr.hir_id) { match p_node { diff --git a/clippy_lints/src/methods/mod.rs b/clippy_lints/src/methods/mod.rs index f1a74220e68..70a2aaf78a0 100644 --- a/clippy_lints/src/methods/mod.rs +++ b/clippy_lints/src/methods/mod.rs @@ -1266,7 +1266,7 @@ declare_clippy_lint! { #[clippy::version = "1.55.0"] pub EXTEND_WITH_DRAIN, perf, - "using vec.append(&mut vec) to move the full range of a vecor to another" + "using vec.append(&mut vec) to move the full range of a vector to another" } declare_clippy_lint! { @@ -2100,7 +2100,7 @@ declare_clippy_lint! { /// using `.collect::()` over `.collect::>().join("")` /// will prevent loop unrolling and will result in a negative performance impact. /// - /// Additionlly, differences have been observed between aarch64 and x86_64 assembly output, + /// Additionally, differences have been observed between aarch64 and x86_64 assembly output, /// with aarch64 tending to producing faster assembly in more cases when using `.collect::()` #[clippy::version = "1.61.0"] pub UNNECESSARY_JOIN, diff --git a/clippy_lints/src/missing_inline.rs b/clippy_lints/src/missing_inline.rs index ac2f16b49e3..6e6ad1ebbce 100644 --- a/clippy_lints/src/missing_inline.rs +++ b/clippy_lints/src/missing_inline.rs @@ -44,7 +44,7 @@ declare_clippy_lint! { /// pub struct PubBaz; /// impl PubBaz { /// fn private() {} // ok - /// pub fn not_ptrivate() {} // missing #[inline] + /// pub fn not_private() {} // missing #[inline] /// } /// /// impl Bar for PubBaz { diff --git a/clippy_lints/src/needless_bitwise_bool.rs b/clippy_lints/src/needless_bitwise_bool.rs index a8a8d174a82..95395e2e136 100644 --- a/clippy_lints/src/needless_bitwise_bool.rs +++ b/clippy_lints/src/needless_bitwise_bool.rs @@ -53,7 +53,7 @@ fn is_bitwise_operation(cx: &LateContext<'_>, expr: &Expr<'_>) -> bool { false } -fn suggession_snippet(cx: &LateContext<'_>, expr: &Expr<'_>) -> Option { +fn suggesstion_snippet(cx: &LateContext<'_>, expr: &Expr<'_>) -> Option { if let ExprKind::Binary(ref op, left, right) = expr.kind { if let (Some(l_snippet), Some(r_snippet)) = (snippet_opt(cx, left.span), snippet_opt(cx, right.span)) { let op_snippet = match op.node { @@ -75,7 +75,7 @@ impl LateLintPass<'_> for NeedlessBitwiseBool { expr.span, "use of bitwise operator instead of lazy operator between booleans", |diag| { - if let Some(sugg) = suggession_snippet(cx, expr) { + if let Some(sugg) = suggesstion_snippet(cx, expr) { diag.span_suggestion(expr.span, "try", sugg, Applicability::MachineApplicable); } }, diff --git a/clippy_lints/src/needless_late_init.rs b/clippy_lints/src/needless_late_init.rs index 9957afcbf04..bbcf7e9e378 100644 --- a/clippy_lints/src/needless_late_init.rs +++ b/clippy_lints/src/needless_late_init.rs @@ -240,7 +240,7 @@ fn check<'tcx>( cx, NEEDLESS_LATE_INIT, local_stmt.span, - "unneeded late initalization", + "unneeded late initialization", |diag| { diag.tool_only_span_suggestion( local_stmt.span, @@ -265,7 +265,7 @@ fn check<'tcx>( cx, NEEDLESS_LATE_INIT, local_stmt.span, - "unneeded late initalization", + "unneeded late initialization", |diag| { diag.tool_only_span_suggestion(local_stmt.span, "remove the local", String::new(), applicability); @@ -296,7 +296,7 @@ fn check<'tcx>( cx, NEEDLESS_LATE_INIT, local_stmt.span, - "unneeded late initalization", + "unneeded late initialization", |diag| { diag.tool_only_span_suggestion(local_stmt.span, "remove the local", String::new(), applicability); diff --git a/clippy_lints/src/octal_escapes.rs b/clippy_lints/src/octal_escapes.rs index c19cea66104..e8532db4f71 100644 --- a/clippy_lints/src/octal_escapes.rs +++ b/clippy_lints/src/octal_escapes.rs @@ -25,7 +25,7 @@ declare_clippy_lint! { /// /// ### Known problems /// The actual meaning can be the intended one. `\x00` can be used in these - /// cases to be unambigious. + /// cases to be unambiguous. /// /// The lint does not trigger for format strings in `print!()`, `write!()` /// and friends since the string is already preprocessed when Clippy lints diff --git a/clippy_lints/src/option_if_let_else.rs b/clippy_lints/src/option_if_let_else.rs index c9f807f2aa3..ea5a8f0858b 100644 --- a/clippy_lints/src/option_if_let_else.rs +++ b/clippy_lints/src/option_if_let_else.rs @@ -78,7 +78,7 @@ fn is_result_ok(cx: &LateContext<'_>, expr: &'_ Expr<'_>) -> bool { /// A struct containing information about occurrences of the /// `if let Some(..) = .. else` construct that this lint detects. -struct OptionIfLetElseOccurence { +struct OptionIfLetElseOccurrence { option: String, method_sugg: String, some_expr: String, @@ -100,9 +100,9 @@ fn format_option_in_sugg(cx: &LateContext<'_>, cond_expr: &Expr<'_>, as_ref: boo } /// If this expression is the option if let/else construct we're detecting, then -/// this function returns an `OptionIfLetElseOccurence` struct with details if +/// this function returns an `OptionIfLetElseOccurrence` struct with details if /// this construct is found, or None if this construct is not found. -fn detect_option_if_let_else<'tcx>(cx: &LateContext<'tcx>, expr: &Expr<'tcx>) -> Option { +fn detect_option_if_let_else<'tcx>(cx: &LateContext<'tcx>, expr: &Expr<'tcx>) -> Option { if_chain! { if !expr.span.from_expansion(); // Don't lint macros, because it behaves weirdly if !in_constant(cx, expr.hir_id); @@ -154,7 +154,7 @@ fn detect_option_if_let_else<'tcx>(cx: &LateContext<'tcx>, expr: &Expr<'tcx>) -> } } } - Some(OptionIfLetElseOccurence { + Some(OptionIfLetElseOccurrence { option: format_option_in_sugg(cx, cond_expr, as_ref, as_mut), method_sugg: method_sugg.to_string(), some_expr: format!("|{}{}| {}", capture_mut, capture_name, Sugg::hir_with_macro_callsite(cx, some_body, "..")), diff --git a/clippy_lints/src/suspicious_operation_groupings.rs b/clippy_lints/src/suspicious_operation_groupings.rs index b5dd27ff80d..c4c1aa11004 100644 --- a/clippy_lints/src/suspicious_operation_groupings.rs +++ b/clippy_lints/src/suspicious_operation_groupings.rs @@ -550,7 +550,7 @@ fn ident_difference_expr_with_base_location( // IdentIter, then the output of this function will be almost always be correct // in practice. // - // If it turns out that problematic cases are more prelavent than we assume, + // If it turns out that problematic cases are more prevalent than we assume, // then we should be able to change this function to do the correct traversal, // without needing to change the rest of the code. diff --git a/clippy_lints/src/transmute/utils.rs b/clippy_lints/src/transmute/utils.rs index 0e07a0b0392..0cbf5ccefa6 100644 --- a/clippy_lints/src/transmute/utils.rs +++ b/clippy_lints/src/transmute/utils.rs @@ -87,7 +87,7 @@ fn check_cast<'tcx>(cx: &LateContext<'tcx>, e: &'tcx Expr<'_>, from_ty: Ty<'tcx> let res = check.do_check(&fn_ctxt); // do_check's documentation says that it might return Ok and create - // errors in the fcx instead of returing Err in some cases. Those cases + // errors in the fcx instead of returning Err in some cases. Those cases // should be filtered out before getting here. assert!( !fn_ctxt.errors_reported_since_creation(), diff --git a/clippy_lints/src/types/mod.rs b/clippy_lints/src/types/mod.rs index 67cc8913318..b1b2addb9a1 100644 --- a/clippy_lints/src/types/mod.rs +++ b/clippy_lints/src/types/mod.rs @@ -432,7 +432,7 @@ impl Types { fn check_fn_decl(&mut self, cx: &LateContext<'_>, decl: &FnDecl<'_>, context: CheckTyContext) { // Ignore functions in trait implementations as they are usually forced by the trait definition. // - // FIXME: idially we would like to warn *if the compicated type can be simplified*, but it's hard to + // FIXME: ideally we would like to warn *if the complicated type can be simplified*, but it's hard to // check. if context.is_in_trait_impl { return; diff --git a/clippy_lints/src/unnested_or_patterns.rs b/clippy_lints/src/unnested_or_patterns.rs index 790ffe618d7..ae431aac83b 100644 --- a/clippy_lints/src/unnested_or_patterns.rs +++ b/clippy_lints/src/unnested_or_patterns.rs @@ -25,7 +25,7 @@ declare_clippy_lint! { /// *disjunctive normal form (DNF)* into *conjunctive normal form (CNF)*. /// /// ### Why is this bad? - /// In the example above, `Some` is repeated, which unncessarily complicates the pattern. + /// In the example above, `Some` is repeated, which unnecessarily complicates the pattern. /// /// ### Example /// ```rust diff --git a/clippy_lints/src/use_self.rs b/clippy_lints/src/use_self.rs index f8e1021af0e..138f8bccb3f 100644 --- a/clippy_lints/src/use_self.rs +++ b/clippy_lints/src/use_self.rs @@ -30,7 +30,7 @@ declare_clippy_lint! { /// /// ### Known problems /// - Unaddressed false negative in fn bodies of trait implementations - /// - False positive with assotiated types in traits (#4140) + /// - False positive with associated types in traits (#4140) /// /// ### Example /// ```rust diff --git a/clippy_lints/src/utils/author.rs b/clippy_lints/src/utils/author.rs index d23c85c033b..ff5be825b78 100644 --- a/clippy_lints/src/utils/author.rs +++ b/clippy_lints/src/utils/author.rs @@ -70,7 +70,7 @@ macro_rules! bind { }; } -/// Transforms the given `Option` varibles into `OptionPat>`. +/// Transforms the given `Option` variables into `OptionPat>`. /// This displays as `Some($name)` or `None` when printed. The name of the inner binding /// is set to the name of the variable passed to the macro. macro_rules! opt_bind { diff --git a/clippy_lints/src/utils/internal_lints.rs b/clippy_lints/src/utils/internal_lints.rs index 25d74b8c499..0e8f40e9210 100644 --- a/clippy_lints/src/utils/internal_lints.rs +++ b/clippy_lints/src/utils/internal_lints.rs @@ -292,7 +292,7 @@ declare_clippy_lint! { /// Checks for unnecessary conversion from Symbol to a string. /// /// ### Why is this bad? - /// It's faster use symbols directly intead of strings. + /// It's faster use symbols directly instead of strings. /// /// ### Example /// Bad: @@ -823,7 +823,7 @@ fn suggest_note( cx, COLLAPSIBLE_SPAN_LINT_CALLS, expr.span, - "this call is collspible", + "this call is collapsible", "collapse into", format!( "span_lint_and_note({}, {}, {}, {}, {}, {})", diff --git a/clippy_lints/src/utils/internal_lints/metadata_collector.rs b/clippy_lints/src/utils/internal_lints/metadata_collector.rs index ca03b8010dd..526bb2f7e06 100644 --- a/clippy_lints/src/utils/internal_lints/metadata_collector.rs +++ b/clippy_lints/src/utils/internal_lints/metadata_collector.rs @@ -117,7 +117,7 @@ const APPLICABILITY_NAME_INDEX: usize = 2; /// This applicability will be set for unresolved applicability values. const APPLICABILITY_UNRESOLVED_STR: &str = "Unresolved"; /// The version that will be displayed if none has been defined -const VERION_DEFAULT_STR: &str = "Unknown"; +const VERSION_DEFAULT_STR: &str = "Unknown"; declare_clippy_lint! { /// ### What it does @@ -571,7 +571,7 @@ fn extract_attr_docs(cx: &LateContext<'_>, item: &Item<'_>) -> Option { fn get_lint_version(cx: &LateContext<'_>, item: &Item<'_>) -> String { extract_clippy_version_value(cx, item).map_or_else( - || VERION_DEFAULT_STR.to_string(), + || VERSION_DEFAULT_STR.to_string(), |version| version.as_str().to_string(), ) } @@ -872,7 +872,7 @@ impl<'a, 'hir> IsMultiSpanScanner<'a, 'hir> { self.suggestion_count += 2; } - /// Checks if the suggestions include multiple spanns + /// Checks if the suggestions include multiple spans fn is_multi_part(&self) -> bool { self.suggestion_count > 1 } diff --git a/clippy_utils/src/macros.rs b/clippy_utils/src/macros.rs index e7d4c5a4952..a268e339bb1 100644 --- a/clippy_utils/src/macros.rs +++ b/clippy_utils/src/macros.rs @@ -367,7 +367,7 @@ impl<'tcx> FormatArgsExpn<'tcx> { expr_visitor_no_bodies(|e| { // if we're still inside of the macro definition... if e.span.ctxt() == expr.span.ctxt() { - // ArgumnetV1::new_() + // ArgumentV1::new_() if_chain! { if let ExprKind::Call(callee, [val]) = e.kind; if let ExprKind::Path(QPath::TypeRelative(ty, seg)) = callee.kind; diff --git a/clippy_utils/src/source.rs b/clippy_utils/src/source.rs index beed7326803..c69a3d8d2a1 100644 --- a/clippy_utils/src/source.rs +++ b/clippy_utils/src/source.rs @@ -108,7 +108,7 @@ pub fn is_present_in_source(cx: &T, span: Span) -> bool { true } -/// Returns the positon just before rarrow +/// Returns the position just before rarrow /// /// ```rust,ignore /// fn into(self) -> () {} diff --git a/tests/lint_message_convention.rs b/tests/lint_message_convention.rs index dc82ba891fb..dd1d4412036 100644 --- a/tests/lint_message_convention.rs +++ b/tests/lint_message_convention.rs @@ -66,7 +66,7 @@ fn lint_message_convention() { // make sure that lint messages: // * are not capitalized - // * don't have puncuation at the end of the last sentence + // * don't have punctuation at the end of the last sentence // these directories have interesting tests let test_dirs = ["ui", "ui-cargo", "ui-internal", "ui-toml"] diff --git a/tests/ui/auxiliary/proc_macro_derive.rs b/tests/ui/auxiliary/proc_macro_derive.rs index 4b7b7fec78f..ed7b17651e6 100644 --- a/tests/ui/auxiliary/proc_macro_derive.rs +++ b/tests/ui/auxiliary/proc_macro_derive.rs @@ -13,7 +13,7 @@ use proc_macro::{quote, TokenStream}; #[proc_macro_derive(DeriveSomething)] pub fn derive(_: TokenStream) -> TokenStream { - // Shound not trigger `used_underscore_binding` + // Should not trigger `used_underscore_binding` let _inside_derive = 1; assert_eq!(_inside_derive, _inside_derive); -- cgit 1.4.1-3-g733a5 From 2be7ad5b39b182e7e2ce6cbe2c49a259288cd464 Mon Sep 17 00:00:00 2001 From: whodi Date: Fri, 15 Apr 2022 15:00:44 -0400 Subject: initialization misspell --- clippy_dev/src/setup/git_hook.rs | 2 +- .../src/matches/infallible_destructuring_match.rs | 44 ++++++++++++++++++++++ .../src/matches/infallible_detructuring_match.rs | 44 ---------------------- clippy_lints/src/types/mod.rs | 4 +- tests/ui/needless_late_init.stderr | 18 ++++----- tests/ui/needless_late_init_fixable.stderr | 12 +++--- 6 files changed, 62 insertions(+), 62 deletions(-) create mode 100644 clippy_lints/src/matches/infallible_destructuring_match.rs delete mode 100644 clippy_lints/src/matches/infallible_detructuring_match.rs (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/setup/git_hook.rs b/clippy_dev/src/setup/git_hook.rs index ad4b96f7ff3..3fbb77d5923 100644 --- a/clippy_dev/src/setup/git_hook.rs +++ b/clippy_dev/src/setup/git_hook.rs @@ -18,7 +18,7 @@ pub fn install_hook(force_override: bool) { // So a little bit of a funny story. Git on unix requires the pre-commit file // to have the `execute` permission to be set. The Rust functions for modifying - // these flags doesn't seem to work when executed with normal user permissions. + // these flags doesn't seem to work when executed with normal user permissions. // // However, there is a little hack that is also being used by Rust itself in their // setup script. Git saves the `execute` flag when syncing files. This means diff --git a/clippy_lints/src/matches/infallible_destructuring_match.rs b/clippy_lints/src/matches/infallible_destructuring_match.rs new file mode 100644 index 00000000000..2472acb6f6e --- /dev/null +++ b/clippy_lints/src/matches/infallible_destructuring_match.rs @@ -0,0 +1,44 @@ +use clippy_utils::diagnostics::span_lint_and_sugg; +use clippy_utils::source::snippet_with_applicability; +use clippy_utils::{path_to_local_id, peel_blocks, strip_pat_refs}; +use rustc_errors::Applicability; +use rustc_hir::{ExprKind, Local, MatchSource, PatKind, QPath}; +use rustc_lint::LateContext; + +use super::INFALLIBLE_DESTRUCTURING_MATCH; + +pub(crate) fn check(cx: &LateContext<'_>, local: &Local<'_>) -> bool { + if_chain! { + if !local.span.from_expansion(); + if let Some(expr) = local.init; + if let ExprKind::Match(target, arms, MatchSource::Normal) = expr.kind; + if arms.len() == 1 && arms[0].guard.is_none(); + if let PatKind::TupleStruct( + QPath::Resolved(None, variant_name), args, _) = arms[0].pat.kind; + if args.len() == 1; + if let PatKind::Binding(_, arg, ..) = strip_pat_refs(&args[0]).kind; + let body = peel_blocks(arms[0].body); + if path_to_local_id(body, arg); + + then { + let mut applicability = Applicability::MachineApplicable; + span_lint_and_sugg( + cx, + INFALLIBLE_DESTRUCTURING_MATCH, + local.span, + "you seem to be trying to use `match` to destructure a single infallible pattern. \ + Consider using `let`", + "try this", + format!( + "let {}({}) = {};", + snippet_with_applicability(cx, variant_name.span, "..", &mut applicability), + snippet_with_applicability(cx, local.pat.span, "..", &mut applicability), + snippet_with_applicability(cx, target.span, "..", &mut applicability), + ), + applicability, + ); + return true; + } + } + false +} diff --git a/clippy_lints/src/matches/infallible_detructuring_match.rs b/clippy_lints/src/matches/infallible_detructuring_match.rs deleted file mode 100644 index 2472acb6f6e..00000000000 --- a/clippy_lints/src/matches/infallible_detructuring_match.rs +++ /dev/null @@ -1,44 +0,0 @@ -use clippy_utils::diagnostics::span_lint_and_sugg; -use clippy_utils::source::snippet_with_applicability; -use clippy_utils::{path_to_local_id, peel_blocks, strip_pat_refs}; -use rustc_errors::Applicability; -use rustc_hir::{ExprKind, Local, MatchSource, PatKind, QPath}; -use rustc_lint::LateContext; - -use super::INFALLIBLE_DESTRUCTURING_MATCH; - -pub(crate) fn check(cx: &LateContext<'_>, local: &Local<'_>) -> bool { - if_chain! { - if !local.span.from_expansion(); - if let Some(expr) = local.init; - if let ExprKind::Match(target, arms, MatchSource::Normal) = expr.kind; - if arms.len() == 1 && arms[0].guard.is_none(); - if let PatKind::TupleStruct( - QPath::Resolved(None, variant_name), args, _) = arms[0].pat.kind; - if args.len() == 1; - if let PatKind::Binding(_, arg, ..) = strip_pat_refs(&args[0]).kind; - let body = peel_blocks(arms[0].body); - if path_to_local_id(body, arg); - - then { - let mut applicability = Applicability::MachineApplicable; - span_lint_and_sugg( - cx, - INFALLIBLE_DESTRUCTURING_MATCH, - local.span, - "you seem to be trying to use `match` to destructure a single infallible pattern. \ - Consider using `let`", - "try this", - format!( - "let {}({}) = {};", - snippet_with_applicability(cx, variant_name.span, "..", &mut applicability), - snippet_with_applicability(cx, local.pat.span, "..", &mut applicability), - snippet_with_applicability(cx, target.span, "..", &mut applicability), - ), - applicability, - ); - return true; - } - } - false -} diff --git a/clippy_lints/src/types/mod.rs b/clippy_lints/src/types/mod.rs index b1b2addb9a1..353a6f6b899 100644 --- a/clippy_lints/src/types/mod.rs +++ b/clippy_lints/src/types/mod.rs @@ -432,8 +432,8 @@ impl Types { fn check_fn_decl(&mut self, cx: &LateContext<'_>, decl: &FnDecl<'_>, context: CheckTyContext) { // Ignore functions in trait implementations as they are usually forced by the trait definition. // - // FIXME: ideally we would like to warn *if the complicated type can be simplified*, but it's hard to - // check. + // FIXME: ideally we would like to warn *if the complicated type can be simplified*, but it's hard + // to check. if context.is_in_trait_impl { return; } diff --git a/tests/ui/needless_late_init.stderr b/tests/ui/needless_late_init.stderr index 9ef8bb23df6..124fe5592c3 100644 --- a/tests/ui/needless_late_init.stderr +++ b/tests/ui/needless_late_init.stderr @@ -1,4 +1,4 @@ -error: unneeded late initalization +error: unneeded late initialization --> $DIR/needless_late_init.rs:5:5 | LL | let a; @@ -20,7 +20,7 @@ help: add a semicolon after the `match` expression LL | }; | + -error: unneeded late initalization +error: unneeded late initialization --> $DIR/needless_late_init.rs:14:5 | LL | let b; @@ -41,7 +41,7 @@ help: add a semicolon after the `if` expression LL | }; | + -error: unneeded late initalization +error: unneeded late initialization --> $DIR/needless_late_init.rs:21:5 | LL | let c; @@ -62,7 +62,7 @@ help: add a semicolon after the `if` expression LL | }; | + -error: unneeded late initalization +error: unneeded late initialization --> $DIR/needless_late_init.rs:28:5 | LL | let d; @@ -83,7 +83,7 @@ help: add a semicolon after the `if` expression LL | }; | + -error: unneeded late initalization +error: unneeded late initialization --> $DIR/needless_late_init.rs:36:5 | LL | let e; @@ -104,7 +104,7 @@ help: add a semicolon after the `if` expression LL | }; | + -error: unneeded late initalization +error: unneeded late initialization --> $DIR/needless_late_init.rs:43:5 | LL | let f; @@ -120,7 +120,7 @@ LL - 1 => f = "three", LL + 1 => "three", | -error: unneeded late initalization +error: unneeded late initialization --> $DIR/needless_late_init.rs:49:5 | LL | let g: usize; @@ -140,7 +140,7 @@ help: add a semicolon after the `if` expression LL | }; | + -error: unneeded late initalization +error: unneeded late initialization --> $DIR/needless_late_init.rs:64:5 | LL | let a; @@ -161,7 +161,7 @@ help: add a semicolon after the `match` expression LL | }; | + -error: unneeded late initalization +error: unneeded late initialization --> $DIR/needless_late_init.rs:81:5 | LL | let a; diff --git a/tests/ui/needless_late_init_fixable.stderr b/tests/ui/needless_late_init_fixable.stderr index 3f3d4f5286b..34dccc2cec8 100644 --- a/tests/ui/needless_late_init_fixable.stderr +++ b/tests/ui/needless_late_init_fixable.stderr @@ -1,4 +1,4 @@ -error: unneeded late initalization +error: unneeded late initialization --> $DIR/needless_late_init_fixable.rs:6:5 | LL | let a; @@ -10,7 +10,7 @@ help: declare `a` here LL | let a = "zero"; | ~~~~~ -error: unneeded late initalization +error: unneeded late initialization --> $DIR/needless_late_init_fixable.rs:9:5 | LL | let b; @@ -21,7 +21,7 @@ help: declare `b` here LL | let b = 1; | ~~~~~ -error: unneeded late initalization +error: unneeded late initialization --> $DIR/needless_late_init_fixable.rs:10:5 | LL | let c; @@ -32,7 +32,7 @@ help: declare `c` here LL | let c = 2; | ~~~~~ -error: unneeded late initalization +error: unneeded late initialization --> $DIR/needless_late_init_fixable.rs:14:5 | LL | let d: usize; @@ -43,7 +43,7 @@ help: declare `d` here LL | let d: usize = 1; | ~~~~~~~~~~~~ -error: unneeded late initalization +error: unneeded late initialization --> $DIR/needless_late_init_fixable.rs:17:5 | LL | let mut e; @@ -54,7 +54,7 @@ help: declare `e` here LL | let mut e = 1; | ~~~~~~~~~ -error: unneeded late initalization +error: unneeded late initialization --> $DIR/needless_late_init_fixable.rs:21:5 | LL | let h; -- cgit 1.4.1-3-g733a5 From b3de32ba3cc2985c4e1d890732548a99fd55bba0 Mon Sep 17 00:00:00 2001 From: Jason Newcomb Date: Sun, 3 Apr 2022 20:28:47 -0400 Subject: Add `rename_lint` command --- clippy_dev/Cargo.toml | 1 + clippy_dev/src/lib.rs | 1 + clippy_dev/src/main.rs | 33 +++- clippy_dev/src/update_lints.rs | 308 +++++++++++++++++++++++++++++++++++--- clippy_lints/src/renamed_lints.rs | 50 ++++--- tests/ui/rename.fixed | 84 +++++------ tests/ui/rename.rs | 84 +++++------ tests/ui/rename.stderr | 180 +++++++++++----------- 8 files changed, 523 insertions(+), 218 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/Cargo.toml b/clippy_dev/Cargo.toml index 1f2d8adecee..7bca17dc0fd 100644 --- a/clippy_dev/Cargo.toml +++ b/clippy_dev/Cargo.toml @@ -4,6 +4,7 @@ version = "0.0.1" edition = "2021" [dependencies] +aho-corasick = "0.7" clap = "2.33" indoc = "1.0" itertools = "0.10.1" diff --git a/clippy_dev/src/lib.rs b/clippy_dev/src/lib.rs index 414b403827d..c4bb0b97e25 100644 --- a/clippy_dev/src/lib.rs +++ b/clippy_dev/src/lib.rs @@ -1,3 +1,4 @@ +#![feature(let_chains)] #![feature(let_else)] #![feature(once_cell)] #![feature(rustc_private)] diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index 30a241c8ba1..b30f67e6959 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -18,9 +18,9 @@ fn main() { if matches.is_present("print-only") { update_lints::print_lints(); } else if matches.is_present("check") { - update_lints::run(update_lints::UpdateMode::Check); + update_lints::update(update_lints::UpdateMode::Check); } else { - update_lints::run(update_lints::UpdateMode::Change); + update_lints::update(update_lints::UpdateMode::Change); } }, ("new_lint", Some(matches)) => { @@ -30,7 +30,7 @@ fn main() { matches.value_of("category"), matches.is_present("msrv"), ) { - Ok(_) => update_lints::run(update_lints::UpdateMode::Change), + Ok(_) => update_lints::update(update_lints::UpdateMode::Change), Err(e) => eprintln!("Unable to create lint: {}", e), } }, @@ -59,6 +59,12 @@ fn main() { let filename = matches.value_of("filename").unwrap(); lint::run(filename); }, + ("rename_lint", Some(matches)) => { + let old_name = matches.value_of("old_name").unwrap(); + let new_name = matches.value_of("new_name").unwrap_or(old_name); + let uplift = matches.is_present("uplift"); + update_lints::rename(old_name, new_name, uplift); + }, _ => {}, } } @@ -232,5 +238,26 @@ fn get_clap_config<'a>() -> ArgMatches<'a> { .help("The path to a file to lint"), ), ) + .subcommand( + SubCommand::with_name("rename_lint") + .about("Renames the given lint") + .arg( + Arg::with_name("old_name") + .index(1) + .required(true) + .help("The name of the lint to rename"), + ) + .arg( + Arg::with_name("new_name") + .index(2) + .required_unless("uplift") + .help("The new name of the lint"), + ) + .arg( + Arg::with_name("uplift") + .long("uplift") + .help("This lint will be uplifted into rustc"), + ), + ) .get_matches() } diff --git a/clippy_dev/src/update_lints.rs b/clippy_dev/src/update_lints.rs index f15b00ecad1..bbce3875e1d 100644 --- a/clippy_dev/src/update_lints.rs +++ b/clippy_dev/src/update_lints.rs @@ -1,11 +1,13 @@ -use core::fmt::Write; +use aho_corasick::AhoCorasickBuilder; +use core::fmt::Write as _; use itertools::Itertools; use rustc_lexer::{tokenize, unescape, LiteralKind, TokenKind}; use std::collections::{HashMap, HashSet}; use std::ffi::OsStr; use std::fs; -use std::path::Path; -use walkdir::WalkDir; +use std::io::{self, Read as _, Seek as _, Write as _}; +use std::path::{Path, PathBuf}; +use walkdir::{DirEntry, WalkDir}; use crate::clippy_project_root; @@ -30,12 +32,19 @@ pub enum UpdateMode { /// # Panics /// /// Panics if a file path could not read from or then written to -#[allow(clippy::too_many_lines)] -pub fn run(update_mode: UpdateMode) { +pub fn update(update_mode: UpdateMode) { let (lints, deprecated_lints, renamed_lints) = gather_all(); + generate_lint_files(update_mode, &lints, &deprecated_lints, &renamed_lints); +} - let internal_lints = Lint::internal_lints(&lints); - let usable_lints = Lint::usable_lints(&lints); +fn generate_lint_files( + update_mode: UpdateMode, + lints: &[Lint], + deprecated_lints: &[DeprecatedLint], + renamed_lints: &[RenamedLint], +) { + let internal_lints = Lint::internal_lints(lints); + let usable_lints = Lint::usable_lints(lints); let mut sorted_usable_lints = usable_lints.clone(); sorted_usable_lints.sort_by_key(|lint| lint.name.clone()); @@ -87,7 +96,7 @@ pub fn run(update_mode: UpdateMode) { process_file( "clippy_lints/src/lib.deprecated.rs", update_mode, - &gen_deprecated(&deprecated_lints), + &gen_deprecated(deprecated_lints), ); let all_group_lints = usable_lints.iter().filter(|l| { @@ -108,10 +117,10 @@ pub fn run(update_mode: UpdateMode) { ); } - let content = gen_deprecated_lints_test(&deprecated_lints); + let content = gen_deprecated_lints_test(deprecated_lints); process_file("tests/ui/deprecated.rs", update_mode, &content); - let content = gen_renamed_lints_test(&renamed_lints); + let content = gen_renamed_lints_test(renamed_lints); process_file("tests/ui/rename.rs", update_mode, &content); } @@ -134,6 +143,209 @@ pub fn print_lints() { println!("there are {} lints", usable_lint_count); } +/// Runs the `rename_lint` command. +/// +/// This does the following: +/// * Adds an entry to `renamed_lints.rs`. +/// * Renames all lint attributes to the new name (e.g. `#[allow(clippy::lint_name)]`). +/// * Renames the lint struct to the new name. +/// * Renames the module containing the lint struct to the new name if it shares a name with the +/// lint. +/// +/// # Panics +/// Panics for the following conditions: +/// * If a file path could not read from or then written to +/// * If either lint name has a prefix +/// * If `old_name` doesn't name an existing lint. +/// * If `old_name` names a deprecated or renamed lint. +#[allow(clippy::too_many_lines)] +pub fn rename(old_name: &str, new_name: &str, uplift: bool) { + if let Some((prefix, _)) = old_name.split_once("::") { + panic!("`{}` should not contain the `{}` prefix", old_name, prefix); + } + if let Some((prefix, _)) = new_name.split_once("::") { + panic!("`{}` should not contain the `{}` prefix", new_name, prefix); + } + + let (mut lints, deprecated_lints, mut renamed_lints) = gather_all(); + let mut old_lint_index = None; + let mut found_new_name = false; + for (i, lint) in lints.iter().enumerate() { + if lint.name == old_name { + old_lint_index = Some(i); + } else if lint.name == new_name { + found_new_name = true; + } + } + let old_lint_index = old_lint_index.unwrap_or_else(|| panic!("could not find lint `{}`", old_name)); + + let lint = RenamedLint { + old_name: format!("clippy::{}", old_name), + new_name: if uplift { + new_name.into() + } else { + format!("clippy::{}", new_name) + }, + }; + + // Renamed lints and deprecated lints shouldn't have been found in the lint list, but check just in + // case. + assert!( + !renamed_lints.iter().any(|l| lint.old_name == l.old_name), + "`{}` has already been renamed", + old_name + ); + assert!( + !deprecated_lints.iter().any(|l| lint.old_name == l.name), + "`{}` has already been deprecated", + old_name + ); + + // Update all lint level attributes. (`clippy::lint_name`) + for file in WalkDir::new(clippy_project_root()) + .into_iter() + .map(Result::unwrap) + .filter(|f| { + let name = f.path().file_name(); + let ext = f.path().extension(); + (ext == Some(OsStr::new("rs")) || ext == Some(OsStr::new("fixed"))) + && name != Some(OsStr::new("rename.rs")) + && name != Some(OsStr::new("renamed_lints.rs")) + }) + { + rewrite_file(file.path(), |s| { + replace_ident_like(s, &[(&lint.old_name, &lint.new_name)]) + }); + } + + renamed_lints.push(lint); + renamed_lints.sort_by(|lhs, rhs| { + lhs.new_name + .starts_with("clippy::") + .cmp(&rhs.new_name.starts_with("clippy::")) + .reverse() + .then_with(|| lhs.old_name.cmp(&rhs.old_name)) + }); + + write_file( + Path::new("clippy_lints/src/renamed_lints.rs"), + &gen_renamed_lints_list(&renamed_lints), + ); + + if uplift { + write_file(Path::new("tests/ui/rename.rs"), &gen_renamed_lints_test(&renamed_lints)); + println!( + "`{}` has be uplifted. All the code inside `clippy_lints` related to it needs to be removed manually.", + old_name + ); + } else if found_new_name { + write_file(Path::new("tests/ui/rename.rs"), &gen_renamed_lints_test(&renamed_lints)); + println!( + "`{}` is already defined. The old linting code inside `clippy_lints` needs to be updated/removed manually.", + new_name + ); + } else { + // Rename the lint struct and source files sharing a name with the lint. + let lint = &mut lints[old_lint_index]; + let old_name_upper = old_name.to_uppercase(); + let new_name_upper = new_name.to_uppercase(); + lint.name = new_name.into(); + + // Rename test files. only rename `.stderr` and `.fixed` files if the new test name doesn't exist. + if try_rename_file( + Path::new(&format!("tests/ui/{}.rs", old_name)), + Path::new(&format!("tests/ui/{}.rs", new_name)), + ) { + try_rename_file( + Path::new(&format!("tests/ui/{}.stderr", old_name)), + Path::new(&format!("tests/ui/{}.stderr", new_name)), + ); + try_rename_file( + Path::new(&format!("tests/ui/{}.fixed", old_name)), + Path::new(&format!("tests/ui/{}.fixed", new_name)), + ); + } + + // Try to rename the file containing the lint if the file name matches the lint's name. + let replacements; + let replacements = if lint.module == old_name + && try_rename_file( + Path::new(&format!("clippy_lints/src/{}.rs", old_name)), + Path::new(&format!("clippy_lints/src/{}.rs", new_name)), + ) { + // Edit the module name in the lint list. Note there could be multiple lints. + for lint in lints.iter_mut().filter(|l| l.module == old_name) { + lint.module = new_name.into(); + } + replacements = [(&*old_name_upper, &*new_name_upper), (old_name, new_name)]; + replacements.as_slice() + } else if !lint.module.contains("::") + // Catch cases like `methods/lint_name.rs` where the lint is stored in `methods/mod.rs` + && try_rename_file( + Path::new(&format!("clippy_lints/src/{}/{}.rs", lint.module, old_name)), + Path::new(&format!("clippy_lints/src/{}/{}.rs", lint.module, new_name)), + ) + { + // Edit the module name in the lint list. Note there could be multiple lints, or none. + let renamed_mod = format!("{}::{}", lint.module, old_name); + for lint in lints.iter_mut().filter(|l| l.module == renamed_mod) { + lint.module = format!("{}::{}", lint.module, new_name); + } + replacements = [(&*old_name_upper, &*new_name_upper), (old_name, new_name)]; + replacements.as_slice() + } else { + replacements = [(&*old_name_upper, &*new_name_upper), ("", "")]; + &replacements[0..1] + }; + + // Don't change `clippy_utils/src/renamed_lints.rs` here as it would try to edit the lint being + // renamed. + for (_, file) in clippy_lints_src_files().filter(|(rel_path, _)| rel_path != OsStr::new("renamed_lints.rs")) { + rewrite_file(file.path(), |s| replace_ident_like(s, replacements)); + } + + generate_lint_files(UpdateMode::Change, &lints, &deprecated_lints, &renamed_lints); + println!("{} has been successfully renamed", old_name); + } + + println!("note: `cargo uitest` still needs to be run to update the test results"); +} + +/// Replace substrings if they aren't bordered by identifier characters. Returns `None` if there +/// were no replacements. +fn replace_ident_like(contents: &str, replacements: &[(&str, &str)]) -> Option { + fn is_ident_char(c: u8) -> bool { + matches!(c, b'a'..=b'z' | b'A'..=b'Z' | b'0'..=b'9' | b'_') + } + + let searcher = AhoCorasickBuilder::new() + .dfa(true) + .match_kind(aho_corasick::MatchKind::LeftmostLongest) + .build_with_size::(replacements.iter().map(|&(x, _)| x.as_bytes())) + .unwrap(); + + let mut result = String::with_capacity(contents.len() + 1024); + let mut pos = 0; + let mut edited = false; + for m in searcher.find_iter(contents) { + let (old, new) = replacements[m.pattern()]; + result.push_str(&contents[pos..m.start()]); + result.push_str( + if !is_ident_char(contents.as_bytes().get(m.start().wrapping_sub(1)).copied().unwrap_or(0)) + && !is_ident_char(contents.as_bytes().get(m.end()).copied().unwrap_or(0)) + { + edited = true; + new + } else { + old + }, + ); + pos = m.end(); + } + result.push_str(&contents[pos..]); + edited.then(|| result) +} + fn round_to_fifty(count: usize) -> usize { count / 50 * 50 } @@ -323,19 +535,27 @@ fn gen_renamed_lints_test(lints: &[RenamedLint]) -> String { res } +fn gen_renamed_lints_list(lints: &[RenamedLint]) -> String { + const HEADER: &str = "\ + // This file is managed by `cargo dev rename_lint`. Prefer using that when possible.\n\n\ + #[rustfmt::skip]\n\ + pub static RENAMED_LINTS: &[(&str, &str)] = &[\n"; + + let mut res = String::from(HEADER); + for lint in lints { + writeln!(res, " (\"{}\", \"{}\"),", lint.old_name, lint.new_name).unwrap(); + } + res.push_str("];\n"); + res +} + /// Gathers all lints defined in `clippy_lints/src` fn gather_all() -> (Vec, Vec, Vec) { let mut lints = Vec::with_capacity(1000); let mut deprecated_lints = Vec::with_capacity(50); let mut renamed_lints = Vec::with_capacity(50); - let root_path = clippy_project_root().join("clippy_lints/src"); - for (rel_path, file) in WalkDir::new(&root_path) - .into_iter() - .map(Result::unwrap) - .filter(|f| f.path().extension() == Some(OsStr::new("rs"))) - .map(|f| (f.path().strip_prefix(&root_path).unwrap().to_path_buf(), f)) - { + for (rel_path, file) in clippy_lints_src_files() { let path = file.path(); let contents = fs::read_to_string(path).unwrap_or_else(|e| panic!("Cannot read from `{}`: {}", path.display(), e)); @@ -362,6 +582,14 @@ fn gather_all() -> (Vec, Vec, Vec) { (lints, deprecated_lints, renamed_lints) } +fn clippy_lints_src_files() -> impl Iterator { + let root_path = clippy_project_root().join("clippy_lints/src"); + let iter = WalkDir::new(&root_path).into_iter(); + iter.map(Result::unwrap) + .filter(|f| f.path().extension() == Some(OsStr::new("rs"))) + .map(move |f| (f.path().strip_prefix(&root_path).unwrap().to_path_buf(), f)) +} + macro_rules! match_tokens { ($iter:ident, $($token:ident $({$($fields:tt)*})? $(($capture:ident))?)*) => { { @@ -526,6 +754,52 @@ fn replace_region_in_text<'a>( Ok(res) } +fn try_rename_file(old_name: &Path, new_name: &Path) -> bool { + match fs::OpenOptions::new().create_new(true).write(true).open(new_name) { + Ok(file) => drop(file), + Err(e) if matches!(e.kind(), io::ErrorKind::AlreadyExists | io::ErrorKind::NotFound) => return false, + Err(e) => panic_file(e, new_name, "create"), + }; + match fs::rename(old_name, new_name) { + Ok(()) => true, + Err(e) => { + drop(fs::remove_file(new_name)); + if e.kind() == io::ErrorKind::NotFound { + false + } else { + panic_file(e, old_name, "rename"); + } + }, + } +} + +#[allow(clippy::needless_pass_by_value)] +fn panic_file(error: io::Error, name: &Path, action: &str) -> ! { + panic!("failed to {} file `{}`: {}", action, name.display(), error) +} + +fn rewrite_file(path: &Path, f: impl FnOnce(&str) -> Option) { + let mut file = fs::OpenOptions::new() + .write(true) + .read(true) + .open(path) + .unwrap_or_else(|e| panic_file(e, path, "open")); + let mut buf = String::new(); + file.read_to_string(&mut buf) + .unwrap_or_else(|e| panic_file(e, path, "read")); + if let Some(new_contents) = f(&buf) { + file.rewind().unwrap_or_else(|e| panic_file(e, path, "write")); + file.write_all(new_contents.as_bytes()) + .unwrap_or_else(|e| panic_file(e, path, "write")); + file.set_len(new_contents.len() as u64) + .unwrap_or_else(|e| panic_file(e, path, "write")); + } +} + +fn write_file(path: &Path, contents: &str) { + fs::write(path, contents).unwrap_or_else(|e| panic_file(e, path, "write")); +} + #[cfg(test)] mod tests { use super::*; diff --git a/clippy_lints/src/renamed_lints.rs b/clippy_lints/src/renamed_lints.rs index e10dc0e1bfe..bfc03116fe2 100644 --- a/clippy_lints/src/renamed_lints.rs +++ b/clippy_lints/src/renamed_lints.rs @@ -1,37 +1,39 @@ +// This file is managed by `cargo dev rename_lint`. Prefer using that when possible. + +#[rustfmt::skip] pub static RENAMED_LINTS: &[(&str, &str)] = &[ - ("clippy::stutter", "clippy::module_name_repetitions"), - ("clippy::new_without_default_derive", "clippy::new_without_default"), - ("clippy::cyclomatic_complexity", "clippy::cognitive_complexity"), - ("clippy::const_static_lifetime", "clippy::redundant_static_lifetimes"), - ("clippy::option_and_then_some", "clippy::bind_instead_of_map"), - ("clippy::box_vec", "clippy::box_collection"), ("clippy::block_in_if_condition_expr", "clippy::blocks_in_if_conditions"), ("clippy::block_in_if_condition_stmt", "clippy::blocks_in_if_conditions"), - ("clippy::option_map_unwrap_or", "clippy::map_unwrap_or"), - ("clippy::option_map_unwrap_or_else", "clippy::map_unwrap_or"), - ("clippy::result_map_unwrap_or_else", "clippy::map_unwrap_or"), - ("clippy::option_unwrap_used", "clippy::unwrap_used"), - ("clippy::result_unwrap_used", "clippy::unwrap_used"), - ("clippy::option_expect_used", "clippy::expect_used"), - ("clippy::result_expect_used", "clippy::expect_used"), + ("clippy::box_vec", "clippy::box_collection"), + ("clippy::const_static_lifetime", "clippy::redundant_static_lifetimes"), + ("clippy::cyclomatic_complexity", "clippy::cognitive_complexity"), + ("clippy::disallowed_method", "clippy::disallowed_methods"), + ("clippy::disallowed_type", "clippy::disallowed_types"), ("clippy::for_loop_over_option", "clippy::for_loops_over_fallibles"), ("clippy::for_loop_over_result", "clippy::for_loops_over_fallibles"), ("clippy::identity_conversion", "clippy::useless_conversion"), - ("clippy::zero_width_space", "clippy::invisible_characters"), - ("clippy::single_char_push_str", "clippy::single_char_add_str"), ("clippy::if_let_some_result", "clippy::match_result_ok"), - ("clippy::disallowed_type", "clippy::disallowed_types"), - ("clippy::disallowed_method", "clippy::disallowed_methods"), + ("clippy::new_without_default_derive", "clippy::new_without_default"), + ("clippy::option_and_then_some", "clippy::bind_instead_of_map"), + ("clippy::option_expect_used", "clippy::expect_used"), + ("clippy::option_map_unwrap_or", "clippy::map_unwrap_or"), + ("clippy::option_map_unwrap_or_else", "clippy::map_unwrap_or"), + ("clippy::option_unwrap_used", "clippy::unwrap_used"), ("clippy::ref_in_deref", "clippy::needless_borrow"), + ("clippy::result_expect_used", "clippy::expect_used"), + ("clippy::result_map_unwrap_or_else", "clippy::map_unwrap_or"), + ("clippy::result_unwrap_used", "clippy::unwrap_used"), + ("clippy::single_char_push_str", "clippy::single_char_add_str"), + ("clippy::stutter", "clippy::module_name_repetitions"), ("clippy::to_string_in_display", "clippy::recursive_format_impl"), - // uplifted lints - ("clippy::invalid_ref", "invalid_value"), - ("clippy::into_iter_on_array", "array_into_iter"), - ("clippy::unused_label", "unused_labels"), + ("clippy::zero_width_space", "clippy::invisible_characters"), ("clippy::drop_bounds", "drop_bounds"), - ("clippy::temporary_cstring_as_ptr", "temporary_cstring_as_ptr"), - ("clippy::panic_params", "non_fmt_panics"), - ("clippy::unknown_clippy_lints", "unknown_lints"), + ("clippy::into_iter_on_array", "array_into_iter"), ("clippy::invalid_atomic_ordering", "invalid_atomic_ordering"), + ("clippy::invalid_ref", "invalid_value"), ("clippy::mem_discriminant_non_enum", "enum_intrinsics_non_enums"), + ("clippy::panic_params", "non_fmt_panics"), + ("clippy::temporary_cstring_as_ptr", "temporary_cstring_as_ptr"), + ("clippy::unknown_clippy_lints", "unknown_lints"), + ("clippy::unused_label", "unused_labels"), ]; diff --git a/tests/ui/rename.fixed b/tests/ui/rename.fixed index 325f63a64dd..9c4079ad6d3 100644 --- a/tests/ui/rename.fixed +++ b/tests/ui/rename.fixed @@ -4,67 +4,67 @@ // run-rustfix -#![allow(clippy::module_name_repetitions)] -#![allow(clippy::new_without_default)] -#![allow(clippy::cognitive_complexity)] -#![allow(clippy::redundant_static_lifetimes)] -#![allow(clippy::bind_instead_of_map)] -#![allow(clippy::box_collection)] #![allow(clippy::blocks_in_if_conditions)] -#![allow(clippy::map_unwrap_or)] -#![allow(clippy::unwrap_used)] -#![allow(clippy::expect_used)] +#![allow(clippy::box_collection)] +#![allow(clippy::redundant_static_lifetimes)] +#![allow(clippy::cognitive_complexity)] +#![allow(clippy::disallowed_methods)] +#![allow(clippy::disallowed_types)] #![allow(clippy::for_loops_over_fallibles)] #![allow(clippy::useless_conversion)] -#![allow(clippy::invisible_characters)] -#![allow(clippy::single_char_add_str)] #![allow(clippy::match_result_ok)] -#![allow(clippy::disallowed_types)] -#![allow(clippy::disallowed_methods)] +#![allow(clippy::new_without_default)] +#![allow(clippy::bind_instead_of_map)] +#![allow(clippy::expect_used)] +#![allow(clippy::map_unwrap_or)] +#![allow(clippy::unwrap_used)] #![allow(clippy::needless_borrow)] +#![allow(clippy::single_char_add_str)] +#![allow(clippy::module_name_repetitions)] #![allow(clippy::recursive_format_impl)] -#![allow(invalid_value)] -#![allow(array_into_iter)] -#![allow(unused_labels)] +#![allow(clippy::invisible_characters)] #![allow(drop_bounds)] -#![allow(temporary_cstring_as_ptr)] -#![allow(non_fmt_panics)] -#![allow(unknown_lints)] +#![allow(array_into_iter)] #![allow(invalid_atomic_ordering)] +#![allow(invalid_value)] #![allow(enum_intrinsics_non_enums)] -#![warn(clippy::module_name_repetitions)] -#![warn(clippy::new_without_default)] -#![warn(clippy::cognitive_complexity)] -#![warn(clippy::redundant_static_lifetimes)] -#![warn(clippy::bind_instead_of_map)] -#![warn(clippy::box_collection)] +#![allow(non_fmt_panics)] +#![allow(temporary_cstring_as_ptr)] +#![allow(unknown_lints)] +#![allow(unused_labels)] #![warn(clippy::blocks_in_if_conditions)] #![warn(clippy::blocks_in_if_conditions)] -#![warn(clippy::map_unwrap_or)] -#![warn(clippy::map_unwrap_or)] -#![warn(clippy::map_unwrap_or)] -#![warn(clippy::unwrap_used)] -#![warn(clippy::unwrap_used)] -#![warn(clippy::expect_used)] -#![warn(clippy::expect_used)] +#![warn(clippy::box_collection)] +#![warn(clippy::redundant_static_lifetimes)] +#![warn(clippy::cognitive_complexity)] +#![warn(clippy::disallowed_methods)] +#![warn(clippy::disallowed_types)] #![warn(clippy::for_loops_over_fallibles)] #![warn(clippy::for_loops_over_fallibles)] #![warn(clippy::useless_conversion)] -#![warn(clippy::invisible_characters)] -#![warn(clippy::single_char_add_str)] #![warn(clippy::match_result_ok)] -#![warn(clippy::disallowed_types)] -#![warn(clippy::disallowed_methods)] +#![warn(clippy::new_without_default)] +#![warn(clippy::bind_instead_of_map)] +#![warn(clippy::expect_used)] +#![warn(clippy::map_unwrap_or)] +#![warn(clippy::map_unwrap_or)] +#![warn(clippy::unwrap_used)] #![warn(clippy::needless_borrow)] +#![warn(clippy::expect_used)] +#![warn(clippy::map_unwrap_or)] +#![warn(clippy::unwrap_used)] +#![warn(clippy::single_char_add_str)] +#![warn(clippy::module_name_repetitions)] #![warn(clippy::recursive_format_impl)] -#![warn(invalid_value)] -#![warn(array_into_iter)] -#![warn(unused_labels)] +#![warn(clippy::invisible_characters)] #![warn(drop_bounds)] -#![warn(temporary_cstring_as_ptr)] -#![warn(non_fmt_panics)] -#![warn(unknown_lints)] +#![warn(array_into_iter)] #![warn(invalid_atomic_ordering)] +#![warn(invalid_value)] #![warn(enum_intrinsics_non_enums)] +#![warn(non_fmt_panics)] +#![warn(temporary_cstring_as_ptr)] +#![warn(unknown_lints)] +#![warn(unused_labels)] fn main() {} diff --git a/tests/ui/rename.rs b/tests/ui/rename.rs index a21b4a24288..e83e66b7fbd 100644 --- a/tests/ui/rename.rs +++ b/tests/ui/rename.rs @@ -4,67 +4,67 @@ // run-rustfix -#![allow(clippy::module_name_repetitions)] -#![allow(clippy::new_without_default)] -#![allow(clippy::cognitive_complexity)] -#![allow(clippy::redundant_static_lifetimes)] -#![allow(clippy::bind_instead_of_map)] -#![allow(clippy::box_collection)] #![allow(clippy::blocks_in_if_conditions)] -#![allow(clippy::map_unwrap_or)] -#![allow(clippy::unwrap_used)] -#![allow(clippy::expect_used)] +#![allow(clippy::box_collection)] +#![allow(clippy::redundant_static_lifetimes)] +#![allow(clippy::cognitive_complexity)] +#![allow(clippy::disallowed_methods)] +#![allow(clippy::disallowed_types)] #![allow(clippy::for_loops_over_fallibles)] #![allow(clippy::useless_conversion)] -#![allow(clippy::invisible_characters)] -#![allow(clippy::single_char_add_str)] #![allow(clippy::match_result_ok)] -#![allow(clippy::disallowed_types)] -#![allow(clippy::disallowed_methods)] +#![allow(clippy::new_without_default)] +#![allow(clippy::bind_instead_of_map)] +#![allow(clippy::expect_used)] +#![allow(clippy::map_unwrap_or)] +#![allow(clippy::unwrap_used)] #![allow(clippy::needless_borrow)] +#![allow(clippy::single_char_add_str)] +#![allow(clippy::module_name_repetitions)] #![allow(clippy::recursive_format_impl)] -#![allow(invalid_value)] -#![allow(array_into_iter)] -#![allow(unused_labels)] +#![allow(clippy::invisible_characters)] #![allow(drop_bounds)] -#![allow(temporary_cstring_as_ptr)] -#![allow(non_fmt_panics)] -#![allow(unknown_lints)] +#![allow(array_into_iter)] #![allow(invalid_atomic_ordering)] +#![allow(invalid_value)] #![allow(enum_intrinsics_non_enums)] -#![warn(clippy::stutter)] -#![warn(clippy::new_without_default_derive)] -#![warn(clippy::cyclomatic_complexity)] -#![warn(clippy::const_static_lifetime)] -#![warn(clippy::option_and_then_some)] -#![warn(clippy::box_vec)] +#![allow(non_fmt_panics)] +#![allow(temporary_cstring_as_ptr)] +#![allow(unknown_lints)] +#![allow(unused_labels)] #![warn(clippy::block_in_if_condition_expr)] #![warn(clippy::block_in_if_condition_stmt)] -#![warn(clippy::option_map_unwrap_or)] -#![warn(clippy::option_map_unwrap_or_else)] -#![warn(clippy::result_map_unwrap_or_else)] -#![warn(clippy::option_unwrap_used)] -#![warn(clippy::result_unwrap_used)] -#![warn(clippy::option_expect_used)] -#![warn(clippy::result_expect_used)] +#![warn(clippy::box_vec)] +#![warn(clippy::const_static_lifetime)] +#![warn(clippy::cyclomatic_complexity)] +#![warn(clippy::disallowed_method)] +#![warn(clippy::disallowed_type)] #![warn(clippy::for_loop_over_option)] #![warn(clippy::for_loop_over_result)] #![warn(clippy::identity_conversion)] -#![warn(clippy::zero_width_space)] -#![warn(clippy::single_char_push_str)] #![warn(clippy::if_let_some_result)] -#![warn(clippy::disallowed_type)] -#![warn(clippy::disallowed_method)] +#![warn(clippy::new_without_default_derive)] +#![warn(clippy::option_and_then_some)] +#![warn(clippy::option_expect_used)] +#![warn(clippy::option_map_unwrap_or)] +#![warn(clippy::option_map_unwrap_or_else)] +#![warn(clippy::option_unwrap_used)] #![warn(clippy::ref_in_deref)] +#![warn(clippy::result_expect_used)] +#![warn(clippy::result_map_unwrap_or_else)] +#![warn(clippy::result_unwrap_used)] +#![warn(clippy::single_char_push_str)] +#![warn(clippy::stutter)] #![warn(clippy::to_string_in_display)] -#![warn(clippy::invalid_ref)] -#![warn(clippy::into_iter_on_array)] -#![warn(clippy::unused_label)] +#![warn(clippy::zero_width_space)] #![warn(clippy::drop_bounds)] -#![warn(clippy::temporary_cstring_as_ptr)] -#![warn(clippy::panic_params)] -#![warn(clippy::unknown_clippy_lints)] +#![warn(clippy::into_iter_on_array)] #![warn(clippy::invalid_atomic_ordering)] +#![warn(clippy::invalid_ref)] #![warn(clippy::mem_discriminant_non_enum)] +#![warn(clippy::panic_params)] +#![warn(clippy::temporary_cstring_as_ptr)] +#![warn(clippy::unknown_clippy_lints)] +#![warn(clippy::unused_label)] fn main() {} diff --git a/tests/ui/rename.stderr b/tests/ui/rename.stderr index 54e12d5fae5..f811b10d017 100644 --- a/tests/ui/rename.stderr +++ b/tests/ui/rename.stderr @@ -1,22 +1,22 @@ -error: lint `clippy::stutter` has been renamed to `clippy::module_name_repetitions` +error: lint `clippy::block_in_if_condition_expr` has been renamed to `clippy::blocks_in_if_conditions` --> $DIR/rename.rs:35:9 | -LL | #![warn(clippy::stutter)] - | ^^^^^^^^^^^^^^^ help: use the new name: `clippy::module_name_repetitions` +LL | #![warn(clippy::block_in_if_condition_expr)] + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::blocks_in_if_conditions` | = note: `-D renamed-and-removed-lints` implied by `-D warnings` -error: lint `clippy::new_without_default_derive` has been renamed to `clippy::new_without_default` +error: lint `clippy::block_in_if_condition_stmt` has been renamed to `clippy::blocks_in_if_conditions` --> $DIR/rename.rs:36:9 | -LL | #![warn(clippy::new_without_default_derive)] - | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::new_without_default` +LL | #![warn(clippy::block_in_if_condition_stmt)] + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::blocks_in_if_conditions` -error: lint `clippy::cyclomatic_complexity` has been renamed to `clippy::cognitive_complexity` +error: lint `clippy::box_vec` has been renamed to `clippy::box_collection` --> $DIR/rename.rs:37:9 | -LL | #![warn(clippy::cyclomatic_complexity)] - | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::cognitive_complexity` +LL | #![warn(clippy::box_vec)] + | ^^^^^^^^^^^^^^^ help: use the new name: `clippy::box_collection` error: lint `clippy::const_static_lifetime` has been renamed to `clippy::redundant_static_lifetimes` --> $DIR/rename.rs:38:9 @@ -24,59 +24,59 @@ error: lint `clippy::const_static_lifetime` has been renamed to `clippy::redunda LL | #![warn(clippy::const_static_lifetime)] | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::redundant_static_lifetimes` -error: lint `clippy::option_and_then_some` has been renamed to `clippy::bind_instead_of_map` +error: lint `clippy::cyclomatic_complexity` has been renamed to `clippy::cognitive_complexity` --> $DIR/rename.rs:39:9 | -LL | #![warn(clippy::option_and_then_some)] - | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::bind_instead_of_map` +LL | #![warn(clippy::cyclomatic_complexity)] + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::cognitive_complexity` -error: lint `clippy::box_vec` has been renamed to `clippy::box_collection` +error: lint `clippy::disallowed_method` has been renamed to `clippy::disallowed_methods` --> $DIR/rename.rs:40:9 | -LL | #![warn(clippy::box_vec)] - | ^^^^^^^^^^^^^^^ help: use the new name: `clippy::box_collection` +LL | #![warn(clippy::disallowed_method)] + | ^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::disallowed_methods` -error: lint `clippy::block_in_if_condition_expr` has been renamed to `clippy::blocks_in_if_conditions` +error: lint `clippy::disallowed_type` has been renamed to `clippy::disallowed_types` --> $DIR/rename.rs:41:9 | -LL | #![warn(clippy::block_in_if_condition_expr)] - | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::blocks_in_if_conditions` +LL | #![warn(clippy::disallowed_type)] + | ^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::disallowed_types` -error: lint `clippy::block_in_if_condition_stmt` has been renamed to `clippy::blocks_in_if_conditions` +error: lint `clippy::for_loop_over_option` has been renamed to `clippy::for_loops_over_fallibles` --> $DIR/rename.rs:42:9 | -LL | #![warn(clippy::block_in_if_condition_stmt)] - | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::blocks_in_if_conditions` +LL | #![warn(clippy::for_loop_over_option)] + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::for_loops_over_fallibles` -error: lint `clippy::option_map_unwrap_or` has been renamed to `clippy::map_unwrap_or` +error: lint `clippy::for_loop_over_result` has been renamed to `clippy::for_loops_over_fallibles` --> $DIR/rename.rs:43:9 | -LL | #![warn(clippy::option_map_unwrap_or)] - | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::map_unwrap_or` +LL | #![warn(clippy::for_loop_over_result)] + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::for_loops_over_fallibles` -error: lint `clippy::option_map_unwrap_or_else` has been renamed to `clippy::map_unwrap_or` +error: lint `clippy::identity_conversion` has been renamed to `clippy::useless_conversion` --> $DIR/rename.rs:44:9 | -LL | #![warn(clippy::option_map_unwrap_or_else)] - | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::map_unwrap_or` +LL | #![warn(clippy::identity_conversion)] + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::useless_conversion` -error: lint `clippy::result_map_unwrap_or_else` has been renamed to `clippy::map_unwrap_or` +error: lint `clippy::if_let_some_result` has been renamed to `clippy::match_result_ok` --> $DIR/rename.rs:45:9 | -LL | #![warn(clippy::result_map_unwrap_or_else)] - | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::map_unwrap_or` +LL | #![warn(clippy::if_let_some_result)] + | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::match_result_ok` -error: lint `clippy::option_unwrap_used` has been renamed to `clippy::unwrap_used` +error: lint `clippy::new_without_default_derive` has been renamed to `clippy::new_without_default` --> $DIR/rename.rs:46:9 | -LL | #![warn(clippy::option_unwrap_used)] - | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::unwrap_used` +LL | #![warn(clippy::new_without_default_derive)] + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::new_without_default` -error: lint `clippy::result_unwrap_used` has been renamed to `clippy::unwrap_used` +error: lint `clippy::option_and_then_some` has been renamed to `clippy::bind_instead_of_map` --> $DIR/rename.rs:47:9 | -LL | #![warn(clippy::result_unwrap_used)] - | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::unwrap_used` +LL | #![warn(clippy::option_and_then_some)] + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::bind_instead_of_map` error: lint `clippy::option_expect_used` has been renamed to `clippy::expect_used` --> $DIR/rename.rs:48:9 @@ -84,77 +84,77 @@ error: lint `clippy::option_expect_used` has been renamed to `clippy::expect_use LL | #![warn(clippy::option_expect_used)] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::expect_used` -error: lint `clippy::result_expect_used` has been renamed to `clippy::expect_used` +error: lint `clippy::option_map_unwrap_or` has been renamed to `clippy::map_unwrap_or` --> $DIR/rename.rs:49:9 | -LL | #![warn(clippy::result_expect_used)] - | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::expect_used` +LL | #![warn(clippy::option_map_unwrap_or)] + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::map_unwrap_or` -error: lint `clippy::for_loop_over_option` has been renamed to `clippy::for_loops_over_fallibles` +error: lint `clippy::option_map_unwrap_or_else` has been renamed to `clippy::map_unwrap_or` --> $DIR/rename.rs:50:9 | -LL | #![warn(clippy::for_loop_over_option)] - | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::for_loops_over_fallibles` +LL | #![warn(clippy::option_map_unwrap_or_else)] + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::map_unwrap_or` -error: lint `clippy::for_loop_over_result` has been renamed to `clippy::for_loops_over_fallibles` +error: lint `clippy::option_unwrap_used` has been renamed to `clippy::unwrap_used` --> $DIR/rename.rs:51:9 | -LL | #![warn(clippy::for_loop_over_result)] - | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::for_loops_over_fallibles` +LL | #![warn(clippy::option_unwrap_used)] + | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::unwrap_used` -error: lint `clippy::identity_conversion` has been renamed to `clippy::useless_conversion` +error: lint `clippy::ref_in_deref` has been renamed to `clippy::needless_borrow` --> $DIR/rename.rs:52:9 | -LL | #![warn(clippy::identity_conversion)] - | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::useless_conversion` +LL | #![warn(clippy::ref_in_deref)] + | ^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::needless_borrow` -error: lint `clippy::zero_width_space` has been renamed to `clippy::invisible_characters` +error: lint `clippy::result_expect_used` has been renamed to `clippy::expect_used` --> $DIR/rename.rs:53:9 | -LL | #![warn(clippy::zero_width_space)] - | ^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::invisible_characters` +LL | #![warn(clippy::result_expect_used)] + | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::expect_used` -error: lint `clippy::single_char_push_str` has been renamed to `clippy::single_char_add_str` +error: lint `clippy::result_map_unwrap_or_else` has been renamed to `clippy::map_unwrap_or` --> $DIR/rename.rs:54:9 | -LL | #![warn(clippy::single_char_push_str)] - | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::single_char_add_str` +LL | #![warn(clippy::result_map_unwrap_or_else)] + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::map_unwrap_or` -error: lint `clippy::if_let_some_result` has been renamed to `clippy::match_result_ok` +error: lint `clippy::result_unwrap_used` has been renamed to `clippy::unwrap_used` --> $DIR/rename.rs:55:9 | -LL | #![warn(clippy::if_let_some_result)] - | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::match_result_ok` +LL | #![warn(clippy::result_unwrap_used)] + | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::unwrap_used` -error: lint `clippy::disallowed_type` has been renamed to `clippy::disallowed_types` +error: lint `clippy::single_char_push_str` has been renamed to `clippy::single_char_add_str` --> $DIR/rename.rs:56:9 | -LL | #![warn(clippy::disallowed_type)] - | ^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::disallowed_types` +LL | #![warn(clippy::single_char_push_str)] + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::single_char_add_str` -error: lint `clippy::disallowed_method` has been renamed to `clippy::disallowed_methods` +error: lint `clippy::stutter` has been renamed to `clippy::module_name_repetitions` --> $DIR/rename.rs:57:9 | -LL | #![warn(clippy::disallowed_method)] - | ^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::disallowed_methods` +LL | #![warn(clippy::stutter)] + | ^^^^^^^^^^^^^^^ help: use the new name: `clippy::module_name_repetitions` -error: lint `clippy::ref_in_deref` has been renamed to `clippy::needless_borrow` +error: lint `clippy::to_string_in_display` has been renamed to `clippy::recursive_format_impl` --> $DIR/rename.rs:58:9 | -LL | #![warn(clippy::ref_in_deref)] - | ^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::needless_borrow` +LL | #![warn(clippy::to_string_in_display)] + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::recursive_format_impl` -error: lint `clippy::to_string_in_display` has been renamed to `clippy::recursive_format_impl` +error: lint `clippy::zero_width_space` has been renamed to `clippy::invisible_characters` --> $DIR/rename.rs:59:9 | -LL | #![warn(clippy::to_string_in_display)] - | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::recursive_format_impl` +LL | #![warn(clippy::zero_width_space)] + | ^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `clippy::invisible_characters` -error: lint `clippy::invalid_ref` has been renamed to `invalid_value` +error: lint `clippy::drop_bounds` has been renamed to `drop_bounds` --> $DIR/rename.rs:60:9 | -LL | #![warn(clippy::invalid_ref)] - | ^^^^^^^^^^^^^^^^^^^ help: use the new name: `invalid_value` +LL | #![warn(clippy::drop_bounds)] + | ^^^^^^^^^^^^^^^^^^^ help: use the new name: `drop_bounds` error: lint `clippy::into_iter_on_array` has been renamed to `array_into_iter` --> $DIR/rename.rs:61:9 @@ -162,23 +162,23 @@ error: lint `clippy::into_iter_on_array` has been renamed to `array_into_iter` LL | #![warn(clippy::into_iter_on_array)] | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `array_into_iter` -error: lint `clippy::unused_label` has been renamed to `unused_labels` +error: lint `clippy::invalid_atomic_ordering` has been renamed to `invalid_atomic_ordering` --> $DIR/rename.rs:62:9 | -LL | #![warn(clippy::unused_label)] - | ^^^^^^^^^^^^^^^^^^^^ help: use the new name: `unused_labels` +LL | #![warn(clippy::invalid_atomic_ordering)] + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `invalid_atomic_ordering` -error: lint `clippy::drop_bounds` has been renamed to `drop_bounds` +error: lint `clippy::invalid_ref` has been renamed to `invalid_value` --> $DIR/rename.rs:63:9 | -LL | #![warn(clippy::drop_bounds)] - | ^^^^^^^^^^^^^^^^^^^ help: use the new name: `drop_bounds` +LL | #![warn(clippy::invalid_ref)] + | ^^^^^^^^^^^^^^^^^^^ help: use the new name: `invalid_value` -error: lint `clippy::temporary_cstring_as_ptr` has been renamed to `temporary_cstring_as_ptr` +error: lint `clippy::mem_discriminant_non_enum` has been renamed to `enum_intrinsics_non_enums` --> $DIR/rename.rs:64:9 | -LL | #![warn(clippy::temporary_cstring_as_ptr)] - | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `temporary_cstring_as_ptr` +LL | #![warn(clippy::mem_discriminant_non_enum)] + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `enum_intrinsics_non_enums` error: lint `clippy::panic_params` has been renamed to `non_fmt_panics` --> $DIR/rename.rs:65:9 @@ -186,23 +186,23 @@ error: lint `clippy::panic_params` has been renamed to `non_fmt_panics` LL | #![warn(clippy::panic_params)] | ^^^^^^^^^^^^^^^^^^^^ help: use the new name: `non_fmt_panics` -error: lint `clippy::unknown_clippy_lints` has been renamed to `unknown_lints` +error: lint `clippy::temporary_cstring_as_ptr` has been renamed to `temporary_cstring_as_ptr` --> $DIR/rename.rs:66:9 | -LL | #![warn(clippy::unknown_clippy_lints)] - | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `unknown_lints` +LL | #![warn(clippy::temporary_cstring_as_ptr)] + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `temporary_cstring_as_ptr` -error: lint `clippy::invalid_atomic_ordering` has been renamed to `invalid_atomic_ordering` +error: lint `clippy::unknown_clippy_lints` has been renamed to `unknown_lints` --> $DIR/rename.rs:67:9 | -LL | #![warn(clippy::invalid_atomic_ordering)] - | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `invalid_atomic_ordering` +LL | #![warn(clippy::unknown_clippy_lints)] + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `unknown_lints` -error: lint `clippy::mem_discriminant_non_enum` has been renamed to `enum_intrinsics_non_enums` +error: lint `clippy::unused_label` has been renamed to `unused_labels` --> $DIR/rename.rs:68:9 | -LL | #![warn(clippy::mem_discriminant_non_enum)] - | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: use the new name: `enum_intrinsics_non_enums` +LL | #![warn(clippy::unused_label)] + | ^^^^^^^^^^^^^^^^^^^^ help: use the new name: `unused_labels` error: aborting due to 34 previous errors -- cgit 1.4.1-3-g733a5 From 905a95171894826c58b1f731780f6df7b9b5eef0 Mon Sep 17 00:00:00 2001 From: Alex Macleod Date: Fri, 6 May 2022 13:21:08 +0100 Subject: Pass through extra args in `cargo dev lint` --- clippy_dev/src/lint.rs | 5 ++++- clippy_dev/src/main.rs | 15 ++++++++++++++- 2 files changed, 18 insertions(+), 2 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lint.rs b/clippy_dev/src/lint.rs index 1bc1a39542d..9e463aa741c 100644 --- a/clippy_dev/src/lint.rs +++ b/clippy_dev/src/lint.rs @@ -13,7 +13,7 @@ fn exit_if_err(status: io::Result) { } } -pub fn run(path: &str) { +pub fn run<'a>(path: &str, args: impl Iterator) { let is_file = match fs::metadata(path) { Ok(metadata) => metadata.is_file(), Err(e) => { @@ -30,6 +30,7 @@ pub fn run(path: &str) { .args(["-Z", "no-codegen"]) .args(["--edition", "2021"]) .arg(path) + .args(args) .status(), ); } else { @@ -42,6 +43,8 @@ pub fn run(path: &str) { .expect("failed to create tempdir"); let status = Command::new(cargo_clippy_path()) + .arg("clippy") + .args(args) .current_dir(path) .env("CARGO_TARGET_DIR", target.as_ref()) .status(); diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index ebf8f38d490..dcfaabbc204 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -76,7 +76,8 @@ fn main() { }, ("lint", Some(matches)) => { let path = matches.value_of("path").unwrap(); - lint::run(path); + let args = matches.values_of("args").into_iter().flatten(); + lint::run(path, args); }, ("rename_lint", Some(matches)) => { let old_name = matches.value_of("old_name").unwrap(); @@ -278,11 +279,23 @@ fn get_clap_config<'a>() -> ArgMatches<'a> { Lint a package directory: cargo dev lint tests/ui-cargo/wildcard_dependencies/fail cargo dev lint ~/my-project + + Run rustfix: + cargo dev lint ~/my-project -- --fix + + Set lint levels: + cargo dev lint file.rs -- -W clippy::pedantic + cargo dev lint ~/my-project -- -- -W clippy::pedantic "}) .arg( Arg::with_name("path") .required(true) .help("The path to a file or package directory to lint"), + ) + .arg( + Arg::with_name("args") + .multiple(true) + .help("Pass extra arguments to cargo/clippy-driver"), ), ) .subcommand( -- cgit 1.4.1-3-g733a5 From fe84ff336055412f0df8a2e625eaf46c6701e574 Mon Sep 17 00:00:00 2001 From: nsunderland1 Date: Fri, 6 May 2022 00:10:11 -0700 Subject: New lint: [`derive_partial_eq_without_eq`] --- CHANGELOG.md | 1 + clippy_dev/src/update_lints.rs | 6 +- clippy_lints/src/checked_conversions.rs | 2 +- clippy_lints/src/derive.rs | 72 ++++++++++++++++++- clippy_lints/src/lib.register_all.rs | 1 + clippy_lints/src/lib.register_lints.rs | 1 + clippy_lints/src/lib.register_style.rs | 1 + clippy_lints/src/loops/utils.rs | 2 +- clippy_lints/src/methods/mod.rs | 2 +- clippy_lints/src/methods/str_splitn.rs | 2 +- clippy_utils/src/numeric_literal.rs | 2 +- tests/ui/absurd-extreme-comparisons.rs | 2 +- tests/ui/assign_ops2.rs | 2 +- tests/ui/cmp_owned/asymmetric_partial_eq.fixed | 2 +- tests/ui/cmp_owned/asymmetric_partial_eq.rs | 2 +- tests/ui/cmp_owned/with_suggestion.fixed | 4 +- tests/ui/cmp_owned/with_suggestion.rs | 4 +- tests/ui/cmp_owned/without_suggestion.rs | 4 +- tests/ui/crashes/ice-6254.rs | 1 + tests/ui/crashes/ice-6254.stderr | 2 +- tests/ui/derive_hash_xor_eq.rs | 2 + tests/ui/derive_hash_xor_eq.stderr | 16 ++--- tests/ui/derive_partial_eq_without_eq.fixed | 98 ++++++++++++++++++++++++++ tests/ui/derive_partial_eq_without_eq.rs | 98 ++++++++++++++++++++++++++ tests/ui/derive_partial_eq_without_eq.stderr | 46 ++++++++++++ tests/ui/equatable_if_let.fixed | 2 +- tests/ui/equatable_if_let.rs | 2 +- tests/ui/unit_cmp.rs | 6 +- tests/ui/unit_cmp.stderr | 12 ++-- 29 files changed, 359 insertions(+), 38 deletions(-) create mode 100644 tests/ui/derive_partial_eq_without_eq.fixed create mode 100644 tests/ui/derive_partial_eq_without_eq.rs create mode 100644 tests/ui/derive_partial_eq_without_eq.stderr (limited to 'clippy_dev/src') diff --git a/CHANGELOG.md b/CHANGELOG.md index 751f9fccd88..0608c360d30 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3350,6 +3350,7 @@ Released 2018-09-13 [`derivable_impls`]: https://rust-lang.github.io/rust-clippy/master/index.html#derivable_impls [`derive_hash_xor_eq`]: https://rust-lang.github.io/rust-clippy/master/index.html#derive_hash_xor_eq [`derive_ord_xor_partial_ord`]: https://rust-lang.github.io/rust-clippy/master/index.html#derive_ord_xor_partial_ord +[`derive_partial_eq_without_eq`]: https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq [`disallowed_methods`]: https://rust-lang.github.io/rust-clippy/master/index.html#disallowed_methods [`disallowed_script_idents`]: https://rust-lang.github.io/rust-clippy/master/index.html#disallowed_script_idents [`disallowed_types`]: https://rust-lang.github.io/rust-clippy/master/index.html#disallowed_types diff --git a/clippy_dev/src/update_lints.rs b/clippy_dev/src/update_lints.rs index 1a6a4336da2..e9cc4f29943 100644 --- a/clippy_dev/src/update_lints.rs +++ b/clippy_dev/src/update_lints.rs @@ -17,7 +17,7 @@ const GENERATED_FILE_COMMENT: &str = "// This file was generated by `cargo dev u const DOCS_LINK: &str = "https://rust-lang.github.io/rust-clippy/master/index.html"; -#[derive(Clone, Copy, PartialEq)] +#[derive(Clone, Copy, PartialEq, Eq)] pub enum UpdateMode { Check, Change, @@ -372,7 +372,7 @@ fn exit_with_failure() { } /// Lint data parsed from the Clippy source code. -#[derive(Clone, PartialEq, Debug)] +#[derive(Clone, PartialEq, Eq, Debug)] struct Lint { name: String, group: String, @@ -414,7 +414,7 @@ impl Lint { } } -#[derive(Clone, PartialEq, Debug)] +#[derive(Clone, PartialEq, Eq, Debug)] struct DeprecatedLint { name: String, reason: String, diff --git a/clippy_lints/src/checked_conversions.rs b/clippy_lints/src/checked_conversions.rs index e23428e216d..28c77ea40ef 100644 --- a/clippy_lints/src/checked_conversions.rs +++ b/clippy_lints/src/checked_conversions.rs @@ -123,7 +123,7 @@ struct Conversion<'a> { } /// The kind of conversion that is checked -#[derive(Copy, Clone, Debug, PartialEq)] +#[derive(Copy, Clone, Debug, PartialEq, Eq)] enum ConversionType { SignedToUnsigned, SignedToSigned, diff --git a/clippy_lints/src/derive.rs b/clippy_lints/src/derive.rs index 557e101494e..a4757ebd8c7 100644 --- a/clippy_lints/src/derive.rs +++ b/clippy_lints/src/derive.rs @@ -1,8 +1,9 @@ -use clippy_utils::diagnostics::{span_lint_and_help, span_lint_and_note, span_lint_and_then}; +use clippy_utils::diagnostics::{span_lint_and_help, span_lint_and_note, span_lint_and_sugg, span_lint_and_then}; use clippy_utils::paths; use clippy_utils::ty::{implements_trait, is_copy}; use clippy_utils::{is_automatically_derived, is_lint_allowed, match_def_path}; use if_chain::if_chain; +use rustc_errors::Applicability; use rustc_hir::intravisit::{walk_expr, walk_fn, walk_item, FnKind, Visitor}; use rustc_hir::{ BlockCheckMode, BodyId, Expr, ExprKind, FnDecl, HirId, Impl, Item, ItemKind, TraitRef, UnsafeSource, Unsafety, @@ -156,11 +157,44 @@ declare_clippy_lint! { "deriving `serde::Deserialize` on a type that has methods using `unsafe`" } +declare_clippy_lint! { + /// ### What it does + /// Checks for types that derive `PartialEq` and could implement `Eq`. + /// + /// ### Why is this bad? + /// If a type `T` derives `PartialEq` and all of its members implement `Eq`, + /// then `T` can always implement `Eq`. Implementing `Eq` allows `T` to be used + /// in APIs that require `Eq` types. It also allows structs containing `T` to derive + /// `Eq` themselves. + /// + /// ### Example + /// ```rust + /// #[derive(PartialEq)] + /// struct Foo { + /// i_am_eq: i32, + /// i_am_eq_too: Vec, + /// } + /// ``` + /// Use instead: + /// ```rust + /// #[derive(PartialEq, Eq)] + /// struct Foo { + /// i_am_eq: i32, + /// i_am_eq_too: Vec, + /// } + /// ``` + #[clippy::version = "1.62.0"] + pub DERIVE_PARTIAL_EQ_WITHOUT_EQ, + style, + "deriving `PartialEq` on a type that can implement `Eq`, without implementing `Eq`" +} + declare_lint_pass!(Derive => [ EXPL_IMPL_CLONE_ON_COPY, DERIVE_HASH_XOR_EQ, DERIVE_ORD_XOR_PARTIAL_ORD, - UNSAFE_DERIVE_DESERIALIZE + UNSAFE_DERIVE_DESERIALIZE, + DERIVE_PARTIAL_EQ_WITHOUT_EQ ]); impl<'tcx> LateLintPass<'tcx> for Derive { @@ -179,6 +213,7 @@ impl<'tcx> LateLintPass<'tcx> for Derive { if is_automatically_derived { check_unsafe_derive_deserialize(cx, item, trait_ref, ty); + check_partial_eq_without_eq(cx, item.span, trait_ref, ty); } else { check_copy_clone(cx, item, trait_ref, ty); } @@ -419,3 +454,36 @@ impl<'tcx> Visitor<'tcx> for UnsafeVisitor<'_, 'tcx> { self.cx.tcx.hir() } } + +/// Implementation of the `DERIVE_PARTIAL_EQ_WITHOUT_EQ` lint. +fn check_partial_eq_without_eq<'tcx>(cx: &LateContext<'tcx>, span: Span, trait_ref: &TraitRef<'_>, ty: Ty<'tcx>) { + if_chain! { + if let ty::Adt(adt, substs) = ty.kind(); + if let Some(eq_trait_def_id) = cx.tcx.get_diagnostic_item(sym::Eq); + if let Some(def_id) = trait_ref.trait_def_id(); + if cx.tcx.is_diagnostic_item(sym::PartialEq, def_id); + if !implements_trait(cx, ty, eq_trait_def_id, substs); + then { + // If all of our fields implement `Eq`, we can implement `Eq` too + for variant in adt.variants() { + for field in &variant.fields { + let ty = field.ty(cx.tcx, substs); + + if !implements_trait(cx, ty, eq_trait_def_id, substs) { + return; + } + } + } + + span_lint_and_sugg( + cx, + DERIVE_PARTIAL_EQ_WITHOUT_EQ, + span.ctxt().outer_expn_data().call_site, + "you are deriving `PartialEq` and can implement `Eq`", + "consider deriving `Eq` as well", + "PartialEq, Eq".to_string(), + Applicability::MachineApplicable, + ) + } + } +} diff --git a/clippy_lints/src/lib.register_all.rs b/clippy_lints/src/lib.register_all.rs index e68718f9fdf..0f43b320f76 100644 --- a/clippy_lints/src/lib.register_all.rs +++ b/clippy_lints/src/lib.register_all.rs @@ -46,6 +46,7 @@ store.register_group(true, "clippy::all", Some("clippy_all"), vec![ LintId::of(derivable_impls::DERIVABLE_IMPLS), LintId::of(derive::DERIVE_HASH_XOR_EQ), LintId::of(derive::DERIVE_ORD_XOR_PARTIAL_ORD), + LintId::of(derive::DERIVE_PARTIAL_EQ_WITHOUT_EQ), LintId::of(disallowed_methods::DISALLOWED_METHODS), LintId::of(disallowed_types::DISALLOWED_TYPES), LintId::of(doc::MISSING_SAFETY_DOC), diff --git a/clippy_lints/src/lib.register_lints.rs b/clippy_lints/src/lib.register_lints.rs index 5768edc5018..4e302b10a0f 100644 --- a/clippy_lints/src/lib.register_lints.rs +++ b/clippy_lints/src/lib.register_lints.rs @@ -113,6 +113,7 @@ store.register_lints(&[ derivable_impls::DERIVABLE_IMPLS, derive::DERIVE_HASH_XOR_EQ, derive::DERIVE_ORD_XOR_PARTIAL_ORD, + derive::DERIVE_PARTIAL_EQ_WITHOUT_EQ, derive::EXPL_IMPL_CLONE_ON_COPY, derive::UNSAFE_DERIVE_DESERIALIZE, disallowed_methods::DISALLOWED_METHODS, diff --git a/clippy_lints/src/lib.register_style.rs b/clippy_lints/src/lib.register_style.rs index d183c0449cd..62f26d821a0 100644 --- a/clippy_lints/src/lib.register_style.rs +++ b/clippy_lints/src/lib.register_style.rs @@ -16,6 +16,7 @@ store.register_group(true, "clippy::style", Some("clippy_style"), vec![ LintId::of(comparison_chain::COMPARISON_CHAIN), LintId::of(default::FIELD_REASSIGN_WITH_DEFAULT), LintId::of(dereference::NEEDLESS_BORROW), + LintId::of(derive::DERIVE_PARTIAL_EQ_WITHOUT_EQ), LintId::of(disallowed_methods::DISALLOWED_METHODS), LintId::of(disallowed_types::DISALLOWED_TYPES), LintId::of(doc::MISSING_SAFETY_DOC), diff --git a/clippy_lints/src/loops/utils.rs b/clippy_lints/src/loops/utils.rs index 772d251b620..4801a84eb92 100644 --- a/clippy_lints/src/loops/utils.rs +++ b/clippy_lints/src/loops/utils.rs @@ -13,7 +13,7 @@ use rustc_span::symbol::{sym, Symbol}; use rustc_typeck::hir_ty_to_ty; use std::iter::Iterator; -#[derive(Debug, PartialEq)] +#[derive(Debug, PartialEq, Eq)] enum IncrementVisitorVarState { Initial, // Not examined yet IncrOnce, // Incremented exactly once, may be a loop counter diff --git a/clippy_lints/src/methods/mod.rs b/clippy_lints/src/methods/mod.rs index e452614ce17..cfeee4d0c70 100644 --- a/clippy_lints/src/methods/mod.rs +++ b/clippy_lints/src/methods/mod.rs @@ -2835,7 +2835,7 @@ const TRAIT_METHODS: [ShouldImplTraitCase; 30] = [ ShouldImplTraitCase::new("std::ops::Sub", "sub", 2, FN_HEADER, SelfKind::Value, OutType::Any, true), ]; -#[derive(Clone, Copy, PartialEq, Debug)] +#[derive(Clone, Copy, PartialEq, Eq, Debug)] enum SelfKind { Value, Ref, diff --git a/clippy_lints/src/methods/str_splitn.rs b/clippy_lints/src/methods/str_splitn.rs index fc375763542..90651a6ba04 100644 --- a/clippy_lints/src/methods/str_splitn.rs +++ b/clippy_lints/src/methods/str_splitn.rs @@ -271,7 +271,7 @@ enum IterUsageKind { NextTuple, } -#[derive(Debug, PartialEq)] +#[derive(Debug, PartialEq, Eq)] enum UnwrapKind { Unwrap, QuestionMark, diff --git a/clippy_utils/src/numeric_literal.rs b/clippy_utils/src/numeric_literal.rs index b92d42e8323..3fb5415ce02 100644 --- a/clippy_utils/src/numeric_literal.rs +++ b/clippy_utils/src/numeric_literal.rs @@ -1,7 +1,7 @@ use rustc_ast::ast::{Lit, LitFloatType, LitIntType, LitKind}; use std::iter; -#[derive(Debug, PartialEq, Copy, Clone)] +#[derive(Debug, PartialEq, Eq, Copy, Clone)] pub enum Radix { Binary, Octal, diff --git a/tests/ui/absurd-extreme-comparisons.rs b/tests/ui/absurd-extreme-comparisons.rs index d205b383d1f..f682b280c1b 100644 --- a/tests/ui/absurd-extreme-comparisons.rs +++ b/tests/ui/absurd-extreme-comparisons.rs @@ -37,7 +37,7 @@ fn main() { use std::cmp::{Ordering, PartialEq, PartialOrd}; -#[derive(PartialEq, PartialOrd)] +#[derive(PartialEq, Eq, PartialOrd)] pub struct U(u64); impl PartialEq for U { diff --git a/tests/ui/assign_ops2.rs b/tests/ui/assign_ops2.rs index 4703a8c7777..f6d3a8fa3f0 100644 --- a/tests/ui/assign_ops2.rs +++ b/tests/ui/assign_ops2.rs @@ -24,7 +24,7 @@ fn main() { use std::ops::{Mul, MulAssign}; -#[derive(Copy, Clone, Debug, PartialEq)] +#[derive(Copy, Clone, Debug, PartialEq, Eq)] pub struct Wrap(i64); impl Mul for Wrap { diff --git a/tests/ui/cmp_owned/asymmetric_partial_eq.fixed b/tests/ui/cmp_owned/asymmetric_partial_eq.fixed index 3305ac9bf8b..abd059c2308 100644 --- a/tests/ui/cmp_owned/asymmetric_partial_eq.fixed +++ b/tests/ui/cmp_owned/asymmetric_partial_eq.fixed @@ -1,5 +1,5 @@ // run-rustfix -#![allow(unused, clippy::redundant_clone)] // See #5700 +#![allow(unused, clippy::redundant_clone, clippy::derive_partial_eq_without_eq)] // See #5700 // Define the types in each module to avoid trait impls leaking between modules. macro_rules! impl_types { diff --git a/tests/ui/cmp_owned/asymmetric_partial_eq.rs b/tests/ui/cmp_owned/asymmetric_partial_eq.rs index 88bc2f51dd6..020ef5f840b 100644 --- a/tests/ui/cmp_owned/asymmetric_partial_eq.rs +++ b/tests/ui/cmp_owned/asymmetric_partial_eq.rs @@ -1,5 +1,5 @@ // run-rustfix -#![allow(unused, clippy::redundant_clone)] // See #5700 +#![allow(unused, clippy::redundant_clone, clippy::derive_partial_eq_without_eq)] // See #5700 // Define the types in each module to avoid trait impls leaking between modules. macro_rules! impl_types { diff --git a/tests/ui/cmp_owned/with_suggestion.fixed b/tests/ui/cmp_owned/with_suggestion.fixed index 05fb96339e3..b28c4378e33 100644 --- a/tests/ui/cmp_owned/with_suggestion.fixed +++ b/tests/ui/cmp_owned/with_suggestion.fixed @@ -45,7 +45,7 @@ impl ToOwned for Foo { } } -#[derive(PartialEq)] +#[derive(PartialEq, Eq)] struct Bar; impl PartialEq for Bar { @@ -61,7 +61,7 @@ impl std::borrow::Borrow for Bar { } } -#[derive(PartialEq)] +#[derive(PartialEq, Eq)] struct Baz; impl ToOwned for Baz { diff --git a/tests/ui/cmp_owned/with_suggestion.rs b/tests/ui/cmp_owned/with_suggestion.rs index 0a02825ed82..c1089010fe1 100644 --- a/tests/ui/cmp_owned/with_suggestion.rs +++ b/tests/ui/cmp_owned/with_suggestion.rs @@ -45,7 +45,7 @@ impl ToOwned for Foo { } } -#[derive(PartialEq)] +#[derive(PartialEq, Eq)] struct Bar; impl PartialEq for Bar { @@ -61,7 +61,7 @@ impl std::borrow::Borrow for Bar { } } -#[derive(PartialEq)] +#[derive(PartialEq, Eq)] struct Baz; impl ToOwned for Baz { diff --git a/tests/ui/cmp_owned/without_suggestion.rs b/tests/ui/cmp_owned/without_suggestion.rs index f44a3901fb4..738d082339a 100644 --- a/tests/ui/cmp_owned/without_suggestion.rs +++ b/tests/ui/cmp_owned/without_suggestion.rs @@ -26,7 +26,7 @@ impl ToOwned for Foo { } } -#[derive(PartialEq)] +#[derive(PartialEq, Eq)] struct Baz; impl ToOwned for Baz { @@ -36,7 +36,7 @@ impl ToOwned for Baz { } } -#[derive(PartialEq)] +#[derive(PartialEq, Eq)] struct Bar; impl PartialEq for Bar { diff --git a/tests/ui/crashes/ice-6254.rs b/tests/ui/crashes/ice-6254.rs index c19eca43884..a2a60a16915 100644 --- a/tests/ui/crashes/ice-6254.rs +++ b/tests/ui/crashes/ice-6254.rs @@ -2,6 +2,7 @@ // panicked at 'assertion failed: rows.iter().all(|r| r.len() == v.len())', // compiler/rustc_mir_build/src/thir/pattern/_match.rs:2030:5 +#[allow(clippy::derive_partial_eq_without_eq)] #[derive(PartialEq)] struct Foo(i32); const FOO_REF_REF: &&Foo = &&Foo(42); diff --git a/tests/ui/crashes/ice-6254.stderr b/tests/ui/crashes/ice-6254.stderr index 95ebf23d818..f37ab2e9b0c 100644 --- a/tests/ui/crashes/ice-6254.stderr +++ b/tests/ui/crashes/ice-6254.stderr @@ -1,5 +1,5 @@ error: to use a constant of type `Foo` in a pattern, `Foo` must be annotated with `#[derive(PartialEq, Eq)]` - --> $DIR/ice-6254.rs:12:9 + --> $DIR/ice-6254.rs:13:9 | LL | FOO_REF_REF => {}, | ^^^^^^^^^^^ diff --git a/tests/ui/derive_hash_xor_eq.rs b/tests/ui/derive_hash_xor_eq.rs index 10abe22d53e..813ddc56646 100644 --- a/tests/ui/derive_hash_xor_eq.rs +++ b/tests/ui/derive_hash_xor_eq.rs @@ -1,3 +1,5 @@ +#![allow(clippy::derive_partial_eq_without_eq)] + #[derive(PartialEq, Hash)] struct Foo; diff --git a/tests/ui/derive_hash_xor_eq.stderr b/tests/ui/derive_hash_xor_eq.stderr index b383072ca4d..e5184bd1407 100644 --- a/tests/ui/derive_hash_xor_eq.stderr +++ b/tests/ui/derive_hash_xor_eq.stderr @@ -1,12 +1,12 @@ error: you are deriving `Hash` but have implemented `PartialEq` explicitly - --> $DIR/derive_hash_xor_eq.rs:10:10 + --> $DIR/derive_hash_xor_eq.rs:12:10 | LL | #[derive(Hash)] | ^^^^ | = note: `#[deny(clippy::derive_hash_xor_eq)]` on by default note: `PartialEq` implemented here - --> $DIR/derive_hash_xor_eq.rs:13:1 + --> $DIR/derive_hash_xor_eq.rs:15:1 | LL | / impl PartialEq for Bar { LL | | fn eq(&self, _: &Bar) -> bool { @@ -17,13 +17,13 @@ LL | | } = note: this error originates in the derive macro `Hash` (in Nightly builds, run with -Z macro-backtrace for more info) error: you are deriving `Hash` but have implemented `PartialEq` explicitly - --> $DIR/derive_hash_xor_eq.rs:19:10 + --> $DIR/derive_hash_xor_eq.rs:21:10 | LL | #[derive(Hash)] | ^^^^ | note: `PartialEq` implemented here - --> $DIR/derive_hash_xor_eq.rs:22:1 + --> $DIR/derive_hash_xor_eq.rs:24:1 | LL | / impl PartialEq for Baz { LL | | fn eq(&self, _: &Baz) -> bool { @@ -34,7 +34,7 @@ LL | | } = note: this error originates in the derive macro `Hash` (in Nightly builds, run with -Z macro-backtrace for more info) error: you are implementing `Hash` explicitly but have derived `PartialEq` - --> $DIR/derive_hash_xor_eq.rs:31:1 + --> $DIR/derive_hash_xor_eq.rs:33:1 | LL | / impl std::hash::Hash for Bah { LL | | fn hash(&self, _: &mut H) {} @@ -42,14 +42,14 @@ LL | | } | |_^ | note: `PartialEq` implemented here - --> $DIR/derive_hash_xor_eq.rs:28:10 + --> $DIR/derive_hash_xor_eq.rs:30:10 | LL | #[derive(PartialEq)] | ^^^^^^^^^ = note: this error originates in the derive macro `PartialEq` (in Nightly builds, run with -Z macro-backtrace for more info) error: you are implementing `Hash` explicitly but have derived `PartialEq` - --> $DIR/derive_hash_xor_eq.rs:49:5 + --> $DIR/derive_hash_xor_eq.rs:51:5 | LL | / impl Hash for Foo3 { LL | | fn hash(&self, _: &mut H) {} @@ -57,7 +57,7 @@ LL | | } | |_____^ | note: `PartialEq` implemented here - --> $DIR/derive_hash_xor_eq.rs:46:14 + --> $DIR/derive_hash_xor_eq.rs:48:14 | LL | #[derive(PartialEq)] | ^^^^^^^^^ diff --git a/tests/ui/derive_partial_eq_without_eq.fixed b/tests/ui/derive_partial_eq_without_eq.fixed new file mode 100644 index 00000000000..7d4d1b3b649 --- /dev/null +++ b/tests/ui/derive_partial_eq_without_eq.fixed @@ -0,0 +1,98 @@ +// run-rustfix + +#![allow(unused)] +#![warn(clippy::derive_partial_eq_without_eq)] + +// Don't warn on structs that aren't PartialEq +struct NotPartialEq { + foo: u32, + bar: String, +} + +// Eq can be derived but is missing +#[derive(Debug, PartialEq, Eq)] +struct MissingEq { + foo: u32, + bar: String, +} + +// Eq is derived +#[derive(PartialEq, Eq)] +struct NotMissingEq { + foo: u32, + bar: String, +} + +// Eq is manually implemented +#[derive(PartialEq)] +struct ManualEqImpl { + foo: u32, + bar: String, +} + +impl Eq for ManualEqImpl {} + +// Cannot be Eq because f32 isn't Eq +#[derive(PartialEq)] +struct CannotBeEq { + foo: u32, + bar: f32, +} + +// Don't warn if PartialEq is manually implemented +struct ManualPartialEqImpl { + foo: u32, + bar: String, +} + +impl PartialEq for ManualPartialEqImpl { + fn eq(&self, other: &Self) -> bool { + self.foo == other.foo && self.bar == other.bar + } +} + +// Generic fields should be properly checked for Eq-ness +#[derive(PartialEq)] +struct GenericNotEq { + foo: T, + bar: U, +} + +#[derive(PartialEq, Eq)] +struct GenericEq { + foo: T, + bar: U, +} + +#[derive(PartialEq, Eq)] +struct TupleStruct(u32); + +#[derive(PartialEq, Eq)] +struct GenericTupleStruct(T); + +#[derive(PartialEq)] +struct TupleStructNotEq(f32); + +#[derive(PartialEq, Eq)] +enum Enum { + Foo(u32), + Bar { a: String, b: () }, +} + +#[derive(PartialEq, Eq)] +enum GenericEnum { + Foo(T), + Bar { a: U, b: V }, +} + +#[derive(PartialEq)] +enum EnumNotEq { + Foo(u32), + Bar { a: String, b: f32 }, +} + +// Ensure that rustfix works properly when `PartialEq` has other derives on either side +#[derive(Debug, PartialEq, Eq, Clone)] +struct RustFixWithOtherDerives; + +fn main() {} diff --git a/tests/ui/derive_partial_eq_without_eq.rs b/tests/ui/derive_partial_eq_without_eq.rs new file mode 100644 index 00000000000..ab4e1df1ca4 --- /dev/null +++ b/tests/ui/derive_partial_eq_without_eq.rs @@ -0,0 +1,98 @@ +// run-rustfix + +#![allow(unused)] +#![warn(clippy::derive_partial_eq_without_eq)] + +// Don't warn on structs that aren't PartialEq +struct NotPartialEq { + foo: u32, + bar: String, +} + +// Eq can be derived but is missing +#[derive(Debug, PartialEq)] +struct MissingEq { + foo: u32, + bar: String, +} + +// Eq is derived +#[derive(PartialEq, Eq)] +struct NotMissingEq { + foo: u32, + bar: String, +} + +// Eq is manually implemented +#[derive(PartialEq)] +struct ManualEqImpl { + foo: u32, + bar: String, +} + +impl Eq for ManualEqImpl {} + +// Cannot be Eq because f32 isn't Eq +#[derive(PartialEq)] +struct CannotBeEq { + foo: u32, + bar: f32, +} + +// Don't warn if PartialEq is manually implemented +struct ManualPartialEqImpl { + foo: u32, + bar: String, +} + +impl PartialEq for ManualPartialEqImpl { + fn eq(&self, other: &Self) -> bool { + self.foo == other.foo && self.bar == other.bar + } +} + +// Generic fields should be properly checked for Eq-ness +#[derive(PartialEq)] +struct GenericNotEq { + foo: T, + bar: U, +} + +#[derive(PartialEq)] +struct GenericEq { + foo: T, + bar: U, +} + +#[derive(PartialEq)] +struct TupleStruct(u32); + +#[derive(PartialEq)] +struct GenericTupleStruct(T); + +#[derive(PartialEq)] +struct TupleStructNotEq(f32); + +#[derive(PartialEq)] +enum Enum { + Foo(u32), + Bar { a: String, b: () }, +} + +#[derive(PartialEq)] +enum GenericEnum { + Foo(T), + Bar { a: U, b: V }, +} + +#[derive(PartialEq)] +enum EnumNotEq { + Foo(u32), + Bar { a: String, b: f32 }, +} + +// Ensure that rustfix works properly when `PartialEq` has other derives on either side +#[derive(Debug, PartialEq, Clone)] +struct RustFixWithOtherDerives; + +fn main() {} diff --git a/tests/ui/derive_partial_eq_without_eq.stderr b/tests/ui/derive_partial_eq_without_eq.stderr new file mode 100644 index 00000000000..bf55165890a --- /dev/null +++ b/tests/ui/derive_partial_eq_without_eq.stderr @@ -0,0 +1,46 @@ +error: you are deriving `PartialEq` and can implement `Eq` + --> $DIR/derive_partial_eq_without_eq.rs:13:17 + | +LL | #[derive(Debug, PartialEq)] + | ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq` + | + = note: `-D clippy::derive-partial-eq-without-eq` implied by `-D warnings` + +error: you are deriving `PartialEq` and can implement `Eq` + --> $DIR/derive_partial_eq_without_eq.rs:61:10 + | +LL | #[derive(PartialEq)] + | ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq` + +error: you are deriving `PartialEq` and can implement `Eq` + --> $DIR/derive_partial_eq_without_eq.rs:67:10 + | +LL | #[derive(PartialEq)] + | ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq` + +error: you are deriving `PartialEq` and can implement `Eq` + --> $DIR/derive_partial_eq_without_eq.rs:70:10 + | +LL | #[derive(PartialEq)] + | ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq` + +error: you are deriving `PartialEq` and can implement `Eq` + --> $DIR/derive_partial_eq_without_eq.rs:76:10 + | +LL | #[derive(PartialEq)] + | ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq` + +error: you are deriving `PartialEq` and can implement `Eq` + --> $DIR/derive_partial_eq_without_eq.rs:82:10 + | +LL | #[derive(PartialEq)] + | ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq` + +error: you are deriving `PartialEq` and can implement `Eq` + --> $DIR/derive_partial_eq_without_eq.rs:95:17 + | +LL | #[derive(Debug, PartialEq, Clone)] + | ^^^^^^^^^ help: consider deriving `Eq` as well: `PartialEq, Eq` + +error: aborting due to 7 previous errors + diff --git a/tests/ui/equatable_if_let.fixed b/tests/ui/equatable_if_let.fixed index 88918d9671e..47bf25e409b 100644 --- a/tests/ui/equatable_if_let.fixed +++ b/tests/ui/equatable_if_let.fixed @@ -1,6 +1,6 @@ // run-rustfix -#![allow(unused_variables, dead_code)] +#![allow(unused_variables, dead_code, clippy::derive_partial_eq_without_eq)] #![warn(clippy::equatable_if_let)] use std::cmp::Ordering; diff --git a/tests/ui/equatable_if_let.rs b/tests/ui/equatable_if_let.rs index 9a7ab75ef45..d498bca2455 100644 --- a/tests/ui/equatable_if_let.rs +++ b/tests/ui/equatable_if_let.rs @@ -1,6 +1,6 @@ // run-rustfix -#![allow(unused_variables, dead_code)] +#![allow(unused_variables, dead_code, clippy::derive_partial_eq_without_eq)] #![warn(clippy::equatable_if_let)] use std::cmp::Ordering; diff --git a/tests/ui/unit_cmp.rs b/tests/ui/unit_cmp.rs index 8d3a4eed82e..3d271104361 100644 --- a/tests/ui/unit_cmp.rs +++ b/tests/ui/unit_cmp.rs @@ -1,5 +1,9 @@ #![warn(clippy::unit_cmp)] -#![allow(clippy::no_effect, clippy::unnecessary_operation)] +#![allow( + clippy::no_effect, + clippy::unnecessary_operation, + clippy::derive_partial_eq_without_eq +)] #[derive(PartialEq)] pub struct ContainsUnit(()); // should be fine diff --git a/tests/ui/unit_cmp.stderr b/tests/ui/unit_cmp.stderr index 824506a4257..41cf19ae685 100644 --- a/tests/ui/unit_cmp.stderr +++ b/tests/ui/unit_cmp.stderr @@ -1,5 +1,5 @@ error: ==-comparison of unit values detected. This will always be true - --> $DIR/unit_cmp.rs:12:8 + --> $DIR/unit_cmp.rs:16:8 | LL | if { | ________^ @@ -12,7 +12,7 @@ LL | | } {} = note: `-D clippy::unit-cmp` implied by `-D warnings` error: >-comparison of unit values detected. This will always be false - --> $DIR/unit_cmp.rs:18:8 + --> $DIR/unit_cmp.rs:22:8 | LL | if { | ________^ @@ -23,7 +23,7 @@ LL | | } {} | |_____^ error: `assert_eq` of unit values detected. This will always succeed - --> $DIR/unit_cmp.rs:24:5 + --> $DIR/unit_cmp.rs:28:5 | LL | / assert_eq!( LL | | { @@ -35,7 +35,7 @@ LL | | ); | |_____^ error: `debug_assert_eq` of unit values detected. This will always succeed - --> $DIR/unit_cmp.rs:32:5 + --> $DIR/unit_cmp.rs:36:5 | LL | / debug_assert_eq!( LL | | { @@ -47,7 +47,7 @@ LL | | ); | |_____^ error: `assert_ne` of unit values detected. This will always fail - --> $DIR/unit_cmp.rs:41:5 + --> $DIR/unit_cmp.rs:45:5 | LL | / assert_ne!( LL | | { @@ -59,7 +59,7 @@ LL | | ); | |_____^ error: `debug_assert_ne` of unit values detected. This will always fail - --> $DIR/unit_cmp.rs:49:5 + --> $DIR/unit_cmp.rs:53:5 | LL | / debug_assert_ne!( LL | | { -- cgit 1.4.1-3-g733a5 From 4e5f69cc869f734d39f74a5b0d9250eb5fc101ce Mon Sep 17 00:00:00 2001 From: ydah <13041216+ydah@users.noreply.github.com> Date: Fri, 13 May 2022 14:20:25 +0900 Subject: Tweak some words improved representation This PR has implemented improved representation. - Use "lib" instead of "lifb" - Use "triggered" instead of "triggere" - Use "blacklisted_name" instead of "blackisted_name" - Use "stabilization" instead of "stabilisation" - Use "behavior" instead of "behaviour" - Use "target" instead of "tartet" - Use "checked_add" instead of "chcked_add" - Use "anti-pattern" instead of "antipattern" - Use "suggestion" instead of "suggesttion" - Use "example" instead of "exampel" - Use "Cheat Sheet" instead of "Cheatsheet" --- clippy_dev/src/main.rs | 2 +- clippy_dev/src/new_lint.rs | 4 ++-- clippy_lints/src/assign_ops.rs | 2 +- clippy_lints/src/casts/cast_slice_different_sizes.rs | 2 +- clippy_lints/src/casts/mod.rs | 2 +- clippy_lints/src/default_union_representation.rs | 4 ++-- clippy_lints/src/derive.rs | 4 ++-- clippy_lints/src/main_recursion.rs | 2 +- clippy_lints/src/methods/mod.rs | 2 +- clippy_lints/src/mutable_debug_assertion.rs | 2 +- clippy_lints/src/needless_bitwise_bool.rs | 4 ++-- clippy_lints/src/pass_by_ref_or_value.rs | 2 +- clippy_lints/src/redundant_clone.rs | 2 +- clippy_lints/src/transmute/mod.rs | 4 ++-- doc/adding_lints.md | 4 ++-- tests/ui/blacklisted_name.rs | 4 ++-- 16 files changed, 23 insertions(+), 23 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index dcfaabbc204..d5cd7ca96c0 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -124,7 +124,7 @@ fn get_clap_config<'a>() -> ArgMatches<'a> { * the lint count in README.md is correct\n \ * the changelog contains markdown link references at the bottom\n \ * all lint groups include the correct lints\n \ - * lint modules in `clippy_lints/*` are visible in `src/lifb.rs` via `pub mod`\n \ + * lint modules in `clippy_lints/*` are visible in `src/lib.rs` via `pub mod`\n \ * all lints are registered in the lint store", ) .arg(Arg::with_name("print-only").long("print-only").help( diff --git a/clippy_dev/src/new_lint.rs b/clippy_dev/src/new_lint.rs index 10f67d301f8..07d19638788 100644 --- a/clippy_dev/src/new_lint.rs +++ b/clippy_dev/src/new_lint.rs @@ -133,7 +133,7 @@ fn to_camel_case(name: &str) -> String { .collect() } -fn get_stabilisation_version() -> String { +fn get_stabilization_version() -> String { fn parse_manifest(contents: &str) -> Option { let version = contents .lines() @@ -199,7 +199,7 @@ fn get_lint_file_contents(lint: &LintData<'_>, enable_msrv: bool) -> String { }, }; - let version = get_stabilisation_version(); + let version = get_stabilization_version(); let lint_name = lint.name; let category = lint.category; let name_camel = to_camel_case(lint.name); diff --git a/clippy_lints/src/assign_ops.rs b/clippy_lints/src/assign_ops.rs index 12c1bddf79d..4c2d3366483 100644 --- a/clippy_lints/src/assign_ops.rs +++ b/clippy_lints/src/assign_ops.rs @@ -50,7 +50,7 @@ declare_clippy_lint! { /// ### Known problems /// Clippy cannot know for sure if `a op= a op b` should have /// been `a = a op a op b` or `a = a op b`/`a op= b`. Therefore, it suggests both. - /// If `a op= a op b` is really the correct behaviour it should be + /// If `a op= a op b` is really the correct behavior it should be /// written as `a = a op a op b` as it's less confusing. /// /// ### Example diff --git a/clippy_lints/src/casts/cast_slice_different_sizes.rs b/clippy_lints/src/casts/cast_slice_different_sizes.rs index bb09a6708a0..027c660ce3b 100644 --- a/clippy_lints/src/casts/cast_slice_different_sizes.rs +++ b/clippy_lints/src/casts/cast_slice_different_sizes.rs @@ -121,7 +121,7 @@ fn expr_cast_chain_tys<'tcx>(cx: &LateContext<'tcx>, expr: &Expr<'tcx>) -> Optio let to_slice_ty = get_raw_slice_ty_mut(cast_to)?; // If the expression that makes up the source of this cast is itself a cast, recursively - // call `expr_cast_chain_tys` and update the end type with the final tartet type. + // call `expr_cast_chain_tys` and update the end type with the final target type. // Otherwise, this cast is not immediately nested, just construct the info for this cast if let Some(prev_info) = expr_cast_chain_tys(cx, cast_expr) { Some(CastChainInfo { diff --git a/clippy_lints/src/casts/mod.rs b/clippy_lints/src/casts/mod.rs index 108e119c104..daf3b7b4ce4 100644 --- a/clippy_lints/src/casts/mod.rs +++ b/clippy_lints/src/casts/mod.rs @@ -306,7 +306,7 @@ declare_clippy_lint! { /// Checks for casts of `&T` to `&mut T` anywhere in the code. /// /// ### Why is this bad? - /// It’s basically guaranteed to be undefined behaviour. + /// It’s basically guaranteed to be undefined behavior. /// `UnsafeCell` is the only way to obtain aliasable data that is considered /// mutable. /// diff --git a/clippy_lints/src/default_union_representation.rs b/clippy_lints/src/default_union_representation.rs index 9b5da0bd8a6..d559ad423df 100644 --- a/clippy_lints/src/default_union_representation.rs +++ b/clippy_lints/src/default_union_representation.rs @@ -25,7 +25,7 @@ declare_clippy_lint! { /// /// fn main() { /// let _x: u32 = unsafe { - /// Foo { a: 0_i32 }.b // Undefined behaviour: `b` is allowed to be padding + /// Foo { a: 0_i32 }.b // Undefined behavior: `b` is allowed to be padding /// }; /// } /// ``` @@ -39,7 +39,7 @@ declare_clippy_lint! { /// /// fn main() { /// let _x: u32 = unsafe { - /// Foo { a: 0_i32 }.b // Now defined behaviour, this is just an i32 -> u32 transmute + /// Foo { a: 0_i32 }.b // Now defined behavior, this is just an i32 -> u32 transmute /// }; /// } /// ``` diff --git a/clippy_lints/src/derive.rs b/clippy_lints/src/derive.rs index a4757ebd8c7..fbbc5bf78a5 100644 --- a/clippy_lints/src/derive.rs +++ b/clippy_lints/src/derive.rs @@ -102,8 +102,8 @@ declare_clippy_lint! { /// types. /// /// ### Why is this bad? - /// To avoid surprising behaviour, these traits should - /// agree and the behaviour of `Copy` cannot be overridden. In almost all + /// To avoid surprising behavior, these traits should + /// agree and the behavior of `Copy` cannot be overridden. In almost all /// situations a `Copy` type should have a `Clone` implementation that does /// nothing more than copy the object, which is what `#[derive(Copy, Clone)]` /// gets you. diff --git a/clippy_lints/src/main_recursion.rs b/clippy_lints/src/main_recursion.rs index fad8fa467d4..20333c150e3 100644 --- a/clippy_lints/src/main_recursion.rs +++ b/clippy_lints/src/main_recursion.rs @@ -12,7 +12,7 @@ declare_clippy_lint! { /// /// ### Why is this bad? /// Apart from special setups (which we could detect following attributes like #![no_std]), - /// recursing into main() seems like an unintuitive antipattern we should be able to detect. + /// recursing into main() seems like an unintuitive anti-pattern we should be able to detect. /// /// ### Example /// ```no_run diff --git a/clippy_lints/src/methods/mod.rs b/clippy_lints/src/methods/mod.rs index 3e07961fcb3..35fc452ed7c 100644 --- a/clippy_lints/src/methods/mod.rs +++ b/clippy_lints/src/methods/mod.rs @@ -1563,7 +1563,7 @@ declare_clippy_lint! { #[clippy::version = "1.39.0"] pub MANUAL_SATURATING_ARITHMETIC, style, - "`.chcked_add/sub(x).unwrap_or(MAX/MIN)`" + "`.checked_add/sub(x).unwrap_or(MAX/MIN)`" } declare_clippy_lint! { diff --git a/clippy_lints/src/mutable_debug_assertion.rs b/clippy_lints/src/mutable_debug_assertion.rs index 4ba68c8eacd..8dba60f3a58 100644 --- a/clippy_lints/src/mutable_debug_assertion.rs +++ b/clippy_lints/src/mutable_debug_assertion.rs @@ -16,7 +16,7 @@ declare_clippy_lint! { /// ### Why is this bad? /// In release builds `debug_assert!` macros are optimized out by the /// compiler. - /// Therefore mutating something in a `debug_assert!` macro results in different behaviour + /// Therefore mutating something in a `debug_assert!` macro results in different behavior /// between a release and debug build. /// /// ### Example diff --git a/clippy_lints/src/needless_bitwise_bool.rs b/clippy_lints/src/needless_bitwise_bool.rs index 95395e2e136..623d22bc9bd 100644 --- a/clippy_lints/src/needless_bitwise_bool.rs +++ b/clippy_lints/src/needless_bitwise_bool.rs @@ -53,7 +53,7 @@ fn is_bitwise_operation(cx: &LateContext<'_>, expr: &Expr<'_>) -> bool { false } -fn suggesstion_snippet(cx: &LateContext<'_>, expr: &Expr<'_>) -> Option { +fn suggestion_snippet(cx: &LateContext<'_>, expr: &Expr<'_>) -> Option { if let ExprKind::Binary(ref op, left, right) = expr.kind { if let (Some(l_snippet), Some(r_snippet)) = (snippet_opt(cx, left.span), snippet_opt(cx, right.span)) { let op_snippet = match op.node { @@ -75,7 +75,7 @@ impl LateLintPass<'_> for NeedlessBitwiseBool { expr.span, "use of bitwise operator instead of lazy operator between booleans", |diag| { - if let Some(sugg) = suggesstion_snippet(cx, expr) { + if let Some(sugg) = suggestion_snippet(cx, expr) { diag.span_suggestion(expr.span, "try", sugg, Applicability::MachineApplicable); } }, diff --git a/clippy_lints/src/pass_by_ref_or_value.rs b/clippy_lints/src/pass_by_ref_or_value.rs index c5b8b8103a1..e3ded716341 100644 --- a/clippy_lints/src/pass_by_ref_or_value.rs +++ b/clippy_lints/src/pass_by_ref_or_value.rs @@ -52,7 +52,7 @@ declare_clippy_lint! { /// to a function that needs the memory address. For further details, refer to /// [this issue](https://github.com/rust-lang/rust-clippy/issues/5953) /// that explains a real case in which this false positive - /// led to an **undefined behaviour** introduced with unsafe code. + /// led to an **undefined behavior** introduced with unsafe code. /// /// ### Example /// diff --git a/clippy_lints/src/redundant_clone.rs b/clippy_lints/src/redundant_clone.rs index 9904617353f..b19f9aff611 100644 --- a/clippy_lints/src/redundant_clone.rs +++ b/clippy_lints/src/redundant_clone.rs @@ -632,7 +632,7 @@ impl<'a, 'tcx> mir::visit::Visitor<'tcx> for PossibleBorrowerVisitor<'a, 'tcx> { } /// Collect possible borrowed for every `&mut` local. -/// For exampel, `_1 = &mut _2` generate _1: {_2,...} +/// For example, `_1 = &mut _2` generate _1: {_2,...} /// Known Problems: not sure all borrowed are tracked struct PossibleOriginVisitor<'a, 'tcx> { possible_origin: TransitiveRelation, diff --git a/clippy_lints/src/transmute/mod.rs b/clippy_lints/src/transmute/mod.rs index 342f23f030c..d2a040beb0c 100644 --- a/clippy_lints/src/transmute/mod.rs +++ b/clippy_lints/src/transmute/mod.rs @@ -27,7 +27,7 @@ declare_clippy_lint! { /// architecture. /// /// ### Why is this bad? - /// It's basically guaranteed to be undefined behaviour. + /// It's basically guaranteed to be undefined behavior. /// /// ### Known problems /// When accessing C, users might want to store pointer @@ -40,7 +40,7 @@ declare_clippy_lint! { #[clippy::version = "pre 1.29.0"] pub WRONG_TRANSMUTE, correctness, - "transmutes that are confusing at best, undefined behaviour at worst and always useless" + "transmutes that are confusing at best, undefined behavior at worst and always useless" } // FIXME: Move this to `complexity` again, after #5343 is fixed diff --git a/doc/adding_lints.md b/doc/adding_lints.md index 4dc94d9f5a5..e8f0c338fd5 100644 --- a/doc/adding_lints.md +++ b/doc/adding_lints.md @@ -28,7 +28,7 @@ because that's clearly a non-descriptive name. - [Debugging](#debugging) - [PR Checklist](#pr-checklist) - [Adding configuration to a lint](#adding-configuration-to-a-lint) - - [Cheatsheet](#cheatsheet) + - [Cheat Sheet](#cheat-sheet) ## Setup @@ -649,7 +649,7 @@ in the following steps: with the configuration value and a rust file that should be linted by Clippy. The test can otherwise be written as usual. -## Cheatsheet +## Cheat Sheet Here are some pointers to things you are likely going to need for every lint: diff --git a/tests/ui/blacklisted_name.rs b/tests/ui/blacklisted_name.rs index 57d7139fef5..27df732a088 100644 --- a/tests/ui/blacklisted_name.rs +++ b/tests/ui/blacklisted_name.rs @@ -46,10 +46,10 @@ fn issue_1647_ref_mut() { mod tests { fn issue_7305() { - // `blackisted_name` lint should not be triggered inside of the test code. + // `blacklisted_name` lint should not be triggered inside of the test code. let foo = 0; - // Check that even in nested functions warning is still not triggere. + // Check that even in nested functions warning is still not triggered. fn nested() { let foo = 0; } -- cgit 1.4.1-3-g733a5 From f7378daf71d0b0cf52a2f1800433ba40314a09b7 Mon Sep 17 00:00:00 2001 From: Jason Newcomb Date: Tue, 3 May 2022 11:03:08 -0400 Subject: Add renamed lints to the changelog link list --- CHANGELOG.md | 35 +++++++++++++++++++++++++++++++++++ clippy_dev/src/update_lints.rs | 9 +++++++-- 2 files changed, 42 insertions(+), 2 deletions(-) (limited to 'clippy_dev/src') diff --git a/CHANGELOG.md b/CHANGELOG.md index 4cb7d414534..9d92f43d6eb 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -3290,6 +3290,8 @@ Released 2018-09-13 [`bind_instead_of_map`]: https://rust-lang.github.io/rust-clippy/master/index.html#bind_instead_of_map [`blacklisted_name`]: https://rust-lang.github.io/rust-clippy/master/index.html#blacklisted_name [`blanket_clippy_restriction_lints`]: https://rust-lang.github.io/rust-clippy/master/index.html#blanket_clippy_restriction_lints +[`block_in_if_condition_expr`]: https://rust-lang.github.io/rust-clippy/master/index.html#block_in_if_condition_expr +[`block_in_if_condition_stmt`]: https://rust-lang.github.io/rust-clippy/master/index.html#block_in_if_condition_stmt [`blocks_in_if_conditions`]: https://rust-lang.github.io/rust-clippy/master/index.html#blocks_in_if_conditions [`bool_assert_comparison`]: https://rust-lang.github.io/rust-clippy/master/index.html#bool_assert_comparison [`bool_comparison`]: https://rust-lang.github.io/rust-clippy/master/index.html#bool_comparison @@ -3297,6 +3299,7 @@ Released 2018-09-13 [`borrow_interior_mutable_const`]: https://rust-lang.github.io/rust-clippy/master/index.html#borrow_interior_mutable_const [`borrowed_box`]: https://rust-lang.github.io/rust-clippy/master/index.html#borrowed_box [`box_collection`]: https://rust-lang.github.io/rust-clippy/master/index.html#box_collection +[`box_vec`]: https://rust-lang.github.io/rust-clippy/master/index.html#box_vec [`boxed_local`]: https://rust-lang.github.io/rust-clippy/master/index.html#boxed_local [`branches_sharing_code`]: https://rust-lang.github.io/rust-clippy/master/index.html#branches_sharing_code [`builtin_type_shadow`]: https://rust-lang.github.io/rust-clippy/master/index.html#builtin_type_shadow @@ -3332,10 +3335,12 @@ Released 2018-09-13 [`collapsible_match`]: https://rust-lang.github.io/rust-clippy/master/index.html#collapsible_match [`comparison_chain`]: https://rust-lang.github.io/rust-clippy/master/index.html#comparison_chain [`comparison_to_empty`]: https://rust-lang.github.io/rust-clippy/master/index.html#comparison_to_empty +[`const_static_lifetime`]: https://rust-lang.github.io/rust-clippy/master/index.html#const_static_lifetime [`copy_iterator`]: https://rust-lang.github.io/rust-clippy/master/index.html#copy_iterator [`crate_in_macro_def`]: https://rust-lang.github.io/rust-clippy/master/index.html#crate_in_macro_def [`create_dir`]: https://rust-lang.github.io/rust-clippy/master/index.html#create_dir [`crosspointer_transmute`]: https://rust-lang.github.io/rust-clippy/master/index.html#crosspointer_transmute +[`cyclomatic_complexity`]: https://rust-lang.github.io/rust-clippy/master/index.html#cyclomatic_complexity [`dbg_macro`]: https://rust-lang.github.io/rust-clippy/master/index.html#dbg_macro [`debug_assert_with_mut_call`]: https://rust-lang.github.io/rust-clippy/master/index.html#debug_assert_with_mut_call [`decimal_literal_representation`]: https://rust-lang.github.io/rust-clippy/master/index.html#decimal_literal_representation @@ -3351,8 +3356,10 @@ Released 2018-09-13 [`derive_hash_xor_eq`]: https://rust-lang.github.io/rust-clippy/master/index.html#derive_hash_xor_eq [`derive_ord_xor_partial_ord`]: https://rust-lang.github.io/rust-clippy/master/index.html#derive_ord_xor_partial_ord [`derive_partial_eq_without_eq`]: https://rust-lang.github.io/rust-clippy/master/index.html#derive_partial_eq_without_eq +[`disallowed_method`]: https://rust-lang.github.io/rust-clippy/master/index.html#disallowed_method [`disallowed_methods`]: https://rust-lang.github.io/rust-clippy/master/index.html#disallowed_methods [`disallowed_script_idents`]: https://rust-lang.github.io/rust-clippy/master/index.html#disallowed_script_idents +[`disallowed_type`]: https://rust-lang.github.io/rust-clippy/master/index.html#disallowed_type [`disallowed_types`]: https://rust-lang.github.io/rust-clippy/master/index.html#disallowed_types [`diverging_sub_expression`]: https://rust-lang.github.io/rust-clippy/master/index.html#diverging_sub_expression [`doc_markdown`]: https://rust-lang.github.io/rust-clippy/master/index.html#doc_markdown @@ -3360,6 +3367,7 @@ Released 2018-09-13 [`double_must_use`]: https://rust-lang.github.io/rust-clippy/master/index.html#double_must_use [`double_neg`]: https://rust-lang.github.io/rust-clippy/master/index.html#double_neg [`double_parens`]: https://rust-lang.github.io/rust-clippy/master/index.html#double_parens +[`drop_bounds`]: https://rust-lang.github.io/rust-clippy/master/index.html#drop_bounds [`drop_copy`]: https://rust-lang.github.io/rust-clippy/master/index.html#drop_copy [`drop_non_drop`]: https://rust-lang.github.io/rust-clippy/master/index.html#drop_non_drop [`drop_ref`]: https://rust-lang.github.io/rust-clippy/master/index.html#drop_ref @@ -3379,6 +3387,7 @@ Released 2018-09-13 [`equatable_if_let`]: https://rust-lang.github.io/rust-clippy/master/index.html#equatable_if_let [`erasing_op`]: https://rust-lang.github.io/rust-clippy/master/index.html#erasing_op [`err_expect`]: https://rust-lang.github.io/rust-clippy/master/index.html#err_expect +[`eval_order_dependence`]: https://rust-lang.github.io/rust-clippy/master/index.html#eval_order_dependence [`excessive_precision`]: https://rust-lang.github.io/rust-clippy/master/index.html#excessive_precision [`exhaustive_enums`]: https://rust-lang.github.io/rust-clippy/master/index.html#exhaustive_enums [`exhaustive_structs`]: https://rust-lang.github.io/rust-clippy/master/index.html#exhaustive_structs @@ -3414,6 +3423,8 @@ Released 2018-09-13 [`fn_to_numeric_cast_any`]: https://rust-lang.github.io/rust-clippy/master/index.html#fn_to_numeric_cast_any [`fn_to_numeric_cast_with_truncation`]: https://rust-lang.github.io/rust-clippy/master/index.html#fn_to_numeric_cast_with_truncation [`for_kv_map`]: https://rust-lang.github.io/rust-clippy/master/index.html#for_kv_map +[`for_loop_over_option`]: https://rust-lang.github.io/rust-clippy/master/index.html#for_loop_over_option +[`for_loop_over_result`]: https://rust-lang.github.io/rust-clippy/master/index.html#for_loop_over_result [`for_loops_over_fallibles`]: https://rust-lang.github.io/rust-clippy/master/index.html#for_loops_over_fallibles [`forget_copy`]: https://rust-lang.github.io/rust-clippy/master/index.html#forget_copy [`forget_non_drop`]: https://rust-lang.github.io/rust-clippy/master/index.html#forget_non_drop @@ -3426,9 +3437,11 @@ Released 2018-09-13 [`future_not_send`]: https://rust-lang.github.io/rust-clippy/master/index.html#future_not_send [`get_last_with_len`]: https://rust-lang.github.io/rust-clippy/master/index.html#get_last_with_len [`get_unwrap`]: https://rust-lang.github.io/rust-clippy/master/index.html#get_unwrap +[`identity_conversion`]: https://rust-lang.github.io/rust-clippy/master/index.html#identity_conversion [`identity_op`]: https://rust-lang.github.io/rust-clippy/master/index.html#identity_op [`if_let_mutex`]: https://rust-lang.github.io/rust-clippy/master/index.html#if_let_mutex [`if_let_redundant_pattern_matching`]: https://rust-lang.github.io/rust-clippy/master/index.html#if_let_redundant_pattern_matching +[`if_let_some_result`]: https://rust-lang.github.io/rust-clippy/master/index.html#if_let_some_result [`if_not_else`]: https://rust-lang.github.io/rust-clippy/master/index.html#if_not_else [`if_same_then_else`]: https://rust-lang.github.io/rust-clippy/master/index.html#if_same_then_else [`if_then_some_else_none`]: https://rust-lang.github.io/rust-clippy/master/index.html#if_then_some_else_none @@ -3457,8 +3470,11 @@ Released 2018-09-13 [`int_plus_one`]: https://rust-lang.github.io/rust-clippy/master/index.html#int_plus_one [`integer_arithmetic`]: https://rust-lang.github.io/rust-clippy/master/index.html#integer_arithmetic [`integer_division`]: https://rust-lang.github.io/rust-clippy/master/index.html#integer_division +[`into_iter_on_array`]: https://rust-lang.github.io/rust-clippy/master/index.html#into_iter_on_array [`into_iter_on_ref`]: https://rust-lang.github.io/rust-clippy/master/index.html#into_iter_on_ref +[`invalid_atomic_ordering`]: https://rust-lang.github.io/rust-clippy/master/index.html#invalid_atomic_ordering [`invalid_null_ptr_usage`]: https://rust-lang.github.io/rust-clippy/master/index.html#invalid_null_ptr_usage +[`invalid_ref`]: https://rust-lang.github.io/rust-clippy/master/index.html#invalid_ref [`invalid_regex`]: https://rust-lang.github.io/rust-clippy/master/index.html#invalid_regex [`invalid_upcast_comparisons`]: https://rust-lang.github.io/rust-clippy/master/index.html#invalid_upcast_comparisons [`invisible_characters`]: https://rust-lang.github.io/rust-clippy/master/index.html#invisible_characters @@ -3532,6 +3548,7 @@ Released 2018-09-13 [`match_wild_err_arm`]: https://rust-lang.github.io/rust-clippy/master/index.html#match_wild_err_arm [`match_wildcard_for_single_variants`]: https://rust-lang.github.io/rust-clippy/master/index.html#match_wildcard_for_single_variants [`maybe_infinite_iter`]: https://rust-lang.github.io/rust-clippy/master/index.html#maybe_infinite_iter +[`mem_discriminant_non_enum`]: https://rust-lang.github.io/rust-clippy/master/index.html#mem_discriminant_non_enum [`mem_forget`]: https://rust-lang.github.io/rust-clippy/master/index.html#mem_forget [`mem_replace_option_with_none`]: https://rust-lang.github.io/rust-clippy/master/index.html#mem_replace_option_with_none [`mem_replace_with_default`]: https://rust-lang.github.io/rust-clippy/master/index.html#mem_replace_with_default @@ -3594,6 +3611,7 @@ Released 2018-09-13 [`never_loop`]: https://rust-lang.github.io/rust-clippy/master/index.html#never_loop [`new_ret_no_self`]: https://rust-lang.github.io/rust-clippy/master/index.html#new_ret_no_self [`new_without_default`]: https://rust-lang.github.io/rust-clippy/master/index.html#new_without_default +[`new_without_default_derive`]: https://rust-lang.github.io/rust-clippy/master/index.html#new_without_default_derive [`no_effect`]: https://rust-lang.github.io/rust-clippy/master/index.html#no_effect [`no_effect_underscore_binding`]: https://rust-lang.github.io/rust-clippy/master/index.html#no_effect_underscore_binding [`non_ascii_literal`]: https://rust-lang.github.io/rust-clippy/master/index.html#non_ascii_literal @@ -3607,19 +3625,25 @@ Released 2018-09-13 [`ok_expect`]: https://rust-lang.github.io/rust-clippy/master/index.html#ok_expect [`only_used_in_recursion`]: https://rust-lang.github.io/rust-clippy/master/index.html#only_used_in_recursion [`op_ref`]: https://rust-lang.github.io/rust-clippy/master/index.html#op_ref +[`option_and_then_some`]: https://rust-lang.github.io/rust-clippy/master/index.html#option_and_then_some [`option_as_ref_deref`]: https://rust-lang.github.io/rust-clippy/master/index.html#option_as_ref_deref [`option_env_unwrap`]: https://rust-lang.github.io/rust-clippy/master/index.html#option_env_unwrap +[`option_expect_used`]: https://rust-lang.github.io/rust-clippy/master/index.html#option_expect_used [`option_filter_map`]: https://rust-lang.github.io/rust-clippy/master/index.html#option_filter_map [`option_if_let_else`]: https://rust-lang.github.io/rust-clippy/master/index.html#option_if_let_else [`option_map_or_none`]: https://rust-lang.github.io/rust-clippy/master/index.html#option_map_or_none [`option_map_unit_fn`]: https://rust-lang.github.io/rust-clippy/master/index.html#option_map_unit_fn +[`option_map_unwrap_or`]: https://rust-lang.github.io/rust-clippy/master/index.html#option_map_unwrap_or +[`option_map_unwrap_or_else`]: https://rust-lang.github.io/rust-clippy/master/index.html#option_map_unwrap_or_else [`option_option`]: https://rust-lang.github.io/rust-clippy/master/index.html#option_option +[`option_unwrap_used`]: https://rust-lang.github.io/rust-clippy/master/index.html#option_unwrap_used [`or_fun_call`]: https://rust-lang.github.io/rust-clippy/master/index.html#or_fun_call [`or_then_unwrap`]: https://rust-lang.github.io/rust-clippy/master/index.html#or_then_unwrap [`out_of_bounds_indexing`]: https://rust-lang.github.io/rust-clippy/master/index.html#out_of_bounds_indexing [`overflow_check_conditional`]: https://rust-lang.github.io/rust-clippy/master/index.html#overflow_check_conditional [`panic`]: https://rust-lang.github.io/rust-clippy/master/index.html#panic [`panic_in_result_fn`]: https://rust-lang.github.io/rust-clippy/master/index.html#panic_in_result_fn +[`panic_params`]: https://rust-lang.github.io/rust-clippy/master/index.html#panic_params [`panicking_unwrap`]: https://rust-lang.github.io/rust-clippy/master/index.html#panicking_unwrap [`partialeq_ne_impl`]: https://rust-lang.github.io/rust-clippy/master/index.html#partialeq_ne_impl [`path_buf_push_overwrite`]: https://rust-lang.github.io/rust-clippy/master/index.html#path_buf_push_overwrite @@ -3661,14 +3685,18 @@ Released 2018-09-13 [`redundant_slicing`]: https://rust-lang.github.io/rust-clippy/master/index.html#redundant_slicing [`redundant_static_lifetimes`]: https://rust-lang.github.io/rust-clippy/master/index.html#redundant_static_lifetimes [`ref_binding_to_reference`]: https://rust-lang.github.io/rust-clippy/master/index.html#ref_binding_to_reference +[`ref_in_deref`]: https://rust-lang.github.io/rust-clippy/master/index.html#ref_in_deref [`ref_option_ref`]: https://rust-lang.github.io/rust-clippy/master/index.html#ref_option_ref [`regex_macro`]: https://rust-lang.github.io/rust-clippy/master/index.html#regex_macro [`repeat_once`]: https://rust-lang.github.io/rust-clippy/master/index.html#repeat_once [`replace_consts`]: https://rust-lang.github.io/rust-clippy/master/index.html#replace_consts [`rest_pat_in_fully_bound_structs`]: https://rust-lang.github.io/rust-clippy/master/index.html#rest_pat_in_fully_bound_structs +[`result_expect_used`]: https://rust-lang.github.io/rust-clippy/master/index.html#result_expect_used [`result_map_or_into_option`]: https://rust-lang.github.io/rust-clippy/master/index.html#result_map_or_into_option [`result_map_unit_fn`]: https://rust-lang.github.io/rust-clippy/master/index.html#result_map_unit_fn +[`result_map_unwrap_or_else`]: https://rust-lang.github.io/rust-clippy/master/index.html#result_map_unwrap_or_else [`result_unit_err`]: https://rust-lang.github.io/rust-clippy/master/index.html#result_unit_err +[`result_unwrap_used`]: https://rust-lang.github.io/rust-clippy/master/index.html#result_unwrap_used [`return_self_not_must_use`]: https://rust-lang.github.io/rust-clippy/master/index.html#return_self_not_must_use [`reversed_empty_ranges`]: https://rust-lang.github.io/rust-clippy/master/index.html#reversed_empty_ranges [`same_functions_in_if_condition`]: https://rust-lang.github.io/rust-clippy/master/index.html#same_functions_in_if_condition @@ -3691,6 +3719,7 @@ Released 2018-09-13 [`single_char_add_str`]: https://rust-lang.github.io/rust-clippy/master/index.html#single_char_add_str [`single_char_lifetime_names`]: https://rust-lang.github.io/rust-clippy/master/index.html#single_char_lifetime_names [`single_char_pattern`]: https://rust-lang.github.io/rust-clippy/master/index.html#single_char_pattern +[`single_char_push_str`]: https://rust-lang.github.io/rust-clippy/master/index.html#single_char_push_str [`single_component_path_imports`]: https://rust-lang.github.io/rust-clippy/master/index.html#single_component_path_imports [`single_element_loop`]: https://rust-lang.github.io/rust-clippy/master/index.html#single_element_loop [`single_match`]: https://rust-lang.github.io/rust-clippy/master/index.html#single_match @@ -3709,6 +3738,7 @@ Released 2018-09-13 [`string_to_string`]: https://rust-lang.github.io/rust-clippy/master/index.html#string_to_string [`strlen_on_c_strings`]: https://rust-lang.github.io/rust-clippy/master/index.html#strlen_on_c_strings [`struct_excessive_bools`]: https://rust-lang.github.io/rust-clippy/master/index.html#struct_excessive_bools +[`stutter`]: https://rust-lang.github.io/rust-clippy/master/index.html#stutter [`suboptimal_flops`]: https://rust-lang.github.io/rust-clippy/master/index.html#suboptimal_flops [`suspicious_arithmetic_impl`]: https://rust-lang.github.io/rust-clippy/master/index.html#suspicious_arithmetic_impl [`suspicious_assignment_formatting`]: https://rust-lang.github.io/rust-clippy/master/index.html#suspicious_assignment_formatting @@ -3720,7 +3750,9 @@ Released 2018-09-13 [`suspicious_unary_op_formatting`]: https://rust-lang.github.io/rust-clippy/master/index.html#suspicious_unary_op_formatting [`tabs_in_doc_comments`]: https://rust-lang.github.io/rust-clippy/master/index.html#tabs_in_doc_comments [`temporary_assignment`]: https://rust-lang.github.io/rust-clippy/master/index.html#temporary_assignment +[`temporary_cstring_as_ptr`]: https://rust-lang.github.io/rust-clippy/master/index.html#temporary_cstring_as_ptr [`to_digit_is_some`]: https://rust-lang.github.io/rust-clippy/master/index.html#to_digit_is_some +[`to_string_in_display`]: https://rust-lang.github.io/rust-clippy/master/index.html#to_string_in_display [`to_string_in_format_args`]: https://rust-lang.github.io/rust-clippy/master/index.html#to_string_in_format_args [`todo`]: https://rust-lang.github.io/rust-clippy/master/index.html#todo [`too_many_arguments`]: https://rust-lang.github.io/rust-clippy/master/index.html#too_many_arguments @@ -3755,6 +3787,7 @@ Released 2018-09-13 [`unit_cmp`]: https://rust-lang.github.io/rust-clippy/master/index.html#unit_cmp [`unit_hash`]: https://rust-lang.github.io/rust-clippy/master/index.html#unit_hash [`unit_return_expecting_ord`]: https://rust-lang.github.io/rust-clippy/master/index.html#unit_return_expecting_ord +[`unknown_clippy_lints`]: https://rust-lang.github.io/rust-clippy/master/index.html#unknown_clippy_lints [`unnecessary_cast`]: https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_cast [`unnecessary_filter_map`]: https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_filter_map [`unnecessary_find_map`]: https://rust-lang.github.io/rust-clippy/master/index.html#unnecessary_find_map @@ -3784,6 +3817,7 @@ Released 2018-09-13 [`unused_async`]: https://rust-lang.github.io/rust-clippy/master/index.html#unused_async [`unused_collect`]: https://rust-lang.github.io/rust-clippy/master/index.html#unused_collect [`unused_io_amount`]: https://rust-lang.github.io/rust-clippy/master/index.html#unused_io_amount +[`unused_label`]: https://rust-lang.github.io/rust-clippy/master/index.html#unused_label [`unused_self`]: https://rust-lang.github.io/rust-clippy/master/index.html#unused_self [`unused_unit`]: https://rust-lang.github.io/rust-clippy/master/index.html#unused_unit [`unusual_byte_groupings`]: https://rust-lang.github.io/rust-clippy/master/index.html#unusual_byte_groupings @@ -3824,5 +3858,6 @@ Released 2018-09-13 [`zero_prefixed_literal`]: https://rust-lang.github.io/rust-clippy/master/index.html#zero_prefixed_literal [`zero_ptr`]: https://rust-lang.github.io/rust-clippy/master/index.html#zero_ptr [`zero_sized_map_values`]: https://rust-lang.github.io/rust-clippy/master/index.html#zero_sized_map_values +[`zero_width_space`]: https://rust-lang.github.io/rust-clippy/master/index.html#zero_width_space [`zst_offset`]: https://rust-lang.github.io/rust-clippy/master/index.html#zst_offset diff --git a/clippy_dev/src/update_lints.rs b/clippy_dev/src/update_lints.rs index e9cc4f29943..5024e63bfa7 100644 --- a/clippy_dev/src/update_lints.rs +++ b/clippy_dev/src/update_lints.rs @@ -66,8 +66,13 @@ fn generate_lint_files( |res| { for lint in usable_lints .iter() - .map(|l| &l.name) - .chain(deprecated_lints.iter().map(|l| &l.name)) + .map(|l| &*l.name) + .chain(deprecated_lints.iter().map(|l| &*l.name)) + .chain( + renamed_lints + .iter() + .map(|l| l.old_name.strip_prefix("clippy::").unwrap_or(&l.old_name)), + ) .sorted() { writeln!(res, "[`{}`]: {}#{}", lint, DOCS_LINK, lint).unwrap(); -- cgit 1.4.1-3-g733a5 From 9b55ea78c83d9cb96b3d4ca6a2c4d1a6c7631730 Mon Sep 17 00:00:00 2001 From: Marcel Hellwig Date: Mon, 23 May 2022 09:23:35 +0200 Subject: update dependencies --- Cargo.toml | 4 +- clippy_dev/Cargo.toml | 2 +- clippy_dev/src/main.rs | 156 ++++++++++++++++++++++-------------------------- clippy_dev/src/serve.rs | 10 ++-- lintcheck/Cargo.toml | 2 +- lintcheck/src/config.rs | 22 +++---- 6 files changed, 89 insertions(+), 107 deletions(-) (limited to 'clippy_dev/src') diff --git a/Cargo.toml b/Cargo.toml index 373e720b0d5..3c8b758d53d 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -28,7 +28,7 @@ tempfile = { version = "3.2", optional = true } termize = "0.1" [dev-dependencies] -compiletest_rs = { version = "0.7.1", features = ["tmp"] } +compiletest_rs = { version = "0.8", features = ["tmp"] } tester = "0.9" regex = "1.5" # This is used by the `collect-metadata` alias. @@ -48,7 +48,7 @@ quote = "1.0" serde = { version = "1.0.125", features = ["derive"] } syn = { version = "1.0", features = ["full"] } futures = "0.3" -parking_lot = "0.11.2" +parking_lot = "0.12" tokio = { version = "1", features = ["io-util"] } rustc-semver = "1.1" diff --git a/clippy_dev/Cargo.toml b/clippy_dev/Cargo.toml index 2cfbcea5034..b0d470a2124 100644 --- a/clippy_dev/Cargo.toml +++ b/clippy_dev/Cargo.toml @@ -5,7 +5,7 @@ edition = "2021" [dependencies] aho-corasick = "0.7" -clap = "2.33" +clap = "3.1" indoc = "1.0" itertools = "0.10.1" opener = "0.5" diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index d5cd7ca96c0..ee535b1d3be 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -2,20 +2,20 @@ // warn on lints, that are included in `rust-lang/rust`s bootstrap #![warn(rust_2018_idioms, unused_lifetimes)] -use clap::{App, AppSettings, Arg, ArgMatches, SubCommand}; +use clap::{Arg, ArgMatches, Command}; use clippy_dev::{bless, fmt, lint, new_lint, serve, setup, update_lints}; use indoc::indoc; fn main() { let matches = get_clap_config(); match matches.subcommand() { - ("bless", Some(matches)) => { + Some(("bless", matches)) => { bless::bless(matches.is_present("ignore-timestamp")); }, - ("fmt", Some(matches)) => { + Some(("fmt", matches)) => { fmt::run(matches.is_present("check"), matches.is_present("verbose")); }, - ("update_lints", Some(matches)) => { + Some(("update_lints", matches)) => { if matches.is_present("print-only") { update_lints::print_lints(); } else if matches.is_present("check") { @@ -24,7 +24,7 @@ fn main() { update_lints::update(update_lints::UpdateMode::Change); } }, - ("new_lint", Some(matches)) => { + Some(("new_lint", matches)) => { match new_lint::create( matches.value_of("pass"), matches.value_of("name"), @@ -35,8 +35,8 @@ fn main() { Err(e) => eprintln!("Unable to create lint: {}", e), } }, - ("setup", Some(sub_command)) => match sub_command.subcommand() { - ("intellij", Some(matches)) => { + Some(("setup", sub_command)) => match sub_command.subcommand() { + Some(("intellij", matches)) => { if matches.is_present("remove") { setup::intellij::remove_rustc_src(); } else { @@ -47,14 +47,14 @@ fn main() { ); } }, - ("git-hook", Some(matches)) => { + Some(("git-hook", matches)) => { if matches.is_present("remove") { setup::git_hook::remove_hook(); } else { setup::git_hook::install_hook(matches.is_present("force-override")); } }, - ("vscode-tasks", Some(matches)) => { + Some(("vscode-tasks", matches)) => { if matches.is_present("remove") { setup::vscode::remove_tasks(); } else { @@ -63,23 +63,23 @@ fn main() { }, _ => {}, }, - ("remove", Some(sub_command)) => match sub_command.subcommand() { - ("git-hook", Some(_)) => setup::git_hook::remove_hook(), - ("intellij", Some(_)) => setup::intellij::remove_rustc_src(), - ("vscode-tasks", Some(_)) => setup::vscode::remove_tasks(), + Some(("remove", sub_command)) => match sub_command.subcommand() { + Some(("git-hook", _)) => setup::git_hook::remove_hook(), + Some(("intellij", _)) => setup::intellij::remove_rustc_src(), + Some(("vscode-tasks", _)) => setup::vscode::remove_tasks(), _ => {}, }, - ("serve", Some(matches)) => { + Some(("serve", matches)) => { let port = matches.value_of("port").unwrap().parse().unwrap(); let lint = matches.value_of("lint"); serve::run(port, lint); }, - ("lint", Some(matches)) => { + Some(("lint", matches)) => { let path = matches.value_of("path").unwrap(); let args = matches.values_of("args").into_iter().flatten(); lint::run(path, args); }, - ("rename_lint", Some(matches)) => { + Some(("rename_lint", matches)) => { let old_name = matches.value_of("old_name").unwrap(); let new_name = matches.value_of("new_name").unwrap_or(old_name); let uplift = matches.is_present("uplift"); @@ -89,35 +89,24 @@ fn main() { } } -fn get_clap_config<'a>() -> ArgMatches<'a> { - App::new("Clippy developer tooling") - .setting(AppSettings::ArgRequiredElseHelp) +fn get_clap_config() -> ArgMatches { + Command::new("Clippy developer tooling") + .arg_required_else_help(true) .subcommand( - SubCommand::with_name("bless") - .about("bless the test output changes") - .arg( - Arg::with_name("ignore-timestamp") - .long("ignore-timestamp") - .help("Include files updated before clippy was built"), - ), + Command::new("bless").about("bless the test output changes").arg( + Arg::new("ignore-timestamp") + .long("ignore-timestamp") + .help("Include files updated before clippy was built"), + ), ) .subcommand( - SubCommand::with_name("fmt") + Command::new("fmt") .about("Run rustfmt on all projects and tests") - .arg( - Arg::with_name("check") - .long("check") - .help("Use the rustfmt --check option"), - ) - .arg( - Arg::with_name("verbose") - .short("v") - .long("verbose") - .help("Echo commands run"), - ), + .arg(Arg::new("check").long("check").help("Use the rustfmt --check option")) + .arg(Arg::new("verbose").short('v').long("verbose").help("Echo commands run")), ) .subcommand( - SubCommand::with_name("update_lints") + Command::new("update_lints") .about("Updates lint registration and information from the source code") .long_about( "Makes sure that:\n \ @@ -127,23 +116,23 @@ fn get_clap_config<'a>() -> ArgMatches<'a> { * lint modules in `clippy_lints/*` are visible in `src/lib.rs` via `pub mod`\n \ * all lints are registered in the lint store", ) - .arg(Arg::with_name("print-only").long("print-only").help( + .arg(Arg::new("print-only").long("print-only").help( "Print a table of lints to STDOUT. \ This does not include deprecated and internal lints. \ (Does not modify any files)", )) .arg( - Arg::with_name("check") + Arg::new("check") .long("check") .help("Checks that `cargo dev update_lints` has been run. Used on CI."), ), ) .subcommand( - SubCommand::with_name("new_lint") + Command::new("new_lint") .about("Create new lint and run `cargo dev update_lints`") .arg( - Arg::with_name("pass") - .short("p") + Arg::new("pass") + .short('p') .long("pass") .help("Specify whether the lint runs during the early or late pass") .takes_value(true) @@ -151,16 +140,16 @@ fn get_clap_config<'a>() -> ArgMatches<'a> { .required(true), ) .arg( - Arg::with_name("name") - .short("n") + Arg::new("name") + .short('n') .long("name") .help("Name of the new lint in snake case, ex: fn_too_long") .takes_value(true) .required(true), ) .arg( - Arg::with_name("category") - .short("c") + Arg::new("category") + .short('c') .long("category") .help("What category the lint belongs to") .default_value("nursery") @@ -179,29 +168,25 @@ fn get_clap_config<'a>() -> ArgMatches<'a> { ]) .takes_value(true), ) - .arg( - Arg::with_name("msrv") - .long("msrv") - .help("Add MSRV config code to the lint"), - ), + .arg(Arg::new("msrv").long("msrv").help("Add MSRV config code to the lint")), ) .subcommand( - SubCommand::with_name("setup") + Command::new("setup") .about("Support for setting up your personal development environment") - .setting(AppSettings::ArgRequiredElseHelp) + .arg_required_else_help(true) .subcommand( - SubCommand::with_name("intellij") + Command::new("intellij") .about("Alter dependencies so Intellij Rust can find rustc internals") .arg( - Arg::with_name("remove") + Arg::new("remove") .long("remove") .help("Remove the dependencies added with 'cargo dev setup intellij'") .required(false), ) .arg( - Arg::with_name("rustc-repo-path") + Arg::new("rustc-repo-path") .long("repo-path") - .short("r") + .short('r') .help("The path to a rustc repo that will be used for setting the dependencies") .takes_value(true) .value_name("path") @@ -210,66 +195,65 @@ fn get_clap_config<'a>() -> ArgMatches<'a> { ), ) .subcommand( - SubCommand::with_name("git-hook") + Command::new("git-hook") .about("Add a pre-commit git hook that formats your code to make it look pretty") .arg( - Arg::with_name("remove") + Arg::new("remove") .long("remove") .help("Remove the pre-commit hook added with 'cargo dev setup git-hook'") .required(false), ) .arg( - Arg::with_name("force-override") + Arg::new("force-override") .long("force-override") - .short("f") + .short('f') .help("Forces the override of an existing git pre-commit hook") .required(false), ), ) .subcommand( - SubCommand::with_name("vscode-tasks") + Command::new("vscode-tasks") .about("Add several tasks to vscode for formatting, validation and testing") .arg( - Arg::with_name("remove") + Arg::new("remove") .long("remove") .help("Remove the tasks added with 'cargo dev setup vscode-tasks'") .required(false), ) .arg( - Arg::with_name("force-override") + Arg::new("force-override") .long("force-override") - .short("f") + .short('f') .help("Forces the override of existing vscode tasks") .required(false), ), ), ) .subcommand( - SubCommand::with_name("remove") + Command::new("remove") .about("Support for undoing changes done by the setup command") - .setting(AppSettings::ArgRequiredElseHelp) - .subcommand(SubCommand::with_name("git-hook").about("Remove any existing pre-commit git hook")) - .subcommand(SubCommand::with_name("vscode-tasks").about("Remove any existing vscode tasks")) + .arg_required_else_help(true) + .subcommand(Command::new("git-hook").about("Remove any existing pre-commit git hook")) + .subcommand(Command::new("vscode-tasks").about("Remove any existing vscode tasks")) .subcommand( - SubCommand::with_name("intellij") - .about("Removes rustc source paths added via `cargo dev setup intellij`"), + Command::new("intellij").about("Removes rustc source paths added via `cargo dev setup intellij`"), ), ) .subcommand( - SubCommand::with_name("serve") + Command::new("serve") .about("Launch a local 'ALL the Clippy Lints' website in a browser") .arg( - Arg::with_name("port") + Arg::new("port") .long("port") - .short("p") + .short('p') .help("Local port for the http server") .default_value("8000") .validator_os(serve::validate_port), ) - .arg(Arg::with_name("lint").help("Which lint's page to load initially (optional)")), + .arg(Arg::new("lint").help("Which lint's page to load initially (optional)")), ) .subcommand( - SubCommand::with_name("lint") + Command::new("lint") .about("Manually run clippy on a file or package") .after_help(indoc! {" EXAMPLES @@ -288,33 +272,33 @@ fn get_clap_config<'a>() -> ArgMatches<'a> { cargo dev lint ~/my-project -- -- -W clippy::pedantic "}) .arg( - Arg::with_name("path") + Arg::new("path") .required(true) .help("The path to a file or package directory to lint"), ) .arg( - Arg::with_name("args") - .multiple(true) + Arg::new("args") + .multiple_occurrences(true) .help("Pass extra arguments to cargo/clippy-driver"), ), ) .subcommand( - SubCommand::with_name("rename_lint") + Command::new("rename_lint") .about("Renames the given lint") .arg( - Arg::with_name("old_name") + Arg::new("old_name") .index(1) .required(true) .help("The name of the lint to rename"), ) .arg( - Arg::with_name("new_name") + Arg::new("new_name") .index(2) - .required_unless("uplift") + .required_unless_present("uplift") .help("The new name of the lint"), ) .arg( - Arg::with_name("uplift") + Arg::new("uplift") .long("uplift") .help("This lint will be uplifted into rustc"), ), diff --git a/clippy_dev/src/serve.rs b/clippy_dev/src/serve.rs index b36e2a28ee4..d55b1a354d0 100644 --- a/clippy_dev/src/serve.rs +++ b/clippy_dev/src/serve.rs @@ -1,4 +1,5 @@ -use std::ffi::{OsStr, OsString}; +use std::ffi::OsStr; +use std::num::ParseIntError; use std::path::Path; use std::process::Command; use std::thread; @@ -59,9 +60,6 @@ fn mtime(path: impl AsRef) -> SystemTime { } #[allow(clippy::missing_errors_doc)] -pub fn validate_port(arg: &OsStr) -> Result<(), OsString> { - match arg.to_string_lossy().parse::() { - Ok(_port) => Ok(()), - Err(err) => Err(OsString::from(err.to_string())), - } +pub fn validate_port(arg: &OsStr) -> Result<(), ParseIntError> { + arg.to_string_lossy().parse::().map(|_| ()) } diff --git a/lintcheck/Cargo.toml b/lintcheck/Cargo.toml index e63f65ce2f7..504d58b5197 100644 --- a/lintcheck/Cargo.toml +++ b/lintcheck/Cargo.toml @@ -11,7 +11,7 @@ publish = false [dependencies] cargo_metadata = "0.14" -clap = "2.33" +clap = "3.1" flate2 = "1.0" rayon = "1.5.1" serde = { version = "1.0", features = ["derive"] } diff --git a/lintcheck/src/config.rs b/lintcheck/src/config.rs index de32b484360..a6f93d2a1c0 100644 --- a/lintcheck/src/config.rs +++ b/lintcheck/src/config.rs @@ -1,47 +1,47 @@ -use clap::{App, Arg, ArgMatches}; +use clap::{Arg, ArgMatches, Command}; use std::env; use std::path::PathBuf; -fn get_clap_config<'a>() -> ArgMatches<'a> { - App::new("lintcheck") +fn get_clap_config() -> ArgMatches { + Command::new("lintcheck") .about("run clippy on a set of crates and check output") .arg( - Arg::with_name("only") + Arg::new("only") .takes_value(true) .value_name("CRATE") .long("only") .help("Only process a single crate of the list"), ) .arg( - Arg::with_name("crates-toml") + Arg::new("crates-toml") .takes_value(true) .value_name("CRATES-SOURCES-TOML-PATH") .long("crates-toml") .help("Set the path for a crates.toml where lintcheck should read the sources from"), ) .arg( - Arg::with_name("threads") + Arg::new("threads") .takes_value(true) .value_name("N") - .short("j") + .short('j') .long("jobs") .help("Number of threads to use, 0 automatic choice"), ) .arg( - Arg::with_name("fix") + Arg::new("fix") .long("--fix") .help("Runs cargo clippy --fix and checks if all suggestions apply"), ) .arg( - Arg::with_name("filter") + Arg::new("filter") .long("--filter") .takes_value(true) - .multiple(true) + .multiple_occurrences(true) .value_name("clippy_lint_name") .help("Apply a filter to only collect specified lints, this also overrides `allow` attributes"), ) .arg( - Arg::with_name("markdown") + Arg::new("markdown") .long("--markdown") .help("Change the reports table to use markdown links"), ) -- cgit 1.4.1-3-g733a5 From b55192880040580bbdab9a36afa1d47bd486d6ed Mon Sep 17 00:00:00 2001 From: flip1995 Date: Sun, 17 Apr 2022 20:43:43 +0200 Subject: Auto update lint count in Clippy book --- clippy_dev/src/update_lints.rs | 10 ++++++++++ 1 file changed, 10 insertions(+) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/update_lints.rs b/clippy_dev/src/update_lints.rs index 5024e63bfa7..1bbd9a45b61 100644 --- a/clippy_dev/src/update_lints.rs +++ b/clippy_dev/src/update_lints.rs @@ -58,6 +58,16 @@ fn generate_lint_files( }, ); + replace_region_in_file( + update_mode, + Path::new("book/src/README.md"), + "[There are over ", + " lints included in this crate!]", + |res| { + write!(res, "{}", round_to_fifty(usable_lints.len())).unwrap(); + }, + ); + replace_region_in_file( update_mode, Path::new("CHANGELOG.md"), -- cgit 1.4.1-3-g733a5 From cccc7500464177018f573b9ce9b3b454be50e11b Mon Sep 17 00:00:00 2001 From: Jason Newcomb Date: Mon, 13 Jun 2022 21:10:30 -0400 Subject: Fix `clap` deprecation warnings --- clippy_dev/src/lint.rs | 2 +- clippy_dev/src/main.rs | 212 +++++++++++++++++++-------------------------- clippy_dev/src/new_lint.rs | 7 +- clippy_dev/src/serve.rs | 2 +- lintcheck/src/config.rs | 64 +++++--------- 5 files changed, 120 insertions(+), 167 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/lint.rs b/clippy_dev/src/lint.rs index 9e463aa741c..71005449b4d 100644 --- a/clippy_dev/src/lint.rs +++ b/clippy_dev/src/lint.rs @@ -13,7 +13,7 @@ fn exit_if_err(status: io::Result) { } } -pub fn run<'a>(path: &str, args: impl Iterator) { +pub fn run<'a>(path: &str, args: impl Iterator) { let is_file = match fs::metadata(path) { Ok(metadata) => metadata.is_file(), Err(e) => { diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index ee535b1d3be..2c27a0bcaf9 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -2,7 +2,7 @@ // warn on lints, that are included in `rust-lang/rust`s bootstrap #![warn(rust_2018_idioms, unused_lifetimes)] -use clap::{Arg, ArgMatches, Command}; +use clap::{Arg, ArgAction, ArgMatches, Command, PossibleValue}; use clippy_dev::{bless, fmt, lint, new_lint, serve, setup, update_lints}; use indoc::indoc; fn main() { @@ -10,15 +10,15 @@ fn main() { match matches.subcommand() { Some(("bless", matches)) => { - bless::bless(matches.is_present("ignore-timestamp")); + bless::bless(matches.contains_id("ignore-timestamp")); }, Some(("fmt", matches)) => { - fmt::run(matches.is_present("check"), matches.is_present("verbose")); + fmt::run(matches.contains_id("check"), matches.contains_id("verbose")); }, Some(("update_lints", matches)) => { - if matches.is_present("print-only") { + if matches.contains_id("print-only") { update_lints::print_lints(); - } else if matches.is_present("check") { + } else if matches.contains_id("check") { update_lints::update(update_lints::UpdateMode::Check); } else { update_lints::update(update_lints::UpdateMode::Change); @@ -26,10 +26,10 @@ fn main() { }, Some(("new_lint", matches)) => { match new_lint::create( - matches.value_of("pass"), - matches.value_of("name"), - matches.value_of("category"), - matches.is_present("msrv"), + matches.get_one::("pass"), + matches.get_one::("name"), + matches.get_one::("category"), + matches.contains_id("msrv"), ) { Ok(_) => update_lints::update(update_lints::UpdateMode::Change), Err(e) => eprintln!("Unable to create lint: {}", e), @@ -37,28 +37,28 @@ fn main() { }, Some(("setup", sub_command)) => match sub_command.subcommand() { Some(("intellij", matches)) => { - if matches.is_present("remove") { + if matches.contains_id("remove") { setup::intellij::remove_rustc_src(); } else { setup::intellij::setup_rustc_src( matches - .value_of("rustc-repo-path") + .get_one::("rustc-repo-path") .expect("this field is mandatory and therefore always valid"), ); } }, Some(("git-hook", matches)) => { - if matches.is_present("remove") { + if matches.contains_id("remove") { setup::git_hook::remove_hook(); } else { - setup::git_hook::install_hook(matches.is_present("force-override")); + setup::git_hook::install_hook(matches.contains_id("force-override")); } }, Some(("vscode-tasks", matches)) => { - if matches.is_present("remove") { + if matches.contains_id("remove") { setup::vscode::remove_tasks(); } else { - setup::vscode::install_tasks(matches.is_present("force-override")); + setup::vscode::install_tasks(matches.contains_id("force-override")); } }, _ => {}, @@ -70,19 +70,19 @@ fn main() { _ => {}, }, Some(("serve", matches)) => { - let port = matches.value_of("port").unwrap().parse().unwrap(); - let lint = matches.value_of("lint"); + let port = *matches.get_one::("port").unwrap(); + let lint = matches.get_one::("lint"); serve::run(port, lint); }, Some(("lint", matches)) => { - let path = matches.value_of("path").unwrap(); - let args = matches.values_of("args").into_iter().flatten(); + let path = matches.get_one::("path").unwrap(); + let args = matches.get_many::("args").into_iter().flatten(); lint::run(path, args); }, Some(("rename_lint", matches)) => { - let old_name = matches.value_of("old_name").unwrap(); - let new_name = matches.value_of("new_name").unwrap_or(old_name); - let uplift = matches.is_present("uplift"); + let old_name = matches.get_one::("old_name").unwrap(); + let new_name = matches.get_one::("new_name").unwrap_or(old_name); + let uplift = matches.contains_id("uplift"); update_lints::rename(old_name, new_name, uplift); }, _ => {}, @@ -92,98 +92,86 @@ fn main() { fn get_clap_config() -> ArgMatches { Command::new("Clippy developer tooling") .arg_required_else_help(true) - .subcommand( + .subcommands([ Command::new("bless").about("bless the test output changes").arg( Arg::new("ignore-timestamp") .long("ignore-timestamp") .help("Include files updated before clippy was built"), ), - ) - .subcommand( Command::new("fmt") .about("Run rustfmt on all projects and tests") - .arg(Arg::new("check").long("check").help("Use the rustfmt --check option")) - .arg(Arg::new("verbose").short('v').long("verbose").help("Echo commands run")), - ) - .subcommand( + .args([ + Arg::new("check").long("check").help("Use the rustfmt --check option"), + Arg::new("verbose").short('v').long("verbose").help("Echo commands run"), + ]), Command::new("update_lints") .about("Updates lint registration and information from the source code") .long_about( "Makes sure that:\n \ - * the lint count in README.md is correct\n \ - * the changelog contains markdown link references at the bottom\n \ - * all lint groups include the correct lints\n \ - * lint modules in `clippy_lints/*` are visible in `src/lib.rs` via `pub mod`\n \ - * all lints are registered in the lint store", + * the lint count in README.md is correct\n \ + * the changelog contains markdown link references at the bottom\n \ + * all lint groups include the correct lints\n \ + * lint modules in `clippy_lints/*` are visible in `src/lib.rs` via `pub mod`\n \ + * all lints are registered in the lint store", ) - .arg(Arg::new("print-only").long("print-only").help( - "Print a table of lints to STDOUT. \ - This does not include deprecated and internal lints. \ - (Does not modify any files)", - )) - .arg( + .args([ + Arg::new("print-only").long("print-only").help( + "Print a table of lints to STDOUT. \ + This does not include deprecated and internal lints. \ + (Does not modify any files)", + ), Arg::new("check") .long("check") .help("Checks that `cargo dev update_lints` has been run. Used on CI."), - ), - ) - .subcommand( + ]), Command::new("new_lint") .about("Create new lint and run `cargo dev update_lints`") - .arg( + .args([ Arg::new("pass") .short('p') .long("pass") .help("Specify whether the lint runs during the early or late pass") .takes_value(true) - .possible_values(&["early", "late"]) + .value_parser([PossibleValue::new("early"), PossibleValue::new("late")]) .required(true), - ) - .arg( Arg::new("name") .short('n') .long("name") .help("Name of the new lint in snake case, ex: fn_too_long") .takes_value(true) .required(true), - ) - .arg( Arg::new("category") .short('c') .long("category") .help("What category the lint belongs to") .default_value("nursery") - .possible_values(&[ - "style", - "correctness", - "suspicious", - "complexity", - "perf", - "pedantic", - "restriction", - "cargo", - "nursery", - "internal", - "internal_warn", + .value_parser([ + PossibleValue::new("style"), + PossibleValue::new("correctness"), + PossibleValue::new("suspicious"), + PossibleValue::new("complexity"), + PossibleValue::new("perf"), + PossibleValue::new("pedantic"), + PossibleValue::new("restriction"), + PossibleValue::new("cargo"), + PossibleValue::new("nursery"), + PossibleValue::new("internal"), + PossibleValue::new("internal_warn"), ]) .takes_value(true), - ) - .arg(Arg::new("msrv").long("msrv").help("Add MSRV config code to the lint")), - ) - .subcommand( + Arg::new("msrv").long("msrv").help("Add MSRV config code to the lint"), + ]), Command::new("setup") .about("Support for setting up your personal development environment") .arg_required_else_help(true) - .subcommand( + .subcommands([ Command::new("intellij") .about("Alter dependencies so Intellij Rust can find rustc internals") - .arg( + .args([ Arg::new("remove") .long("remove") .help("Remove the dependencies added with 'cargo dev setup intellij'") .required(false), - ) - .arg( Arg::new("rustc-repo-path") .long("repo-path") .short('r') @@ -192,67 +180,53 @@ fn get_clap_config() -> ArgMatches { .value_name("path") .conflicts_with("remove") .required(true), - ), - ) - .subcommand( + ]), Command::new("git-hook") .about("Add a pre-commit git hook that formats your code to make it look pretty") - .arg( + .args([ Arg::new("remove") .long("remove") .help("Remove the pre-commit hook added with 'cargo dev setup git-hook'") .required(false), - ) - .arg( Arg::new("force-override") .long("force-override") .short('f') .help("Forces the override of an existing git pre-commit hook") .required(false), - ), - ) - .subcommand( + ]), Command::new("vscode-tasks") .about("Add several tasks to vscode for formatting, validation and testing") - .arg( + .args([ Arg::new("remove") .long("remove") .help("Remove the tasks added with 'cargo dev setup vscode-tasks'") .required(false), - ) - .arg( Arg::new("force-override") .long("force-override") .short('f') .help("Forces the override of existing vscode tasks") .required(false), - ), - ), - ) - .subcommand( + ]), + ]), Command::new("remove") .about("Support for undoing changes done by the setup command") .arg_required_else_help(true) - .subcommand(Command::new("git-hook").about("Remove any existing pre-commit git hook")) - .subcommand(Command::new("vscode-tasks").about("Remove any existing vscode tasks")) - .subcommand( + .subcommands([ + Command::new("git-hook").about("Remove any existing pre-commit git hook"), + Command::new("vscode-tasks").about("Remove any existing vscode tasks"), Command::new("intellij").about("Removes rustc source paths added via `cargo dev setup intellij`"), - ), - ) - .subcommand( + ]), Command::new("serve") .about("Launch a local 'ALL the Clippy Lints' website in a browser") - .arg( + .args([ Arg::new("port") .long("port") .short('p') .help("Local port for the http server") .default_value("8000") - .validator_os(serve::validate_port), - ) - .arg(Arg::new("lint").help("Which lint's page to load initially (optional)")), - ) - .subcommand( + .value_parser(clap::value_parser!(u16)), + Arg::new("lint").help("Which lint's page to load initially (optional)"), + ]), Command::new("lint") .about("Manually run clippy on a file or package") .after_help(indoc! {" @@ -271,37 +245,27 @@ fn get_clap_config() -> ArgMatches { cargo dev lint file.rs -- -W clippy::pedantic cargo dev lint ~/my-project -- -- -W clippy::pedantic "}) - .arg( + .args([ Arg::new("path") .required(true) .help("The path to a file or package directory to lint"), - ) - .arg( Arg::new("args") - .multiple_occurrences(true) + .action(ArgAction::Append) .help("Pass extra arguments to cargo/clippy-driver"), - ), - ) - .subcommand( - Command::new("rename_lint") - .about("Renames the given lint") - .arg( - Arg::new("old_name") - .index(1) - .required(true) - .help("The name of the lint to rename"), - ) - .arg( - Arg::new("new_name") - .index(2) - .required_unless_present("uplift") - .help("The new name of the lint"), - ) - .arg( - Arg::new("uplift") - .long("uplift") - .help("This lint will be uplifted into rustc"), - ), - ) + ]), + Command::new("rename_lint").about("Renames the given lint").args([ + Arg::new("old_name") + .index(1) + .required(true) + .help("The name of the lint to rename"), + Arg::new("new_name") + .index(2) + .required_unless_present("uplift") + .help("The new name of the lint"), + Arg::new("uplift") + .long("uplift") + .help("This lint will be uplifted into rustc"), + ]), + ]) .get_matches() } diff --git a/clippy_dev/src/new_lint.rs b/clippy_dev/src/new_lint.rs index 07d19638788..748d73c0801 100644 --- a/clippy_dev/src/new_lint.rs +++ b/clippy_dev/src/new_lint.rs @@ -34,7 +34,12 @@ impl Context for io::Result { /// # Errors /// /// This function errors out if the files couldn't be created or written to. -pub fn create(pass: Option<&str>, lint_name: Option<&str>, category: Option<&str>, msrv: bool) -> io::Result<()> { +pub fn create( + pass: Option<&String>, + lint_name: Option<&String>, + category: Option<&String>, + msrv: bool, +) -> io::Result<()> { let lint = LintData { pass: pass.expect("`pass` argument is validated by clap"), name: lint_name.expect("`name` argument is validated by clap"), diff --git a/clippy_dev/src/serve.rs b/clippy_dev/src/serve.rs index d55b1a354d0..f15f24da946 100644 --- a/clippy_dev/src/serve.rs +++ b/clippy_dev/src/serve.rs @@ -8,7 +8,7 @@ use std::time::{Duration, SystemTime}; /// # Panics /// /// Panics if the python commands could not be spawned -pub fn run(port: u16, lint: Option<&str>) -> ! { +pub fn run(port: u16, lint: Option<&String>) -> ! { let mut url = Some(match lint { None => format!("http://localhost:{}", port), Some(lint) => format!("http://localhost:{}/#{}", port, lint), diff --git a/lintcheck/src/config.rs b/lintcheck/src/config.rs index a6f93d2a1c0..1742cf677c0 100644 --- a/lintcheck/src/config.rs +++ b/lintcheck/src/config.rs @@ -1,50 +1,40 @@ -use clap::{Arg, ArgMatches, Command}; +use clap::{Arg, ArgAction, ArgMatches, Command}; use std::env; use std::path::PathBuf; fn get_clap_config() -> ArgMatches { Command::new("lintcheck") .about("run clippy on a set of crates and check output") - .arg( + .args([ Arg::new("only") - .takes_value(true) + .action(ArgAction::Set) .value_name("CRATE") .long("only") .help("Only process a single crate of the list"), - ) - .arg( Arg::new("crates-toml") - .takes_value(true) + .action(ArgAction::Set) .value_name("CRATES-SOURCES-TOML-PATH") .long("crates-toml") .help("Set the path for a crates.toml where lintcheck should read the sources from"), - ) - .arg( Arg::new("threads") - .takes_value(true) + .action(ArgAction::Set) .value_name("N") + .value_parser(clap::value_parser!(usize)) .short('j') .long("jobs") .help("Number of threads to use, 0 automatic choice"), - ) - .arg( Arg::new("fix") - .long("--fix") + .long("fix") .help("Runs cargo clippy --fix and checks if all suggestions apply"), - ) - .arg( Arg::new("filter") - .long("--filter") - .takes_value(true) - .multiple_occurrences(true) + .long("filter") + .action(ArgAction::Append) .value_name("clippy_lint_name") .help("Apply a filter to only collect specified lints, this also overrides `allow` attributes"), - ) - .arg( Arg::new("markdown") - .long("--markdown") + .long("markdown") .help("Change the reports table to use markdown links"), - ) + ]) .get_matches() } @@ -75,13 +65,13 @@ impl LintcheckConfig { // if not, use the default "lintcheck/lintcheck_crates.toml" let sources_toml = env::var("LINTCHECK_TOML").unwrap_or_else(|_| { clap_config - .value_of("crates-toml") - .clone() + .get_one::("crates-toml") + .map(|s| &**s) .unwrap_or("lintcheck/lintcheck_crates.toml") - .to_string() + .into() }); - let markdown = clap_config.is_present("markdown"); + let markdown = clap_config.contains_id("markdown"); let sources_toml_path = PathBuf::from(sources_toml); // for the path where we save the lint results, get the filename without extension (so for @@ -96,25 +86,19 @@ impl LintcheckConfig { // look at the --threads arg, if 0 is passed, ask rayon rayon how many threads it would spawn and // use half of that for the physical core count // by default use a single thread - let max_jobs = match clap_config.value_of("threads") { - Some(threads) => { - let threads: usize = threads - .parse() - .unwrap_or_else(|_| panic!("Failed to parse '{}' to a digit", threads)); - if threads == 0 { - // automatic choice - // Rayon seems to return thread count so half that for core count - (rayon::current_num_threads() / 2) as usize - } else { - threads - } + let max_jobs = match clap_config.get_one::("threads") { + Some(&0) => { + // automatic choice + // Rayon seems to return thread count so half that for core count + (rayon::current_num_threads() / 2) as usize }, + Some(&threads) => threads, // no -j passed, use a single thread None => 1, }; let lint_filter: Vec = clap_config - .values_of("filter") + .get_many::("filter") .map(|iter| { iter.map(|lint_name| { let mut filter = lint_name.replace('_', "-"); @@ -131,8 +115,8 @@ impl LintcheckConfig { max_jobs, sources_toml_path, lintcheck_results_path, - only: clap_config.value_of("only").map(String::from), - fix: clap_config.is_present("fix"), + only: clap_config.get_one::("only").map(String::from), + fix: clap_config.contains_id("fix"), lint_filter, markdown, } -- cgit 1.4.1-3-g733a5 From 2bd1581bbf8e6e1ac3ad78638ac9c1ab0baa9a8f Mon Sep 17 00:00:00 2001 From: Serial <69764315+Serial-ATA@users.noreply.github.com> Date: Sun, 22 May 2022 15:41:43 -0400 Subject: Add `dev deprecate` --- clippy_dev/Cargo.toml | 2 +- clippy_dev/src/main.rs | 18 + clippy_dev/src/new_lint.rs | 2 +- clippy_dev/src/update_lints.rs | 393 ++++++++++++++++++--- clippy_lints/src/deprecated_lints.rs | 16 +- clippy_lints/src/lib.register_internal.rs | 1 + clippy_lints/src/lib.register_lints.rs | 2 + clippy_lints/src/utils/internal_lints.rs | 107 ++++-- .../src/utils/internal_lints/metadata_collector.rs | 2 +- 9 files changed, 474 insertions(+), 69 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/Cargo.toml b/clippy_dev/Cargo.toml index b0d470a2124..2ac3b4fe2ed 100644 --- a/clippy_dev/Cargo.toml +++ b/clippy_dev/Cargo.toml @@ -5,7 +5,7 @@ edition = "2021" [dependencies] aho-corasick = "0.7" -clap = "3.1" +clap = "3.2" indoc = "1.0" itertools = "0.10.1" opener = "0.5" diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index 2c27a0bcaf9..243a901503f 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -5,6 +5,7 @@ use clap::{Arg, ArgAction, ArgMatches, Command, PossibleValue}; use clippy_dev::{bless, fmt, lint, new_lint, serve, setup, update_lints}; use indoc::indoc; + fn main() { let matches = get_clap_config(); @@ -85,6 +86,11 @@ fn main() { let uplift = matches.contains_id("uplift"); update_lints::rename(old_name, new_name, uplift); }, + Some(("deprecate", matches)) => { + let name = matches.get_one::("name").unwrap(); + let reason = matches.get_one("reason"); + update_lints::deprecate(name, reason); + }, _ => {}, } } @@ -266,6 +272,18 @@ fn get_clap_config() -> ArgMatches { .long("uplift") .help("This lint will be uplifted into rustc"), ]), + Command::new("deprecate").about("Deprecates the given lint").args([ + Arg::new("name") + .index(1) + .required(true) + .help("The name of the lint to deprecate"), + Arg::new("reason") + .long("reason") + .short('r') + .required(false) + .takes_value(true) + .help("The reason for deprecation"), + ]), ]) .get_matches() } diff --git a/clippy_dev/src/new_lint.rs b/clippy_dev/src/new_lint.rs index 748d73c0801..7d7e760ef44 100644 --- a/clippy_dev/src/new_lint.rs +++ b/clippy_dev/src/new_lint.rs @@ -138,7 +138,7 @@ fn to_camel_case(name: &str) -> String { .collect() } -fn get_stabilization_version() -> String { +pub(crate) fn get_stabilization_version() -> String { fn parse_manifest(contents: &str) -> Option { let version = contents .lines() diff --git a/clippy_dev/src/update_lints.rs b/clippy_dev/src/update_lints.rs index 1bbd9a45b61..31deb499b2e 100644 --- a/clippy_dev/src/update_lints.rs +++ b/clippy_dev/src/update_lints.rs @@ -1,16 +1,17 @@ +use crate::clippy_project_root; use aho_corasick::AhoCorasickBuilder; -use core::fmt::Write as _; +use indoc::writedoc; use itertools::Itertools; use rustc_lexer::{tokenize, unescape, LiteralKind, TokenKind}; use std::collections::{HashMap, HashSet}; use std::ffi::OsStr; -use std::fs; -use std::io::{self, Read as _, Seek as _, Write as _}; +use std::fmt::Write; +use std::fs::{self, OpenOptions}; +use std::io::{self, Read, Seek, SeekFrom, Write as _}; +use std::ops::Range; use std::path::{Path, PathBuf}; use walkdir::{DirEntry, WalkDir}; -use crate::clippy_project_root; - const GENERATED_FILE_COMMENT: &str = "// This file was generated by `cargo dev update_lints`.\n\ // Use that command to update this file and do not edit by hand.\n\ // Manual edits will be overwritten.\n\n"; @@ -326,6 +327,198 @@ pub fn rename(old_name: &str, new_name: &str, uplift: bool) { println!("note: `cargo uitest` still needs to be run to update the test results"); } +const DEFAULT_DEPRECATION_REASON: &str = "default deprecation note"; +/// Runs the `deprecate` command +/// +/// This does the following: +/// * Adds an entry to `deprecated_lints.rs`. +/// * Removes the lint declaration (and the entire file if applicable) +/// +/// # Panics +/// +/// If a file path could not read from or written to +pub fn deprecate(name: &str, reason: Option<&String>) { + fn finish( + (lints, mut deprecated_lints, renamed_lints): (Vec, Vec, Vec), + name: &str, + reason: &str, + ) { + deprecated_lints.push(DeprecatedLint { + name: name.to_string(), + reason: reason.to_string(), + declaration_range: Range::default(), + }); + + generate_lint_files(UpdateMode::Change, &lints, &deprecated_lints, &renamed_lints); + println!("info: `{}` has successfully been deprecated", name); + + if reason == DEFAULT_DEPRECATION_REASON { + println!("note: the deprecation reason must be updated in `clippy_lints/src/deprecated_lints.rs`"); + } + println!("note: you must run `cargo uitest` to update the test results"); + } + + let reason = reason.map_or(DEFAULT_DEPRECATION_REASON, String::as_str); + let name_lower = name.to_lowercase(); + let name_upper = name.to_uppercase(); + + let (mut lints, deprecated_lints, renamed_lints) = gather_all(); + let Some(lint) = lints.iter().find(|l| l.name == name_lower) else { panic!("failed to find lint `{}`", name) }; + + let mod_path = { + let mut mod_path = PathBuf::from(format!("clippy_lints/src/{}", lint.module)); + if mod_path.is_dir() { + mod_path = mod_path.join(name); + } + + mod_path.set_extension("rs"); + mod_path + }; + + let deprecated_lints_path = &*clippy_project_root().join("clippy_lints/src/deprecated_lints.rs"); + + if remove_lint_declaration(&name_lower, &mod_path, &mut lints).unwrap_or(false) { + declare_deprecated(&name_upper, deprecated_lints_path, reason).unwrap(); + finish((lints, deprecated_lints, renamed_lints), name, reason); + return; + } + + eprintln!("error: lint not found"); +} + +fn remove_lint_declaration(name: &str, path: &Path, lints: &mut Vec) -> io::Result { + fn remove_lint(name: &str, lints: &mut Vec) { + lints.iter().position(|l| l.name == name).map(|pos| lints.remove(pos)); + } + + fn remove_test_assets(name: &str) { + let test_file_stem = format!("tests/ui/{}", name); + let path = Path::new(&test_file_stem); + + // Some lints have their own directories, delete them + if path.is_dir() { + fs::remove_dir_all(path).ok(); + return; + } + + // Remove all related test files + fs::remove_file(path.with_extension("rs")).ok(); + fs::remove_file(path.with_extension("stderr")).ok(); + fs::remove_file(path.with_extension("fixed")).ok(); + } + + fn remove_impl_lint_pass(lint_name_upper: &str, content: &mut String) { + let impl_lint_pass_start = content.find("impl_lint_pass!").unwrap_or_else(|| { + content + .find("declare_lint_pass!") + .unwrap_or_else(|| panic!("failed to find `impl_lint_pass`")) + }); + let mut impl_lint_pass_end = (&content[impl_lint_pass_start..]) + .find(']') + .expect("failed to find `impl_lint_pass` terminator"); + + impl_lint_pass_end += impl_lint_pass_start; + if let Some(lint_name_pos) = content[impl_lint_pass_start..impl_lint_pass_end].find(&lint_name_upper) { + let mut lint_name_end = impl_lint_pass_start + (lint_name_pos + lint_name_upper.len()); + for c in content[lint_name_end..impl_lint_pass_end].chars() { + // Remove trailing whitespace + if c.is_whitespace() { + lint_name_end += 1; + } else { + break; + } + } + + content.replace_range(impl_lint_pass_start + lint_name_pos..lint_name_end, ""); + } + } + + if path.exists() { + if let Some(lint) = lints.iter().find(|l| l.name == name) { + if lint.module == name { + // The lint name is the same as the file, we can just delete the entire file + fs::remove_file(path)?; + } else { + // We can't delete the entire file, just remove the declaration + if lint.module != name { + let mut mod_decl_path = path.to_path_buf(); + if mod_decl_path.is_dir() { + mod_decl_path = Path::new("clippy_lints/src").join(&lint.module).join("mod.rs"); + } + + let mut content = fs::read_to_string(&mod_decl_path) + .unwrap_or_else(|_| panic!("failed to read `{}`", path.to_string_lossy())); + + eprintln!( + "warn: you will have to manually remove any code related to `{}` from `{}`", + name, + &mod_decl_path.to_string_lossy() + ); + + assert!( + content[lint.declaration_range.clone()].contains(&name.to_uppercase()), + "error: `{}` does not contain lint `{}`'s declaration", + mod_decl_path.display(), + lint.name + ); + + // Remove lint declaration (declare_clippy_lint!) + content.replace_range(lint.declaration_range.clone(), ""); + + // Remove the module declaration (mod xyz;) + let mod_decl = format!("\nmod {};", name); + content = content.replacen(&mod_decl, "", 1); + + remove_impl_lint_pass(&lint.name.to_uppercase(), &mut content); + fs::write(mod_decl_path, content) + .unwrap_or_else(|_| panic!("failed to write to `{}`", path.to_string_lossy())); + } + } + + remove_test_assets(name); + remove_lint(name, lints); + return Ok(true); + } + } + + Ok(false) +} + +fn declare_deprecated(name: &str, path: &Path, reason: &str) -> io::Result<()> { + let mut file = OpenOptions::new().write(true).open(path)?; + + file.seek(SeekFrom::End(0))?; + + let version = crate::new_lint::get_stabilization_version(); + let deprecation_reason = if reason == DEFAULT_DEPRECATION_REASON { + "TODO" + } else { + reason + }; + + writedoc!( + file, + " + + declare_deprecated_lint! {{ + /// ### What it does + /// Nothing. This lint has been deprecated. + /// + /// ### Deprecation reason + /// {} + #[clippy::version = \"{}\"] + pub {}, + \"{}\" + }} + + ", + deprecation_reason, + version, + name, + reason, + ) +} + /// Replace substrings if they aren't bordered by identifier characters. Returns `None` if there /// were no replacements. fn replace_ident_like(contents: &str, replacements: &[(&str, &str)]) -> Option { @@ -393,16 +586,18 @@ struct Lint { group: String, desc: String, module: String, + declaration_range: Range, } impl Lint { #[must_use] - fn new(name: &str, group: &str, desc: &str, module: &str) -> Self { + fn new(name: &str, group: &str, desc: &str, module: &str, declaration_range: Range) -> Self { Self { name: name.to_lowercase(), group: group.into(), desc: remove_line_splices(desc), module: module.into(), + declaration_range, } } @@ -433,12 +628,14 @@ impl Lint { struct DeprecatedLint { name: String, reason: String, + declaration_range: Range, } impl DeprecatedLint { - fn new(name: &str, reason: &str) -> Self { + fn new(name: &str, reason: &str, declaration_range: Range) -> Self { Self { name: name.to_lowercase(), reason: remove_line_splices(reason), + declaration_range, } } } @@ -610,7 +807,11 @@ fn clippy_lints_src_files() -> impl Iterator { macro_rules! match_tokens { ($iter:ident, $($token:ident $({$($fields:tt)*})? $(($capture:ident))?)*) => { { - $($(let $capture =)? if let Some((TokenKind::$token $({$($fields)*})?, _x)) = $iter.next() { + $($(let $capture =)? if let Some(LintDeclSearchResult { + token_kind: TokenKind::$token $({$($fields)*})?, + content: _x, + .. + }) = $iter.next() { _x } else { continue; @@ -621,40 +822,72 @@ macro_rules! match_tokens { } } +struct LintDeclSearchResult<'a> { + token_kind: TokenKind, + content: &'a str, + range: Range, +} + /// Parse a source file looking for `declare_clippy_lint` macro invocations. fn parse_contents(contents: &str, module: &str, lints: &mut Vec) { let mut offset = 0usize; let mut iter = tokenize(contents).map(|t| { let range = offset..offset + t.len; offset = range.end; - (t.kind, &contents[range]) + + LintDeclSearchResult { + token_kind: t.kind, + content: &contents[range.clone()], + range, + } }); - while iter.any(|(kind, s)| kind == TokenKind::Ident && s == "declare_clippy_lint") { + while let Some(LintDeclSearchResult { range, .. }) = iter.find( + |LintDeclSearchResult { + token_kind, content, .. + }| token_kind == &TokenKind::Ident && *content == "declare_clippy_lint", + ) { + let start = range.start; + let mut iter = iter .by_ref() - .filter(|&(kind, _)| !matches!(kind, TokenKind::Whitespace | TokenKind::LineComment { .. })); + .filter(|t| !matches!(t.token_kind, TokenKind::Whitespace | TokenKind::LineComment { .. })); // matches `!{` match_tokens!(iter, Bang OpenBrace); match iter.next() { // #[clippy::version = "version"] pub - Some((TokenKind::Pound, _)) => { + Some(LintDeclSearchResult { + token_kind: TokenKind::Pound, + .. + }) => { match_tokens!(iter, OpenBracket Ident Colon Colon Ident Eq Literal{..} CloseBracket Ident); }, // pub - Some((TokenKind::Ident, _)) => (), + Some(LintDeclSearchResult { + token_kind: TokenKind::Ident, + .. + }) => (), _ => continue, } + let (name, group, desc) = match_tokens!( iter, // LINT_NAME Ident(name) Comma // group, Ident(group) Comma - // "description" } - Literal{..}(desc) CloseBrace + // "description" + Literal{..}(desc) ); - lints.push(Lint::new(name, group, desc, module)); + + if let Some(LintDeclSearchResult { + token_kind: TokenKind::CloseBrace, + range, + .. + }) = iter.next() + { + lints.push(Lint::new(name, group, desc, module, start..range.end)); + } } } @@ -664,12 +897,24 @@ fn parse_deprecated_contents(contents: &str, lints: &mut Vec) { let mut iter = tokenize(contents).map(|t| { let range = offset..offset + t.len; offset = range.end; - (t.kind, &contents[range]) + + LintDeclSearchResult { + token_kind: t.kind, + content: &contents[range.clone()], + range, + } }); - while iter.any(|(kind, s)| kind == TokenKind::Ident && s == "declare_deprecated_lint") { - let mut iter = iter - .by_ref() - .filter(|&(kind, _)| !matches!(kind, TokenKind::Whitespace | TokenKind::LineComment { .. })); + + while let Some(LintDeclSearchResult { range, .. }) = iter.find( + |LintDeclSearchResult { + token_kind, content, .. + }| token_kind == &TokenKind::Ident && *content == "declare_deprecated_lint", + ) { + let start = range.start; + + let mut iter = iter.by_ref().filter(|LintDeclSearchResult { ref token_kind, .. }| { + !matches!(token_kind, TokenKind::Whitespace | TokenKind::LineComment { .. }) + }); let (name, reason) = match_tokens!( iter, // !{ @@ -680,10 +925,16 @@ fn parse_deprecated_contents(contents: &str, lints: &mut Vec) { Ident Ident(name) Comma // "description" Literal{kind: LiteralKind::Str{..},..}(reason) - // } - CloseBrace ); - lints.push(DeprecatedLint::new(name, reason)); + + if let Some(LintDeclSearchResult { + token_kind: TokenKind::CloseBrace, + range, + .. + }) = iter.next() + { + lints.push(DeprecatedLint::new(name, reason, start..range.end)); + } } } @@ -693,8 +944,14 @@ fn parse_renamed_contents(contents: &str, lints: &mut Vec) { let mut iter = tokenize(line).map(|t| { let range = offset..offset + t.len; offset = range.end; - (t.kind, &line[range]) + + LintDeclSearchResult { + token_kind: t.kind, + content: &line[range.clone()], + range, + } }); + let (old_name, new_name) = match_tokens!( iter, // ("old_name", @@ -844,10 +1101,25 @@ mod tests { "#; let mut result = Vec::new(); parse_contents(CONTENTS, "module_name", &mut result); + for r in &mut result { + r.declaration_range = Range::default(); + } let expected = vec![ - Lint::new("ptr_arg", "style", "\"really long text\"", "module_name"), - Lint::new("doc_markdown", "pedantic", "\"single line\"", "module_name"), + Lint::new( + "ptr_arg", + "style", + "\"really long text\"", + "module_name", + Range::default(), + ), + Lint::new( + "doc_markdown", + "pedantic", + "\"single line\"", + "module_name", + Range::default(), + ), ]; assert_eq!(expected, result); } @@ -865,10 +1137,14 @@ mod tests { let mut result = Vec::new(); parse_deprecated_contents(DEPRECATED_CONTENTS, &mut result); + for r in &mut result { + r.declaration_range = Range::default(); + } let expected = vec![DeprecatedLint::new( "should_assert_eq", "\"`assert!()` will be more flexible with RFC 2011\"", + Range::default(), )]; assert_eq!(expected, result); } @@ -876,15 +1152,34 @@ mod tests { #[test] fn test_usable_lints() { let lints = vec![ - Lint::new("should_assert_eq2", "Not Deprecated", "\"abc\"", "module_name"), - Lint::new("should_assert_eq2", "internal", "\"abc\"", "module_name"), - Lint::new("should_assert_eq2", "internal_style", "\"abc\"", "module_name"), + Lint::new( + "should_assert_eq2", + "Not Deprecated", + "\"abc\"", + "module_name", + Range::default(), + ), + Lint::new( + "should_assert_eq2", + "internal", + "\"abc\"", + "module_name", + Range::default(), + ), + Lint::new( + "should_assert_eq2", + "internal_style", + "\"abc\"", + "module_name", + Range::default(), + ), ]; let expected = vec![Lint::new( "should_assert_eq2", "Not Deprecated", "\"abc\"", "module_name", + Range::default(), )]; assert_eq!(expected, Lint::usable_lints(&lints)); } @@ -892,21 +1187,33 @@ mod tests { #[test] fn test_by_lint_group() { let lints = vec![ - Lint::new("should_assert_eq", "group1", "\"abc\"", "module_name"), - Lint::new("should_assert_eq2", "group2", "\"abc\"", "module_name"), - Lint::new("incorrect_match", "group1", "\"abc\"", "module_name"), + Lint::new("should_assert_eq", "group1", "\"abc\"", "module_name", Range::default()), + Lint::new( + "should_assert_eq2", + "group2", + "\"abc\"", + "module_name", + Range::default(), + ), + Lint::new("incorrect_match", "group1", "\"abc\"", "module_name", Range::default()), ]; let mut expected: HashMap> = HashMap::new(); expected.insert( "group1".to_string(), vec![ - Lint::new("should_assert_eq", "group1", "\"abc\"", "module_name"), - Lint::new("incorrect_match", "group1", "\"abc\"", "module_name"), + Lint::new("should_assert_eq", "group1", "\"abc\"", "module_name", Range::default()), + Lint::new("incorrect_match", "group1", "\"abc\"", "module_name", Range::default()), ], ); expected.insert( "group2".to_string(), - vec![Lint::new("should_assert_eq2", "group2", "\"abc\"", "module_name")], + vec![Lint::new( + "should_assert_eq2", + "group2", + "\"abc\"", + "module_name", + Range::default(), + )], ); assert_eq!(expected, Lint::by_lint_group(lints.into_iter())); } @@ -914,8 +1221,12 @@ mod tests { #[test] fn test_gen_deprecated() { let lints = vec![ - DeprecatedLint::new("should_assert_eq", "\"has been superseded by should_assert_eq2\""), - DeprecatedLint::new("another_deprecated", "\"will be removed\""), + DeprecatedLint::new( + "should_assert_eq", + "\"has been superseded by should_assert_eq2\"", + Range::default(), + ), + DeprecatedLint::new("another_deprecated", "\"will be removed\"", Range::default()), ]; let expected = GENERATED_FILE_COMMENT.to_string() @@ -940,9 +1251,9 @@ mod tests { #[test] fn test_gen_lint_group_list() { let lints = vec![ - Lint::new("abc", "group1", "\"abc\"", "module_name"), - Lint::new("should_assert_eq", "group1", "\"abc\"", "module_name"), - Lint::new("internal", "internal_style", "\"abc\"", "module_name"), + Lint::new("abc", "group1", "\"abc\"", "module_name", Range::default()), + Lint::new("should_assert_eq", "group1", "\"abc\"", "module_name", Range::default()), + Lint::new("internal", "internal_style", "\"abc\"", "module_name", Range::default()), ]; let expected = GENERATED_FILE_COMMENT.to_string() + &[ diff --git a/clippy_lints/src/deprecated_lints.rs b/clippy_lints/src/deprecated_lints.rs index 5d5ea0f49c8..d7a4b6f5c88 100644 --- a/clippy_lints/src/deprecated_lints.rs +++ b/clippy_lints/src/deprecated_lints.rs @@ -1,16 +1,22 @@ -// NOTE: if you add a deprecated lint in this file, please add a corresponding test in -// tests/ui/deprecated.rs +// NOTE: Entries should be created with `cargo dev deprecate` /// This struct fakes the `Lint` declaration that is usually created by `declare_lint!`. This /// enables the simple extraction of the metadata without changing the current deprecation /// declaration. -pub struct ClippyDeprecatedLint; +pub struct ClippyDeprecatedLint { + #[cfg(feature = "internal")] + #[allow(dead_code)] + desc: &'static str, +} macro_rules! declare_deprecated_lint { - { $(#[$attr:meta])* pub $name: ident, $_reason: expr} => { + { $(#[$attr:meta])* pub $name: ident, $reason: literal} => { $(#[$attr])* #[allow(dead_code)] - pub static $name: ClippyDeprecatedLint = ClippyDeprecatedLint {}; + pub static $name: ClippyDeprecatedLint = ClippyDeprecatedLint { + #[cfg(feature = "internal")] + desc: $reason + }; } } diff --git a/clippy_lints/src/lib.register_internal.rs b/clippy_lints/src/lib.register_internal.rs index 4778f4fdfa7..be63646a12f 100644 --- a/clippy_lints/src/lib.register_internal.rs +++ b/clippy_lints/src/lib.register_internal.rs @@ -6,6 +6,7 @@ store.register_group(true, "clippy::internal", Some("clippy_internal"), vec![ LintId::of(utils::internal_lints::CLIPPY_LINTS_INTERNAL), LintId::of(utils::internal_lints::COLLAPSIBLE_SPAN_LINT_CALLS), LintId::of(utils::internal_lints::COMPILER_LINT_FUNCTIONS), + LintId::of(utils::internal_lints::DEFAULT_DEPRECATION_REASON), LintId::of(utils::internal_lints::DEFAULT_LINT), LintId::of(utils::internal_lints::IF_CHAIN_STYLE), LintId::of(utils::internal_lints::INTERNING_DEFINED_SYMBOL), diff --git a/clippy_lints/src/lib.register_lints.rs b/clippy_lints/src/lib.register_lints.rs index de22f50cf94..faa63b3036c 100644 --- a/clippy_lints/src/lib.register_lints.rs +++ b/clippy_lints/src/lib.register_lints.rs @@ -10,6 +10,8 @@ store.register_lints(&[ #[cfg(feature = "internal")] utils::internal_lints::COMPILER_LINT_FUNCTIONS, #[cfg(feature = "internal")] + utils::internal_lints::DEFAULT_DEPRECATION_REASON, + #[cfg(feature = "internal")] utils::internal_lints::DEFAULT_LINT, #[cfg(feature = "internal")] utils::internal_lints::IF_CHAIN_STYLE, diff --git a/clippy_lints/src/utils/internal_lints.rs b/clippy_lints/src/utils/internal_lints.rs index b885e5132f1..c5380662566 100644 --- a/clippy_lints/src/utils/internal_lints.rs +++ b/clippy_lints/src/utils/internal_lints.rs @@ -1,3 +1,4 @@ +use crate::utils::internal_lints::metadata_collector::is_deprecated_lint; use clippy_utils::consts::{constant_simple, Constant}; use clippy_utils::diagnostics::{span_lint, span_lint_and_help, span_lint_and_sugg, span_lint_and_then}; use clippy_utils::macros::root_macro_call_first_node; @@ -338,6 +339,47 @@ declare_clippy_lint! { "checking if all necessary steps were taken when adding a MSRV to a lint" } +declare_clippy_lint! { + /// ### What it does + /// Checks for cases of an auto-generated deprecated lint without an updated reason, + /// i.e. `"default deprecation note"`. + /// + /// ### Why is this bad? + /// Indicates that the documentation is incomplete. + /// + /// ### Example + /// Bad: + /// ```rust,ignore + /// declare_deprecated_lint! { + /// /// ### What it does + /// /// Nothing. This lint has been deprecated. + /// /// + /// /// ### Deprecation reason + /// /// TODO + /// #[clippy::version = "1.63.0"] + /// pub COOL_LINT, + /// "default deprecation note" + /// } + /// ``` + /// + /// Good: + /// ```rust,ignore + /// declare_deprecated_lint! { + /// /// ### What it does + /// /// Nothing. This lint has been deprecated. + /// /// + /// /// ### Deprecation reason + /// /// This lint has been replaced by `cooler_lint` + /// #[clippy::version = "1.63.0"] + /// pub COOL_LINT, + /// "this lint has been replaced by `cooler_lint`" + /// } + /// ``` + pub DEFAULT_DEPRECATION_REASON, + internal, + "found 'default deprecation note' in a deprecated lint declaration" +} + declare_lint_pass!(ClippyLintsInternal => [CLIPPY_LINTS_INTERNAL]); impl EarlyLintPass for ClippyLintsInternal { @@ -375,42 +417,67 @@ pub struct LintWithoutLintPass { registered_lints: FxHashSet, } -impl_lint_pass!(LintWithoutLintPass => [DEFAULT_LINT, LINT_WITHOUT_LINT_PASS, INVALID_CLIPPY_VERSION_ATTRIBUTE, MISSING_CLIPPY_VERSION_ATTRIBUTE]); +impl_lint_pass!(LintWithoutLintPass => [DEFAULT_LINT, LINT_WITHOUT_LINT_PASS, INVALID_CLIPPY_VERSION_ATTRIBUTE, MISSING_CLIPPY_VERSION_ATTRIBUTE, DEFAULT_DEPRECATION_REASON]); impl<'tcx> LateLintPass<'tcx> for LintWithoutLintPass { fn check_item(&mut self, cx: &LateContext<'tcx>, item: &'tcx Item<'_>) { - if is_lint_allowed(cx, DEFAULT_LINT, item.hir_id()) { + if is_lint_allowed(cx, DEFAULT_LINT, item.hir_id()) + || is_lint_allowed(cx, DEFAULT_DEPRECATION_REASON, item.hir_id()) + { return; } if let hir::ItemKind::Static(ty, Mutability::Not, body_id) = item.kind { - if is_lint_ref_type(cx, ty) { + let is_lint_ref_ty = is_lint_ref_type(cx, ty); + if is_deprecated_lint(cx, ty) || is_lint_ref_ty { check_invalid_clippy_version_attribute(cx, item); let expr = &cx.tcx.hir().body(body_id).value; - if_chain! { - if let ExprKind::AddrOf(_, _, inner_exp) = expr.kind; - if let ExprKind::Struct(_, fields, _) = inner_exp.kind; - let field = fields - .iter() - .find(|f| f.ident.as_str() == "desc") - .expect("lints must have a description field"); - if let ExprKind::Lit(Spanned { - node: LitKind::Str(ref sym, _), - .. - }) = field.expr.kind; - if sym.as_str() == "default lint description"; - - then { + let fields; + if is_lint_ref_ty { + if let ExprKind::AddrOf(_, _, inner_exp) = expr.kind + && let ExprKind::Struct(_, struct_fields, _) = inner_exp.kind { + fields = struct_fields; + } else { + return; + } + } else if let ExprKind::Struct(_, struct_fields, _) = expr.kind { + fields = struct_fields; + } else { + return; + } + + let field = fields + .iter() + .find(|f| f.ident.as_str() == "desc") + .expect("lints must have a description field"); + + if let ExprKind::Lit(Spanned { + node: LitKind::Str(ref sym, _), + .. + }) = field.expr.kind + { + let sym_str = sym.as_str(); + if is_lint_ref_ty { + if sym_str == "default lint description" { + span_lint( + cx, + DEFAULT_LINT, + item.span, + &format!("the lint `{}` has the default lint description", item.ident.name), + ); + } + + self.declared_lints.insert(item.ident.name, item.span); + } else if sym_str == "default deprecation note" { span_lint( cx, - DEFAULT_LINT, + DEFAULT_DEPRECATION_REASON, item.span, - &format!("the lint `{}` has the default lint description", item.ident.name), + &format!("the lint `{}` has the default deprecation reason", item.ident.name), ); } } - self.declared_lints.insert(item.ident.name, item.span); } } else if let Some(macro_call) = root_macro_call_first_node(cx, item) { if !matches!( diff --git a/clippy_lints/src/utils/internal_lints/metadata_collector.rs b/clippy_lints/src/utils/internal_lints/metadata_collector.rs index 99e9e3275ab..025ad87f72d 100644 --- a/clippy_lints/src/utils/internal_lints/metadata_collector.rs +++ b/clippy_lints/src/utils/internal_lints/metadata_collector.rs @@ -842,7 +842,7 @@ fn get_lint_level_from_group(lint_group: &str) -> Option<&'static str> { .find_map(|(group_name, group_level)| (*group_name == lint_group).then(|| *group_level)) } -fn is_deprecated_lint(cx: &LateContext<'_>, ty: &hir::Ty<'_>) -> bool { +pub(super) fn is_deprecated_lint(cx: &LateContext<'_>, ty: &hir::Ty<'_>) -> bool { if let hir::TyKind::Path(ref path) = ty.kind { if let hir::def::Res::Def(DefKind::Struct, def_id) = cx.qpath_res(path, ty.hir_id) { return match_def_path(cx, def_id, &DEPRECATED_LINT_TYPE); -- cgit 1.4.1-3-g733a5 From ebf77f6d7ecfb2cc60dfb39116d889af76d932cf Mon Sep 17 00:00:00 2001 From: Serial <69764315+Serial-ATA@users.noreply.github.com> Date: Thu, 23 Jun 2022 10:37:00 -0400 Subject: Fix ICE when deprecating lints in directories --- clippy_dev/src/update_lints.rs | 72 ++++++++++++++++++++++-------------------- 1 file changed, 37 insertions(+), 35 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/update_lints.rs b/clippy_dev/src/update_lints.rs index 31deb499b2e..115f5f0064f 100644 --- a/clippy_dev/src/update_lints.rs +++ b/clippy_dev/src/update_lints.rs @@ -363,12 +363,12 @@ pub fn deprecate(name: &str, reason: Option<&String>) { let name_upper = name.to_uppercase(); let (mut lints, deprecated_lints, renamed_lints) = gather_all(); - let Some(lint) = lints.iter().find(|l| l.name == name_lower) else { panic!("failed to find lint `{}`", name) }; + let Some(lint) = lints.iter().find(|l| l.name == name_lower) else { eprintln!("error: failed to find lint `{}`", name); return; }; let mod_path = { let mut mod_path = PathBuf::from(format!("clippy_lints/src/{}", lint.module)); if mod_path.is_dir() { - mod_path = mod_path.join(name); + mod_path = mod_path.join("mod"); } mod_path.set_extension("rs"); @@ -422,7 +422,7 @@ fn remove_lint_declaration(name: &str, path: &Path, lints: &mut Vec) -> io let mut lint_name_end = impl_lint_pass_start + (lint_name_pos + lint_name_upper.len()); for c in content[lint_name_end..impl_lint_pass_end].chars() { // Remove trailing whitespace - if c.is_whitespace() { + if c == ',' || c.is_whitespace() { lint_name_end += 1; } else { break; @@ -440,39 +440,41 @@ fn remove_lint_declaration(name: &str, path: &Path, lints: &mut Vec) -> io fs::remove_file(path)?; } else { // We can't delete the entire file, just remove the declaration - if lint.module != name { - let mut mod_decl_path = path.to_path_buf(); - if mod_decl_path.is_dir() { - mod_decl_path = Path::new("clippy_lints/src").join(&lint.module).join("mod.rs"); - } - - let mut content = fs::read_to_string(&mod_decl_path) - .unwrap_or_else(|_| panic!("failed to read `{}`", path.to_string_lossy())); - - eprintln!( - "warn: you will have to manually remove any code related to `{}` from `{}`", - name, - &mod_decl_path.to_string_lossy() - ); - - assert!( - content[lint.declaration_range.clone()].contains(&name.to_uppercase()), - "error: `{}` does not contain lint `{}`'s declaration", - mod_decl_path.display(), - lint.name - ); - - // Remove lint declaration (declare_clippy_lint!) - content.replace_range(lint.declaration_range.clone(), ""); - - // Remove the module declaration (mod xyz;) - let mod_decl = format!("\nmod {};", name); - content = content.replacen(&mod_decl, "", 1); - - remove_impl_lint_pass(&lint.name.to_uppercase(), &mut content); - fs::write(mod_decl_path, content) - .unwrap_or_else(|_| panic!("failed to write to `{}`", path.to_string_lossy())); + + if let Some(Some("mod.rs")) = path.file_name().map(OsStr::to_str) { + // Remove clippy_lints/src/some_mod/some_lint.rs + let mut lint_mod_path = path.to_path_buf(); + lint_mod_path.set_file_name(name); + lint_mod_path.set_extension("rs"); + + fs::remove_file(lint_mod_path).ok(); } + + let mut content = + fs::read_to_string(&path).unwrap_or_else(|_| panic!("failed to read `{}`", path.to_string_lossy())); + + eprintln!( + "warn: you will have to manually remove any code related to `{}` from `{}`", + name, + path.display() + ); + + assert!( + content[lint.declaration_range.clone()].contains(&name.to_uppercase()), + "error: `{}` does not contain lint `{}`'s declaration", + path.display(), + lint.name + ); + + // Remove lint declaration (declare_clippy_lint!) + content.replace_range(lint.declaration_range.clone(), ""); + + // Remove the module declaration (mod xyz;) + let mod_decl = format!("\nmod {};", name); + content = content.replacen(&mod_decl, "", 1); + + remove_impl_lint_pass(&lint.name.to_uppercase(), &mut content); + fs::write(path, content).unwrap_or_else(|_| panic!("failed to write to `{}`", path.to_string_lossy())); } remove_test_assets(name); -- cgit 1.4.1-3-g733a5 From d42af68e0362ef7a43a9a3d0e216a7d83b291e20 Mon Sep 17 00:00:00 2001 From: Serial <69764315+Serial-ATA@users.noreply.github.com> Date: Thu, 23 Jun 2022 11:50:11 -0400 Subject: Add `cargo dev dogfood` --- clippy_dev/src/dogfood.rs | 33 +++++++++++++++++++++++++++++++++ clippy_dev/src/lib.rs | 1 + clippy_dev/src/main.rs | 21 ++++++++++++++++++++- tests/dogfood.rs | 14 ++++++++++---- 4 files changed, 64 insertions(+), 5 deletions(-) create mode 100644 clippy_dev/src/dogfood.rs (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/dogfood.rs b/clippy_dev/src/dogfood.rs new file mode 100644 index 00000000000..b69e9f649ec --- /dev/null +++ b/clippy_dev/src/dogfood.rs @@ -0,0 +1,33 @@ +use crate::clippy_project_root; +use std::process::Command; + +/// # Panics +/// +/// Panics if unable to run the dogfood test +pub fn dogfood(fix: bool, allow_dirty: bool, allow_staged: bool) { + let mut cmd = Command::new("cargo"); + + cmd.current_dir(clippy_project_root()) + .args(["test", "--test", "dogfood"]) + .args(["--features", "internal"]) + .args(["--", "dogfood_clippy"]); + + let mut dogfood_args = Vec::new(); + if fix { + dogfood_args.push("--fix"); + } + + if allow_dirty { + dogfood_args.push("--allow-dirty"); + } + + if allow_staged { + dogfood_args.push("--allow-staged"); + } + + cmd.env("__CLIPPY_DOGFOOD_ARGS", dogfood_args.join(" ")); + + let output = cmd.output().expect("failed to run command"); + + println!("{}", String::from_utf8_lossy(&output.stdout)); +} diff --git a/clippy_dev/src/lib.rs b/clippy_dev/src/lib.rs index 81e807cf10c..82574a8e64b 100644 --- a/clippy_dev/src/lib.rs +++ b/clippy_dev/src/lib.rs @@ -11,6 +11,7 @@ extern crate rustc_lexer; use std::path::PathBuf; pub mod bless; +pub mod dogfood; pub mod fmt; pub mod lint; pub mod new_lint; diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index 2c27a0bcaf9..41eda842f95 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -3,8 +3,9 @@ #![warn(rust_2018_idioms, unused_lifetimes)] use clap::{Arg, ArgAction, ArgMatches, Command, PossibleValue}; -use clippy_dev::{bless, fmt, lint, new_lint, serve, setup, update_lints}; +use clippy_dev::{bless, dogfood, fmt, lint, new_lint, serve, setup, update_lints}; use indoc::indoc; + fn main() { let matches = get_clap_config(); @@ -12,6 +13,13 @@ fn main() { Some(("bless", matches)) => { bless::bless(matches.contains_id("ignore-timestamp")); }, + Some(("dogfood", matches)) => { + dogfood::dogfood( + matches.contains_id("fix"), + matches.contains_id("allow-dirty"), + matches.contains_id("allow-staged"), + ); + }, Some(("fmt", matches)) => { fmt::run(matches.contains_id("check"), matches.contains_id("verbose")); }, @@ -98,6 +106,17 @@ fn get_clap_config() -> ArgMatches { .long("ignore-timestamp") .help("Include files updated before clippy was built"), ), + Command::new("dogfood").about("Runs the dogfood test").args([ + Arg::new("fix").long("fix").help("Apply the suggestions when possible"), + Arg::new("allow-dirty") + .long("allow-dirty") + .help("Fix code even if the working directory has changes") + .requires("fix"), + Arg::new("allow-staged") + .long("allow-staged") + .help("Fix code even if the working directory has staged changes") + .requires("fix"), + ]), Command::new("fmt") .about("Run rustfmt on all projects and tests") .args([ diff --git a/tests/dogfood.rs b/tests/dogfood.rs index fffc5360342..5697e8680cd 100644 --- a/tests/dogfood.rs +++ b/tests/dogfood.rs @@ -74,10 +74,16 @@ fn run_clippy_for_package(project: &str, args: &[&str]) { .env("CARGO_INCREMENTAL", "0") .arg("clippy") .arg("--all-targets") - .arg("--all-features") - .arg("--") - .args(args) - .arg("-Cdebuginfo=0"); // disable debuginfo to generate less data in the target dir + .arg("--all-features"); + + if let Ok(dogfood_args) = std::env::var("__CLIPPY_DOGFOOD_ARGS") { + for arg in dogfood_args.split_whitespace() { + command.arg(arg); + } + } + + command.arg("--").args(args); + command.arg("-Cdebuginfo=0"); // disable debuginfo to generate less data in the target dir if cfg!(feature = "internal") { // internal lints only exist if we build with the internal feature -- cgit 1.4.1-3-g733a5 From 5e2a2d3ac993cc6b89e561e69b4571d95d0f7627 Mon Sep 17 00:00:00 2001 From: Jason Newcomb Date: Tue, 14 Jun 2022 11:44:43 -0400 Subject: Fix dogfood --- clippy_dev/src/update_lints.rs | 2 +- clippy_lints/src/dereference.rs | 26 ++++++++++++------------ clippy_lints/src/matches/match_same_arms.rs | 2 +- clippy_lints/src/matches/match_single_binding.rs | 4 ++-- 4 files changed, 17 insertions(+), 17 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/update_lints.rs b/clippy_dev/src/update_lints.rs index 115f5f0064f..2e0659f42d7 100644 --- a/clippy_dev/src/update_lints.rs +++ b/clippy_dev/src/update_lints.rs @@ -413,7 +413,7 @@ fn remove_lint_declaration(name: &str, path: &Path, lints: &mut Vec) -> io .find("declare_lint_pass!") .unwrap_or_else(|| panic!("failed to find `impl_lint_pass`")) }); - let mut impl_lint_pass_end = (&content[impl_lint_pass_start..]) + let mut impl_lint_pass_end = content[impl_lint_pass_start..] .find(']') .expect("failed to find `impl_lint_pass` terminator"); diff --git a/clippy_lints/src/dereference.rs b/clippy_lints/src/dereference.rs index e80ee6af650..59dcc1ebf19 100644 --- a/clippy_lints/src/dereference.rs +++ b/clippy_lints/src/dereference.rs @@ -911,7 +911,18 @@ fn param_auto_deref_stability(ty: Ty<'_>, precedence: i8) -> Position { ty = ref_ty; continue; }, - ty::Bool + ty::Infer(_) + | ty::Error(_) + | ty::Param(_) + | ty::Bound(..) + | ty::Opaque(..) + | ty::Placeholder(_) + | ty::Dynamic(..) => Position::ReborrowStable(precedence), + ty::Adt(..) if ty.has_placeholders() || ty.has_param_types_or_consts() => { + Position::ReborrowStable(precedence) + }, + ty::Adt(..) + | ty::Bool | ty::Char | ty::Int(_) | ty::Uint(_) @@ -929,17 +940,6 @@ fn param_auto_deref_stability(ty: Ty<'_>, precedence: i8) -> Position { | ty::Never | ty::Tuple(_) | ty::Projection(_) => Position::DerefStable(precedence), - ty::Infer(_) - | ty::Error(_) - | ty::Param(_) - | ty::Bound(..) - | ty::Opaque(..) - | ty::Placeholder(_) - | ty::Dynamic(..) => Position::ReborrowStable(precedence), - ty::Adt(..) if ty.has_placeholders() || ty.has_param_types_or_consts() => { - Position::ReborrowStable(precedence) - }, - ty::Adt(..) => Position::DerefStable(precedence), }; } } @@ -952,7 +952,7 @@ fn ty_contains_field(ty: Ty<'_>, name: Symbol) -> bool { } } -#[expect(clippy::needless_pass_by_value)] +#[expect(clippy::needless_pass_by_value, clippy::too_many_lines)] fn report<'tcx>(cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>, state: State, data: StateData) { match state { State::DerefMethod { diff --git a/clippy_lints/src/matches/match_same_arms.rs b/clippy_lints/src/matches/match_same_arms.rs index 16fefea5520..15513de7d86 100644 --- a/clippy_lints/src/matches/match_same_arms.rs +++ b/clippy_lints/src/matches/match_same_arms.rs @@ -285,7 +285,7 @@ impl<'a> NormalizedPat<'a> { // TODO: Handle negative integers. They're currently treated as a wild match. ExprKind::Lit(lit) => match lit.node { LitKind::Str(sym, _) => Self::LitStr(sym), - LitKind::ByteStr(ref bytes) => Self::LitBytes(&**bytes), + LitKind::ByteStr(ref bytes) => Self::LitBytes(bytes), LitKind::Byte(val) => Self::LitInt(val.into()), LitKind::Char(val) => Self::LitInt(val.into()), LitKind::Int(val, _) => Self::LitInt(val), diff --git a/clippy_lints/src/matches/match_single_binding.rs b/clippy_lints/src/matches/match_single_binding.rs index 9df2db45dcf..5ae4a65acaf 100644 --- a/clippy_lints/src/matches/match_single_binding.rs +++ b/clippy_lints/src/matches/match_single_binding.rs @@ -55,7 +55,7 @@ pub(crate) fn check<'a>(cx: &LateContext<'a>, ex: &Expr<'a>, arms: &[Arm<'_>], e cx, (ex, expr), (bind_names, matched_vars), - &*snippet_body, + &snippet_body, &mut applicability, Some(span), ); @@ -88,7 +88,7 @@ pub(crate) fn check<'a>(cx: &LateContext<'a>, ex: &Expr<'a>, arms: &[Arm<'_>], e cx, (ex, expr), (bind_names, matched_vars), - &*snippet_body, + &snippet_body, &mut applicability, None, ); -- cgit 1.4.1-3-g733a5 From b7230d4f44e974c6639980a2e44e8d7523b6c90c Mon Sep 17 00:00:00 2001 From: Josh Triplett Date: Wed, 6 Jul 2022 00:52:53 -0700 Subject: Dogfood fixes to use `bool::then_some` --- clippy_dev/src/update_lints.rs | 2 +- clippy_lints/src/dereference.rs | 4 +++- clippy_lints/src/entry.rs | 2 +- clippy_lints/src/inherent_impl.rs | 2 +- clippy_lints/src/manual_non_exhaustive.rs | 2 +- clippy_lints/src/matches/manual_map.rs | 2 +- clippy_lints/src/matches/match_same_arms.rs | 4 ++-- clippy_lints/src/matches/mod.rs | 4 ++-- clippy_lints/src/methods/manual_str_repeat.rs | 2 +- clippy_lints/src/option_if_let_else.rs | 2 +- clippy_lints/src/ptr.rs | 2 +- clippy_lints/src/swap_ptr_to_ref.rs | 2 +- clippy_lints/src/utils/internal_lints/metadata_collector.rs | 2 +- clippy_lints/src/write.rs | 2 +- clippy_utils/src/lib.rs | 2 +- clippy_utils/src/source.rs | 2 +- 16 files changed, 20 insertions(+), 18 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/update_lints.rs b/clippy_dev/src/update_lints.rs index 2e0659f42d7..c089f4d8ce4 100644 --- a/clippy_dev/src/update_lints.rs +++ b/clippy_dev/src/update_lints.rs @@ -553,7 +553,7 @@ fn replace_ident_like(contents: &str, replacements: &[(&str, &str)]) -> Option usize { diff --git a/clippy_lints/src/dereference.rs b/clippy_lints/src/dereference.rs index 59dcc1ebf19..6a35044d459 100644 --- a/clippy_lints/src/dereference.rs +++ b/clippy_lints/src/dereference.rs @@ -730,7 +730,9 @@ fn walk_parents<'tcx>(cx: &LateContext<'tcx>, e: &'tcx Expr<'_>) -> (Position, & Position::DerefStable(precedence) }) }, - ExprKind::Call(func, _) if func.hir_id == child_id => (child_id == e.hir_id).then(|| Position::Callee), + ExprKind::Call(func, _) if func.hir_id == child_id => { + (child_id == e.hir_id).then_some(Position::Callee) + }, ExprKind::Call(func, args) => args .iter() .position(|arg| arg.hir_id == child_id) diff --git a/clippy_lints/src/entry.rs b/clippy_lints/src/entry.rs index 27743a0ebec..4e3ae4c9614 100644 --- a/clippy_lints/src/entry.rs +++ b/clippy_lints/src/entry.rs @@ -650,7 +650,7 @@ fn find_insert_calls<'tcx>( let allow_insert_closure = s.allow_insert_closure; let is_single_insert = s.is_single_insert; let edits = s.edits; - s.can_use_entry.then(|| InsertSearchResults { + s.can_use_entry.then_some(InsertSearchResults { edits, allow_insert_closure, is_single_insert, diff --git a/clippy_lints/src/inherent_impl.rs b/clippy_lints/src/inherent_impl.rs index 6a031a627df..c5abcc46254 100644 --- a/clippy_lints/src/inherent_impl.rs +++ b/clippy_lints/src/inherent_impl.rs @@ -127,7 +127,7 @@ fn get_impl_span(cx: &LateContext<'_>, id: LocalDefId) -> Option { (!span.from_expansion() && impl_item.generics.params.is_empty() && !is_lint_allowed(cx, MULTIPLE_INHERENT_IMPL, id)) - .then(|| span) + .then_some(span) } else { None } diff --git a/clippy_lints/src/manual_non_exhaustive.rs b/clippy_lints/src/manual_non_exhaustive.rs index 4278e98dc91..2b04475c7a9 100644 --- a/clippy_lints/src/manual_non_exhaustive.rs +++ b/clippy_lints/src/manual_non_exhaustive.rs @@ -161,7 +161,7 @@ impl<'tcx> LateLintPass<'tcx> for ManualNonExhaustiveEnum { (matches!(v.data, hir::VariantData::Unit(_)) && v.ident.as_str().starts_with('_') && is_doc_hidden(cx.tcx.hir().attrs(v.id))) - .then(|| (id, v.span)) + .then_some((id, v.span)) }); if let Some((id, span)) = iter.next() && iter.next().is_none() diff --git a/clippy_lints/src/matches/manual_map.rs b/clippy_lints/src/matches/manual_map.rs index 542905a2d76..8f98b43b9e5 100644 --- a/clippy_lints/src/matches/manual_map.rs +++ b/clippy_lints/src/matches/manual_map.rs @@ -105,7 +105,7 @@ fn check<'tcx>( // Determine which binding mode to use. let explicit_ref = some_pat.contains_explicit_ref_binding(); - let binding_ref = explicit_ref.or_else(|| (ty_ref_count != pat_ref_count).then(|| ty_mutability)); + let binding_ref = explicit_ref.or_else(|| (ty_ref_count != pat_ref_count).then_some(ty_mutability)); let as_ref_str = match binding_ref { Some(Mutability::Mut) => ".as_mut()", diff --git a/clippy_lints/src/matches/match_same_arms.rs b/clippy_lints/src/matches/match_same_arms.rs index 15513de7d86..61d28b15066 100644 --- a/clippy_lints/src/matches/match_same_arms.rs +++ b/clippy_lints/src/matches/match_same_arms.rs @@ -38,7 +38,7 @@ pub(super) fn check<'tcx>(cx: &LateContext<'tcx>, arms: &'tcx [Arm<'_>]) { normalized_pats[i + 1..] .iter() .enumerate() - .find_map(|(j, other)| pat.has_overlapping_values(other).then(|| i + 1 + j)) + .find_map(|(j, other)| pat.has_overlapping_values(other).then_some(i + 1 + j)) .unwrap_or(normalized_pats.len()) }) .collect(); @@ -55,7 +55,7 @@ pub(super) fn check<'tcx>(cx: &LateContext<'tcx>, arms: &'tcx [Arm<'_>]) { .zip(forwards_blocking_idxs[..i].iter().copied().rev()) .skip_while(|&(_, forward_block)| forward_block > i) .find_map(|((j, other), forward_block)| { - (forward_block == i || pat.has_overlapping_values(other)).then(|| j) + (forward_block == i || pat.has_overlapping_values(other)).then_some(j) }) .unwrap_or(0) }) diff --git a/clippy_lints/src/matches/mod.rs b/clippy_lints/src/matches/mod.rs index b2a873ef582..5c996bc33f3 100644 --- a/clippy_lints/src/matches/mod.rs +++ b/clippy_lints/src/matches/mod.rs @@ -1061,7 +1061,7 @@ fn contains_cfg_arm(cx: &LateContext<'_>, e: &Expr<'_>, scrutinee: &Expr<'_>, ar let start = scrutinee_span.hi(); let mut arm_spans = arms.iter().map(|arm| { let data = arm.span.data(); - (data.ctxt == SyntaxContext::root()).then(|| (data.lo, data.hi)) + (data.ctxt == SyntaxContext::root()).then_some((data.lo, data.hi)) }); let end = e.span.hi(); @@ -1095,7 +1095,7 @@ fn contains_cfg_arm(cx: &LateContext<'_>, e: &Expr<'_>, scrutinee: &Expr<'_>, ar parent: None, } .span(); - (!span_contains_cfg(cx, span)).then(|| next_start).ok_or(()) + (!span_contains_cfg(cx, span)).then_some(next_start).ok_or(()) }); match found { Ok(start) => { diff --git a/clippy_lints/src/methods/manual_str_repeat.rs b/clippy_lints/src/methods/manual_str_repeat.rs index 68a75667914..46d2fc493f8 100644 --- a/clippy_lints/src/methods/manual_str_repeat.rs +++ b/clippy_lints/src/methods/manual_str_repeat.rs @@ -43,7 +43,7 @@ fn parse_repeat_arg(cx: &LateContext<'_>, e: &Expr<'_>) -> Option { Some(RepeatKind::String) } else { let ty = ty.peel_refs(); - (ty.is_str() || is_type_diagnostic_item(cx, ty, sym::String)).then(|| RepeatKind::String) + (ty.is_str() || is_type_diagnostic_item(cx, ty, sym::String)).then_some(RepeatKind::String) } } } diff --git a/clippy_lints/src/option_if_let_else.rs b/clippy_lints/src/option_if_let_else.rs index ea5a8f0858b..44f153cffac 100644 --- a/clippy_lints/src/option_if_let_else.rs +++ b/clippy_lints/src/option_if_let_else.rs @@ -146,7 +146,7 @@ fn detect_option_if_let_else<'tcx>(cx: &LateContext<'tcx>, expr: &Expr<'tcx>) -> }); if let ExprKind::Path(QPath::Resolved(None, Path { res: Res::Local(local_id), .. })) = e.kind { match some_captures.get(local_id) - .or_else(|| (method_sugg == "map_or_else").then(|| ()).and_then(|_| none_captures.get(local_id))) + .or_else(|| (method_sugg == "map_or_else").then_some(()).and_then(|_| none_captures.get(local_id))) { Some(CaptureKind::Value | CaptureKind::Ref(Mutability::Mut)) => return None, Some(CaptureKind::Ref(Mutability::Not)) if as_mut => return None, diff --git a/clippy_lints/src/ptr.rs b/clippy_lints/src/ptr.rs index 25b73918c0a..8bacc6f6b32 100644 --- a/clippy_lints/src/ptr.rs +++ b/clippy_lints/src/ptr.rs @@ -501,7 +501,7 @@ fn check_mut_from_ref<'tcx>(cx: &LateContext<'tcx>, sig: &FnSig<'_>, body: Optio .iter() .filter_map(get_rptr_lm) .filter(|&(lt, _, _)| lt.name == out.name) - .map(|(_, mutability, span)| (mutability == Mutability::Not).then(|| span)) + .map(|(_, mutability, span)| (mutability == Mutability::Not).then_some(span)) .collect(); if let Some(args) = args && !args.is_empty() diff --git a/clippy_lints/src/swap_ptr_to_ref.rs b/clippy_lints/src/swap_ptr_to_ref.rs index 75d3b040c96..3cbbda80f3a 100644 --- a/clippy_lints/src/swap_ptr_to_ref.rs +++ b/clippy_lints/src/swap_ptr_to_ref.rs @@ -73,7 +73,7 @@ fn is_ptr_to_ref(cx: &LateContext<'_>, e: &Expr<'_>, ctxt: SyntaxContext) -> (bo && let ExprKind::Unary(UnOp::Deref, derefed_expr) = borrowed_expr.kind && cx.typeck_results().expr_ty(derefed_expr).is_unsafe_ptr() { - (true, (borrowed_expr.span.ctxt() == ctxt || derefed_expr.span.ctxt() == ctxt).then(|| derefed_expr.span)) + (true, (borrowed_expr.span.ctxt() == ctxt || derefed_expr.span.ctxt() == ctxt).then_some(derefed_expr.span)) } else { (false, None) } diff --git a/clippy_lints/src/utils/internal_lints/metadata_collector.rs b/clippy_lints/src/utils/internal_lints/metadata_collector.rs index 6518e0a6ea0..3010fc0223c 100644 --- a/clippy_lints/src/utils/internal_lints/metadata_collector.rs +++ b/clippy_lints/src/utils/internal_lints/metadata_collector.rs @@ -843,7 +843,7 @@ fn get_lint_group(cx: &LateContext<'_>, lint_id: LintId) -> Option { fn get_lint_level_from_group(lint_group: &str) -> Option<&'static str> { DEFAULT_LINT_LEVELS .iter() - .find_map(|(group_name, group_level)| (*group_name == lint_group).then(|| *group_level)) + .find_map(|(group_name, group_level)| (*group_name == lint_group).then_some(*group_level)) } pub(super) fn is_deprecated_lint(cx: &LateContext<'_>, ty: &hir::Ty<'_>) -> bool { diff --git a/clippy_lints/src/write.rs b/clippy_lints/src/write.rs index 67b2bc8c3f3..08b88947520 100644 --- a/clippy_lints/src/write.rs +++ b/clippy_lints/src/write.rs @@ -515,7 +515,7 @@ impl Write { args.push(arg, span); } - parser.errors.is_empty().then(move || args) + parser.errors.is_empty().then_some(args) } /// Checks the arguments of `print[ln]!` and `write[ln]!` calls. It will return a tuple of two diff --git a/clippy_utils/src/lib.rs b/clippy_utils/src/lib.rs index 9fa28e137f9..0e739303683 100644 --- a/clippy_utils/src/lib.rs +++ b/clippy_utils/src/lib.rs @@ -1016,7 +1016,7 @@ pub fn can_move_expr_to_closure<'tcx>(cx: &LateContext<'tcx>, expr: &'tcx Expr<' captures: HirIdMap::default(), }; v.visit_expr(expr); - v.allow_closure.then(|| v.captures) + v.allow_closure.then_some(v.captures) } /// Returns the method names and argument list of nested method call expressions that make up diff --git a/clippy_utils/src/source.rs b/clippy_utils/src/source.rs index f88a92fb11c..1197fe914de 100644 --- a/clippy_utils/src/source.rs +++ b/clippy_utils/src/source.rs @@ -353,7 +353,7 @@ pub fn snippet_with_context<'a>( /// span containing `m!(0)`. pub fn walk_span_to_context(span: Span, outer: SyntaxContext) -> Option { let outer_span = hygiene::walk_chain(span, outer); - (outer_span.ctxt() == outer).then(|| outer_span) + (outer_span.ctxt() == outer).then_some(outer_span) } /// Removes block comments from the given `Vec` of lines. -- cgit 1.4.1-3-g733a5 From 51cd5a866728539c1d1db81c437c474ffbef7ccf Mon Sep 17 00:00:00 2001 From: Serial <69764315+Serial-ATA@users.noreply.github.com> Date: Thu, 14 Jul 2022 15:58:38 -0400 Subject: Add `--type` flag to `dev new_lint` --- clippy_dev/src/main.rs | 9 +- clippy_dev/src/new_lint.rs | 294 +++++++++++++++++++++++++++++++++----- clippy_dev/src/update_lints.rs | 10 +- clippy_lints/src/cargo/mod.rs | 10 +- clippy_lints/src/matches/mod.rs | 20 +-- clippy_lints/src/operators/mod.rs | 12 +- 6 files changed, 295 insertions(+), 60 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index a29ba2d0c85..2008942d087 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -37,6 +37,7 @@ fn main() { matches.get_one::("pass"), matches.get_one::("name"), matches.get_one::("category"), + matches.get_one::("type"), matches.contains_id("msrv"), ) { Ok(_) => update_lints::update(update_lints::UpdateMode::Change), @@ -157,7 +158,8 @@ fn get_clap_config() -> ArgMatches { .help("Specify whether the lint runs during the early or late pass") .takes_value(true) .value_parser([PossibleValue::new("early"), PossibleValue::new("late")]) - .required(true), + .conflicts_with("type") + .required_unless_present("type"), Arg::new("name") .short('n') .long("name") @@ -183,6 +185,11 @@ fn get_clap_config() -> ArgMatches { PossibleValue::new("internal_warn"), ]) .takes_value(true), + Arg::new("type") + .long("type") + .help("What directory the lint belongs in") + .takes_value(true) + .required(false), Arg::new("msrv").long("msrv").help("Add MSRV config code to the lint"), ]), Command::new("setup") diff --git a/clippy_dev/src/new_lint.rs b/clippy_dev/src/new_lint.rs index 7d7e760ef44..af22cb89942 100644 --- a/clippy_dev/src/new_lint.rs +++ b/clippy_dev/src/new_lint.rs @@ -1,5 +1,5 @@ use crate::clippy_project_root; -use indoc::indoc; +use indoc::{indoc, writedoc}; use std::fmt::Write as _; use std::fs::{self, OpenOptions}; use std::io::prelude::*; @@ -10,6 +10,7 @@ struct LintData<'a> { pass: &'a str, name: &'a str, category: &'a str, + ty: Option<&'a str>, project_root: PathBuf, } @@ -38,25 +39,35 @@ pub fn create( pass: Option<&String>, lint_name: Option<&String>, category: Option<&String>, + ty: Option<&String>, msrv: bool, ) -> io::Result<()> { let lint = LintData { - pass: pass.expect("`pass` argument is validated by clap"), + pass: pass.map_or("", String::as_str), name: lint_name.expect("`name` argument is validated by clap"), category: category.expect("`category` argument is validated by clap"), + ty: ty.map(String::as_str), project_root: clippy_project_root(), }; create_lint(&lint, msrv).context("Unable to create lint implementation")?; create_test(&lint).context("Unable to create a test for the new lint")?; - add_lint(&lint, msrv).context("Unable to add lint to clippy_lints/src/lib.rs") + + if lint.ty.is_none() { + add_lint(&lint, msrv).context("Unable to add lint to clippy_lints/src/lib.rs")?; + } + + Ok(()) } fn create_lint(lint: &LintData<'_>, enable_msrv: bool) -> io::Result<()> { - let lint_contents = get_lint_file_contents(lint, enable_msrv); - - let lint_path = format!("clippy_lints/src/{}.rs", lint.name); - write_file(lint.project_root.join(&lint_path), lint_contents.as_bytes()) + if let Some(ty) = lint.ty { + generate_from_ty(lint, enable_msrv, ty) + } else { + let lint_contents = get_lint_file_contents(lint, enable_msrv); + let lint_path = format!("clippy_lints/src/{}.rs", lint.name); + write_file(lint.project_root.join(&lint_path), lint_contents.as_bytes()) + } } fn create_test(lint: &LintData<'_>) -> io::Result<()> { @@ -204,7 +215,6 @@ fn get_lint_file_contents(lint: &LintData<'_>, enable_msrv: bool) -> String { }, }; - let version = get_stabilization_version(); let lint_name = lint.name; let category = lint.category; let name_camel = to_camel_case(lint.name); @@ -238,32 +248,7 @@ fn get_lint_file_contents(lint: &LintData<'_>, enable_msrv: bool) -> String { ) }); - let _ = write!( - result, - indoc! {r#" - declare_clippy_lint! {{ - /// ### What it does - /// - /// ### Why is this bad? - /// - /// ### Example - /// ```rust - /// // example code where clippy issues a warning - /// ``` - /// Use instead: - /// ```rust - /// // example code which does not raise clippy warning - /// ``` - #[clippy::version = "{version}"] - pub {name_upper}, - {category}, - "default lint description" - }} - "#}, - version = version, - name_upper = name_upper, - category = category, - ); + let _ = write!(result, "{}", get_lint_declaration(&name_upper, category)); result.push_str(&if enable_msrv { format!( @@ -312,6 +297,247 @@ fn get_lint_file_contents(lint: &LintData<'_>, enable_msrv: bool) -> String { result } +fn get_lint_declaration(name_upper: &str, category: &str) -> String { + format!( + indoc! {r#" + declare_clippy_lint! {{ + /// ### What it does + /// + /// ### Why is this bad? + /// + /// ### Example + /// ```rust + /// // example code where clippy issues a warning + /// ``` + /// Use instead: + /// ```rust + /// // example code which does not raise clippy warning + /// ``` + #[clippy::version = "{version}"] + pub {name_upper}, + {category}, + "default lint description" + }} + "#}, + version = get_stabilization_version(), + name_upper = name_upper, + category = category, + ) +} + +fn generate_from_ty(lint: &LintData<'_>, enable_msrv: bool, ty: &str) -> io::Result<()> { + if ty == "cargo" { + assert_eq!( + lint.category, "cargo", + "Lints of type `cargo` must have the `cargo` category" + ); + } + + let ty_dir = lint.project_root.join(format!("clippy_lints/src/{}", ty)); + assert!( + ty_dir.exists() && ty_dir.is_dir(), + "Directory `{}` does not exist!", + ty_dir.display() + ); + + let lint_file_path = ty_dir.join(format!("{}.rs", lint.name)); + assert!( + !lint_file_path.exists(), + "File `{}` already exists", + lint_file_path.display() + ); + + let mod_file_path = ty_dir.join("mod.rs"); + let context_import = setup_mod_file(&mod_file_path, lint)?; + + let name_upper = lint.name.to_uppercase(); + let mut lint_file_contents = String::new(); + + if enable_msrv { + let _ = writedoc!( + lint_file_contents, + r#" + use clippy_utils::{{meets_msrv, msrvs}}; + use rustc_lint::{{{context_import}, LintContext}}; + use rustc_semver::RustcVersion; + + use super::{name_upper}; + + // TODO: Adjust the parameters as necessary + pub(super) fn check(cx: &{context_import}, msrv: Option) {{ + if !meets_msrv(msrv, todo!("Add a new entry in `clippy_utils/src/msrvs`")) {{ + return; + }} + todo!(); + }} + "#, + context_import = context_import, + name_upper = name_upper, + ); + } else { + let _ = writedoc!( + lint_file_contents, + r#" + use rustc_lint::{{{context_import}, LintContext}}; + + use super::{name_upper}; + + // TODO: Adjust the parameters as necessary + pub(super) fn check(cx: &{context_import}) {{ + todo!(); + }} + "#, + context_import = context_import, + name_upper = name_upper, + ); + } + + write_file(lint_file_path, lint_file_contents)?; + + Ok(()) +} + +#[allow(clippy::too_many_lines)] +fn setup_mod_file(path: &Path, lint: &LintData<'_>) -> io::Result<&'static str> { + use super::update_lints::{match_tokens, LintDeclSearchResult}; + use rustc_lexer::TokenKind; + + let lint_name_upper = lint.name.to_uppercase(); + + let mut file_contents = fs::read_to_string(path)?; + assert!( + !file_contents.contains(&lint_name_upper), + "Lint `{}` already defined in `{}`", + lint.name, + path.display() + ); + + let mut offset = 0usize; + let mut last_decl_curly_offset = None; + let mut lint_context = None; + + let mut iter = rustc_lexer::tokenize(&file_contents).map(|t| { + let range = offset..offset + t.len; + offset = range.end; + + LintDeclSearchResult { + token_kind: t.kind, + content: &file_contents[range.clone()], + range, + } + }); + + // Find both the last lint declaration (declare_clippy_lint!) and the lint pass impl + while let Some(LintDeclSearchResult { content, .. }) = iter.find(|result| result.token_kind == TokenKind::Ident) { + let mut iter = iter + .by_ref() + .filter(|t| !matches!(t.token_kind, TokenKind::Whitespace | TokenKind::LineComment { .. })); + + match content { + "declare_clippy_lint" => { + // matches `!{` + match_tokens!(iter, Bang OpenBrace); + if let Some(LintDeclSearchResult { range, .. }) = + iter.find(|result| result.token_kind == TokenKind::CloseBrace) + { + last_decl_curly_offset = Some(range.end); + } + }, + "impl" => { + let mut token = iter.next(); + match token { + // matches <'foo> + Some(LintDeclSearchResult { + token_kind: TokenKind::Lt, + .. + }) => { + match_tokens!(iter, Lifetime { .. } Gt); + token = iter.next(); + }, + None => break, + _ => {}, + } + + if let Some(LintDeclSearchResult { + token_kind: TokenKind::Ident, + content, + .. + }) = token + { + // Get the appropriate lint context struct + lint_context = match content { + "LateLintPass" => Some("LateContext"), + "EarlyLintPass" => Some("EarlyContext"), + _ => continue, + }; + } + }, + _ => {}, + } + } + + drop(iter); + + let last_decl_curly_offset = + last_decl_curly_offset.unwrap_or_else(|| panic!("No lint declarations found in `{}`", path.display())); + let lint_context = + lint_context.unwrap_or_else(|| panic!("No lint pass implementation found in `{}`", path.display())); + + // Add the lint declaration to `mod.rs` + file_contents.replace_range( + // Remove the trailing newline, which should always be present + last_decl_curly_offset..=last_decl_curly_offset, + &format!("\n\n{}", get_lint_declaration(&lint_name_upper, lint.category)), + ); + + // Add the lint to `impl_lint_pass`/`declare_lint_pass` + let impl_lint_pass_start = file_contents.find("impl_lint_pass!").unwrap_or_else(|| { + file_contents + .find("declare_lint_pass!") + .unwrap_or_else(|| panic!("failed to find `impl_lint_pass`/`declare_lint_pass`")) + }); + + let mut arr_start = file_contents[impl_lint_pass_start..].find('[').unwrap_or_else(|| { + panic!("malformed `impl_lint_pass`/`declare_lint_pass`"); + }); + + arr_start += impl_lint_pass_start; + + let mut arr_end = file_contents[arr_start..] + .find(']') + .expect("failed to find `impl_lint_pass` terminator"); + + arr_end += arr_start; + + let mut arr_content = file_contents[arr_start + 1..arr_end].to_string(); + arr_content.retain(|c| !c.is_whitespace()); + + let mut new_arr_content = String::new(); + for ident in arr_content + .split(',') + .chain(std::iter::once(&*lint_name_upper)) + .filter(|s| !s.is_empty()) + { + let _ = write!(new_arr_content, "\n {},", ident); + } + new_arr_content.push('\n'); + + file_contents.replace_range(arr_start + 1..arr_end, &new_arr_content); + + // Just add the mod declaration at the top, it'll be fixed by rustfmt + file_contents.insert_str(0, &format!("mod {};\n", &lint.name)); + + let mut file = OpenOptions::new() + .write(true) + .truncate(true) + .open(path) + .context(format!("trying to open: `{}`", path.display()))?; + file.write_all(file_contents.as_bytes()) + .context(format!("writing to file: `{}`", path.display()))?; + + Ok(lint_context) +} + #[test] fn test_camel_case() { let s = "a_lint"; diff --git a/clippy_dev/src/update_lints.rs b/clippy_dev/src/update_lints.rs index c089f4d8ce4..aed38bc2817 100644 --- a/clippy_dev/src/update_lints.rs +++ b/clippy_dev/src/update_lints.rs @@ -824,10 +824,12 @@ macro_rules! match_tokens { } } -struct LintDeclSearchResult<'a> { - token_kind: TokenKind, - content: &'a str, - range: Range, +pub(crate) use match_tokens; + +pub(crate) struct LintDeclSearchResult<'a> { + pub token_kind: TokenKind, + pub content: &'a str, + pub range: Range, } /// Parse a source file looking for `declare_clippy_lint` macro invocations. diff --git a/clippy_lints/src/cargo/mod.rs b/clippy_lints/src/cargo/mod.rs index abe95c6663f..9f45db86a09 100644 --- a/clippy_lints/src/cargo/mod.rs +++ b/clippy_lints/src/cargo/mod.rs @@ -1,3 +1,8 @@ +mod common_metadata; +mod feature_name; +mod multiple_crate_versions; +mod wildcard_dependencies; + use cargo_metadata::MetadataCommand; use clippy_utils::diagnostics::span_lint; use clippy_utils::is_lint_allowed; @@ -6,11 +11,6 @@ use rustc_lint::{LateContext, LateLintPass, Lint}; use rustc_session::{declare_tool_lint, impl_lint_pass}; use rustc_span::DUMMY_SP; -mod common_metadata; -mod feature_name; -mod multiple_crate_versions; -mod wildcard_dependencies; - declare_clippy_lint! { /// ### What it does /// Checks to see if all common metadata is defined in diff --git a/clippy_lints/src/matches/mod.rs b/clippy_lints/src/matches/mod.rs index a3d69a4d09c..b638f271602 100644 --- a/clippy_lints/src/matches/mod.rs +++ b/clippy_lints/src/matches/mod.rs @@ -1,13 +1,3 @@ -use clippy_utils::source::{snippet_opt, span_starts_with, walk_span_to_context}; -use clippy_utils::{higher, in_constant, meets_msrv, msrvs}; -use rustc_hir::{Arm, Expr, ExprKind, Local, MatchSource, Pat}; -use rustc_lexer::{tokenize, TokenKind}; -use rustc_lint::{LateContext, LateLintPass, LintContext}; -use rustc_middle::lint::in_external_macro; -use rustc_semver::RustcVersion; -use rustc_session::{declare_tool_lint, impl_lint_pass}; -use rustc_span::{Span, SpanData, SyntaxContext}; - mod collapsible_match; mod infallible_destructuring_match; mod manual_map; @@ -31,6 +21,16 @@ mod single_match; mod try_err; mod wild_in_or_pats; +use clippy_utils::source::{snippet_opt, span_starts_with, walk_span_to_context}; +use clippy_utils::{higher, in_constant, meets_msrv, msrvs}; +use rustc_hir::{Arm, Expr, ExprKind, Local, MatchSource, Pat}; +use rustc_lexer::{tokenize, TokenKind}; +use rustc_lint::{LateContext, LateLintPass, LintContext}; +use rustc_middle::lint::in_external_macro; +use rustc_semver::RustcVersion; +use rustc_session::{declare_tool_lint, impl_lint_pass}; +use rustc_span::{Span, SpanData, SyntaxContext}; + declare_clippy_lint! { /// ### What it does /// Checks for matches with a single arm where an `if let` diff --git a/clippy_lints/src/operators/mod.rs b/clippy_lints/src/operators/mod.rs index c688d94bb52..bb6d99406b4 100644 --- a/clippy_lints/src/operators/mod.rs +++ b/clippy_lints/src/operators/mod.rs @@ -1,9 +1,3 @@ -use rustc_hir::{Body, Expr, ExprKind, UnOp}; -use rustc_lint::{LateContext, LateLintPass}; -use rustc_session::{declare_tool_lint, impl_lint_pass}; - -pub(crate) mod arithmetic; - mod absurd_extreme_comparisons; mod assign_op_pattern; mod bit_mask; @@ -27,6 +21,12 @@ mod ptr_eq; mod self_assignment; mod verbose_bit_mask; +pub(crate) mod arithmetic; + +use rustc_hir::{Body, Expr, ExprKind, UnOp}; +use rustc_lint::{LateContext, LateLintPass}; +use rustc_session::{declare_tool_lint, impl_lint_pass}; + declare_clippy_lint! { /// ### What it does /// Checks for comparisons where one side of the relation is -- cgit 1.4.1-3-g733a5 From c8ee8c30f00214fcc3849d3124501e5e9768bb53 Mon Sep 17 00:00:00 2001 From: Serial <69764315+Serial-ATA@users.noreply.github.com> Date: Tue, 26 Jul 2022 19:18:10 -0400 Subject: Give the user more information during creation --- clippy_dev/src/new_lint.rs | 33 +++++++++++++++++++++++---------- 1 file changed, 23 insertions(+), 10 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/new_lint.rs b/clippy_dev/src/new_lint.rs index af22cb89942..4eea25b66de 100644 --- a/clippy_dev/src/new_lint.rs +++ b/clippy_dev/src/new_lint.rs @@ -62,11 +62,14 @@ pub fn create( fn create_lint(lint: &LintData<'_>, enable_msrv: bool) -> io::Result<()> { if let Some(ty) = lint.ty { - generate_from_ty(lint, enable_msrv, ty) + create_lint_for_ty(lint, enable_msrv, ty) } else { let lint_contents = get_lint_file_contents(lint, enable_msrv); let lint_path = format!("clippy_lints/src/{}.rs", lint.name); - write_file(lint.project_root.join(&lint_path), lint_contents.as_bytes()) + write_file(lint.project_root.join(&lint_path), lint_contents.as_bytes())?; + println!("Generated lint file: `{}`", lint_path); + + Ok(()) } } @@ -86,16 +89,22 @@ fn create_test(lint: &LintData<'_>) -> io::Result<()> { if lint.category == "cargo" { let relative_test_dir = format!("tests/ui-cargo/{}", lint.name); - let test_dir = lint.project_root.join(relative_test_dir); + let test_dir = lint.project_root.join(&relative_test_dir); fs::create_dir(&test_dir)?; create_project_layout(lint.name, &test_dir, "fail", "Content that triggers the lint goes here")?; - create_project_layout(lint.name, &test_dir, "pass", "This file should not trigger the lint") + create_project_layout(lint.name, &test_dir, "pass", "This file should not trigger the lint")?; + + println!("Generated test directories: `{}`, `{}`", format!("{}/pass", relative_test_dir), format!("{}/fail", relative_test_dir)); } else { let test_path = format!("tests/ui/{}.rs", lint.name); let test_contents = get_test_file_contents(lint.name, None); - write_file(lint.project_root.join(test_path), test_contents) + write_file(lint.project_root.join(&test_path), test_contents)?; + + println!("Generated test file: `{}`", test_path); } + + Ok(()) } fn add_lint(lint: &LintData<'_>, enable_msrv: bool) -> io::Result<()> { @@ -325,12 +334,14 @@ fn get_lint_declaration(name_upper: &str, category: &str) -> String { ) } -fn generate_from_ty(lint: &LintData<'_>, enable_msrv: bool, ty: &str) -> io::Result<()> { - if ty == "cargo" { - assert_eq!( +fn create_lint_for_ty(lint: &LintData<'_>, enable_msrv: bool, ty: &str) -> io::Result<()> { + match ty { + "cargo" => assert_eq!( lint.category, "cargo", "Lints of type `cargo` must have the `cargo` category" - ); + ), + _ if lint.category == "cargo" => panic!("Lints of category `cargo` must have the `cargo` type"), + _ => {} } let ty_dir = lint.project_root.join(format!("clippy_lints/src/{}", ty)); @@ -392,7 +403,9 @@ fn generate_from_ty(lint: &LintData<'_>, enable_msrv: bool, ty: &str) -> io::Res ); } - write_file(lint_file_path, lint_file_contents)?; + write_file(lint_file_path.as_path(), lint_file_contents)?; + println!("Generated lint file: `clippy_lints/src/{}/{}.rs`", ty, lint.name); + println!("Be sure to add a call to `{}::check` in `clippy_lints/src/{}/mod.rs`!", lint.name, ty); Ok(()) } -- cgit 1.4.1-3-g733a5 From f31937043dbd8a10309ad742cd9e1a49721a09e5 Mon Sep 17 00:00:00 2001 From: Serial <69764315+Serial-ATA@users.noreply.github.com> Date: Tue, 26 Jul 2022 19:32:34 -0400 Subject: Implicitly set `--type=cargo` when using `--category=cargo` --- clippy_dev/src/main.rs | 4 ++-- clippy_dev/src/new_lint.rs | 20 ++++++++++++++------ 2 files changed, 16 insertions(+), 8 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index 2008942d087..a417d3dd8a4 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -36,8 +36,8 @@ fn main() { match new_lint::create( matches.get_one::("pass"), matches.get_one::("name"), - matches.get_one::("category"), - matches.get_one::("type"), + matches.get_one::("category").map(String::as_str), + matches.get_one::("type").map(String::as_str), matches.contains_id("msrv"), ) { Ok(_) => update_lints::update(update_lints::UpdateMode::Change), diff --git a/clippy_dev/src/new_lint.rs b/clippy_dev/src/new_lint.rs index 4eea25b66de..03d2ef3d19e 100644 --- a/clippy_dev/src/new_lint.rs +++ b/clippy_dev/src/new_lint.rs @@ -38,15 +38,20 @@ impl Context for io::Result { pub fn create( pass: Option<&String>, lint_name: Option<&String>, - category: Option<&String>, - ty: Option<&String>, + category: Option<&str>, + mut ty: Option<&str>, msrv: bool, ) -> io::Result<()> { + if category == Some("cargo") && ty.is_none() { + // `cargo` is a special category, these lints should always be in `clippy_lints/src/cargo` + ty = Some("cargo"); + } + let lint = LintData { pass: pass.map_or("", String::as_str), name: lint_name.expect("`name` argument is validated by clap"), category: category.expect("`category` argument is validated by clap"), - ty: ty.map(String::as_str), + ty, project_root: clippy_project_root(), }; @@ -95,7 +100,7 @@ fn create_test(lint: &LintData<'_>) -> io::Result<()> { create_project_layout(lint.name, &test_dir, "fail", "Content that triggers the lint goes here")?; create_project_layout(lint.name, &test_dir, "pass", "This file should not trigger the lint")?; - println!("Generated test directories: `{}`, `{}`", format!("{}/pass", relative_test_dir), format!("{}/fail", relative_test_dir)); + println!("Generated test directories: `{relative_test_dir}/pass`, `{relative_test_dir}/fail`"); } else { let test_path = format!("tests/ui/{}.rs", lint.name); let test_contents = get_test_file_contents(lint.name, None); @@ -341,7 +346,7 @@ fn create_lint_for_ty(lint: &LintData<'_>, enable_msrv: bool, ty: &str) -> io::R "Lints of type `cargo` must have the `cargo` category" ), _ if lint.category == "cargo" => panic!("Lints of category `cargo` must have the `cargo` type"), - _ => {} + _ => {}, } let ty_dir = lint.project_root.join(format!("clippy_lints/src/{}", ty)); @@ -405,7 +410,10 @@ fn create_lint_for_ty(lint: &LintData<'_>, enable_msrv: bool, ty: &str) -> io::R write_file(lint_file_path.as_path(), lint_file_contents)?; println!("Generated lint file: `clippy_lints/src/{}/{}.rs`", ty, lint.name); - println!("Be sure to add a call to `{}::check` in `clippy_lints/src/{}/mod.rs`!", lint.name, ty); + println!( + "Be sure to add a call to `{}::check` in `clippy_lints/src/{}/mod.rs`!", + lint.name, ty + ); Ok(()) } -- cgit 1.4.1-3-g733a5 From 1ed7bff32c3a4a62a644aed139dbb953c0725911 Mon Sep 17 00:00:00 2001 From: Serial <69764315+Serial-ATA@users.noreply.github.com> Date: Thu, 28 Jul 2022 03:40:21 -0400 Subject: Tell the user how to revert `dev setup intellij` --- clippy_dev/src/fmt.rs | 8 ++++---- 1 file changed, 4 insertions(+), 4 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/fmt.rs b/clippy_dev/src/fmt.rs index d513a229b7e..3b27f061eb0 100644 --- a/clippy_dev/src/fmt.rs +++ b/clippy_dev/src/fmt.rs @@ -13,7 +13,7 @@ pub enum CliError { IoError(io::Error), RustfmtNotInstalled, WalkDirError(walkdir::Error), - RaSetupActive, + IntellijSetupActive, } impl From for CliError { @@ -48,7 +48,7 @@ pub fn run(check: bool, verbose: bool) { .expect("Failed to read clippy Cargo.toml") .contains(&"[target.'cfg(NOT_A_PLATFORM)'.dependencies]") { - return Err(CliError::RaSetupActive); + return Err(CliError::IntellijSetupActive); } rustfmt_test(context)?; @@ -93,11 +93,11 @@ pub fn run(check: bool, verbose: bool) { CliError::WalkDirError(err) => { eprintln!("error: {}", err); }, - CliError::RaSetupActive => { + CliError::IntellijSetupActive => { eprintln!( "error: a local rustc repo is enabled as path dependency via `cargo dev setup intellij`. Not formatting because that would format the local repo as well! -Please revert the changes to Cargo.tomls first." +Please revert the changes to Cargo.tomls with `cargo dev remove intellij`." ); }, } -- cgit 1.4.1-3-g733a5 From 1bf88414790bacf5773bd7f19f0c58e183d0ca7c Mon Sep 17 00:00:00 2001 From: Guilherme-Vasconcelos <49197151+Guilherme-Vasconcelos@users.noreply.github.com> Date: Fri, 5 Aug 2022 20:59:50 -0300 Subject: Update all tests to comply with clippy::manual_empty_string_creations --- clippy_dev/src/new_lint.rs | 2 +- clippy_lints/src/manual_async_fn.rs | 2 +- clippy_lints/src/methods/option_map_unwrap_or.rs | 2 +- clippy_lints/src/misc_early/unneeded_wildcard_pattern.rs | 2 +- clippy_lints/src/unnecessary_wraps.rs | 2 +- tests/ui/case_sensitive_file_extension_comparisons.rs | 10 +++++----- tests/ui/case_sensitive_file_extension_comparisons.stderr | 12 ++++++------ tests/ui/format.fixed | 2 +- tests/ui/format.rs | 2 +- tests/ui/identity_op.fixed | 2 +- tests/ui/identity_op.rs | 2 +- tests/ui/manual_empty_string_creations.fixed | 2 +- tests/ui/or_fun_call.fixed | 4 ++-- tests/ui/or_fun_call.rs | 4 ++-- tests/ui/or_fun_call.stderr | 6 +++--- tests/ui/string_add.rs | 4 ++-- tests/ui/string_add_assign.fixed | 4 ++-- tests/ui/string_add_assign.rs | 4 ++-- tests/ui/unnecessary_owned_empty_strings.fixed | 1 + tests/ui/unnecessary_owned_empty_strings.rs | 1 + tests/ui/unnecessary_owned_empty_strings.stderr | 2 +- tests/ui/useless_conversion_try.rs | 4 ++-- tests/ui/useless_conversion_try.stderr | 2 +- 23 files changed, 40 insertions(+), 38 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/new_lint.rs b/clippy_dev/src/new_lint.rs index 10a8f31f457..be05e67d724 100644 --- a/clippy_dev/src/new_lint.rs +++ b/clippy_dev/src/new_lint.rs @@ -155,7 +155,7 @@ fn to_camel_case(name: &str) -> String { name.split('_') .map(|s| { if s.is_empty() { - String::from("") + String::new() } else { [&s[0..1].to_uppercase(), &s[1..]].concat() } diff --git a/clippy_lints/src/manual_async_fn.rs b/clippy_lints/src/manual_async_fn.rs index a0ca7e6ff1e..2502c8f880d 100644 --- a/clippy_lints/src/manual_async_fn.rs +++ b/clippy_lints/src/manual_async_fn.rs @@ -192,7 +192,7 @@ fn suggested_ret(cx: &LateContext<'_>, output: &Ty<'_>) -> Option<(&'static str, match output.kind { TyKind::Tup(tys) if tys.is_empty() => { let sugg = "remove the return type"; - Some((sugg, "".into())) + Some((sugg, String::new())) }, _ => { let sugg = "return the output of the future directly"; diff --git a/clippy_lints/src/methods/option_map_unwrap_or.rs b/clippy_lints/src/methods/option_map_unwrap_or.rs index 6c641af59f9..3c4002a3aef 100644 --- a/clippy_lints/src/methods/option_map_unwrap_or.rs +++ b/clippy_lints/src/methods/option_map_unwrap_or.rs @@ -78,7 +78,7 @@ pub(super) fn check<'tcx>( map_span, String::from(if unwrap_snippet_none { "and_then" } else { "map_or" }), ), - (expr.span.with_lo(unwrap_recv.span.hi()), String::from("")), + (expr.span.with_lo(unwrap_recv.span.hi()), String::new()), ]; if !unwrap_snippet_none { diff --git a/clippy_lints/src/misc_early/unneeded_wildcard_pattern.rs b/clippy_lints/src/misc_early/unneeded_wildcard_pattern.rs index df044538fe1..7c4ae746e90 100644 --- a/clippy_lints/src/misc_early/unneeded_wildcard_pattern.rs +++ b/clippy_lints/src/misc_early/unneeded_wildcard_pattern.rs @@ -46,7 +46,7 @@ fn span_lint(cx: &EarlyContext<'_>, span: Span, only_one: bool) { "these patterns are unneeded as the `..` pattern can match those elements" }, if only_one { "remove it" } else { "remove them" }, - "".to_string(), + String::new(), Applicability::MachineApplicable, ); } diff --git a/clippy_lints/src/unnecessary_wraps.rs b/clippy_lints/src/unnecessary_wraps.rs index f4f5a4336a3..a5afbb8ff9d 100644 --- a/clippy_lints/src/unnecessary_wraps.rs +++ b/clippy_lints/src/unnecessary_wraps.rs @@ -130,7 +130,7 @@ impl<'tcx> LateLintPass<'tcx> for UnnecessaryWraps { ( ret_expr.span, if inner_type.is_unit() { - "".to_string() + String::new() } else { snippet(cx, arg.span.source_callsite(), "..").to_string() } diff --git a/tests/ui/case_sensitive_file_extension_comparisons.rs b/tests/ui/case_sensitive_file_extension_comparisons.rs index 0d65071af15..6f0485b5279 100644 --- a/tests/ui/case_sensitive_file_extension_comparisons.rs +++ b/tests/ui/case_sensitive_file_extension_comparisons.rs @@ -14,31 +14,31 @@ fn is_rust_file(filename: &str) -> bool { fn main() { // std::string::String and &str should trigger the lint failure with .ext12 - let _ = String::from("").ends_with(".ext12"); + let _ = String::new().ends_with(".ext12"); let _ = "str".ends_with(".ext12"); // The test struct should not trigger the lint failure with .ext12 TestStruct {}.ends_with(".ext12"); // std::string::String and &str should trigger the lint failure with .EXT12 - let _ = String::from("").ends_with(".EXT12"); + let _ = String::new().ends_with(".EXT12"); let _ = "str".ends_with(".EXT12"); // The test struct should not trigger the lint failure with .EXT12 TestStruct {}.ends_with(".EXT12"); // Should not trigger the lint failure with .eXT12 - let _ = String::from("").ends_with(".eXT12"); + let _ = String::new().ends_with(".eXT12"); let _ = "str".ends_with(".eXT12"); TestStruct {}.ends_with(".eXT12"); // Should not trigger the lint failure with .EXT123 (too long) - let _ = String::from("").ends_with(".EXT123"); + let _ = String::new().ends_with(".EXT123"); let _ = "str".ends_with(".EXT123"); TestStruct {}.ends_with(".EXT123"); // Shouldn't fail if it doesn't start with a dot - let _ = String::from("").ends_with("a.ext"); + let _ = String::new().ends_with("a.ext"); let _ = "str".ends_with("a.extA"); TestStruct {}.ends_with("a.ext"); } diff --git a/tests/ui/case_sensitive_file_extension_comparisons.stderr b/tests/ui/case_sensitive_file_extension_comparisons.stderr index 05b98169f2d..5d9a043edb9 100644 --- a/tests/ui/case_sensitive_file_extension_comparisons.stderr +++ b/tests/ui/case_sensitive_file_extension_comparisons.stderr @@ -8,10 +8,10 @@ LL | filename.ends_with(".rs") = help: consider using a case-insensitive comparison instead error: case-sensitive file extension comparison - --> $DIR/case_sensitive_file_extension_comparisons.rs:17:30 + --> $DIR/case_sensitive_file_extension_comparisons.rs:17:27 | -LL | let _ = String::from("").ends_with(".ext12"); - | ^^^^^^^^^^^^^^^^^^^ +LL | let _ = String::new().ends_with(".ext12"); + | ^^^^^^^^^^^^^^^^^^^ | = help: consider using a case-insensitive comparison instead @@ -24,10 +24,10 @@ LL | let _ = "str".ends_with(".ext12"); = help: consider using a case-insensitive comparison instead error: case-sensitive file extension comparison - --> $DIR/case_sensitive_file_extension_comparisons.rs:24:30 + --> $DIR/case_sensitive_file_extension_comparisons.rs:24:27 | -LL | let _ = String::from("").ends_with(".EXT12"); - | ^^^^^^^^^^^^^^^^^^^ +LL | let _ = String::new().ends_with(".EXT12"); + | ^^^^^^^^^^^^^^^^^^^ | = help: consider using a case-insensitive comparison instead diff --git a/tests/ui/format.fixed b/tests/ui/format.fixed index 6b754f3bd71..b56d6aec508 100644 --- a/tests/ui/format.fixed +++ b/tests/ui/format.fixed @@ -33,7 +33,7 @@ fn main() { format!("foo {}", "bar"); format!("{} bar", "foo"); - let arg: String = "".to_owned(); + let arg = String::new(); arg.to_string(); format!("{:?}", arg); // Don't warn about debug. format!("{:8}", arg); diff --git a/tests/ui/format.rs b/tests/ui/format.rs index ca9826b356e..4c1a3a840ed 100644 --- a/tests/ui/format.rs +++ b/tests/ui/format.rs @@ -35,7 +35,7 @@ fn main() { format!("foo {}", "bar"); format!("{} bar", "foo"); - let arg: String = "".to_owned(); + let arg = String::new(); format!("{}", arg); format!("{:?}", arg); // Don't warn about debug. format!("{:8}", arg); diff --git a/tests/ui/identity_op.fixed b/tests/ui/identity_op.fixed index 5f9cebe212a..fa564e23cd2 100644 --- a/tests/ui/identity_op.fixed +++ b/tests/ui/identity_op.fixed @@ -68,7 +68,7 @@ fn main() { &x; x; - let mut a = A("".into()); + let mut a = A(String::new()); let b = a << 0; // no error: non-integer 1 * Meter; // no error: non-integer diff --git a/tests/ui/identity_op.rs b/tests/ui/identity_op.rs index ca799c9cfac..3d06d2a73b6 100644 --- a/tests/ui/identity_op.rs +++ b/tests/ui/identity_op.rs @@ -68,7 +68,7 @@ fn main() { &x >> 0; x >> &0; - let mut a = A("".into()); + let mut a = A(String::new()); let b = a << 0; // no error: non-integer 1 * Meter; // no error: non-integer diff --git a/tests/ui/manual_empty_string_creations.fixed b/tests/ui/manual_empty_string_creations.fixed index 3516312ee0c..caf0c657c81 100644 --- a/tests/ui/manual_empty_string_creations.fixed +++ b/tests/ui/manual_empty_string_creations.fixed @@ -7,7 +7,7 @@ macro_rules! create_strings_from_macro { ($some_str:expr) => { let _: String = $some_str.into(); let _ = $some_str.to_string(); - } + }; } fn main() { diff --git a/tests/ui/or_fun_call.fixed b/tests/ui/or_fun_call.fixed index fdb08d953ff..18ea4e55029 100644 --- a/tests/ui/or_fun_call.fixed +++ b/tests/ui/or_fun_call.fixed @@ -90,8 +90,8 @@ fn or_fun_call() { let mut btree_vec = BTreeMap::>::new(); btree_vec.entry(42).or_insert(vec![]); - let stringy = Some(String::from("")); - let _ = stringy.unwrap_or_else(|| "".to_owned()); + let stringy = Some(String::new()); + let _ = stringy.unwrap_or_default(); let opt = Some(1); let hello = "Hello"; diff --git a/tests/ui/or_fun_call.rs b/tests/ui/or_fun_call.rs index 57ab5f03ee2..c353b41e449 100644 --- a/tests/ui/or_fun_call.rs +++ b/tests/ui/or_fun_call.rs @@ -90,8 +90,8 @@ fn or_fun_call() { let mut btree_vec = BTreeMap::>::new(); btree_vec.entry(42).or_insert(vec![]); - let stringy = Some(String::from("")); - let _ = stringy.unwrap_or("".to_owned()); + let stringy = Some(String::new()); + let _ = stringy.unwrap_or(String::new()); let opt = Some(1); let hello = "Hello"; diff --git a/tests/ui/or_fun_call.stderr b/tests/ui/or_fun_call.stderr index 4c5938ab88b..887f23ac976 100644 --- a/tests/ui/or_fun_call.stderr +++ b/tests/ui/or_fun_call.stderr @@ -66,11 +66,11 @@ error: use of `unwrap_or` followed by a function call LL | without_default.unwrap_or(Foo::new()); | ^^^^^^^^^^^^^^^^^^^^^ help: try this: `unwrap_or_else(Foo::new)` -error: use of `unwrap_or` followed by a function call +error: use of `unwrap_or` followed by a call to `new` --> $DIR/or_fun_call.rs:94:21 | -LL | let _ = stringy.unwrap_or("".to_owned()); - | ^^^^^^^^^^^^^^^^^^^^^^^^ help: try this: `unwrap_or_else(|| "".to_owned())` +LL | let _ = stringy.unwrap_or(String::new()); + | ^^^^^^^^^^^^^^^^^^^^^^^^ help: try this: `unwrap_or_default()` error: use of `unwrap_or` followed by a function call --> $DIR/or_fun_call.rs:102:21 diff --git a/tests/ui/string_add.rs b/tests/ui/string_add.rs index 30fd17c59e5..16673c01e63 100644 --- a/tests/ui/string_add.rs +++ b/tests/ui/string_add.rs @@ -7,13 +7,13 @@ extern crate macro_rules; #[allow(clippy::string_add_assign, unused)] fn main() { // ignores assignment distinction - let mut x = "".to_owned(); + let mut x = String::new(); for _ in 1..3 { x = x + "."; } - let y = "".to_owned(); + let y = String::new(); let z = y + "..."; assert_eq!(&x, &z); diff --git a/tests/ui/string_add_assign.fixed b/tests/ui/string_add_assign.fixed index db71bab1e52..b687f43b254 100644 --- a/tests/ui/string_add_assign.fixed +++ b/tests/ui/string_add_assign.fixed @@ -4,13 +4,13 @@ #[warn(clippy::string_add_assign)] fn main() { // ignores assignment distinction - let mut x = "".to_owned(); + let mut x = String::new(); for _ in 1..3 { x += "."; } - let y = "".to_owned(); + let y = String::new(); let z = y + "..."; assert_eq!(&x, &z); diff --git a/tests/ui/string_add_assign.rs b/tests/ui/string_add_assign.rs index 644991945cb..e5dbde108fb 100644 --- a/tests/ui/string_add_assign.rs +++ b/tests/ui/string_add_assign.rs @@ -4,13 +4,13 @@ #[warn(clippy::string_add_assign)] fn main() { // ignores assignment distinction - let mut x = "".to_owned(); + let mut x = String::new(); for _ in 1..3 { x = x + "."; } - let y = "".to_owned(); + let y = String::new(); let z = y + "..."; assert_eq!(&x, &z); diff --git a/tests/ui/unnecessary_owned_empty_strings.fixed b/tests/ui/unnecessary_owned_empty_strings.fixed index f95f91329a2..c390618ca98 100644 --- a/tests/ui/unnecessary_owned_empty_strings.fixed +++ b/tests/ui/unnecessary_owned_empty_strings.fixed @@ -12,6 +12,7 @@ fn main() { ref_str_argument(""); // should be linted + #[allow(clippy::manual_empty_string_creations)] ref_str_argument(""); // should not be linted diff --git a/tests/ui/unnecessary_owned_empty_strings.rs b/tests/ui/unnecessary_owned_empty_strings.rs index 0cbdc151ed9..4a9d6125eb1 100644 --- a/tests/ui/unnecessary_owned_empty_strings.rs +++ b/tests/ui/unnecessary_owned_empty_strings.rs @@ -12,6 +12,7 @@ fn main() { ref_str_argument(&String::new()); // should be linted + #[allow(clippy::manual_empty_string_creations)] ref_str_argument(&String::from("")); // should not be linted diff --git a/tests/ui/unnecessary_owned_empty_strings.stderr b/tests/ui/unnecessary_owned_empty_strings.stderr index 46bc4597b33..1eb198a8675 100644 --- a/tests/ui/unnecessary_owned_empty_strings.stderr +++ b/tests/ui/unnecessary_owned_empty_strings.stderr @@ -7,7 +7,7 @@ LL | ref_str_argument(&String::new()); = note: `-D clippy::unnecessary-owned-empty-strings` implied by `-D warnings` error: usage of `&String::from("")` for a function expecting a `&str` argument - --> $DIR/unnecessary_owned_empty_strings.rs:15:22 + --> $DIR/unnecessary_owned_empty_strings.rs:16:22 | LL | ref_str_argument(&String::from("")); | ^^^^^^^^^^^^^^^^^ help: try: `""` diff --git a/tests/ui/useless_conversion_try.rs b/tests/ui/useless_conversion_try.rs index 39f54c27bee..4acf5b5fa2d 100644 --- a/tests/ui/useless_conversion_try.rs +++ b/tests/ui/useless_conversion_try.rs @@ -29,10 +29,10 @@ fn main() { let _ = String::try_from("foo".to_string()).unwrap(); let _ = String::try_from(format!("A: {:04}", 123)).unwrap(); let _: String = format!("Hello {}", "world").try_into().unwrap(); - let _: String = "".to_owned().try_into().unwrap(); + let _: String = String::new().try_into().unwrap(); let _: String = match String::from("_").try_into() { Ok(a) => a, - Err(_) => "".into(), + Err(_) => String::new(), }; // FIXME this is a false negative #[allow(clippy::cmp_owned)] diff --git a/tests/ui/useless_conversion_try.stderr b/tests/ui/useless_conversion_try.stderr index b691c13f7db..12e74d61471 100644 --- a/tests/ui/useless_conversion_try.stderr +++ b/tests/ui/useless_conversion_try.stderr @@ -62,7 +62,7 @@ LL | let _: String = format!("Hello {}", "world").try_into().unwrap(); error: useless conversion to the same type: `std::string::String` --> $DIR/useless_conversion_try.rs:32:21 | -LL | let _: String = "".to_owned().try_into().unwrap(); +LL | let _: String = String::new().try_into().unwrap(); | ^^^^^^^^^^^^^^^^^^^^^^^^ | = help: consider removing `.try_into()` -- cgit 1.4.1-3-g733a5 From 032f112745d2632fc37175fad7bab98215062586 Mon Sep 17 00:00:00 2001 From: "Samuel E. Moelius III" Date: Fri, 8 Jul 2022 05:30:17 -0400 Subject: Fix adjacent code --- clippy_dev/src/bless.rs | 2 +- clippy_dev/src/fmt.rs | 8 ++++---- clippy_dev/src/update_lints.rs | 4 ++-- rustc_tools_util/src/lib.rs | 4 ++-- tests/check-fmt.rs | 2 +- tests/dogfood.rs | 4 ++-- tests/integration.rs | 4 ++-- tests/lint_message_convention.rs | 4 ++-- tests/ui/regex.rs | 2 +- tests/ui/same_item_push.rs | 1 + tests/ui/verbose_file_reads.rs | 2 +- tests/workspace.rs | 14 +++++++------- 12 files changed, 26 insertions(+), 25 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/bless.rs b/clippy_dev/src/bless.rs index f5c51b9474f..92b2771f3fe 100644 --- a/clippy_dev/src/bless.rs +++ b/clippy_dev/src/bless.rs @@ -37,7 +37,7 @@ fn update_reference_file(test_output_entry: &DirEntry, ignore_timestamp: bool) { return; } - let test_output_file = fs::read(&test_output_path).expect("Unable to read test output file"); + let test_output_file = fs::read(test_output_path).expect("Unable to read test output file"); let reference_file = fs::read(&reference_file_path).unwrap_or_default(); if test_output_file != reference_file { diff --git a/clippy_dev/src/fmt.rs b/clippy_dev/src/fmt.rs index 3b27f061eb0..357cf6fc43a 100644 --- a/clippy_dev/src/fmt.rs +++ b/clippy_dev/src/fmt.rs @@ -46,7 +46,7 @@ pub fn run(check: bool, verbose: bool) { // dependency if fs::read_to_string(project_root.join("Cargo.toml")) .expect("Failed to read clippy Cargo.toml") - .contains(&"[target.'cfg(NOT_A_PLATFORM)'.dependencies]") + .contains("[target.'cfg(NOT_A_PLATFORM)'.dependencies]") { return Err(CliError::IntellijSetupActive); } @@ -193,10 +193,10 @@ fn rustfmt_test(context: &FmtContext) -> Result<(), CliError> { let args = &["--version"]; if context.verbose { - println!("{}", format_command(&program, &dir, args)); + println!("{}", format_command(program, &dir, args)); } - let output = Command::new(&program).current_dir(&dir).args(args.iter()).output()?; + let output = Command::new(program).current_dir(&dir).args(args.iter()).output()?; if output.status.success() { Ok(()) @@ -207,7 +207,7 @@ fn rustfmt_test(context: &FmtContext) -> Result<(), CliError> { Err(CliError::RustfmtNotInstalled) } else { Err(CliError::CommandFailed( - format_command(&program, &dir, args), + format_command(program, &dir, args), std::str::from_utf8(&output.stderr).unwrap_or("").to_string(), )) } diff --git a/clippy_dev/src/update_lints.rs b/clippy_dev/src/update_lints.rs index 05e79a24188..c503142e5e4 100644 --- a/clippy_dev/src/update_lints.rs +++ b/clippy_dev/src/update_lints.rs @@ -418,7 +418,7 @@ fn remove_lint_declaration(name: &str, path: &Path, lints: &mut Vec) -> io .expect("failed to find `impl_lint_pass` terminator"); impl_lint_pass_end += impl_lint_pass_start; - if let Some(lint_name_pos) = content[impl_lint_pass_start..impl_lint_pass_end].find(&lint_name_upper) { + if let Some(lint_name_pos) = content[impl_lint_pass_start..impl_lint_pass_end].find(lint_name_upper) { let mut lint_name_end = impl_lint_pass_start + (lint_name_pos + lint_name_upper.len()); for c in content[lint_name_end..impl_lint_pass_end].chars() { // Remove trailing whitespace @@ -451,7 +451,7 @@ fn remove_lint_declaration(name: &str, path: &Path, lints: &mut Vec) -> io } let mut content = - fs::read_to_string(&path).unwrap_or_else(|_| panic!("failed to read `{}`", path.to_string_lossy())); + fs::read_to_string(path).unwrap_or_else(|_| panic!("failed to read `{}`", path.to_string_lossy())); eprintln!( "warn: you will have to manually remove any code related to `{}` from `{}`", diff --git a/rustc_tools_util/src/lib.rs b/rustc_tools_util/src/lib.rs index 5f289918a7c..429dddc42ea 100644 --- a/rustc_tools_util/src/lib.rs +++ b/rustc_tools_util/src/lib.rs @@ -84,7 +84,7 @@ impl std::fmt::Debug for VersionInfo { #[must_use] pub fn get_commit_hash() -> Option { std::process::Command::new("git") - .args(&["rev-parse", "--short", "HEAD"]) + .args(["rev-parse", "--short", "HEAD"]) .output() .ok() .and_then(|r| String::from_utf8(r.stdout).ok()) @@ -93,7 +93,7 @@ pub fn get_commit_hash() -> Option { #[must_use] pub fn get_commit_date() -> Option { std::process::Command::new("git") - .args(&["log", "-1", "--date=short", "--pretty=format:%cd"]) + .args(["log", "-1", "--date=short", "--pretty=format:%cd"]) .output() .ok() .and_then(|r| String::from_utf8(r.stdout).ok()) diff --git a/tests/check-fmt.rs b/tests/check-fmt.rs index 0defd45b68b..e106583de4a 100644 --- a/tests/check-fmt.rs +++ b/tests/check-fmt.rs @@ -13,7 +13,7 @@ fn fmt() { let root_dir = PathBuf::from(env!("CARGO_MANIFEST_DIR")); let output = Command::new("cargo") .current_dir(root_dir) - .args(&["dev", "fmt", "--check"]) + .args(["dev", "fmt", "--check"]) .output() .unwrap(); diff --git a/tests/dogfood.rs b/tests/dogfood.rs index 5697e8680cd..961525bbd91 100644 --- a/tests/dogfood.rs +++ b/tests/dogfood.rs @@ -87,11 +87,11 @@ fn run_clippy_for_package(project: &str, args: &[&str]) { if cfg!(feature = "internal") { // internal lints only exist if we build with the internal feature - command.args(&["-D", "clippy::internal"]); + command.args(["-D", "clippy::internal"]); } else { // running a clippy built without internal lints on the clippy source // that contains e.g. `allow(clippy::invalid_paths)` - command.args(&["-A", "unknown_lints"]); + command.args(["-A", "unknown_lints"]); } let output = command.output().unwrap(); diff --git a/tests/integration.rs b/tests/integration.rs index c64425fa01a..23a9bef3ccc 100644 --- a/tests/integration.rs +++ b/tests/integration.rs @@ -19,7 +19,7 @@ fn integration_test() { repo_dir.push(crate_name); let st = Command::new("git") - .args(&[ + .args([ OsStr::new("clone"), OsStr::new("--depth=1"), OsStr::new(&repo_url), @@ -37,7 +37,7 @@ fn integration_test() { .current_dir(repo_dir) .env("RUST_BACKTRACE", "full") .env("CARGO_TARGET_DIR", target_dir) - .args(&[ + .args([ "clippy", "--all-targets", "--all-features", diff --git a/tests/lint_message_convention.rs b/tests/lint_message_convention.rs index c3aae1a9aa2..2e0f4e76075 100644 --- a/tests/lint_message_convention.rs +++ b/tests/lint_message_convention.rs @@ -19,7 +19,7 @@ impl Message { // we don't want the first letter after "error: ", "help: " ... to be capitalized // also no punctuation (except for "?" ?) at the end of a line static REGEX_SET: LazyLock = LazyLock::new(|| { - RegexSet::new(&[ + RegexSet::new([ r"error: [A-Z]", r"help: [A-Z]", r"warning: [A-Z]", @@ -37,7 +37,7 @@ impl Message { // sometimes the first character is capitalized and it is legal (like in "C-like enum variants") or // we want to ask a question ending in "?" static EXCEPTIONS_SET: LazyLock = LazyLock::new(|| { - RegexSet::new(&[ + RegexSet::new([ r"\.\.\.$", r".*C-like enum variant discriminant is not portable to 32-bit targets", r".*Intel x86 assembly syntax used", diff --git a/tests/ui/regex.rs b/tests/ui/regex.rs index f7f3b195ccc..f0e1a8128d7 100644 --- a/tests/ui/regex.rs +++ b/tests/ui/regex.rs @@ -1,4 +1,4 @@ -#![allow(unused)] +#![allow(unused, clippy::needless_borrow)] #![warn(clippy::invalid_regex, clippy::trivial_regex)] extern crate regex; diff --git a/tests/ui/same_item_push.rs b/tests/ui/same_item_push.rs index 99964f0de07..af01a8df71b 100644 --- a/tests/ui/same_item_push.rs +++ b/tests/ui/same_item_push.rs @@ -151,6 +151,7 @@ fn main() { // Fix #6987 let mut vec = Vec::new(); + #[allow(clippy::needless_borrow)] for _ in 0..10 { vec.push(1); vec.extend(&[2]); diff --git a/tests/ui/verbose_file_reads.rs b/tests/ui/verbose_file_reads.rs index e0065e05ade..df267e9872a 100644 --- a/tests/ui/verbose_file_reads.rs +++ b/tests/ui/verbose_file_reads.rs @@ -18,7 +18,7 @@ fn main() -> std::io::Result<()> { s.read_to_end(); s.read_to_string(); // Should catch this - let mut f = File::open(&path)?; + let mut f = File::open(path)?; let mut buffer = Vec::new(); f.read_to_end(&mut buffer)?; // ...and this diff --git a/tests/workspace.rs b/tests/workspace.rs index e13efb3e016..95325e06037 100644 --- a/tests/workspace.rs +++ b/tests/workspace.rs @@ -20,8 +20,8 @@ fn test_no_deps_ignores_path_deps_in_workspaces() { .current_dir(&cwd) .env("CARGO_TARGET_DIR", &target_dir) .arg("clean") - .args(&["-p", "subcrate"]) - .args(&["-p", "path_dep"]) + .args(["-p", "subcrate"]) + .args(["-p", "path_dep"]) .output() .unwrap(); @@ -32,11 +32,11 @@ fn test_no_deps_ignores_path_deps_in_workspaces() { .env("CARGO_INCREMENTAL", "0") .env("CARGO_TARGET_DIR", &target_dir) .arg("clippy") - .args(&["-p", "subcrate"]) + .args(["-p", "subcrate"]) .arg("--no-deps") .arg("--") .arg("-Cdebuginfo=0") // disable debuginfo to generate less data in the target dir - .args(&["--cfg", r#"feature="primary_package_test""#]) + .args(["--cfg", r#"feature="primary_package_test""#]) .output() .unwrap(); println!("status: {}", output.status); @@ -52,10 +52,10 @@ fn test_no_deps_ignores_path_deps_in_workspaces() { .env("CARGO_INCREMENTAL", "0") .env("CARGO_TARGET_DIR", &target_dir) .arg("clippy") - .args(&["-p", "subcrate"]) + .args(["-p", "subcrate"]) .arg("--") .arg("-Cdebuginfo=0") // disable debuginfo to generate less data in the target dir - .args(&["--cfg", r#"feature="primary_package_test""#]) + .args(["--cfg", r#"feature="primary_package_test""#]) .output() .unwrap(); println!("status: {}", output.status); @@ -79,7 +79,7 @@ fn test_no_deps_ignores_path_deps_in_workspaces() { .env("CARGO_INCREMENTAL", "0") .env("CARGO_TARGET_DIR", &target_dir) .arg("clippy") - .args(&["-p", "subcrate"]) + .args(["-p", "subcrate"]) .arg("--") .arg("-Cdebuginfo=0") // disable debuginfo to generate less data in the target dir .output() -- cgit 1.4.1-3-g733a5 From d4a0785464f567c8781f15819f8be74a95b0a3f0 Mon Sep 17 00:00:00 2001 From: Jason Newcomb Date: Wed, 31 Aug 2022 23:24:29 -0400 Subject: Correctly handle unescape warnings --- clippy_dev/src/update_lints.rs | 6 +++++- clippy_lints/src/write.rs | 6 +++++- clippy_utils/src/macros.rs | 6 ++++-- tests/ui/crashes/ice-9405.rs | 11 +++++++++++ tests/ui/crashes/ice-9405.stderr | 11 +++++++++++ 5 files changed, 36 insertions(+), 4 deletions(-) create mode 100644 tests/ui/crashes/ice-9405.rs create mode 100644 tests/ui/crashes/ice-9405.stderr (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/update_lints.rs b/clippy_dev/src/update_lints.rs index c503142e5e4..28bec872c08 100644 --- a/clippy_dev/src/update_lints.rs +++ b/clippy_dev/src/update_lints.rs @@ -977,7 +977,11 @@ fn remove_line_splices(s: &str) -> String { .and_then(|s| s.strip_suffix('"')) .unwrap_or_else(|| panic!("expected quoted string, found `{}`", s)); let mut res = String::with_capacity(s.len()); - unescape::unescape_literal(s, unescape::Mode::Str, &mut |range, _| res.push_str(&s[range])); + unescape::unescape_literal(s, unescape::Mode::Str, &mut |range, ch| { + if ch.is_ok() { + res.push_str(&s[range]); + } + }); res } diff --git a/clippy_lints/src/write.rs b/clippy_lints/src/write.rs index 5533840b166..abd681c5307 100644 --- a/clippy_lints/src/write.rs +++ b/clippy_lints/src/write.rs @@ -805,7 +805,11 @@ fn check_newlines(fmtstr: &StrLit) -> bool { let contents = fmtstr.symbol.as_str(); let mut cb = |r: Range, c: Result| { - let c = c.unwrap(); + let c = match c { + Ok(c) => c, + Err(e) if !e.is_fatal() => return, + Err(e) => panic!("{:?}", e), + }; if r.end == contents.len() && c == '\n' && !last_was_cr && !has_internal_newline { should_lint = true; diff --git a/clippy_utils/src/macros.rs b/clippy_utils/src/macros.rs index e5ca3545540..6b7d5e9aea8 100644 --- a/clippy_utils/src/macros.rs +++ b/clippy_utils/src/macros.rs @@ -389,8 +389,10 @@ impl FormatString { }; let mut unescaped = String::with_capacity(inner.len()); - unescape_literal(inner, mode, &mut |_, ch| { - unescaped.push(ch.unwrap()); + unescape_literal(inner, mode, &mut |_, ch| match ch { + Ok(ch) => unescaped.push(ch), + Err(e) if !e.is_fatal() => (), + Err(e) => panic!("{:?}", e), }); let mut parts = Vec::new(); diff --git a/tests/ui/crashes/ice-9405.rs b/tests/ui/crashes/ice-9405.rs new file mode 100644 index 00000000000..e2d274aeb04 --- /dev/null +++ b/tests/ui/crashes/ice-9405.rs @@ -0,0 +1,11 @@ +#![warn(clippy::useless_format)] +#![allow(clippy::print_literal)] + +fn main() { + println!( + "\ + + {}", + "multiple skipped lines" + ); +} diff --git a/tests/ui/crashes/ice-9405.stderr b/tests/ui/crashes/ice-9405.stderr new file mode 100644 index 00000000000..9a6e410f21e --- /dev/null +++ b/tests/ui/crashes/ice-9405.stderr @@ -0,0 +1,11 @@ +warning: multiple lines skipped by escaped newline + --> $DIR/ice-9405.rs:6:10 + | +LL | "/ + | __________^ +LL | | +LL | | {}", + | |____________^ skipping everything up to and including this point + +warning: 1 warning emitted + -- cgit 1.4.1-3-g733a5 From ad72aee93c80cf2e207e1f728ff0c87336ead695 Mon Sep 17 00:00:00 2001 From: Andre Bogus Date: Sun, 5 Jun 2022 10:44:14 +0200 Subject: add `--explain` subcommand --- clippy_dev/src/update_lints.rs | 188 ++++++- src/docs.rs | 596 +++++++++++++++++++++ src/docs/absurd_extreme_comparisons.txt | 25 + src/docs/alloc_instead_of_core.txt | 18 + src/docs/allow_attributes_without_reason.txt | 22 + src/docs/almost_complete_letter_range.txt | 15 + src/docs/almost_swapped.txt | 15 + src/docs/approx_constant.txt | 24 + src/docs/arithmetic.txt | 28 + src/docs/as_conversions.txt | 32 ++ src/docs/as_underscore.txt | 21 + src/docs/assertions_on_constants.txt | 14 + src/docs/assertions_on_result_states.txt | 14 + src/docs/assign_op_pattern.txt | 28 + src/docs/async_yields_async.txt | 28 + src/docs/await_holding_invalid_type.txt | 29 + src/docs/await_holding_lock.txt | 51 ++ src/docs/await_holding_refcell_ref.txt | 47 ++ src/docs/bad_bit_mask.txt | 30 ++ src/docs/bind_instead_of_map.txt | 22 + src/docs/blanket_clippy_restriction_lints.txt | 16 + src/docs/blocks_in_if_conditions.txt | 21 + src/docs/bool_assert_comparison.txt | 16 + src/docs/bool_comparison.txt | 18 + src/docs/bool_to_int_with_if.txt | 26 + src/docs/borrow_as_ptr.txt | 26 + src/docs/borrow_deref_ref.txt | 27 + src/docs/borrow_interior_mutable_const.txt | 40 ++ src/docs/borrowed_box.txt | 19 + src/docs/box_collection.txt | 23 + src/docs/boxed_local.txt | 18 + src/docs/branches_sharing_code.txt | 32 ++ src/docs/builtin_type_shadow.txt | 15 + src/docs/bytes_count_to_len.txt | 18 + src/docs/bytes_nth.txt | 16 + src/docs/cargo_common_metadata.txt | 33 ++ .../case_sensitive_file_extension_comparisons.txt | 21 + src/docs/cast_abs_to_unsigned.txt | 16 + src/docs/cast_enum_constructor.txt | 11 + src/docs/cast_enum_truncation.txt | 12 + src/docs/cast_lossless.txt | 26 + src/docs/cast_possible_truncation.txt | 16 + src/docs/cast_possible_wrap.txt | 17 + src/docs/cast_precision_loss.txt | 19 + src/docs/cast_ptr_alignment.txt | 21 + src/docs/cast_ref_to_mut.txt | 28 + src/docs/cast_sign_loss.txt | 15 + src/docs/cast_slice_different_sizes.txt | 38 ++ src/docs/cast_slice_from_raw_parts.txt | 20 + src/docs/char_lit_as_u8.txt | 21 + src/docs/chars_last_cmp.txt | 17 + src/docs/chars_next_cmp.txt | 19 + src/docs/checked_conversions.txt | 15 + src/docs/clone_double_ref.txt | 16 + src/docs/clone_on_copy.txt | 11 + src/docs/clone_on_ref_ptr.txt | 21 + src/docs/cloned_instead_of_copied.txt | 16 + src/docs/cmp_nan.txt | 16 + src/docs/cmp_null.txt | 23 + src/docs/cmp_owned.txt | 18 + src/docs/cognitive_complexity.txt | 13 + src/docs/collapsible_else_if.txt | 29 + src/docs/collapsible_if.txt | 23 + src/docs/collapsible_match.txt | 31 ++ src/docs/collapsible_str_replace.txt | 19 + src/docs/comparison_chain.txt | 36 ++ src/docs/comparison_to_empty.txt | 31 ++ src/docs/copy_iterator.txt | 20 + src/docs/crate_in_macro_def.txt | 35 ++ src/docs/create_dir.txt | 15 + src/docs/crosspointer_transmute.txt | 12 + src/docs/dbg_macro.txt | 16 + src/docs/debug_assert_with_mut_call.txt | 18 + src/docs/decimal_literal_representation.txt | 13 + src/docs/declare_interior_mutable_const.txt | 46 ++ src/docs/default_instead_of_iter_empty.txt | 15 + src/docs/default_numeric_fallback.txt | 28 + src/docs/default_trait_access.txt | 16 + src/docs/default_union_representation.txt | 36 ++ src/docs/deprecated_cfg_attr.txt | 24 + src/docs/deprecated_semver.txt | 13 + src/docs/deref_addrof.txt | 22 + src/docs/deref_by_slicing.txt | 17 + src/docs/derivable_impls.txt | 35 ++ src/docs/derive_hash_xor_eq.txt | 23 + src/docs/derive_ord_xor_partial_ord.txt | 44 ++ src/docs/derive_partial_eq_without_eq.txt | 25 + src/docs/disallowed_methods.txt | 41 ++ src/docs/disallowed_names.txt | 12 + src/docs/disallowed_script_idents.txt | 32 ++ src/docs/disallowed_types.txt | 33 ++ src/docs/diverging_sub_expression.txt | 19 + src/docs/doc_link_with_quotes.txt | 16 + src/docs/doc_markdown.txt | 35 ++ src/docs/double_comparisons.txt | 17 + src/docs/double_must_use.txt | 17 + src/docs/double_neg.txt | 12 + src/docs/double_parens.txt | 24 + src/docs/drop_copy.txt | 15 + src/docs/drop_non_drop.txt | 13 + src/docs/drop_ref.txt | 17 + src/docs/duplicate_mod.txt | 31 ++ src/docs/duplicate_underscore_argument.txt | 16 + src/docs/duration_subsec.txt | 19 + src/docs/else_if_without_else.txt | 27 + src/docs/empty_drop.txt | 20 + src/docs/empty_enum.txt | 27 + src/docs/empty_line_after_outer_attr.txt | 35 ++ src/docs/empty_loop.txt | 27 + src/docs/empty_structs_with_brackets.txt | 14 + src/docs/enum_clike_unportable_variant.txt | 16 + src/docs/enum_glob_use.txt | 24 + src/docs/enum_variant_names.txt | 30 ++ src/docs/eq_op.txt | 22 + src/docs/equatable_if_let.txt | 23 + src/docs/erasing_op.txt | 15 + src/docs/err_expect.txt | 16 + src/docs/excessive_precision.txt | 18 + src/docs/exhaustive_enums.txt | 23 + src/docs/exhaustive_structs.txt | 23 + src/docs/exit.txt | 12 + src/docs/expect_fun_call.txt | 24 + src/docs/expect_used.txt | 26 + src/docs/expl_impl_clone_on_copy.txt | 20 + src/docs/explicit_auto_deref.txt | 16 + src/docs/explicit_counter_loop.txt | 21 + src/docs/explicit_deref_methods.txt | 24 + src/docs/explicit_into_iter_loop.txt | 20 + src/docs/explicit_iter_loop.txt | 25 + src/docs/explicit_write.txt | 18 + src/docs/extend_with_drain.txt | 21 + src/docs/extra_unused_lifetimes.txt | 23 + src/docs/fallible_impl_from.txt | 32 ++ src/docs/field_reassign_with_default.txt | 23 + src/docs/filetype_is_file.txt | 29 + src/docs/filter_map_identity.txt | 14 + src/docs/filter_map_next.txt | 16 + src/docs/filter_next.txt | 16 + src/docs/flat_map_identity.txt | 14 + src/docs/flat_map_option.txt | 16 + src/docs/float_arithmetic.txt | 11 + src/docs/float_cmp.txt | 28 + src/docs/float_cmp_const.txt | 26 + src/docs/float_equality_without_abs.txt | 26 + src/docs/fn_address_comparisons.txt | 17 + src/docs/fn_params_excessive_bools.txt | 31 ++ src/docs/fn_to_numeric_cast.txt | 21 + src/docs/fn_to_numeric_cast_any.txt | 35 ++ src/docs/fn_to_numeric_cast_with_truncation.txt | 26 + src/docs/for_kv_map.txt | 22 + src/docs/for_loops_over_fallibles.txt | 32 ++ src/docs/forget_copy.txt | 21 + src/docs/forget_non_drop.txt | 13 + src/docs/forget_ref.txt | 15 + src/docs/format_in_format_args.txt | 16 + src/docs/format_push_string.txt | 26 + src/docs/from_iter_instead_of_collect.txt | 24 + src/docs/from_over_into.txt | 26 + src/docs/from_str_radix_10.txt | 25 + src/docs/future_not_send.txt | 29 + src/docs/get_first.txt | 19 + src/docs/get_last_with_len.txt | 26 + src/docs/get_unwrap.txt | 30 ++ src/docs/identity_op.txt | 11 + src/docs/if_let_mutex.txt | 25 + src/docs/if_not_else.txt | 25 + src/docs/if_same_then_else.txt | 15 + src/docs/if_then_some_else_none.txt | 26 + src/docs/ifs_same_cond.txt | 25 + src/docs/implicit_clone.txt | 19 + src/docs/implicit_hasher.txt | 26 + src/docs/implicit_return.txt | 22 + src/docs/implicit_saturating_sub.txt | 21 + src/docs/imprecise_flops.txt | 23 + src/docs/inconsistent_digit_grouping.txt | 17 + src/docs/inconsistent_struct_constructor.txt | 40 ++ src/docs/index_refutable_slice.txt | 29 + src/docs/indexing_slicing.txt | 33 ++ src/docs/ineffective_bit_mask.txt | 25 + src/docs/inefficient_to_string.txt | 17 + src/docs/infallible_destructuring_match.txt | 29 + src/docs/infinite_iter.txt | 13 + src/docs/inherent_to_string.txt | 29 + src/docs/inherent_to_string_shadow_display.txt | 37 ++ src/docs/init_numbered_fields.txt | 24 + src/docs/inline_always.txt | 23 + src/docs/inline_asm_x86_att_syntax.txt | 16 + src/docs/inline_asm_x86_intel_syntax.txt | 16 + src/docs/inline_fn_without_body.txt | 14 + src/docs/inspect_for_each.txt | 23 + src/docs/int_plus_one.txt | 15 + src/docs/integer_arithmetic.txt | 18 + src/docs/integer_division.txt | 19 + src/docs/into_iter_on_ref.txt | 18 + src/docs/invalid_null_ptr_usage.txt | 16 + src/docs/invalid_regex.txt | 12 + src/docs/invalid_upcast_comparisons.txt | 18 + src/docs/invalid_utf8_in_unchecked.txt | 12 + src/docs/invisible_characters.txt | 10 + src/docs/is_digit_ascii_radix.txt | 20 + src/docs/items_after_statements.txt | 37 ++ src/docs/iter_cloned_collect.txt | 17 + src/docs/iter_count.txt | 22 + src/docs/iter_next_loop.txt | 17 + src/docs/iter_next_slice.txt | 16 + src/docs/iter_not_returning_iterator.txt | 26 + src/docs/iter_nth.txt | 20 + src/docs/iter_nth_zero.txt | 17 + src/docs/iter_on_empty_collections.txt | 25 + src/docs/iter_on_single_items.txt | 24 + src/docs/iter_overeager_cloned.txt | 22 + src/docs/iter_skip_next.txt | 18 + src/docs/iter_with_drain.txt | 16 + src/docs/iterator_step_by_zero.txt | 13 + src/docs/just_underscores_and_digits.txt | 14 + src/docs/large_const_arrays.txt | 17 + src/docs/large_digit_groups.txt | 12 + src/docs/large_enum_variant.txt | 40 ++ src/docs/large_include_file.txt | 21 + src/docs/large_stack_arrays.txt | 10 + src/docs/large_types_passed_by_value.txt | 24 + src/docs/len_without_is_empty.txt | 19 + src/docs/len_zero.txt | 28 + src/docs/let_and_return.txt | 21 + src/docs/let_underscore_drop.txt | 29 + src/docs/let_underscore_lock.txt | 20 + src/docs/let_underscore_must_use.txt | 17 + src/docs/let_unit_value.txt | 13 + src/docs/linkedlist.txt | 32 ++ src/docs/lossy_float_literal.txt | 18 + src/docs/macro_use_imports.txt | 12 + src/docs/main_recursion.txt | 13 + src/docs/manual_assert.txt | 18 + src/docs/manual_async_fn.txt | 16 + src/docs/manual_bits.txt | 15 + src/docs/manual_filter_map.txt | 19 + src/docs/manual_find.txt | 24 + src/docs/manual_find_map.txt | 19 + src/docs/manual_flatten.txt | 25 + src/docs/manual_instant_elapsed.txt | 21 + src/docs/manual_map.txt | 17 + src/docs/manual_memcpy.txt | 18 + src/docs/manual_non_exhaustive.txt | 41 ++ src/docs/manual_ok_or.txt | 19 + src/docs/manual_range_contains.txt | 19 + src/docs/manual_rem_euclid.txt | 17 + src/docs/manual_retain.txt | 15 + src/docs/manual_saturating_arithmetic.txt | 18 + src/docs/manual_split_once.txt | 29 + src/docs/manual_str_repeat.txt | 15 + src/docs/manual_string_new.txt | 20 + src/docs/manual_strip.txt | 24 + src/docs/manual_swap.txt | 22 + src/docs/manual_unwrap_or.txt | 20 + src/docs/many_single_char_names.txt | 12 + src/docs/map_clone.txt | 22 + src/docs/map_collect_result_unit.txt | 14 + src/docs/map_entry.txt | 28 + src/docs/map_err_ignore.txt | 93 ++++ src/docs/map_flatten.txt | 21 + src/docs/map_identity.txt | 16 + src/docs/map_unwrap_or.txt | 22 + src/docs/match_as_ref.txt | 23 + src/docs/match_bool.txt | 24 + src/docs/match_like_matches_macro.txt | 32 ++ src/docs/match_on_vec_items.txt | 29 + src/docs/match_overlapping_arm.txt | 16 + src/docs/match_ref_pats.txt | 26 + src/docs/match_result_ok.txt | 27 + src/docs/match_same_arms.txt | 38 ++ src/docs/match_single_binding.txt | 23 + src/docs/match_str_case_mismatch.txt | 22 + src/docs/match_wild_err_arm.txt | 16 + src/docs/match_wildcard_for_single_variants.txt | 27 + src/docs/maybe_infinite_iter.txt | 16 + src/docs/mem_forget.txt | 12 + src/docs/mem_replace_option_with_none.txt | 21 + src/docs/mem_replace_with_default.txt | 18 + src/docs/mem_replace_with_uninit.txt | 24 + src/docs/min_max.txt | 18 + src/docs/mismatched_target_os.txt | 24 + src/docs/mismatching_type_param_order.txt | 33 ++ src/docs/misrefactored_assign_op.txt | 20 + src/docs/missing_const_for_fn.txt | 40 ++ src/docs/missing_docs_in_private_items.txt | 9 + src/docs/missing_enforced_import_renames.txt | 22 + src/docs/missing_errors_doc.txt | 21 + src/docs/missing_inline_in_public_items.txt | 45 ++ src/docs/missing_panics_doc.txt | 24 + src/docs/missing_safety_doc.txt | 26 + src/docs/missing_spin_loop.txt | 27 + src/docs/mistyped_literal_suffixes.txt | 15 + src/docs/mixed_case_hex_literals.txt | 16 + src/docs/mixed_read_write_in_expression.txt | 32 ++ src/docs/mod_module_files.txt | 22 + src/docs/module_inception.txt | 24 + src/docs/module_name_repetitions.txt | 20 + src/docs/modulo_arithmetic.txt | 15 + src/docs/modulo_one.txt | 16 + src/docs/multi_assignments.txt | 17 + src/docs/multiple_crate_versions.txt | 19 + src/docs/multiple_inherent_impl.txt | 26 + src/docs/must_use_candidate.txt | 23 + src/docs/must_use_unit.txt | 13 + src/docs/mut_from_ref.txt | 26 + src/docs/mut_mut.txt | 12 + src/docs/mut_mutex_lock.txt | 29 + src/docs/mut_range_bound.txt | 29 + src/docs/mutable_key_type.txt | 61 +++ src/docs/mutex_atomic.txt | 22 + src/docs/mutex_integer.txt | 22 + src/docs/naive_bytecount.txt | 22 + src/docs/needless_arbitrary_self_type.txt | 44 ++ src/docs/needless_bitwise_bool.txt | 22 + src/docs/needless_bool.txt | 26 + src/docs/needless_borrow.txt | 21 + src/docs/needless_borrowed_reference.txt | 30 ++ src/docs/needless_collect.txt | 14 + src/docs/needless_continue.txt | 61 +++ src/docs/needless_doctest_main.txt | 22 + src/docs/needless_for_each.txt | 24 + src/docs/needless_late_init.txt | 42 ++ src/docs/needless_lifetimes.txt | 29 + src/docs/needless_match.txt | 36 ++ src/docs/needless_option_as_deref.txt | 18 + src/docs/needless_option_take.txt | 17 + src/docs/needless_parens_on_range_literals.txt | 23 + src/docs/needless_pass_by_value.txt | 27 + src/docs/needless_question_mark.txt | 43 ++ src/docs/needless_range_loop.txt | 23 + src/docs/needless_return.txt | 19 + src/docs/needless_splitn.txt | 16 + src/docs/needless_update.txt | 30 ++ src/docs/neg_cmp_op_on_partial_ord.txt | 26 + src/docs/neg_multiply.txt | 18 + src/docs/negative_feature_names.txt | 22 + src/docs/never_loop.txt | 15 + src/docs/new_ret_no_self.txt | 47 ++ src/docs/new_without_default.txt | 32 ++ src/docs/no_effect.txt | 12 + src/docs/no_effect_replace.txt | 11 + src/docs/no_effect_underscore_binding.txt | 16 + src/docs/non_ascii_literal.txt | 19 + src/docs/non_octal_unix_permissions.txt | 23 + src/docs/non_send_fields_in_send_ty.txt | 36 ++ src/docs/nonminimal_bool.txt | 23 + src/docs/nonsensical_open_options.txt | 14 + src/docs/nonstandard_macro_braces.txt | 15 + src/docs/not_unsafe_ptr_arg_deref.txt | 30 ++ src/docs/obfuscated_if_else.txt | 21 + src/docs/octal_escapes.txt | 33 ++ src/docs/ok_expect.txt | 19 + src/docs/only_used_in_recursion.txt | 58 ++ src/docs/op_ref.txt | 17 + src/docs/option_as_ref_deref.txt | 15 + src/docs/option_env_unwrap.txt | 19 + src/docs/option_filter_map.txt | 15 + src/docs/option_if_let_else.txt | 46 ++ src/docs/option_map_or_none.txt | 19 + src/docs/option_map_unit_fn.txt | 27 + src/docs/option_option.txt | 32 ++ src/docs/or_fun_call.txt | 26 + src/docs/or_then_unwrap.txt | 22 + src/docs/out_of_bounds_indexing.txt | 22 + src/docs/overflow_check_conditional.txt | 11 + src/docs/overly_complex_bool_expr.txt | 20 + src/docs/panic.txt | 10 + src/docs/panic_in_result_fn.txt | 22 + src/docs/panicking_unwrap.txt | 18 + src/docs/partialeq_ne_impl.txt | 18 + src/docs/partialeq_to_none.txt | 24 + src/docs/path_buf_push_overwrite.txt | 25 + src/docs/pattern_type_mismatch.txt | 64 +++ src/docs/positional_named_format_parameters.txt | 15 + src/docs/possible_missing_comma.txt | 14 + src/docs/precedence.txt | 17 + src/docs/print_in_format_impl.txt | 34 ++ src/docs/print_literal.txt | 20 + src/docs/print_stderr.txt | 21 + src/docs/print_stdout.txt | 21 + src/docs/print_with_newline.txt | 16 + src/docs/println_empty_string.txt | 16 + src/docs/ptr_arg.txt | 29 + src/docs/ptr_as_ptr.txt | 22 + src/docs/ptr_eq.txt | 22 + src/docs/ptr_offset_with_cast.txt | 30 ++ src/docs/pub_use.txt | 28 + src/docs/question_mark.txt | 18 + src/docs/range_minus_one.txt | 27 + src/docs/range_plus_one.txt | 36 ++ src/docs/range_zip_with_len.txt | 16 + src/docs/rc_buffer.txt | 27 + src/docs/rc_clone_in_vec_init.txt | 29 + src/docs/rc_mutex.txt | 26 + src/docs/read_zero_byte_vec.txt | 30 ++ src/docs/recursive_format_impl.txt | 32 ++ src/docs/redundant_allocation.txt | 17 + src/docs/redundant_clone.txt | 23 + src/docs/redundant_closure.txt | 25 + src/docs/redundant_closure_call.txt | 17 + src/docs/redundant_closure_for_method_calls.txt | 15 + src/docs/redundant_else.txt | 30 ++ src/docs/redundant_feature_names.txt | 23 + src/docs/redundant_field_names.txt | 22 + src/docs/redundant_pattern.txt | 22 + src/docs/redundant_pattern_matching.txt | 45 ++ src/docs/redundant_pub_crate.txt | 21 + src/docs/redundant_slicing.txt | 24 + src/docs/redundant_static_lifetimes.txt | 19 + src/docs/ref_binding_to_reference.txt | 21 + src/docs/ref_option_ref.txt | 19 + src/docs/repeat_once.txt | 25 + src/docs/rest_pat_in_fully_bound_structs.txt | 24 + src/docs/result_large_err.txt | 36 ++ src/docs/result_map_or_into_option.txt | 16 + src/docs/result_map_unit_fn.txt | 26 + src/docs/result_unit_err.txt | 40 ++ src/docs/return_self_not_must_use.txt | 46 ++ src/docs/reversed_empty_ranges.txt | 26 + src/docs/same_functions_in_if_condition.txt | 41 ++ src/docs/same_item_push.txt | 29 + src/docs/same_name_method.txt | 23 + src/docs/search_is_some.txt | 24 + src/docs/self_assignment.txt | 32 ++ src/docs/self_named_constructors.txt | 26 + src/docs/self_named_module_files.txt | 22 + src/docs/semicolon_if_nothing_returned.txt | 20 + src/docs/separated_literal_suffix.txt | 17 + src/docs/serde_api_misuse.txt | 10 + src/docs/shadow_reuse.txt | 20 + src/docs/shadow_same.txt | 18 + src/docs/shadow_unrelated.txt | 22 + src/docs/short_circuit_statement.txt | 14 + src/docs/should_implement_trait.txt | 22 + src/docs/significant_drop_in_scrutinee.txt | 43 ++ src/docs/similar_names.txt | 12 + src/docs/single_char_add_str.txt | 18 + src/docs/single_char_lifetime_names.txt | 28 + src/docs/single_char_pattern.txt | 20 + src/docs/single_component_path_imports.txt | 21 + src/docs/single_element_loop.txt | 21 + src/docs/single_match.txt | 21 + src/docs/single_match_else.txt | 29 + src/docs/size_of_in_element_count.txt | 16 + src/docs/skip_while_next.txt | 16 + src/docs/slow_vector_initialization.txt | 24 + src/docs/stable_sort_primitive.txt | 31 ++ src/docs/std_instead_of_alloc.txt | 18 + src/docs/std_instead_of_core.txt | 18 + src/docs/str_to_string.txt | 18 + src/docs/string_add.txt | 27 + src/docs/string_add_assign.txt | 17 + src/docs/string_extend_chars.txt | 23 + src/docs/string_from_utf8_as_bytes.txt | 15 + src/docs/string_lit_as_bytes.txt | 39 ++ src/docs/string_slice.txt | 17 + src/docs/string_to_string.txt | 19 + src/docs/strlen_on_c_strings.txt | 20 + src/docs/struct_excessive_bools.txt | 29 + src/docs/suboptimal_flops.txt | 50 ++ src/docs/suspicious_arithmetic_impl.txt | 17 + src/docs/suspicious_assignment_formatting.txt | 12 + src/docs/suspicious_else_formatting.txt | 30 ++ src/docs/suspicious_map.txt | 13 + src/docs/suspicious_op_assign_impl.txt | 15 + src/docs/suspicious_operation_groupings.txt | 41 ++ src/docs/suspicious_splitn.txt | 22 + src/docs/suspicious_to_owned.txt | 39 ++ src/docs/suspicious_unary_op_formatting.txt | 18 + src/docs/swap_ptr_to_ref.txt | 23 + src/docs/tabs_in_doc_comments.txt | 44 ++ src/docs/temporary_assignment.txt | 12 + src/docs/to_digit_is_some.txt | 15 + src/docs/to_string_in_format_args.txt | 17 + src/docs/todo.txt | 10 + src/docs/too_many_arguments.txt | 14 + src/docs/too_many_lines.txt | 17 + src/docs/toplevel_ref_arg.txt | 28 + src/docs/trailing_empty_array.txt | 22 + src/docs/trait_duplication_in_bounds.txt | 37 ++ src/docs/transmute_bytes_to_str.txt | 27 + src/docs/transmute_float_to_int.txt | 16 + src/docs/transmute_int_to_bool.txt | 16 + src/docs/transmute_int_to_char.txt | 27 + src/docs/transmute_int_to_float.txt | 16 + src/docs/transmute_num_to_bytes.txt | 16 + src/docs/transmute_ptr_to_ptr.txt | 21 + src/docs/transmute_ptr_to_ref.txt | 21 + src/docs/transmute_undefined_repr.txt | 22 + src/docs/transmutes_expressible_as_ptr_casts.txt | 16 + src/docs/transmuting_null.txt | 15 + src/docs/trim_split_whitespace.txt | 14 + src/docs/trivial_regex.txt | 18 + src/docs/trivially_copy_pass_by_ref.txt | 43 ++ src/docs/try_err.txt | 28 + src/docs/type_complexity.txt | 14 + src/docs/type_repetition_in_bounds.txt | 16 + src/docs/undocumented_unsafe_blocks.txt | 43 ++ src/docs/undropped_manually_drops.txt | 22 + src/docs/unicode_not_nfc.txt | 12 + src/docs/unimplemented.txt | 10 + src/docs/uninit_assumed_init.txt | 28 + src/docs/uninit_vec.txt | 41 ++ src/docs/unit_arg.txt | 14 + src/docs/unit_cmp.txt | 33 ++ src/docs/unit_hash.txt | 20 + src/docs/unit_return_expecting_ord.txt | 20 + src/docs/unnecessary_cast.txt | 19 + src/docs/unnecessary_filter_map.txt | 23 + src/docs/unnecessary_find_map.txt | 23 + src/docs/unnecessary_fold.txt | 17 + src/docs/unnecessary_join.txt | 25 + src/docs/unnecessary_lazy_evaluations.txt | 32 ++ src/docs/unnecessary_mut_passed.txt | 17 + src/docs/unnecessary_operation.txt | 12 + src/docs/unnecessary_owned_empty_strings.txt | 16 + src/docs/unnecessary_self_imports.txt | 19 + src/docs/unnecessary_sort_by.txt | 21 + src/docs/unnecessary_to_owned.txt | 24 + src/docs/unnecessary_unwrap.txt | 20 + src/docs/unnecessary_wraps.txt | 36 ++ src/docs/unneeded_field_pattern.txt | 26 + src/docs/unneeded_wildcard_pattern.txt | 28 + src/docs/unnested_or_patterns.txt | 22 + src/docs/unreachable.txt | 10 + src/docs/unreadable_literal.txt | 16 + src/docs/unsafe_derive_deserialize.txt | 27 + src/docs/unsafe_removed_from_name.txt | 15 + src/docs/unseparated_literal_suffix.txt | 18 + src/docs/unsound_collection_transmute.txt | 25 + src/docs/unused_async.txt | 23 + src/docs/unused_io_amount.txt | 31 ++ src/docs/unused_peekable.txt | 26 + src/docs/unused_rounding.txt | 17 + src/docs/unused_self.txt | 23 + src/docs/unused_unit.txt | 18 + src/docs/unusual_byte_groupings.txt | 12 + src/docs/unwrap_in_result.txt | 39 ++ src/docs/unwrap_or_else_default.txt | 18 + src/docs/unwrap_used.txt | 37 ++ src/docs/upper_case_acronyms.txt | 25 + src/docs/use_debug.txt | 12 + src/docs/use_self.txt | 31 ++ src/docs/used_underscore_binding.txt | 19 + src/docs/useless_asref.txt | 17 + src/docs/useless_attribute.txt | 36 ++ src/docs/useless_conversion.txt | 17 + src/docs/useless_format.txt | 22 + src/docs/useless_let_if_seq.txt | 39 ++ src/docs/useless_transmute.txt | 12 + src/docs/useless_vec.txt | 18 + src/docs/vec_box.txt | 26 + src/docs/vec_init_then_push.txt | 23 + src/docs/vec_resize_to_zero.txt | 15 + src/docs/verbose_bit_mask.txt | 15 + src/docs/verbose_file_reads.txt | 17 + src/docs/vtable_address_comparisons.txt | 17 + src/docs/while_immutable_condition.txt | 20 + src/docs/while_let_loop.txt | 25 + src/docs/while_let_on_iterator.txt | 20 + src/docs/wildcard_dependencies.txt | 13 + src/docs/wildcard_enum_match_arm.txt | 25 + src/docs/wildcard_imports.txt | 45 ++ src/docs/wildcard_in_or_patterns.txt | 22 + src/docs/write_literal.txt | 21 + src/docs/write_with_newline.txt | 18 + src/docs/writeln_empty_string.txt | 16 + src/docs/wrong_self_convention.txt | 39 ++ src/docs/wrong_transmute.txt | 15 + src/docs/zero_divided_by_zero.txt | 15 + src/docs/zero_prefixed_literal.txt | 32 ++ src/docs/zero_ptr.txt | 16 + src/docs/zero_sized_map_values.txt | 24 + src/docs/zst_offset.txt | 11 + src/main.rs | 13 + 575 files changed, 13817 insertions(+), 28 deletions(-) create mode 100644 src/docs.rs create mode 100644 src/docs/absurd_extreme_comparisons.txt create mode 100644 src/docs/alloc_instead_of_core.txt create mode 100644 src/docs/allow_attributes_without_reason.txt create mode 100644 src/docs/almost_complete_letter_range.txt create mode 100644 src/docs/almost_swapped.txt create mode 100644 src/docs/approx_constant.txt create mode 100644 src/docs/arithmetic.txt create mode 100644 src/docs/as_conversions.txt create mode 100644 src/docs/as_underscore.txt create mode 100644 src/docs/assertions_on_constants.txt create mode 100644 src/docs/assertions_on_result_states.txt create mode 100644 src/docs/assign_op_pattern.txt create mode 100644 src/docs/async_yields_async.txt create mode 100644 src/docs/await_holding_invalid_type.txt create mode 100644 src/docs/await_holding_lock.txt create mode 100644 src/docs/await_holding_refcell_ref.txt create mode 100644 src/docs/bad_bit_mask.txt create mode 100644 src/docs/bind_instead_of_map.txt create mode 100644 src/docs/blanket_clippy_restriction_lints.txt create mode 100644 src/docs/blocks_in_if_conditions.txt create mode 100644 src/docs/bool_assert_comparison.txt create mode 100644 src/docs/bool_comparison.txt create mode 100644 src/docs/bool_to_int_with_if.txt create mode 100644 src/docs/borrow_as_ptr.txt create mode 100644 src/docs/borrow_deref_ref.txt create mode 100644 src/docs/borrow_interior_mutable_const.txt create mode 100644 src/docs/borrowed_box.txt create mode 100644 src/docs/box_collection.txt create mode 100644 src/docs/boxed_local.txt create mode 100644 src/docs/branches_sharing_code.txt create mode 100644 src/docs/builtin_type_shadow.txt create mode 100644 src/docs/bytes_count_to_len.txt create mode 100644 src/docs/bytes_nth.txt create mode 100644 src/docs/cargo_common_metadata.txt create mode 100644 src/docs/case_sensitive_file_extension_comparisons.txt create mode 100644 src/docs/cast_abs_to_unsigned.txt create mode 100644 src/docs/cast_enum_constructor.txt create mode 100644 src/docs/cast_enum_truncation.txt create mode 100644 src/docs/cast_lossless.txt create mode 100644 src/docs/cast_possible_truncation.txt create mode 100644 src/docs/cast_possible_wrap.txt create mode 100644 src/docs/cast_precision_loss.txt create mode 100644 src/docs/cast_ptr_alignment.txt create mode 100644 src/docs/cast_ref_to_mut.txt create mode 100644 src/docs/cast_sign_loss.txt create mode 100644 src/docs/cast_slice_different_sizes.txt create mode 100644 src/docs/cast_slice_from_raw_parts.txt create mode 100644 src/docs/char_lit_as_u8.txt create mode 100644 src/docs/chars_last_cmp.txt create mode 100644 src/docs/chars_next_cmp.txt create mode 100644 src/docs/checked_conversions.txt create mode 100644 src/docs/clone_double_ref.txt create mode 100644 src/docs/clone_on_copy.txt create mode 100644 src/docs/clone_on_ref_ptr.txt create mode 100644 src/docs/cloned_instead_of_copied.txt create mode 100644 src/docs/cmp_nan.txt create mode 100644 src/docs/cmp_null.txt create mode 100644 src/docs/cmp_owned.txt create mode 100644 src/docs/cognitive_complexity.txt create mode 100644 src/docs/collapsible_else_if.txt create mode 100644 src/docs/collapsible_if.txt create mode 100644 src/docs/collapsible_match.txt create mode 100644 src/docs/collapsible_str_replace.txt create mode 100644 src/docs/comparison_chain.txt create mode 100644 src/docs/comparison_to_empty.txt create mode 100644 src/docs/copy_iterator.txt create mode 100644 src/docs/crate_in_macro_def.txt create mode 100644 src/docs/create_dir.txt create mode 100644 src/docs/crosspointer_transmute.txt create mode 100644 src/docs/dbg_macro.txt create mode 100644 src/docs/debug_assert_with_mut_call.txt create mode 100644 src/docs/decimal_literal_representation.txt create mode 100644 src/docs/declare_interior_mutable_const.txt create mode 100644 src/docs/default_instead_of_iter_empty.txt create mode 100644 src/docs/default_numeric_fallback.txt create mode 100644 src/docs/default_trait_access.txt create mode 100644 src/docs/default_union_representation.txt create mode 100644 src/docs/deprecated_cfg_attr.txt create mode 100644 src/docs/deprecated_semver.txt create mode 100644 src/docs/deref_addrof.txt create mode 100644 src/docs/deref_by_slicing.txt create mode 100644 src/docs/derivable_impls.txt create mode 100644 src/docs/derive_hash_xor_eq.txt create mode 100644 src/docs/derive_ord_xor_partial_ord.txt create mode 100644 src/docs/derive_partial_eq_without_eq.txt create mode 100644 src/docs/disallowed_methods.txt create mode 100644 src/docs/disallowed_names.txt create mode 100644 src/docs/disallowed_script_idents.txt create mode 100644 src/docs/disallowed_types.txt create mode 100644 src/docs/diverging_sub_expression.txt create mode 100644 src/docs/doc_link_with_quotes.txt create mode 100644 src/docs/doc_markdown.txt create mode 100644 src/docs/double_comparisons.txt create mode 100644 src/docs/double_must_use.txt create mode 100644 src/docs/double_neg.txt create mode 100644 src/docs/double_parens.txt create mode 100644 src/docs/drop_copy.txt create mode 100644 src/docs/drop_non_drop.txt create mode 100644 src/docs/drop_ref.txt create mode 100644 src/docs/duplicate_mod.txt create mode 100644 src/docs/duplicate_underscore_argument.txt create mode 100644 src/docs/duration_subsec.txt create mode 100644 src/docs/else_if_without_else.txt create mode 100644 src/docs/empty_drop.txt create mode 100644 src/docs/empty_enum.txt create mode 100644 src/docs/empty_line_after_outer_attr.txt create mode 100644 src/docs/empty_loop.txt create mode 100644 src/docs/empty_structs_with_brackets.txt create mode 100644 src/docs/enum_clike_unportable_variant.txt create mode 100644 src/docs/enum_glob_use.txt create mode 100644 src/docs/enum_variant_names.txt create mode 100644 src/docs/eq_op.txt create mode 100644 src/docs/equatable_if_let.txt create mode 100644 src/docs/erasing_op.txt create mode 100644 src/docs/err_expect.txt create mode 100644 src/docs/excessive_precision.txt create mode 100644 src/docs/exhaustive_enums.txt create mode 100644 src/docs/exhaustive_structs.txt create mode 100644 src/docs/exit.txt create mode 100644 src/docs/expect_fun_call.txt create mode 100644 src/docs/expect_used.txt create mode 100644 src/docs/expl_impl_clone_on_copy.txt create mode 100644 src/docs/explicit_auto_deref.txt create mode 100644 src/docs/explicit_counter_loop.txt create mode 100644 src/docs/explicit_deref_methods.txt create mode 100644 src/docs/explicit_into_iter_loop.txt create mode 100644 src/docs/explicit_iter_loop.txt create mode 100644 src/docs/explicit_write.txt create mode 100644 src/docs/extend_with_drain.txt create mode 100644 src/docs/extra_unused_lifetimes.txt create mode 100644 src/docs/fallible_impl_from.txt create mode 100644 src/docs/field_reassign_with_default.txt create mode 100644 src/docs/filetype_is_file.txt create mode 100644 src/docs/filter_map_identity.txt create mode 100644 src/docs/filter_map_next.txt create mode 100644 src/docs/filter_next.txt create mode 100644 src/docs/flat_map_identity.txt create mode 100644 src/docs/flat_map_option.txt create mode 100644 src/docs/float_arithmetic.txt create mode 100644 src/docs/float_cmp.txt create mode 100644 src/docs/float_cmp_const.txt create mode 100644 src/docs/float_equality_without_abs.txt create mode 100644 src/docs/fn_address_comparisons.txt create mode 100644 src/docs/fn_params_excessive_bools.txt create mode 100644 src/docs/fn_to_numeric_cast.txt create mode 100644 src/docs/fn_to_numeric_cast_any.txt create mode 100644 src/docs/fn_to_numeric_cast_with_truncation.txt create mode 100644 src/docs/for_kv_map.txt create mode 100644 src/docs/for_loops_over_fallibles.txt create mode 100644 src/docs/forget_copy.txt create mode 100644 src/docs/forget_non_drop.txt create mode 100644 src/docs/forget_ref.txt create mode 100644 src/docs/format_in_format_args.txt create mode 100644 src/docs/format_push_string.txt create mode 100644 src/docs/from_iter_instead_of_collect.txt create mode 100644 src/docs/from_over_into.txt create mode 100644 src/docs/from_str_radix_10.txt create mode 100644 src/docs/future_not_send.txt create mode 100644 src/docs/get_first.txt create mode 100644 src/docs/get_last_with_len.txt create mode 100644 src/docs/get_unwrap.txt create mode 100644 src/docs/identity_op.txt create mode 100644 src/docs/if_let_mutex.txt create mode 100644 src/docs/if_not_else.txt create mode 100644 src/docs/if_same_then_else.txt create mode 100644 src/docs/if_then_some_else_none.txt create mode 100644 src/docs/ifs_same_cond.txt create mode 100644 src/docs/implicit_clone.txt create mode 100644 src/docs/implicit_hasher.txt create mode 100644 src/docs/implicit_return.txt create mode 100644 src/docs/implicit_saturating_sub.txt create mode 100644 src/docs/imprecise_flops.txt create mode 100644 src/docs/inconsistent_digit_grouping.txt create mode 100644 src/docs/inconsistent_struct_constructor.txt create mode 100644 src/docs/index_refutable_slice.txt create mode 100644 src/docs/indexing_slicing.txt create mode 100644 src/docs/ineffective_bit_mask.txt create mode 100644 src/docs/inefficient_to_string.txt create mode 100644 src/docs/infallible_destructuring_match.txt create mode 100644 src/docs/infinite_iter.txt create mode 100644 src/docs/inherent_to_string.txt create mode 100644 src/docs/inherent_to_string_shadow_display.txt create mode 100644 src/docs/init_numbered_fields.txt create mode 100644 src/docs/inline_always.txt create mode 100644 src/docs/inline_asm_x86_att_syntax.txt create mode 100644 src/docs/inline_asm_x86_intel_syntax.txt create mode 100644 src/docs/inline_fn_without_body.txt create mode 100644 src/docs/inspect_for_each.txt create mode 100644 src/docs/int_plus_one.txt create mode 100644 src/docs/integer_arithmetic.txt create mode 100644 src/docs/integer_division.txt create mode 100644 src/docs/into_iter_on_ref.txt create mode 100644 src/docs/invalid_null_ptr_usage.txt create mode 100644 src/docs/invalid_regex.txt create mode 100644 src/docs/invalid_upcast_comparisons.txt create mode 100644 src/docs/invalid_utf8_in_unchecked.txt create mode 100644 src/docs/invisible_characters.txt create mode 100644 src/docs/is_digit_ascii_radix.txt create mode 100644 src/docs/items_after_statements.txt create mode 100644 src/docs/iter_cloned_collect.txt create mode 100644 src/docs/iter_count.txt create mode 100644 src/docs/iter_next_loop.txt create mode 100644 src/docs/iter_next_slice.txt create mode 100644 src/docs/iter_not_returning_iterator.txt create mode 100644 src/docs/iter_nth.txt create mode 100644 src/docs/iter_nth_zero.txt create mode 100644 src/docs/iter_on_empty_collections.txt create mode 100644 src/docs/iter_on_single_items.txt create mode 100644 src/docs/iter_overeager_cloned.txt create mode 100644 src/docs/iter_skip_next.txt create mode 100644 src/docs/iter_with_drain.txt create mode 100644 src/docs/iterator_step_by_zero.txt create mode 100644 src/docs/just_underscores_and_digits.txt create mode 100644 src/docs/large_const_arrays.txt create mode 100644 src/docs/large_digit_groups.txt create mode 100644 src/docs/large_enum_variant.txt create mode 100644 src/docs/large_include_file.txt create mode 100644 src/docs/large_stack_arrays.txt create mode 100644 src/docs/large_types_passed_by_value.txt create mode 100644 src/docs/len_without_is_empty.txt create mode 100644 src/docs/len_zero.txt create mode 100644 src/docs/let_and_return.txt create mode 100644 src/docs/let_underscore_drop.txt create mode 100644 src/docs/let_underscore_lock.txt create mode 100644 src/docs/let_underscore_must_use.txt create mode 100644 src/docs/let_unit_value.txt create mode 100644 src/docs/linkedlist.txt create mode 100644 src/docs/lossy_float_literal.txt create mode 100644 src/docs/macro_use_imports.txt create mode 100644 src/docs/main_recursion.txt create mode 100644 src/docs/manual_assert.txt create mode 100644 src/docs/manual_async_fn.txt create mode 100644 src/docs/manual_bits.txt create mode 100644 src/docs/manual_filter_map.txt create mode 100644 src/docs/manual_find.txt create mode 100644 src/docs/manual_find_map.txt create mode 100644 src/docs/manual_flatten.txt create mode 100644 src/docs/manual_instant_elapsed.txt create mode 100644 src/docs/manual_map.txt create mode 100644 src/docs/manual_memcpy.txt create mode 100644 src/docs/manual_non_exhaustive.txt create mode 100644 src/docs/manual_ok_or.txt create mode 100644 src/docs/manual_range_contains.txt create mode 100644 src/docs/manual_rem_euclid.txt create mode 100644 src/docs/manual_retain.txt create mode 100644 src/docs/manual_saturating_arithmetic.txt create mode 100644 src/docs/manual_split_once.txt create mode 100644 src/docs/manual_str_repeat.txt create mode 100644 src/docs/manual_string_new.txt create mode 100644 src/docs/manual_strip.txt create mode 100644 src/docs/manual_swap.txt create mode 100644 src/docs/manual_unwrap_or.txt create mode 100644 src/docs/many_single_char_names.txt create mode 100644 src/docs/map_clone.txt create mode 100644 src/docs/map_collect_result_unit.txt create mode 100644 src/docs/map_entry.txt create mode 100644 src/docs/map_err_ignore.txt create mode 100644 src/docs/map_flatten.txt create mode 100644 src/docs/map_identity.txt create mode 100644 src/docs/map_unwrap_or.txt create mode 100644 src/docs/match_as_ref.txt create mode 100644 src/docs/match_bool.txt create mode 100644 src/docs/match_like_matches_macro.txt create mode 100644 src/docs/match_on_vec_items.txt create mode 100644 src/docs/match_overlapping_arm.txt create mode 100644 src/docs/match_ref_pats.txt create mode 100644 src/docs/match_result_ok.txt create mode 100644 src/docs/match_same_arms.txt create mode 100644 src/docs/match_single_binding.txt create mode 100644 src/docs/match_str_case_mismatch.txt create mode 100644 src/docs/match_wild_err_arm.txt create mode 100644 src/docs/match_wildcard_for_single_variants.txt create mode 100644 src/docs/maybe_infinite_iter.txt create mode 100644 src/docs/mem_forget.txt create mode 100644 src/docs/mem_replace_option_with_none.txt create mode 100644 src/docs/mem_replace_with_default.txt create mode 100644 src/docs/mem_replace_with_uninit.txt create mode 100644 src/docs/min_max.txt create mode 100644 src/docs/mismatched_target_os.txt create mode 100644 src/docs/mismatching_type_param_order.txt create mode 100644 src/docs/misrefactored_assign_op.txt create mode 100644 src/docs/missing_const_for_fn.txt create mode 100644 src/docs/missing_docs_in_private_items.txt create mode 100644 src/docs/missing_enforced_import_renames.txt create mode 100644 src/docs/missing_errors_doc.txt create mode 100644 src/docs/missing_inline_in_public_items.txt create mode 100644 src/docs/missing_panics_doc.txt create mode 100644 src/docs/missing_safety_doc.txt create mode 100644 src/docs/missing_spin_loop.txt create mode 100644 src/docs/mistyped_literal_suffixes.txt create mode 100644 src/docs/mixed_case_hex_literals.txt create mode 100644 src/docs/mixed_read_write_in_expression.txt create mode 100644 src/docs/mod_module_files.txt create mode 100644 src/docs/module_inception.txt create mode 100644 src/docs/module_name_repetitions.txt create mode 100644 src/docs/modulo_arithmetic.txt create mode 100644 src/docs/modulo_one.txt create mode 100644 src/docs/multi_assignments.txt create mode 100644 src/docs/multiple_crate_versions.txt create mode 100644 src/docs/multiple_inherent_impl.txt create mode 100644 src/docs/must_use_candidate.txt create mode 100644 src/docs/must_use_unit.txt create mode 100644 src/docs/mut_from_ref.txt create mode 100644 src/docs/mut_mut.txt create mode 100644 src/docs/mut_mutex_lock.txt create mode 100644 src/docs/mut_range_bound.txt create mode 100644 src/docs/mutable_key_type.txt create mode 100644 src/docs/mutex_atomic.txt create mode 100644 src/docs/mutex_integer.txt create mode 100644 src/docs/naive_bytecount.txt create mode 100644 src/docs/needless_arbitrary_self_type.txt create mode 100644 src/docs/needless_bitwise_bool.txt create mode 100644 src/docs/needless_bool.txt create mode 100644 src/docs/needless_borrow.txt create mode 100644 src/docs/needless_borrowed_reference.txt create mode 100644 src/docs/needless_collect.txt create mode 100644 src/docs/needless_continue.txt create mode 100644 src/docs/needless_doctest_main.txt create mode 100644 src/docs/needless_for_each.txt create mode 100644 src/docs/needless_late_init.txt create mode 100644 src/docs/needless_lifetimes.txt create mode 100644 src/docs/needless_match.txt create mode 100644 src/docs/needless_option_as_deref.txt create mode 100644 src/docs/needless_option_take.txt create mode 100644 src/docs/needless_parens_on_range_literals.txt create mode 100644 src/docs/needless_pass_by_value.txt create mode 100644 src/docs/needless_question_mark.txt create mode 100644 src/docs/needless_range_loop.txt create mode 100644 src/docs/needless_return.txt create mode 100644 src/docs/needless_splitn.txt create mode 100644 src/docs/needless_update.txt create mode 100644 src/docs/neg_cmp_op_on_partial_ord.txt create mode 100644 src/docs/neg_multiply.txt create mode 100644 src/docs/negative_feature_names.txt create mode 100644 src/docs/never_loop.txt create mode 100644 src/docs/new_ret_no_self.txt create mode 100644 src/docs/new_without_default.txt create mode 100644 src/docs/no_effect.txt create mode 100644 src/docs/no_effect_replace.txt create mode 100644 src/docs/no_effect_underscore_binding.txt create mode 100644 src/docs/non_ascii_literal.txt create mode 100644 src/docs/non_octal_unix_permissions.txt create mode 100644 src/docs/non_send_fields_in_send_ty.txt create mode 100644 src/docs/nonminimal_bool.txt create mode 100644 src/docs/nonsensical_open_options.txt create mode 100644 src/docs/nonstandard_macro_braces.txt create mode 100644 src/docs/not_unsafe_ptr_arg_deref.txt create mode 100644 src/docs/obfuscated_if_else.txt create mode 100644 src/docs/octal_escapes.txt create mode 100644 src/docs/ok_expect.txt create mode 100644 src/docs/only_used_in_recursion.txt create mode 100644 src/docs/op_ref.txt create mode 100644 src/docs/option_as_ref_deref.txt create mode 100644 src/docs/option_env_unwrap.txt create mode 100644 src/docs/option_filter_map.txt create mode 100644 src/docs/option_if_let_else.txt create mode 100644 src/docs/option_map_or_none.txt create mode 100644 src/docs/option_map_unit_fn.txt create mode 100644 src/docs/option_option.txt create mode 100644 src/docs/or_fun_call.txt create mode 100644 src/docs/or_then_unwrap.txt create mode 100644 src/docs/out_of_bounds_indexing.txt create mode 100644 src/docs/overflow_check_conditional.txt create mode 100644 src/docs/overly_complex_bool_expr.txt create mode 100644 src/docs/panic.txt create mode 100644 src/docs/panic_in_result_fn.txt create mode 100644 src/docs/panicking_unwrap.txt create mode 100644 src/docs/partialeq_ne_impl.txt create mode 100644 src/docs/partialeq_to_none.txt create mode 100644 src/docs/path_buf_push_overwrite.txt create mode 100644 src/docs/pattern_type_mismatch.txt create mode 100644 src/docs/positional_named_format_parameters.txt create mode 100644 src/docs/possible_missing_comma.txt create mode 100644 src/docs/precedence.txt create mode 100644 src/docs/print_in_format_impl.txt create mode 100644 src/docs/print_literal.txt create mode 100644 src/docs/print_stderr.txt create mode 100644 src/docs/print_stdout.txt create mode 100644 src/docs/print_with_newline.txt create mode 100644 src/docs/println_empty_string.txt create mode 100644 src/docs/ptr_arg.txt create mode 100644 src/docs/ptr_as_ptr.txt create mode 100644 src/docs/ptr_eq.txt create mode 100644 src/docs/ptr_offset_with_cast.txt create mode 100644 src/docs/pub_use.txt create mode 100644 src/docs/question_mark.txt create mode 100644 src/docs/range_minus_one.txt create mode 100644 src/docs/range_plus_one.txt create mode 100644 src/docs/range_zip_with_len.txt create mode 100644 src/docs/rc_buffer.txt create mode 100644 src/docs/rc_clone_in_vec_init.txt create mode 100644 src/docs/rc_mutex.txt create mode 100644 src/docs/read_zero_byte_vec.txt create mode 100644 src/docs/recursive_format_impl.txt create mode 100644 src/docs/redundant_allocation.txt create mode 100644 src/docs/redundant_clone.txt create mode 100644 src/docs/redundant_closure.txt create mode 100644 src/docs/redundant_closure_call.txt create mode 100644 src/docs/redundant_closure_for_method_calls.txt create mode 100644 src/docs/redundant_else.txt create mode 100644 src/docs/redundant_feature_names.txt create mode 100644 src/docs/redundant_field_names.txt create mode 100644 src/docs/redundant_pattern.txt create mode 100644 src/docs/redundant_pattern_matching.txt create mode 100644 src/docs/redundant_pub_crate.txt create mode 100644 src/docs/redundant_slicing.txt create mode 100644 src/docs/redundant_static_lifetimes.txt create mode 100644 src/docs/ref_binding_to_reference.txt create mode 100644 src/docs/ref_option_ref.txt create mode 100644 src/docs/repeat_once.txt create mode 100644 src/docs/rest_pat_in_fully_bound_structs.txt create mode 100644 src/docs/result_large_err.txt create mode 100644 src/docs/result_map_or_into_option.txt create mode 100644 src/docs/result_map_unit_fn.txt create mode 100644 src/docs/result_unit_err.txt create mode 100644 src/docs/return_self_not_must_use.txt create mode 100644 src/docs/reversed_empty_ranges.txt create mode 100644 src/docs/same_functions_in_if_condition.txt create mode 100644 src/docs/same_item_push.txt create mode 100644 src/docs/same_name_method.txt create mode 100644 src/docs/search_is_some.txt create mode 100644 src/docs/self_assignment.txt create mode 100644 src/docs/self_named_constructors.txt create mode 100644 src/docs/self_named_module_files.txt create mode 100644 src/docs/semicolon_if_nothing_returned.txt create mode 100644 src/docs/separated_literal_suffix.txt create mode 100644 src/docs/serde_api_misuse.txt create mode 100644 src/docs/shadow_reuse.txt create mode 100644 src/docs/shadow_same.txt create mode 100644 src/docs/shadow_unrelated.txt create mode 100644 src/docs/short_circuit_statement.txt create mode 100644 src/docs/should_implement_trait.txt create mode 100644 src/docs/significant_drop_in_scrutinee.txt create mode 100644 src/docs/similar_names.txt create mode 100644 src/docs/single_char_add_str.txt create mode 100644 src/docs/single_char_lifetime_names.txt create mode 100644 src/docs/single_char_pattern.txt create mode 100644 src/docs/single_component_path_imports.txt create mode 100644 src/docs/single_element_loop.txt create mode 100644 src/docs/single_match.txt create mode 100644 src/docs/single_match_else.txt create mode 100644 src/docs/size_of_in_element_count.txt create mode 100644 src/docs/skip_while_next.txt create mode 100644 src/docs/slow_vector_initialization.txt create mode 100644 src/docs/stable_sort_primitive.txt create mode 100644 src/docs/std_instead_of_alloc.txt create mode 100644 src/docs/std_instead_of_core.txt create mode 100644 src/docs/str_to_string.txt create mode 100644 src/docs/string_add.txt create mode 100644 src/docs/string_add_assign.txt create mode 100644 src/docs/string_extend_chars.txt create mode 100644 src/docs/string_from_utf8_as_bytes.txt create mode 100644 src/docs/string_lit_as_bytes.txt create mode 100644 src/docs/string_slice.txt create mode 100644 src/docs/string_to_string.txt create mode 100644 src/docs/strlen_on_c_strings.txt create mode 100644 src/docs/struct_excessive_bools.txt create mode 100644 src/docs/suboptimal_flops.txt create mode 100644 src/docs/suspicious_arithmetic_impl.txt create mode 100644 src/docs/suspicious_assignment_formatting.txt create mode 100644 src/docs/suspicious_else_formatting.txt create mode 100644 src/docs/suspicious_map.txt create mode 100644 src/docs/suspicious_op_assign_impl.txt create mode 100644 src/docs/suspicious_operation_groupings.txt create mode 100644 src/docs/suspicious_splitn.txt create mode 100644 src/docs/suspicious_to_owned.txt create mode 100644 src/docs/suspicious_unary_op_formatting.txt create mode 100644 src/docs/swap_ptr_to_ref.txt create mode 100644 src/docs/tabs_in_doc_comments.txt create mode 100644 src/docs/temporary_assignment.txt create mode 100644 src/docs/to_digit_is_some.txt create mode 100644 src/docs/to_string_in_format_args.txt create mode 100644 src/docs/todo.txt create mode 100644 src/docs/too_many_arguments.txt create mode 100644 src/docs/too_many_lines.txt create mode 100644 src/docs/toplevel_ref_arg.txt create mode 100644 src/docs/trailing_empty_array.txt create mode 100644 src/docs/trait_duplication_in_bounds.txt create mode 100644 src/docs/transmute_bytes_to_str.txt create mode 100644 src/docs/transmute_float_to_int.txt create mode 100644 src/docs/transmute_int_to_bool.txt create mode 100644 src/docs/transmute_int_to_char.txt create mode 100644 src/docs/transmute_int_to_float.txt create mode 100644 src/docs/transmute_num_to_bytes.txt create mode 100644 src/docs/transmute_ptr_to_ptr.txt create mode 100644 src/docs/transmute_ptr_to_ref.txt create mode 100644 src/docs/transmute_undefined_repr.txt create mode 100644 src/docs/transmutes_expressible_as_ptr_casts.txt create mode 100644 src/docs/transmuting_null.txt create mode 100644 src/docs/trim_split_whitespace.txt create mode 100644 src/docs/trivial_regex.txt create mode 100644 src/docs/trivially_copy_pass_by_ref.txt create mode 100644 src/docs/try_err.txt create mode 100644 src/docs/type_complexity.txt create mode 100644 src/docs/type_repetition_in_bounds.txt create mode 100644 src/docs/undocumented_unsafe_blocks.txt create mode 100644 src/docs/undropped_manually_drops.txt create mode 100644 src/docs/unicode_not_nfc.txt create mode 100644 src/docs/unimplemented.txt create mode 100644 src/docs/uninit_assumed_init.txt create mode 100644 src/docs/uninit_vec.txt create mode 100644 src/docs/unit_arg.txt create mode 100644 src/docs/unit_cmp.txt create mode 100644 src/docs/unit_hash.txt create mode 100644 src/docs/unit_return_expecting_ord.txt create mode 100644 src/docs/unnecessary_cast.txt create mode 100644 src/docs/unnecessary_filter_map.txt create mode 100644 src/docs/unnecessary_find_map.txt create mode 100644 src/docs/unnecessary_fold.txt create mode 100644 src/docs/unnecessary_join.txt create mode 100644 src/docs/unnecessary_lazy_evaluations.txt create mode 100644 src/docs/unnecessary_mut_passed.txt create mode 100644 src/docs/unnecessary_operation.txt create mode 100644 src/docs/unnecessary_owned_empty_strings.txt create mode 100644 src/docs/unnecessary_self_imports.txt create mode 100644 src/docs/unnecessary_sort_by.txt create mode 100644 src/docs/unnecessary_to_owned.txt create mode 100644 src/docs/unnecessary_unwrap.txt create mode 100644 src/docs/unnecessary_wraps.txt create mode 100644 src/docs/unneeded_field_pattern.txt create mode 100644 src/docs/unneeded_wildcard_pattern.txt create mode 100644 src/docs/unnested_or_patterns.txt create mode 100644 src/docs/unreachable.txt create mode 100644 src/docs/unreadable_literal.txt create mode 100644 src/docs/unsafe_derive_deserialize.txt create mode 100644 src/docs/unsafe_removed_from_name.txt create mode 100644 src/docs/unseparated_literal_suffix.txt create mode 100644 src/docs/unsound_collection_transmute.txt create mode 100644 src/docs/unused_async.txt create mode 100644 src/docs/unused_io_amount.txt create mode 100644 src/docs/unused_peekable.txt create mode 100644 src/docs/unused_rounding.txt create mode 100644 src/docs/unused_self.txt create mode 100644 src/docs/unused_unit.txt create mode 100644 src/docs/unusual_byte_groupings.txt create mode 100644 src/docs/unwrap_in_result.txt create mode 100644 src/docs/unwrap_or_else_default.txt create mode 100644 src/docs/unwrap_used.txt create mode 100644 src/docs/upper_case_acronyms.txt create mode 100644 src/docs/use_debug.txt create mode 100644 src/docs/use_self.txt create mode 100644 src/docs/used_underscore_binding.txt create mode 100644 src/docs/useless_asref.txt create mode 100644 src/docs/useless_attribute.txt create mode 100644 src/docs/useless_conversion.txt create mode 100644 src/docs/useless_format.txt create mode 100644 src/docs/useless_let_if_seq.txt create mode 100644 src/docs/useless_transmute.txt create mode 100644 src/docs/useless_vec.txt create mode 100644 src/docs/vec_box.txt create mode 100644 src/docs/vec_init_then_push.txt create mode 100644 src/docs/vec_resize_to_zero.txt create mode 100644 src/docs/verbose_bit_mask.txt create mode 100644 src/docs/verbose_file_reads.txt create mode 100644 src/docs/vtable_address_comparisons.txt create mode 100644 src/docs/while_immutable_condition.txt create mode 100644 src/docs/while_let_loop.txt create mode 100644 src/docs/while_let_on_iterator.txt create mode 100644 src/docs/wildcard_dependencies.txt create mode 100644 src/docs/wildcard_enum_match_arm.txt create mode 100644 src/docs/wildcard_imports.txt create mode 100644 src/docs/wildcard_in_or_patterns.txt create mode 100644 src/docs/write_literal.txt create mode 100644 src/docs/write_with_newline.txt create mode 100644 src/docs/writeln_empty_string.txt create mode 100644 src/docs/wrong_self_convention.txt create mode 100644 src/docs/wrong_transmute.txt create mode 100644 src/docs/zero_divided_by_zero.txt create mode 100644 src/docs/zero_prefixed_literal.txt create mode 100644 src/docs/zero_ptr.txt create mode 100644 src/docs/zero_sized_map_values.txt create mode 100644 src/docs/zst_offset.txt (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/update_lints.rs b/clippy_dev/src/update_lints.rs index 28bec872c08..b95061bf81a 100644 --- a/clippy_dev/src/update_lints.rs +++ b/clippy_dev/src/update_lints.rs @@ -3,7 +3,7 @@ use aho_corasick::AhoCorasickBuilder; use indoc::writedoc; use itertools::Itertools; use rustc_lexer::{tokenize, unescape, LiteralKind, TokenKind}; -use std::collections::{HashMap, HashSet}; +use std::collections::{BTreeSet, HashMap, HashSet}; use std::ffi::OsStr; use std::fmt::Write; use std::fs::{self, OpenOptions}; @@ -124,6 +124,8 @@ fn generate_lint_files( let content = gen_lint_group_list("all", all_group_lints); process_file("clippy_lints/src/lib.register_all.rs", update_mode, &content); + update_docs(update_mode, &usable_lints); + for (lint_group, lints) in Lint::by_lint_group(usable_lints.into_iter().chain(internal_lints)) { let content = gen_lint_group_list(&lint_group, lints.iter()); process_file( @@ -140,6 +142,62 @@ fn generate_lint_files( process_file("tests/ui/rename.rs", update_mode, &content); } +fn update_docs(update_mode: UpdateMode, usable_lints: &[Lint]) { + replace_region_in_file(update_mode, Path::new("src/docs.rs"), "docs! {\n", "\n}\n", |res| { + for name in usable_lints.iter().map(|lint| lint.name.clone()).sorted() { + writeln!(res, r#" "{name}","#).unwrap(); + } + }); + + if update_mode == UpdateMode::Check { + let mut extra = BTreeSet::new(); + let mut lint_names = usable_lints + .iter() + .map(|lint| lint.name.clone()) + .collect::>(); + for file in std::fs::read_dir("src/docs").unwrap() { + let filename = file.unwrap().file_name().into_string().unwrap(); + if let Some(name) = filename.strip_suffix(".txt") { + if !lint_names.remove(name) { + extra.insert(name.to_string()); + } + } + } + + let failed = print_lint_names("extra lint docs:", &extra) | print_lint_names("missing lint docs:", &lint_names); + + if failed { + exit_with_failure(); + } + } else { + if std::fs::remove_dir_all("src/docs").is_err() { + eprintln!("could not remove src/docs directory"); + } + if std::fs::create_dir("src/docs").is_err() { + eprintln!("could not recreate src/docs directory"); + } + } + for lint in usable_lints { + process_file( + Path::new("src/docs").join(lint.name.clone() + ".txt"), + update_mode, + &lint.documentation, + ); + } +} + +fn print_lint_names(header: &str, lints: &BTreeSet) -> bool { + if lints.is_empty() { + return false; + } + println!("{}", header); + for lint in lints.iter().sorted() { + println!(" {}", lint); + } + println!(); + true +} + pub fn print_lints() { let (lint_list, _, _) = gather_all(); let usable_lints = Lint::usable_lints(&lint_list); @@ -589,17 +647,26 @@ struct Lint { desc: String, module: String, declaration_range: Range, + documentation: String, } impl Lint { #[must_use] - fn new(name: &str, group: &str, desc: &str, module: &str, declaration_range: Range) -> Self { + fn new( + name: &str, + group: &str, + desc: &str, + module: &str, + declaration_range: Range, + documentation: String, + ) -> Self { Self { name: name.to_lowercase(), group: group.into(), desc: remove_line_splices(desc), module: module.into(), declaration_range, + documentation, } } @@ -852,27 +919,35 @@ fn parse_contents(contents: &str, module: &str, lints: &mut Vec) { }| token_kind == &TokenKind::Ident && *content == "declare_clippy_lint", ) { let start = range.start; - - let mut iter = iter - .by_ref() - .filter(|t| !matches!(t.token_kind, TokenKind::Whitespace | TokenKind::LineComment { .. })); + let mut docs = String::with_capacity(128); + let mut iter = iter.by_ref().filter(|t| !matches!(t.token_kind, TokenKind::Whitespace)); // matches `!{` match_tokens!(iter, Bang OpenBrace); - match iter.next() { - // #[clippy::version = "version"] pub - Some(LintDeclSearchResult { - token_kind: TokenKind::Pound, - .. - }) => { - match_tokens!(iter, OpenBracket Ident Colon Colon Ident Eq Literal{..} CloseBracket Ident); - }, - // pub - Some(LintDeclSearchResult { - token_kind: TokenKind::Ident, - .. - }) => (), - _ => continue, + let mut in_code = false; + while let Some(t) = iter.next() { + match t.token_kind { + TokenKind::LineComment { .. } => { + if let Some(line) = t.content.strip_prefix("/// ").or_else(|| t.content.strip_prefix("///")) { + if line.starts_with("```") { + docs += "```\n"; + in_code = !in_code; + } else if !(in_code && line.starts_with("# ")) { + docs += line; + docs.push('\n'); + } + } + }, + TokenKind::Pound => { + match_tokens!(iter, OpenBracket Ident Colon Colon Ident Eq Literal{..} CloseBracket Ident); + break; + }, + TokenKind::Ident => { + break; + }, + _ => {}, + } } + docs.pop(); // remove final newline let (name, group, desc) = match_tokens!( iter, @@ -890,7 +965,7 @@ fn parse_contents(contents: &str, module: &str, lints: &mut Vec) { .. }) = iter.next() { - lints.push(Lint::new(name, group, desc, module, start..range.end)); + lints.push(Lint::new(name, group, desc, module, start..range.end, docs)); } } } @@ -1120,6 +1195,7 @@ mod tests { "\"really long text\"", "module_name", Range::default(), + String::new(), ), Lint::new( "doc_markdown", @@ -1127,6 +1203,7 @@ mod tests { "\"single line\"", "module_name", Range::default(), + String::new(), ), ]; assert_eq!(expected, result); @@ -1166,6 +1243,7 @@ mod tests { "\"abc\"", "module_name", Range::default(), + String::new(), ), Lint::new( "should_assert_eq2", @@ -1173,6 +1251,7 @@ mod tests { "\"abc\"", "module_name", Range::default(), + String::new(), ), Lint::new( "should_assert_eq2", @@ -1180,6 +1259,7 @@ mod tests { "\"abc\"", "module_name", Range::default(), + String::new(), ), ]; let expected = vec![Lint::new( @@ -1188,6 +1268,7 @@ mod tests { "\"abc\"", "module_name", Range::default(), + String::new(), )]; assert_eq!(expected, Lint::usable_lints(&lints)); } @@ -1195,22 +1276,51 @@ mod tests { #[test] fn test_by_lint_group() { let lints = vec![ - Lint::new("should_assert_eq", "group1", "\"abc\"", "module_name", Range::default()), + Lint::new( + "should_assert_eq", + "group1", + "\"abc\"", + "module_name", + Range::default(), + String::new(), + ), Lint::new( "should_assert_eq2", "group2", "\"abc\"", "module_name", Range::default(), + String::new(), + ), + Lint::new( + "incorrect_match", + "group1", + "\"abc\"", + "module_name", + Range::default(), + String::new(), ), - Lint::new("incorrect_match", "group1", "\"abc\"", "module_name", Range::default()), ]; let mut expected: HashMap> = HashMap::new(); expected.insert( "group1".to_string(), vec![ - Lint::new("should_assert_eq", "group1", "\"abc\"", "module_name", Range::default()), - Lint::new("incorrect_match", "group1", "\"abc\"", "module_name", Range::default()), + Lint::new( + "should_assert_eq", + "group1", + "\"abc\"", + "module_name", + Range::default(), + String::new(), + ), + Lint::new( + "incorrect_match", + "group1", + "\"abc\"", + "module_name", + Range::default(), + String::new(), + ), ], ); expected.insert( @@ -1221,6 +1331,7 @@ mod tests { "\"abc\"", "module_name", Range::default(), + String::new(), )], ); assert_eq!(expected, Lint::by_lint_group(lints.into_iter())); @@ -1259,9 +1370,30 @@ mod tests { #[test] fn test_gen_lint_group_list() { let lints = vec![ - Lint::new("abc", "group1", "\"abc\"", "module_name", Range::default()), - Lint::new("should_assert_eq", "group1", "\"abc\"", "module_name", Range::default()), - Lint::new("internal", "internal_style", "\"abc\"", "module_name", Range::default()), + Lint::new( + "abc", + "group1", + "\"abc\"", + "module_name", + Range::default(), + String::new(), + ), + Lint::new( + "should_assert_eq", + "group1", + "\"abc\"", + "module_name", + Range::default(), + String::new(), + ), + Lint::new( + "internal", + "internal_style", + "\"abc\"", + "module_name", + Range::default(), + String::new(), + ), ]; let expected = GENERATED_FILE_COMMENT.to_string() + &[ diff --git a/src/docs.rs b/src/docs.rs new file mode 100644 index 00000000000..69243bf4d9c --- /dev/null +++ b/src/docs.rs @@ -0,0 +1,596 @@ +// autogenerated. Please look at /clippy_dev/src/update_lints.rs + +macro_rules! include_lint { + ($file_name: expr) => { + include_str!($file_name) + }; +} + +macro_rules! docs { + ($($lint_name: expr,)*) => { + pub fn explain(lint: &str) { + println!("{}", match lint { + $( + $lint_name => include_lint!(concat!("docs/", concat!($lint_name, ".txt"))), + )* + _ => "unknown lint", + }) + } + } +} + +docs! { + "absurd_extreme_comparisons", + "alloc_instead_of_core", + "allow_attributes_without_reason", + "almost_complete_letter_range", + "almost_swapped", + "approx_constant", + "arithmetic", + "as_conversions", + "as_underscore", + "assertions_on_constants", + "assertions_on_result_states", + "assign_op_pattern", + "async_yields_async", + "await_holding_invalid_type", + "await_holding_lock", + "await_holding_refcell_ref", + "bad_bit_mask", + "bind_instead_of_map", + "blanket_clippy_restriction_lints", + "blocks_in_if_conditions", + "bool_assert_comparison", + "bool_comparison", + "bool_to_int_with_if", + "borrow_as_ptr", + "borrow_deref_ref", + "borrow_interior_mutable_const", + "borrowed_box", + "box_collection", + "boxed_local", + "branches_sharing_code", + "builtin_type_shadow", + "bytes_count_to_len", + "bytes_nth", + "cargo_common_metadata", + "case_sensitive_file_extension_comparisons", + "cast_abs_to_unsigned", + "cast_enum_constructor", + "cast_enum_truncation", + "cast_lossless", + "cast_possible_truncation", + "cast_possible_wrap", + "cast_precision_loss", + "cast_ptr_alignment", + "cast_ref_to_mut", + "cast_sign_loss", + "cast_slice_different_sizes", + "cast_slice_from_raw_parts", + "char_lit_as_u8", + "chars_last_cmp", + "chars_next_cmp", + "checked_conversions", + "clone_double_ref", + "clone_on_copy", + "clone_on_ref_ptr", + "cloned_instead_of_copied", + "cmp_nan", + "cmp_null", + "cmp_owned", + "cognitive_complexity", + "collapsible_else_if", + "collapsible_if", + "collapsible_match", + "collapsible_str_replace", + "comparison_chain", + "comparison_to_empty", + "copy_iterator", + "crate_in_macro_def", + "create_dir", + "crosspointer_transmute", + "dbg_macro", + "debug_assert_with_mut_call", + "decimal_literal_representation", + "declare_interior_mutable_const", + "default_instead_of_iter_empty", + "default_numeric_fallback", + "default_trait_access", + "default_union_representation", + "deprecated_cfg_attr", + "deprecated_semver", + "deref_addrof", + "deref_by_slicing", + "derivable_impls", + "derive_hash_xor_eq", + "derive_ord_xor_partial_ord", + "derive_partial_eq_without_eq", + "disallowed_methods", + "disallowed_names", + "disallowed_script_idents", + "disallowed_types", + "diverging_sub_expression", + "doc_link_with_quotes", + "doc_markdown", + "double_comparisons", + "double_must_use", + "double_neg", + "double_parens", + "drop_copy", + "drop_non_drop", + "drop_ref", + "duplicate_mod", + "duplicate_underscore_argument", + "duration_subsec", + "else_if_without_else", + "empty_drop", + "empty_enum", + "empty_line_after_outer_attr", + "empty_loop", + "empty_structs_with_brackets", + "enum_clike_unportable_variant", + "enum_glob_use", + "enum_variant_names", + "eq_op", + "equatable_if_let", + "erasing_op", + "err_expect", + "excessive_precision", + "exhaustive_enums", + "exhaustive_structs", + "exit", + "expect_fun_call", + "expect_used", + "expl_impl_clone_on_copy", + "explicit_auto_deref", + "explicit_counter_loop", + "explicit_deref_methods", + "explicit_into_iter_loop", + "explicit_iter_loop", + "explicit_write", + "extend_with_drain", + "extra_unused_lifetimes", + "fallible_impl_from", + "field_reassign_with_default", + "filetype_is_file", + "filter_map_identity", + "filter_map_next", + "filter_next", + "flat_map_identity", + "flat_map_option", + "float_arithmetic", + "float_cmp", + "float_cmp_const", + "float_equality_without_abs", + "fn_address_comparisons", + "fn_params_excessive_bools", + "fn_to_numeric_cast", + "fn_to_numeric_cast_any", + "fn_to_numeric_cast_with_truncation", + "for_kv_map", + "for_loops_over_fallibles", + "forget_copy", + "forget_non_drop", + "forget_ref", + "format_in_format_args", + "format_push_string", + "from_iter_instead_of_collect", + "from_over_into", + "from_str_radix_10", + "future_not_send", + "get_first", + "get_last_with_len", + "get_unwrap", + "identity_op", + "if_let_mutex", + "if_not_else", + "if_same_then_else", + "if_then_some_else_none", + "ifs_same_cond", + "implicit_clone", + "implicit_hasher", + "implicit_return", + "implicit_saturating_sub", + "imprecise_flops", + "inconsistent_digit_grouping", + "inconsistent_struct_constructor", + "index_refutable_slice", + "indexing_slicing", + "ineffective_bit_mask", + "inefficient_to_string", + "infallible_destructuring_match", + "infinite_iter", + "inherent_to_string", + "inherent_to_string_shadow_display", + "init_numbered_fields", + "inline_always", + "inline_asm_x86_att_syntax", + "inline_asm_x86_intel_syntax", + "inline_fn_without_body", + "inspect_for_each", + "int_plus_one", + "integer_arithmetic", + "integer_division", + "into_iter_on_ref", + "invalid_null_ptr_usage", + "invalid_regex", + "invalid_upcast_comparisons", + "invalid_utf8_in_unchecked", + "invisible_characters", + "is_digit_ascii_radix", + "items_after_statements", + "iter_cloned_collect", + "iter_count", + "iter_next_loop", + "iter_next_slice", + "iter_not_returning_iterator", + "iter_nth", + "iter_nth_zero", + "iter_on_empty_collections", + "iter_on_single_items", + "iter_overeager_cloned", + "iter_skip_next", + "iter_with_drain", + "iterator_step_by_zero", + "just_underscores_and_digits", + "large_const_arrays", + "large_digit_groups", + "large_enum_variant", + "large_include_file", + "large_stack_arrays", + "large_types_passed_by_value", + "len_without_is_empty", + "len_zero", + "let_and_return", + "let_underscore_drop", + "let_underscore_lock", + "let_underscore_must_use", + "let_unit_value", + "linkedlist", + "lossy_float_literal", + "macro_use_imports", + "main_recursion", + "manual_assert", + "manual_async_fn", + "manual_bits", + "manual_filter_map", + "manual_find", + "manual_find_map", + "manual_flatten", + "manual_instant_elapsed", + "manual_map", + "manual_memcpy", + "manual_non_exhaustive", + "manual_ok_or", + "manual_range_contains", + "manual_rem_euclid", + "manual_retain", + "manual_saturating_arithmetic", + "manual_split_once", + "manual_str_repeat", + "manual_string_new", + "manual_strip", + "manual_swap", + "manual_unwrap_or", + "many_single_char_names", + "map_clone", + "map_collect_result_unit", + "map_entry", + "map_err_ignore", + "map_flatten", + "map_identity", + "map_unwrap_or", + "match_as_ref", + "match_bool", + "match_like_matches_macro", + "match_on_vec_items", + "match_overlapping_arm", + "match_ref_pats", + "match_result_ok", + "match_same_arms", + "match_single_binding", + "match_str_case_mismatch", + "match_wild_err_arm", + "match_wildcard_for_single_variants", + "maybe_infinite_iter", + "mem_forget", + "mem_replace_option_with_none", + "mem_replace_with_default", + "mem_replace_with_uninit", + "min_max", + "mismatched_target_os", + "mismatching_type_param_order", + "misrefactored_assign_op", + "missing_const_for_fn", + "missing_docs_in_private_items", + "missing_enforced_import_renames", + "missing_errors_doc", + "missing_inline_in_public_items", + "missing_panics_doc", + "missing_safety_doc", + "missing_spin_loop", + "mistyped_literal_suffixes", + "mixed_case_hex_literals", + "mixed_read_write_in_expression", + "mod_module_files", + "module_inception", + "module_name_repetitions", + "modulo_arithmetic", + "modulo_one", + "multi_assignments", + "multiple_crate_versions", + "multiple_inherent_impl", + "must_use_candidate", + "must_use_unit", + "mut_from_ref", + "mut_mut", + "mut_mutex_lock", + "mut_range_bound", + "mutable_key_type", + "mutex_atomic", + "mutex_integer", + "naive_bytecount", + "needless_arbitrary_self_type", + "needless_bitwise_bool", + "needless_bool", + "needless_borrow", + "needless_borrowed_reference", + "needless_collect", + "needless_continue", + "needless_doctest_main", + "needless_for_each", + "needless_late_init", + "needless_lifetimes", + "needless_match", + "needless_option_as_deref", + "needless_option_take", + "needless_parens_on_range_literals", + "needless_pass_by_value", + "needless_question_mark", + "needless_range_loop", + "needless_return", + "needless_splitn", + "needless_update", + "neg_cmp_op_on_partial_ord", + "neg_multiply", + "negative_feature_names", + "never_loop", + "new_ret_no_self", + "new_without_default", + "no_effect", + "no_effect_replace", + "no_effect_underscore_binding", + "non_ascii_literal", + "non_octal_unix_permissions", + "non_send_fields_in_send_ty", + "nonminimal_bool", + "nonsensical_open_options", + "nonstandard_macro_braces", + "not_unsafe_ptr_arg_deref", + "obfuscated_if_else", + "octal_escapes", + "ok_expect", + "only_used_in_recursion", + "op_ref", + "option_as_ref_deref", + "option_env_unwrap", + "option_filter_map", + "option_if_let_else", + "option_map_or_none", + "option_map_unit_fn", + "option_option", + "or_fun_call", + "or_then_unwrap", + "out_of_bounds_indexing", + "overflow_check_conditional", + "overly_complex_bool_expr", + "panic", + "panic_in_result_fn", + "panicking_unwrap", + "partialeq_ne_impl", + "partialeq_to_none", + "path_buf_push_overwrite", + "pattern_type_mismatch", + "positional_named_format_parameters", + "possible_missing_comma", + "precedence", + "print_in_format_impl", + "print_literal", + "print_stderr", + "print_stdout", + "print_with_newline", + "println_empty_string", + "ptr_arg", + "ptr_as_ptr", + "ptr_eq", + "ptr_offset_with_cast", + "pub_use", + "question_mark", + "range_minus_one", + "range_plus_one", + "range_zip_with_len", + "rc_buffer", + "rc_clone_in_vec_init", + "rc_mutex", + "read_zero_byte_vec", + "recursive_format_impl", + "redundant_allocation", + "redundant_clone", + "redundant_closure", + "redundant_closure_call", + "redundant_closure_for_method_calls", + "redundant_else", + "redundant_feature_names", + "redundant_field_names", + "redundant_pattern", + "redundant_pattern_matching", + "redundant_pub_crate", + "redundant_slicing", + "redundant_static_lifetimes", + "ref_binding_to_reference", + "ref_option_ref", + "repeat_once", + "rest_pat_in_fully_bound_structs", + "result_large_err", + "result_map_or_into_option", + "result_map_unit_fn", + "result_unit_err", + "return_self_not_must_use", + "reversed_empty_ranges", + "same_functions_in_if_condition", + "same_item_push", + "same_name_method", + "search_is_some", + "self_assignment", + "self_named_constructors", + "self_named_module_files", + "semicolon_if_nothing_returned", + "separated_literal_suffix", + "serde_api_misuse", + "shadow_reuse", + "shadow_same", + "shadow_unrelated", + "short_circuit_statement", + "should_implement_trait", + "significant_drop_in_scrutinee", + "similar_names", + "single_char_add_str", + "single_char_lifetime_names", + "single_char_pattern", + "single_component_path_imports", + "single_element_loop", + "single_match", + "single_match_else", + "size_of_in_element_count", + "skip_while_next", + "slow_vector_initialization", + "stable_sort_primitive", + "std_instead_of_alloc", + "std_instead_of_core", + "str_to_string", + "string_add", + "string_add_assign", + "string_extend_chars", + "string_from_utf8_as_bytes", + "string_lit_as_bytes", + "string_slice", + "string_to_string", + "strlen_on_c_strings", + "struct_excessive_bools", + "suboptimal_flops", + "suspicious_arithmetic_impl", + "suspicious_assignment_formatting", + "suspicious_else_formatting", + "suspicious_map", + "suspicious_op_assign_impl", + "suspicious_operation_groupings", + "suspicious_splitn", + "suspicious_to_owned", + "suspicious_unary_op_formatting", + "swap_ptr_to_ref", + "tabs_in_doc_comments", + "temporary_assignment", + "to_digit_is_some", + "to_string_in_format_args", + "todo", + "too_many_arguments", + "too_many_lines", + "toplevel_ref_arg", + "trailing_empty_array", + "trait_duplication_in_bounds", + "transmute_bytes_to_str", + "transmute_float_to_int", + "transmute_int_to_bool", + "transmute_int_to_char", + "transmute_int_to_float", + "transmute_num_to_bytes", + "transmute_ptr_to_ptr", + "transmute_ptr_to_ref", + "transmute_undefined_repr", + "transmutes_expressible_as_ptr_casts", + "transmuting_null", + "trim_split_whitespace", + "trivial_regex", + "trivially_copy_pass_by_ref", + "try_err", + "type_complexity", + "type_repetition_in_bounds", + "undocumented_unsafe_blocks", + "undropped_manually_drops", + "unicode_not_nfc", + "unimplemented", + "uninit_assumed_init", + "uninit_vec", + "unit_arg", + "unit_cmp", + "unit_hash", + "unit_return_expecting_ord", + "unnecessary_cast", + "unnecessary_filter_map", + "unnecessary_find_map", + "unnecessary_fold", + "unnecessary_join", + "unnecessary_lazy_evaluations", + "unnecessary_mut_passed", + "unnecessary_operation", + "unnecessary_owned_empty_strings", + "unnecessary_self_imports", + "unnecessary_sort_by", + "unnecessary_to_owned", + "unnecessary_unwrap", + "unnecessary_wraps", + "unneeded_field_pattern", + "unneeded_wildcard_pattern", + "unnested_or_patterns", + "unreachable", + "unreadable_literal", + "unsafe_derive_deserialize", + "unsafe_removed_from_name", + "unseparated_literal_suffix", + "unsound_collection_transmute", + "unused_async", + "unused_io_amount", + "unused_peekable", + "unused_rounding", + "unused_self", + "unused_unit", + "unusual_byte_groupings", + "unwrap_in_result", + "unwrap_or_else_default", + "unwrap_used", + "upper_case_acronyms", + "use_debug", + "use_self", + "used_underscore_binding", + "useless_asref", + "useless_attribute", + "useless_conversion", + "useless_format", + "useless_let_if_seq", + "useless_transmute", + "useless_vec", + "vec_box", + "vec_init_then_push", + "vec_resize_to_zero", + "verbose_bit_mask", + "verbose_file_reads", + "vtable_address_comparisons", + "while_immutable_condition", + "while_let_loop", + "while_let_on_iterator", + "wildcard_dependencies", + "wildcard_enum_match_arm", + "wildcard_imports", + "wildcard_in_or_patterns", + "write_literal", + "write_with_newline", + "writeln_empty_string", + "wrong_self_convention", + "wrong_transmute", + "zero_divided_by_zero", + "zero_prefixed_literal", + "zero_ptr", + "zero_sized_map_values", + "zst_offset", + +} diff --git a/src/docs/absurd_extreme_comparisons.txt b/src/docs/absurd_extreme_comparisons.txt new file mode 100644 index 00000000000..590bee28aa2 --- /dev/null +++ b/src/docs/absurd_extreme_comparisons.txt @@ -0,0 +1,25 @@ +### What it does +Checks for comparisons where one side of the relation is +either the minimum or maximum value for its type and warns if it involves a +case that is always true or always false. Only integer and boolean types are +checked. + +### Why is this bad? +An expression like `min <= x` may misleadingly imply +that it is possible for `x` to be less than the minimum. Expressions like +`max < x` are probably mistakes. + +### Known problems +For `usize` the size of the current compile target will +be assumed (e.g., 64 bits on 64 bit systems). This means code that uses such +a comparison to detect target pointer width will trigger this lint. One can +use `mem::sizeof` and compare its value or conditional compilation +attributes +like `#[cfg(target_pointer_width = "64")] ..` instead. + +### Example +``` +let vec: Vec = Vec::new(); +if vec.len() <= 0 {} +if 100 > i32::MAX {} +``` \ No newline at end of file diff --git a/src/docs/alloc_instead_of_core.txt b/src/docs/alloc_instead_of_core.txt new file mode 100644 index 00000000000..488a36e9276 --- /dev/null +++ b/src/docs/alloc_instead_of_core.txt @@ -0,0 +1,18 @@ +### What it does + +Finds items imported through `alloc` when available through `core`. + +### Why is this bad? + +Crates which have `no_std` compatibility and may optionally require alloc may wish to ensure types are +imported from core to ensure disabling `alloc` does not cause the crate to fail to compile. This lint +is also useful for crates migrating to become `no_std` compatible. + +### Example +``` +use alloc::slice::from_ref; +``` +Use instead: +``` +use core::slice::from_ref; +``` \ No newline at end of file diff --git a/src/docs/allow_attributes_without_reason.txt b/src/docs/allow_attributes_without_reason.txt new file mode 100644 index 00000000000..fcc4f49b08b --- /dev/null +++ b/src/docs/allow_attributes_without_reason.txt @@ -0,0 +1,22 @@ +### What it does +Checks for attributes that allow lints without a reason. + +(This requires the `lint_reasons` feature) + +### Why is this bad? +Allowing a lint should always have a reason. This reason should be documented to +ensure that others understand the reasoning + +### Example +``` +#![feature(lint_reasons)] + +#![allow(clippy::some_lint)] +``` + +Use instead: +``` +#![feature(lint_reasons)] + +#![allow(clippy::some_lint, reason = "False positive rust-lang/rust-clippy#1002020")] +``` \ No newline at end of file diff --git a/src/docs/almost_complete_letter_range.txt b/src/docs/almost_complete_letter_range.txt new file mode 100644 index 00000000000..01cbaf9eae2 --- /dev/null +++ b/src/docs/almost_complete_letter_range.txt @@ -0,0 +1,15 @@ +### What it does +Checks for ranges which almost include the entire range of letters from 'a' to 'z', but +don't because they're a half open range. + +### Why is this bad? +This (`'a'..'z'`) is almost certainly a typo meant to include all letters. + +### Example +``` +let _ = 'a'..'z'; +``` +Use instead: +``` +let _ = 'a'..='z'; +``` \ No newline at end of file diff --git a/src/docs/almost_swapped.txt b/src/docs/almost_swapped.txt new file mode 100644 index 00000000000..cd10a8d5409 --- /dev/null +++ b/src/docs/almost_swapped.txt @@ -0,0 +1,15 @@ +### What it does +Checks for `foo = bar; bar = foo` sequences. + +### Why is this bad? +This looks like a failed attempt to swap. + +### Example +``` +a = b; +b = a; +``` +If swapping is intended, use `swap()` instead: +``` +std::mem::swap(&mut a, &mut b); +``` \ No newline at end of file diff --git a/src/docs/approx_constant.txt b/src/docs/approx_constant.txt new file mode 100644 index 00000000000..393fa4b5ef7 --- /dev/null +++ b/src/docs/approx_constant.txt @@ -0,0 +1,24 @@ +### What it does +Checks for floating point literals that approximate +constants which are defined in +[`std::f32::consts`](https://doc.rust-lang.org/stable/std/f32/consts/#constants) +or +[`std::f64::consts`](https://doc.rust-lang.org/stable/std/f64/consts/#constants), +respectively, suggesting to use the predefined constant. + +### Why is this bad? +Usually, the definition in the standard library is more +precise than what people come up with. If you find that your definition is +actually more precise, please [file a Rust +issue](https://github.com/rust-lang/rust/issues). + +### Example +``` +let x = 3.14; +let y = 1_f64 / x; +``` +Use instead: +``` +let x = std::f32::consts::PI; +let y = std::f64::consts::FRAC_1_PI; +``` \ No newline at end of file diff --git a/src/docs/arithmetic.txt b/src/docs/arithmetic.txt new file mode 100644 index 00000000000..0b3f07d9505 --- /dev/null +++ b/src/docs/arithmetic.txt @@ -0,0 +1,28 @@ +### What it does +Checks for any kind of arithmetic operation of any type. + +Operators like `+`, `-`, `*` or `<<` are usually capable of overflowing according to the [Rust +Reference](https://doc.rust-lang.org/reference/expressions/operator-expr.html#overflow), +or can panic (`/`, `%`). Known safe built-in types like `Wrapping` or `Saturing` are filtered +away. + +### Why is this bad? +Integer overflow will trigger a panic in debug builds or will wrap in +release mode. Division by zero will cause a panic in either mode. In some applications one +wants explicitly checked, wrapping or saturating arithmetic. + +#### Example +``` +a + 1; +``` + +Third-party types also tend to overflow. + +#### Example +``` +use rust_decimal::Decimal; +let _n = Decimal::MAX + Decimal::MAX; +``` + +### Allowed types +Custom allowed types can be specified through the "arithmetic-allowed" filter. \ No newline at end of file diff --git a/src/docs/as_conversions.txt b/src/docs/as_conversions.txt new file mode 100644 index 00000000000..4af479bd811 --- /dev/null +++ b/src/docs/as_conversions.txt @@ -0,0 +1,32 @@ +### What it does +Checks for usage of `as` conversions. + +Note that this lint is specialized in linting *every single* use of `as` +regardless of whether good alternatives exist or not. +If you want more precise lints for `as`, please consider using these separate lints: +`unnecessary_cast`, `cast_lossless/cast_possible_truncation/cast_possible_wrap/cast_precision_loss/cast_sign_loss`, +`fn_to_numeric_cast(_with_truncation)`, `char_lit_as_u8`, `ref_to_mut` and `ptr_as_ptr`. +There is a good explanation the reason why this lint should work in this way and how it is useful +[in this issue](https://github.com/rust-lang/rust-clippy/issues/5122). + +### Why is this bad? +`as` conversions will perform many kinds of +conversions, including silently lossy conversions and dangerous coercions. +There are cases when it makes sense to use `as`, so the lint is +Allow by default. + +### Example +``` +let a: u32; +... +f(a as u16); +``` + +Use instead: +``` +f(a.try_into()?); + +// or + +f(a.try_into().expect("Unexpected u16 overflow in f")); +``` \ No newline at end of file diff --git a/src/docs/as_underscore.txt b/src/docs/as_underscore.txt new file mode 100644 index 00000000000..2d9b0c35893 --- /dev/null +++ b/src/docs/as_underscore.txt @@ -0,0 +1,21 @@ +### What it does +Check for the usage of `as _` conversion using inferred type. + +### Why is this bad? +The conversion might include lossy conversion and dangerous cast that might go +undetected due to the type being inferred. + +The lint is allowed by default as using `_` is less wordy than always specifying the type. + +### Example +``` +fn foo(n: usize) {} +let n: u16 = 256; +foo(n as _); +``` +Use instead: +``` +fn foo(n: usize) {} +let n: u16 = 256; +foo(n as usize); +``` \ No newline at end of file diff --git a/src/docs/assertions_on_constants.txt b/src/docs/assertions_on_constants.txt new file mode 100644 index 00000000000..270c1e3b639 --- /dev/null +++ b/src/docs/assertions_on_constants.txt @@ -0,0 +1,14 @@ +### What it does +Checks for `assert!(true)` and `assert!(false)` calls. + +### Why is this bad? +Will be optimized out by the compiler or should probably be replaced by a +`panic!()` or `unreachable!()` + +### Example +``` +assert!(false) +assert!(true) +const B: bool = false; +assert!(B) +``` \ No newline at end of file diff --git a/src/docs/assertions_on_result_states.txt b/src/docs/assertions_on_result_states.txt new file mode 100644 index 00000000000..0889084fd3a --- /dev/null +++ b/src/docs/assertions_on_result_states.txt @@ -0,0 +1,14 @@ +### What it does +Checks for `assert!(r.is_ok())` or `assert!(r.is_err())` calls. + +### Why is this bad? +An assertion failure cannot output an useful message of the error. + +### Known problems +The suggested replacement decreases the readability of code and log output. + +### Example +``` +assert!(r.is_ok()); +assert!(r.is_err()); +``` \ No newline at end of file diff --git a/src/docs/assign_op_pattern.txt b/src/docs/assign_op_pattern.txt new file mode 100644 index 00000000000..f355c0cc18d --- /dev/null +++ b/src/docs/assign_op_pattern.txt @@ -0,0 +1,28 @@ +### What it does +Checks for `a = a op b` or `a = b commutative_op a` +patterns. + +### Why is this bad? +These can be written as the shorter `a op= b`. + +### Known problems +While forbidden by the spec, `OpAssign` traits may have +implementations that differ from the regular `Op` impl. + +### Example +``` +let mut a = 5; +let b = 0; +// ... + +a = a + b; +``` + +Use instead: +``` +let mut a = 5; +let b = 0; +// ... + +a += b; +``` \ No newline at end of file diff --git a/src/docs/async_yields_async.txt b/src/docs/async_yields_async.txt new file mode 100644 index 00000000000..a40de6d2e47 --- /dev/null +++ b/src/docs/async_yields_async.txt @@ -0,0 +1,28 @@ +### What it does +Checks for async blocks that yield values of types +that can themselves be awaited. + +### Why is this bad? +An await is likely missing. + +### Example +``` +async fn foo() {} + +fn bar() { + let x = async { + foo() + }; +} +``` + +Use instead: +``` +async fn foo() {} + +fn bar() { + let x = async { + foo().await + }; +} +``` \ No newline at end of file diff --git a/src/docs/await_holding_invalid_type.txt b/src/docs/await_holding_invalid_type.txt new file mode 100644 index 00000000000..e9c768772ff --- /dev/null +++ b/src/docs/await_holding_invalid_type.txt @@ -0,0 +1,29 @@ +### What it does +Allows users to configure types which should not be held across `await` +suspension points. + +### Why is this bad? +There are some types which are perfectly "safe" to be used concurrently +from a memory access perspective but will cause bugs at runtime if they +are held in such a way. + +### Example + +``` +await-holding-invalid-types = [ + # You can specify a type name + "CustomLockType", + # You can (optionally) specify a reason + { path = "OtherCustomLockType", reason = "Relies on a thread local" } +] +``` + +``` +struct CustomLockType; +struct OtherCustomLockType; +async fn foo() { + let _x = CustomLockType; + let _y = OtherCustomLockType; + baz().await; // Lint violation +} +``` \ No newline at end of file diff --git a/src/docs/await_holding_lock.txt b/src/docs/await_holding_lock.txt new file mode 100644 index 00000000000..0f450a11160 --- /dev/null +++ b/src/docs/await_holding_lock.txt @@ -0,0 +1,51 @@ +### What it does +Checks for calls to await while holding a non-async-aware MutexGuard. + +### Why is this bad? +The Mutex types found in std::sync and parking_lot +are not designed to operate in an async context across await points. + +There are two potential solutions. One is to use an async-aware Mutex +type. Many asynchronous foundation crates provide such a Mutex type. The +other solution is to ensure the mutex is unlocked before calling await, +either by introducing a scope or an explicit call to Drop::drop. + +### Known problems +Will report false positive for explicitly dropped guards +([#6446](https://github.com/rust-lang/rust-clippy/issues/6446)). A workaround for this is +to wrap the `.lock()` call in a block instead of explicitly dropping the guard. + +### Example +``` +async fn foo(x: &Mutex) { + let mut guard = x.lock().unwrap(); + *guard += 1; + baz().await; +} + +async fn bar(x: &Mutex) { + let mut guard = x.lock().unwrap(); + *guard += 1; + drop(guard); // explicit drop + baz().await; +} +``` + +Use instead: +``` +async fn foo(x: &Mutex) { + { + let mut guard = x.lock().unwrap(); + *guard += 1; + } + baz().await; +} + +async fn bar(x: &Mutex) { + { + let mut guard = x.lock().unwrap(); + *guard += 1; + } // guard dropped here at end of scope + baz().await; +} +``` \ No newline at end of file diff --git a/src/docs/await_holding_refcell_ref.txt b/src/docs/await_holding_refcell_ref.txt new file mode 100644 index 00000000000..226a261b9cc --- /dev/null +++ b/src/docs/await_holding_refcell_ref.txt @@ -0,0 +1,47 @@ +### What it does +Checks for calls to await while holding a `RefCell` `Ref` or `RefMut`. + +### Why is this bad? +`RefCell` refs only check for exclusive mutable access +at runtime. Holding onto a `RefCell` ref across an `await` suspension point +risks panics from a mutable ref shared while other refs are outstanding. + +### Known problems +Will report false positive for explicitly dropped refs +([#6353](https://github.com/rust-lang/rust-clippy/issues/6353)). A workaround for this is +to wrap the `.borrow[_mut]()` call in a block instead of explicitly dropping the ref. + +### Example +``` +async fn foo(x: &RefCell) { + let mut y = x.borrow_mut(); + *y += 1; + baz().await; +} + +async fn bar(x: &RefCell) { + let mut y = x.borrow_mut(); + *y += 1; + drop(y); // explicit drop + baz().await; +} +``` + +Use instead: +``` +async fn foo(x: &RefCell) { + { + let mut y = x.borrow_mut(); + *y += 1; + } + baz().await; +} + +async fn bar(x: &RefCell) { + { + let mut y = x.borrow_mut(); + *y += 1; + } // y dropped here at end of scope + baz().await; +} +``` \ No newline at end of file diff --git a/src/docs/bad_bit_mask.txt b/src/docs/bad_bit_mask.txt new file mode 100644 index 00000000000..d40024ee562 --- /dev/null +++ b/src/docs/bad_bit_mask.txt @@ -0,0 +1,30 @@ +### What it does +Checks for incompatible bit masks in comparisons. + +The formula for detecting if an expression of the type `_ m + c` (where `` is one of {`&`, `|`} and `` is one of +{`!=`, `>=`, `>`, `!=`, `>=`, `>`}) can be determined from the following +table: + +|Comparison |Bit Op|Example |is always|Formula | +|------------|------|-------------|---------|----------------------| +|`==` or `!=`| `&` |`x & 2 == 3` |`false` |`c & m != c` | +|`<` or `>=`| `&` |`x & 2 < 3` |`true` |`m < c` | +|`>` or `<=`| `&` |`x & 1 > 1` |`false` |`m <= c` | +|`==` or `!=`| `\|` |`x \| 1 == 0`|`false` |`c \| m != c` | +|`<` or `>=`| `\|` |`x \| 1 < 1` |`false` |`m >= c` | +|`<=` or `>` | `\|` |`x \| 1 > 0` |`true` |`m > c` | + +### Why is this bad? +If the bits that the comparison cares about are always +set to zero or one by the bit mask, the comparison is constant `true` or +`false` (depending on mask, compared value, and operators). + +So the code is actively misleading, and the only reason someone would write +this intentionally is to win an underhanded Rust contest or create a +test-case for this lint. + +### Example +``` +if (x & 1 == 2) { } +``` \ No newline at end of file diff --git a/src/docs/bind_instead_of_map.txt b/src/docs/bind_instead_of_map.txt new file mode 100644 index 00000000000..148575803d3 --- /dev/null +++ b/src/docs/bind_instead_of_map.txt @@ -0,0 +1,22 @@ +### What it does +Checks for usage of `_.and_then(|x| Some(y))`, `_.and_then(|x| Ok(y))` or +`_.or_else(|x| Err(y))`. + +### Why is this bad? +Readability, this can be written more concisely as +`_.map(|x| y)` or `_.map_err(|x| y)`. + +### Example +``` +let _ = opt().and_then(|s| Some(s.len())); +let _ = res().and_then(|s| if s.len() == 42 { Ok(10) } else { Ok(20) }); +let _ = res().or_else(|s| if s.len() == 42 { Err(10) } else { Err(20) }); +``` + +The correct use would be: + +``` +let _ = opt().map(|s| s.len()); +let _ = res().map(|s| if s.len() == 42 { 10 } else { 20 }); +let _ = res().map_err(|s| if s.len() == 42 { 10 } else { 20 }); +``` \ No newline at end of file diff --git a/src/docs/blanket_clippy_restriction_lints.txt b/src/docs/blanket_clippy_restriction_lints.txt new file mode 100644 index 00000000000..28a4ebf7169 --- /dev/null +++ b/src/docs/blanket_clippy_restriction_lints.txt @@ -0,0 +1,16 @@ +### What it does +Checks for `warn`/`deny`/`forbid` attributes targeting the whole clippy::restriction category. + +### Why is this bad? +Restriction lints sometimes are in contrast with other lints or even go against idiomatic rust. +These lints should only be enabled on a lint-by-lint basis and with careful consideration. + +### Example +``` +#![deny(clippy::restriction)] +``` + +Use instead: +``` +#![deny(clippy::as_conversions)] +``` \ No newline at end of file diff --git a/src/docs/blocks_in_if_conditions.txt b/src/docs/blocks_in_if_conditions.txt new file mode 100644 index 00000000000..3afa14853fd --- /dev/null +++ b/src/docs/blocks_in_if_conditions.txt @@ -0,0 +1,21 @@ +### What it does +Checks for `if` conditions that use blocks containing an +expression, statements or conditions that use closures with blocks. + +### Why is this bad? +Style, using blocks in the condition makes it hard to read. + +### Examples +``` +if { true } { /* ... */ } + +if { let x = somefunc(); x } { /* ... */ } +``` + +Use instead: +``` +if true { /* ... */ } + +let res = { let x = somefunc(); x }; +if res { /* ... */ } +``` \ No newline at end of file diff --git a/src/docs/bool_assert_comparison.txt b/src/docs/bool_assert_comparison.txt new file mode 100644 index 00000000000..df7ca00cc2b --- /dev/null +++ b/src/docs/bool_assert_comparison.txt @@ -0,0 +1,16 @@ +### What it does +This lint warns about boolean comparisons in assert-like macros. + +### Why is this bad? +It is shorter to use the equivalent. + +### Example +``` +assert_eq!("a".is_empty(), false); +assert_ne!("a".is_empty(), true); +``` + +Use instead: +``` +assert!(!"a".is_empty()); +``` \ No newline at end of file diff --git a/src/docs/bool_comparison.txt b/src/docs/bool_comparison.txt new file mode 100644 index 00000000000..0996f60cec4 --- /dev/null +++ b/src/docs/bool_comparison.txt @@ -0,0 +1,18 @@ +### What it does +Checks for expressions of the form `x == true`, +`x != true` and order comparisons such as `x < true` (or vice versa) and +suggest using the variable directly. + +### Why is this bad? +Unnecessary code. + +### Example +``` +if x == true {} +if y == false {} +``` +use `x` directly: +``` +if x {} +if !y {} +``` \ No newline at end of file diff --git a/src/docs/bool_to_int_with_if.txt b/src/docs/bool_to_int_with_if.txt new file mode 100644 index 00000000000..63535b454c9 --- /dev/null +++ b/src/docs/bool_to_int_with_if.txt @@ -0,0 +1,26 @@ +### What it does +Instead of using an if statement to convert a bool to an int, +this lint suggests using a `from()` function or an `as` coercion. + +### Why is this bad? +Coercion or `from()` is idiomatic way to convert bool to a number. +Both methods are guaranteed to return 1 for true, and 0 for false. + +See https://doc.rust-lang.org/std/primitive.bool.html#impl-From%3Cbool%3E + +### Example +``` +if condition { + 1_i64 +} else { + 0 +}; +``` +Use instead: +``` +i64::from(condition); +``` +or +``` +condition as i64; +``` \ No newline at end of file diff --git a/src/docs/borrow_as_ptr.txt b/src/docs/borrow_as_ptr.txt new file mode 100644 index 00000000000..0be865abd57 --- /dev/null +++ b/src/docs/borrow_as_ptr.txt @@ -0,0 +1,26 @@ +### What it does +Checks for the usage of `&expr as *const T` or +`&mut expr as *mut T`, and suggest using `ptr::addr_of` or +`ptr::addr_of_mut` instead. + +### Why is this bad? +This would improve readability and avoid creating a reference +that points to an uninitialized value or unaligned place. +Read the `ptr::addr_of` docs for more information. + +### Example +``` +let val = 1; +let p = &val as *const i32; + +let mut val_mut = 1; +let p_mut = &mut val_mut as *mut i32; +``` +Use instead: +``` +let val = 1; +let p = std::ptr::addr_of!(val); + +let mut val_mut = 1; +let p_mut = std::ptr::addr_of_mut!(val_mut); +``` \ No newline at end of file diff --git a/src/docs/borrow_deref_ref.txt b/src/docs/borrow_deref_ref.txt new file mode 100644 index 00000000000..352480d3f26 --- /dev/null +++ b/src/docs/borrow_deref_ref.txt @@ -0,0 +1,27 @@ +### What it does +Checks for `&*(&T)`. + +### Why is this bad? +Dereferencing and then borrowing a reference value has no effect in most cases. + +### Known problems +False negative on such code: +``` +let x = &12; +let addr_x = &x as *const _ as usize; +let addr_y = &&*x as *const _ as usize; // assert ok now, and lint triggered. + // But if we fix it, assert will fail. +assert_ne!(addr_x, addr_y); +``` + +### Example +``` +let s = &String::new(); + +let a: &String = &* s; +``` + +Use instead: +``` +let a: &String = s; +``` \ No newline at end of file diff --git a/src/docs/borrow_interior_mutable_const.txt b/src/docs/borrow_interior_mutable_const.txt new file mode 100644 index 00000000000..e55b6a77e66 --- /dev/null +++ b/src/docs/borrow_interior_mutable_const.txt @@ -0,0 +1,40 @@ +### What it does +Checks if `const` items which is interior mutable (e.g., +contains a `Cell`, `Mutex`, `AtomicXxxx`, etc.) has been borrowed directly. + +### Why is this bad? +Consts are copied everywhere they are referenced, i.e., +every time you refer to the const a fresh instance of the `Cell` or `Mutex` +or `AtomicXxxx` will be created, which defeats the whole purpose of using +these types in the first place. + +The `const` value should be stored inside a `static` item. + +### Known problems +When an enum has variants with interior mutability, use of its non +interior mutable variants can generate false positives. See issue +[#3962](https://github.com/rust-lang/rust-clippy/issues/3962) + +Types that have underlying or potential interior mutability trigger the lint whether +the interior mutable field is used or not. See issues +[#5812](https://github.com/rust-lang/rust-clippy/issues/5812) and +[#3825](https://github.com/rust-lang/rust-clippy/issues/3825) + +### Example +``` +use std::sync::atomic::{AtomicUsize, Ordering::SeqCst}; +const CONST_ATOM: AtomicUsize = AtomicUsize::new(12); + +CONST_ATOM.store(6, SeqCst); // the content of the atomic is unchanged +assert_eq!(CONST_ATOM.load(SeqCst), 12); // because the CONST_ATOM in these lines are distinct +``` + +Use instead: +``` +use std::sync::atomic::{AtomicUsize, Ordering::SeqCst}; +const CONST_ATOM: AtomicUsize = AtomicUsize::new(12); + +static STATIC_ATOM: AtomicUsize = CONST_ATOM; +STATIC_ATOM.store(9, SeqCst); +assert_eq!(STATIC_ATOM.load(SeqCst), 9); // use a `static` item to refer to the same instance +``` \ No newline at end of file diff --git a/src/docs/borrowed_box.txt b/src/docs/borrowed_box.txt new file mode 100644 index 00000000000..d7089be662a --- /dev/null +++ b/src/docs/borrowed_box.txt @@ -0,0 +1,19 @@ +### What it does +Checks for use of `&Box` anywhere in the code. +Check the [Box documentation](https://doc.rust-lang.org/std/boxed/index.html) for more information. + +### Why is this bad? +A `&Box` parameter requires the function caller to box `T` first before passing it to a function. +Using `&T` defines a concrete type for the parameter and generalizes the function, this would also +auto-deref to `&T` at the function call site if passed a `&Box`. + +### Example +``` +fn foo(bar: &Box) { ... } +``` + +Better: + +``` +fn foo(bar: &T) { ... } +``` \ No newline at end of file diff --git a/src/docs/box_collection.txt b/src/docs/box_collection.txt new file mode 100644 index 00000000000..053f24c4628 --- /dev/null +++ b/src/docs/box_collection.txt @@ -0,0 +1,23 @@ +### What it does +Checks for use of `Box` where T is a collection such as Vec anywhere in the code. +Check the [Box documentation](https://doc.rust-lang.org/std/boxed/index.html) for more information. + +### Why is this bad? +Collections already keeps their contents in a separate area on +the heap. So if you `Box` them, you just add another level of indirection +without any benefit whatsoever. + +### Example +``` +struct X { + values: Box>, +} +``` + +Better: + +``` +struct X { + values: Vec, +} +``` \ No newline at end of file diff --git a/src/docs/boxed_local.txt b/src/docs/boxed_local.txt new file mode 100644 index 00000000000..8b1febf1455 --- /dev/null +++ b/src/docs/boxed_local.txt @@ -0,0 +1,18 @@ +### What it does +Checks for usage of `Box` where an unboxed `T` would +work fine. + +### Why is this bad? +This is an unnecessary allocation, and bad for +performance. It is only necessary to allocate if you wish to move the box +into something. + +### Example +``` +fn foo(x: Box) {} +``` + +Use instead: +``` +fn foo(x: u32) {} +``` \ No newline at end of file diff --git a/src/docs/branches_sharing_code.txt b/src/docs/branches_sharing_code.txt new file mode 100644 index 00000000000..79be6124798 --- /dev/null +++ b/src/docs/branches_sharing_code.txt @@ -0,0 +1,32 @@ +### What it does +Checks if the `if` and `else` block contain shared code that can be +moved out of the blocks. + +### Why is this bad? +Duplicate code is less maintainable. + +### Known problems +* The lint doesn't check if the moved expressions modify values that are being used in + the if condition. The suggestion can in that case modify the behavior of the program. + See [rust-clippy#7452](https://github.com/rust-lang/rust-clippy/issues/7452) + +### Example +``` +let foo = if … { + println!("Hello World"); + 13 +} else { + println!("Hello World"); + 42 +}; +``` + +Use instead: +``` +println!("Hello World"); +let foo = if … { + 13 +} else { + 42 +}; +``` \ No newline at end of file diff --git a/src/docs/builtin_type_shadow.txt b/src/docs/builtin_type_shadow.txt new file mode 100644 index 00000000000..15b1c9df7ba --- /dev/null +++ b/src/docs/builtin_type_shadow.txt @@ -0,0 +1,15 @@ +### What it does +Warns if a generic shadows a built-in type. + +### Why is this bad? +This gives surprising type errors. + +### Example + +``` +impl Foo { + fn impl_func(&self) -> u32 { + 42 + } +} +``` \ No newline at end of file diff --git a/src/docs/bytes_count_to_len.txt b/src/docs/bytes_count_to_len.txt new file mode 100644 index 00000000000..ca7bf9a38da --- /dev/null +++ b/src/docs/bytes_count_to_len.txt @@ -0,0 +1,18 @@ +### What it does +It checks for `str::bytes().count()` and suggests replacing it with +`str::len()`. + +### Why is this bad? +`str::bytes().count()` is longer and may not be as performant as using +`str::len()`. + +### Example +``` +"hello".bytes().count(); +String::from("hello").bytes().count(); +``` +Use instead: +``` +"hello".len(); +String::from("hello").len(); +``` \ No newline at end of file diff --git a/src/docs/bytes_nth.txt b/src/docs/bytes_nth.txt new file mode 100644 index 00000000000..260de343353 --- /dev/null +++ b/src/docs/bytes_nth.txt @@ -0,0 +1,16 @@ +### What it does +Checks for the use of `.bytes().nth()`. + +### Why is this bad? +`.as_bytes().get()` is more efficient and more +readable. + +### Example +``` +"Hello".bytes().nth(3); +``` + +Use instead: +``` +"Hello".as_bytes().get(3); +``` \ No newline at end of file diff --git a/src/docs/cargo_common_metadata.txt b/src/docs/cargo_common_metadata.txt new file mode 100644 index 00000000000..1998647a927 --- /dev/null +++ b/src/docs/cargo_common_metadata.txt @@ -0,0 +1,33 @@ +### What it does +Checks to see if all common metadata is defined in +`Cargo.toml`. See: https://rust-lang-nursery.github.io/api-guidelines/documentation.html#cargotoml-includes-all-common-metadata-c-metadata + +### Why is this bad? +It will be more difficult for users to discover the +purpose of the crate, and key information related to it. + +### Example +``` +[package] +name = "clippy" +version = "0.0.212" +repository = "https://github.com/rust-lang/rust-clippy" +readme = "README.md" +license = "MIT OR Apache-2.0" +keywords = ["clippy", "lint", "plugin"] +categories = ["development-tools", "development-tools::cargo-plugins"] +``` + +Should include a description field like: + +``` +[package] +name = "clippy" +version = "0.0.212" +description = "A bunch of helpful lints to avoid common pitfalls in Rust" +repository = "https://github.com/rust-lang/rust-clippy" +readme = "README.md" +license = "MIT OR Apache-2.0" +keywords = ["clippy", "lint", "plugin"] +categories = ["development-tools", "development-tools::cargo-plugins"] +``` \ No newline at end of file diff --git a/src/docs/case_sensitive_file_extension_comparisons.txt b/src/docs/case_sensitive_file_extension_comparisons.txt new file mode 100644 index 00000000000..8e6e18ed4e2 --- /dev/null +++ b/src/docs/case_sensitive_file_extension_comparisons.txt @@ -0,0 +1,21 @@ +### What it does +Checks for calls to `ends_with` with possible file extensions +and suggests to use a case-insensitive approach instead. + +### Why is this bad? +`ends_with` is case-sensitive and may not detect files with a valid extension. + +### Example +``` +fn is_rust_file(filename: &str) -> bool { + filename.ends_with(".rs") +} +``` +Use instead: +``` +fn is_rust_file(filename: &str) -> bool { + let filename = std::path::Path::new(filename); + filename.extension() + .map_or(false, |ext| ext.eq_ignore_ascii_case("rs")) +} +``` \ No newline at end of file diff --git a/src/docs/cast_abs_to_unsigned.txt b/src/docs/cast_abs_to_unsigned.txt new file mode 100644 index 00000000000..c5d8ee034ce --- /dev/null +++ b/src/docs/cast_abs_to_unsigned.txt @@ -0,0 +1,16 @@ +### What it does +Checks for uses of the `abs()` method that cast the result to unsigned. + +### Why is this bad? +The `unsigned_abs()` method avoids panic when called on the MIN value. + +### Example +``` +let x: i32 = -42; +let y: u32 = x.abs() as u32; +``` +Use instead: +``` +let x: i32 = -42; +let y: u32 = x.unsigned_abs(); +``` \ No newline at end of file diff --git a/src/docs/cast_enum_constructor.txt b/src/docs/cast_enum_constructor.txt new file mode 100644 index 00000000000..675c03a42bc --- /dev/null +++ b/src/docs/cast_enum_constructor.txt @@ -0,0 +1,11 @@ +### What it does +Checks for casts from an enum tuple constructor to an integer. + +### Why is this bad? +The cast is easily confused with casting a c-like enum value to an integer. + +### Example +``` +enum E { X(i32) }; +let _ = E::X as usize; +``` \ No newline at end of file diff --git a/src/docs/cast_enum_truncation.txt b/src/docs/cast_enum_truncation.txt new file mode 100644 index 00000000000..abe32a8296d --- /dev/null +++ b/src/docs/cast_enum_truncation.txt @@ -0,0 +1,12 @@ +### What it does +Checks for casts from an enum type to an integral type which will definitely truncate the +value. + +### Why is this bad? +The resulting integral value will not match the value of the variant it came from. + +### Example +``` +enum E { X = 256 }; +let _ = E::X as u8; +``` \ No newline at end of file diff --git a/src/docs/cast_lossless.txt b/src/docs/cast_lossless.txt new file mode 100644 index 00000000000..c3a61dd470f --- /dev/null +++ b/src/docs/cast_lossless.txt @@ -0,0 +1,26 @@ +### What it does +Checks for casts between numerical types that may +be replaced by safe conversion functions. + +### Why is this bad? +Rust's `as` keyword will perform many kinds of +conversions, including silently lossy conversions. Conversion functions such +as `i32::from` will only perform lossless conversions. Using the conversion +functions prevents conversions from turning into silent lossy conversions if +the types of the input expressions ever change, and make it easier for +people reading the code to know that the conversion is lossless. + +### Example +``` +fn as_u64(x: u8) -> u64 { + x as u64 +} +``` + +Using `::from` would look like this: + +``` +fn as_u64(x: u8) -> u64 { + u64::from(x) +} +``` \ No newline at end of file diff --git a/src/docs/cast_possible_truncation.txt b/src/docs/cast_possible_truncation.txt new file mode 100644 index 00000000000..0b164848cc7 --- /dev/null +++ b/src/docs/cast_possible_truncation.txt @@ -0,0 +1,16 @@ +### What it does +Checks for casts between numerical types that may +truncate large values. This is expected behavior, so the cast is `Allow` by +default. + +### Why is this bad? +In some problem domains, it is good practice to avoid +truncation. This lint can be activated to help assess where additional +checks could be beneficial. + +### Example +``` +fn as_u8(x: u64) -> u8 { + x as u8 +} +``` \ No newline at end of file diff --git a/src/docs/cast_possible_wrap.txt b/src/docs/cast_possible_wrap.txt new file mode 100644 index 00000000000..f883fc9cfb9 --- /dev/null +++ b/src/docs/cast_possible_wrap.txt @@ -0,0 +1,17 @@ +### What it does +Checks for casts from an unsigned type to a signed type of +the same size. Performing such a cast is a 'no-op' for the compiler, +i.e., nothing is changed at the bit level, and the binary representation of +the value is reinterpreted. This can cause wrapping if the value is too big +for the target signed type. However, the cast works as defined, so this lint +is `Allow` by default. + +### Why is this bad? +While such a cast is not bad in itself, the results can +be surprising when this is not the intended behavior, as demonstrated by the +example below. + +### Example +``` +u32::MAX as i32; // will yield a value of `-1` +``` \ No newline at end of file diff --git a/src/docs/cast_precision_loss.txt b/src/docs/cast_precision_loss.txt new file mode 100644 index 00000000000..f915d9f8a6d --- /dev/null +++ b/src/docs/cast_precision_loss.txt @@ -0,0 +1,19 @@ +### What it does +Checks for casts from any numerical to a float type where +the receiving type cannot store all values from the original type without +rounding errors. This possible rounding is to be expected, so this lint is +`Allow` by default. + +Basically, this warns on casting any integer with 32 or more bits to `f32` +or any 64-bit integer to `f64`. + +### Why is this bad? +It's not bad at all. But in some applications it can be +helpful to know where precision loss can take place. This lint can help find +those places in the code. + +### Example +``` +let x = u64::MAX; +x as f64; +``` \ No newline at end of file diff --git a/src/docs/cast_ptr_alignment.txt b/src/docs/cast_ptr_alignment.txt new file mode 100644 index 00000000000..6a6d4dcaa2a --- /dev/null +++ b/src/docs/cast_ptr_alignment.txt @@ -0,0 +1,21 @@ +### What it does +Checks for casts, using `as` or `pointer::cast`, +from a less-strictly-aligned pointer to a more-strictly-aligned pointer + +### Why is this bad? +Dereferencing the resulting pointer may be undefined +behavior. + +### Known problems +Using `std::ptr::read_unaligned` and `std::ptr::write_unaligned` or similar +on the resulting pointer is fine. Is over-zealous: Casts with manual alignment checks or casts like +u64-> u8 -> u16 can be fine. Miri is able to do a more in-depth analysis. + +### Example +``` +let _ = (&1u8 as *const u8) as *const u16; +let _ = (&mut 1u8 as *mut u8) as *mut u16; + +(&1u8 as *const u8).cast::(); +(&mut 1u8 as *mut u8).cast::(); +``` \ No newline at end of file diff --git a/src/docs/cast_ref_to_mut.txt b/src/docs/cast_ref_to_mut.txt new file mode 100644 index 00000000000..fb5b4dbb62d --- /dev/null +++ b/src/docs/cast_ref_to_mut.txt @@ -0,0 +1,28 @@ +### What it does +Checks for casts of `&T` to `&mut T` anywhere in the code. + +### Why is this bad? +It’s basically guaranteed to be undefined behavior. +`UnsafeCell` is the only way to obtain aliasable data that is considered +mutable. + +### Example +``` +fn x(r: &i32) { + unsafe { + *(r as *const _ as *mut _) += 1; + } +} +``` + +Instead consider using interior mutability types. + +``` +use std::cell::UnsafeCell; + +fn x(r: &UnsafeCell) { + unsafe { + *r.get() += 1; + } +} +``` \ No newline at end of file diff --git a/src/docs/cast_sign_loss.txt b/src/docs/cast_sign_loss.txt new file mode 100644 index 00000000000..d64fe1b07f4 --- /dev/null +++ b/src/docs/cast_sign_loss.txt @@ -0,0 +1,15 @@ +### What it does +Checks for casts from a signed to an unsigned numerical +type. In this case, negative values wrap around to large positive values, +which can be quite surprising in practice. However, as the cast works as +defined, this lint is `Allow` by default. + +### Why is this bad? +Possibly surprising results. You can activate this lint +as a one-time check to see where numerical wrapping can arise. + +### Example +``` +let y: i8 = -1; +y as u128; // will return 18446744073709551615 +``` \ No newline at end of file diff --git a/src/docs/cast_slice_different_sizes.txt b/src/docs/cast_slice_different_sizes.txt new file mode 100644 index 00000000000..c01ef0ba92c --- /dev/null +++ b/src/docs/cast_slice_different_sizes.txt @@ -0,0 +1,38 @@ +### What it does +Checks for `as` casts between raw pointers to slices with differently sized elements. + +### Why is this bad? +The produced raw pointer to a slice does not update its length metadata. The produced +pointer will point to a different number of bytes than the original pointer because the +length metadata of a raw slice pointer is in elements rather than bytes. +Producing a slice reference from the raw pointer will either create a slice with +less data (which can be surprising) or create a slice with more data and cause Undefined Behavior. + +### Example +// Missing data +``` +let a = [1_i32, 2, 3, 4]; +let p = &a as *const [i32] as *const [u8]; +unsafe { + println!("{:?}", &*p); +} +``` +// Undefined Behavior (note: also potential alignment issues) +``` +let a = [1_u8, 2, 3, 4]; +let p = &a as *const [u8] as *const [u32]; +unsafe { + println!("{:?}", &*p); +} +``` +Instead use `ptr::slice_from_raw_parts` to construct a slice from a data pointer and the correct length +``` +let a = [1_i32, 2, 3, 4]; +let old_ptr = &a as *const [i32]; +// The data pointer is cast to a pointer to the target `u8` not `[u8]` +// The length comes from the known length of 4 i32s times the 4 bytes per i32 +let new_ptr = core::ptr::slice_from_raw_parts(old_ptr as *const u8, 16); +unsafe { + println!("{:?}", &*new_ptr); +} +``` \ No newline at end of file diff --git a/src/docs/cast_slice_from_raw_parts.txt b/src/docs/cast_slice_from_raw_parts.txt new file mode 100644 index 00000000000..b58c739766a --- /dev/null +++ b/src/docs/cast_slice_from_raw_parts.txt @@ -0,0 +1,20 @@ +### What it does +Checks for a raw slice being cast to a slice pointer + +### Why is this bad? +This can result in multiple `&mut` references to the same location when only a pointer is +required. +`ptr::slice_from_raw_parts` is a safe alternative that doesn't require +the same [safety requirements] to be upheld. + +### Example +``` +let _: *const [u8] = std::slice::from_raw_parts(ptr, len) as *const _; +let _: *mut [u8] = std::slice::from_raw_parts_mut(ptr, len) as *mut _; +``` +Use instead: +``` +let _: *const [u8] = std::ptr::slice_from_raw_parts(ptr, len); +let _: *mut [u8] = std::ptr::slice_from_raw_parts_mut(ptr, len); +``` +[safety requirements]: https://doc.rust-lang.org/std/slice/fn.from_raw_parts.html#safety \ No newline at end of file diff --git a/src/docs/char_lit_as_u8.txt b/src/docs/char_lit_as_u8.txt new file mode 100644 index 00000000000..00d60b9a451 --- /dev/null +++ b/src/docs/char_lit_as_u8.txt @@ -0,0 +1,21 @@ +### What it does +Checks for expressions where a character literal is cast +to `u8` and suggests using a byte literal instead. + +### Why is this bad? +In general, casting values to smaller types is +error-prone and should be avoided where possible. In the particular case of +converting a character literal to u8, it is easy to avoid by just using a +byte literal instead. As an added bonus, `b'a'` is even slightly shorter +than `'a' as u8`. + +### Example +``` +'x' as u8 +``` + +A better version, using the byte literal: + +``` +b'x' +``` \ No newline at end of file diff --git a/src/docs/chars_last_cmp.txt b/src/docs/chars_last_cmp.txt new file mode 100644 index 00000000000..4c1d8838973 --- /dev/null +++ b/src/docs/chars_last_cmp.txt @@ -0,0 +1,17 @@ +### What it does +Checks for usage of `_.chars().last()` or +`_.chars().next_back()` on a `str` to check if it ends with a given char. + +### Why is this bad? +Readability, this can be written more concisely as +`_.ends_with(_)`. + +### Example +``` +name.chars().last() == Some('_') || name.chars().next_back() == Some('-'); +``` + +Use instead: +``` +name.ends_with('_') || name.ends_with('-'); +``` \ No newline at end of file diff --git a/src/docs/chars_next_cmp.txt b/src/docs/chars_next_cmp.txt new file mode 100644 index 00000000000..77cbce2de00 --- /dev/null +++ b/src/docs/chars_next_cmp.txt @@ -0,0 +1,19 @@ +### What it does +Checks for usage of `.chars().next()` on a `str` to check +if it starts with a given char. + +### Why is this bad? +Readability, this can be written more concisely as +`_.starts_with(_)`. + +### Example +``` +let name = "foo"; +if name.chars().next() == Some('_') {}; +``` + +Use instead: +``` +let name = "foo"; +if name.starts_with('_') {}; +``` \ No newline at end of file diff --git a/src/docs/checked_conversions.txt b/src/docs/checked_conversions.txt new file mode 100644 index 00000000000..536b01294ee --- /dev/null +++ b/src/docs/checked_conversions.txt @@ -0,0 +1,15 @@ +### What it does +Checks for explicit bounds checking when casting. + +### Why is this bad? +Reduces the readability of statements & is error prone. + +### Example +``` +foo <= i32::MAX as u32; +``` + +Use instead: +``` +i32::try_from(foo).is_ok(); +``` \ No newline at end of file diff --git a/src/docs/clone_double_ref.txt b/src/docs/clone_double_ref.txt new file mode 100644 index 00000000000..2729635bd24 --- /dev/null +++ b/src/docs/clone_double_ref.txt @@ -0,0 +1,16 @@ +### What it does +Checks for usage of `.clone()` on an `&&T`. + +### Why is this bad? +Cloning an `&&T` copies the inner `&T`, instead of +cloning the underlying `T`. + +### Example +``` +fn main() { + let x = vec![1]; + let y = &&x; + let z = y.clone(); + println!("{:p} {:p}", *y, z); // prints out the same pointer +} +``` \ No newline at end of file diff --git a/src/docs/clone_on_copy.txt b/src/docs/clone_on_copy.txt new file mode 100644 index 00000000000..99a0bdb4c4a --- /dev/null +++ b/src/docs/clone_on_copy.txt @@ -0,0 +1,11 @@ +### What it does +Checks for usage of `.clone()` on a `Copy` type. + +### Why is this bad? +The only reason `Copy` types implement `Clone` is for +generics, not for using the `clone` method on a concrete type. + +### Example +``` +42u64.clone(); +``` \ No newline at end of file diff --git a/src/docs/clone_on_ref_ptr.txt b/src/docs/clone_on_ref_ptr.txt new file mode 100644 index 00000000000..2d83f8fefc1 --- /dev/null +++ b/src/docs/clone_on_ref_ptr.txt @@ -0,0 +1,21 @@ +### What it does +Checks for usage of `.clone()` on a ref-counted pointer, +(`Rc`, `Arc`, `rc::Weak`, or `sync::Weak`), and suggests calling Clone via unified +function syntax instead (e.g., `Rc::clone(foo)`). + +### Why is this bad? +Calling '.clone()' on an Rc, Arc, or Weak +can obscure the fact that only the pointer is being cloned, not the underlying +data. + +### Example +``` +let x = Rc::new(1); + +x.clone(); +``` + +Use instead: +``` +Rc::clone(&x); +``` \ No newline at end of file diff --git a/src/docs/cloned_instead_of_copied.txt b/src/docs/cloned_instead_of_copied.txt new file mode 100644 index 00000000000..2f2014d5fd2 --- /dev/null +++ b/src/docs/cloned_instead_of_copied.txt @@ -0,0 +1,16 @@ +### What it does +Checks for usages of `cloned()` on an `Iterator` or `Option` where +`copied()` could be used instead. + +### Why is this bad? +`copied()` is better because it guarantees that the type being cloned +implements `Copy`. + +### Example +``` +[1, 2, 3].iter().cloned(); +``` +Use instead: +``` +[1, 2, 3].iter().copied(); +``` \ No newline at end of file diff --git a/src/docs/cmp_nan.txt b/src/docs/cmp_nan.txt new file mode 100644 index 00000000000..e2ad04d9323 --- /dev/null +++ b/src/docs/cmp_nan.txt @@ -0,0 +1,16 @@ +### What it does +Checks for comparisons to NaN. + +### Why is this bad? +NaN does not compare meaningfully to anything – not +even itself – so those comparisons are simply wrong. + +### Example +``` +if x == f32::NAN { } +``` + +Use instead: +``` +if x.is_nan() { } +``` \ No newline at end of file diff --git a/src/docs/cmp_null.txt b/src/docs/cmp_null.txt new file mode 100644 index 00000000000..02fd15124f0 --- /dev/null +++ b/src/docs/cmp_null.txt @@ -0,0 +1,23 @@ +### What it does +This lint checks for equality comparisons with `ptr::null` + +### Why is this bad? +It's easier and more readable to use the inherent +`.is_null()` +method instead + +### Example +``` +use std::ptr; + +if x == ptr::null { + // .. +} +``` + +Use instead: +``` +if x.is_null() { + // .. +} +``` \ No newline at end of file diff --git a/src/docs/cmp_owned.txt b/src/docs/cmp_owned.txt new file mode 100644 index 00000000000..f8d4956ff1d --- /dev/null +++ b/src/docs/cmp_owned.txt @@ -0,0 +1,18 @@ +### What it does +Checks for conversions to owned values just for the sake +of a comparison. + +### Why is this bad? +The comparison can operate on a reference, so creating +an owned value effectively throws it away directly afterwards, which is +needlessly consuming code and heap space. + +### Example +``` +if x.to_owned() == y {} +``` + +Use instead: +``` +if x == y {} +``` \ No newline at end of file diff --git a/src/docs/cognitive_complexity.txt b/src/docs/cognitive_complexity.txt new file mode 100644 index 00000000000..fdd75f6479c --- /dev/null +++ b/src/docs/cognitive_complexity.txt @@ -0,0 +1,13 @@ +### What it does +Checks for methods with high cognitive complexity. + +### Why is this bad? +Methods of high cognitive complexity tend to be hard to +both read and maintain. Also LLVM will tend to optimize small methods better. + +### Known problems +Sometimes it's hard to find a way to reduce the +complexity. + +### Example +You'll see it when you get the warning. \ No newline at end of file diff --git a/src/docs/collapsible_else_if.txt b/src/docs/collapsible_else_if.txt new file mode 100644 index 00000000000..4ddfca17731 --- /dev/null +++ b/src/docs/collapsible_else_if.txt @@ -0,0 +1,29 @@ +### What it does +Checks for collapsible `else { if ... }` expressions +that can be collapsed to `else if ...`. + +### Why is this bad? +Each `if`-statement adds one level of nesting, which +makes code look more complex than it really is. + +### Example +``` + +if x { + … +} else { + if y { + … + } +} +``` + +Should be written: + +``` +if x { + … +} else if y { + … +} +``` \ No newline at end of file diff --git a/src/docs/collapsible_if.txt b/src/docs/collapsible_if.txt new file mode 100644 index 00000000000..e1264ee062e --- /dev/null +++ b/src/docs/collapsible_if.txt @@ -0,0 +1,23 @@ +### What it does +Checks for nested `if` statements which can be collapsed +by `&&`-combining their conditions. + +### Why is this bad? +Each `if`-statement adds one level of nesting, which +makes code look more complex than it really is. + +### Example +``` +if x { + if y { + // … + } +} +``` + +Use instead: +``` +if x && y { + // … +} +``` \ No newline at end of file diff --git a/src/docs/collapsible_match.txt b/src/docs/collapsible_match.txt new file mode 100644 index 00000000000..0d59594a03a --- /dev/null +++ b/src/docs/collapsible_match.txt @@ -0,0 +1,31 @@ +### What it does +Finds nested `match` or `if let` expressions where the patterns may be "collapsed" together +without adding any branches. + +Note that this lint is not intended to find _all_ cases where nested match patterns can be merged, but only +cases where merging would most likely make the code more readable. + +### Why is this bad? +It is unnecessarily verbose and complex. + +### Example +``` +fn func(opt: Option>) { + let n = match opt { + Some(n) => match n { + Ok(n) => n, + _ => return, + } + None => return, + }; +} +``` +Use instead: +``` +fn func(opt: Option>) { + let n = match opt { + Some(Ok(n)) => n, + _ => return, + }; +} +``` \ No newline at end of file diff --git a/src/docs/collapsible_str_replace.txt b/src/docs/collapsible_str_replace.txt new file mode 100644 index 00000000000..c24c25a3028 --- /dev/null +++ b/src/docs/collapsible_str_replace.txt @@ -0,0 +1,19 @@ +### What it does +Checks for consecutive calls to `str::replace` (2 or more) +that can be collapsed into a single call. + +### Why is this bad? +Consecutive `str::replace` calls scan the string multiple times +with repetitive code. + +### Example +``` +let hello = "hesuo worpd" + .replace('s', "l") + .replace("u", "l") + .replace('p', "l"); +``` +Use instead: +``` +let hello = "hesuo worpd".replace(&['s', 'u', 'p'], "l"); +``` \ No newline at end of file diff --git a/src/docs/comparison_chain.txt b/src/docs/comparison_chain.txt new file mode 100644 index 00000000000..43b09f31ff4 --- /dev/null +++ b/src/docs/comparison_chain.txt @@ -0,0 +1,36 @@ +### What it does +Checks comparison chains written with `if` that can be +rewritten with `match` and `cmp`. + +### Why is this bad? +`if` is not guaranteed to be exhaustive and conditionals can get +repetitive + +### Known problems +The match statement may be slower due to the compiler +not inlining the call to cmp. See issue [#5354](https://github.com/rust-lang/rust-clippy/issues/5354) + +### Example +``` +fn f(x: u8, y: u8) { + if x > y { + a() + } else if x < y { + b() + } else { + c() + } +} +``` + +Use instead: +``` +use std::cmp::Ordering; +fn f(x: u8, y: u8) { + match x.cmp(&y) { + Ordering::Greater => a(), + Ordering::Less => b(), + Ordering::Equal => c() + } +} +``` \ No newline at end of file diff --git a/src/docs/comparison_to_empty.txt b/src/docs/comparison_to_empty.txt new file mode 100644 index 00000000000..db6f74fe270 --- /dev/null +++ b/src/docs/comparison_to_empty.txt @@ -0,0 +1,31 @@ +### What it does +Checks for comparing to an empty slice such as `""` or `[]`, +and suggests using `.is_empty()` where applicable. + +### Why is this bad? +Some structures can answer `.is_empty()` much faster +than checking for equality. So it is good to get into the habit of using +`.is_empty()`, and having it is cheap. +Besides, it makes the intent clearer than a manual comparison in some contexts. + +### Example + +``` +if s == "" { + .. +} + +if arr == [] { + .. +} +``` +Use instead: +``` +if s.is_empty() { + .. +} + +if arr.is_empty() { + .. +} +``` \ No newline at end of file diff --git a/src/docs/copy_iterator.txt b/src/docs/copy_iterator.txt new file mode 100644 index 00000000000..5f9a2a015b8 --- /dev/null +++ b/src/docs/copy_iterator.txt @@ -0,0 +1,20 @@ +### What it does +Checks for types that implement `Copy` as well as +`Iterator`. + +### Why is this bad? +Implicit copies can be confusing when working with +iterator combinators. + +### Example +``` +#[derive(Copy, Clone)] +struct Countdown(u8); + +impl Iterator for Countdown { + // ... +} + +let a: Vec<_> = my_iterator.take(1).collect(); +let b: Vec<_> = my_iterator.collect(); +``` \ No newline at end of file diff --git a/src/docs/crate_in_macro_def.txt b/src/docs/crate_in_macro_def.txt new file mode 100644 index 00000000000..047e986dee7 --- /dev/null +++ b/src/docs/crate_in_macro_def.txt @@ -0,0 +1,35 @@ +### What it does +Checks for use of `crate` as opposed to `$crate` in a macro definition. + +### Why is this bad? +`crate` refers to the macro call's crate, whereas `$crate` refers to the macro definition's +crate. Rarely is the former intended. See: +https://doc.rust-lang.org/reference/macros-by-example.html#hygiene + +### Example +``` +#[macro_export] +macro_rules! print_message { + () => { + println!("{}", crate::MESSAGE); + }; +} +pub const MESSAGE: &str = "Hello!"; +``` +Use instead: +``` +#[macro_export] +macro_rules! print_message { + () => { + println!("{}", $crate::MESSAGE); + }; +} +pub const MESSAGE: &str = "Hello!"; +``` + +Note that if the use of `crate` is intentional, an `allow` attribute can be applied to the +macro definition, e.g.: +``` +#[allow(clippy::crate_in_macro_def)] +macro_rules! ok { ... crate::foo ... } +``` \ No newline at end of file diff --git a/src/docs/create_dir.txt b/src/docs/create_dir.txt new file mode 100644 index 00000000000..e4e7937684e --- /dev/null +++ b/src/docs/create_dir.txt @@ -0,0 +1,15 @@ +### What it does +Checks usage of `std::fs::create_dir` and suggest using `std::fs::create_dir_all` instead. + +### Why is this bad? +Sometimes `std::fs::create_dir` is mistakenly chosen over `std::fs::create_dir_all`. + +### Example +``` +std::fs::create_dir("foo"); +``` + +Use instead: +``` +std::fs::create_dir_all("foo"); +``` \ No newline at end of file diff --git a/src/docs/crosspointer_transmute.txt b/src/docs/crosspointer_transmute.txt new file mode 100644 index 00000000000..49dea154970 --- /dev/null +++ b/src/docs/crosspointer_transmute.txt @@ -0,0 +1,12 @@ +### What it does +Checks for transmutes between a type `T` and `*T`. + +### Why is this bad? +It's easy to mistakenly transmute between a type and a +pointer to that type. + +### Example +``` +core::intrinsics::transmute(t) // where the result type is the same as + // `*t` or `&t`'s +``` \ No newline at end of file diff --git a/src/docs/dbg_macro.txt b/src/docs/dbg_macro.txt new file mode 100644 index 00000000000..3e1a9a043f9 --- /dev/null +++ b/src/docs/dbg_macro.txt @@ -0,0 +1,16 @@ +### What it does +Checks for usage of dbg!() macro. + +### Why is this bad? +`dbg!` macro is intended as a debugging tool. It +should not be in version control. + +### Example +``` +dbg!(true) +``` + +Use instead: +``` +true +``` \ No newline at end of file diff --git a/src/docs/debug_assert_with_mut_call.txt b/src/docs/debug_assert_with_mut_call.txt new file mode 100644 index 00000000000..2c44abe1f05 --- /dev/null +++ b/src/docs/debug_assert_with_mut_call.txt @@ -0,0 +1,18 @@ +### What it does +Checks for function/method calls with a mutable +parameter in `debug_assert!`, `debug_assert_eq!` and `debug_assert_ne!` macros. + +### Why is this bad? +In release builds `debug_assert!` macros are optimized out by the +compiler. +Therefore mutating something in a `debug_assert!` macro results in different behavior +between a release and debug build. + +### Example +``` +debug_assert_eq!(vec![3].pop(), Some(3)); + +// or + +debug_assert!(takes_a_mut_parameter(&mut x)); +``` \ No newline at end of file diff --git a/src/docs/decimal_literal_representation.txt b/src/docs/decimal_literal_representation.txt new file mode 100644 index 00000000000..daca9bbb3a8 --- /dev/null +++ b/src/docs/decimal_literal_representation.txt @@ -0,0 +1,13 @@ +### What it does +Warns if there is a better representation for a numeric literal. + +### Why is this bad? +Especially for big powers of 2 a hexadecimal representation is more +readable than a decimal representation. + +### Example +``` +`255` => `0xFF` +`65_535` => `0xFFFF` +`4_042_322_160` => `0xF0F0_F0F0` +``` \ No newline at end of file diff --git a/src/docs/declare_interior_mutable_const.txt b/src/docs/declare_interior_mutable_const.txt new file mode 100644 index 00000000000..2801b5ccff8 --- /dev/null +++ b/src/docs/declare_interior_mutable_const.txt @@ -0,0 +1,46 @@ +### What it does +Checks for declaration of `const` items which is interior +mutable (e.g., contains a `Cell`, `Mutex`, `AtomicXxxx`, etc.). + +### Why is this bad? +Consts are copied everywhere they are referenced, i.e., +every time you refer to the const a fresh instance of the `Cell` or `Mutex` +or `AtomicXxxx` will be created, which defeats the whole purpose of using +these types in the first place. + +The `const` should better be replaced by a `static` item if a global +variable is wanted, or replaced by a `const fn` if a constructor is wanted. + +### Known problems +A "non-constant" const item is a legacy way to supply an +initialized value to downstream `static` items (e.g., the +`std::sync::ONCE_INIT` constant). In this case the use of `const` is legit, +and this lint should be suppressed. + +Even though the lint avoids triggering on a constant whose type has enums that have variants +with interior mutability, and its value uses non interior mutable variants (see +[#3962](https://github.com/rust-lang/rust-clippy/issues/3962) and +[#3825](https://github.com/rust-lang/rust-clippy/issues/3825) for examples); +it complains about associated constants without default values only based on its types; +which might not be preferable. +There're other enums plus associated constants cases that the lint cannot handle. + +Types that have underlying or potential interior mutability trigger the lint whether +the interior mutable field is used or not. See issues +[#5812](https://github.com/rust-lang/rust-clippy/issues/5812) and + +### Example +``` +use std::sync::atomic::{AtomicUsize, Ordering::SeqCst}; + +const CONST_ATOM: AtomicUsize = AtomicUsize::new(12); +CONST_ATOM.store(6, SeqCst); // the content of the atomic is unchanged +assert_eq!(CONST_ATOM.load(SeqCst), 12); // because the CONST_ATOM in these lines are distinct +``` + +Use instead: +``` +static STATIC_ATOM: AtomicUsize = AtomicUsize::new(15); +STATIC_ATOM.store(9, SeqCst); +assert_eq!(STATIC_ATOM.load(SeqCst), 9); // use a `static` item to refer to the same instance +``` \ No newline at end of file diff --git a/src/docs/default_instead_of_iter_empty.txt b/src/docs/default_instead_of_iter_empty.txt new file mode 100644 index 00000000000..b63ef3d18fc --- /dev/null +++ b/src/docs/default_instead_of_iter_empty.txt @@ -0,0 +1,15 @@ +### What it does +It checks for `std::iter::Empty::default()` and suggests replacing it with +`std::iter::empty()`. +### Why is this bad? +`std::iter::empty()` is the more idiomatic way. +### Example +``` +let _ = std::iter::Empty::::default(); +let iter: std::iter::Empty = std::iter::Empty::default(); +``` +Use instead: +``` +let _ = std::iter::empty::(); +let iter: std::iter::Empty = std::iter::empty(); +``` \ No newline at end of file diff --git a/src/docs/default_numeric_fallback.txt b/src/docs/default_numeric_fallback.txt new file mode 100644 index 00000000000..15076a0a68b --- /dev/null +++ b/src/docs/default_numeric_fallback.txt @@ -0,0 +1,28 @@ +### What it does +Checks for usage of unconstrained numeric literals which may cause default numeric fallback in type +inference. + +Default numeric fallback means that if numeric types have not yet been bound to concrete +types at the end of type inference, then integer type is bound to `i32`, and similarly +floating type is bound to `f64`. + +See [RFC0212](https://github.com/rust-lang/rfcs/blob/master/text/0212-restore-int-fallback.md) for more information about the fallback. + +### Why is this bad? +For those who are very careful about types, default numeric fallback +can be a pitfall that cause unexpected runtime behavior. + +### Known problems +This lint can only be allowed at the function level or above. + +### Example +``` +let i = 10; +let f = 1.23; +``` + +Use instead: +``` +let i = 10i32; +let f = 1.23f64; +``` \ No newline at end of file diff --git a/src/docs/default_trait_access.txt b/src/docs/default_trait_access.txt new file mode 100644 index 00000000000..e69298969c8 --- /dev/null +++ b/src/docs/default_trait_access.txt @@ -0,0 +1,16 @@ +### What it does +Checks for literal calls to `Default::default()`. + +### Why is this bad? +It's easier for the reader if the name of the type is used, rather than the +generic `Default`. + +### Example +``` +let s: String = Default::default(); +``` + +Use instead: +``` +let s = String::default(); +``` \ No newline at end of file diff --git a/src/docs/default_union_representation.txt b/src/docs/default_union_representation.txt new file mode 100644 index 00000000000..f79ff9760e5 --- /dev/null +++ b/src/docs/default_union_representation.txt @@ -0,0 +1,36 @@ +### What it does +Displays a warning when a union is declared with the default representation (without a `#[repr(C)]` attribute). + +### Why is this bad? +Unions in Rust have unspecified layout by default, despite many people thinking that they +lay out each field at the start of the union (like C does). That is, there are no guarantees +about the offset of the fields for unions with multiple non-ZST fields without an explicitly +specified layout. These cases may lead to undefined behavior in unsafe blocks. + +### Example +``` +union Foo { + a: i32, + b: u32, +} + +fn main() { + let _x: u32 = unsafe { + Foo { a: 0_i32 }.b // Undefined behavior: `b` is allowed to be padding + }; +} +``` +Use instead: +``` +#[repr(C)] +union Foo { + a: i32, + b: u32, +} + +fn main() { + let _x: u32 = unsafe { + Foo { a: 0_i32 }.b // Now defined behavior, this is just an i32 -> u32 transmute + }; +} +``` \ No newline at end of file diff --git a/src/docs/deprecated_cfg_attr.txt b/src/docs/deprecated_cfg_attr.txt new file mode 100644 index 00000000000..9f264887a05 --- /dev/null +++ b/src/docs/deprecated_cfg_attr.txt @@ -0,0 +1,24 @@ +### What it does +Checks for `#[cfg_attr(rustfmt, rustfmt_skip)]` and suggests to replace it +with `#[rustfmt::skip]`. + +### Why is this bad? +Since tool_attributes ([rust-lang/rust#44690](https://github.com/rust-lang/rust/issues/44690)) +are stable now, they should be used instead of the old `cfg_attr(rustfmt)` attributes. + +### Known problems +This lint doesn't detect crate level inner attributes, because they get +processed before the PreExpansionPass lints get executed. See +[#3123](https://github.com/rust-lang/rust-clippy/pull/3123#issuecomment-422321765) + +### Example +``` +#[cfg_attr(rustfmt, rustfmt_skip)] +fn main() { } +``` + +Use instead: +``` +#[rustfmt::skip] +fn main() { } +``` \ No newline at end of file diff --git a/src/docs/deprecated_semver.txt b/src/docs/deprecated_semver.txt new file mode 100644 index 00000000000..c9574a99b2b --- /dev/null +++ b/src/docs/deprecated_semver.txt @@ -0,0 +1,13 @@ +### What it does +Checks for `#[deprecated]` annotations with a `since` +field that is not a valid semantic version. + +### Why is this bad? +For checking the version of the deprecation, it must be +a valid semver. Failing that, the contained information is useless. + +### Example +``` +#[deprecated(since = "forever")] +fn something_else() { /* ... */ } +``` \ No newline at end of file diff --git a/src/docs/deref_addrof.txt b/src/docs/deref_addrof.txt new file mode 100644 index 00000000000..fa711b924d4 --- /dev/null +++ b/src/docs/deref_addrof.txt @@ -0,0 +1,22 @@ +### What it does +Checks for usage of `*&` and `*&mut` in expressions. + +### Why is this bad? +Immediately dereferencing a reference is no-op and +makes the code less clear. + +### Known problems +Multiple dereference/addrof pairs are not handled so +the suggested fix for `x = **&&y` is `x = *&y`, which is still incorrect. + +### Example +``` +let a = f(*&mut b); +let c = *&d; +``` + +Use instead: +``` +let a = f(b); +let c = d; +``` \ No newline at end of file diff --git a/src/docs/deref_by_slicing.txt b/src/docs/deref_by_slicing.txt new file mode 100644 index 00000000000..4dad24ac00c --- /dev/null +++ b/src/docs/deref_by_slicing.txt @@ -0,0 +1,17 @@ +### What it does +Checks for slicing expressions which are equivalent to dereferencing the +value. + +### Why is this bad? +Some people may prefer to dereference rather than slice. + +### Example +``` +let vec = vec![1, 2, 3]; +let slice = &vec[..]; +``` +Use instead: +``` +let vec = vec![1, 2, 3]; +let slice = &*vec; +``` \ No newline at end of file diff --git a/src/docs/derivable_impls.txt b/src/docs/derivable_impls.txt new file mode 100644 index 00000000000..8e4a80a672c --- /dev/null +++ b/src/docs/derivable_impls.txt @@ -0,0 +1,35 @@ +### What it does +Detects manual `std::default::Default` implementations that are identical to a derived implementation. + +### Why is this bad? +It is less concise. + +### Example +``` +struct Foo { + bar: bool +} + +impl Default for Foo { + fn default() -> Self { + Self { + bar: false + } + } +} +``` + +Use instead: +``` +#[derive(Default)] +struct Foo { + bar: bool +} +``` + +### Known problems +Derive macros [sometimes use incorrect bounds](https://github.com/rust-lang/rust/issues/26925) +in generic types and the user defined `impl` maybe is more generalized or +specialized than what derive will produce. This lint can't detect the manual `impl` +has exactly equal bounds, and therefore this lint is disabled for types with +generic parameters. \ No newline at end of file diff --git a/src/docs/derive_hash_xor_eq.txt b/src/docs/derive_hash_xor_eq.txt new file mode 100644 index 00000000000..fbf623d5adb --- /dev/null +++ b/src/docs/derive_hash_xor_eq.txt @@ -0,0 +1,23 @@ +### What it does +Checks for deriving `Hash` but implementing `PartialEq` +explicitly or vice versa. + +### Why is this bad? +The implementation of these traits must agree (for +example for use with `HashMap`) so it’s probably a bad idea to use a +default-generated `Hash` implementation with an explicitly defined +`PartialEq`. In particular, the following must hold for any type: + +``` +k1 == k2 ⇒ hash(k1) == hash(k2) +``` + +### Example +``` +#[derive(Hash)] +struct Foo; + +impl PartialEq for Foo { + ... +} +``` \ No newline at end of file diff --git a/src/docs/derive_ord_xor_partial_ord.txt b/src/docs/derive_ord_xor_partial_ord.txt new file mode 100644 index 00000000000..f2107a5f69e --- /dev/null +++ b/src/docs/derive_ord_xor_partial_ord.txt @@ -0,0 +1,44 @@ +### What it does +Checks for deriving `Ord` but implementing `PartialOrd` +explicitly or vice versa. + +### Why is this bad? +The implementation of these traits must agree (for +example for use with `sort`) so it’s probably a bad idea to use a +default-generated `Ord` implementation with an explicitly defined +`PartialOrd`. In particular, the following must hold for any type +implementing `Ord`: + +``` +k1.cmp(&k2) == k1.partial_cmp(&k2).unwrap() +``` + +### Example +``` +#[derive(Ord, PartialEq, Eq)] +struct Foo; + +impl PartialOrd for Foo { + ... +} +``` +Use instead: +``` +#[derive(PartialEq, Eq)] +struct Foo; + +impl PartialOrd for Foo { + fn partial_cmp(&self, other: &Foo) -> Option { + Some(self.cmp(other)) + } +} + +impl Ord for Foo { + ... +} +``` +or, if you don't need a custom ordering: +``` +#[derive(Ord, PartialOrd, PartialEq, Eq)] +struct Foo; +``` \ No newline at end of file diff --git a/src/docs/derive_partial_eq_without_eq.txt b/src/docs/derive_partial_eq_without_eq.txt new file mode 100644 index 00000000000..932fabad666 --- /dev/null +++ b/src/docs/derive_partial_eq_without_eq.txt @@ -0,0 +1,25 @@ +### What it does +Checks for types that derive `PartialEq` and could implement `Eq`. + +### Why is this bad? +If a type `T` derives `PartialEq` and all of its members implement `Eq`, +then `T` can always implement `Eq`. Implementing `Eq` allows `T` to be used +in APIs that require `Eq` types. It also allows structs containing `T` to derive +`Eq` themselves. + +### Example +``` +#[derive(PartialEq)] +struct Foo { + i_am_eq: i32, + i_am_eq_too: Vec, +} +``` +Use instead: +``` +#[derive(PartialEq, Eq)] +struct Foo { + i_am_eq: i32, + i_am_eq_too: Vec, +} +``` \ No newline at end of file diff --git a/src/docs/disallowed_methods.txt b/src/docs/disallowed_methods.txt new file mode 100644 index 00000000000..d8ad5b6a667 --- /dev/null +++ b/src/docs/disallowed_methods.txt @@ -0,0 +1,41 @@ +### What it does +Denies the configured methods and functions in clippy.toml + +Note: Even though this lint is warn-by-default, it will only trigger if +methods are defined in the clippy.toml file. + +### Why is this bad? +Some methods are undesirable in certain contexts, and it's beneficial to +lint for them as needed. + +### Example +An example clippy.toml configuration: +``` +disallowed-methods = [ + # Can use a string as the path of the disallowed method. + "std::boxed::Box::new", + # Can also use an inline table with a `path` key. + { path = "std::time::Instant::now" }, + # When using an inline table, can add a `reason` for why the method + # is disallowed. + { path = "std::vec::Vec::leak", reason = "no leaking memory" }, +] +``` + +``` +// Example code where clippy issues a warning +let xs = vec![1, 2, 3, 4]; +xs.leak(); // Vec::leak is disallowed in the config. +// The diagnostic contains the message "no leaking memory". + +let _now = Instant::now(); // Instant::now is disallowed in the config. + +let _box = Box::new(3); // Box::new is disallowed in the config. +``` + +Use instead: +``` +// Example code which does not raise clippy warning +let mut xs = Vec::new(); // Vec::new is _not_ disallowed in the config. +xs.push(123); // Vec::push is _not_ disallowed in the config. +``` \ No newline at end of file diff --git a/src/docs/disallowed_names.txt b/src/docs/disallowed_names.txt new file mode 100644 index 00000000000..f4aaee9c77b --- /dev/null +++ b/src/docs/disallowed_names.txt @@ -0,0 +1,12 @@ +### What it does +Checks for usage of disallowed names for variables, such +as `foo`. + +### Why is this bad? +These names are usually placeholder names and should be +avoided. + +### Example +``` +let foo = 3.14; +``` \ No newline at end of file diff --git a/src/docs/disallowed_script_idents.txt b/src/docs/disallowed_script_idents.txt new file mode 100644 index 00000000000..2151b7a20de --- /dev/null +++ b/src/docs/disallowed_script_idents.txt @@ -0,0 +1,32 @@ +### What it does +Checks for usage of unicode scripts other than those explicitly allowed +by the lint config. + +This lint doesn't take into account non-text scripts such as `Unknown` and `Linear_A`. +It also ignores the `Common` script type. +While configuring, be sure to use official script name [aliases] from +[the list of supported scripts][supported_scripts]. + +See also: [`non_ascii_idents`]. + +[aliases]: http://www.unicode.org/reports/tr24/tr24-31.html#Script_Value_Aliases +[supported_scripts]: https://www.unicode.org/iso15924/iso15924-codes.html + +### Why is this bad? +It may be not desired to have many different scripts for +identifiers in the codebase. + +Note that if you only want to allow plain English, you might want to use +built-in [`non_ascii_idents`] lint instead. + +[`non_ascii_idents`]: https://doc.rust-lang.org/rustc/lints/listing/allowed-by-default.html#non-ascii-idents + +### Example +``` +// Assuming that `clippy.toml` contains the following line: +// allowed-locales = ["Latin", "Cyrillic"] +let counter = 10; // OK, latin is allowed. +let счётчик = 10; // OK, cyrillic is allowed. +let zähler = 10; // OK, it's still latin. +let カウンタ = 10; // Will spawn the lint. +``` \ No newline at end of file diff --git a/src/docs/disallowed_types.txt b/src/docs/disallowed_types.txt new file mode 100644 index 00000000000..2bcbcddee56 --- /dev/null +++ b/src/docs/disallowed_types.txt @@ -0,0 +1,33 @@ +### What it does +Denies the configured types in clippy.toml. + +Note: Even though this lint is warn-by-default, it will only trigger if +types are defined in the clippy.toml file. + +### Why is this bad? +Some types are undesirable in certain contexts. + +### Example: +An example clippy.toml configuration: +``` +disallowed-types = [ + # Can use a string as the path of the disallowed type. + "std::collections::BTreeMap", + # Can also use an inline table with a `path` key. + { path = "std::net::TcpListener" }, + # When using an inline table, can add a `reason` for why the type + # is disallowed. + { path = "std::net::Ipv4Addr", reason = "no IPv4 allowed" }, +] +``` + +``` +use std::collections::BTreeMap; +// or its use +let x = std::collections::BTreeMap::new(); +``` +Use instead: +``` +// A similar type that is allowed by the config +use std::collections::HashMap; +``` \ No newline at end of file diff --git a/src/docs/diverging_sub_expression.txt b/src/docs/diverging_sub_expression.txt new file mode 100644 index 00000000000..19436221802 --- /dev/null +++ b/src/docs/diverging_sub_expression.txt @@ -0,0 +1,19 @@ +### What it does +Checks for diverging calls that are not match arms or +statements. + +### Why is this bad? +It is often confusing to read. In addition, the +sub-expression evaluation order for Rust is not well documented. + +### Known problems +Someone might want to use `some_bool || panic!()` as a +shorthand. + +### Example +``` +let a = b() || panic!() || c(); +// `c()` is dead, `panic!()` is only called if `b()` returns `false` +let x = (a, b, c, panic!()); +// can simply be replaced by `panic!()` +``` \ No newline at end of file diff --git a/src/docs/doc_link_with_quotes.txt b/src/docs/doc_link_with_quotes.txt new file mode 100644 index 00000000000..107c8ac116d --- /dev/null +++ b/src/docs/doc_link_with_quotes.txt @@ -0,0 +1,16 @@ +### What it does +Detects the syntax `['foo']` in documentation comments (notice quotes instead of backticks) +outside of code blocks +### Why is this bad? +It is likely a typo when defining an intra-doc link + +### Example +``` +/// See also: ['foo'] +fn bar() {} +``` +Use instead: +``` +/// See also: [`foo`] +fn bar() {} +``` \ No newline at end of file diff --git a/src/docs/doc_markdown.txt b/src/docs/doc_markdown.txt new file mode 100644 index 00000000000..94f54c587e3 --- /dev/null +++ b/src/docs/doc_markdown.txt @@ -0,0 +1,35 @@ +### What it does +Checks for the presence of `_`, `::` or camel-case words +outside ticks in documentation. + +### Why is this bad? +*Rustdoc* supports markdown formatting, `_`, `::` and +camel-case probably indicates some code which should be included between +ticks. `_` can also be used for emphasis in markdown, this lint tries to +consider that. + +### Known problems +Lots of bad docs won’t be fixed, what the lint checks +for is limited, and there are still false positives. HTML elements and their +content are not linted. + +In addition, when writing documentation comments, including `[]` brackets +inside a link text would trip the parser. Therefore, documenting link with +`[`SmallVec<[T; INLINE_CAPACITY]>`]` and then [`SmallVec<[T; INLINE_CAPACITY]>`]: SmallVec +would fail. + +### Examples +``` +/// Do something with the foo_bar parameter. See also +/// that::other::module::foo. +// ^ `foo_bar` and `that::other::module::foo` should be ticked. +fn doit(foo_bar: usize) {} +``` + +``` +// Link text with `[]` brackets should be written as following: +/// Consume the array and return the inner +/// [`SmallVec<[T; INLINE_CAPACITY]>`][SmallVec]. +/// [SmallVec]: SmallVec +fn main() {} +``` \ No newline at end of file diff --git a/src/docs/double_comparisons.txt b/src/docs/double_comparisons.txt new file mode 100644 index 00000000000..7dc6818779f --- /dev/null +++ b/src/docs/double_comparisons.txt @@ -0,0 +1,17 @@ +### What it does +Checks for double comparisons that could be simplified to a single expression. + + +### Why is this bad? +Readability. + +### Example +``` +if x == y || x < y {} +``` + +Use instead: + +``` +if x <= y {} +``` \ No newline at end of file diff --git a/src/docs/double_must_use.txt b/src/docs/double_must_use.txt new file mode 100644 index 00000000000..0017d10d40d --- /dev/null +++ b/src/docs/double_must_use.txt @@ -0,0 +1,17 @@ +### What it does +Checks for a `#[must_use]` attribute without +further information on functions and methods that return a type already +marked as `#[must_use]`. + +### Why is this bad? +The attribute isn't needed. Not using the result +will already be reported. Alternatively, one can add some text to the +attribute to improve the lint message. + +### Examples +``` +#[must_use] +fn double_must_use() -> Result<(), ()> { + unimplemented!(); +} +``` \ No newline at end of file diff --git a/src/docs/double_neg.txt b/src/docs/double_neg.txt new file mode 100644 index 00000000000..a07f67496d7 --- /dev/null +++ b/src/docs/double_neg.txt @@ -0,0 +1,12 @@ +### What it does +Detects expressions of the form `--x`. + +### Why is this bad? +It can mislead C/C++ programmers to think `x` was +decremented. + +### Example +``` +let mut x = 3; +--x; +``` \ No newline at end of file diff --git a/src/docs/double_parens.txt b/src/docs/double_parens.txt new file mode 100644 index 00000000000..260d7dd575e --- /dev/null +++ b/src/docs/double_parens.txt @@ -0,0 +1,24 @@ +### What it does +Checks for unnecessary double parentheses. + +### Why is this bad? +This makes code harder to read and might indicate a +mistake. + +### Example +``` +fn simple_double_parens() -> i32 { + ((0)) +} + +foo((0)); +``` + +Use instead: +``` +fn simple_no_parens() -> i32 { + 0 +} + +foo(0); +``` \ No newline at end of file diff --git a/src/docs/drop_copy.txt b/src/docs/drop_copy.txt new file mode 100644 index 00000000000..f917ca8ed21 --- /dev/null +++ b/src/docs/drop_copy.txt @@ -0,0 +1,15 @@ +### What it does +Checks for calls to `std::mem::drop` with a value +that derives the Copy trait + +### Why is this bad? +Calling `std::mem::drop` [does nothing for types that +implement Copy](https://doc.rust-lang.org/std/mem/fn.drop.html), since the +value will be copied and moved into the function on invocation. + +### Example +``` +let x: i32 = 42; // i32 implements Copy +std::mem::drop(x) // A copy of x is passed to the function, leaving the + // original unaffected +``` \ No newline at end of file diff --git a/src/docs/drop_non_drop.txt b/src/docs/drop_non_drop.txt new file mode 100644 index 00000000000..ee1e3a6c216 --- /dev/null +++ b/src/docs/drop_non_drop.txt @@ -0,0 +1,13 @@ +### What it does +Checks for calls to `std::mem::drop` with a value that does not implement `Drop`. + +### Why is this bad? +Calling `std::mem::drop` is no different than dropping such a type. A different value may +have been intended. + +### Example +``` +struct Foo; +let x = Foo; +std::mem::drop(x); +``` \ No newline at end of file diff --git a/src/docs/drop_ref.txt b/src/docs/drop_ref.txt new file mode 100644 index 00000000000..c4f7adf0cfa --- /dev/null +++ b/src/docs/drop_ref.txt @@ -0,0 +1,17 @@ +### What it does +Checks for calls to `std::mem::drop` with a reference +instead of an owned value. + +### Why is this bad? +Calling `drop` on a reference will only drop the +reference itself, which is a no-op. It will not call the `drop` method (from +the `Drop` trait implementation) on the underlying referenced value, which +is likely what was intended. + +### Example +``` +let mut lock_guard = mutex.lock(); +std::mem::drop(&lock_guard) // Should have been drop(lock_guard), mutex +// still locked +operation_that_requires_mutex_to_be_unlocked(); +``` \ No newline at end of file diff --git a/src/docs/duplicate_mod.txt b/src/docs/duplicate_mod.txt new file mode 100644 index 00000000000..709a9aba03a --- /dev/null +++ b/src/docs/duplicate_mod.txt @@ -0,0 +1,31 @@ +### What it does +Checks for files that are included as modules multiple times. + +### Why is this bad? +Loading a file as a module more than once causes it to be compiled +multiple times, taking longer and putting duplicate content into the +module tree. + +### Example +``` +// lib.rs +mod a; +mod b; +``` +``` +// a.rs +#[path = "./b.rs"] +mod b; +``` + +Use instead: + +``` +// lib.rs +mod a; +mod b; +``` +``` +// a.rs +use crate::b; +``` \ No newline at end of file diff --git a/src/docs/duplicate_underscore_argument.txt b/src/docs/duplicate_underscore_argument.txt new file mode 100644 index 00000000000..a8fcd6a9fbe --- /dev/null +++ b/src/docs/duplicate_underscore_argument.txt @@ -0,0 +1,16 @@ +### What it does +Checks for function arguments having the similar names +differing by an underscore. + +### Why is this bad? +It affects code readability. + +### Example +``` +fn foo(a: i32, _a: i32) {} +``` + +Use instead: +``` +fn bar(a: i32, _b: i32) {} +``` \ No newline at end of file diff --git a/src/docs/duration_subsec.txt b/src/docs/duration_subsec.txt new file mode 100644 index 00000000000..e7e0ca88745 --- /dev/null +++ b/src/docs/duration_subsec.txt @@ -0,0 +1,19 @@ +### What it does +Checks for calculation of subsecond microseconds or milliseconds +from other `Duration` methods. + +### Why is this bad? +It's more concise to call `Duration::subsec_micros()` or +`Duration::subsec_millis()` than to calculate them. + +### Example +``` +let micros = duration.subsec_nanos() / 1_000; +let millis = duration.subsec_nanos() / 1_000_000; +``` + +Use instead: +``` +let micros = duration.subsec_micros(); +let millis = duration.subsec_millis(); +``` \ No newline at end of file diff --git a/src/docs/else_if_without_else.txt b/src/docs/else_if_without_else.txt new file mode 100644 index 00000000000..33f5d0f9185 --- /dev/null +++ b/src/docs/else_if_without_else.txt @@ -0,0 +1,27 @@ +### What it does +Checks for usage of if expressions with an `else if` branch, +but without a final `else` branch. + +### Why is this bad? +Some coding guidelines require this (e.g., MISRA-C:2004 Rule 14.10). + +### Example +``` +if x.is_positive() { + a(); +} else if x.is_negative() { + b(); +} +``` + +Use instead: + +``` +if x.is_positive() { + a(); +} else if x.is_negative() { + b(); +} else { + // We don't care about zero. +} +``` \ No newline at end of file diff --git a/src/docs/empty_drop.txt b/src/docs/empty_drop.txt new file mode 100644 index 00000000000..d0c0c24a9c8 --- /dev/null +++ b/src/docs/empty_drop.txt @@ -0,0 +1,20 @@ +### What it does +Checks for empty `Drop` implementations. + +### Why is this bad? +Empty `Drop` implementations have no effect when dropping an instance of the type. They are +most likely useless. However, an empty `Drop` implementation prevents a type from being +destructured, which might be the intention behind adding the implementation as a marker. + +### Example +``` +struct S; + +impl Drop for S { + fn drop(&mut self) {} +} +``` +Use instead: +``` +struct S; +``` \ No newline at end of file diff --git a/src/docs/empty_enum.txt b/src/docs/empty_enum.txt new file mode 100644 index 00000000000..f7b41c41ee5 --- /dev/null +++ b/src/docs/empty_enum.txt @@ -0,0 +1,27 @@ +### What it does +Checks for `enum`s with no variants. + +As of this writing, the `never_type` is still a +nightly-only experimental API. Therefore, this lint is only triggered +if the `never_type` is enabled. + +### Why is this bad? +If you want to introduce a type which +can't be instantiated, you should use `!` (the primitive type "never"), +or a wrapper around it, because `!` has more extensive +compiler support (type inference, etc...) and wrappers +around it are the conventional way to define an uninhabited type. +For further information visit [never type documentation](https://doc.rust-lang.org/std/primitive.never.html) + + +### Example +``` +enum Test {} +``` + +Use instead: +``` +#![feature(never_type)] + +struct Test(!); +``` \ No newline at end of file diff --git a/src/docs/empty_line_after_outer_attr.txt b/src/docs/empty_line_after_outer_attr.txt new file mode 100644 index 00000000000..c85242bbee0 --- /dev/null +++ b/src/docs/empty_line_after_outer_attr.txt @@ -0,0 +1,35 @@ +### What it does +Checks for empty lines after outer attributes + +### Why is this bad? +Most likely the attribute was meant to be an inner attribute using a '!'. +If it was meant to be an outer attribute, then the following item +should not be separated by empty lines. + +### Known problems +Can cause false positives. + +From the clippy side it's difficult to detect empty lines between an attributes and the +following item because empty lines and comments are not part of the AST. The parsing +currently works for basic cases but is not perfect. + +### Example +``` +#[allow(dead_code)] + +fn not_quite_good_code() { } +``` + +Use instead: +``` +// Good (as inner attribute) +#![allow(dead_code)] + +fn this_is_fine() { } + +// or + +// Good (as outer attribute) +#[allow(dead_code)] +fn this_is_fine_too() { } +``` \ No newline at end of file diff --git a/src/docs/empty_loop.txt b/src/docs/empty_loop.txt new file mode 100644 index 00000000000..fea49a74d04 --- /dev/null +++ b/src/docs/empty_loop.txt @@ -0,0 +1,27 @@ +### What it does +Checks for empty `loop` expressions. + +### Why is this bad? +These busy loops burn CPU cycles without doing +anything. It is _almost always_ a better idea to `panic!` than to have +a busy loop. + +If panicking isn't possible, think of the environment and either: + - block on something + - sleep the thread for some microseconds + - yield or pause the thread + +For `std` targets, this can be done with +[`std::thread::sleep`](https://doc.rust-lang.org/std/thread/fn.sleep.html) +or [`std::thread::yield_now`](https://doc.rust-lang.org/std/thread/fn.yield_now.html). + +For `no_std` targets, doing this is more complicated, especially because +`#[panic_handler]`s can't panic. To stop/pause the thread, you will +probably need to invoke some target-specific intrinsic. Examples include: + - [`x86_64::instructions::hlt`](https://docs.rs/x86_64/0.12.2/x86_64/instructions/fn.hlt.html) + - [`cortex_m::asm::wfi`](https://docs.rs/cortex-m/0.6.3/cortex_m/asm/fn.wfi.html) + +### Example +``` +loop {} +``` \ No newline at end of file diff --git a/src/docs/empty_structs_with_brackets.txt b/src/docs/empty_structs_with_brackets.txt new file mode 100644 index 00000000000..ab5e35ae2ad --- /dev/null +++ b/src/docs/empty_structs_with_brackets.txt @@ -0,0 +1,14 @@ +### What it does +Finds structs without fields (a so-called "empty struct") that are declared with brackets. + +### Why is this bad? +Empty brackets after a struct declaration can be omitted. + +### Example +``` +struct Cookie {} +``` +Use instead: +``` +struct Cookie; +``` \ No newline at end of file diff --git a/src/docs/enum_clike_unportable_variant.txt b/src/docs/enum_clike_unportable_variant.txt new file mode 100644 index 00000000000..d30a973a5a1 --- /dev/null +++ b/src/docs/enum_clike_unportable_variant.txt @@ -0,0 +1,16 @@ +### What it does +Checks for C-like enumerations that are +`repr(isize/usize)` and have values that don't fit into an `i32`. + +### Why is this bad? +This will truncate the variant value on 32 bit +architectures, but works fine on 64 bit. + +### Example +``` +#[repr(usize)] +enum NonPortable { + X = 0x1_0000_0000, + Y = 0, +} +``` \ No newline at end of file diff --git a/src/docs/enum_glob_use.txt b/src/docs/enum_glob_use.txt new file mode 100644 index 00000000000..3776822c35b --- /dev/null +++ b/src/docs/enum_glob_use.txt @@ -0,0 +1,24 @@ +### What it does +Checks for `use Enum::*`. + +### Why is this bad? +It is usually better style to use the prefixed name of +an enumeration variant, rather than importing variants. + +### Known problems +Old-style enumerations that prefix the variants are +still around. + +### Example +``` +use std::cmp::Ordering::*; + +foo(Less); +``` + +Use instead: +``` +use std::cmp::Ordering; + +foo(Ordering::Less) +``` \ No newline at end of file diff --git a/src/docs/enum_variant_names.txt b/src/docs/enum_variant_names.txt new file mode 100644 index 00000000000..e726925edda --- /dev/null +++ b/src/docs/enum_variant_names.txt @@ -0,0 +1,30 @@ +### What it does +Detects enumeration variants that are prefixed or suffixed +by the same characters. + +### Why is this bad? +Enumeration variant names should specify their variant, +not repeat the enumeration name. + +### Limitations +Characters with no casing will be considered when comparing prefixes/suffixes +This applies to numbers and non-ascii characters without casing +e.g. `Foo1` and `Foo2` is considered to have different prefixes +(the prefixes are `Foo1` and `Foo2` respectively), as also `Bar螃`, `Bar蟹` + +### Example +``` +enum Cake { + BlackForestCake, + HummingbirdCake, + BattenbergCake, +} +``` +Use instead: +``` +enum Cake { + BlackForest, + Hummingbird, + Battenberg, +} +``` \ No newline at end of file diff --git a/src/docs/eq_op.txt b/src/docs/eq_op.txt new file mode 100644 index 00000000000..2d75a0ec546 --- /dev/null +++ b/src/docs/eq_op.txt @@ -0,0 +1,22 @@ +### What it does +Checks for equal operands to comparison, logical and +bitwise, difference and division binary operators (`==`, `>`, etc., `&&`, +`||`, `&`, `|`, `^`, `-` and `/`). + +### Why is this bad? +This is usually just a typo or a copy and paste error. + +### Known problems +False negatives: We had some false positives regarding +calls (notably [racer](https://github.com/phildawes/racer) had one instance +of `x.pop() && x.pop()`), so we removed matching any function or method +calls. We may introduce a list of known pure functions in the future. + +### Example +``` +if x + 1 == x + 1 {} + +// or + +assert_eq!(a, a); +``` \ No newline at end of file diff --git a/src/docs/equatable_if_let.txt b/src/docs/equatable_if_let.txt new file mode 100644 index 00000000000..9997046954c --- /dev/null +++ b/src/docs/equatable_if_let.txt @@ -0,0 +1,23 @@ +### What it does +Checks for pattern matchings that can be expressed using equality. + +### Why is this bad? + +* It reads better and has less cognitive load because equality won't cause binding. +* It is a [Yoda condition](https://en.wikipedia.org/wiki/Yoda_conditions). Yoda conditions are widely +criticized for increasing the cognitive load of reading the code. +* Equality is a simple bool expression and can be merged with `&&` and `||` and +reuse if blocks + +### Example +``` +if let Some(2) = x { + do_thing(); +} +``` +Use instead: +``` +if x == Some(2) { + do_thing(); +} +``` \ No newline at end of file diff --git a/src/docs/erasing_op.txt b/src/docs/erasing_op.txt new file mode 100644 index 00000000000..3d285a6d86e --- /dev/null +++ b/src/docs/erasing_op.txt @@ -0,0 +1,15 @@ +### What it does +Checks for erasing operations, e.g., `x * 0`. + +### Why is this bad? +The whole expression can be replaced by zero. +This is most likely not the intended outcome and should probably be +corrected + +### Example +``` +let x = 1; +0 / x; +0 * x; +x & 0; +``` \ No newline at end of file diff --git a/src/docs/err_expect.txt b/src/docs/err_expect.txt new file mode 100644 index 00000000000..1dc83c5ce0e --- /dev/null +++ b/src/docs/err_expect.txt @@ -0,0 +1,16 @@ +### What it does +Checks for `.err().expect()` calls on the `Result` type. + +### Why is this bad? +`.expect_err()` can be called directly to avoid the extra type conversion from `err()`. + +### Example +``` +let x: Result = Ok(10); +x.err().expect("Testing err().expect()"); +``` +Use instead: +``` +let x: Result = Ok(10); +x.expect_err("Testing expect_err"); +``` \ No newline at end of file diff --git a/src/docs/excessive_precision.txt b/src/docs/excessive_precision.txt new file mode 100644 index 00000000000..517879c4715 --- /dev/null +++ b/src/docs/excessive_precision.txt @@ -0,0 +1,18 @@ +### What it does +Checks for float literals with a precision greater +than that supported by the underlying type. + +### Why is this bad? +Rust will truncate the literal silently. + +### Example +``` +let v: f32 = 0.123_456_789_9; +println!("{}", v); // 0.123_456_789 +``` + +Use instead: +``` +let v: f64 = 0.123_456_789_9; +println!("{}", v); // 0.123_456_789_9 +``` \ No newline at end of file diff --git a/src/docs/exhaustive_enums.txt b/src/docs/exhaustive_enums.txt new file mode 100644 index 00000000000..d1032a7a29a --- /dev/null +++ b/src/docs/exhaustive_enums.txt @@ -0,0 +1,23 @@ +### What it does +Warns on any exported `enum`s that are not tagged `#[non_exhaustive]` + +### Why is this bad? +Exhaustive enums are typically fine, but a project which does +not wish to make a stability commitment around exported enums may wish to +disable them by default. + +### Example +``` +enum Foo { + Bar, + Baz +} +``` +Use instead: +``` +#[non_exhaustive] +enum Foo { + Bar, + Baz +} +``` \ No newline at end of file diff --git a/src/docs/exhaustive_structs.txt b/src/docs/exhaustive_structs.txt new file mode 100644 index 00000000000..fd6e4f5caf1 --- /dev/null +++ b/src/docs/exhaustive_structs.txt @@ -0,0 +1,23 @@ +### What it does +Warns on any exported `structs`s that are not tagged `#[non_exhaustive]` + +### Why is this bad? +Exhaustive structs are typically fine, but a project which does +not wish to make a stability commitment around exported structs may wish to +disable them by default. + +### Example +``` +struct Foo { + bar: u8, + baz: String, +} +``` +Use instead: +``` +#[non_exhaustive] +struct Foo { + bar: u8, + baz: String, +} +``` \ No newline at end of file diff --git a/src/docs/exit.txt b/src/docs/exit.txt new file mode 100644 index 00000000000..1e6154d43e0 --- /dev/null +++ b/src/docs/exit.txt @@ -0,0 +1,12 @@ +### What it does +`exit()` terminates the program and doesn't provide a +stack trace. + +### Why is this bad? +Ideally a program is terminated by finishing +the main function. + +### Example +``` +std::process::exit(0) +``` \ No newline at end of file diff --git a/src/docs/expect_fun_call.txt b/src/docs/expect_fun_call.txt new file mode 100644 index 00000000000..d82d9aa9baf --- /dev/null +++ b/src/docs/expect_fun_call.txt @@ -0,0 +1,24 @@ +### What it does +Checks for calls to `.expect(&format!(...))`, `.expect(foo(..))`, +etc., and suggests to use `unwrap_or_else` instead + +### Why is this bad? +The function will always be called. + +### Known problems +If the function has side-effects, not calling it will +change the semantics of the program, but you shouldn't rely on that anyway. + +### Example +``` +foo.expect(&format!("Err {}: {}", err_code, err_msg)); + +// or + +foo.expect(format!("Err {}: {}", err_code, err_msg).as_str()); +``` + +Use instead: +``` +foo.unwrap_or_else(|| panic!("Err {}: {}", err_code, err_msg)); +``` \ No newline at end of file diff --git a/src/docs/expect_used.txt b/src/docs/expect_used.txt new file mode 100644 index 00000000000..4a6981e334f --- /dev/null +++ b/src/docs/expect_used.txt @@ -0,0 +1,26 @@ +### What it does +Checks for `.expect()` or `.expect_err()` calls on `Result`s and `.expect()` call on `Option`s. + +### Why is this bad? +Usually it is better to handle the `None` or `Err` case. +Still, for a lot of quick-and-dirty code, `expect` is a good choice, which is why +this lint is `Allow` by default. + +`result.expect()` will let the thread panic on `Err` +values. Normally, you want to implement more sophisticated error handling, +and propagate errors upwards with `?` operator. + +### Examples +``` +option.expect("one"); +result.expect("one"); +``` + +Use instead: +``` +option?; + +// or + +result?; +``` \ No newline at end of file diff --git a/src/docs/expl_impl_clone_on_copy.txt b/src/docs/expl_impl_clone_on_copy.txt new file mode 100644 index 00000000000..391d93b6713 --- /dev/null +++ b/src/docs/expl_impl_clone_on_copy.txt @@ -0,0 +1,20 @@ +### What it does +Checks for explicit `Clone` implementations for `Copy` +types. + +### Why is this bad? +To avoid surprising behavior, these traits should +agree and the behavior of `Copy` cannot be overridden. In almost all +situations a `Copy` type should have a `Clone` implementation that does +nothing more than copy the object, which is what `#[derive(Copy, Clone)]` +gets you. + +### Example +``` +#[derive(Copy)] +struct Foo; + +impl Clone for Foo { + // .. +} +``` \ No newline at end of file diff --git a/src/docs/explicit_auto_deref.txt b/src/docs/explicit_auto_deref.txt new file mode 100644 index 00000000000..65b25631772 --- /dev/null +++ b/src/docs/explicit_auto_deref.txt @@ -0,0 +1,16 @@ +### What it does +Checks for dereferencing expressions which would be covered by auto-deref. + +### Why is this bad? +This unnecessarily complicates the code. + +### Example +``` +let x = String::new(); +let y: &str = &*x; +``` +Use instead: +``` +let x = String::new(); +let y: &str = &x; +``` \ No newline at end of file diff --git a/src/docs/explicit_counter_loop.txt b/src/docs/explicit_counter_loop.txt new file mode 100644 index 00000000000..2661a43e103 --- /dev/null +++ b/src/docs/explicit_counter_loop.txt @@ -0,0 +1,21 @@ +### What it does +Checks `for` loops over slices with an explicit counter +and suggests the use of `.enumerate()`. + +### Why is this bad? +Using `.enumerate()` makes the intent more clear, +declutters the code and may be faster in some instances. + +### Example +``` +let mut i = 0; +for item in &v { + bar(i, *item); + i += 1; +} +``` + +Use instead: +``` +for (i, item) in v.iter().enumerate() { bar(i, *item); } +``` \ No newline at end of file diff --git a/src/docs/explicit_deref_methods.txt b/src/docs/explicit_deref_methods.txt new file mode 100644 index 00000000000..e14e981c707 --- /dev/null +++ b/src/docs/explicit_deref_methods.txt @@ -0,0 +1,24 @@ +### What it does +Checks for explicit `deref()` or `deref_mut()` method calls. + +### Why is this bad? +Dereferencing by `&*x` or `&mut *x` is clearer and more concise, +when not part of a method chain. + +### Example +``` +use std::ops::Deref; +let a: &mut String = &mut String::from("foo"); +let b: &str = a.deref(); +``` + +Use instead: +``` +let a: &mut String = &mut String::from("foo"); +let b = &*a; +``` + +This lint excludes: +``` +let _ = d.unwrap().deref(); +``` \ No newline at end of file diff --git a/src/docs/explicit_into_iter_loop.txt b/src/docs/explicit_into_iter_loop.txt new file mode 100644 index 00000000000..3931dfd69a3 --- /dev/null +++ b/src/docs/explicit_into_iter_loop.txt @@ -0,0 +1,20 @@ +### What it does +Checks for loops on `y.into_iter()` where `y` will do, and +suggests the latter. + +### Why is this bad? +Readability. + +### Example +``` +// with `y` a `Vec` or slice: +for x in y.into_iter() { + // .. +} +``` +can be rewritten to +``` +for x in y { + // .. +} +``` \ No newline at end of file diff --git a/src/docs/explicit_iter_loop.txt b/src/docs/explicit_iter_loop.txt new file mode 100644 index 00000000000..cabe72e91d0 --- /dev/null +++ b/src/docs/explicit_iter_loop.txt @@ -0,0 +1,25 @@ +### What it does +Checks for loops on `x.iter()` where `&x` will do, and +suggests the latter. + +### Why is this bad? +Readability. + +### Known problems +False negatives. We currently only warn on some known +types. + +### Example +``` +// with `y` a `Vec` or slice: +for x in y.iter() { + // .. +} +``` + +Use instead: +``` +for x in &y { + // .. +} +``` \ No newline at end of file diff --git a/src/docs/explicit_write.txt b/src/docs/explicit_write.txt new file mode 100644 index 00000000000..eafed5d39e5 --- /dev/null +++ b/src/docs/explicit_write.txt @@ -0,0 +1,18 @@ +### What it does +Checks for usage of `write!()` / `writeln()!` which can be +replaced with `(e)print!()` / `(e)println!()` + +### Why is this bad? +Using `(e)println! is clearer and more concise + +### Example +``` +writeln!(&mut std::io::stderr(), "foo: {:?}", bar).unwrap(); +writeln!(&mut std::io::stdout(), "foo: {:?}", bar).unwrap(); +``` + +Use instead: +``` +eprintln!("foo: {:?}", bar); +println!("foo: {:?}", bar); +``` \ No newline at end of file diff --git a/src/docs/extend_with_drain.txt b/src/docs/extend_with_drain.txt new file mode 100644 index 00000000000..2f31dcf5f74 --- /dev/null +++ b/src/docs/extend_with_drain.txt @@ -0,0 +1,21 @@ +### What it does +Checks for occurrences where one vector gets extended instead of append + +### Why is this bad? +Using `append` instead of `extend` is more concise and faster + +### Example +``` +let mut a = vec![1, 2, 3]; +let mut b = vec![4, 5, 6]; + +a.extend(b.drain(..)); +``` + +Use instead: +``` +let mut a = vec![1, 2, 3]; +let mut b = vec![4, 5, 6]; + +a.append(&mut b); +``` \ No newline at end of file diff --git a/src/docs/extra_unused_lifetimes.txt b/src/docs/extra_unused_lifetimes.txt new file mode 100644 index 00000000000..bc1814aa475 --- /dev/null +++ b/src/docs/extra_unused_lifetimes.txt @@ -0,0 +1,23 @@ +### What it does +Checks for lifetimes in generics that are never used +anywhere else. + +### Why is this bad? +The additional lifetimes make the code look more +complicated, while there is nothing out of the ordinary going on. Removing +them leads to more readable code. + +### Example +``` +// unnecessary lifetimes +fn unused_lifetime<'a>(x: u8) { + // .. +} +``` + +Use instead: +``` +fn no_lifetime(x: u8) { + // ... +} +``` \ No newline at end of file diff --git a/src/docs/fallible_impl_from.txt b/src/docs/fallible_impl_from.txt new file mode 100644 index 00000000000..588a5bb103d --- /dev/null +++ b/src/docs/fallible_impl_from.txt @@ -0,0 +1,32 @@ +### What it does +Checks for impls of `From<..>` that contain `panic!()` or `unwrap()` + +### Why is this bad? +`TryFrom` should be used if there's a possibility of failure. + +### Example +``` +struct Foo(i32); + +impl From for Foo { + fn from(s: String) -> Self { + Foo(s.parse().unwrap()) + } +} +``` + +Use instead: +``` +struct Foo(i32); + +impl TryFrom for Foo { + type Error = (); + fn try_from(s: String) -> Result { + if let Ok(parsed) = s.parse() { + Ok(Foo(parsed)) + } else { + Err(()) + } + } +} +``` \ No newline at end of file diff --git a/src/docs/field_reassign_with_default.txt b/src/docs/field_reassign_with_default.txt new file mode 100644 index 00000000000..e58b7239fde --- /dev/null +++ b/src/docs/field_reassign_with_default.txt @@ -0,0 +1,23 @@ +### What it does +Checks for immediate reassignment of fields initialized +with Default::default(). + +### Why is this bad? +It's more idiomatic to use the [functional update syntax](https://doc.rust-lang.org/reference/expressions/struct-expr.html#functional-update-syntax). + +### Known problems +Assignments to patterns that are of tuple type are not linted. + +### Example +``` +let mut a: A = Default::default(); +a.i = 42; +``` + +Use instead: +``` +let a = A { + i: 42, + .. Default::default() +}; +``` \ No newline at end of file diff --git a/src/docs/filetype_is_file.txt b/src/docs/filetype_is_file.txt new file mode 100644 index 00000000000..ad14bd62c4d --- /dev/null +++ b/src/docs/filetype_is_file.txt @@ -0,0 +1,29 @@ +### What it does +Checks for `FileType::is_file()`. + +### Why is this bad? +When people testing a file type with `FileType::is_file` +they are testing whether a path is something they can get bytes from. But +`is_file` doesn't cover special file types in unix-like systems, and doesn't cover +symlink in windows. Using `!FileType::is_dir()` is a better way to that intention. + +### Example +``` +let metadata = std::fs::metadata("foo.txt")?; +let filetype = metadata.file_type(); + +if filetype.is_file() { + // read file +} +``` + +should be written as: + +``` +let metadata = std::fs::metadata("foo.txt")?; +let filetype = metadata.file_type(); + +if !filetype.is_dir() { + // read file +} +``` \ No newline at end of file diff --git a/src/docs/filter_map_identity.txt b/src/docs/filter_map_identity.txt new file mode 100644 index 00000000000..83b666f2e27 --- /dev/null +++ b/src/docs/filter_map_identity.txt @@ -0,0 +1,14 @@ +### What it does +Checks for usage of `filter_map(|x| x)`. + +### Why is this bad? +Readability, this can be written more concisely by using `flatten`. + +### Example +``` +iter.filter_map(|x| x); +``` +Use instead: +``` +iter.flatten(); +``` \ No newline at end of file diff --git a/src/docs/filter_map_next.txt b/src/docs/filter_map_next.txt new file mode 100644 index 00000000000..b38620b56a5 --- /dev/null +++ b/src/docs/filter_map_next.txt @@ -0,0 +1,16 @@ +### What it does +Checks for usage of `_.filter_map(_).next()`. + +### Why is this bad? +Readability, this can be written more concisely as +`_.find_map(_)`. + +### Example +``` + (0..3).filter_map(|x| if x == 2 { Some(x) } else { None }).next(); +``` +Can be written as + +``` + (0..3).find_map(|x| if x == 2 { Some(x) } else { None }); +``` \ No newline at end of file diff --git a/src/docs/filter_next.txt b/src/docs/filter_next.txt new file mode 100644 index 00000000000..898a74166dc --- /dev/null +++ b/src/docs/filter_next.txt @@ -0,0 +1,16 @@ +### What it does +Checks for usage of `_.filter(_).next()`. + +### Why is this bad? +Readability, this can be written more concisely as +`_.find(_)`. + +### Example +``` +vec.iter().filter(|x| **x == 0).next(); +``` + +Use instead: +``` +vec.iter().find(|x| **x == 0); +``` \ No newline at end of file diff --git a/src/docs/flat_map_identity.txt b/src/docs/flat_map_identity.txt new file mode 100644 index 00000000000..a5ee79b4982 --- /dev/null +++ b/src/docs/flat_map_identity.txt @@ -0,0 +1,14 @@ +### What it does +Checks for usage of `flat_map(|x| x)`. + +### Why is this bad? +Readability, this can be written more concisely by using `flatten`. + +### Example +``` +iter.flat_map(|x| x); +``` +Can be written as +``` +iter.flatten(); +``` \ No newline at end of file diff --git a/src/docs/flat_map_option.txt b/src/docs/flat_map_option.txt new file mode 100644 index 00000000000..d50b9156d36 --- /dev/null +++ b/src/docs/flat_map_option.txt @@ -0,0 +1,16 @@ +### What it does +Checks for usages of `Iterator::flat_map()` where `filter_map()` could be +used instead. + +### Why is this bad? +When applicable, `filter_map()` is more clear since it shows that +`Option` is used to produce 0 or 1 items. + +### Example +``` +let nums: Vec = ["1", "2", "whee!"].iter().flat_map(|x| x.parse().ok()).collect(); +``` +Use instead: +``` +let nums: Vec = ["1", "2", "whee!"].iter().filter_map(|x| x.parse().ok()).collect(); +``` \ No newline at end of file diff --git a/src/docs/float_arithmetic.txt b/src/docs/float_arithmetic.txt new file mode 100644 index 00000000000..1f9bce5abd5 --- /dev/null +++ b/src/docs/float_arithmetic.txt @@ -0,0 +1,11 @@ +### What it does +Checks for float arithmetic. + +### Why is this bad? +For some embedded systems or kernel development, it +can be useful to rule out floating-point numbers. + +### Example +``` +a + 1.0; +``` \ No newline at end of file diff --git a/src/docs/float_cmp.txt b/src/docs/float_cmp.txt new file mode 100644 index 00000000000..c19907c903e --- /dev/null +++ b/src/docs/float_cmp.txt @@ -0,0 +1,28 @@ +### What it does +Checks for (in-)equality comparisons on floating-point +values (apart from zero), except in functions called `*eq*` (which probably +implement equality for a type involving floats). + +### Why is this bad? +Floating point calculations are usually imprecise, so +asking if two values are *exactly* equal is asking for trouble. For a good +guide on what to do, see [the floating point +guide](http://www.floating-point-gui.de/errors/comparison). + +### Example +``` +let x = 1.2331f64; +let y = 1.2332f64; + +if y == 1.23f64 { } +if y != x {} // where both are floats +``` + +Use instead: +``` +let error_margin = f64::EPSILON; // Use an epsilon for comparison +// Or, if Rust <= 1.42, use `std::f64::EPSILON` constant instead. +// let error_margin = std::f64::EPSILON; +if (y - 1.23f64).abs() < error_margin { } +if (y - x).abs() > error_margin { } +``` \ No newline at end of file diff --git a/src/docs/float_cmp_const.txt b/src/docs/float_cmp_const.txt new file mode 100644 index 00000000000..9208feaacd8 --- /dev/null +++ b/src/docs/float_cmp_const.txt @@ -0,0 +1,26 @@ +### What it does +Checks for (in-)equality comparisons on floating-point +value and constant, except in functions called `*eq*` (which probably +implement equality for a type involving floats). + +### Why is this bad? +Floating point calculations are usually imprecise, so +asking if two values are *exactly* equal is asking for trouble. For a good +guide on what to do, see [the floating point +guide](http://www.floating-point-gui.de/errors/comparison). + +### Example +``` +let x: f64 = 1.0; +const ONE: f64 = 1.00; + +if x == ONE { } // where both are floats +``` + +Use instead: +``` +let error_margin = f64::EPSILON; // Use an epsilon for comparison +// Or, if Rust <= 1.42, use `std::f64::EPSILON` constant instead. +// let error_margin = std::f64::EPSILON; +if (x - ONE).abs() < error_margin { } +``` \ No newline at end of file diff --git a/src/docs/float_equality_without_abs.txt b/src/docs/float_equality_without_abs.txt new file mode 100644 index 00000000000..556b574e15d --- /dev/null +++ b/src/docs/float_equality_without_abs.txt @@ -0,0 +1,26 @@ +### What it does +Checks for statements of the form `(a - b) < f32::EPSILON` or +`(a - b) < f64::EPSILON`. Notes the missing `.abs()`. + +### Why is this bad? +The code without `.abs()` is more likely to have a bug. + +### Known problems +If the user can ensure that b is larger than a, the `.abs()` is +technically unnecessary. However, it will make the code more robust and doesn't have any +large performance implications. If the abs call was deliberately left out for performance +reasons, it is probably better to state this explicitly in the code, which then can be done +with an allow. + +### Example +``` +pub fn is_roughly_equal(a: f32, b: f32) -> bool { + (a - b) < f32::EPSILON +} +``` +Use instead: +``` +pub fn is_roughly_equal(a: f32, b: f32) -> bool { + (a - b).abs() < f32::EPSILON +} +``` \ No newline at end of file diff --git a/src/docs/fn_address_comparisons.txt b/src/docs/fn_address_comparisons.txt new file mode 100644 index 00000000000..7d2b7b681de --- /dev/null +++ b/src/docs/fn_address_comparisons.txt @@ -0,0 +1,17 @@ +### What it does +Checks for comparisons with an address of a function item. + +### Why is this bad? +Function item address is not guaranteed to be unique and could vary +between different code generation units. Furthermore different function items could have +the same address after being merged together. + +### Example +``` +type F = fn(); +fn a() {} +let f: F = a; +if f == a { + // ... +} +``` \ No newline at end of file diff --git a/src/docs/fn_params_excessive_bools.txt b/src/docs/fn_params_excessive_bools.txt new file mode 100644 index 00000000000..2eae0563368 --- /dev/null +++ b/src/docs/fn_params_excessive_bools.txt @@ -0,0 +1,31 @@ +### What it does +Checks for excessive use of +bools in function definitions. + +### Why is this bad? +Calls to such functions +are confusing and error prone, because it's +hard to remember argument order and you have +no type system support to back you up. Using +two-variant enums instead of bools often makes +API easier to use. + +### Example +``` +fn f(is_round: bool, is_hot: bool) { ... } +``` + +Use instead: +``` +enum Shape { + Round, + Spiky, +} + +enum Temperature { + Hot, + IceCold, +} + +fn f(shape: Shape, temperature: Temperature) { ... } +``` \ No newline at end of file diff --git a/src/docs/fn_to_numeric_cast.txt b/src/docs/fn_to_numeric_cast.txt new file mode 100644 index 00000000000..1f587f6d717 --- /dev/null +++ b/src/docs/fn_to_numeric_cast.txt @@ -0,0 +1,21 @@ +### What it does +Checks for casts of function pointers to something other than usize + +### Why is this bad? +Casting a function pointer to anything other than usize/isize is not portable across +architectures, because you end up losing bits if the target type is too small or end up with a +bunch of extra bits that waste space and add more instructions to the final binary than +strictly necessary for the problem + +Casting to isize also doesn't make sense since there are no signed addresses. + +### Example +``` +fn fun() -> i32 { 1 } +let _ = fun as i64; +``` + +Use instead: +``` +let _ = fun as usize; +``` \ No newline at end of file diff --git a/src/docs/fn_to_numeric_cast_any.txt b/src/docs/fn_to_numeric_cast_any.txt new file mode 100644 index 00000000000..ee3c33d2372 --- /dev/null +++ b/src/docs/fn_to_numeric_cast_any.txt @@ -0,0 +1,35 @@ +### What it does +Checks for casts of a function pointer to any integer type. + +### Why is this bad? +Casting a function pointer to an integer can have surprising results and can occur +accidentally if parentheses are omitted from a function call. If you aren't doing anything +low-level with function pointers then you can opt-out of casting functions to integers in +order to avoid mistakes. Alternatively, you can use this lint to audit all uses of function +pointer casts in your code. + +### Example +``` +// fn1 is cast as `usize` +fn fn1() -> u16 { + 1 +}; +let _ = fn1 as usize; +``` + +Use instead: +``` +// maybe you intended to call the function? +fn fn2() -> u16 { + 1 +}; +let _ = fn2() as usize; + +// or + +// maybe you intended to cast it to a function type? +fn fn3() -> u16 { + 1 +} +let _ = fn3 as fn() -> u16; +``` \ No newline at end of file diff --git a/src/docs/fn_to_numeric_cast_with_truncation.txt b/src/docs/fn_to_numeric_cast_with_truncation.txt new file mode 100644 index 00000000000..69f12fa319f --- /dev/null +++ b/src/docs/fn_to_numeric_cast_with_truncation.txt @@ -0,0 +1,26 @@ +### What it does +Checks for casts of a function pointer to a numeric type not wide enough to +store address. + +### Why is this bad? +Such a cast discards some bits of the function's address. If this is intended, it would be more +clearly expressed by casting to usize first, then casting the usize to the intended type (with +a comment) to perform the truncation. + +### Example +``` +fn fn1() -> i16 { + 1 +}; +let _ = fn1 as i32; +``` + +Use instead: +``` +// Cast to usize first, then comment with the reason for the truncation +fn fn1() -> i16 { + 1 +}; +let fn_ptr = fn1 as usize; +let fn_ptr_truncated = fn_ptr as i32; +``` \ No newline at end of file diff --git a/src/docs/for_kv_map.txt b/src/docs/for_kv_map.txt new file mode 100644 index 00000000000..a9a2ffee9c7 --- /dev/null +++ b/src/docs/for_kv_map.txt @@ -0,0 +1,22 @@ +### What it does +Checks for iterating a map (`HashMap` or `BTreeMap`) and +ignoring either the keys or values. + +### Why is this bad? +Readability. There are `keys` and `values` methods that +can be used to express that don't need the values or keys. + +### Example +``` +for (k, _) in &map { + .. +} +``` + +could be replaced by + +``` +for k in map.keys() { + .. +} +``` \ No newline at end of file diff --git a/src/docs/for_loops_over_fallibles.txt b/src/docs/for_loops_over_fallibles.txt new file mode 100644 index 00000000000..c5a7508e45d --- /dev/null +++ b/src/docs/for_loops_over_fallibles.txt @@ -0,0 +1,32 @@ +### What it does +Checks for `for` loops over `Option` or `Result` values. + +### Why is this bad? +Readability. This is more clearly expressed as an `if +let`. + +### Example +``` +for x in opt { + // .. +} + +for x in &res { + // .. +} + +for x in res.iter() { + // .. +} +``` + +Use instead: +``` +if let Some(x) = opt { + // .. +} + +if let Ok(x) = res { + // .. +} +``` \ No newline at end of file diff --git a/src/docs/forget_copy.txt b/src/docs/forget_copy.txt new file mode 100644 index 00000000000..1d100912e9a --- /dev/null +++ b/src/docs/forget_copy.txt @@ -0,0 +1,21 @@ +### What it does +Checks for calls to `std::mem::forget` with a value that +derives the Copy trait + +### Why is this bad? +Calling `std::mem::forget` [does nothing for types that +implement Copy](https://doc.rust-lang.org/std/mem/fn.drop.html) since the +value will be copied and moved into the function on invocation. + +An alternative, but also valid, explanation is that Copy types do not +implement +the Drop trait, which means they have no destructors. Without a destructor, +there +is nothing for `std::mem::forget` to ignore. + +### Example +``` +let x: i32 = 42; // i32 implements Copy +std::mem::forget(x) // A copy of x is passed to the function, leaving the + // original unaffected +``` \ No newline at end of file diff --git a/src/docs/forget_non_drop.txt b/src/docs/forget_non_drop.txt new file mode 100644 index 00000000000..3307d654c17 --- /dev/null +++ b/src/docs/forget_non_drop.txt @@ -0,0 +1,13 @@ +### What it does +Checks for calls to `std::mem::forget` with a value that does not implement `Drop`. + +### Why is this bad? +Calling `std::mem::forget` is no different than dropping such a type. A different value may +have been intended. + +### Example +``` +struct Foo; +let x = Foo; +std::mem::forget(x); +``` \ No newline at end of file diff --git a/src/docs/forget_ref.txt b/src/docs/forget_ref.txt new file mode 100644 index 00000000000..874fb878606 --- /dev/null +++ b/src/docs/forget_ref.txt @@ -0,0 +1,15 @@ +### What it does +Checks for calls to `std::mem::forget` with a reference +instead of an owned value. + +### Why is this bad? +Calling `forget` on a reference will only forget the +reference itself, which is a no-op. It will not forget the underlying +referenced +value, which is likely what was intended. + +### Example +``` +let x = Box::new(1); +std::mem::forget(&x) // Should have been forget(x), x will still be dropped +``` \ No newline at end of file diff --git a/src/docs/format_in_format_args.txt b/src/docs/format_in_format_args.txt new file mode 100644 index 00000000000..ac498472f01 --- /dev/null +++ b/src/docs/format_in_format_args.txt @@ -0,0 +1,16 @@ +### What it does +Detects `format!` within the arguments of another macro that does +formatting such as `format!` itself, `write!` or `println!`. Suggests +inlining the `format!` call. + +### Why is this bad? +The recommended code is both shorter and avoids a temporary allocation. + +### Example +``` +println!("error: {}", format!("something failed at {}", Location::caller())); +``` +Use instead: +``` +println!("error: something failed at {}", Location::caller()); +``` \ No newline at end of file diff --git a/src/docs/format_push_string.txt b/src/docs/format_push_string.txt new file mode 100644 index 00000000000..ca409ebc7ec --- /dev/null +++ b/src/docs/format_push_string.txt @@ -0,0 +1,26 @@ +### What it does +Detects cases where the result of a `format!` call is +appended to an existing `String`. + +### Why is this bad? +Introduces an extra, avoidable heap allocation. + +### Known problems +`format!` returns a `String` but `write!` returns a `Result`. +Thus you are forced to ignore the `Err` variant to achieve the same API. + +While using `write!` in the suggested way should never fail, this isn't necessarily clear to the programmer. + +### Example +``` +let mut s = String::new(); +s += &format!("0x{:X}", 1024); +s.push_str(&format!("0x{:X}", 1024)); +``` +Use instead: +``` +use std::fmt::Write as _; // import without risk of name clashing + +let mut s = String::new(); +let _ = write!(s, "0x{:X}", 1024); +``` \ No newline at end of file diff --git a/src/docs/from_iter_instead_of_collect.txt b/src/docs/from_iter_instead_of_collect.txt new file mode 100644 index 00000000000..f3fd2759726 --- /dev/null +++ b/src/docs/from_iter_instead_of_collect.txt @@ -0,0 +1,24 @@ +### What it does +Checks for `from_iter()` function calls on types that implement the `FromIterator` +trait. + +### Why is this bad? +It is recommended style to use collect. See +[FromIterator documentation](https://doc.rust-lang.org/std/iter/trait.FromIterator.html) + +### Example +``` +let five_fives = std::iter::repeat(5).take(5); + +let v = Vec::from_iter(five_fives); + +assert_eq!(v, vec![5, 5, 5, 5, 5]); +``` +Use instead: +``` +let five_fives = std::iter::repeat(5).take(5); + +let v: Vec = five_fives.collect(); + +assert_eq!(v, vec![5, 5, 5, 5, 5]); +``` \ No newline at end of file diff --git a/src/docs/from_over_into.txt b/src/docs/from_over_into.txt new file mode 100644 index 00000000000..0770bcc42c2 --- /dev/null +++ b/src/docs/from_over_into.txt @@ -0,0 +1,26 @@ +### What it does +Searches for implementations of the `Into<..>` trait and suggests to implement `From<..>` instead. + +### Why is this bad? +According the std docs implementing `From<..>` is preferred since it gives you `Into<..>` for free where the reverse isn't true. + +### Example +``` +struct StringWrapper(String); + +impl Into for String { + fn into(self) -> StringWrapper { + StringWrapper(self) + } +} +``` +Use instead: +``` +struct StringWrapper(String); + +impl From for StringWrapper { + fn from(s: String) -> StringWrapper { + StringWrapper(s) + } +} +``` \ No newline at end of file diff --git a/src/docs/from_str_radix_10.txt b/src/docs/from_str_radix_10.txt new file mode 100644 index 00000000000..f6f319d3eaa --- /dev/null +++ b/src/docs/from_str_radix_10.txt @@ -0,0 +1,25 @@ +### What it does + +Checks for function invocations of the form `primitive::from_str_radix(s, 10)` + +### Why is this bad? + +This specific common use case can be rewritten as `s.parse::()` +(and in most cases, the turbofish can be removed), which reduces code length +and complexity. + +### Known problems + +This lint may suggest using (&).parse() instead of .parse() directly +in some cases, which is correct but adds unnecessary complexity to the code. + +### Example +``` +let input: &str = get_input(); +let num = u16::from_str_radix(input, 10)?; +``` +Use instead: +``` +let input: &str = get_input(); +let num: u16 = input.parse()?; +``` \ No newline at end of file diff --git a/src/docs/future_not_send.txt b/src/docs/future_not_send.txt new file mode 100644 index 00000000000..0aa048d2735 --- /dev/null +++ b/src/docs/future_not_send.txt @@ -0,0 +1,29 @@ +### What it does +This lint requires Future implementations returned from +functions and methods to implement the `Send` marker trait. It is mostly +used by library authors (public and internal) that target an audience where +multithreaded executors are likely to be used for running these Futures. + +### Why is this bad? +A Future implementation captures some state that it +needs to eventually produce its final value. When targeting a multithreaded +executor (which is the norm on non-embedded devices) this means that this +state may need to be transported to other threads, in other words the +whole Future needs to implement the `Send` marker trait. If it does not, +then the resulting Future cannot be submitted to a thread pool in the +end user’s code. + +Especially for generic functions it can be confusing to leave the +discovery of this problem to the end user: the reported error location +will be far from its cause and can in many cases not even be fixed without +modifying the library where the offending Future implementation is +produced. + +### Example +``` +async fn not_send(bytes: std::rc::Rc<[u8]>) {} +``` +Use instead: +``` +async fn is_send(bytes: std::sync::Arc<[u8]>) {} +``` \ No newline at end of file diff --git a/src/docs/get_first.txt b/src/docs/get_first.txt new file mode 100644 index 00000000000..c905a737ddf --- /dev/null +++ b/src/docs/get_first.txt @@ -0,0 +1,19 @@ +### What it does +Checks for using `x.get(0)` instead of +`x.first()`. + +### Why is this bad? +Using `x.first()` is easier to read and has the same +result. + +### Example +``` +let x = vec![2, 3, 5]; +let first_element = x.get(0); +``` + +Use instead: +``` +let x = vec![2, 3, 5]; +let first_element = x.first(); +``` \ No newline at end of file diff --git a/src/docs/get_last_with_len.txt b/src/docs/get_last_with_len.txt new file mode 100644 index 00000000000..31c7f269586 --- /dev/null +++ b/src/docs/get_last_with_len.txt @@ -0,0 +1,26 @@ +### What it does +Checks for using `x.get(x.len() - 1)` instead of +`x.last()`. + +### Why is this bad? +Using `x.last()` is easier to read and has the same +result. + +Note that using `x[x.len() - 1]` is semantically different from +`x.last()`. Indexing into the array will panic on out-of-bounds +accesses, while `x.get()` and `x.last()` will return `None`. + +There is another lint (get_unwrap) that covers the case of using +`x.get(index).unwrap()` instead of `x[index]`. + +### Example +``` +let x = vec![2, 3, 5]; +let last_element = x.get(x.len() - 1); +``` + +Use instead: +``` +let x = vec![2, 3, 5]; +let last_element = x.last(); +``` \ No newline at end of file diff --git a/src/docs/get_unwrap.txt b/src/docs/get_unwrap.txt new file mode 100644 index 00000000000..8defc222441 --- /dev/null +++ b/src/docs/get_unwrap.txt @@ -0,0 +1,30 @@ +### What it does +Checks for use of `.get().unwrap()` (or +`.get_mut().unwrap`) on a standard library type which implements `Index` + +### Why is this bad? +Using the Index trait (`[]`) is more clear and more +concise. + +### Known problems +Not a replacement for error handling: Using either +`.unwrap()` or the Index trait (`[]`) carries the risk of causing a `panic` +if the value being accessed is `None`. If the use of `.get().unwrap()` is a +temporary placeholder for dealing with the `Option` type, then this does +not mitigate the need for error handling. If there is a chance that `.get()` +will be `None` in your program, then it is advisable that the `None` case +is handled in a future refactor instead of using `.unwrap()` or the Index +trait. + +### Example +``` +let mut some_vec = vec![0, 1, 2, 3]; +let last = some_vec.get(3).unwrap(); +*some_vec.get_mut(0).unwrap() = 1; +``` +The correct use would be: +``` +let mut some_vec = vec![0, 1, 2, 3]; +let last = some_vec[3]; +some_vec[0] = 1; +``` \ No newline at end of file diff --git a/src/docs/identity_op.txt b/src/docs/identity_op.txt new file mode 100644 index 00000000000..a8e40bb43e9 --- /dev/null +++ b/src/docs/identity_op.txt @@ -0,0 +1,11 @@ +### What it does +Checks for identity operations, e.g., `x + 0`. + +### Why is this bad? +This code can be removed without changing the +meaning. So it just obscures what's going on. Delete it mercilessly. + +### Example +``` +x / 1 + 0 * 1 - 0 | 0; +``` \ No newline at end of file diff --git a/src/docs/if_let_mutex.txt b/src/docs/if_let_mutex.txt new file mode 100644 index 00000000000..4d873ade9ac --- /dev/null +++ b/src/docs/if_let_mutex.txt @@ -0,0 +1,25 @@ +### What it does +Checks for `Mutex::lock` calls in `if let` expression +with lock calls in any of the else blocks. + +### Why is this bad? +The Mutex lock remains held for the whole +`if let ... else` block and deadlocks. + +### Example +``` +if let Ok(thing) = mutex.lock() { + do_thing(); +} else { + mutex.lock(); +} +``` +Should be written +``` +let locked = mutex.lock(); +if let Ok(thing) = locked { + do_thing(thing); +} else { + use_locked(locked); +} +``` \ No newline at end of file diff --git a/src/docs/if_not_else.txt b/src/docs/if_not_else.txt new file mode 100644 index 00000000000..0e5ac4ce6bb --- /dev/null +++ b/src/docs/if_not_else.txt @@ -0,0 +1,25 @@ +### What it does +Checks for usage of `!` or `!=` in an if condition with an +else branch. + +### Why is this bad? +Negations reduce the readability of statements. + +### Example +``` +if !v.is_empty() { + a() +} else { + b() +} +``` + +Could be written: + +``` +if v.is_empty() { + b() +} else { + a() +} +``` \ No newline at end of file diff --git a/src/docs/if_same_then_else.txt b/src/docs/if_same_then_else.txt new file mode 100644 index 00000000000..75127016bb8 --- /dev/null +++ b/src/docs/if_same_then_else.txt @@ -0,0 +1,15 @@ +### What it does +Checks for `if/else` with the same body as the *then* part +and the *else* part. + +### Why is this bad? +This is probably a copy & paste error. + +### Example +``` +let foo = if … { + 42 +} else { + 42 +}; +``` \ No newline at end of file diff --git a/src/docs/if_then_some_else_none.txt b/src/docs/if_then_some_else_none.txt new file mode 100644 index 00000000000..13744f920e3 --- /dev/null +++ b/src/docs/if_then_some_else_none.txt @@ -0,0 +1,26 @@ +### What it does +Checks for if-else that could be written using either `bool::then` or `bool::then_some`. + +### Why is this bad? +Looks a little redundant. Using `bool::then` is more concise and incurs no loss of clarity. +For simple calculations and known values, use `bool::then_some`, which is eagerly evaluated +in comparison to `bool::then`. + +### Example +``` +let a = if v.is_empty() { + println!("true!"); + Some(42) +} else { + None +}; +``` + +Could be written: + +``` +let a = v.is_empty().then(|| { + println!("true!"); + 42 +}); +``` \ No newline at end of file diff --git a/src/docs/ifs_same_cond.txt b/src/docs/ifs_same_cond.txt new file mode 100644 index 00000000000..024ba5df93a --- /dev/null +++ b/src/docs/ifs_same_cond.txt @@ -0,0 +1,25 @@ +### What it does +Checks for consecutive `if`s with the same condition. + +### Why is this bad? +This is probably a copy & paste error. + +### Example +``` +if a == b { + … +} else if a == b { + … +} +``` + +Note that this lint ignores all conditions with a function call as it could +have side effects: + +``` +if foo() { + … +} else if foo() { // not linted + … +} +``` \ No newline at end of file diff --git a/src/docs/implicit_clone.txt b/src/docs/implicit_clone.txt new file mode 100644 index 00000000000..f5aa112c52c --- /dev/null +++ b/src/docs/implicit_clone.txt @@ -0,0 +1,19 @@ +### What it does +Checks for the usage of `_.to_owned()`, `vec.to_vec()`, or similar when calling `_.clone()` would be clearer. + +### Why is this bad? +These methods do the same thing as `_.clone()` but may be confusing as +to why we are calling `to_vec` on something that is already a `Vec` or calling `to_owned` on something that is already owned. + +### Example +``` +let a = vec![1, 2, 3]; +let b = a.to_vec(); +let c = a.to_owned(); +``` +Use instead: +``` +let a = vec![1, 2, 3]; +let b = a.clone(); +let c = a.clone(); +``` \ No newline at end of file diff --git a/src/docs/implicit_hasher.txt b/src/docs/implicit_hasher.txt new file mode 100644 index 00000000000..0c1f76620f5 --- /dev/null +++ b/src/docs/implicit_hasher.txt @@ -0,0 +1,26 @@ +### What it does +Checks for public `impl` or `fn` missing generalization +over different hashers and implicitly defaulting to the default hashing +algorithm (`SipHash`). + +### Why is this bad? +`HashMap` or `HashSet` with custom hashers cannot be +used with them. + +### Known problems +Suggestions for replacing constructors can contain +false-positives. Also applying suggestions can require modification of other +pieces of code, possibly including external crates. + +### Example +``` +impl Serialize for HashMap { } + +pub fn foo(map: &mut HashMap) { } +``` +could be rewritten as +``` +impl Serialize for HashMap { } + +pub fn foo(map: &mut HashMap) { } +``` \ No newline at end of file diff --git a/src/docs/implicit_return.txt b/src/docs/implicit_return.txt new file mode 100644 index 00000000000..ee65a636b38 --- /dev/null +++ b/src/docs/implicit_return.txt @@ -0,0 +1,22 @@ +### What it does +Checks for missing return statements at the end of a block. + +### Why is this bad? +Actually omitting the return keyword is idiomatic Rust code. Programmers +coming from other languages might prefer the expressiveness of `return`. It's possible to miss +the last returning statement because the only difference is a missing `;`. Especially in bigger +code with multiple return paths having a `return` keyword makes it easier to find the +corresponding statements. + +### Example +``` +fn foo(x: usize) -> usize { + x +} +``` +add return +``` +fn foo(x: usize) -> usize { + return x; +} +``` \ No newline at end of file diff --git a/src/docs/implicit_saturating_sub.txt b/src/docs/implicit_saturating_sub.txt new file mode 100644 index 00000000000..03b47905a21 --- /dev/null +++ b/src/docs/implicit_saturating_sub.txt @@ -0,0 +1,21 @@ +### What it does +Checks for implicit saturating subtraction. + +### Why is this bad? +Simplicity and readability. Instead we can easily use an builtin function. + +### Example +``` +let mut i: u32 = end - start; + +if i != 0 { + i -= 1; +} +``` + +Use instead: +``` +let mut i: u32 = end - start; + +i = i.saturating_sub(1); +``` \ No newline at end of file diff --git a/src/docs/imprecise_flops.txt b/src/docs/imprecise_flops.txt new file mode 100644 index 00000000000..e84d81cea98 --- /dev/null +++ b/src/docs/imprecise_flops.txt @@ -0,0 +1,23 @@ +### What it does +Looks for floating-point expressions that +can be expressed using built-in methods to improve accuracy +at the cost of performance. + +### Why is this bad? +Negatively impacts accuracy. + +### Example +``` +let a = 3f32; +let _ = a.powf(1.0 / 3.0); +let _ = (1.0 + a).ln(); +let _ = a.exp() - 1.0; +``` + +Use instead: +``` +let a = 3f32; +let _ = a.cbrt(); +let _ = a.ln_1p(); +let _ = a.exp_m1(); +``` \ No newline at end of file diff --git a/src/docs/inconsistent_digit_grouping.txt b/src/docs/inconsistent_digit_grouping.txt new file mode 100644 index 00000000000..aa0b072de1c --- /dev/null +++ b/src/docs/inconsistent_digit_grouping.txt @@ -0,0 +1,17 @@ +### What it does +Warns if an integral or floating-point constant is +grouped inconsistently with underscores. + +### Why is this bad? +Readers may incorrectly interpret inconsistently +grouped digits. + +### Example +``` +618_64_9189_73_511 +``` + +Use instead: +``` +61_864_918_973_511 +``` \ No newline at end of file diff --git a/src/docs/inconsistent_struct_constructor.txt b/src/docs/inconsistent_struct_constructor.txt new file mode 100644 index 00000000000..eb682109a54 --- /dev/null +++ b/src/docs/inconsistent_struct_constructor.txt @@ -0,0 +1,40 @@ +### What it does +Checks for struct constructors where all fields are shorthand and +the order of the field init shorthand in the constructor is inconsistent +with the order in the struct definition. + +### Why is this bad? +Since the order of fields in a constructor doesn't affect the +resulted instance as the below example indicates, + +``` +#[derive(Debug, PartialEq, Eq)] +struct Foo { + x: i32, + y: i32, +} +let x = 1; +let y = 2; + +// This assertion never fails: +assert_eq!(Foo { x, y }, Foo { y, x }); +``` + +inconsistent order can be confusing and decreases readability and consistency. + +### Example +``` +struct Foo { + x: i32, + y: i32, +} +let x = 1; +let y = 2; + +Foo { y, x }; +``` + +Use instead: +``` +Foo { x, y }; +``` \ No newline at end of file diff --git a/src/docs/index_refutable_slice.txt b/src/docs/index_refutable_slice.txt new file mode 100644 index 00000000000..8a7d52761af --- /dev/null +++ b/src/docs/index_refutable_slice.txt @@ -0,0 +1,29 @@ +### What it does +The lint checks for slice bindings in patterns that are only used to +access individual slice values. + +### Why is this bad? +Accessing slice values using indices can lead to panics. Using refutable +patterns can avoid these. Binding to individual values also improves the +readability as they can be named. + +### Limitations +This lint currently only checks for immutable access inside `if let` +patterns. + +### Example +``` +let slice: Option<&[u32]> = Some(&[1, 2, 3]); + +if let Some(slice) = slice { + println!("{}", slice[0]); +} +``` +Use instead: +``` +let slice: Option<&[u32]> = Some(&[1, 2, 3]); + +if let Some(&[first, ..]) = slice { + println!("{}", first); +} +``` \ No newline at end of file diff --git a/src/docs/indexing_slicing.txt b/src/docs/indexing_slicing.txt new file mode 100644 index 00000000000..76ca6ed318b --- /dev/null +++ b/src/docs/indexing_slicing.txt @@ -0,0 +1,33 @@ +### What it does +Checks for usage of indexing or slicing. Arrays are special cases, this lint +does report on arrays if we can tell that slicing operations are in bounds and does not +lint on constant `usize` indexing on arrays because that is handled by rustc's `const_err` lint. + +### Why is this bad? +Indexing and slicing can panic at runtime and there are +safe alternatives. + +### Example +``` +// Vector +let x = vec![0; 5]; + +x[2]; +&x[2..100]; + +// Array +let y = [0, 1, 2, 3]; + +&y[10..100]; +&y[10..]; +``` + +Use instead: +``` + +x.get(2); +x.get(2..100); + +y.get(10); +y.get(10..100); +``` \ No newline at end of file diff --git a/src/docs/ineffective_bit_mask.txt b/src/docs/ineffective_bit_mask.txt new file mode 100644 index 00000000000..f6e7ef55621 --- /dev/null +++ b/src/docs/ineffective_bit_mask.txt @@ -0,0 +1,25 @@ +### What it does +Checks for bit masks in comparisons which can be removed +without changing the outcome. The basic structure can be seen in the +following table: + +|Comparison| Bit Op |Example |equals | +|----------|----------|------------|-------| +|`>` / `<=`|`\|` / `^`|`x \| 2 > 3`|`x > 3`| +|`<` / `>=`|`\|` / `^`|`x ^ 1 < 4` |`x < 4`| + +### Why is this bad? +Not equally evil as [`bad_bit_mask`](#bad_bit_mask), +but still a bit misleading, because the bit mask is ineffective. + +### Known problems +False negatives: This lint will only match instances +where we have figured out the math (which is for a power-of-two compared +value). This means things like `x | 1 >= 7` (which would be better written +as `x >= 6`) will not be reported (but bit masks like this are fairly +uncommon). + +### Example +``` +if (x | 1 > 3) { } +``` \ No newline at end of file diff --git a/src/docs/inefficient_to_string.txt b/src/docs/inefficient_to_string.txt new file mode 100644 index 00000000000..f7061d1ce7b --- /dev/null +++ b/src/docs/inefficient_to_string.txt @@ -0,0 +1,17 @@ +### What it does +Checks for usage of `.to_string()` on an `&&T` where +`T` implements `ToString` directly (like `&&str` or `&&String`). + +### Why is this bad? +This bypasses the specialized implementation of +`ToString` and instead goes through the more expensive string formatting +facilities. + +### Example +``` +// Generic implementation for `T: Display` is used (slow) +["foo", "bar"].iter().map(|s| s.to_string()); + +// OK, the specialized impl is used +["foo", "bar"].iter().map(|&s| s.to_string()); +``` \ No newline at end of file diff --git a/src/docs/infallible_destructuring_match.txt b/src/docs/infallible_destructuring_match.txt new file mode 100644 index 00000000000..4b5d3c4ba6c --- /dev/null +++ b/src/docs/infallible_destructuring_match.txt @@ -0,0 +1,29 @@ +### What it does +Checks for matches being used to destructure a single-variant enum +or tuple struct where a `let` will suffice. + +### Why is this bad? +Just readability – `let` doesn't nest, whereas a `match` does. + +### Example +``` +enum Wrapper { + Data(i32), +} + +let wrapper = Wrapper::Data(42); + +let data = match wrapper { + Wrapper::Data(i) => i, +}; +``` + +The correct use would be: +``` +enum Wrapper { + Data(i32), +} + +let wrapper = Wrapper::Data(42); +let Wrapper::Data(data) = wrapper; +``` \ No newline at end of file diff --git a/src/docs/infinite_iter.txt b/src/docs/infinite_iter.txt new file mode 100644 index 00000000000..8a22fabc549 --- /dev/null +++ b/src/docs/infinite_iter.txt @@ -0,0 +1,13 @@ +### What it does +Checks for iteration that is guaranteed to be infinite. + +### Why is this bad? +While there may be places where this is acceptable +(e.g., in event streams), in most cases this is simply an error. + +### Example +``` +use std::iter; + +iter::repeat(1_u8).collect::>(); +``` \ No newline at end of file diff --git a/src/docs/inherent_to_string.txt b/src/docs/inherent_to_string.txt new file mode 100644 index 00000000000..b18e600e9e6 --- /dev/null +++ b/src/docs/inherent_to_string.txt @@ -0,0 +1,29 @@ +### What it does +Checks for the definition of inherent methods with a signature of `to_string(&self) -> String`. + +### Why is this bad? +This method is also implicitly defined if a type implements the `Display` trait. As the functionality of `Display` is much more versatile, it should be preferred. + +### Example +``` +pub struct A; + +impl A { + pub fn to_string(&self) -> String { + "I am A".to_string() + } +} +``` + +Use instead: +``` +use std::fmt; + +pub struct A; + +impl fmt::Display for A { + fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { + write!(f, "I am A") + } +} +``` \ No newline at end of file diff --git a/src/docs/inherent_to_string_shadow_display.txt b/src/docs/inherent_to_string_shadow_display.txt new file mode 100644 index 00000000000..a4bd0b622c4 --- /dev/null +++ b/src/docs/inherent_to_string_shadow_display.txt @@ -0,0 +1,37 @@ +### What it does +Checks for the definition of inherent methods with a signature of `to_string(&self) -> String` and if the type implementing this method also implements the `Display` trait. + +### Why is this bad? +This method is also implicitly defined if a type implements the `Display` trait. The less versatile inherent method will then shadow the implementation introduced by `Display`. + +### Example +``` +use std::fmt; + +pub struct A; + +impl A { + pub fn to_string(&self) -> String { + "I am A".to_string() + } +} + +impl fmt::Display for A { + fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { + write!(f, "I am A, too") + } +} +``` + +Use instead: +``` +use std::fmt; + +pub struct A; + +impl fmt::Display for A { + fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { + write!(f, "I am A") + } +} +``` \ No newline at end of file diff --git a/src/docs/init_numbered_fields.txt b/src/docs/init_numbered_fields.txt new file mode 100644 index 00000000000..ba40af6a5fa --- /dev/null +++ b/src/docs/init_numbered_fields.txt @@ -0,0 +1,24 @@ +### What it does +Checks for tuple structs initialized with field syntax. +It will however not lint if a base initializer is present. +The lint will also ignore code in macros. + +### Why is this bad? +This may be confusing to the uninitiated and adds no +benefit as opposed to tuple initializers + +### Example +``` +struct TupleStruct(u8, u16); + +let _ = TupleStruct { + 0: 1, + 1: 23, +}; + +// should be written as +let base = TupleStruct(1, 23); + +// This is OK however +let _ = TupleStruct { 0: 42, ..base }; +``` \ No newline at end of file diff --git a/src/docs/inline_always.txt b/src/docs/inline_always.txt new file mode 100644 index 00000000000..7721da4c4cc --- /dev/null +++ b/src/docs/inline_always.txt @@ -0,0 +1,23 @@ +### What it does +Checks for items annotated with `#[inline(always)]`, +unless the annotated function is empty or simply panics. + +### Why is this bad? +While there are valid uses of this annotation (and once +you know when to use it, by all means `allow` this lint), it's a common +newbie-mistake to pepper one's code with it. + +As a rule of thumb, before slapping `#[inline(always)]` on a function, +measure if that additional function call really affects your runtime profile +sufficiently to make up for the increase in compile time. + +### Known problems +False positives, big time. This lint is meant to be +deactivated by everyone doing serious performance work. This means having +done the measurement. + +### Example +``` +#[inline(always)] +fn not_quite_hot_code(..) { ... } +``` \ No newline at end of file diff --git a/src/docs/inline_asm_x86_att_syntax.txt b/src/docs/inline_asm_x86_att_syntax.txt new file mode 100644 index 00000000000..8eb49d122d8 --- /dev/null +++ b/src/docs/inline_asm_x86_att_syntax.txt @@ -0,0 +1,16 @@ +### What it does +Checks for usage of AT&T x86 assembly syntax. + +### Why is this bad? +The lint has been enabled to indicate a preference +for Intel x86 assembly syntax. + +### Example + +``` +asm!("lea ({}), {}", in(reg) ptr, lateout(reg) _, options(att_syntax)); +``` +Use instead: +``` +asm!("lea {}, [{}]", lateout(reg) _, in(reg) ptr); +``` \ No newline at end of file diff --git a/src/docs/inline_asm_x86_intel_syntax.txt b/src/docs/inline_asm_x86_intel_syntax.txt new file mode 100644 index 00000000000..5aa22c8ed23 --- /dev/null +++ b/src/docs/inline_asm_x86_intel_syntax.txt @@ -0,0 +1,16 @@ +### What it does +Checks for usage of Intel x86 assembly syntax. + +### Why is this bad? +The lint has been enabled to indicate a preference +for AT&T x86 assembly syntax. + +### Example + +``` +asm!("lea {}, [{}]", lateout(reg) _, in(reg) ptr); +``` +Use instead: +``` +asm!("lea ({}), {}", in(reg) ptr, lateout(reg) _, options(att_syntax)); +``` \ No newline at end of file diff --git a/src/docs/inline_fn_without_body.txt b/src/docs/inline_fn_without_body.txt new file mode 100644 index 00000000000..127c161aaa2 --- /dev/null +++ b/src/docs/inline_fn_without_body.txt @@ -0,0 +1,14 @@ +### What it does +Checks for `#[inline]` on trait methods without bodies + +### Why is this bad? +Only implementations of trait methods may be inlined. +The inline attribute is ignored for trait methods without bodies. + +### Example +``` +trait Animal { + #[inline] + fn name(&self) -> &'static str; +} +``` \ No newline at end of file diff --git a/src/docs/inspect_for_each.txt b/src/docs/inspect_for_each.txt new file mode 100644 index 00000000000..01a46d6c451 --- /dev/null +++ b/src/docs/inspect_for_each.txt @@ -0,0 +1,23 @@ +### What it does +Checks for usage of `inspect().for_each()`. + +### Why is this bad? +It is the same as performing the computation +inside `inspect` at the beginning of the closure in `for_each`. + +### Example +``` +[1,2,3,4,5].iter() +.inspect(|&x| println!("inspect the number: {}", x)) +.for_each(|&x| { + assert!(x >= 0); +}); +``` +Can be written as +``` +[1,2,3,4,5].iter() +.for_each(|&x| { + println!("inspect the number: {}", x); + assert!(x >= 0); +}); +``` \ No newline at end of file diff --git a/src/docs/int_plus_one.txt b/src/docs/int_plus_one.txt new file mode 100644 index 00000000000..1b68f3eeb64 --- /dev/null +++ b/src/docs/int_plus_one.txt @@ -0,0 +1,15 @@ +### What it does +Checks for usage of `x >= y + 1` or `x - 1 >= y` (and `<=`) in a block + +### Why is this bad? +Readability -- better to use `> y` instead of `>= y + 1`. + +### Example +``` +if x >= y + 1 {} +``` + +Use instead: +``` +if x > y {} +``` \ No newline at end of file diff --git a/src/docs/integer_arithmetic.txt b/src/docs/integer_arithmetic.txt new file mode 100644 index 00000000000..ea57a2ef97b --- /dev/null +++ b/src/docs/integer_arithmetic.txt @@ -0,0 +1,18 @@ +### What it does +Checks for integer arithmetic operations which could overflow or panic. + +Specifically, checks for any operators (`+`, `-`, `*`, `<<`, etc) which are capable +of overflowing according to the [Rust +Reference](https://doc.rust-lang.org/reference/expressions/operator-expr.html#overflow), +or which can panic (`/`, `%`). No bounds analysis or sophisticated reasoning is +attempted. + +### Why is this bad? +Integer overflow will trigger a panic in debug builds or will wrap in +release mode. Division by zero will cause a panic in either mode. In some applications one +wants explicitly checked, wrapping or saturating arithmetic. + +### Example +``` +a + 1; +``` \ No newline at end of file diff --git a/src/docs/integer_division.txt b/src/docs/integer_division.txt new file mode 100644 index 00000000000..f6d3349810e --- /dev/null +++ b/src/docs/integer_division.txt @@ -0,0 +1,19 @@ +### What it does +Checks for division of integers + +### Why is this bad? +When outside of some very specific algorithms, +integer division is very often a mistake because it discards the +remainder. + +### Example +``` +let x = 3 / 2; +println!("{}", x); +``` + +Use instead: +``` +let x = 3f32 / 2f32; +println!("{}", x); +``` \ No newline at end of file diff --git a/src/docs/into_iter_on_ref.txt b/src/docs/into_iter_on_ref.txt new file mode 100644 index 00000000000..acb6bd474eb --- /dev/null +++ b/src/docs/into_iter_on_ref.txt @@ -0,0 +1,18 @@ +### What it does +Checks for `into_iter` calls on references which should be replaced by `iter` +or `iter_mut`. + +### Why is this bad? +Readability. Calling `into_iter` on a reference will not move out its +content into the resulting iterator, which is confusing. It is better just call `iter` or +`iter_mut` directly. + +### Example +``` +(&vec).into_iter(); +``` + +Use instead: +``` +(&vec).iter(); +``` \ No newline at end of file diff --git a/src/docs/invalid_null_ptr_usage.txt b/src/docs/invalid_null_ptr_usage.txt new file mode 100644 index 00000000000..6fb3fa3f83d --- /dev/null +++ b/src/docs/invalid_null_ptr_usage.txt @@ -0,0 +1,16 @@ +### What it does +This lint checks for invalid usages of `ptr::null`. + +### Why is this bad? +This causes undefined behavior. + +### Example +``` +// Undefined behavior +unsafe { std::slice::from_raw_parts(ptr::null(), 0); } +``` + +Use instead: +``` +unsafe { std::slice::from_raw_parts(NonNull::dangling().as_ptr(), 0); } +``` \ No newline at end of file diff --git a/src/docs/invalid_regex.txt b/src/docs/invalid_regex.txt new file mode 100644 index 00000000000..6c9969b6e1a --- /dev/null +++ b/src/docs/invalid_regex.txt @@ -0,0 +1,12 @@ +### What it does +Checks [regex](https://crates.io/crates/regex) creation +(with `Regex::new`, `RegexBuilder::new`, or `RegexSet::new`) for correct +regex syntax. + +### Why is this bad? +This will lead to a runtime panic. + +### Example +``` +Regex::new("(") +``` \ No newline at end of file diff --git a/src/docs/invalid_upcast_comparisons.txt b/src/docs/invalid_upcast_comparisons.txt new file mode 100644 index 00000000000..77cb0330803 --- /dev/null +++ b/src/docs/invalid_upcast_comparisons.txt @@ -0,0 +1,18 @@ +### What it does +Checks for comparisons where the relation is always either +true or false, but where one side has been upcast so that the comparison is +necessary. Only integer types are checked. + +### Why is this bad? +An expression like `let x : u8 = ...; (x as u32) > 300` +will mistakenly imply that it is possible for `x` to be outside the range of +`u8`. + +### Known problems +https://github.com/rust-lang/rust-clippy/issues/886 + +### Example +``` +let x: u8 = 1; +(x as u32) > 300; +``` \ No newline at end of file diff --git a/src/docs/invalid_utf8_in_unchecked.txt b/src/docs/invalid_utf8_in_unchecked.txt new file mode 100644 index 00000000000..afb5acbe9c5 --- /dev/null +++ b/src/docs/invalid_utf8_in_unchecked.txt @@ -0,0 +1,12 @@ +### What it does +Checks for `std::str::from_utf8_unchecked` with an invalid UTF-8 literal + +### Why is this bad? +Creating such a `str` would result in undefined behavior + +### Example +``` +unsafe { + std::str::from_utf8_unchecked(b"cl\x82ippy"); +} +``` \ No newline at end of file diff --git a/src/docs/invisible_characters.txt b/src/docs/invisible_characters.txt new file mode 100644 index 00000000000..3dda380911f --- /dev/null +++ b/src/docs/invisible_characters.txt @@ -0,0 +1,10 @@ +### What it does +Checks for invisible Unicode characters in the code. + +### Why is this bad? +Having an invisible character in the code makes for all +sorts of April fools, but otherwise is very much frowned upon. + +### Example +You don't see it, but there may be a zero-width space or soft hyphen +some­where in this text. \ No newline at end of file diff --git a/src/docs/is_digit_ascii_radix.txt b/src/docs/is_digit_ascii_radix.txt new file mode 100644 index 00000000000..9f11cf43054 --- /dev/null +++ b/src/docs/is_digit_ascii_radix.txt @@ -0,0 +1,20 @@ +### What it does +Finds usages of [`char::is_digit`](https://doc.rust-lang.org/stable/std/primitive.char.html#method.is_digit) that +can be replaced with [`is_ascii_digit`](https://doc.rust-lang.org/stable/std/primitive.char.html#method.is_ascii_digit) or +[`is_ascii_hexdigit`](https://doc.rust-lang.org/stable/std/primitive.char.html#method.is_ascii_hexdigit). + +### Why is this bad? +`is_digit(..)` is slower and requires specifying the radix. + +### Example +``` +let c: char = '6'; +c.is_digit(10); +c.is_digit(16); +``` +Use instead: +``` +let c: char = '6'; +c.is_ascii_digit(); +c.is_ascii_hexdigit(); +``` \ No newline at end of file diff --git a/src/docs/items_after_statements.txt b/src/docs/items_after_statements.txt new file mode 100644 index 00000000000..6fdfff50d20 --- /dev/null +++ b/src/docs/items_after_statements.txt @@ -0,0 +1,37 @@ +### What it does +Checks for items declared after some statement in a block. + +### Why is this bad? +Items live for the entire scope they are declared +in. But statements are processed in order. This might cause confusion as +it's hard to figure out which item is meant in a statement. + +### Example +``` +fn foo() { + println!("cake"); +} + +fn main() { + foo(); // prints "foo" + fn foo() { + println!("foo"); + } + foo(); // prints "foo" +} +``` + +Use instead: +``` +fn foo() { + println!("cake"); +} + +fn main() { + fn foo() { + println!("foo"); + } + foo(); // prints "foo" + foo(); // prints "foo" +} +``` \ No newline at end of file diff --git a/src/docs/iter_cloned_collect.txt b/src/docs/iter_cloned_collect.txt new file mode 100644 index 00000000000..90dc9ebb40f --- /dev/null +++ b/src/docs/iter_cloned_collect.txt @@ -0,0 +1,17 @@ +### What it does +Checks for the use of `.cloned().collect()` on slice to +create a `Vec`. + +### Why is this bad? +`.to_vec()` is clearer + +### Example +``` +let s = [1, 2, 3, 4, 5]; +let s2: Vec = s[..].iter().cloned().collect(); +``` +The better use would be: +``` +let s = [1, 2, 3, 4, 5]; +let s2: Vec = s.to_vec(); +``` \ No newline at end of file diff --git a/src/docs/iter_count.txt b/src/docs/iter_count.txt new file mode 100644 index 00000000000..f3db4a26c29 --- /dev/null +++ b/src/docs/iter_count.txt @@ -0,0 +1,22 @@ +### What it does +Checks for the use of `.iter().count()`. + +### Why is this bad? +`.len()` is more efficient and more +readable. + +### Example +``` +let some_vec = vec![0, 1, 2, 3]; + +some_vec.iter().count(); +&some_vec[..].iter().count(); +``` + +Use instead: +``` +let some_vec = vec![0, 1, 2, 3]; + +some_vec.len(); +&some_vec[..].len(); +``` \ No newline at end of file diff --git a/src/docs/iter_next_loop.txt b/src/docs/iter_next_loop.txt new file mode 100644 index 00000000000..b33eb39d6e1 --- /dev/null +++ b/src/docs/iter_next_loop.txt @@ -0,0 +1,17 @@ +### What it does +Checks for loops on `x.next()`. + +### Why is this bad? +`next()` returns either `Some(value)` if there was a +value, or `None` otherwise. The insidious thing is that `Option<_>` +implements `IntoIterator`, so that possibly one value will be iterated, +leading to some hard to find bugs. No one will want to write such code +[except to win an Underhanded Rust +Contest](https://www.reddit.com/r/rust/comments/3hb0wm/underhanded_rust_contest/cu5yuhr). + +### Example +``` +for x in y.next() { + .. +} +``` \ No newline at end of file diff --git a/src/docs/iter_next_slice.txt b/src/docs/iter_next_slice.txt new file mode 100644 index 00000000000..1cea25eaf30 --- /dev/null +++ b/src/docs/iter_next_slice.txt @@ -0,0 +1,16 @@ +### What it does +Checks for usage of `iter().next()` on a Slice or an Array + +### Why is this bad? +These can be shortened into `.get()` + +### Example +``` +a[2..].iter().next(); +b.iter().next(); +``` +should be written as: +``` +a.get(2); +b.get(0); +``` \ No newline at end of file diff --git a/src/docs/iter_not_returning_iterator.txt b/src/docs/iter_not_returning_iterator.txt new file mode 100644 index 00000000000..0ca862910a6 --- /dev/null +++ b/src/docs/iter_not_returning_iterator.txt @@ -0,0 +1,26 @@ +### What it does +Detects methods named `iter` or `iter_mut` that do not have a return type that implements `Iterator`. + +### Why is this bad? +Methods named `iter` or `iter_mut` conventionally return an `Iterator`. + +### Example +``` +// `String` does not implement `Iterator` +struct Data {} +impl Data { + fn iter(&self) -> String { + todo!() + } +} +``` +Use instead: +``` +use std::str::Chars; +struct Data {} +impl Data { + fn iter(&self) -> Chars<'static> { + todo!() + } +} +``` \ No newline at end of file diff --git a/src/docs/iter_nth.txt b/src/docs/iter_nth.txt new file mode 100644 index 00000000000..3d67d583ffd --- /dev/null +++ b/src/docs/iter_nth.txt @@ -0,0 +1,20 @@ +### What it does +Checks for use of `.iter().nth()` (and the related +`.iter_mut().nth()`) on standard library types with *O*(1) element access. + +### Why is this bad? +`.get()` and `.get_mut()` are more efficient and more +readable. + +### Example +``` +let some_vec = vec![0, 1, 2, 3]; +let bad_vec = some_vec.iter().nth(3); +let bad_slice = &some_vec[..].iter().nth(3); +``` +The correct use would be: +``` +let some_vec = vec![0, 1, 2, 3]; +let bad_vec = some_vec.get(3); +let bad_slice = &some_vec[..].get(3); +``` \ No newline at end of file diff --git a/src/docs/iter_nth_zero.txt b/src/docs/iter_nth_zero.txt new file mode 100644 index 00000000000..8efe47a16a1 --- /dev/null +++ b/src/docs/iter_nth_zero.txt @@ -0,0 +1,17 @@ +### What it does +Checks for the use of `iter.nth(0)`. + +### Why is this bad? +`iter.next()` is equivalent to +`iter.nth(0)`, as they both consume the next element, + but is more readable. + +### Example +``` +let x = s.iter().nth(0); +``` + +Use instead: +``` +let x = s.iter().next(); +``` \ No newline at end of file diff --git a/src/docs/iter_on_empty_collections.txt b/src/docs/iter_on_empty_collections.txt new file mode 100644 index 00000000000..87c4ec12afa --- /dev/null +++ b/src/docs/iter_on_empty_collections.txt @@ -0,0 +1,25 @@ +### What it does + +Checks for calls to `iter`, `iter_mut` or `into_iter` on empty collections + +### Why is this bad? + +It is simpler to use the empty function from the standard library: + +### Example + +``` +use std::{slice, option}; +let a: slice::Iter = [].iter(); +let f: option::IntoIter = None.into_iter(); +``` +Use instead: +``` +use std::iter; +let a: iter::Empty = iter::empty(); +let b: iter::Empty = iter::empty(); +``` + +### Known problems + +The type of the resulting iterator might become incompatible with its usage \ No newline at end of file diff --git a/src/docs/iter_on_single_items.txt b/src/docs/iter_on_single_items.txt new file mode 100644 index 00000000000..d0388f25d04 --- /dev/null +++ b/src/docs/iter_on_single_items.txt @@ -0,0 +1,24 @@ +### What it does + +Checks for calls to `iter`, `iter_mut` or `into_iter` on collections containing a single item + +### Why is this bad? + +It is simpler to use the once function from the standard library: + +### Example + +``` +let a = [123].iter(); +let b = Some(123).into_iter(); +``` +Use instead: +``` +use std::iter; +let a = iter::once(&123); +let b = iter::once(123); +``` + +### Known problems + +The type of the resulting iterator might become incompatible with its usage \ No newline at end of file diff --git a/src/docs/iter_overeager_cloned.txt b/src/docs/iter_overeager_cloned.txt new file mode 100644 index 00000000000..2f902a0c2db --- /dev/null +++ b/src/docs/iter_overeager_cloned.txt @@ -0,0 +1,22 @@ +### What it does +Checks for usage of `_.cloned().()` where call to `.cloned()` can be postponed. + +### Why is this bad? +It's often inefficient to clone all elements of an iterator, when eventually, only some +of them will be consumed. + +### Known Problems +This `lint` removes the side of effect of cloning items in the iterator. +A code that relies on that side-effect could fail. + +### Examples +``` +vec.iter().cloned().take(10); +vec.iter().cloned().last(); +``` + +Use instead: +``` +vec.iter().take(10).cloned(); +vec.iter().last().cloned(); +``` \ No newline at end of file diff --git a/src/docs/iter_skip_next.txt b/src/docs/iter_skip_next.txt new file mode 100644 index 00000000000..da226b041cf --- /dev/null +++ b/src/docs/iter_skip_next.txt @@ -0,0 +1,18 @@ +### What it does +Checks for use of `.skip(x).next()` on iterators. + +### Why is this bad? +`.nth(x)` is cleaner + +### Example +``` +let some_vec = vec![0, 1, 2, 3]; +let bad_vec = some_vec.iter().skip(3).next(); +let bad_slice = &some_vec[..].iter().skip(3).next(); +``` +The correct use would be: +``` +let some_vec = vec![0, 1, 2, 3]; +let bad_vec = some_vec.iter().nth(3); +let bad_slice = &some_vec[..].iter().nth(3); +``` \ No newline at end of file diff --git a/src/docs/iter_with_drain.txt b/src/docs/iter_with_drain.txt new file mode 100644 index 00000000000..2c52b99f7a5 --- /dev/null +++ b/src/docs/iter_with_drain.txt @@ -0,0 +1,16 @@ +### What it does +Checks for use of `.drain(..)` on `Vec` and `VecDeque` for iteration. + +### Why is this bad? +`.into_iter()` is simpler with better performance. + +### Example +``` +let mut foo = vec![0, 1, 2, 3]; +let bar: HashSet = foo.drain(..).collect(); +``` +Use instead: +``` +let foo = vec![0, 1, 2, 3]; +let bar: HashSet = foo.into_iter().collect(); +``` \ No newline at end of file diff --git a/src/docs/iterator_step_by_zero.txt b/src/docs/iterator_step_by_zero.txt new file mode 100644 index 00000000000..73ecc99acfc --- /dev/null +++ b/src/docs/iterator_step_by_zero.txt @@ -0,0 +1,13 @@ +### What it does +Checks for calling `.step_by(0)` on iterators which panics. + +### Why is this bad? +This very much looks like an oversight. Use `panic!()` instead if you +actually intend to panic. + +### Example +``` +for x in (0..100).step_by(0) { + //.. +} +``` \ No newline at end of file diff --git a/src/docs/just_underscores_and_digits.txt b/src/docs/just_underscores_and_digits.txt new file mode 100644 index 00000000000..a8790bcf25b --- /dev/null +++ b/src/docs/just_underscores_and_digits.txt @@ -0,0 +1,14 @@ +### What it does +Checks if you have variables whose name consists of just +underscores and digits. + +### Why is this bad? +It's hard to memorize what a variable means without a +descriptive name. + +### Example +``` +let _1 = 1; +let ___1 = 1; +let __1___2 = 11; +``` \ No newline at end of file diff --git a/src/docs/large_const_arrays.txt b/src/docs/large_const_arrays.txt new file mode 100644 index 00000000000..71f67854f2a --- /dev/null +++ b/src/docs/large_const_arrays.txt @@ -0,0 +1,17 @@ +### What it does +Checks for large `const` arrays that should +be defined as `static` instead. + +### Why is this bad? +Performance: const variables are inlined upon use. +Static items result in only one instance and has a fixed location in memory. + +### Example +``` +pub const a = [0u32; 1_000_000]; +``` + +Use instead: +``` +pub static a = [0u32; 1_000_000]; +``` \ No newline at end of file diff --git a/src/docs/large_digit_groups.txt b/src/docs/large_digit_groups.txt new file mode 100644 index 00000000000..f60b19345af --- /dev/null +++ b/src/docs/large_digit_groups.txt @@ -0,0 +1,12 @@ +### What it does +Warns if the digits of an integral or floating-point +constant are grouped into groups that +are too large. + +### Why is this bad? +Negatively impacts readability. + +### Example +``` +let x: u64 = 6186491_8973511; +``` \ No newline at end of file diff --git a/src/docs/large_enum_variant.txt b/src/docs/large_enum_variant.txt new file mode 100644 index 00000000000..787e8e027e1 --- /dev/null +++ b/src/docs/large_enum_variant.txt @@ -0,0 +1,40 @@ +### What it does +Checks for large size differences between variants on +`enum`s. + +### Why is this bad? +Enum size is bounded by the largest variant. Having a +large variant can penalize the memory layout of that enum. + +### Known problems +This lint obviously cannot take the distribution of +variants in your running program into account. It is possible that the +smaller variants make up less than 1% of all instances, in which case +the overhead is negligible and the boxing is counter-productive. Always +measure the change this lint suggests. + +For types that implement `Copy`, the suggestion to `Box` a variant's +data would require removing the trait impl. The types can of course +still be `Clone`, but that is worse ergonomically. Depending on the +use case it may be possible to store the large data in an auxiliary +structure (e.g. Arena or ECS). + +The lint will ignore generic types if the layout depends on the +generics, even if the size difference will be large anyway. + +### Example +``` +enum Test { + A(i32), + B([i32; 8000]), +} +``` + +Use instead: +``` +// Possibly better +enum Test2 { + A(i32), + B(Box<[i32; 8000]>), +} +``` \ No newline at end of file diff --git a/src/docs/large_include_file.txt b/src/docs/large_include_file.txt new file mode 100644 index 00000000000..b2a54bd2eb5 --- /dev/null +++ b/src/docs/large_include_file.txt @@ -0,0 +1,21 @@ +### What it does +Checks for the inclusion of large files via `include_bytes!()` +and `include_str!()` + +### Why is this bad? +Including large files can increase the size of the binary + +### Example +``` +let included_str = include_str!("very_large_file.txt"); +let included_bytes = include_bytes!("very_large_file.txt"); +``` + +Use instead: +``` +use std::fs; + +// You can load the file at runtime +let string = fs::read_to_string("very_large_file.txt")?; +let bytes = fs::read("very_large_file.txt")?; +``` \ No newline at end of file diff --git a/src/docs/large_stack_arrays.txt b/src/docs/large_stack_arrays.txt new file mode 100644 index 00000000000..4a6f34785b0 --- /dev/null +++ b/src/docs/large_stack_arrays.txt @@ -0,0 +1,10 @@ +### What it does +Checks for local arrays that may be too large. + +### Why is this bad? +Large local arrays may cause stack overflow. + +### Example +``` +let a = [0u32; 1_000_000]; +``` \ No newline at end of file diff --git a/src/docs/large_types_passed_by_value.txt b/src/docs/large_types_passed_by_value.txt new file mode 100644 index 00000000000..bca07f3ac61 --- /dev/null +++ b/src/docs/large_types_passed_by_value.txt @@ -0,0 +1,24 @@ +### What it does +Checks for functions taking arguments by value, where +the argument type is `Copy` and large enough to be worth considering +passing by reference. Does not trigger if the function is being exported, +because that might induce API breakage, if the parameter is declared as mutable, +or if the argument is a `self`. + +### Why is this bad? +Arguments passed by value might result in an unnecessary +shallow copy, taking up more space in the stack and requiring a call to +`memcpy`, which can be expensive. + +### Example +``` +#[derive(Clone, Copy)] +struct TooLarge([u8; 2048]); + +fn foo(v: TooLarge) {} +``` + +Use instead: +``` +fn foo(v: &TooLarge) {} +``` \ No newline at end of file diff --git a/src/docs/len_without_is_empty.txt b/src/docs/len_without_is_empty.txt new file mode 100644 index 00000000000..47a2e857522 --- /dev/null +++ b/src/docs/len_without_is_empty.txt @@ -0,0 +1,19 @@ +### What it does +Checks for items that implement `.len()` but not +`.is_empty()`. + +### Why is this bad? +It is good custom to have both methods, because for +some data structures, asking about the length will be a costly operation, +whereas `.is_empty()` can usually answer in constant time. Also it used to +lead to false positives on the [`len_zero`](#len_zero) lint – currently that +lint will ignore such entities. + +### Example +``` +impl X { + pub fn len(&self) -> usize { + .. + } +} +``` \ No newline at end of file diff --git a/src/docs/len_zero.txt b/src/docs/len_zero.txt new file mode 100644 index 00000000000..664124bd391 --- /dev/null +++ b/src/docs/len_zero.txt @@ -0,0 +1,28 @@ +### What it does +Checks for getting the length of something via `.len()` +just to compare to zero, and suggests using `.is_empty()` where applicable. + +### Why is this bad? +Some structures can answer `.is_empty()` much faster +than calculating their length. So it is good to get into the habit of using +`.is_empty()`, and having it is cheap. +Besides, it makes the intent clearer than a manual comparison in some contexts. + +### Example +``` +if x.len() == 0 { + .. +} +if y.len() != 0 { + .. +} +``` +instead use +``` +if x.is_empty() { + .. +} +if !y.is_empty() { + .. +} +``` \ No newline at end of file diff --git a/src/docs/let_and_return.txt b/src/docs/let_and_return.txt new file mode 100644 index 00000000000..eba5a90ddd6 --- /dev/null +++ b/src/docs/let_and_return.txt @@ -0,0 +1,21 @@ +### What it does +Checks for `let`-bindings, which are subsequently +returned. + +### Why is this bad? +It is just extraneous code. Remove it to make your code +more rusty. + +### Example +``` +fn foo() -> String { + let x = String::new(); + x +} +``` +instead, use +``` +fn foo() -> String { + String::new() +} +``` \ No newline at end of file diff --git a/src/docs/let_underscore_drop.txt b/src/docs/let_underscore_drop.txt new file mode 100644 index 00000000000..29ce9bf50ce --- /dev/null +++ b/src/docs/let_underscore_drop.txt @@ -0,0 +1,29 @@ +### What it does +Checks for `let _ = ` +where expr has a type that implements `Drop` + +### Why is this bad? +This statement immediately drops the initializer +expression instead of extending its lifetime to the end of the scope, which +is often not intended. To extend the expression's lifetime to the end of the +scope, use an underscore-prefixed name instead (i.e. _var). If you want to +explicitly drop the expression, `std::mem::drop` conveys your intention +better and is less error-prone. + +### Example +``` +{ + let _ = DroppableItem; + // ^ dropped here + /* more code */ +} +``` + +Use instead: +``` +{ + let _droppable = DroppableItem; + /* more code */ + // dropped at end of scope +} +``` \ No newline at end of file diff --git a/src/docs/let_underscore_lock.txt b/src/docs/let_underscore_lock.txt new file mode 100644 index 00000000000..bd8217fb58b --- /dev/null +++ b/src/docs/let_underscore_lock.txt @@ -0,0 +1,20 @@ +### What it does +Checks for `let _ = sync_lock`. +This supports `mutex` and `rwlock` in `std::sync` and `parking_lot`. + +### Why is this bad? +This statement immediately drops the lock instead of +extending its lifetime to the end of the scope, which is often not intended. +To extend lock lifetime to the end of the scope, use an underscore-prefixed +name instead (i.e. _lock). If you want to explicitly drop the lock, +`std::mem::drop` conveys your intention better and is less error-prone. + +### Example +``` +let _ = mutex.lock(); +``` + +Use instead: +``` +let _lock = mutex.lock(); +``` \ No newline at end of file diff --git a/src/docs/let_underscore_must_use.txt b/src/docs/let_underscore_must_use.txt new file mode 100644 index 00000000000..270b81d9a4c --- /dev/null +++ b/src/docs/let_underscore_must_use.txt @@ -0,0 +1,17 @@ +### What it does +Checks for `let _ = ` where expr is `#[must_use]` + +### Why is this bad? +It's better to explicitly handle the value of a `#[must_use]` +expr + +### Example +``` +fn f() -> Result { + Ok(0) +} + +let _ = f(); +// is_ok() is marked #[must_use] +let _ = f().is_ok(); +``` \ No newline at end of file diff --git a/src/docs/let_unit_value.txt b/src/docs/let_unit_value.txt new file mode 100644 index 00000000000..bc16d5b3d81 --- /dev/null +++ b/src/docs/let_unit_value.txt @@ -0,0 +1,13 @@ +### What it does +Checks for binding a unit value. + +### Why is this bad? +A unit value cannot usefully be used anywhere. So +binding one is kind of pointless. + +### Example +``` +let x = { + 1; +}; +``` \ No newline at end of file diff --git a/src/docs/linkedlist.txt b/src/docs/linkedlist.txt new file mode 100644 index 00000000000..986ff1369e3 --- /dev/null +++ b/src/docs/linkedlist.txt @@ -0,0 +1,32 @@ +### What it does +Checks for usage of any `LinkedList`, suggesting to use a +`Vec` or a `VecDeque` (formerly called `RingBuf`). + +### Why is this bad? +Gankro says: + +> The TL;DR of `LinkedList` is that it's built on a massive amount of +pointers and indirection. +> It wastes memory, it has terrible cache locality, and is all-around slow. +`RingBuf`, while +> "only" amortized for push/pop, should be faster in the general case for +almost every possible +> workload, and isn't even amortized at all if you can predict the capacity +you need. +> +> `LinkedList`s are only really good if you're doing a lot of merging or +splitting of lists. +> This is because they can just mangle some pointers instead of actually +copying the data. Even +> if you're doing a lot of insertion in the middle of the list, `RingBuf` +can still be better +> because of how expensive it is to seek to the middle of a `LinkedList`. + +### Known problems +False positives – the instances where using a +`LinkedList` makes sense are few and far between, but they can still happen. + +### Example +``` +let x: LinkedList = LinkedList::new(); +``` \ No newline at end of file diff --git a/src/docs/lossy_float_literal.txt b/src/docs/lossy_float_literal.txt new file mode 100644 index 00000000000..bbcb9115ea6 --- /dev/null +++ b/src/docs/lossy_float_literal.txt @@ -0,0 +1,18 @@ +### What it does +Checks for whole number float literals that +cannot be represented as the underlying type without loss. + +### Why is this bad? +Rust will silently lose precision during +conversion to a float. + +### Example +``` +let _: f32 = 16_777_217.0; // 16_777_216.0 +``` + +Use instead: +``` +let _: f32 = 16_777_216.0; +let _: f64 = 16_777_217.0; +``` \ No newline at end of file diff --git a/src/docs/macro_use_imports.txt b/src/docs/macro_use_imports.txt new file mode 100644 index 00000000000..6a8180a60bc --- /dev/null +++ b/src/docs/macro_use_imports.txt @@ -0,0 +1,12 @@ +### What it does +Checks for `#[macro_use] use...`. + +### Why is this bad? +Since the Rust 2018 edition you can import +macro's directly, this is considered idiomatic. + +### Example +``` +#[macro_use] +use some_macro; +``` \ No newline at end of file diff --git a/src/docs/main_recursion.txt b/src/docs/main_recursion.txt new file mode 100644 index 00000000000..e49becd15bb --- /dev/null +++ b/src/docs/main_recursion.txt @@ -0,0 +1,13 @@ +### What it does +Checks for recursion using the entrypoint. + +### Why is this bad? +Apart from special setups (which we could detect following attributes like #![no_std]), +recursing into main() seems like an unintuitive anti-pattern we should be able to detect. + +### Example +``` +fn main() { + main(); +} +``` \ No newline at end of file diff --git a/src/docs/manual_assert.txt b/src/docs/manual_assert.txt new file mode 100644 index 00000000000..93653081a2c --- /dev/null +++ b/src/docs/manual_assert.txt @@ -0,0 +1,18 @@ +### What it does +Detects `if`-then-`panic!` that can be replaced with `assert!`. + +### Why is this bad? +`assert!` is simpler than `if`-then-`panic!`. + +### Example +``` +let sad_people: Vec<&str> = vec![]; +if !sad_people.is_empty() { + panic!("there are sad people: {:?}", sad_people); +} +``` +Use instead: +``` +let sad_people: Vec<&str> = vec![]; +assert!(sad_people.is_empty(), "there are sad people: {:?}", sad_people); +``` \ No newline at end of file diff --git a/src/docs/manual_async_fn.txt b/src/docs/manual_async_fn.txt new file mode 100644 index 00000000000..d01ac402e0d --- /dev/null +++ b/src/docs/manual_async_fn.txt @@ -0,0 +1,16 @@ +### What it does +It checks for manual implementations of `async` functions. + +### Why is this bad? +It's more idiomatic to use the dedicated syntax. + +### Example +``` +use std::future::Future; + +fn foo() -> impl Future { async { 42 } } +``` +Use instead: +``` +async fn foo() -> i32 { 42 } +``` \ No newline at end of file diff --git a/src/docs/manual_bits.txt b/src/docs/manual_bits.txt new file mode 100644 index 00000000000..b96c2eb151d --- /dev/null +++ b/src/docs/manual_bits.txt @@ -0,0 +1,15 @@ +### What it does +Checks for uses of `std::mem::size_of::() * 8` when +`T::BITS` is available. + +### Why is this bad? +Can be written as the shorter `T::BITS`. + +### Example +``` +std::mem::size_of::() * 8; +``` +Use instead: +``` +usize::BITS as usize; +``` \ No newline at end of file diff --git a/src/docs/manual_filter_map.txt b/src/docs/manual_filter_map.txt new file mode 100644 index 00000000000..3b6860798ff --- /dev/null +++ b/src/docs/manual_filter_map.txt @@ -0,0 +1,19 @@ +### What it does +Checks for usage of `_.filter(_).map(_)` that can be written more simply +as `filter_map(_)`. + +### Why is this bad? +Redundant code in the `filter` and `map` operations is poor style and +less performant. + +### Example +``` +(0_i32..10) + .filter(|n| n.checked_add(1).is_some()) + .map(|n| n.checked_add(1).unwrap()); +``` + +Use instead: +``` +(0_i32..10).filter_map(|n| n.checked_add(1)); +``` \ No newline at end of file diff --git a/src/docs/manual_find.txt b/src/docs/manual_find.txt new file mode 100644 index 00000000000..e3e07a2771f --- /dev/null +++ b/src/docs/manual_find.txt @@ -0,0 +1,24 @@ +### What it does +Check for manual implementations of Iterator::find + +### Why is this bad? +It doesn't affect performance, but using `find` is shorter and easier to read. + +### Example + +``` +fn example(arr: Vec) -> Option { + for el in arr { + if el == 1 { + return Some(el); + } + } + None +} +``` +Use instead: +``` +fn example(arr: Vec) -> Option { + arr.into_iter().find(|&el| el == 1) +} +``` \ No newline at end of file diff --git a/src/docs/manual_find_map.txt b/src/docs/manual_find_map.txt new file mode 100644 index 00000000000..83b22060c0e --- /dev/null +++ b/src/docs/manual_find_map.txt @@ -0,0 +1,19 @@ +### What it does +Checks for usage of `_.find(_).map(_)` that can be written more simply +as `find_map(_)`. + +### Why is this bad? +Redundant code in the `find` and `map` operations is poor style and +less performant. + +### Example +``` +(0_i32..10) + .find(|n| n.checked_add(1).is_some()) + .map(|n| n.checked_add(1).unwrap()); +``` + +Use instead: +``` +(0_i32..10).find_map(|n| n.checked_add(1)); +``` \ No newline at end of file diff --git a/src/docs/manual_flatten.txt b/src/docs/manual_flatten.txt new file mode 100644 index 00000000000..62d5f3ec935 --- /dev/null +++ b/src/docs/manual_flatten.txt @@ -0,0 +1,25 @@ +### What it does +Check for unnecessary `if let` usage in a for loop +where only the `Some` or `Ok` variant of the iterator element is used. + +### Why is this bad? +It is verbose and can be simplified +by first calling the `flatten` method on the `Iterator`. + +### Example + +``` +let x = vec![Some(1), Some(2), Some(3)]; +for n in x { + if let Some(n) = n { + println!("{}", n); + } +} +``` +Use instead: +``` +let x = vec![Some(1), Some(2), Some(3)]; +for n in x.into_iter().flatten() { + println!("{}", n); +} +``` \ No newline at end of file diff --git a/src/docs/manual_instant_elapsed.txt b/src/docs/manual_instant_elapsed.txt new file mode 100644 index 00000000000..dde3d493c70 --- /dev/null +++ b/src/docs/manual_instant_elapsed.txt @@ -0,0 +1,21 @@ +### What it does +Lints subtraction between `Instant::now()` and another `Instant`. + +### Why is this bad? +It is easy to accidentally write `prev_instant - Instant::now()`, which will always be 0ns +as `Instant` subtraction saturates. + +`prev_instant.elapsed()` also more clearly signals intention. + +### Example +``` +use std::time::Instant; +let prev_instant = Instant::now(); +let duration = Instant::now() - prev_instant; +``` +Use instead: +``` +use std::time::Instant; +let prev_instant = Instant::now(); +let duration = prev_instant.elapsed(); +``` \ No newline at end of file diff --git a/src/docs/manual_map.txt b/src/docs/manual_map.txt new file mode 100644 index 00000000000..7f68ccd1037 --- /dev/null +++ b/src/docs/manual_map.txt @@ -0,0 +1,17 @@ +### What it does +Checks for usages of `match` which could be implemented using `map` + +### Why is this bad? +Using the `map` method is clearer and more concise. + +### Example +``` +match Some(0) { + Some(x) => Some(x + 1), + None => None, +}; +``` +Use instead: +``` +Some(0).map(|x| x + 1); +``` \ No newline at end of file diff --git a/src/docs/manual_memcpy.txt b/src/docs/manual_memcpy.txt new file mode 100644 index 00000000000..d7690bf2586 --- /dev/null +++ b/src/docs/manual_memcpy.txt @@ -0,0 +1,18 @@ +### What it does +Checks for for-loops that manually copy items between +slices that could be optimized by having a memcpy. + +### Why is this bad? +It is not as fast as a memcpy. + +### Example +``` +for i in 0..src.len() { + dst[i + 64] = src[i]; +} +``` + +Use instead: +``` +dst[64..(src.len() + 64)].clone_from_slice(&src[..]); +``` \ No newline at end of file diff --git a/src/docs/manual_non_exhaustive.txt b/src/docs/manual_non_exhaustive.txt new file mode 100644 index 00000000000..fb021393bd7 --- /dev/null +++ b/src/docs/manual_non_exhaustive.txt @@ -0,0 +1,41 @@ +### What it does +Checks for manual implementations of the non-exhaustive pattern. + +### Why is this bad? +Using the #[non_exhaustive] attribute expresses better the intent +and allows possible optimizations when applied to enums. + +### Example +``` +struct S { + pub a: i32, + pub b: i32, + _c: (), +} + +enum E { + A, + B, + #[doc(hidden)] + _C, +} + +struct T(pub i32, pub i32, ()); +``` +Use instead: +``` +#[non_exhaustive] +struct S { + pub a: i32, + pub b: i32, +} + +#[non_exhaustive] +enum E { + A, + B, +} + +#[non_exhaustive] +struct T(pub i32, pub i32); +``` \ No newline at end of file diff --git a/src/docs/manual_ok_or.txt b/src/docs/manual_ok_or.txt new file mode 100644 index 00000000000..5accdf25965 --- /dev/null +++ b/src/docs/manual_ok_or.txt @@ -0,0 +1,19 @@ +### What it does + +Finds patterns that reimplement `Option::ok_or`. + +### Why is this bad? + +Concise code helps focusing on behavior instead of boilerplate. + +### Examples +``` +let foo: Option = None; +foo.map_or(Err("error"), |v| Ok(v)); +``` + +Use instead: +``` +let foo: Option = None; +foo.ok_or("error"); +``` \ No newline at end of file diff --git a/src/docs/manual_range_contains.txt b/src/docs/manual_range_contains.txt new file mode 100644 index 00000000000..0ade26951d3 --- /dev/null +++ b/src/docs/manual_range_contains.txt @@ -0,0 +1,19 @@ +### What it does +Checks for expressions like `x >= 3 && x < 8` that could +be more readably expressed as `(3..8).contains(x)`. + +### Why is this bad? +`contains` expresses the intent better and has less +failure modes (such as fencepost errors or using `||` instead of `&&`). + +### Example +``` +// given +let x = 6; + +assert!(x >= 3 && x < 8); +``` +Use instead: +``` +assert!((3..8).contains(&x)); +``` \ No newline at end of file diff --git a/src/docs/manual_rem_euclid.txt b/src/docs/manual_rem_euclid.txt new file mode 100644 index 00000000000..d3bb8c61304 --- /dev/null +++ b/src/docs/manual_rem_euclid.txt @@ -0,0 +1,17 @@ +### What it does +Checks for an expression like `((x % 4) + 4) % 4` which is a common manual reimplementation +of `x.rem_euclid(4)`. + +### Why is this bad? +It's simpler and more readable. + +### Example +``` +let x: i32 = 24; +let rem = ((x % 4) + 4) % 4; +``` +Use instead: +``` +let x: i32 = 24; +let rem = x.rem_euclid(4); +``` \ No newline at end of file diff --git a/src/docs/manual_retain.txt b/src/docs/manual_retain.txt new file mode 100644 index 00000000000..cd4f65a93fc --- /dev/null +++ b/src/docs/manual_retain.txt @@ -0,0 +1,15 @@ +### What it does +Checks for code to be replaced by `.retain()`. +### Why is this bad? +`.retain()` is simpler and avoids needless allocation. +### Example +``` +let mut vec = vec![0, 1, 2]; +vec = vec.iter().filter(|&x| x % 2 == 0).copied().collect(); +vec = vec.into_iter().filter(|x| x % 2 == 0).collect(); +``` +Use instead: +``` +let mut vec = vec![0, 1, 2]; +vec.retain(|x| x % 2 == 0); +``` \ No newline at end of file diff --git a/src/docs/manual_saturating_arithmetic.txt b/src/docs/manual_saturating_arithmetic.txt new file mode 100644 index 00000000000..d9f5d3d1187 --- /dev/null +++ b/src/docs/manual_saturating_arithmetic.txt @@ -0,0 +1,18 @@ +### What it does +Checks for `.checked_add/sub(x).unwrap_or(MAX/MIN)`. + +### Why is this bad? +These can be written simply with `saturating_add/sub` methods. + +### Example +``` +let add = x.checked_add(y).unwrap_or(u32::MAX); +let sub = x.checked_sub(y).unwrap_or(u32::MIN); +``` + +can be written using dedicated methods for saturating addition/subtraction as: + +``` +let add = x.saturating_add(y); +let sub = x.saturating_sub(y); +``` \ No newline at end of file diff --git a/src/docs/manual_split_once.txt b/src/docs/manual_split_once.txt new file mode 100644 index 00000000000..291ae447de0 --- /dev/null +++ b/src/docs/manual_split_once.txt @@ -0,0 +1,29 @@ +### What it does +Checks for usages of `str::splitn(2, _)` + +### Why is this bad? +`split_once` is both clearer in intent and slightly more efficient. + +### Example +``` +let s = "key=value=add"; +let (key, value) = s.splitn(2, '=').next_tuple()?; +let value = s.splitn(2, '=').nth(1)?; + +let mut parts = s.splitn(2, '='); +let key = parts.next()?; +let value = parts.next()?; +``` + +Use instead: +``` +let s = "key=value=add"; +let (key, value) = s.split_once('=')?; +let value = s.split_once('=')?.1; + +let (key, value) = s.split_once('=')?; +``` + +### Limitations +The multiple statement variant currently only detects `iter.next()?`/`iter.next().unwrap()` +in two separate `let` statements that immediately follow the `splitn()` \ No newline at end of file diff --git a/src/docs/manual_str_repeat.txt b/src/docs/manual_str_repeat.txt new file mode 100644 index 00000000000..1d4a7a48e20 --- /dev/null +++ b/src/docs/manual_str_repeat.txt @@ -0,0 +1,15 @@ +### What it does +Checks for manual implementations of `str::repeat` + +### Why is this bad? +These are both harder to read, as well as less performant. + +### Example +``` +let x: String = std::iter::repeat('x').take(10).collect(); +``` + +Use instead: +``` +let x: String = "x".repeat(10); +``` \ No newline at end of file diff --git a/src/docs/manual_string_new.txt b/src/docs/manual_string_new.txt new file mode 100644 index 00000000000..4cbc43f8f84 --- /dev/null +++ b/src/docs/manual_string_new.txt @@ -0,0 +1,20 @@ +### What it does + +Checks for usage of `""` to create a `String`, such as `"".to_string()`, `"".to_owned()`, +`String::from("")` and others. + +### Why is this bad? + +Different ways of creating an empty string makes your code less standardized, which can +be confusing. + +### Example +``` +let a = "".to_string(); +let b: String = "".into(); +``` +Use instead: +``` +let a = String::new(); +let b = String::new(); +``` \ No newline at end of file diff --git a/src/docs/manual_strip.txt b/src/docs/manual_strip.txt new file mode 100644 index 00000000000..f32d8e7a09b --- /dev/null +++ b/src/docs/manual_strip.txt @@ -0,0 +1,24 @@ +### What it does +Suggests using `strip_{prefix,suffix}` over `str::{starts,ends}_with` and slicing using +the pattern's length. + +### Why is this bad? +Using `str:strip_{prefix,suffix}` is safer and may have better performance as there is no +slicing which may panic and the compiler does not need to insert this panic code. It is +also sometimes more readable as it removes the need for duplicating or storing the pattern +used by `str::{starts,ends}_with` and in the slicing. + +### Example +``` +let s = "hello, world!"; +if s.starts_with("hello, ") { + assert_eq!(s["hello, ".len()..].to_uppercase(), "WORLD!"); +} +``` +Use instead: +``` +let s = "hello, world!"; +if let Some(end) = s.strip_prefix("hello, ") { + assert_eq!(end.to_uppercase(), "WORLD!"); +} +``` \ No newline at end of file diff --git a/src/docs/manual_swap.txt b/src/docs/manual_swap.txt new file mode 100644 index 00000000000..bd9526288e3 --- /dev/null +++ b/src/docs/manual_swap.txt @@ -0,0 +1,22 @@ +### What it does +Checks for manual swapping. + +### Why is this bad? +The `std::mem::swap` function exposes the intent better +without deinitializing or copying either variable. + +### Example +``` +let mut a = 42; +let mut b = 1337; + +let t = b; +b = a; +a = t; +``` +Use std::mem::swap(): +``` +let mut a = 1; +let mut b = 2; +std::mem::swap(&mut a, &mut b); +``` \ No newline at end of file diff --git a/src/docs/manual_unwrap_or.txt b/src/docs/manual_unwrap_or.txt new file mode 100644 index 00000000000..1fd7d831bfc --- /dev/null +++ b/src/docs/manual_unwrap_or.txt @@ -0,0 +1,20 @@ +### What it does +Finds patterns that reimplement `Option::unwrap_or` or `Result::unwrap_or`. + +### Why is this bad? +Concise code helps focusing on behavior instead of boilerplate. + +### Example +``` +let foo: Option = None; +match foo { + Some(v) => v, + None => 1, +}; +``` + +Use instead: +``` +let foo: Option = None; +foo.unwrap_or(1); +``` \ No newline at end of file diff --git a/src/docs/many_single_char_names.txt b/src/docs/many_single_char_names.txt new file mode 100644 index 00000000000..55ee5da5557 --- /dev/null +++ b/src/docs/many_single_char_names.txt @@ -0,0 +1,12 @@ +### What it does +Checks for too many variables whose name consists of a +single character. + +### Why is this bad? +It's hard to memorize what a variable means without a +descriptive name. + +### Example +``` +let (a, b, c, d, e, f, g) = (...); +``` \ No newline at end of file diff --git a/src/docs/map_clone.txt b/src/docs/map_clone.txt new file mode 100644 index 00000000000..3ee27f072ef --- /dev/null +++ b/src/docs/map_clone.txt @@ -0,0 +1,22 @@ +### What it does +Checks for usage of `map(|x| x.clone())` or +dereferencing closures for `Copy` types, on `Iterator` or `Option`, +and suggests `cloned()` or `copied()` instead + +### Why is this bad? +Readability, this can be written more concisely + +### Example +``` +let x = vec![42, 43]; +let y = x.iter(); +let z = y.map(|i| *i); +``` + +The correct use would be: + +``` +let x = vec![42, 43]; +let y = x.iter(); +let z = y.cloned(); +``` \ No newline at end of file diff --git a/src/docs/map_collect_result_unit.txt b/src/docs/map_collect_result_unit.txt new file mode 100644 index 00000000000..9b720612495 --- /dev/null +++ b/src/docs/map_collect_result_unit.txt @@ -0,0 +1,14 @@ +### What it does +Checks for usage of `_.map(_).collect::()`. + +### Why is this bad? +Using `try_for_each` instead is more readable and idiomatic. + +### Example +``` +(0..3).map(|t| Err(t)).collect::>(); +``` +Use instead: +``` +(0..3).try_for_each(|t| Err(t)); +``` \ No newline at end of file diff --git a/src/docs/map_entry.txt b/src/docs/map_entry.txt new file mode 100644 index 00000000000..20dba1798d0 --- /dev/null +++ b/src/docs/map_entry.txt @@ -0,0 +1,28 @@ +### What it does +Checks for uses of `contains_key` + `insert` on `HashMap` +or `BTreeMap`. + +### Why is this bad? +Using `entry` is more efficient. + +### Known problems +The suggestion may have type inference errors in some cases. e.g. +``` +let mut map = std::collections::HashMap::new(); +let _ = if !map.contains_key(&0) { + map.insert(0, 0) +} else { + None +}; +``` + +### Example +``` +if !map.contains_key(&k) { + map.insert(k, v); +} +``` +Use instead: +``` +map.entry(k).or_insert(v); +``` \ No newline at end of file diff --git a/src/docs/map_err_ignore.txt b/src/docs/map_err_ignore.txt new file mode 100644 index 00000000000..2606c13a7af --- /dev/null +++ b/src/docs/map_err_ignore.txt @@ -0,0 +1,93 @@ +### What it does +Checks for instances of `map_err(|_| Some::Enum)` + +### Why is this bad? +This `map_err` throws away the original error rather than allowing the enum to contain and report the cause of the error + +### Example +Before: +``` +use std::fmt; + +#[derive(Debug)] +enum Error { + Indivisible, + Remainder(u8), +} + +impl fmt::Display for Error { + fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { + match self { + Error::Indivisible => write!(f, "could not divide input by three"), + Error::Remainder(remainder) => write!( + f, + "input is not divisible by three, remainder = {}", + remainder + ), + } + } +} + +impl std::error::Error for Error {} + +fn divisible_by_3(input: &str) -> Result<(), Error> { + input + .parse::() + .map_err(|_| Error::Indivisible) + .map(|v| v % 3) + .and_then(|remainder| { + if remainder == 0 { + Ok(()) + } else { + Err(Error::Remainder(remainder as u8)) + } + }) +} + ``` + + After: + ```rust +use std::{fmt, num::ParseIntError}; + +#[derive(Debug)] +enum Error { + Indivisible(ParseIntError), + Remainder(u8), +} + +impl fmt::Display for Error { + fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { + match self { + Error::Indivisible(_) => write!(f, "could not divide input by three"), + Error::Remainder(remainder) => write!( + f, + "input is not divisible by three, remainder = {}", + remainder + ), + } + } +} + +impl std::error::Error for Error { + fn source(&self) -> Option<&(dyn std::error::Error + 'static)> { + match self { + Error::Indivisible(source) => Some(source), + _ => None, + } + } +} + +fn divisible_by_3(input: &str) -> Result<(), Error> { + input + .parse::() + .map_err(Error::Indivisible) + .map(|v| v % 3) + .and_then(|remainder| { + if remainder == 0 { + Ok(()) + } else { + Err(Error::Remainder(remainder as u8)) + } + }) +} +``` \ No newline at end of file diff --git a/src/docs/map_flatten.txt b/src/docs/map_flatten.txt new file mode 100644 index 00000000000..73c0e51407f --- /dev/null +++ b/src/docs/map_flatten.txt @@ -0,0 +1,21 @@ +### What it does +Checks for usage of `_.map(_).flatten(_)` on `Iterator` and `Option` + +### Why is this bad? +Readability, this can be written more concisely as +`_.flat_map(_)` for `Iterator` or `_.and_then(_)` for `Option` + +### Example +``` +let vec = vec![vec![1]]; +let opt = Some(5); + +vec.iter().map(|x| x.iter()).flatten(); +opt.map(|x| Some(x * 2)).flatten(); +``` + +Use instead: +``` +vec.iter().flat_map(|x| x.iter()); +opt.and_then(|x| Some(x * 2)); +``` \ No newline at end of file diff --git a/src/docs/map_identity.txt b/src/docs/map_identity.txt new file mode 100644 index 00000000000..e2e7af0bed9 --- /dev/null +++ b/src/docs/map_identity.txt @@ -0,0 +1,16 @@ +### What it does +Checks for instances of `map(f)` where `f` is the identity function. + +### Why is this bad? +It can be written more concisely without the call to `map`. + +### Example +``` +let x = [1, 2, 3]; +let y: Vec<_> = x.iter().map(|x| x).map(|x| 2*x).collect(); +``` +Use instead: +``` +let x = [1, 2, 3]; +let y: Vec<_> = x.iter().map(|x| 2*x).collect(); +``` \ No newline at end of file diff --git a/src/docs/map_unwrap_or.txt b/src/docs/map_unwrap_or.txt new file mode 100644 index 00000000000..485b29f01b1 --- /dev/null +++ b/src/docs/map_unwrap_or.txt @@ -0,0 +1,22 @@ +### What it does +Checks for usage of `option.map(_).unwrap_or(_)` or `option.map(_).unwrap_or_else(_)` or +`result.map(_).unwrap_or_else(_)`. + +### Why is this bad? +Readability, these can be written more concisely (resp.) as +`option.map_or(_, _)`, `option.map_or_else(_, _)` and `result.map_or_else(_, _)`. + +### Known problems +The order of the arguments is not in execution order + +### Examples +``` +option.map(|a| a + 1).unwrap_or(0); +result.map(|a| a + 1).unwrap_or_else(some_function); +``` + +Use instead: +``` +option.map_or(0, |a| a + 1); +result.map_or_else(some_function, |a| a + 1); +``` \ No newline at end of file diff --git a/src/docs/match_as_ref.txt b/src/docs/match_as_ref.txt new file mode 100644 index 00000000000..5e5f3d645a4 --- /dev/null +++ b/src/docs/match_as_ref.txt @@ -0,0 +1,23 @@ +### What it does +Checks for match which is used to add a reference to an +`Option` value. + +### Why is this bad? +Using `as_ref()` or `as_mut()` instead is shorter. + +### Example +``` +let x: Option<()> = None; + +let r: Option<&()> = match x { + None => None, + Some(ref v) => Some(v), +}; +``` + +Use instead: +``` +let x: Option<()> = None; + +let r: Option<&()> = x.as_ref(); +``` \ No newline at end of file diff --git a/src/docs/match_bool.txt b/src/docs/match_bool.txt new file mode 100644 index 00000000000..96f9e1f8b7d --- /dev/null +++ b/src/docs/match_bool.txt @@ -0,0 +1,24 @@ +### What it does +Checks for matches where match expression is a `bool`. It +suggests to replace the expression with an `if...else` block. + +### Why is this bad? +It makes the code less readable. + +### Example +``` +let condition: bool = true; +match condition { + true => foo(), + false => bar(), +} +``` +Use if/else instead: +``` +let condition: bool = true; +if condition { + foo(); +} else { + bar(); +} +``` \ No newline at end of file diff --git a/src/docs/match_like_matches_macro.txt b/src/docs/match_like_matches_macro.txt new file mode 100644 index 00000000000..643e2ddc97b --- /dev/null +++ b/src/docs/match_like_matches_macro.txt @@ -0,0 +1,32 @@ +### What it does +Checks for `match` or `if let` expressions producing a +`bool` that could be written using `matches!` + +### Why is this bad? +Readability and needless complexity. + +### Known problems +This lint falsely triggers, if there are arms with +`cfg` attributes that remove an arm evaluating to `false`. + +### Example +``` +let x = Some(5); + +let a = match x { + Some(0) => true, + _ => false, +}; + +let a = if let Some(0) = x { + true +} else { + false +}; +``` + +Use instead: +``` +let x = Some(5); +let a = matches!(x, Some(0)); +``` \ No newline at end of file diff --git a/src/docs/match_on_vec_items.txt b/src/docs/match_on_vec_items.txt new file mode 100644 index 00000000000..981d18d0f9e --- /dev/null +++ b/src/docs/match_on_vec_items.txt @@ -0,0 +1,29 @@ +### What it does +Checks for `match vec[idx]` or `match vec[n..m]`. + +### Why is this bad? +This can panic at runtime. + +### Example +``` +let arr = vec![0, 1, 2, 3]; +let idx = 1; + +match arr[idx] { + 0 => println!("{}", 0), + 1 => println!("{}", 3), + _ => {}, +} +``` + +Use instead: +``` +let arr = vec![0, 1, 2, 3]; +let idx = 1; + +match arr.get(idx) { + Some(0) => println!("{}", 0), + Some(1) => println!("{}", 3), + _ => {}, +} +``` \ No newline at end of file diff --git a/src/docs/match_overlapping_arm.txt b/src/docs/match_overlapping_arm.txt new file mode 100644 index 00000000000..841c091bd5c --- /dev/null +++ b/src/docs/match_overlapping_arm.txt @@ -0,0 +1,16 @@ +### What it does +Checks for overlapping match arms. + +### Why is this bad? +It is likely to be an error and if not, makes the code +less obvious. + +### Example +``` +let x = 5; +match x { + 1..=10 => println!("1 ... 10"), + 5..=15 => println!("5 ... 15"), + _ => (), +} +``` \ No newline at end of file diff --git a/src/docs/match_ref_pats.txt b/src/docs/match_ref_pats.txt new file mode 100644 index 00000000000..b1d90299509 --- /dev/null +++ b/src/docs/match_ref_pats.txt @@ -0,0 +1,26 @@ +### What it does +Checks for matches where all arms match a reference, +suggesting to remove the reference and deref the matched expression +instead. It also checks for `if let &foo = bar` blocks. + +### Why is this bad? +It just makes the code less readable. That reference +destructuring adds nothing to the code. + +### Example +``` +match x { + &A(ref y) => foo(y), + &B => bar(), + _ => frob(&x), +} +``` + +Use instead: +``` +match *x { + A(ref y) => foo(y), + B => bar(), + _ => frob(x), +} +``` \ No newline at end of file diff --git a/src/docs/match_result_ok.txt b/src/docs/match_result_ok.txt new file mode 100644 index 00000000000..eea7c8e00f1 --- /dev/null +++ b/src/docs/match_result_ok.txt @@ -0,0 +1,27 @@ +### What it does +Checks for unnecessary `ok()` in `while let`. + +### Why is this bad? +Calling `ok()` in `while let` is unnecessary, instead match +on `Ok(pat)` + +### Example +``` +while let Some(value) = iter.next().ok() { + vec.push(value) +} + +if let Some(value) = iter.next().ok() { + vec.push(value) +} +``` +Use instead: +``` +while let Ok(value) = iter.next() { + vec.push(value) +} + +if let Ok(value) = iter.next() { + vec.push(value) +} +``` \ No newline at end of file diff --git a/src/docs/match_same_arms.txt b/src/docs/match_same_arms.txt new file mode 100644 index 00000000000..14edf12032e --- /dev/null +++ b/src/docs/match_same_arms.txt @@ -0,0 +1,38 @@ +### What it does +Checks for `match` with identical arm bodies. + +### Why is this bad? +This is probably a copy & paste error. If arm bodies +are the same on purpose, you can factor them +[using `|`](https://doc.rust-lang.org/book/patterns.html#multiple-patterns). + +### Known problems +False positive possible with order dependent `match` +(see issue +[#860](https://github.com/rust-lang/rust-clippy/issues/860)). + +### Example +``` +match foo { + Bar => bar(), + Quz => quz(), + Baz => bar(), // <= oops +} +``` + +This should probably be +``` +match foo { + Bar => bar(), + Quz => quz(), + Baz => baz(), // <= fixed +} +``` + +or if the original code was not a typo: +``` +match foo { + Bar | Baz => bar(), // <= shows the intent better + Quz => quz(), +} +``` \ No newline at end of file diff --git a/src/docs/match_single_binding.txt b/src/docs/match_single_binding.txt new file mode 100644 index 00000000000..67ded0bbd55 --- /dev/null +++ b/src/docs/match_single_binding.txt @@ -0,0 +1,23 @@ +### What it does +Checks for useless match that binds to only one value. + +### Why is this bad? +Readability and needless complexity. + +### Known problems + Suggested replacements may be incorrect when `match` +is actually binding temporary value, bringing a 'dropped while borrowed' error. + +### Example +``` +match (a, b) { + (c, d) => { + // useless match + } +} +``` + +Use instead: +``` +let (c, d) = (a, b); +``` \ No newline at end of file diff --git a/src/docs/match_str_case_mismatch.txt b/src/docs/match_str_case_mismatch.txt new file mode 100644 index 00000000000..19e74c2084e --- /dev/null +++ b/src/docs/match_str_case_mismatch.txt @@ -0,0 +1,22 @@ +### What it does +Checks for `match` expressions modifying the case of a string with non-compliant arms + +### Why is this bad? +The arm is unreachable, which is likely a mistake + +### Example +``` +match &*text.to_ascii_lowercase() { + "foo" => {}, + "Bar" => {}, + _ => {}, +} +``` +Use instead: +``` +match &*text.to_ascii_lowercase() { + "foo" => {}, + "bar" => {}, + _ => {}, +} +``` \ No newline at end of file diff --git a/src/docs/match_wild_err_arm.txt b/src/docs/match_wild_err_arm.txt new file mode 100644 index 00000000000..f89b3a23a1c --- /dev/null +++ b/src/docs/match_wild_err_arm.txt @@ -0,0 +1,16 @@ +### What it does +Checks for arm which matches all errors with `Err(_)` +and take drastic actions like `panic!`. + +### Why is this bad? +It is generally a bad practice, similar to +catching all exceptions in java with `catch(Exception)` + +### Example +``` +let x: Result = Ok(3); +match x { + Ok(_) => println!("ok"), + Err(_) => panic!("err"), +} +``` \ No newline at end of file diff --git a/src/docs/match_wildcard_for_single_variants.txt b/src/docs/match_wildcard_for_single_variants.txt new file mode 100644 index 00000000000..25559b9ecdc --- /dev/null +++ b/src/docs/match_wildcard_for_single_variants.txt @@ -0,0 +1,27 @@ +### What it does +Checks for wildcard enum matches for a single variant. + +### Why is this bad? +New enum variants added by library updates can be missed. + +### Known problems +Suggested replacements may not use correct path to enum +if it's not present in the current scope. + +### Example +``` +match x { + Foo::A => {}, + Foo::B => {}, + _ => {}, +} +``` + +Use instead: +``` +match x { + Foo::A => {}, + Foo::B => {}, + Foo::C => {}, +} +``` \ No newline at end of file diff --git a/src/docs/maybe_infinite_iter.txt b/src/docs/maybe_infinite_iter.txt new file mode 100644 index 00000000000..1204a49b466 --- /dev/null +++ b/src/docs/maybe_infinite_iter.txt @@ -0,0 +1,16 @@ +### What it does +Checks for iteration that may be infinite. + +### Why is this bad? +While there may be places where this is acceptable +(e.g., in event streams), in most cases this is simply an error. + +### Known problems +The code may have a condition to stop iteration, but +this lint is not clever enough to analyze it. + +### Example +``` +let infinite_iter = 0..; +[0..].iter().zip(infinite_iter.take_while(|x| *x > 5)); +``` \ No newline at end of file diff --git a/src/docs/mem_forget.txt b/src/docs/mem_forget.txt new file mode 100644 index 00000000000..a6888c48fc3 --- /dev/null +++ b/src/docs/mem_forget.txt @@ -0,0 +1,12 @@ +### What it does +Checks for usage of `std::mem::forget(t)` where `t` is +`Drop`. + +### Why is this bad? +`std::mem::forget(t)` prevents `t` from running its +destructor, possibly causing leaks. + +### Example +``` +mem::forget(Rc::new(55)) +``` \ No newline at end of file diff --git a/src/docs/mem_replace_option_with_none.txt b/src/docs/mem_replace_option_with_none.txt new file mode 100644 index 00000000000..7f243d1c165 --- /dev/null +++ b/src/docs/mem_replace_option_with_none.txt @@ -0,0 +1,21 @@ +### What it does +Checks for `mem::replace()` on an `Option` with +`None`. + +### Why is this bad? +`Option` already has the method `take()` for +taking its current value (Some(..) or None) and replacing it with +`None`. + +### Example +``` +use std::mem; + +let mut an_option = Some(0); +let replaced = mem::replace(&mut an_option, None); +``` +Is better expressed with: +``` +let mut an_option = Some(0); +let taken = an_option.take(); +``` \ No newline at end of file diff --git a/src/docs/mem_replace_with_default.txt b/src/docs/mem_replace_with_default.txt new file mode 100644 index 00000000000..24e0913a30c --- /dev/null +++ b/src/docs/mem_replace_with_default.txt @@ -0,0 +1,18 @@ +### What it does +Checks for `std::mem::replace` on a value of type +`T` with `T::default()`. + +### Why is this bad? +`std::mem` module already has the method `take` to +take the current value and replace it with the default value of that type. + +### Example +``` +let mut text = String::from("foo"); +let replaced = std::mem::replace(&mut text, String::default()); +``` +Is better expressed with: +``` +let mut text = String::from("foo"); +let taken = std::mem::take(&mut text); +``` \ No newline at end of file diff --git a/src/docs/mem_replace_with_uninit.txt b/src/docs/mem_replace_with_uninit.txt new file mode 100644 index 00000000000..0bb483668ab --- /dev/null +++ b/src/docs/mem_replace_with_uninit.txt @@ -0,0 +1,24 @@ +### What it does +Checks for `mem::replace(&mut _, mem::uninitialized())` +and `mem::replace(&mut _, mem::zeroed())`. + +### Why is this bad? +This will lead to undefined behavior even if the +value is overwritten later, because the uninitialized value may be +observed in the case of a panic. + +### Example +``` +use std::mem; + +#[allow(deprecated, invalid_value)] +fn myfunc (v: &mut Vec) { + let taken_v = unsafe { mem::replace(v, mem::uninitialized()) }; + let new_v = may_panic(taken_v); // undefined behavior on panic + mem::forget(mem::replace(v, new_v)); +} +``` + +The [take_mut](https://docs.rs/take_mut) crate offers a sound solution, +at the cost of either lazily creating a replacement value or aborting +on panic, to ensure that the uninitialized value cannot be observed. \ No newline at end of file diff --git a/src/docs/min_max.txt b/src/docs/min_max.txt new file mode 100644 index 00000000000..6acf0f932e9 --- /dev/null +++ b/src/docs/min_max.txt @@ -0,0 +1,18 @@ +### What it does +Checks for expressions where `std::cmp::min` and `max` are +used to clamp values, but switched so that the result is constant. + +### Why is this bad? +This is in all probability not the intended outcome. At +the least it hurts readability of the code. + +### Example +``` +min(0, max(100, x)) + +// or + +x.max(100).min(0) +``` +It will always be equal to `0`. Probably the author meant to clamp the value +between 0 and 100, but has erroneously swapped `min` and `max`. \ No newline at end of file diff --git a/src/docs/mismatched_target_os.txt b/src/docs/mismatched_target_os.txt new file mode 100644 index 00000000000..51e5ec6e7c5 --- /dev/null +++ b/src/docs/mismatched_target_os.txt @@ -0,0 +1,24 @@ +### What it does +Checks for cfg attributes having operating systems used in target family position. + +### Why is this bad? +The configuration option will not be recognised and the related item will not be included +by the conditional compilation engine. + +### Example +``` +#[cfg(linux)] +fn conditional() { } +``` + +Use instead: +``` +#[cfg(target_os = "linux")] +fn conditional() { } + +// or + +#[cfg(unix)] +fn conditional() { } +``` +Check the [Rust Reference](https://doc.rust-lang.org/reference/conditional-compilation.html#target_os) for more details. \ No newline at end of file diff --git a/src/docs/mismatching_type_param_order.txt b/src/docs/mismatching_type_param_order.txt new file mode 100644 index 00000000000..ffc7f32d0aa --- /dev/null +++ b/src/docs/mismatching_type_param_order.txt @@ -0,0 +1,33 @@ +### What it does +Checks for type parameters which are positioned inconsistently between +a type definition and impl block. Specifically, a parameter in an impl +block which has the same name as a parameter in the type def, but is in +a different place. + +### Why is this bad? +Type parameters are determined by their position rather than name. +Naming type parameters inconsistently may cause you to refer to the +wrong type parameter. + +### Limitations +This lint only applies to impl blocks with simple generic params, e.g. +`A`. If there is anything more complicated, such as a tuple, it will be +ignored. + +### Example +``` +struct Foo { + x: A, + y: B, +} +// inside the impl, B refers to Foo::A +impl Foo {} +``` +Use instead: +``` +struct Foo { + x: A, + y: B, +} +impl Foo {} +``` \ No newline at end of file diff --git a/src/docs/misrefactored_assign_op.txt b/src/docs/misrefactored_assign_op.txt new file mode 100644 index 00000000000..3d691fe4178 --- /dev/null +++ b/src/docs/misrefactored_assign_op.txt @@ -0,0 +1,20 @@ +### What it does +Checks for `a op= a op b` or `a op= b op a` patterns. + +### Why is this bad? +Most likely these are bugs where one meant to write `a +op= b`. + +### Known problems +Clippy cannot know for sure if `a op= a op b` should have +been `a = a op a op b` or `a = a op b`/`a op= b`. Therefore, it suggests both. +If `a op= a op b` is really the correct behavior it should be +written as `a = a op a op b` as it's less confusing. + +### Example +``` +let mut a = 5; +let b = 2; +// ... +a += a + b; +``` \ No newline at end of file diff --git a/src/docs/missing_const_for_fn.txt b/src/docs/missing_const_for_fn.txt new file mode 100644 index 00000000000..067614d4c46 --- /dev/null +++ b/src/docs/missing_const_for_fn.txt @@ -0,0 +1,40 @@ +### What it does +Suggests the use of `const` in functions and methods where possible. + +### Why is this bad? +Not having the function const prevents callers of the function from being const as well. + +### Known problems +Const functions are currently still being worked on, with some features only being available +on nightly. This lint does not consider all edge cases currently and the suggestions may be +incorrect if you are using this lint on stable. + +Also, the lint only runs one pass over the code. Consider these two non-const functions: + +``` +fn a() -> i32 { + 0 +} +fn b() -> i32 { + a() +} +``` + +When running Clippy, the lint will only suggest to make `a` const, because `b` at this time +can't be const as it calls a non-const function. Making `a` const and running Clippy again, +will suggest to make `b` const, too. + +### Example +``` +fn new() -> Self { + Self { random_number: 42 } +} +``` + +Could be a const fn: + +``` +const fn new() -> Self { + Self { random_number: 42 } +} +``` \ No newline at end of file diff --git a/src/docs/missing_docs_in_private_items.txt b/src/docs/missing_docs_in_private_items.txt new file mode 100644 index 00000000000..5d37505bb17 --- /dev/null +++ b/src/docs/missing_docs_in_private_items.txt @@ -0,0 +1,9 @@ +### What it does +Warns if there is missing doc for any documentable item +(public or private). + +### Why is this bad? +Doc is good. *rustc* has a `MISSING_DOCS` +allowed-by-default lint for +public members, but has no way to enforce documentation of private items. +This lint fixes that. \ No newline at end of file diff --git a/src/docs/missing_enforced_import_renames.txt b/src/docs/missing_enforced_import_renames.txt new file mode 100644 index 00000000000..8f4649bd592 --- /dev/null +++ b/src/docs/missing_enforced_import_renames.txt @@ -0,0 +1,22 @@ +### What it does +Checks for imports that do not rename the item as specified +in the `enforce-import-renames` config option. + +### Why is this bad? +Consistency is important, if a project has defined import +renames they should be followed. More practically, some item names are too +vague outside of their defining scope this can enforce a more meaningful naming. + +### Example +An example clippy.toml configuration: +``` +enforced-import-renames = [ { path = "serde_json::Value", rename = "JsonValue" }] +``` + +``` +use serde_json::Value; +``` +Use instead: +``` +use serde_json::Value as JsonValue; +``` \ No newline at end of file diff --git a/src/docs/missing_errors_doc.txt b/src/docs/missing_errors_doc.txt new file mode 100644 index 00000000000..028778d85ae --- /dev/null +++ b/src/docs/missing_errors_doc.txt @@ -0,0 +1,21 @@ +### What it does +Checks the doc comments of publicly visible functions that +return a `Result` type and warns if there is no `# Errors` section. + +### Why is this bad? +Documenting the type of errors that can be returned from a +function can help callers write code to handle the errors appropriately. + +### Examples +Since the following function returns a `Result` it has an `# Errors` section in +its doc comment: + +``` +/// # Errors +/// +/// Will return `Err` if `filename` does not exist or the user does not have +/// permission to read it. +pub fn read(filename: String) -> io::Result { + unimplemented!(); +} +``` \ No newline at end of file diff --git a/src/docs/missing_inline_in_public_items.txt b/src/docs/missing_inline_in_public_items.txt new file mode 100644 index 00000000000..d90c50fe7f9 --- /dev/null +++ b/src/docs/missing_inline_in_public_items.txt @@ -0,0 +1,45 @@ +### What it does +It lints if an exported function, method, trait method with default impl, +or trait method impl is not `#[inline]`. + +### Why is this bad? +In general, it is not. Functions can be inlined across +crates when that's profitable as long as any form of LTO is used. When LTO is disabled, +functions that are not `#[inline]` cannot be inlined across crates. Certain types of crates +might intend for most of the methods in their public API to be able to be inlined across +crates even when LTO is disabled. For these types of crates, enabling this lint might make +sense. It allows the crate to require all exported methods to be `#[inline]` by default, and +then opt out for specific methods where this might not make sense. + +### Example +``` +pub fn foo() {} // missing #[inline] +fn ok() {} // ok +#[inline] pub fn bar() {} // ok +#[inline(always)] pub fn baz() {} // ok + +pub trait Bar { + fn bar(); // ok + fn def_bar() {} // missing #[inline] +} + +struct Baz; +impl Baz { + fn private() {} // ok +} + +impl Bar for Baz { + fn bar() {} // ok - Baz is not exported +} + +pub struct PubBaz; +impl PubBaz { + fn private() {} // ok + pub fn not_private() {} // missing #[inline] +} + +impl Bar for PubBaz { + fn bar() {} // missing #[inline] + fn def_bar() {} // missing #[inline] +} +``` \ No newline at end of file diff --git a/src/docs/missing_panics_doc.txt b/src/docs/missing_panics_doc.txt new file mode 100644 index 00000000000..e5e39a82451 --- /dev/null +++ b/src/docs/missing_panics_doc.txt @@ -0,0 +1,24 @@ +### What it does +Checks the doc comments of publicly visible functions that +may panic and warns if there is no `# Panics` section. + +### Why is this bad? +Documenting the scenarios in which panicking occurs +can help callers who do not want to panic to avoid those situations. + +### Examples +Since the following function may panic it has a `# Panics` section in +its doc comment: + +``` +/// # Panics +/// +/// Will panic if y is 0 +pub fn divide_by(x: i32, y: i32) -> i32 { + if y == 0 { + panic!("Cannot divide by 0") + } else { + x / y + } +} +``` \ No newline at end of file diff --git a/src/docs/missing_safety_doc.txt b/src/docs/missing_safety_doc.txt new file mode 100644 index 00000000000..6492eb84f63 --- /dev/null +++ b/src/docs/missing_safety_doc.txt @@ -0,0 +1,26 @@ +### What it does +Checks for the doc comments of publicly visible +unsafe functions and warns if there is no `# Safety` section. + +### Why is this bad? +Unsafe functions should document their safety +preconditions, so that users can be sure they are using them safely. + +### Examples +``` +/// This function should really be documented +pub unsafe fn start_apocalypse(u: &mut Universe) { + unimplemented!(); +} +``` + +At least write a line about safety: + +``` +/// # Safety +/// +/// This function should not be called before the horsemen are ready. +pub unsafe fn start_apocalypse(u: &mut Universe) { + unimplemented!(); +} +``` \ No newline at end of file diff --git a/src/docs/missing_spin_loop.txt b/src/docs/missing_spin_loop.txt new file mode 100644 index 00000000000..3a06a91d718 --- /dev/null +++ b/src/docs/missing_spin_loop.txt @@ -0,0 +1,27 @@ +### What it does +Check for empty spin loops + +### Why is this bad? +The loop body should have something like `thread::park()` or at least +`std::hint::spin_loop()` to avoid needlessly burning cycles and conserve +energy. Perhaps even better use an actual lock, if possible. + +### Known problems +This lint doesn't currently trigger on `while let` or +`loop { match .. { .. } }` loops, which would be considered idiomatic in +combination with e.g. `AtomicBool::compare_exchange_weak`. + +### Example + +``` +use core::sync::atomic::{AtomicBool, Ordering}; +let b = AtomicBool::new(true); +// give a ref to `b` to another thread,wait for it to become false +while b.load(Ordering::Acquire) {}; +``` +Use instead: +``` +while b.load(Ordering::Acquire) { + std::hint::spin_loop() +} +``` \ No newline at end of file diff --git a/src/docs/mistyped_literal_suffixes.txt b/src/docs/mistyped_literal_suffixes.txt new file mode 100644 index 00000000000..1760fcbfeac --- /dev/null +++ b/src/docs/mistyped_literal_suffixes.txt @@ -0,0 +1,15 @@ +### What it does +Warns for mistyped suffix in literals + +### Why is this bad? +This is most probably a typo + +### Known problems +- Does not match on integers too large to fit in the corresponding unsigned type +- Does not match on `_127` since that is a valid grouping for decimal and octal numbers + +### Example +``` +`2_32` => `2_i32` +`250_8 => `250_u8` +``` \ No newline at end of file diff --git a/src/docs/mixed_case_hex_literals.txt b/src/docs/mixed_case_hex_literals.txt new file mode 100644 index 00000000000..d2d01e0c98e --- /dev/null +++ b/src/docs/mixed_case_hex_literals.txt @@ -0,0 +1,16 @@ +### What it does +Warns on hexadecimal literals with mixed-case letter +digits. + +### Why is this bad? +It looks confusing. + +### Example +``` +0x1a9BAcD +``` + +Use instead: +``` +0x1A9BACD +``` \ No newline at end of file diff --git a/src/docs/mixed_read_write_in_expression.txt b/src/docs/mixed_read_write_in_expression.txt new file mode 100644 index 00000000000..02d1c5d0525 --- /dev/null +++ b/src/docs/mixed_read_write_in_expression.txt @@ -0,0 +1,32 @@ +### What it does +Checks for a read and a write to the same variable where +whether the read occurs before or after the write depends on the evaluation +order of sub-expressions. + +### Why is this bad? +It is often confusing to read. As described [here](https://doc.rust-lang.org/reference/expressions.html?highlight=subexpression#evaluation-order-of-operands), +the operands of these expressions are evaluated before applying the effects of the expression. + +### Known problems +Code which intentionally depends on the evaluation +order, or which is correct for any evaluation order. + +### Example +``` +let mut x = 0; + +let a = { + x = 1; + 1 +} + x; +// Unclear whether a is 1 or 2. +``` + +Use instead: +``` +let tmp = { + x = 1; + 1 +}; +let a = tmp + x; +``` \ No newline at end of file diff --git a/src/docs/mod_module_files.txt b/src/docs/mod_module_files.txt new file mode 100644 index 00000000000..95bca583afd --- /dev/null +++ b/src/docs/mod_module_files.txt @@ -0,0 +1,22 @@ +### What it does +Checks that module layout uses only self named module files, bans `mod.rs` files. + +### Why is this bad? +Having multiple module layout styles in a project can be confusing. + +### Example +``` +src/ + stuff/ + stuff_files.rs + mod.rs + lib.rs +``` +Use instead: +``` +src/ + stuff/ + stuff_files.rs + stuff.rs + lib.rs +``` \ No newline at end of file diff --git a/src/docs/module_inception.txt b/src/docs/module_inception.txt new file mode 100644 index 00000000000..d80a1b8d8fe --- /dev/null +++ b/src/docs/module_inception.txt @@ -0,0 +1,24 @@ +### What it does +Checks for modules that have the same name as their +parent module + +### Why is this bad? +A typical beginner mistake is to have `mod foo;` and +again `mod foo { .. +}` in `foo.rs`. +The expectation is that items inside the inner `mod foo { .. }` are then +available +through `foo::x`, but they are only available through +`foo::foo::x`. +If this is done on purpose, it would be better to choose a more +representative module name. + +### Example +``` +// lib.rs +mod foo; +// foo.rs +mod foo { + ... +} +``` \ No newline at end of file diff --git a/src/docs/module_name_repetitions.txt b/src/docs/module_name_repetitions.txt new file mode 100644 index 00000000000..3bc05d02780 --- /dev/null +++ b/src/docs/module_name_repetitions.txt @@ -0,0 +1,20 @@ +### What it does +Detects type names that are prefixed or suffixed by the +containing module's name. + +### Why is this bad? +It requires the user to type the module name twice. + +### Example +``` +mod cake { + struct BlackForestCake; +} +``` + +Use instead: +``` +mod cake { + struct BlackForest; +} +``` \ No newline at end of file diff --git a/src/docs/modulo_arithmetic.txt b/src/docs/modulo_arithmetic.txt new file mode 100644 index 00000000000..ff7296f3c5b --- /dev/null +++ b/src/docs/modulo_arithmetic.txt @@ -0,0 +1,15 @@ +### What it does +Checks for modulo arithmetic. + +### Why is this bad? +The results of modulo (%) operation might differ +depending on the language, when negative numbers are involved. +If you interop with different languages it might be beneficial +to double check all places that use modulo arithmetic. + +For example, in Rust `17 % -3 = 2`, but in Python `17 % -3 = -1`. + +### Example +``` +let x = -17 % 3; +``` \ No newline at end of file diff --git a/src/docs/modulo_one.txt b/src/docs/modulo_one.txt new file mode 100644 index 00000000000..bc8f95b0be6 --- /dev/null +++ b/src/docs/modulo_one.txt @@ -0,0 +1,16 @@ +### What it does +Checks for getting the remainder of a division by one or minus +one. + +### Why is this bad? +The result for a divisor of one can only ever be zero; for +minus one it can cause panic/overflow (if the left operand is the minimal value of +the respective integer type) or results in zero. No one will write such code +deliberately, unless trying to win an Underhanded Rust Contest. Even for that +contest, it's probably a bad idea. Use something more underhanded. + +### Example +``` +let a = x % 1; +let a = x % -1; +``` \ No newline at end of file diff --git a/src/docs/multi_assignments.txt b/src/docs/multi_assignments.txt new file mode 100644 index 00000000000..ed1f1b420cb --- /dev/null +++ b/src/docs/multi_assignments.txt @@ -0,0 +1,17 @@ +### What it does +Checks for nested assignments. + +### Why is this bad? +While this is in most cases already a type mismatch, +the result of an assignment being `()` can throw off people coming from languages like python or C, +where such assignments return a copy of the assigned value. + +### Example +``` +a = b = 42; +``` +Use instead: +``` +b = 42; +a = b; +``` \ No newline at end of file diff --git a/src/docs/multiple_crate_versions.txt b/src/docs/multiple_crate_versions.txt new file mode 100644 index 00000000000..cf2d2c6abee --- /dev/null +++ b/src/docs/multiple_crate_versions.txt @@ -0,0 +1,19 @@ +### What it does +Checks to see if multiple versions of a crate are being +used. + +### Why is this bad? +This bloats the size of targets, and can lead to +confusing error messages when structs or traits are used interchangeably +between different versions of a crate. + +### Known problems +Because this can be caused purely by the dependencies +themselves, it's not always possible to fix this issue. + +### Example +``` +[dependencies] +ctrlc = "=3.1.0" +ansi_term = "=0.11.0" +``` \ No newline at end of file diff --git a/src/docs/multiple_inherent_impl.txt b/src/docs/multiple_inherent_impl.txt new file mode 100644 index 00000000000..9d42286560c --- /dev/null +++ b/src/docs/multiple_inherent_impl.txt @@ -0,0 +1,26 @@ +### What it does +Checks for multiple inherent implementations of a struct + +### Why is this bad? +Splitting the implementation of a type makes the code harder to navigate. + +### Example +``` +struct X; +impl X { + fn one() {} +} +impl X { + fn other() {} +} +``` + +Could be written: + +``` +struct X; +impl X { + fn one() {} + fn other() {} +} +``` \ No newline at end of file diff --git a/src/docs/must_use_candidate.txt b/src/docs/must_use_candidate.txt new file mode 100644 index 00000000000..70890346fe6 --- /dev/null +++ b/src/docs/must_use_candidate.txt @@ -0,0 +1,23 @@ +### What it does +Checks for public functions that have no +`#[must_use]` attribute, but return something not already marked +must-use, have no mutable arg and mutate no statics. + +### Why is this bad? +Not bad at all, this lint just shows places where +you could add the attribute. + +### Known problems +The lint only checks the arguments for mutable +types without looking if they are actually changed. On the other hand, +it also ignores a broad range of potentially interesting side effects, +because we cannot decide whether the programmer intends the function to +be called for the side effect or the result. Expect many false +positives. At least we don't lint if the result type is unit or already +`#[must_use]`. + +### Examples +``` +// this could be annotated with `#[must_use]`. +fn id(t: T) -> T { t } +``` \ No newline at end of file diff --git a/src/docs/must_use_unit.txt b/src/docs/must_use_unit.txt new file mode 100644 index 00000000000..cabbb23f865 --- /dev/null +++ b/src/docs/must_use_unit.txt @@ -0,0 +1,13 @@ +### What it does +Checks for a `#[must_use]` attribute on +unit-returning functions and methods. + +### Why is this bad? +Unit values are useless. The attribute is likely +a remnant of a refactoring that removed the return type. + +### Examples +``` +#[must_use] +fn useless() { } +``` \ No newline at end of file diff --git a/src/docs/mut_from_ref.txt b/src/docs/mut_from_ref.txt new file mode 100644 index 00000000000..cc1da12549a --- /dev/null +++ b/src/docs/mut_from_ref.txt @@ -0,0 +1,26 @@ +### What it does +This lint checks for functions that take immutable references and return +mutable ones. This will not trigger if no unsafe code exists as there +are multiple safe functions which will do this transformation + +To be on the conservative side, if there's at least one mutable +reference with the output lifetime, this lint will not trigger. + +### Why is this bad? +Creating a mutable reference which can be repeatably derived from an +immutable reference is unsound as it allows creating multiple live +mutable references to the same object. + +This [error](https://github.com/rust-lang/rust/issues/39465) actually +lead to an interim Rust release 1.15.1. + +### Known problems +This pattern is used by memory allocators to allow allocating multiple +objects while returning mutable references to each one. So long as +different mutable references are returned each time such a function may +be safe. + +### Example +``` +fn foo(&Foo) -> &mut Bar { .. } +``` \ No newline at end of file diff --git a/src/docs/mut_mut.txt b/src/docs/mut_mut.txt new file mode 100644 index 00000000000..0bd34dd24b2 --- /dev/null +++ b/src/docs/mut_mut.txt @@ -0,0 +1,12 @@ +### What it does +Checks for instances of `mut mut` references. + +### Why is this bad? +Multiple `mut`s don't add anything meaningful to the +source. This is either a copy'n'paste error, or it shows a fundamental +misunderstanding of references. + +### Example +``` +let x = &mut &mut y; +``` \ No newline at end of file diff --git a/src/docs/mut_mutex_lock.txt b/src/docs/mut_mutex_lock.txt new file mode 100644 index 00000000000..5e9ad8a3f17 --- /dev/null +++ b/src/docs/mut_mutex_lock.txt @@ -0,0 +1,29 @@ +### What it does +Checks for `&mut Mutex::lock` calls + +### Why is this bad? +`Mutex::lock` is less efficient than +calling `Mutex::get_mut`. In addition you also have a statically +guarantee that the mutex isn't locked, instead of just a runtime +guarantee. + +### Example +``` +use std::sync::{Arc, Mutex}; + +let mut value_rc = Arc::new(Mutex::new(42_u8)); +let value_mutex = Arc::get_mut(&mut value_rc).unwrap(); + +let mut value = value_mutex.lock().unwrap(); +*value += 1; +``` +Use instead: +``` +use std::sync::{Arc, Mutex}; + +let mut value_rc = Arc::new(Mutex::new(42_u8)); +let value_mutex = Arc::get_mut(&mut value_rc).unwrap(); + +let value = value_mutex.get_mut().unwrap(); +*value += 1; +``` \ No newline at end of file diff --git a/src/docs/mut_range_bound.txt b/src/docs/mut_range_bound.txt new file mode 100644 index 00000000000..e9c38a543b1 --- /dev/null +++ b/src/docs/mut_range_bound.txt @@ -0,0 +1,29 @@ +### What it does +Checks for loops which have a range bound that is a mutable variable + +### Why is this bad? +One might think that modifying the mutable variable changes the loop bounds + +### Known problems +False positive when mutation is followed by a `break`, but the `break` is not immediately +after the mutation: + +``` +let mut x = 5; +for _ in 0..x { + x += 1; // x is a range bound that is mutated + ..; // some other expression + break; // leaves the loop, so mutation is not an issue +} +``` + +False positive on nested loops ([#6072](https://github.com/rust-lang/rust-clippy/issues/6072)) + +### Example +``` +let mut foo = 42; +for i in 0..foo { + foo -= 1; + println!("{}", i); // prints numbers from 0 to 42, not 0 to 21 +} +``` \ No newline at end of file diff --git a/src/docs/mutable_key_type.txt b/src/docs/mutable_key_type.txt new file mode 100644 index 00000000000..15fe34f2bb5 --- /dev/null +++ b/src/docs/mutable_key_type.txt @@ -0,0 +1,61 @@ +### What it does +Checks for sets/maps with mutable key types. + +### Why is this bad? +All of `HashMap`, `HashSet`, `BTreeMap` and +`BtreeSet` rely on either the hash or the order of keys be unchanging, +so having types with interior mutability is a bad idea. + +### Known problems + +#### False Positives +It's correct to use a struct that contains interior mutability as a key, when its +implementation of `Hash` or `Ord` doesn't access any of the interior mutable types. +However, this lint is unable to recognize this, so it will often cause false positives in +theses cases. The `bytes` crate is a great example of this. + +#### False Negatives +For custom `struct`s/`enum`s, this lint is unable to check for interior mutability behind +indirection. For example, `struct BadKey<'a>(&'a Cell)` will be seen as immutable +and cause a false negative if its implementation of `Hash`/`Ord` accesses the `Cell`. + +This lint does check a few cases for indirection. Firstly, using some standard library +types (`Option`, `Result`, `Box`, `Rc`, `Arc`, `Vec`, `VecDeque`, `BTreeMap` and +`BTreeSet`) directly as keys (e.g. in `HashMap>, ()>`) **will** trigger the +lint, because the impls of `Hash`/`Ord` for these types directly call `Hash`/`Ord` on their +contained type. + +Secondly, the implementations of `Hash` and `Ord` for raw pointers (`*const T` or `*mut T`) +apply only to the **address** of the contained value. Therefore, interior mutability +behind raw pointers (e.g. in `HashSet<*mut Cell>`) can't impact the value of `Hash` +or `Ord`, and therefore will not trigger this link. For more info, see issue +[#6745](https://github.com/rust-lang/rust-clippy/issues/6745). + +### Example +``` +use std::cmp::{PartialEq, Eq}; +use std::collections::HashSet; +use std::hash::{Hash, Hasher}; +use std::sync::atomic::AtomicUsize; + +struct Bad(AtomicUsize); +impl PartialEq for Bad { + fn eq(&self, rhs: &Self) -> bool { + .. +; unimplemented!(); + } +} + +impl Eq for Bad {} + +impl Hash for Bad { + fn hash(&self, h: &mut H) { + .. +; unimplemented!(); + } +} + +fn main() { + let _: HashSet = HashSet::new(); +} +``` \ No newline at end of file diff --git a/src/docs/mutex_atomic.txt b/src/docs/mutex_atomic.txt new file mode 100644 index 00000000000..062ac8b323b --- /dev/null +++ b/src/docs/mutex_atomic.txt @@ -0,0 +1,22 @@ +### What it does +Checks for usages of `Mutex` where an atomic will do. + +### Why is this bad? +Using a mutex just to make access to a plain bool or +reference sequential is shooting flies with cannons. +`std::sync::atomic::AtomicBool` and `std::sync::atomic::AtomicPtr` are leaner and +faster. + +### Known problems +This lint cannot detect if the mutex is actually used +for waiting before a critical section. + +### Example +``` +let x = Mutex::new(&y); +``` + +Use instead: +``` +let x = AtomicBool::new(y); +``` \ No newline at end of file diff --git a/src/docs/mutex_integer.txt b/src/docs/mutex_integer.txt new file mode 100644 index 00000000000..f9dbdfb904c --- /dev/null +++ b/src/docs/mutex_integer.txt @@ -0,0 +1,22 @@ +### What it does +Checks for usages of `Mutex` where `X` is an integral +type. + +### Why is this bad? +Using a mutex just to make access to a plain integer +sequential is +shooting flies with cannons. `std::sync::atomic::AtomicUsize` is leaner and faster. + +### Known problems +This lint cannot detect if the mutex is actually used +for waiting before a critical section. + +### Example +``` +let x = Mutex::new(0usize); +``` + +Use instead: +``` +let x = AtomicUsize::new(0usize); +``` \ No newline at end of file diff --git a/src/docs/naive_bytecount.txt b/src/docs/naive_bytecount.txt new file mode 100644 index 00000000000..24659dc79ae --- /dev/null +++ b/src/docs/naive_bytecount.txt @@ -0,0 +1,22 @@ +### What it does +Checks for naive byte counts + +### Why is this bad? +The [`bytecount`](https://crates.io/crates/bytecount) +crate has methods to count your bytes faster, especially for large slices. + +### Known problems +If you have predominantly small slices, the +`bytecount::count(..)` method may actually be slower. However, if you can +ensure that less than 2³²-1 matches arise, the `naive_count_32(..)` can be +faster in those cases. + +### Example +``` +let count = vec.iter().filter(|x| **x == 0u8).count(); +``` + +Use instead: +``` +let count = bytecount::count(&vec, 0u8); +``` \ No newline at end of file diff --git a/src/docs/needless_arbitrary_self_type.txt b/src/docs/needless_arbitrary_self_type.txt new file mode 100644 index 00000000000..8216a3a3fb6 --- /dev/null +++ b/src/docs/needless_arbitrary_self_type.txt @@ -0,0 +1,44 @@ +### What it does +The lint checks for `self` in fn parameters that +specify the `Self`-type explicitly +### Why is this bad? +Increases the amount and decreases the readability of code + +### Example +``` +enum ValType { + I32, + I64, + F32, + F64, +} + +impl ValType { + pub fn bytes(self: Self) -> usize { + match self { + Self::I32 | Self::F32 => 4, + Self::I64 | Self::F64 => 8, + } + } +} +``` + +Could be rewritten as + +``` +enum ValType { + I32, + I64, + F32, + F64, +} + +impl ValType { + pub fn bytes(self) -> usize { + match self { + Self::I32 | Self::F32 => 4, + Self::I64 | Self::F64 => 8, + } + } +} +``` \ No newline at end of file diff --git a/src/docs/needless_bitwise_bool.txt b/src/docs/needless_bitwise_bool.txt new file mode 100644 index 00000000000..fcd7b730aaa --- /dev/null +++ b/src/docs/needless_bitwise_bool.txt @@ -0,0 +1,22 @@ +### What it does +Checks for uses of bitwise and/or operators between booleans, where performance may be improved by using +a lazy and. + +### Why is this bad? +The bitwise operators do not support short-circuiting, so it may hinder code performance. +Additionally, boolean logic "masked" as bitwise logic is not caught by lints like `unnecessary_fold` + +### Known problems +This lint evaluates only when the right side is determined to have no side effects. At this time, that +determination is quite conservative. + +### Example +``` +let (x,y) = (true, false); +if x & !y {} // where both x and y are booleans +``` +Use instead: +``` +let (x,y) = (true, false); +if x && !y {} +``` \ No newline at end of file diff --git a/src/docs/needless_bool.txt b/src/docs/needless_bool.txt new file mode 100644 index 00000000000..b5c78871f14 --- /dev/null +++ b/src/docs/needless_bool.txt @@ -0,0 +1,26 @@ +### What it does +Checks for expressions of the form `if c { true } else { +false }` (or vice versa) and suggests using the condition directly. + +### Why is this bad? +Redundant code. + +### Known problems +Maybe false positives: Sometimes, the two branches are +painstakingly documented (which we, of course, do not detect), so they *may* +have some value. Even then, the documentation can be rewritten to match the +shorter code. + +### Example +``` +if x { + false +} else { + true +} +``` + +Use instead: +``` +!x +``` \ No newline at end of file diff --git a/src/docs/needless_borrow.txt b/src/docs/needless_borrow.txt new file mode 100644 index 00000000000..4debcf47372 --- /dev/null +++ b/src/docs/needless_borrow.txt @@ -0,0 +1,21 @@ +### What it does +Checks for address of operations (`&`) that are going to +be dereferenced immediately by the compiler. + +### Why is this bad? +Suggests that the receiver of the expression borrows +the expression. + +### Example +``` +fn fun(_a: &i32) {} + +let x: &i32 = &&&&&&5; +fun(&x); +``` + +Use instead: +``` +let x: &i32 = &5; +fun(x); +``` \ No newline at end of file diff --git a/src/docs/needless_borrowed_reference.txt b/src/docs/needless_borrowed_reference.txt new file mode 100644 index 00000000000..55faa0cf571 --- /dev/null +++ b/src/docs/needless_borrowed_reference.txt @@ -0,0 +1,30 @@ +### What it does +Checks for bindings that destructure a reference and borrow the inner +value with `&ref`. + +### Why is this bad? +This pattern has no effect in almost all cases. + +### Known problems +In some cases, `&ref` is needed to avoid a lifetime mismatch error. +Example: +``` +fn foo(a: &Option, b: &Option) { + match (a, b) { + (None, &ref c) | (&ref c, None) => (), + (&Some(ref c), _) => (), + }; +} +``` + +### Example +``` +let mut v = Vec::::new(); +v.iter_mut().filter(|&ref a| a.is_empty()); +``` + +Use instead: +``` +let mut v = Vec::::new(); +v.iter_mut().filter(|a| a.is_empty()); +``` \ No newline at end of file diff --git a/src/docs/needless_collect.txt b/src/docs/needless_collect.txt new file mode 100644 index 00000000000..275c39afc9d --- /dev/null +++ b/src/docs/needless_collect.txt @@ -0,0 +1,14 @@ +### What it does +Checks for functions collecting an iterator when collect +is not needed. + +### Why is this bad? +`collect` causes the allocation of a new data structure, +when this allocation may not be needed. + +### Example +``` +let len = iterator.clone().collect::>().len(); +// should be +let len = iterator.count(); +``` \ No newline at end of file diff --git a/src/docs/needless_continue.txt b/src/docs/needless_continue.txt new file mode 100644 index 00000000000..2cee621c1af --- /dev/null +++ b/src/docs/needless_continue.txt @@ -0,0 +1,61 @@ +### What it does +The lint checks for `if`-statements appearing in loops +that contain a `continue` statement in either their main blocks or their +`else`-blocks, when omitting the `else`-block possibly with some +rearrangement of code can make the code easier to understand. + +### Why is this bad? +Having explicit `else` blocks for `if` statements +containing `continue` in their THEN branch adds unnecessary branching and +nesting to the code. Having an else block containing just `continue` can +also be better written by grouping the statements following the whole `if` +statement within the THEN block and omitting the else block completely. + +### Example +``` +while condition() { + update_condition(); + if x { + // ... + } else { + continue; + } + println!("Hello, world"); +} +``` + +Could be rewritten as + +``` +while condition() { + update_condition(); + if x { + // ... + println!("Hello, world"); + } +} +``` + +As another example, the following code + +``` +loop { + if waiting() { + continue; + } else { + // Do something useful + } + # break; +} +``` +Could be rewritten as + +``` +loop { + if waiting() { + continue; + } + // Do something useful + # break; +} +``` \ No newline at end of file diff --git a/src/docs/needless_doctest_main.txt b/src/docs/needless_doctest_main.txt new file mode 100644 index 00000000000..8f91a7baa71 --- /dev/null +++ b/src/docs/needless_doctest_main.txt @@ -0,0 +1,22 @@ +### What it does +Checks for `fn main() { .. }` in doctests + +### Why is this bad? +The test can be shorter (and likely more readable) +if the `fn main()` is left implicit. + +### Examples +``` +/// An example of a doctest with a `main()` function +/// +/// # Examples +/// +/// ``` +/// fn main() { +/// // this needs not be in an `fn` +/// } +/// ``` +fn needless_main() { + unimplemented!(); +} +``` \ No newline at end of file diff --git a/src/docs/needless_for_each.txt b/src/docs/needless_for_each.txt new file mode 100644 index 00000000000..9ae6dd360c8 --- /dev/null +++ b/src/docs/needless_for_each.txt @@ -0,0 +1,24 @@ +### What it does +Checks for usage of `for_each` that would be more simply written as a +`for` loop. + +### Why is this bad? +`for_each` may be used after applying iterator transformers like +`filter` for better readability and performance. It may also be used to fit a simple +operation on one line. +But when none of these apply, a simple `for` loop is more idiomatic. + +### Example +``` +let v = vec![0, 1, 2]; +v.iter().for_each(|elem| { + println!("{}", elem); +}) +``` +Use instead: +``` +let v = vec![0, 1, 2]; +for elem in v.iter() { + println!("{}", elem); +} +``` \ No newline at end of file diff --git a/src/docs/needless_late_init.txt b/src/docs/needless_late_init.txt new file mode 100644 index 00000000000..9e7bbcea998 --- /dev/null +++ b/src/docs/needless_late_init.txt @@ -0,0 +1,42 @@ +### What it does +Checks for late initializations that can be replaced by a `let` statement +with an initializer. + +### Why is this bad? +Assigning in the `let` statement is less repetitive. + +### Example +``` +let a; +a = 1; + +let b; +match 3 { + 0 => b = "zero", + 1 => b = "one", + _ => b = "many", +} + +let c; +if true { + c = 1; +} else { + c = -1; +} +``` +Use instead: +``` +let a = 1; + +let b = match 3 { + 0 => "zero", + 1 => "one", + _ => "many", +}; + +let c = if true { + 1 +} else { + -1 +}; +``` \ No newline at end of file diff --git a/src/docs/needless_lifetimes.txt b/src/docs/needless_lifetimes.txt new file mode 100644 index 00000000000..b280caa66b5 --- /dev/null +++ b/src/docs/needless_lifetimes.txt @@ -0,0 +1,29 @@ +### What it does +Checks for lifetime annotations which can be removed by +relying on lifetime elision. + +### Why is this bad? +The additional lifetimes make the code look more +complicated, while there is nothing out of the ordinary going on. Removing +them leads to more readable code. + +### Known problems +- We bail out if the function has a `where` clause where lifetimes +are mentioned due to potential false positives. +- Lifetime bounds such as `impl Foo + 'a` and `T: 'a` must be elided with the +placeholder notation `'_` because the fully elided notation leaves the type bound to `'static`. + +### Example +``` +// Unnecessary lifetime annotations +fn in_and_out<'a>(x: &'a u8, y: u8) -> &'a u8 { + x +} +``` + +Use instead: +``` +fn elided(x: &u8, y: u8) -> &u8 { + x +} +``` \ No newline at end of file diff --git a/src/docs/needless_match.txt b/src/docs/needless_match.txt new file mode 100644 index 00000000000..92b40a5df64 --- /dev/null +++ b/src/docs/needless_match.txt @@ -0,0 +1,36 @@ +### What it does +Checks for unnecessary `match` or match-like `if let` returns for `Option` and `Result` +when function signatures are the same. + +### Why is this bad? +This `match` block does nothing and might not be what the coder intended. + +### Example +``` +fn foo() -> Result<(), i32> { + match result { + Ok(val) => Ok(val), + Err(err) => Err(err), + } +} + +fn bar() -> Option { + if let Some(val) = option { + Some(val) + } else { + None + } +} +``` + +Could be replaced as + +``` +fn foo() -> Result<(), i32> { + result +} + +fn bar() -> Option { + option +} +``` \ No newline at end of file diff --git a/src/docs/needless_option_as_deref.txt b/src/docs/needless_option_as_deref.txt new file mode 100644 index 00000000000..226396c97ac --- /dev/null +++ b/src/docs/needless_option_as_deref.txt @@ -0,0 +1,18 @@ +### What it does +Checks for no-op uses of `Option::{as_deref, as_deref_mut}`, +for example, `Option<&T>::as_deref()` returns the same type. + +### Why is this bad? +Redundant code and improving readability. + +### Example +``` +let a = Some(&1); +let b = a.as_deref(); // goes from Option<&i32> to Option<&i32> +``` + +Use instead: +``` +let a = Some(&1); +let b = a; +``` \ No newline at end of file diff --git a/src/docs/needless_option_take.txt b/src/docs/needless_option_take.txt new file mode 100644 index 00000000000..6bac65a13b5 --- /dev/null +++ b/src/docs/needless_option_take.txt @@ -0,0 +1,17 @@ +### What it does +Checks for calling `take` function after `as_ref`. + +### Why is this bad? +Redundant code. `take` writes `None` to its argument. +In this case the modification is useless as it's a temporary that cannot be read from afterwards. + +### Example +``` +let x = Some(3); +x.as_ref().take(); +``` +Use instead: +``` +let x = Some(3); +x.as_ref(); +``` \ No newline at end of file diff --git a/src/docs/needless_parens_on_range_literals.txt b/src/docs/needless_parens_on_range_literals.txt new file mode 100644 index 00000000000..85fab10cb5f --- /dev/null +++ b/src/docs/needless_parens_on_range_literals.txt @@ -0,0 +1,23 @@ +### What it does +The lint checks for parenthesis on literals in range statements that are +superfluous. + +### Why is this bad? +Having superfluous parenthesis makes the code less readable +overhead when reading. + +### Example + +``` +for i in (0)..10 { + println!("{i}"); +} +``` + +Use instead: + +``` +for i in 0..10 { + println!("{i}"); +} +``` \ No newline at end of file diff --git a/src/docs/needless_pass_by_value.txt b/src/docs/needless_pass_by_value.txt new file mode 100644 index 00000000000..58c420b19f6 --- /dev/null +++ b/src/docs/needless_pass_by_value.txt @@ -0,0 +1,27 @@ +### What it does +Checks for functions taking arguments by value, but not +consuming them in its +body. + +### Why is this bad? +Taking arguments by reference is more flexible and can +sometimes avoid +unnecessary allocations. + +### Known problems +* This lint suggests taking an argument by reference, +however sometimes it is better to let users decide the argument type +(by using `Borrow` trait, for example), depending on how the function is used. + +### Example +``` +fn foo(v: Vec) { + assert_eq!(v.len(), 42); +} +``` +should be +``` +fn foo(v: &[i32]) { + assert_eq!(v.len(), 42); +} +``` \ No newline at end of file diff --git a/src/docs/needless_question_mark.txt b/src/docs/needless_question_mark.txt new file mode 100644 index 00000000000..540739fd45f --- /dev/null +++ b/src/docs/needless_question_mark.txt @@ -0,0 +1,43 @@ +### What it does +Suggests alternatives for useless applications of `?` in terminating expressions + +### Why is this bad? +There's no reason to use `?` to short-circuit when execution of the body will end there anyway. + +### Example +``` +struct TO { + magic: Option, +} + +fn f(to: TO) -> Option { + Some(to.magic?) +} + +struct TR { + magic: Result, +} + +fn g(tr: Result) -> Result { + tr.and_then(|t| Ok(t.magic?)) +} + +``` +Use instead: +``` +struct TO { + magic: Option, +} + +fn f(to: TO) -> Option { + to.magic +} + +struct TR { + magic: Result, +} + +fn g(tr: Result) -> Result { + tr.and_then(|t| t.magic) +} +``` \ No newline at end of file diff --git a/src/docs/needless_range_loop.txt b/src/docs/needless_range_loop.txt new file mode 100644 index 00000000000..583c09b2849 --- /dev/null +++ b/src/docs/needless_range_loop.txt @@ -0,0 +1,23 @@ +### What it does +Checks for looping over the range of `0..len` of some +collection just to get the values by index. + +### Why is this bad? +Just iterating the collection itself makes the intent +more clear and is probably faster. + +### Example +``` +let vec = vec!['a', 'b', 'c']; +for i in 0..vec.len() { + println!("{}", vec[i]); +} +``` + +Use instead: +``` +let vec = vec!['a', 'b', 'c']; +for i in vec { + println!("{}", i); +} +``` \ No newline at end of file diff --git a/src/docs/needless_return.txt b/src/docs/needless_return.txt new file mode 100644 index 00000000000..48782cb0ca8 --- /dev/null +++ b/src/docs/needless_return.txt @@ -0,0 +1,19 @@ +### What it does +Checks for return statements at the end of a block. + +### Why is this bad? +Removing the `return` and semicolon will make the code +more rusty. + +### Example +``` +fn foo(x: usize) -> usize { + return x; +} +``` +simplify to +``` +fn foo(x: usize) -> usize { + x +} +``` \ No newline at end of file diff --git a/src/docs/needless_splitn.txt b/src/docs/needless_splitn.txt new file mode 100644 index 00000000000..b10a84fbc42 --- /dev/null +++ b/src/docs/needless_splitn.txt @@ -0,0 +1,16 @@ +### What it does +Checks for usages of `str::splitn` (or `str::rsplitn`) where using `str::split` would be the same. +### Why is this bad? +The function `split` is simpler and there is no performance difference in these cases, considering +that both functions return a lazy iterator. +### Example +``` +let str = "key=value=add"; +let _ = str.splitn(3, '=').next().unwrap(); +``` + +Use instead: +``` +let str = "key=value=add"; +let _ = str.split('=').next().unwrap(); +``` \ No newline at end of file diff --git a/src/docs/needless_update.txt b/src/docs/needless_update.txt new file mode 100644 index 00000000000..82adabf6482 --- /dev/null +++ b/src/docs/needless_update.txt @@ -0,0 +1,30 @@ +### What it does +Checks for needlessly including a base struct on update +when all fields are changed anyway. + +This lint is not applied to structs marked with +[non_exhaustive](https://doc.rust-lang.org/reference/attributes/type_system.html). + +### Why is this bad? +This will cost resources (because the base has to be +somewhere), and make the code less readable. + +### Example +``` +Point { + x: 1, + y: 1, + z: 1, + ..zero_point +}; +``` + +Use instead: +``` +// Missing field `z` +Point { + x: 1, + y: 1, + ..zero_point +}; +``` \ No newline at end of file diff --git a/src/docs/neg_cmp_op_on_partial_ord.txt b/src/docs/neg_cmp_op_on_partial_ord.txt new file mode 100644 index 00000000000..fa55c6cfd74 --- /dev/null +++ b/src/docs/neg_cmp_op_on_partial_ord.txt @@ -0,0 +1,26 @@ +### What it does +Checks for the usage of negated comparison operators on types which only implement +`PartialOrd` (e.g., `f64`). + +### Why is this bad? +These operators make it easy to forget that the underlying types actually allow not only three +potential Orderings (Less, Equal, Greater) but also a fourth one (Uncomparable). This is +especially easy to miss if the operator based comparison result is negated. + +### Example +``` +let a = 1.0; +let b = f64::NAN; + +let not_less_or_equal = !(a <= b); +``` + +Use instead: +``` +use std::cmp::Ordering; + +let _not_less_or_equal = match a.partial_cmp(&b) { + None | Some(Ordering::Greater) => true, + _ => false, +}; +``` \ No newline at end of file diff --git a/src/docs/neg_multiply.txt b/src/docs/neg_multiply.txt new file mode 100644 index 00000000000..4e8b096eb9c --- /dev/null +++ b/src/docs/neg_multiply.txt @@ -0,0 +1,18 @@ +### What it does +Checks for multiplication by -1 as a form of negation. + +### Why is this bad? +It's more readable to just negate. + +### Known problems +This only catches integers (for now). + +### Example +``` +let a = x * -1; +``` + +Use instead: +``` +let a = -x; +``` \ No newline at end of file diff --git a/src/docs/negative_feature_names.txt b/src/docs/negative_feature_names.txt new file mode 100644 index 00000000000..01ee9efb318 --- /dev/null +++ b/src/docs/negative_feature_names.txt @@ -0,0 +1,22 @@ +### What it does +Checks for negative feature names with prefix `no-` or `not-` + +### Why is this bad? +Features are supposed to be additive, and negatively-named features violate it. + +### Example +``` +[features] +default = [] +no-abc = [] +not-def = [] + +``` +Use instead: +``` +[features] +default = ["abc", "def"] +abc = [] +def = [] + +``` \ No newline at end of file diff --git a/src/docs/never_loop.txt b/src/docs/never_loop.txt new file mode 100644 index 00000000000..737ccf415cb --- /dev/null +++ b/src/docs/never_loop.txt @@ -0,0 +1,15 @@ +### What it does +Checks for loops that will always `break`, `return` or +`continue` an outer loop. + +### Why is this bad? +This loop never loops, all it does is obfuscating the +code. + +### Example +``` +loop { + ..; + break; +} +``` \ No newline at end of file diff --git a/src/docs/new_ret_no_self.txt b/src/docs/new_ret_no_self.txt new file mode 100644 index 00000000000..291bad24a64 --- /dev/null +++ b/src/docs/new_ret_no_self.txt @@ -0,0 +1,47 @@ +### What it does +Checks for `new` not returning a type that contains `Self`. + +### Why is this bad? +As a convention, `new` methods are used to make a new +instance of a type. + +### Example +In an impl block: +``` +impl Foo { + fn new() -> NotAFoo { + } +} +``` + +``` +struct Bar(Foo); +impl Foo { + // Bad. The type name must contain `Self` + fn new() -> Bar { + } +} +``` + +``` +impl Foo { + // Good. Return type contains `Self` + fn new() -> Result { + } +} +``` + +Or in a trait definition: +``` +pub trait Trait { + // Bad. The type name must contain `Self` + fn new(); +} +``` + +``` +pub trait Trait { + // Good. Return type contains `Self` + fn new() -> Self; +} +``` \ No newline at end of file diff --git a/src/docs/new_without_default.txt b/src/docs/new_without_default.txt new file mode 100644 index 00000000000..662d39c8efd --- /dev/null +++ b/src/docs/new_without_default.txt @@ -0,0 +1,32 @@ +### What it does +Checks for public types with a `pub fn new() -> Self` method and no +implementation of +[`Default`](https://doc.rust-lang.org/std/default/trait.Default.html). + +### Why is this bad? +The user might expect to be able to use +[`Default`](https://doc.rust-lang.org/std/default/trait.Default.html) as the +type can be constructed without arguments. + +### Example +``` +pub struct Foo(Bar); + +impl Foo { + pub fn new() -> Self { + Foo(Bar::new()) + } +} +``` + +To fix the lint, add a `Default` implementation that delegates to `new`: + +``` +pub struct Foo(Bar); + +impl Default for Foo { + fn default() -> Self { + Foo::new() + } +} +``` \ No newline at end of file diff --git a/src/docs/no_effect.txt b/src/docs/no_effect.txt new file mode 100644 index 00000000000..d4cc08fa8a7 --- /dev/null +++ b/src/docs/no_effect.txt @@ -0,0 +1,12 @@ +### What it does +Checks for statements which have no effect. + +### Why is this bad? +Unlike dead code, these statements are actually +executed. However, as they have no effect, all they do is make the code less +readable. + +### Example +``` +0; +``` \ No newline at end of file diff --git a/src/docs/no_effect_replace.txt b/src/docs/no_effect_replace.txt new file mode 100644 index 00000000000..646d45287ef --- /dev/null +++ b/src/docs/no_effect_replace.txt @@ -0,0 +1,11 @@ +### What it does +Checks for `replace` statements which have no effect. + +### Why is this bad? +It's either a mistake or confusing. + +### Example +``` +"1234".replace("12", "12"); +"1234".replacen("12", "12", 1); +``` \ No newline at end of file diff --git a/src/docs/no_effect_underscore_binding.txt b/src/docs/no_effect_underscore_binding.txt new file mode 100644 index 00000000000..972f60dd01e --- /dev/null +++ b/src/docs/no_effect_underscore_binding.txt @@ -0,0 +1,16 @@ +### What it does +Checks for binding to underscore prefixed variable without side-effects. + +### Why is this bad? +Unlike dead code, these bindings are actually +executed. However, as they have no effect and shouldn't be used further on, all they +do is make the code less readable. + +### Known problems +Further usage of this variable is not checked, which can lead to false positives if it is +used later in the code. + +### Example +``` +let _i_serve_no_purpose = 1; +``` \ No newline at end of file diff --git a/src/docs/non_ascii_literal.txt b/src/docs/non_ascii_literal.txt new file mode 100644 index 00000000000..164902b4726 --- /dev/null +++ b/src/docs/non_ascii_literal.txt @@ -0,0 +1,19 @@ +### What it does +Checks for non-ASCII characters in string and char literals. + +### Why is this bad? +Yeah, we know, the 90's called and wanted their charset +back. Even so, there still are editors and other programs out there that +don't work well with Unicode. So if the code is meant to be used +internationally, on multiple operating systems, or has other portability +requirements, activating this lint could be useful. + +### Example +``` +let x = String::from("€"); +``` + +Use instead: +``` +let x = String::from("\u{20ac}"); +``` \ No newline at end of file diff --git a/src/docs/non_octal_unix_permissions.txt b/src/docs/non_octal_unix_permissions.txt new file mode 100644 index 00000000000..4a468e94db1 --- /dev/null +++ b/src/docs/non_octal_unix_permissions.txt @@ -0,0 +1,23 @@ +### What it does +Checks for non-octal values used to set Unix file permissions. + +### Why is this bad? +They will be converted into octal, creating potentially +unintended file permissions. + +### Example +``` +use std::fs::OpenOptions; +use std::os::unix::fs::OpenOptionsExt; + +let mut options = OpenOptions::new(); +options.mode(644); +``` +Use instead: +``` +use std::fs::OpenOptions; +use std::os::unix::fs::OpenOptionsExt; + +let mut options = OpenOptions::new(); +options.mode(0o644); +``` \ No newline at end of file diff --git a/src/docs/non_send_fields_in_send_ty.txt b/src/docs/non_send_fields_in_send_ty.txt new file mode 100644 index 00000000000..11e6f6e162c --- /dev/null +++ b/src/docs/non_send_fields_in_send_ty.txt @@ -0,0 +1,36 @@ +### What it does +This lint warns about a `Send` implementation for a type that +contains fields that are not safe to be sent across threads. +It tries to detect fields that can cause a soundness issue +when sent to another thread (e.g., `Rc`) while allowing `!Send` fields +that are expected to exist in a `Send` type, such as raw pointers. + +### Why is this bad? +Sending the struct to another thread effectively sends all of its fields, +and the fields that do not implement `Send` can lead to soundness bugs +such as data races when accessed in a thread +that is different from the thread that created it. + +See: +* [*The Rustonomicon* about *Send and Sync*](https://doc.rust-lang.org/nomicon/send-and-sync.html) +* [The documentation of `Send`](https://doc.rust-lang.org/std/marker/trait.Send.html) + +### Known Problems +This lint relies on heuristics to distinguish types that are actually +unsafe to be sent across threads and `!Send` types that are expected to +exist in `Send` type. Its rule can filter out basic cases such as +`Vec<*const T>`, but it's not perfect. Feel free to create an issue if +you have a suggestion on how this heuristic can be improved. + +### Example +``` +struct ExampleStruct { + rc_is_not_send: Rc, + unbounded_generic_field: T, +} + +// This impl is unsound because it allows sending `!Send` types through `ExampleStruct` +unsafe impl Send for ExampleStruct {} +``` +Use thread-safe types like [`std::sync::Arc`](https://doc.rust-lang.org/std/sync/struct.Arc.html) +or specify correct bounds on generic type parameters (`T: Send`). \ No newline at end of file diff --git a/src/docs/nonminimal_bool.txt b/src/docs/nonminimal_bool.txt new file mode 100644 index 00000000000..488980ddf02 --- /dev/null +++ b/src/docs/nonminimal_bool.txt @@ -0,0 +1,23 @@ +### What it does +Checks for boolean expressions that can be written more +concisely. + +### Why is this bad? +Readability of boolean expressions suffers from +unnecessary duplication. + +### Known problems +Ignores short circuiting behavior of `||` and +`&&`. Ignores `|`, `&` and `^`. + +### Example +``` +if a && true {} +if !(a == b) {} +``` + +Use instead: +``` +if a {} +if a != b {} +``` \ No newline at end of file diff --git a/src/docs/nonsensical_open_options.txt b/src/docs/nonsensical_open_options.txt new file mode 100644 index 00000000000..7a95443b51a --- /dev/null +++ b/src/docs/nonsensical_open_options.txt @@ -0,0 +1,14 @@ +### What it does +Checks for duplicate open options as well as combinations +that make no sense. + +### Why is this bad? +In the best case, the code will be harder to read than +necessary. I don't know the worst case. + +### Example +``` +use std::fs::OpenOptions; + +OpenOptions::new().read(true).truncate(true); +``` \ No newline at end of file diff --git a/src/docs/nonstandard_macro_braces.txt b/src/docs/nonstandard_macro_braces.txt new file mode 100644 index 00000000000..7e8d0d2d33b --- /dev/null +++ b/src/docs/nonstandard_macro_braces.txt @@ -0,0 +1,15 @@ +### What it does +Checks that common macros are used with consistent bracing. + +### Why is this bad? +This is mostly a consistency lint although using () or [] +doesn't give you a semicolon in item position, which can be unexpected. + +### Example +``` +vec!{1, 2, 3}; +``` +Use instead: +``` +vec![1, 2, 3]; +``` \ No newline at end of file diff --git a/src/docs/not_unsafe_ptr_arg_deref.txt b/src/docs/not_unsafe_ptr_arg_deref.txt new file mode 100644 index 00000000000..31355fbb7b6 --- /dev/null +++ b/src/docs/not_unsafe_ptr_arg_deref.txt @@ -0,0 +1,30 @@ +### What it does +Checks for public functions that dereference raw pointer +arguments but are not marked `unsafe`. + +### Why is this bad? +The function should probably be marked `unsafe`, since +for an arbitrary raw pointer, there is no way of telling for sure if it is +valid. + +### Known problems +* It does not check functions recursively so if the pointer is passed to a +private non-`unsafe` function which does the dereferencing, the lint won't +trigger. +* It only checks for arguments whose type are raw pointers, not raw pointers +got from an argument in some other way (`fn foo(bar: &[*const u8])` or +`some_argument.get_raw_ptr()`). + +### Example +``` +pub fn foo(x: *const u8) { + println!("{}", unsafe { *x }); +} +``` + +Use instead: +``` +pub unsafe fn foo(x: *const u8) { + println!("{}", unsafe { *x }); +} +``` \ No newline at end of file diff --git a/src/docs/obfuscated_if_else.txt b/src/docs/obfuscated_if_else.txt new file mode 100644 index 00000000000..638f63b0db5 --- /dev/null +++ b/src/docs/obfuscated_if_else.txt @@ -0,0 +1,21 @@ +### What it does +Checks for usages of `.then_some(..).unwrap_or(..)` + +### Why is this bad? +This can be written more clearly with `if .. else ..` + +### Limitations +This lint currently only looks for usages of +`.then_some(..).unwrap_or(..)`, but will be expanded +to account for similar patterns. + +### Example +``` +let x = true; +x.then_some("a").unwrap_or("b"); +``` +Use instead: +``` +let x = true; +if x { "a" } else { "b" }; +``` \ No newline at end of file diff --git a/src/docs/octal_escapes.txt b/src/docs/octal_escapes.txt new file mode 100644 index 00000000000..eee82058715 --- /dev/null +++ b/src/docs/octal_escapes.txt @@ -0,0 +1,33 @@ +### What it does +Checks for `\0` escapes in string and byte literals that look like octal +character escapes in C. + +### Why is this bad? + +C and other languages support octal character escapes in strings, where +a backslash is followed by up to three octal digits. For example, `\033` +stands for the ASCII character 27 (ESC). Rust does not support this +notation, but has the escape code `\0` which stands for a null +byte/character, and any following digits do not form part of the escape +sequence. Therefore, `\033` is not a compiler error but the result may +be surprising. + +### Known problems +The actual meaning can be the intended one. `\x00` can be used in these +cases to be unambiguous. + +The lint does not trigger for format strings in `print!()`, `write!()` +and friends since the string is already preprocessed when Clippy lints +can see it. + +### Example +``` +let one = "\033[1m Bold? \033[0m"; // \033 intended as escape +let two = "\033\0"; // \033 intended as null-3-3 +``` + +Use instead: +``` +let one = "\x1b[1mWill this be bold?\x1b[0m"; +let two = "\x0033\x00"; +``` \ No newline at end of file diff --git a/src/docs/ok_expect.txt b/src/docs/ok_expect.txt new file mode 100644 index 00000000000..fd5205d49dc --- /dev/null +++ b/src/docs/ok_expect.txt @@ -0,0 +1,19 @@ +### What it does +Checks for usage of `ok().expect(..)`. + +### Why is this bad? +Because you usually call `expect()` on the `Result` +directly to get a better error message. + +### Known problems +The error type needs to implement `Debug` + +### Example +``` +x.ok().expect("why did I do this again?"); +``` + +Use instead: +``` +x.expect("why did I do this again?"); +``` \ No newline at end of file diff --git a/src/docs/only_used_in_recursion.txt b/src/docs/only_used_in_recursion.txt new file mode 100644 index 00000000000..f19f47ff9eb --- /dev/null +++ b/src/docs/only_used_in_recursion.txt @@ -0,0 +1,58 @@ +### What it does +Checks for arguments that are only used in recursion with no side-effects. + +### Why is this bad? +It could contain a useless calculation and can make function simpler. + +The arguments can be involved in calculations and assignments but as long as +the calculations have no side-effects (function calls or mutating dereference) +and the assigned variables are also only in recursion, it is useless. + +### Known problems +Too many code paths in the linting code are currently untested and prone to produce false +positives or are prone to have performance implications. + +In some cases, this would not catch all useless arguments. + +``` +fn foo(a: usize, b: usize) -> usize { + let f = |x| x + 1; + + if a == 0 { + 1 + } else { + foo(a - 1, f(b)) + } +} +``` + +For example, the argument `b` is only used in recursion, but the lint would not catch it. + +List of some examples that can not be caught: +- binary operation of non-primitive types +- closure usage +- some `break` relative operations +- struct pattern binding + +Also, when you recurse the function name with path segments, it is not possible to detect. + +### Example +``` +fn f(a: usize, b: usize) -> usize { + if a == 0 { + 1 + } else { + f(a - 1, b + 1) + } +} +``` +Use instead: +``` +fn f(a: usize) -> usize { + if a == 0 { + 1 + } else { + f(a - 1) + } +} +``` \ No newline at end of file diff --git a/src/docs/op_ref.txt b/src/docs/op_ref.txt new file mode 100644 index 00000000000..7a7ed1bc9ba --- /dev/null +++ b/src/docs/op_ref.txt @@ -0,0 +1,17 @@ +### What it does +Checks for arguments to `==` which have their address +taken to satisfy a bound +and suggests to dereference the other argument instead + +### Why is this bad? +It is more idiomatic to dereference the other argument. + +### Example +``` +&x == y +``` + +Use instead: +``` +x == *y +``` \ No newline at end of file diff --git a/src/docs/option_as_ref_deref.txt b/src/docs/option_as_ref_deref.txt new file mode 100644 index 00000000000..ad7411d3d4b --- /dev/null +++ b/src/docs/option_as_ref_deref.txt @@ -0,0 +1,15 @@ +### What it does +Checks for usage of `_.as_ref().map(Deref::deref)` or it's aliases (such as String::as_str). + +### Why is this bad? +Readability, this can be written more concisely as +`_.as_deref()`. + +### Example +``` +opt.as_ref().map(String::as_str) +``` +Can be written as +``` +opt.as_deref() +``` \ No newline at end of file diff --git a/src/docs/option_env_unwrap.txt b/src/docs/option_env_unwrap.txt new file mode 100644 index 00000000000..c952cba8e26 --- /dev/null +++ b/src/docs/option_env_unwrap.txt @@ -0,0 +1,19 @@ +### What it does +Checks for usage of `option_env!(...).unwrap()` and +suggests usage of the `env!` macro. + +### Why is this bad? +Unwrapping the result of `option_env!` will panic +at run-time if the environment variable doesn't exist, whereas `env!` +catches it at compile-time. + +### Example +``` +let _ = option_env!("HOME").unwrap(); +``` + +Is better expressed as: + +``` +let _ = env!("HOME"); +``` \ No newline at end of file diff --git a/src/docs/option_filter_map.txt b/src/docs/option_filter_map.txt new file mode 100644 index 00000000000..25f7bde7b4d --- /dev/null +++ b/src/docs/option_filter_map.txt @@ -0,0 +1,15 @@ +### What it does +Checks for indirect collection of populated `Option` + +### Why is this bad? +`Option` is like a collection of 0-1 things, so `flatten` +automatically does this without suspicious-looking `unwrap` calls. + +### Example +``` +let _ = std::iter::empty::>().filter(Option::is_some).map(Option::unwrap); +``` +Use instead: +``` +let _ = std::iter::empty::>().flatten(); +``` \ No newline at end of file diff --git a/src/docs/option_if_let_else.txt b/src/docs/option_if_let_else.txt new file mode 100644 index 00000000000..43652db513b --- /dev/null +++ b/src/docs/option_if_let_else.txt @@ -0,0 +1,46 @@ +### What it does +Lints usage of `if let Some(v) = ... { y } else { x }` and +`match .. { Some(v) => y, None/_ => x }` which are more +idiomatically done with `Option::map_or` (if the else bit is a pure +expression) or `Option::map_or_else` (if the else bit is an impure +expression). + +### Why is this bad? +Using the dedicated functions of the `Option` type is clearer and +more concise than an `if let` expression. + +### Known problems +This lint uses a deliberately conservative metric for checking +if the inside of either body contains breaks or continues which will +cause it to not suggest a fix if either block contains a loop with +continues or breaks contained within the loop. + +### Example +``` +let _ = if let Some(foo) = optional { + foo +} else { + 5 +}; +let _ = match optional { + Some(val) => val + 1, + None => 5 +}; +let _ = if let Some(foo) = optional { + foo +} else { + let y = do_complicated_function(); + y*y +}; +``` + +should be + +``` +let _ = optional.map_or(5, |foo| foo); +let _ = optional.map_or(5, |val| val + 1); +let _ = optional.map_or_else(||{ + let y = do_complicated_function(); + y*y +}, |foo| foo); +``` \ No newline at end of file diff --git a/src/docs/option_map_or_none.txt b/src/docs/option_map_or_none.txt new file mode 100644 index 00000000000..c86c65215f0 --- /dev/null +++ b/src/docs/option_map_or_none.txt @@ -0,0 +1,19 @@ +### What it does +Checks for usage of `_.map_or(None, _)`. + +### Why is this bad? +Readability, this can be written more concisely as +`_.and_then(_)`. + +### Known problems +The order of the arguments is not in execution order. + +### Example +``` +opt.map_or(None, |a| Some(a + 1)); +``` + +Use instead: +``` +opt.and_then(|a| Some(a + 1)); +``` \ No newline at end of file diff --git a/src/docs/option_map_unit_fn.txt b/src/docs/option_map_unit_fn.txt new file mode 100644 index 00000000000..fc4b528f092 --- /dev/null +++ b/src/docs/option_map_unit_fn.txt @@ -0,0 +1,27 @@ +### What it does +Checks for usage of `option.map(f)` where f is a function +or closure that returns the unit type `()`. + +### Why is this bad? +Readability, this can be written more clearly with +an if let statement + +### Example +``` +let x: Option = do_stuff(); +x.map(log_err_msg); +x.map(|msg| log_err_msg(format_msg(msg))); +``` + +The correct use would be: + +``` +let x: Option = do_stuff(); +if let Some(msg) = x { + log_err_msg(msg); +} + +if let Some(msg) = x { + log_err_msg(format_msg(msg)); +} +``` \ No newline at end of file diff --git a/src/docs/option_option.txt b/src/docs/option_option.txt new file mode 100644 index 00000000000..b4324bd8399 --- /dev/null +++ b/src/docs/option_option.txt @@ -0,0 +1,32 @@ +### What it does +Checks for use of `Option>` in function signatures and type +definitions + +### Why is this bad? +`Option<_>` represents an optional value. `Option>` +represents an optional optional value which is logically the same thing as an optional +value but has an unneeded extra level of wrapping. + +If you have a case where `Some(Some(_))`, `Some(None)` and `None` are distinct cases, +consider a custom `enum` instead, with clear names for each case. + +### Example +``` +fn get_data() -> Option> { + None +} +``` + +Better: + +``` +pub enum Contents { + Data(Vec), // Was Some(Some(Vec)) + NotYetFetched, // Was Some(None) + None, // Was None +} + +fn get_data() -> Contents { + Contents::None +} +``` \ No newline at end of file diff --git a/src/docs/or_fun_call.txt b/src/docs/or_fun_call.txt new file mode 100644 index 00000000000..5605e96c98e --- /dev/null +++ b/src/docs/or_fun_call.txt @@ -0,0 +1,26 @@ +### What it does +Checks for calls to `.or(foo(..))`, `.unwrap_or(foo(..))`, +etc., and suggests to use `or_else`, `unwrap_or_else`, etc., or +`unwrap_or_default` instead. + +### Why is this bad? +The function will always be called and potentially +allocate an object acting as the default. + +### Known problems +If the function has side-effects, not calling it will +change the semantic of the program, but you shouldn't rely on that anyway. + +### Example +``` +foo.unwrap_or(String::new()); +``` + +Use instead: +``` +foo.unwrap_or_else(String::new); + +// or + +foo.unwrap_or_default(); +``` \ No newline at end of file diff --git a/src/docs/or_then_unwrap.txt b/src/docs/or_then_unwrap.txt new file mode 100644 index 00000000000..64ac53749e8 --- /dev/null +++ b/src/docs/or_then_unwrap.txt @@ -0,0 +1,22 @@ +### What it does +Checks for `.or(…).unwrap()` calls to Options and Results. + +### Why is this bad? +You should use `.unwrap_or(…)` instead for clarity. + +### Example +``` +// Result +let value = result.or::(Ok(fallback)).unwrap(); + +// Option +let value = option.or(Some(fallback)).unwrap(); +``` +Use instead: +``` +// Result +let value = result.unwrap_or(fallback); + +// Option +let value = option.unwrap_or(fallback); +``` \ No newline at end of file diff --git a/src/docs/out_of_bounds_indexing.txt b/src/docs/out_of_bounds_indexing.txt new file mode 100644 index 00000000000..5802eea2996 --- /dev/null +++ b/src/docs/out_of_bounds_indexing.txt @@ -0,0 +1,22 @@ +### What it does +Checks for out of bounds array indexing with a constant +index. + +### Why is this bad? +This will always panic at runtime. + +### Example +``` +let x = [1, 2, 3, 4]; + +x[9]; +&x[2..9]; +``` + +Use instead: +``` +// Index within bounds + +x[0]; +x[3]; +``` \ No newline at end of file diff --git a/src/docs/overflow_check_conditional.txt b/src/docs/overflow_check_conditional.txt new file mode 100644 index 00000000000..a09cc18a0bc --- /dev/null +++ b/src/docs/overflow_check_conditional.txt @@ -0,0 +1,11 @@ +### What it does +Detects classic underflow/overflow checks. + +### Why is this bad? +Most classic C underflow/overflow checks will fail in +Rust. Users can use functions like `overflowing_*` and `wrapping_*` instead. + +### Example +``` +a + b < a; +``` \ No newline at end of file diff --git a/src/docs/overly_complex_bool_expr.txt b/src/docs/overly_complex_bool_expr.txt new file mode 100644 index 00000000000..65ca18392e7 --- /dev/null +++ b/src/docs/overly_complex_bool_expr.txt @@ -0,0 +1,20 @@ +### What it does +Checks for boolean expressions that contain terminals that +can be eliminated. + +### Why is this bad? +This is most likely a logic bug. + +### Known problems +Ignores short circuiting behavior. + +### Example +``` +// The `b` is unnecessary, the expression is equivalent to `if a`. +if a && b || a { ... } +``` + +Use instead: +``` +if a {} +``` \ No newline at end of file diff --git a/src/docs/panic.txt b/src/docs/panic.txt new file mode 100644 index 00000000000..f9bdc6e87cc --- /dev/null +++ b/src/docs/panic.txt @@ -0,0 +1,10 @@ +### What it does +Checks for usage of `panic!`. + +### Why is this bad? +`panic!` will stop the execution of the executable + +### Example +``` +panic!("even with a good reason"); +``` \ No newline at end of file diff --git a/src/docs/panic_in_result_fn.txt b/src/docs/panic_in_result_fn.txt new file mode 100644 index 00000000000..51c2f8ae5a3 --- /dev/null +++ b/src/docs/panic_in_result_fn.txt @@ -0,0 +1,22 @@ +### What it does +Checks for usage of `panic!`, `unimplemented!`, `todo!`, `unreachable!` or assertions in a function of type result. + +### Why is this bad? +For some codebases, it is desirable for functions of type result to return an error instead of crashing. Hence panicking macros should be avoided. + +### Known problems +Functions called from a function returning a `Result` may invoke a panicking macro. This is not checked. + +### Example +``` +fn result_with_panic() -> Result +{ + panic!("error"); +} +``` +Use instead: +``` +fn result_without_panic() -> Result { + Err(String::from("error")) +} +``` \ No newline at end of file diff --git a/src/docs/panicking_unwrap.txt b/src/docs/panicking_unwrap.txt new file mode 100644 index 00000000000..1fbc245c8ec --- /dev/null +++ b/src/docs/panicking_unwrap.txt @@ -0,0 +1,18 @@ +### What it does +Checks for calls of `unwrap[_err]()` that will always fail. + +### Why is this bad? +If panicking is desired, an explicit `panic!()` should be used. + +### Known problems +This lint only checks `if` conditions not assignments. +So something like `let x: Option<()> = None; x.unwrap();` will not be recognized. + +### Example +``` +if option.is_none() { + do_something_with(option.unwrap()) +} +``` + +This code will always panic. The if condition should probably be inverted. \ No newline at end of file diff --git a/src/docs/partialeq_ne_impl.txt b/src/docs/partialeq_ne_impl.txt new file mode 100644 index 00000000000..78f55188bab --- /dev/null +++ b/src/docs/partialeq_ne_impl.txt @@ -0,0 +1,18 @@ +### What it does +Checks for manual re-implementations of `PartialEq::ne`. + +### Why is this bad? +`PartialEq::ne` is required to always return the +negated result of `PartialEq::eq`, which is exactly what the default +implementation does. Therefore, there should never be any need to +re-implement it. + +### Example +``` +struct Foo; + +impl PartialEq for Foo { + fn eq(&self, other: &Foo) -> bool { true } + fn ne(&self, other: &Foo) -> bool { !(self == other) } +} +``` \ No newline at end of file diff --git a/src/docs/partialeq_to_none.txt b/src/docs/partialeq_to_none.txt new file mode 100644 index 00000000000..5cc07bf8843 --- /dev/null +++ b/src/docs/partialeq_to_none.txt @@ -0,0 +1,24 @@ +### What it does + +Checks for binary comparisons to a literal `Option::None`. + +### Why is this bad? + +A programmer checking if some `foo` is `None` via a comparison `foo == None` +is usually inspired from other programming languages (e.g. `foo is None` +in Python). +Checking if a value of type `Option` is (not) equal to `None` in that +way relies on `T: PartialEq` to do the comparison, which is unneeded. + +### Example +``` +fn foo(f: Option) -> &'static str { + if f != None { "yay" } else { "nay" } +} +``` +Use instead: +``` +fn foo(f: Option) -> &'static str { + if f.is_some() { "yay" } else { "nay" } +} +``` \ No newline at end of file diff --git a/src/docs/path_buf_push_overwrite.txt b/src/docs/path_buf_push_overwrite.txt new file mode 100644 index 00000000000..34f8901da23 --- /dev/null +++ b/src/docs/path_buf_push_overwrite.txt @@ -0,0 +1,25 @@ +### What it does +* Checks for [push](https://doc.rust-lang.org/std/path/struct.PathBuf.html#method.push) +calls on `PathBuf` that can cause overwrites. + +### Why is this bad? +Calling `push` with a root path at the start can overwrite the +previous defined path. + +### Example +``` +use std::path::PathBuf; + +let mut x = PathBuf::from("/foo"); +x.push("/bar"); +assert_eq!(x, PathBuf::from("/bar")); +``` +Could be written: + +``` +use std::path::PathBuf; + +let mut x = PathBuf::from("/foo"); +x.push("bar"); +assert_eq!(x, PathBuf::from("/foo/bar")); +``` \ No newline at end of file diff --git a/src/docs/pattern_type_mismatch.txt b/src/docs/pattern_type_mismatch.txt new file mode 100644 index 00000000000..64da881d592 --- /dev/null +++ b/src/docs/pattern_type_mismatch.txt @@ -0,0 +1,64 @@ +### What it does +Checks for patterns that aren't exact representations of the types +they are applied to. + +To satisfy this lint, you will have to adjust either the expression that is matched +against or the pattern itself, as well as the bindings that are introduced by the +adjusted patterns. For matching you will have to either dereference the expression +with the `*` operator, or amend the patterns to explicitly match against `&` +or `&mut ` depending on the reference mutability. For the bindings you need +to use the inverse. You can leave them as plain bindings if you wish for the value +to be copied, but you must use `ref mut ` or `ref ` to construct +a reference into the matched structure. + +If you are looking for a way to learn about ownership semantics in more detail, it +is recommended to look at IDE options available to you to highlight types, lifetimes +and reference semantics in your code. The available tooling would expose these things +in a general way even outside of the various pattern matching mechanics. Of course +this lint can still be used to highlight areas of interest and ensure a good understanding +of ownership semantics. + +### Why is this bad? +It isn't bad in general. But in some contexts it can be desirable +because it increases ownership hints in the code, and will guard against some changes +in ownership. + +### Example +This example shows the basic adjustments necessary to satisfy the lint. Note how +the matched expression is explicitly dereferenced with `*` and the `inner` variable +is bound to a shared borrow via `ref inner`. + +``` +// Bad +let value = &Some(Box::new(23)); +match value { + Some(inner) => println!("{}", inner), + None => println!("none"), +} + +// Good +let value = &Some(Box::new(23)); +match *value { + Some(ref inner) => println!("{}", inner), + None => println!("none"), +} +``` + +The following example demonstrates one of the advantages of the more verbose style. +Note how the second version uses `ref mut a` to explicitly declare `a` a shared mutable +borrow, while `b` is simply taken by value. This ensures that the loop body cannot +accidentally modify the wrong part of the structure. + +``` +// Bad +let mut values = vec![(2, 3), (3, 4)]; +for (a, b) in &mut values { + *a += *b; +} + +// Good +let mut values = vec![(2, 3), (3, 4)]; +for &mut (ref mut a, b) in &mut values { + *a += b; +} +``` \ No newline at end of file diff --git a/src/docs/positional_named_format_parameters.txt b/src/docs/positional_named_format_parameters.txt new file mode 100644 index 00000000000..e391d240667 --- /dev/null +++ b/src/docs/positional_named_format_parameters.txt @@ -0,0 +1,15 @@ +### What it does +This lint warns when a named parameter in a format string is used as a positional one. + +### Why is this bad? +It may be confused for an assignment and obfuscates which parameter is being used. + +### Example +``` +println!("{}", x = 10); +``` + +Use instead: +``` +println!("{x}", x = 10); +``` \ No newline at end of file diff --git a/src/docs/possible_missing_comma.txt b/src/docs/possible_missing_comma.txt new file mode 100644 index 00000000000..5d92f4cae91 --- /dev/null +++ b/src/docs/possible_missing_comma.txt @@ -0,0 +1,14 @@ +### What it does +Checks for possible missing comma in an array. It lints if +an array element is a binary operator expression and it lies on two lines. + +### Why is this bad? +This could lead to unexpected results. + +### Example +``` +let a = &[ + -1, -2, -3 // <= no comma here + -4, -5, -6 +]; +``` \ No newline at end of file diff --git a/src/docs/precedence.txt b/src/docs/precedence.txt new file mode 100644 index 00000000000..fda0b831f33 --- /dev/null +++ b/src/docs/precedence.txt @@ -0,0 +1,17 @@ +### What it does +Checks for operations where precedence may be unclear +and suggests to add parentheses. Currently it catches the following: +* mixed usage of arithmetic and bit shifting/combining operators without +parentheses +* a "negative" numeric literal (which is really a unary `-` followed by a +numeric literal) + followed by a method call + +### Why is this bad? +Not everyone knows the precedence of those operators by +heart, so expressions like these may trip others trying to reason about the +code. + +### Example +* `1 << 2 + 3` equals 32, while `(1 << 2) + 3` equals 7 +* `-1i32.abs()` equals -1, while `(-1i32).abs()` equals 1 \ No newline at end of file diff --git a/src/docs/print_in_format_impl.txt b/src/docs/print_in_format_impl.txt new file mode 100644 index 00000000000..140d23d6faa --- /dev/null +++ b/src/docs/print_in_format_impl.txt @@ -0,0 +1,34 @@ +### What it does +Checks for use of `println`, `print`, `eprintln` or `eprint` in an +implementation of a formatting trait. + +### Why is this bad? +Using a print macro is likely unintentional since formatting traits +should write to the `Formatter`, not stdout/stderr. + +### Example +``` +use std::fmt::{Display, Error, Formatter}; + +struct S; +impl Display for S { + fn fmt(&self, f: &mut Formatter) -> Result<(), Error> { + println!("S"); + + Ok(()) + } +} +``` +Use instead: +``` +use std::fmt::{Display, Error, Formatter}; + +struct S; +impl Display for S { + fn fmt(&self, f: &mut Formatter) -> Result<(), Error> { + writeln!(f, "S"); + + Ok(()) + } +} +``` \ No newline at end of file diff --git a/src/docs/print_literal.txt b/src/docs/print_literal.txt new file mode 100644 index 00000000000..160073414f9 --- /dev/null +++ b/src/docs/print_literal.txt @@ -0,0 +1,20 @@ +### What it does +This lint warns about the use of literals as `print!`/`println!` args. + +### Why is this bad? +Using literals as `println!` args is inefficient +(c.f., https://github.com/matthiaskrgr/rust-str-bench) and unnecessary +(i.e., just put the literal in the format string) + +### Known problems +Will also warn with macro calls as arguments that expand to literals +-- e.g., `println!("{}", env!("FOO"))`. + +### Example +``` +println!("{}", "foo"); +``` +use the literal without formatting: +``` +println!("foo"); +``` \ No newline at end of file diff --git a/src/docs/print_stderr.txt b/src/docs/print_stderr.txt new file mode 100644 index 00000000000..fc14511cd6a --- /dev/null +++ b/src/docs/print_stderr.txt @@ -0,0 +1,21 @@ +### What it does +Checks for printing on *stderr*. The purpose of this lint +is to catch debugging remnants. + +### Why is this bad? +People often print on *stderr* while debugging an +application and might forget to remove those prints afterward. + +### Known problems +* Only catches `eprint!` and `eprintln!` calls. +* The lint level is unaffected by crate attributes. The level can still + be set for functions, modules and other items. To change the level for + the entire crate, please use command line flags. More information and a + configuration example can be found in [clippy#6610]. + +[clippy#6610]: https://github.com/rust-lang/rust-clippy/issues/6610#issuecomment-977120558 + +### Example +``` +eprintln!("Hello world!"); +``` \ No newline at end of file diff --git a/src/docs/print_stdout.txt b/src/docs/print_stdout.txt new file mode 100644 index 00000000000..6c9a4b98e1e --- /dev/null +++ b/src/docs/print_stdout.txt @@ -0,0 +1,21 @@ +### What it does +Checks for printing on *stdout*. The purpose of this lint +is to catch debugging remnants. + +### Why is this bad? +People often print on *stdout* while debugging an +application and might forget to remove those prints afterward. + +### Known problems +* Only catches `print!` and `println!` calls. +* The lint level is unaffected by crate attributes. The level can still + be set for functions, modules and other items. To change the level for + the entire crate, please use command line flags. More information and a + configuration example can be found in [clippy#6610]. + +[clippy#6610]: https://github.com/rust-lang/rust-clippy/issues/6610#issuecomment-977120558 + +### Example +``` +println!("Hello world!"); +``` \ No newline at end of file diff --git a/src/docs/print_with_newline.txt b/src/docs/print_with_newline.txt new file mode 100644 index 00000000000..640323e822d --- /dev/null +++ b/src/docs/print_with_newline.txt @@ -0,0 +1,16 @@ +### What it does +This lint warns when you use `print!()` with a format +string that ends in a newline. + +### Why is this bad? +You should use `println!()` instead, which appends the +newline. + +### Example +``` +print!("Hello {}!\n", name); +``` +use println!() instead +``` +println!("Hello {}!", name); +``` \ No newline at end of file diff --git a/src/docs/println_empty_string.txt b/src/docs/println_empty_string.txt new file mode 100644 index 00000000000..b980413022c --- /dev/null +++ b/src/docs/println_empty_string.txt @@ -0,0 +1,16 @@ +### What it does +This lint warns when you use `println!("")` to +print a newline. + +### Why is this bad? +You should use `println!()`, which is simpler. + +### Example +``` +println!(""); +``` + +Use instead: +``` +println!(); +``` \ No newline at end of file diff --git a/src/docs/ptr_arg.txt b/src/docs/ptr_arg.txt new file mode 100644 index 00000000000..796b0a65b71 --- /dev/null +++ b/src/docs/ptr_arg.txt @@ -0,0 +1,29 @@ +### What it does +This lint checks for function arguments of type `&String`, `&Vec`, +`&PathBuf`, and `Cow<_>`. It will also suggest you replace `.clone()` calls +with the appropriate `.to_owned()`/`to_string()` calls. + +### Why is this bad? +Requiring the argument to be of the specific size +makes the function less useful for no benefit; slices in the form of `&[T]` +or `&str` usually suffice and can be obtained from other types, too. + +### Known problems +There may be `fn(&Vec)`-typed references pointing to your function. +If you have them, you will get a compiler error after applying this lint's +suggestions. You then have the choice to undo your changes or change the +type of the reference. + +Note that if the function is part of your public interface, there may be +other crates referencing it, of which you may not be aware. Carefully +deprecate the function before applying the lint suggestions in this case. + +### Example +``` +fn foo(&Vec) { .. } +``` + +Use instead: +``` +fn foo(&[u32]) { .. } +``` \ No newline at end of file diff --git a/src/docs/ptr_as_ptr.txt b/src/docs/ptr_as_ptr.txt new file mode 100644 index 00000000000..8fb35c4aae8 --- /dev/null +++ b/src/docs/ptr_as_ptr.txt @@ -0,0 +1,22 @@ +### What it does +Checks for `as` casts between raw pointers without changing its mutability, +namely `*const T` to `*const U` and `*mut T` to `*mut U`. + +### Why is this bad? +Though `as` casts between raw pointers is not terrible, `pointer::cast` is safer because +it cannot accidentally change the pointer's mutability nor cast the pointer to other types like `usize`. + +### Example +``` +let ptr: *const u32 = &42_u32; +let mut_ptr: *mut u32 = &mut 42_u32; +let _ = ptr as *const i32; +let _ = mut_ptr as *mut i32; +``` +Use instead: +``` +let ptr: *const u32 = &42_u32; +let mut_ptr: *mut u32 = &mut 42_u32; +let _ = ptr.cast::(); +let _ = mut_ptr.cast::(); +``` \ No newline at end of file diff --git a/src/docs/ptr_eq.txt b/src/docs/ptr_eq.txt new file mode 100644 index 00000000000..06b36ca55e6 --- /dev/null +++ b/src/docs/ptr_eq.txt @@ -0,0 +1,22 @@ +### What it does +Use `std::ptr::eq` when applicable + +### Why is this bad? +`ptr::eq` can be used to compare `&T` references +(which coerce to `*const T` implicitly) by their address rather than +comparing the values they point to. + +### Example +``` +let a = &[1, 2, 3]; +let b = &[1, 2, 3]; + +assert!(a as *const _ as usize == b as *const _ as usize); +``` +Use instead: +``` +let a = &[1, 2, 3]; +let b = &[1, 2, 3]; + +assert!(std::ptr::eq(a, b)); +``` \ No newline at end of file diff --git a/src/docs/ptr_offset_with_cast.txt b/src/docs/ptr_offset_with_cast.txt new file mode 100644 index 00000000000..f204e769bf4 --- /dev/null +++ b/src/docs/ptr_offset_with_cast.txt @@ -0,0 +1,30 @@ +### What it does +Checks for usage of the `offset` pointer method with a `usize` casted to an +`isize`. + +### Why is this bad? +If we’re always increasing the pointer address, we can avoid the numeric +cast by using the `add` method instead. + +### Example +``` +let vec = vec![b'a', b'b', b'c']; +let ptr = vec.as_ptr(); +let offset = 1_usize; + +unsafe { + ptr.offset(offset as isize); +} +``` + +Could be written: + +``` +let vec = vec![b'a', b'b', b'c']; +let ptr = vec.as_ptr(); +let offset = 1_usize; + +unsafe { + ptr.add(offset); +} +``` \ No newline at end of file diff --git a/src/docs/pub_use.txt b/src/docs/pub_use.txt new file mode 100644 index 00000000000..407cafa0190 --- /dev/null +++ b/src/docs/pub_use.txt @@ -0,0 +1,28 @@ +### What it does + +Restricts the usage of `pub use ...` + +### Why is this bad? + +`pub use` is usually fine, but a project may wish to limit `pub use` instances to prevent +unintentional exports or to encourage placing exported items directly in public modules + +### Example +``` +pub mod outer { + mod inner { + pub struct Test {} + } + pub use inner::Test; +} + +use outer::Test; +``` +Use instead: +``` +pub mod outer { + pub struct Test {} +} + +use outer::Test; +``` \ No newline at end of file diff --git a/src/docs/question_mark.txt b/src/docs/question_mark.txt new file mode 100644 index 00000000000..4dc987be881 --- /dev/null +++ b/src/docs/question_mark.txt @@ -0,0 +1,18 @@ +### What it does +Checks for expressions that could be replaced by the question mark operator. + +### Why is this bad? +Question mark usage is more idiomatic. + +### Example +``` +if option.is_none() { + return None; +} +``` + +Could be written: + +``` +option?; +``` \ No newline at end of file diff --git a/src/docs/range_minus_one.txt b/src/docs/range_minus_one.txt new file mode 100644 index 00000000000..fcb96dcc34e --- /dev/null +++ b/src/docs/range_minus_one.txt @@ -0,0 +1,27 @@ +### What it does +Checks for inclusive ranges where 1 is subtracted from +the upper bound, e.g., `x..=(y-1)`. + +### Why is this bad? +The code is more readable with an exclusive range +like `x..y`. + +### Known problems +This will cause a warning that cannot be fixed if +the consumer of the range only accepts a specific range type, instead of +the generic `RangeBounds` trait +([#3307](https://github.com/rust-lang/rust-clippy/issues/3307)). + +### Example +``` +for i in x..=(y-1) { + // .. +} +``` + +Use instead: +``` +for i in x..y { + // .. +} +``` \ No newline at end of file diff --git a/src/docs/range_plus_one.txt b/src/docs/range_plus_one.txt new file mode 100644 index 00000000000..193c85f9cbc --- /dev/null +++ b/src/docs/range_plus_one.txt @@ -0,0 +1,36 @@ +### What it does +Checks for exclusive ranges where 1 is added to the +upper bound, e.g., `x..(y+1)`. + +### Why is this bad? +The code is more readable with an inclusive range +like `x..=y`. + +### Known problems +Will add unnecessary pair of parentheses when the +expression is not wrapped in a pair but starts with an opening parenthesis +and ends with a closing one. +I.e., `let _ = (f()+1)..(f()+1)` results in `let _ = ((f()+1)..=f())`. + +Also in many cases, inclusive ranges are still slower to run than +exclusive ranges, because they essentially add an extra branch that +LLVM may fail to hoist out of the loop. + +This will cause a warning that cannot be fixed if the consumer of the +range only accepts a specific range type, instead of the generic +`RangeBounds` trait +([#3307](https://github.com/rust-lang/rust-clippy/issues/3307)). + +### Example +``` +for i in x..(y+1) { + // .. +} +``` + +Use instead: +``` +for i in x..=y { + // .. +} +``` \ No newline at end of file diff --git a/src/docs/range_zip_with_len.txt b/src/docs/range_zip_with_len.txt new file mode 100644 index 00000000000..24c1efec789 --- /dev/null +++ b/src/docs/range_zip_with_len.txt @@ -0,0 +1,16 @@ +### What it does +Checks for zipping a collection with the range of +`0.._.len()`. + +### Why is this bad? +The code is better expressed with `.enumerate()`. + +### Example +``` +let _ = x.iter().zip(0..x.len()); +``` + +Use instead: +``` +let _ = x.iter().enumerate(); +``` \ No newline at end of file diff --git a/src/docs/rc_buffer.txt b/src/docs/rc_buffer.txt new file mode 100644 index 00000000000..82ac58eeb30 --- /dev/null +++ b/src/docs/rc_buffer.txt @@ -0,0 +1,27 @@ +### What it does +Checks for `Rc` and `Arc` when `T` is a mutable buffer type such as `String` or `Vec`. + +### Why is this bad? +Expressions such as `Rc` usually have no advantage over `Rc`, since +it is larger and involves an extra level of indirection, and doesn't implement `Borrow`. + +While mutating a buffer type would still be possible with `Rc::get_mut()`, it only +works if there are no additional references yet, which usually defeats the purpose of +enclosing it in a shared ownership type. Instead, additionally wrapping the inner +type with an interior mutable container (such as `RefCell` or `Mutex`) would normally +be used. + +### Known problems +This pattern can be desirable to avoid the overhead of a `RefCell` or `Mutex` for +cases where mutation only happens before there are any additional references. + +### Example +``` +fn foo(interned: Rc) { ... } +``` + +Better: + +``` +fn foo(interned: Rc) { ... } +``` \ No newline at end of file diff --git a/src/docs/rc_clone_in_vec_init.txt b/src/docs/rc_clone_in_vec_init.txt new file mode 100644 index 00000000000..6fc08aaf9ab --- /dev/null +++ b/src/docs/rc_clone_in_vec_init.txt @@ -0,0 +1,29 @@ +### What it does +Checks for reference-counted pointers (`Arc`, `Rc`, `rc::Weak`, and `sync::Weak`) +in `vec![elem; len]` + +### Why is this bad? +This will create `elem` once and clone it `len` times - doing so with `Arc`/`Rc`/`Weak` +is a bit misleading, as it will create references to the same pointer, rather +than different instances. + +### Example +``` +let v = vec![std::sync::Arc::new("some data".to_string()); 100]; +// or +let v = vec![std::rc::Rc::new("some data".to_string()); 100]; +``` +Use instead: +``` +// Initialize each value separately: +let mut data = Vec::with_capacity(100); +for _ in 0..100 { + data.push(std::rc::Rc::new("some data".to_string())); +} + +// Or if you want clones of the same reference, +// Create the reference beforehand to clarify that +// it should be cloned for each value +let data = std::rc::Rc::new("some data".to_string()); +let v = vec![data; 100]; +``` \ No newline at end of file diff --git a/src/docs/rc_mutex.txt b/src/docs/rc_mutex.txt new file mode 100644 index 00000000000..ed7a1e344d0 --- /dev/null +++ b/src/docs/rc_mutex.txt @@ -0,0 +1,26 @@ +### What it does +Checks for `Rc>`. + +### Why is this bad? +`Rc` is used in single thread and `Mutex` is used in multi thread. +Consider using `Rc>` in single thread or `Arc>` in multi thread. + +### Known problems +Sometimes combining generic types can lead to the requirement that a +type use Rc in conjunction with Mutex. We must consider those cases false positives, but +alas they are quite hard to rule out. Luckily they are also rare. + +### Example +``` +use std::rc::Rc; +use std::sync::Mutex; +fn foo(interned: Rc>) { ... } +``` + +Better: + +``` +use std::rc::Rc; +use std::cell::RefCell +fn foo(interned: Rc>) { ... } +``` \ No newline at end of file diff --git a/src/docs/read_zero_byte_vec.txt b/src/docs/read_zero_byte_vec.txt new file mode 100644 index 00000000000..cef5604e01c --- /dev/null +++ b/src/docs/read_zero_byte_vec.txt @@ -0,0 +1,30 @@ +### What it does +This lint catches reads into a zero-length `Vec`. +Especially in the case of a call to `with_capacity`, this lint warns that read +gets the number of bytes from the `Vec`'s length, not its capacity. + +### Why is this bad? +Reading zero bytes is almost certainly not the intended behavior. + +### Known problems +In theory, a very unusual read implementation could assign some semantic meaning +to zero-byte reads. But it seems exceptionally unlikely that code intending to do +a zero-byte read would allocate a `Vec` for it. + +### Example +``` +use std::io; +fn foo(mut f: F) { + let mut data = Vec::with_capacity(100); + f.read(&mut data).unwrap(); +} +``` +Use instead: +``` +use std::io; +fn foo(mut f: F) { + let mut data = Vec::with_capacity(100); + data.resize(100, 0); + f.read(&mut data).unwrap(); +} +``` \ No newline at end of file diff --git a/src/docs/recursive_format_impl.txt b/src/docs/recursive_format_impl.txt new file mode 100644 index 00000000000..32fffd84cf4 --- /dev/null +++ b/src/docs/recursive_format_impl.txt @@ -0,0 +1,32 @@ +### What it does +Checks for format trait implementations (e.g. `Display`) with a recursive call to itself +which uses `self` as a parameter. +This is typically done indirectly with the `write!` macro or with `to_string()`. + +### Why is this bad? +This will lead to infinite recursion and a stack overflow. + +### Example + +``` +use std::fmt; + +struct Structure(i32); +impl fmt::Display for Structure { + fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { + write!(f, "{}", self.to_string()) + } +} + +``` +Use instead: +``` +use std::fmt; + +struct Structure(i32); +impl fmt::Display for Structure { + fn fmt(&self, f: &mut fmt::Formatter) -> fmt::Result { + write!(f, "{}", self.0) + } +} +``` \ No newline at end of file diff --git a/src/docs/redundant_allocation.txt b/src/docs/redundant_allocation.txt new file mode 100644 index 00000000000..86bf51e8dfe --- /dev/null +++ b/src/docs/redundant_allocation.txt @@ -0,0 +1,17 @@ +### What it does +Checks for use of redundant allocations anywhere in the code. + +### Why is this bad? +Expressions such as `Rc<&T>`, `Rc>`, `Rc>`, `Rc>`, `Arc<&T>`, `Arc>`, +`Arc>`, `Arc>`, `Box<&T>`, `Box>`, `Box>`, `Box>`, add an unnecessary level of indirection. + +### Example +``` +fn foo(bar: Rc<&usize>) {} +``` + +Better: + +``` +fn foo(bar: &usize) {} +``` \ No newline at end of file diff --git a/src/docs/redundant_clone.txt b/src/docs/redundant_clone.txt new file mode 100644 index 00000000000..b29aed0b5e7 --- /dev/null +++ b/src/docs/redundant_clone.txt @@ -0,0 +1,23 @@ +### What it does +Checks for a redundant `clone()` (and its relatives) which clones an owned +value that is going to be dropped without further use. + +### Why is this bad? +It is not always possible for the compiler to eliminate useless +allocations and deallocations generated by redundant `clone()`s. + +### Known problems +False-negatives: analysis performed by this lint is conservative and limited. + +### Example +``` +{ + let x = Foo::new(); + call(x.clone()); + call(x.clone()); // this can just pass `x` +} + +["lorem", "ipsum"].join(" ").to_string(); + +Path::new("/a/b").join("c").to_path_buf(); +``` \ No newline at end of file diff --git a/src/docs/redundant_closure.txt b/src/docs/redundant_closure.txt new file mode 100644 index 00000000000..0faa9513f97 --- /dev/null +++ b/src/docs/redundant_closure.txt @@ -0,0 +1,25 @@ +### What it does +Checks for closures which just call another function where +the function can be called directly. `unsafe` functions or calls where types +get adjusted are ignored. + +### Why is this bad? +Needlessly creating a closure adds code for no benefit +and gives the optimizer more work. + +### Known problems +If creating the closure inside the closure has a side- +effect then moving the closure creation out will change when that side- +effect runs. +See [#1439](https://github.com/rust-lang/rust-clippy/issues/1439) for more details. + +### Example +``` +xs.map(|x| foo(x)) +``` + +Use instead: +``` +// where `foo(_)` is a plain function that takes the exact argument type of `x`. +xs.map(foo) +``` \ No newline at end of file diff --git a/src/docs/redundant_closure_call.txt b/src/docs/redundant_closure_call.txt new file mode 100644 index 00000000000..913d1a705e2 --- /dev/null +++ b/src/docs/redundant_closure_call.txt @@ -0,0 +1,17 @@ +### What it does +Detects closures called in the same expression where they +are defined. + +### Why is this bad? +It is unnecessarily adding to the expression's +complexity. + +### Example +``` +let a = (|| 42)(); +``` + +Use instead: +``` +let a = 42; +``` \ No newline at end of file diff --git a/src/docs/redundant_closure_for_method_calls.txt b/src/docs/redundant_closure_for_method_calls.txt new file mode 100644 index 00000000000..865510e1475 --- /dev/null +++ b/src/docs/redundant_closure_for_method_calls.txt @@ -0,0 +1,15 @@ +### What it does +Checks for closures which only invoke a method on the closure +argument and can be replaced by referencing the method directly. + +### Why is this bad? +It's unnecessary to create the closure. + +### Example +``` +Some('a').map(|s| s.to_uppercase()); +``` +may be rewritten as +``` +Some('a').map(char::to_uppercase); +``` \ No newline at end of file diff --git a/src/docs/redundant_else.txt b/src/docs/redundant_else.txt new file mode 100644 index 00000000000..3f4e8691760 --- /dev/null +++ b/src/docs/redundant_else.txt @@ -0,0 +1,30 @@ +### What it does +Checks for `else` blocks that can be removed without changing semantics. + +### Why is this bad? +The `else` block adds unnecessary indentation and verbosity. + +### Known problems +Some may prefer to keep the `else` block for clarity. + +### Example +``` +fn my_func(count: u32) { + if count == 0 { + print!("Nothing to do"); + return; + } else { + print!("Moving on..."); + } +} +``` +Use instead: +``` +fn my_func(count: u32) { + if count == 0 { + print!("Nothing to do"); + return; + } + print!("Moving on..."); +} +``` \ No newline at end of file diff --git a/src/docs/redundant_feature_names.txt b/src/docs/redundant_feature_names.txt new file mode 100644 index 00000000000..5bd6925ed47 --- /dev/null +++ b/src/docs/redundant_feature_names.txt @@ -0,0 +1,23 @@ +### What it does +Checks for feature names with prefix `use-`, `with-` or suffix `-support` + +### Why is this bad? +These prefixes and suffixes have no significant meaning. + +### Example +``` +[features] +default = ["use-abc", "with-def", "ghi-support"] +use-abc = [] // redundant +with-def = [] // redundant +ghi-support = [] // redundant +``` + +Use instead: +``` +[features] +default = ["abc", "def", "ghi"] +abc = [] +def = [] +ghi = [] +``` diff --git a/src/docs/redundant_field_names.txt b/src/docs/redundant_field_names.txt new file mode 100644 index 00000000000..35f20a466b3 --- /dev/null +++ b/src/docs/redundant_field_names.txt @@ -0,0 +1,22 @@ +### What it does +Checks for fields in struct literals where shorthands +could be used. + +### Why is this bad? +If the field and variable names are the same, +the field name is redundant. + +### Example +``` +let bar: u8 = 123; + +struct Foo { + bar: u8, +} + +let foo = Foo { bar: bar }; +``` +the last line can be simplified to +``` +let foo = Foo { bar }; +``` \ No newline at end of file diff --git a/src/docs/redundant_pattern.txt b/src/docs/redundant_pattern.txt new file mode 100644 index 00000000000..45f6cfc8670 --- /dev/null +++ b/src/docs/redundant_pattern.txt @@ -0,0 +1,22 @@ +### What it does +Checks for patterns in the form `name @ _`. + +### Why is this bad? +It's almost always more readable to just use direct +bindings. + +### Example +``` +match v { + Some(x) => (), + y @ _ => (), +} +``` + +Use instead: +``` +match v { + Some(x) => (), + y => (), +} +``` \ No newline at end of file diff --git a/src/docs/redundant_pattern_matching.txt b/src/docs/redundant_pattern_matching.txt new file mode 100644 index 00000000000..77b1021e0db --- /dev/null +++ b/src/docs/redundant_pattern_matching.txt @@ -0,0 +1,45 @@ +### What it does +Lint for redundant pattern matching over `Result`, `Option`, +`std::task::Poll` or `std::net::IpAddr` + +### Why is this bad? +It's more concise and clear to just use the proper +utility function + +### Known problems +This will change the drop order for the matched type. Both `if let` and +`while let` will drop the value at the end of the block, both `if` and `while` will drop the +value before entering the block. For most types this change will not matter, but for a few +types this will not be an acceptable change (e.g. locks). See the +[reference](https://doc.rust-lang.org/reference/destructors.html#drop-scopes) for more about +drop order. + +### Example +``` +if let Ok(_) = Ok::(42) {} +if let Err(_) = Err::(42) {} +if let None = None::<()> {} +if let Some(_) = Some(42) {} +if let Poll::Pending = Poll::Pending::<()> {} +if let Poll::Ready(_) = Poll::Ready(42) {} +if let IpAddr::V4(_) = IpAddr::V4(Ipv4Addr::LOCALHOST) {} +if let IpAddr::V6(_) = IpAddr::V6(Ipv6Addr::LOCALHOST) {} +match Ok::(42) { + Ok(_) => true, + Err(_) => false, +}; +``` + +The more idiomatic use would be: + +``` +if Ok::(42).is_ok() {} +if Err::(42).is_err() {} +if None::<()>.is_none() {} +if Some(42).is_some() {} +if Poll::Pending::<()>.is_pending() {} +if Poll::Ready(42).is_ready() {} +if IpAddr::V4(Ipv4Addr::LOCALHOST).is_ipv4() {} +if IpAddr::V6(Ipv6Addr::LOCALHOST).is_ipv6() {} +Ok::(42).is_ok(); +``` \ No newline at end of file diff --git a/src/docs/redundant_pub_crate.txt b/src/docs/redundant_pub_crate.txt new file mode 100644 index 00000000000..a527bb5acda --- /dev/null +++ b/src/docs/redundant_pub_crate.txt @@ -0,0 +1,21 @@ +### What it does +Checks for items declared `pub(crate)` that are not crate visible because they +are inside a private module. + +### Why is this bad? +Writing `pub(crate)` is misleading when it's redundant due to the parent +module's visibility. + +### Example +``` +mod internal { + pub(crate) fn internal_fn() { } +} +``` +This function is not visible outside the module and it can be declared with `pub` or +private visibility +``` +mod internal { + pub fn internal_fn() { } +} +``` \ No newline at end of file diff --git a/src/docs/redundant_slicing.txt b/src/docs/redundant_slicing.txt new file mode 100644 index 00000000000..6798911ed76 --- /dev/null +++ b/src/docs/redundant_slicing.txt @@ -0,0 +1,24 @@ +### What it does +Checks for redundant slicing expressions which use the full range, and +do not change the type. + +### Why is this bad? +It unnecessarily adds complexity to the expression. + +### Known problems +If the type being sliced has an implementation of `Index` +that actually changes anything then it can't be removed. However, this would be surprising +to people reading the code and should have a note with it. + +### Example +``` +fn get_slice(x: &[u32]) -> &[u32] { + &x[..] +} +``` +Use instead: +``` +fn get_slice(x: &[u32]) -> &[u32] { + x +} +``` \ No newline at end of file diff --git a/src/docs/redundant_static_lifetimes.txt b/src/docs/redundant_static_lifetimes.txt new file mode 100644 index 00000000000..edb8e7b5c62 --- /dev/null +++ b/src/docs/redundant_static_lifetimes.txt @@ -0,0 +1,19 @@ +### What it does +Checks for constants and statics with an explicit `'static` lifetime. + +### Why is this bad? +Adding `'static` to every reference can create very +complicated types. + +### Example +``` +const FOO: &'static [(&'static str, &'static str, fn(&Bar) -> bool)] = +&[...] +static FOO: &'static [(&'static str, &'static str, fn(&Bar) -> bool)] = +&[...] +``` +This code can be rewritten as +``` + const FOO: &[(&str, &str, fn(&Bar) -> bool)] = &[...] + static FOO: &[(&str, &str, fn(&Bar) -> bool)] = &[...] +``` \ No newline at end of file diff --git a/src/docs/ref_binding_to_reference.txt b/src/docs/ref_binding_to_reference.txt new file mode 100644 index 00000000000..dc391cd988e --- /dev/null +++ b/src/docs/ref_binding_to_reference.txt @@ -0,0 +1,21 @@ +### What it does +Checks for `ref` bindings which create a reference to a reference. + +### Why is this bad? +The address-of operator at the use site is clearer about the need for a reference. + +### Example +``` +let x = Some(""); +if let Some(ref x) = x { + // use `x` here +} +``` + +Use instead: +``` +let x = Some(""); +if let Some(x) = x { + // use `&x` here +} +``` \ No newline at end of file diff --git a/src/docs/ref_option_ref.txt b/src/docs/ref_option_ref.txt new file mode 100644 index 00000000000..951c7bd7f7e --- /dev/null +++ b/src/docs/ref_option_ref.txt @@ -0,0 +1,19 @@ +### What it does +Checks for usage of `&Option<&T>`. + +### Why is this bad? +Since `&` is Copy, it's useless to have a +reference on `Option<&T>`. + +### Known problems +It may be irrelevant to use this lint on +public API code as it will make a breaking change to apply it. + +### Example +``` +let x: &Option<&u32> = &Some(&0u32); +``` +Use instead: +``` +let x: Option<&u32> = Some(&0u32); +``` \ No newline at end of file diff --git a/src/docs/repeat_once.txt b/src/docs/repeat_once.txt new file mode 100644 index 00000000000..3ba189c1945 --- /dev/null +++ b/src/docs/repeat_once.txt @@ -0,0 +1,25 @@ +### What it does +Checks for usage of `.repeat(1)` and suggest the following method for each types. +- `.to_string()` for `str` +- `.clone()` for `String` +- `.to_vec()` for `slice` + +The lint will evaluate constant expressions and values as arguments of `.repeat(..)` and emit a message if +they are equivalent to `1`. (Related discussion in [rust-clippy#7306](https://github.com/rust-lang/rust-clippy/issues/7306)) + +### Why is this bad? +For example, `String.repeat(1)` is equivalent to `.clone()`. If cloning +the string is the intention behind this, `clone()` should be used. + +### Example +``` +fn main() { + let x = String::from("hello world").repeat(1); +} +``` +Use instead: +``` +fn main() { + let x = String::from("hello world").clone(); +} +``` \ No newline at end of file diff --git a/src/docs/rest_pat_in_fully_bound_structs.txt b/src/docs/rest_pat_in_fully_bound_structs.txt new file mode 100644 index 00000000000..40ebbe754a3 --- /dev/null +++ b/src/docs/rest_pat_in_fully_bound_structs.txt @@ -0,0 +1,24 @@ +### What it does +Checks for unnecessary '..' pattern binding on struct when all fields are explicitly matched. + +### Why is this bad? +Correctness and readability. It's like having a wildcard pattern after +matching all enum variants explicitly. + +### Example +``` +let a = A { a: 5 }; + +match a { + A { a: 5, .. } => {}, + _ => {}, +} +``` + +Use instead: +``` +match a { + A { a: 5 } => {}, + _ => {}, +} +``` \ No newline at end of file diff --git a/src/docs/result_large_err.txt b/src/docs/result_large_err.txt new file mode 100644 index 00000000000..e5fab3c5cfc --- /dev/null +++ b/src/docs/result_large_err.txt @@ -0,0 +1,36 @@ +### What it does +Checks for functions that return `Result` with an unusually large +`Err`-variant. + +### Why is this bad? +A `Result` is at least as large as the `Err`-variant. While we +expect that variant to be seldomly used, the compiler needs to reserve +and move that much memory every single time. + +### Known problems +The size determined by Clippy is platform-dependent. + +### Examples +``` +pub enum ParseError { + UnparsedBytes([u8; 512]), + UnexpectedEof, +} + +// The `Result` has at least 512 bytes, even in the `Ok`-case +pub fn parse() -> Result<(), ParseError> { + Ok(()) +} +``` +should be +``` +pub enum ParseError { + UnparsedBytes(Box<[u8; 512]>), + UnexpectedEof, +} + +// The `Result` is slightly larger than a pointer +pub fn parse() -> Result<(), ParseError> { + Ok(()) +} +``` \ No newline at end of file diff --git a/src/docs/result_map_or_into_option.txt b/src/docs/result_map_or_into_option.txt new file mode 100644 index 00000000000..899d98c307c --- /dev/null +++ b/src/docs/result_map_or_into_option.txt @@ -0,0 +1,16 @@ +### What it does +Checks for usage of `_.map_or(None, Some)`. + +### Why is this bad? +Readability, this can be written more concisely as +`_.ok()`. + +### Example +``` +assert_eq!(Some(1), r.map_or(None, Some)); +``` + +Use instead: +``` +assert_eq!(Some(1), r.ok()); +``` \ No newline at end of file diff --git a/src/docs/result_map_unit_fn.txt b/src/docs/result_map_unit_fn.txt new file mode 100644 index 00000000000..3455c5c1f9b --- /dev/null +++ b/src/docs/result_map_unit_fn.txt @@ -0,0 +1,26 @@ +### What it does +Checks for usage of `result.map(f)` where f is a function +or closure that returns the unit type `()`. + +### Why is this bad? +Readability, this can be written more clearly with +an if let statement + +### Example +``` +let x: Result = do_stuff(); +x.map(log_err_msg); +x.map(|msg| log_err_msg(format_msg(msg))); +``` + +The correct use would be: + +``` +let x: Result = do_stuff(); +if let Ok(msg) = x { + log_err_msg(msg); +}; +if let Ok(msg) = x { + log_err_msg(format_msg(msg)); +}; +``` \ No newline at end of file diff --git a/src/docs/result_unit_err.txt b/src/docs/result_unit_err.txt new file mode 100644 index 00000000000..7c8ec2ffcf9 --- /dev/null +++ b/src/docs/result_unit_err.txt @@ -0,0 +1,40 @@ +### What it does +Checks for public functions that return a `Result` +with an `Err` type of `()`. It suggests using a custom type that +implements `std::error::Error`. + +### Why is this bad? +Unit does not implement `Error` and carries no +further information about what went wrong. + +### Known problems +Of course, this lint assumes that `Result` is used +for a fallible operation (which is after all the intended use). However +code may opt to (mis)use it as a basic two-variant-enum. In that case, +the suggestion is misguided, and the code should use a custom enum +instead. + +### Examples +``` +pub fn read_u8() -> Result { Err(()) } +``` +should become +``` +use std::fmt; + +#[derive(Debug)] +pub struct EndOfStream; + +impl fmt::Display for EndOfStream { + fn fmt(&self, f: &mut fmt::Formatter<'_>) -> fmt::Result { + write!(f, "End of Stream") + } +} + +impl std::error::Error for EndOfStream { } + +pub fn read_u8() -> Result { Err(EndOfStream) } +``` + +Note that there are crates that simplify creating the error type, e.g. +[`thiserror`](https://docs.rs/thiserror). \ No newline at end of file diff --git a/src/docs/return_self_not_must_use.txt b/src/docs/return_self_not_must_use.txt new file mode 100644 index 00000000000..4a4fd2c6e51 --- /dev/null +++ b/src/docs/return_self_not_must_use.txt @@ -0,0 +1,46 @@ +### What it does +This lint warns when a method returning `Self` doesn't have the `#[must_use]` attribute. + +### Why is this bad? +Methods returning `Self` often create new values, having the `#[must_use]` attribute +prevents users from "forgetting" to use the newly created value. + +The `#[must_use]` attribute can be added to the type itself to ensure that instances +are never forgotten. Functions returning a type marked with `#[must_use]` will not be +linted, as the usage is already enforced by the type attribute. + +### Limitations +This lint is only applied on methods taking a `self` argument. It would be mostly noise +if it was added on constructors for example. + +### Example +``` +pub struct Bar; +impl Bar { + // Missing attribute + pub fn bar(&self) -> Self { + Self + } +} +``` + +Use instead: +``` +// It's better to have the `#[must_use]` attribute on the method like this: +pub struct Bar; +impl Bar { + #[must_use] + pub fn bar(&self) -> Self { + Self + } +} + +// Or on the type definition like this: +#[must_use] +pub struct Bar; +impl Bar { + pub fn bar(&self) -> Self { + Self + } +} +``` \ No newline at end of file diff --git a/src/docs/reversed_empty_ranges.txt b/src/docs/reversed_empty_ranges.txt new file mode 100644 index 00000000000..39f48119386 --- /dev/null +++ b/src/docs/reversed_empty_ranges.txt @@ -0,0 +1,26 @@ +### What it does +Checks for range expressions `x..y` where both `x` and `y` +are constant and `x` is greater or equal to `y`. + +### Why is this bad? +Empty ranges yield no values so iterating them is a no-op. +Moreover, trying to use a reversed range to index a slice will panic at run-time. + +### Example +``` +fn main() { + (10..=0).for_each(|x| println!("{}", x)); + + let arr = [1, 2, 3, 4, 5]; + let sub = &arr[3..1]; +} +``` +Use instead: +``` +fn main() { + (0..=10).rev().for_each(|x| println!("{}", x)); + + let arr = [1, 2, 3, 4, 5]; + let sub = &arr[1..3]; +} +``` \ No newline at end of file diff --git a/src/docs/same_functions_in_if_condition.txt b/src/docs/same_functions_in_if_condition.txt new file mode 100644 index 00000000000..a0a90eec681 --- /dev/null +++ b/src/docs/same_functions_in_if_condition.txt @@ -0,0 +1,41 @@ +### What it does +Checks for consecutive `if`s with the same function call. + +### Why is this bad? +This is probably a copy & paste error. +Despite the fact that function can have side effects and `if` works as +intended, such an approach is implicit and can be considered a "code smell". + +### Example +``` +if foo() == bar { + … +} else if foo() == bar { + … +} +``` + +This probably should be: +``` +if foo() == bar { + … +} else if foo() == baz { + … +} +``` + +or if the original code was not a typo and called function mutates a state, +consider move the mutation out of the `if` condition to avoid similarity to +a copy & paste error: + +``` +let first = foo(); +if first == bar { + … +} else { + let second = foo(); + if second == bar { + … + } +} +``` \ No newline at end of file diff --git a/src/docs/same_item_push.txt b/src/docs/same_item_push.txt new file mode 100644 index 00000000000..7e724073f8a --- /dev/null +++ b/src/docs/same_item_push.txt @@ -0,0 +1,29 @@ +### What it does +Checks whether a for loop is being used to push a constant +value into a Vec. + +### Why is this bad? +This kind of operation can be expressed more succinctly with +`vec![item; SIZE]` or `vec.resize(NEW_SIZE, item)` and using these alternatives may also +have better performance. + +### Example +``` +let item1 = 2; +let item2 = 3; +let mut vec: Vec = Vec::new(); +for _ in 0..20 { + vec.push(item1); +} +for _ in 0..30 { + vec.push(item2); +} +``` + +Use instead: +``` +let item1 = 2; +let item2 = 3; +let mut vec: Vec = vec![item1; 20]; +vec.resize(20 + 30, item2); +``` \ No newline at end of file diff --git a/src/docs/same_name_method.txt b/src/docs/same_name_method.txt new file mode 100644 index 00000000000..792dd717fc6 --- /dev/null +++ b/src/docs/same_name_method.txt @@ -0,0 +1,23 @@ +### What it does +It lints if a struct has two methods with the same name: +one from a trait, another not from trait. + +### Why is this bad? +Confusing. + +### Example +``` +trait T { + fn foo(&self) {} +} + +struct S; + +impl T for S { + fn foo(&self) {} +} + +impl S { + fn foo(&self) {} +} +``` \ No newline at end of file diff --git a/src/docs/search_is_some.txt b/src/docs/search_is_some.txt new file mode 100644 index 00000000000..67292d54585 --- /dev/null +++ b/src/docs/search_is_some.txt @@ -0,0 +1,24 @@ +### What it does +Checks for an iterator or string search (such as `find()`, +`position()`, or `rposition()`) followed by a call to `is_some()` or `is_none()`. + +### Why is this bad? +Readability, this can be written more concisely as: +* `_.any(_)`, or `_.contains(_)` for `is_some()`, +* `!_.any(_)`, or `!_.contains(_)` for `is_none()`. + +### Example +``` +let vec = vec![1]; +vec.iter().find(|x| **x == 0).is_some(); + +"hello world".find("world").is_none(); +``` + +Use instead: +``` +let vec = vec![1]; +vec.iter().any(|x| *x == 0); + +!"hello world".contains("world"); +``` \ No newline at end of file diff --git a/src/docs/self_assignment.txt b/src/docs/self_assignment.txt new file mode 100644 index 00000000000..ea60ea077ab --- /dev/null +++ b/src/docs/self_assignment.txt @@ -0,0 +1,32 @@ +### What it does +Checks for explicit self-assignments. + +### Why is this bad? +Self-assignments are redundant and unlikely to be +intentional. + +### Known problems +If expression contains any deref coercions or +indexing operations they are assumed not to have any side effects. + +### Example +``` +struct Event { + x: i32, +} + +fn copy_position(a: &mut Event, b: &Event) { + a.x = a.x; +} +``` + +Should be: +``` +struct Event { + x: i32, +} + +fn copy_position(a: &mut Event, b: &Event) { + a.x = b.x; +} +``` \ No newline at end of file diff --git a/src/docs/self_named_constructors.txt b/src/docs/self_named_constructors.txt new file mode 100644 index 00000000000..a01669a8454 --- /dev/null +++ b/src/docs/self_named_constructors.txt @@ -0,0 +1,26 @@ +### What it does +Warns when constructors have the same name as their types. + +### Why is this bad? +Repeating the name of the type is redundant. + +### Example +``` +struct Foo {} + +impl Foo { + pub fn foo() -> Foo { + Foo {} + } +} +``` +Use instead: +``` +struct Foo {} + +impl Foo { + pub fn new() -> Foo { + Foo {} + } +} +``` \ No newline at end of file diff --git a/src/docs/self_named_module_files.txt b/src/docs/self_named_module_files.txt new file mode 100644 index 00000000000..73e80513628 --- /dev/null +++ b/src/docs/self_named_module_files.txt @@ -0,0 +1,22 @@ +### What it does +Checks that module layout uses only `mod.rs` files. + +### Why is this bad? +Having multiple module layout styles in a project can be confusing. + +### Example +``` +src/ + stuff/ + stuff_files.rs + stuff.rs + lib.rs +``` +Use instead: +``` +src/ + stuff/ + stuff_files.rs + mod.rs + lib.rs +``` \ No newline at end of file diff --git a/src/docs/semicolon_if_nothing_returned.txt b/src/docs/semicolon_if_nothing_returned.txt new file mode 100644 index 00000000000..30c963ca211 --- /dev/null +++ b/src/docs/semicolon_if_nothing_returned.txt @@ -0,0 +1,20 @@ +### What it does +Looks for blocks of expressions and fires if the last expression returns +`()` but is not followed by a semicolon. + +### Why is this bad? +The semicolon might be optional but when extending the block with new +code, it doesn't require a change in previous last line. + +### Example +``` +fn main() { + println!("Hello world") +} +``` +Use instead: +``` +fn main() { + println!("Hello world"); +} +``` \ No newline at end of file diff --git a/src/docs/separated_literal_suffix.txt b/src/docs/separated_literal_suffix.txt new file mode 100644 index 00000000000..226a6b8a987 --- /dev/null +++ b/src/docs/separated_literal_suffix.txt @@ -0,0 +1,17 @@ +### What it does +Warns if literal suffixes are separated by an underscore. +To enforce separated literal suffix style, +see the `unseparated_literal_suffix` lint. + +### Why is this bad? +Suffix style should be consistent. + +### Example +``` +123832_i32 +``` + +Use instead: +``` +123832i32 +``` \ No newline at end of file diff --git a/src/docs/serde_api_misuse.txt b/src/docs/serde_api_misuse.txt new file mode 100644 index 00000000000..8a3c89ac11a --- /dev/null +++ b/src/docs/serde_api_misuse.txt @@ -0,0 +1,10 @@ +### What it does +Checks for mis-uses of the serde API. + +### Why is this bad? +Serde is very finnicky about how its API should be +used, but the type system can't be used to enforce it (yet?). + +### Example +Implementing `Visitor::visit_string` but not +`Visitor::visit_str`. \ No newline at end of file diff --git a/src/docs/shadow_reuse.txt b/src/docs/shadow_reuse.txt new file mode 100644 index 00000000000..9eb8e7ad164 --- /dev/null +++ b/src/docs/shadow_reuse.txt @@ -0,0 +1,20 @@ +### What it does +Checks for bindings that shadow other bindings already in +scope, while reusing the original value. + +### Why is this bad? +Not too much, in fact it's a common pattern in Rust +code. Still, some argue that name shadowing like this hurts readability, +because a value may be bound to different things depending on position in +the code. + +### Example +``` +let x = 2; +let x = x + 1; +``` +use different variable name: +``` +let x = 2; +let y = x + 1; +``` \ No newline at end of file diff --git a/src/docs/shadow_same.txt b/src/docs/shadow_same.txt new file mode 100644 index 00000000000..3cd96f560a5 --- /dev/null +++ b/src/docs/shadow_same.txt @@ -0,0 +1,18 @@ +### What it does +Checks for bindings that shadow other bindings already in +scope, while just changing reference level or mutability. + +### Why is this bad? +Not much, in fact it's a very common pattern in Rust +code. Still, some may opt to avoid it in their code base, they can set this +lint to `Warn`. + +### Example +``` +let x = &x; +``` + +Use instead: +``` +let y = &x; // use different variable name +``` \ No newline at end of file diff --git a/src/docs/shadow_unrelated.txt b/src/docs/shadow_unrelated.txt new file mode 100644 index 00000000000..436251c520a --- /dev/null +++ b/src/docs/shadow_unrelated.txt @@ -0,0 +1,22 @@ +### What it does +Checks for bindings that shadow other bindings already in +scope, either without an initialization or with one that does not even use +the original value. + +### Why is this bad? +Name shadowing can hurt readability, especially in +large code bases, because it is easy to lose track of the active binding at +any place in the code. This can be alleviated by either giving more specific +names to bindings or introducing more scopes to contain the bindings. + +### Example +``` +let x = y; +let x = z; // shadows the earlier binding +``` + +Use instead: +``` +let x = y; +let w = z; // use different variable name +``` \ No newline at end of file diff --git a/src/docs/short_circuit_statement.txt b/src/docs/short_circuit_statement.txt new file mode 100644 index 00000000000..31492bed03d --- /dev/null +++ b/src/docs/short_circuit_statement.txt @@ -0,0 +1,14 @@ +### What it does +Checks for the use of short circuit boolean conditions as +a +statement. + +### Why is this bad? +Using a short circuit boolean condition as a statement +may hide the fact that the second part is executed or not depending on the +outcome of the first part. + +### Example +``` +f() && g(); // We should write `if f() { g(); }`. +``` \ No newline at end of file diff --git a/src/docs/should_implement_trait.txt b/src/docs/should_implement_trait.txt new file mode 100644 index 00000000000..02e74751ae0 --- /dev/null +++ b/src/docs/should_implement_trait.txt @@ -0,0 +1,22 @@ +### What it does +Checks for methods that should live in a trait +implementation of a `std` trait (see [llogiq's blog +post](http://llogiq.github.io/2015/07/30/traits.html) for further +information) instead of an inherent implementation. + +### Why is this bad? +Implementing the traits improve ergonomics for users of +the code, often with very little cost. Also people seeing a `mul(...)` +method +may expect `*` to work equally, so you should have good reason to disappoint +them. + +### Example +``` +struct X; +impl X { + fn add(&self, other: &X) -> X { + // .. + } +} +``` \ No newline at end of file diff --git a/src/docs/significant_drop_in_scrutinee.txt b/src/docs/significant_drop_in_scrutinee.txt new file mode 100644 index 00000000000..f869def0ddb --- /dev/null +++ b/src/docs/significant_drop_in_scrutinee.txt @@ -0,0 +1,43 @@ +### What it does +Check for temporaries returned from function calls in a match scrutinee that have the +`clippy::has_significant_drop` attribute. + +### Why is this bad? +The `clippy::has_significant_drop` attribute can be added to types whose Drop impls have +an important side-effect, such as unlocking a mutex, making it important for users to be +able to accurately understand their lifetimes. When a temporary is returned in a function +call in a match scrutinee, its lifetime lasts until the end of the match block, which may +be surprising. + +For `Mutex`es this can lead to a deadlock. This happens when the match scrutinee uses a +function call that returns a `MutexGuard` and then tries to lock again in one of the match +arms. In that case the `MutexGuard` in the scrutinee will not be dropped until the end of +the match block and thus will not unlock. + +### Example +``` +let mutex = Mutex::new(State {}); + +match mutex.lock().unwrap().foo() { + true => { + mutex.lock().unwrap().bar(); // Deadlock! + } + false => {} +}; + +println!("All done!"); +``` +Use instead: +``` +let mutex = Mutex::new(State {}); + +let is_foo = mutex.lock().unwrap().foo(); +match is_foo { + true => { + mutex.lock().unwrap().bar(); + } + false => {} +}; + +println!("All done!"); +``` \ No newline at end of file diff --git a/src/docs/similar_names.txt b/src/docs/similar_names.txt new file mode 100644 index 00000000000..13aca9c0bb7 --- /dev/null +++ b/src/docs/similar_names.txt @@ -0,0 +1,12 @@ +### What it does +Checks for names that are very similar and thus confusing. + +### Why is this bad? +It's hard to distinguish between names that differ only +by a single character. + +### Example +``` +let checked_exp = something; +let checked_expr = something_else; +``` \ No newline at end of file diff --git a/src/docs/single_char_add_str.txt b/src/docs/single_char_add_str.txt new file mode 100644 index 00000000000..cf23dc0c89b --- /dev/null +++ b/src/docs/single_char_add_str.txt @@ -0,0 +1,18 @@ +### What it does +Warns when using `push_str`/`insert_str` with a single-character string literal +where `push`/`insert` with a `char` would work fine. + +### Why is this bad? +It's less clear that we are pushing a single character. + +### Example +``` +string.insert_str(0, "R"); +string.push_str("R"); +``` + +Use instead: +``` +string.insert(0, 'R'); +string.push('R'); +``` \ No newline at end of file diff --git a/src/docs/single_char_lifetime_names.txt b/src/docs/single_char_lifetime_names.txt new file mode 100644 index 00000000000..92dd24bf247 --- /dev/null +++ b/src/docs/single_char_lifetime_names.txt @@ -0,0 +1,28 @@ +### What it does +Checks for lifetimes with names which are one character +long. + +### Why is this bad? +A single character is likely not enough to express the +purpose of a lifetime. Using a longer name can make code +easier to understand, especially for those who are new to +Rust. + +### Known problems +Rust programmers and learning resources tend to use single +character lifetimes, so this lint is at odds with the +ecosystem at large. In addition, the lifetime's purpose may +be obvious or, rarely, expressible in one character. + +### Example +``` +struct DiagnosticCtx<'a> { + source: &'a str, +} +``` +Use instead: +``` +struct DiagnosticCtx<'src> { + source: &'src str, +} +``` \ No newline at end of file diff --git a/src/docs/single_char_pattern.txt b/src/docs/single_char_pattern.txt new file mode 100644 index 00000000000..9e5ad1e7d63 --- /dev/null +++ b/src/docs/single_char_pattern.txt @@ -0,0 +1,20 @@ +### What it does +Checks for string methods that receive a single-character +`str` as an argument, e.g., `_.split("x")`. + +### Why is this bad? +Performing these methods using a `char` is faster than +using a `str`. + +### Known problems +Does not catch multi-byte unicode characters. + +### Example +``` +_.split("x"); +``` + +Use instead: +``` +_.split('x'); +``` \ No newline at end of file diff --git a/src/docs/single_component_path_imports.txt b/src/docs/single_component_path_imports.txt new file mode 100644 index 00000000000..3a026388183 --- /dev/null +++ b/src/docs/single_component_path_imports.txt @@ -0,0 +1,21 @@ +### What it does +Checking for imports with single component use path. + +### Why is this bad? +Import with single component use path such as `use cratename;` +is not necessary, and thus should be removed. + +### Example +``` +use regex; + +fn main() { + regex::Regex::new(r"^\d{4}-\d{2}-\d{2}$").unwrap(); +} +``` +Better as +``` +fn main() { + regex::Regex::new(r"^\d{4}-\d{2}-\d{2}$").unwrap(); +} +``` \ No newline at end of file diff --git a/src/docs/single_element_loop.txt b/src/docs/single_element_loop.txt new file mode 100644 index 00000000000..6f0c15a85f7 --- /dev/null +++ b/src/docs/single_element_loop.txt @@ -0,0 +1,21 @@ +### What it does +Checks whether a for loop has a single element. + +### Why is this bad? +There is no reason to have a loop of a +single element. + +### Example +``` +let item1 = 2; +for item in &[item1] { + println!("{}", item); +} +``` + +Use instead: +``` +let item1 = 2; +let item = &item1; +println!("{}", item); +``` \ No newline at end of file diff --git a/src/docs/single_match.txt b/src/docs/single_match.txt new file mode 100644 index 00000000000..31dde4da848 --- /dev/null +++ b/src/docs/single_match.txt @@ -0,0 +1,21 @@ +### What it does +Checks for matches with a single arm where an `if let` +will usually suffice. + +### Why is this bad? +Just readability – `if let` nests less than a `match`. + +### Example +``` +match x { + Some(ref foo) => bar(foo), + _ => (), +} +``` + +Use instead: +``` +if let Some(ref foo) = x { + bar(foo); +} +``` \ No newline at end of file diff --git a/src/docs/single_match_else.txt b/src/docs/single_match_else.txt new file mode 100644 index 00000000000..29a447af09b --- /dev/null +++ b/src/docs/single_match_else.txt @@ -0,0 +1,29 @@ +### What it does +Checks for matches with two arms where an `if let else` will +usually suffice. + +### Why is this bad? +Just readability – `if let` nests less than a `match`. + +### Known problems +Personal style preferences may differ. + +### Example +Using `match`: + +``` +match x { + Some(ref foo) => bar(foo), + _ => bar(&other_ref), +} +``` + +Using `if let` with `else`: + +``` +if let Some(ref foo) = x { + bar(foo); +} else { + bar(&other_ref); +} +``` \ No newline at end of file diff --git a/src/docs/size_of_in_element_count.txt b/src/docs/size_of_in_element_count.txt new file mode 100644 index 00000000000..d893ec6a2a0 --- /dev/null +++ b/src/docs/size_of_in_element_count.txt @@ -0,0 +1,16 @@ +### What it does +Detects expressions where +`size_of::` or `size_of_val::` is used as a +count of elements of type `T` + +### Why is this bad? +These functions expect a count +of `T` and not a number of bytes + +### Example +``` +const SIZE: usize = 128; +let x = [2u8; SIZE]; +let mut y = [2u8; SIZE]; +unsafe { copy_nonoverlapping(x.as_ptr(), y.as_mut_ptr(), size_of::() * SIZE) }; +``` \ No newline at end of file diff --git a/src/docs/skip_while_next.txt b/src/docs/skip_while_next.txt new file mode 100644 index 00000000000..1ec8a3a28d5 --- /dev/null +++ b/src/docs/skip_while_next.txt @@ -0,0 +1,16 @@ +### What it does +Checks for usage of `_.skip_while(condition).next()`. + +### Why is this bad? +Readability, this can be written more concisely as +`_.find(!condition)`. + +### Example +``` +vec.iter().skip_while(|x| **x == 0).next(); +``` + +Use instead: +``` +vec.iter().find(|x| **x != 0); +``` \ No newline at end of file diff --git a/src/docs/slow_vector_initialization.txt b/src/docs/slow_vector_initialization.txt new file mode 100644 index 00000000000..53442e17965 --- /dev/null +++ b/src/docs/slow_vector_initialization.txt @@ -0,0 +1,24 @@ +### What it does +Checks slow zero-filled vector initialization + +### Why is this bad? +These structures are non-idiomatic and less efficient than simply using +`vec![0; len]`. + +### Example +``` +let mut vec1 = Vec::with_capacity(len); +vec1.resize(len, 0); + +let mut vec1 = Vec::with_capacity(len); +vec1.resize(vec1.capacity(), 0); + +let mut vec2 = Vec::with_capacity(len); +vec2.extend(repeat(0).take(len)); +``` + +Use instead: +``` +let mut vec1 = vec![0; len]; +let mut vec2 = vec![0; len]; +``` \ No newline at end of file diff --git a/src/docs/stable_sort_primitive.txt b/src/docs/stable_sort_primitive.txt new file mode 100644 index 00000000000..6465dbee46b --- /dev/null +++ b/src/docs/stable_sort_primitive.txt @@ -0,0 +1,31 @@ +### What it does +When sorting primitive values (integers, bools, chars, as well +as arrays, slices, and tuples of such items), it is typically better to +use an unstable sort than a stable sort. + +### Why is this bad? +Typically, using a stable sort consumes more memory and cpu cycles. +Because values which compare equal are identical, preserving their +relative order (the guarantee that a stable sort provides) means +nothing, while the extra costs still apply. + +### Known problems + +As pointed out in +[issue #8241](https://github.com/rust-lang/rust-clippy/issues/8241), +a stable sort can instead be significantly faster for certain scenarios +(eg. when a sorted vector is extended with new data and resorted). + +For more information and benchmarking results, please refer to the +issue linked above. + +### Example +``` +let mut vec = vec![2, 1, 3]; +vec.sort(); +``` +Use instead: +``` +let mut vec = vec![2, 1, 3]; +vec.sort_unstable(); +``` \ No newline at end of file diff --git a/src/docs/std_instead_of_alloc.txt b/src/docs/std_instead_of_alloc.txt new file mode 100644 index 00000000000..c2d32704e50 --- /dev/null +++ b/src/docs/std_instead_of_alloc.txt @@ -0,0 +1,18 @@ +### What it does + +Finds items imported through `std` when available through `alloc`. + +### Why is this bad? + +Crates which have `no_std` compatibility and require alloc may wish to ensure types are imported from +alloc to ensure disabling `std` does not cause the crate to fail to compile. This lint is also useful +for crates migrating to become `no_std` compatible. + +### Example +``` +use std::vec::Vec; +``` +Use instead: +``` +use alloc::vec::Vec; +``` \ No newline at end of file diff --git a/src/docs/std_instead_of_core.txt b/src/docs/std_instead_of_core.txt new file mode 100644 index 00000000000..f1e1518c6a6 --- /dev/null +++ b/src/docs/std_instead_of_core.txt @@ -0,0 +1,18 @@ +### What it does + +Finds items imported through `std` when available through `core`. + +### Why is this bad? + +Crates which have `no_std` compatibility may wish to ensure types are imported from core to ensure +disabling `std` does not cause the crate to fail to compile. This lint is also useful for crates +migrating to become `no_std` compatible. + +### Example +``` +use std::hash::Hasher; +``` +Use instead: +``` +use core::hash::Hasher; +``` \ No newline at end of file diff --git a/src/docs/str_to_string.txt b/src/docs/str_to_string.txt new file mode 100644 index 00000000000..a2475522374 --- /dev/null +++ b/src/docs/str_to_string.txt @@ -0,0 +1,18 @@ +### What it does +This lint checks for `.to_string()` method calls on values of type `&str`. + +### Why is this bad? +The `to_string` method is also used on other types to convert them to a string. +When called on a `&str` it turns the `&str` into the owned variant `String`, which can be better +expressed with `.to_owned()`. + +### Example +``` +// example code where clippy issues a warning +let _ = "str".to_string(); +``` +Use instead: +``` +// example code which does not raise clippy warning +let _ = "str".to_owned(); +``` \ No newline at end of file diff --git a/src/docs/string_add.txt b/src/docs/string_add.txt new file mode 100644 index 00000000000..23dafd0d033 --- /dev/null +++ b/src/docs/string_add.txt @@ -0,0 +1,27 @@ +### What it does +Checks for all instances of `x + _` where `x` is of type +`String`, but only if [`string_add_assign`](#string_add_assign) does *not* +match. + +### Why is this bad? +It's not bad in and of itself. However, this particular +`Add` implementation is asymmetric (the other operand need not be `String`, +but `x` does), while addition as mathematically defined is symmetric, also +the `String::push_str(_)` function is a perfectly good replacement. +Therefore, some dislike it and wish not to have it in their code. + +That said, other people think that string addition, having a long tradition +in other languages is actually fine, which is why we decided to make this +particular lint `allow` by default. + +### Example +``` +let x = "Hello".to_owned(); +x + ", World"; +``` + +Use instead: +``` +let mut x = "Hello".to_owned(); +x.push_str(", World"); +``` \ No newline at end of file diff --git a/src/docs/string_add_assign.txt b/src/docs/string_add_assign.txt new file mode 100644 index 00000000000..7438be855db --- /dev/null +++ b/src/docs/string_add_assign.txt @@ -0,0 +1,17 @@ +### What it does +Checks for string appends of the form `x = x + y` (without +`let`!). + +### Why is this bad? +It's not really bad, but some people think that the +`.push_str(_)` method is more readable. + +### Example +``` +let mut x = "Hello".to_owned(); +x = x + ", World"; + +// More readable +x += ", World"; +x.push_str(", World"); +``` \ No newline at end of file diff --git a/src/docs/string_extend_chars.txt b/src/docs/string_extend_chars.txt new file mode 100644 index 00000000000..619ea3e1186 --- /dev/null +++ b/src/docs/string_extend_chars.txt @@ -0,0 +1,23 @@ +### What it does +Checks for the use of `.extend(s.chars())` where s is a +`&str` or `String`. + +### Why is this bad? +`.push_str(s)` is clearer + +### Example +``` +let abc = "abc"; +let def = String::from("def"); +let mut s = String::new(); +s.extend(abc.chars()); +s.extend(def.chars()); +``` +The correct use would be: +``` +let abc = "abc"; +let def = String::from("def"); +let mut s = String::new(); +s.push_str(abc); +s.push_str(&def); +``` \ No newline at end of file diff --git a/src/docs/string_from_utf8_as_bytes.txt b/src/docs/string_from_utf8_as_bytes.txt new file mode 100644 index 00000000000..9102d73471c --- /dev/null +++ b/src/docs/string_from_utf8_as_bytes.txt @@ -0,0 +1,15 @@ +### What it does +Check if the string is transformed to byte array and casted back to string. + +### Why is this bad? +It's unnecessary, the string can be used directly. + +### Example +``` +std::str::from_utf8(&"Hello World!".as_bytes()[6..11]).unwrap(); +``` + +Use instead: +``` +&"Hello World!"[6..11]; +``` \ No newline at end of file diff --git a/src/docs/string_lit_as_bytes.txt b/src/docs/string_lit_as_bytes.txt new file mode 100644 index 00000000000..a125b97ed65 --- /dev/null +++ b/src/docs/string_lit_as_bytes.txt @@ -0,0 +1,39 @@ +### What it does +Checks for the `as_bytes` method called on string literals +that contain only ASCII characters. + +### Why is this bad? +Byte string literals (e.g., `b"foo"`) can be used +instead. They are shorter but less discoverable than `as_bytes()`. + +### Known problems +`"str".as_bytes()` and the suggested replacement of `b"str"` are not +equivalent because they have different types. The former is `&[u8]` +while the latter is `&[u8; 3]`. That means in general they will have a +different set of methods and different trait implementations. + +``` +fn f(v: Vec) {} + +f("...".as_bytes().to_owned()); // works +f(b"...".to_owned()); // does not work, because arg is [u8; 3] not Vec + +fn g(r: impl std::io::Read) {} + +g("...".as_bytes()); // works +g(b"..."); // does not work +``` + +The actual equivalent of `"str".as_bytes()` with the same type is not +`b"str"` but `&b"str"[..]`, which is a great deal of punctuation and not +more readable than a function call. + +### Example +``` +let bstr = "a byte string".as_bytes(); +``` + +Use instead: +``` +let bstr = b"a byte string"; +``` \ No newline at end of file diff --git a/src/docs/string_slice.txt b/src/docs/string_slice.txt new file mode 100644 index 00000000000..3d9e49dd39e --- /dev/null +++ b/src/docs/string_slice.txt @@ -0,0 +1,17 @@ +### What it does +Checks for slice operations on strings + +### Why is this bad? +UTF-8 characters span multiple bytes, and it is easy to inadvertently confuse character +counts and string indices. This may lead to panics, and should warrant some test cases +containing wide UTF-8 characters. This lint is most useful in code that should avoid +panics at all costs. + +### Known problems +Probably lots of false positives. If an index comes from a known valid position (e.g. +obtained via `char_indices` over the same string), it is totally OK. + +# Example +``` +&"Ölkanne"[1..]; +``` \ No newline at end of file diff --git a/src/docs/string_to_string.txt b/src/docs/string_to_string.txt new file mode 100644 index 00000000000..deb7eebe784 --- /dev/null +++ b/src/docs/string_to_string.txt @@ -0,0 +1,19 @@ +### What it does +This lint checks for `.to_string()` method calls on values of type `String`. + +### Why is this bad? +The `to_string` method is also used on other types to convert them to a string. +When called on a `String` it only clones the `String`, which can be better expressed with `.clone()`. + +### Example +``` +// example code where clippy issues a warning +let msg = String::from("Hello World"); +let _ = msg.to_string(); +``` +Use instead: +``` +// example code which does not raise clippy warning +let msg = String::from("Hello World"); +let _ = msg.clone(); +``` \ No newline at end of file diff --git a/src/docs/strlen_on_c_strings.txt b/src/docs/strlen_on_c_strings.txt new file mode 100644 index 00000000000..0454abf55a2 --- /dev/null +++ b/src/docs/strlen_on_c_strings.txt @@ -0,0 +1,20 @@ +### What it does +Checks for usage of `libc::strlen` on a `CString` or `CStr` value, +and suggest calling `as_bytes().len()` or `to_bytes().len()` respectively instead. + +### Why is this bad? +This avoids calling an unsafe `libc` function. +Currently, it also avoids calculating the length. + +### Example +``` +use std::ffi::CString; +let cstring = CString::new("foo").expect("CString::new failed"); +let len = unsafe { libc::strlen(cstring.as_ptr()) }; +``` +Use instead: +``` +use std::ffi::CString; +let cstring = CString::new("foo").expect("CString::new failed"); +let len = cstring.as_bytes().len(); +``` \ No newline at end of file diff --git a/src/docs/struct_excessive_bools.txt b/src/docs/struct_excessive_bools.txt new file mode 100644 index 00000000000..9e197c78620 --- /dev/null +++ b/src/docs/struct_excessive_bools.txt @@ -0,0 +1,29 @@ +### What it does +Checks for excessive +use of bools in structs. + +### Why is this bad? +Excessive bools in a struct +is often a sign that it's used as a state machine, +which is much better implemented as an enum. +If it's not the case, excessive bools usually benefit +from refactoring into two-variant enums for better +readability and API. + +### Example +``` +struct S { + is_pending: bool, + is_processing: bool, + is_finished: bool, +} +``` + +Use instead: +``` +enum S { + Pending, + Processing, + Finished, +} +``` \ No newline at end of file diff --git a/src/docs/suboptimal_flops.txt b/src/docs/suboptimal_flops.txt new file mode 100644 index 00000000000..f1c9c665b08 --- /dev/null +++ b/src/docs/suboptimal_flops.txt @@ -0,0 +1,50 @@ +### What it does +Looks for floating-point expressions that +can be expressed using built-in methods to improve both +accuracy and performance. + +### Why is this bad? +Negatively impacts accuracy and performance. + +### Example +``` +use std::f32::consts::E; + +let a = 3f32; +let _ = (2f32).powf(a); +let _ = E.powf(a); +let _ = a.powf(1.0 / 2.0); +let _ = a.log(2.0); +let _ = a.log(10.0); +let _ = a.log(E); +let _ = a.powf(2.0); +let _ = a * 2.0 + 4.0; +let _ = if a < 0.0 { + -a +} else { + a +}; +let _ = if a < 0.0 { + a +} else { + -a +}; +``` + +is better expressed as + +``` +use std::f32::consts::E; + +let a = 3f32; +let _ = a.exp2(); +let _ = a.exp(); +let _ = a.sqrt(); +let _ = a.log2(); +let _ = a.log10(); +let _ = a.ln(); +let _ = a.powi(2); +let _ = a.mul_add(2.0, 4.0); +let _ = a.abs(); +let _ = -a.abs(); +``` \ No newline at end of file diff --git a/src/docs/suspicious_arithmetic_impl.txt b/src/docs/suspicious_arithmetic_impl.txt new file mode 100644 index 00000000000..d67ff279346 --- /dev/null +++ b/src/docs/suspicious_arithmetic_impl.txt @@ -0,0 +1,17 @@ +### What it does +Lints for suspicious operations in impls of arithmetic operators, e.g. +subtracting elements in an Add impl. + +### Why is this bad? +This is probably a typo or copy-and-paste error and not intended. + +### Example +``` +impl Add for Foo { + type Output = Foo; + + fn add(self, other: Foo) -> Foo { + Foo(self.0 - other.0) + } +} +``` \ No newline at end of file diff --git a/src/docs/suspicious_assignment_formatting.txt b/src/docs/suspicious_assignment_formatting.txt new file mode 100644 index 00000000000..b889827cdf2 --- /dev/null +++ b/src/docs/suspicious_assignment_formatting.txt @@ -0,0 +1,12 @@ +### What it does +Checks for use of the non-existent `=*`, `=!` and `=-` +operators. + +### Why is this bad? +This is either a typo of `*=`, `!=` or `-=` or +confusing. + +### Example +``` +a =- 42; // confusing, should it be `a -= 42` or `a = -42`? +``` \ No newline at end of file diff --git a/src/docs/suspicious_else_formatting.txt b/src/docs/suspicious_else_formatting.txt new file mode 100644 index 00000000000..3cf2f74868e --- /dev/null +++ b/src/docs/suspicious_else_formatting.txt @@ -0,0 +1,30 @@ +### What it does +Checks for formatting of `else`. It lints if the `else` +is followed immediately by a newline or the `else` seems to be missing. + +### Why is this bad? +This is probably some refactoring remnant, even if the +code is correct, it might look confusing. + +### Example +``` +if foo { +} { // looks like an `else` is missing here +} + +if foo { +} if bar { // looks like an `else` is missing here +} + +if foo { +} else + +{ // this is the `else` block of the previous `if`, but should it be? +} + +if foo { +} else + +if bar { // this is the `else` block of the previous `if`, but should it be? +} +``` \ No newline at end of file diff --git a/src/docs/suspicious_map.txt b/src/docs/suspicious_map.txt new file mode 100644 index 00000000000..d8fa52c43fb --- /dev/null +++ b/src/docs/suspicious_map.txt @@ -0,0 +1,13 @@ +### What it does +Checks for calls to `map` followed by a `count`. + +### Why is this bad? +It looks suspicious. Maybe `map` was confused with `filter`. +If the `map` call is intentional, this should be rewritten +using `inspect`. Or, if you intend to drive the iterator to +completion, you can just use `for_each` instead. + +### Example +``` +let _ = (0..3).map(|x| x + 2).count(); +``` \ No newline at end of file diff --git a/src/docs/suspicious_op_assign_impl.txt b/src/docs/suspicious_op_assign_impl.txt new file mode 100644 index 00000000000..81abfbecae0 --- /dev/null +++ b/src/docs/suspicious_op_assign_impl.txt @@ -0,0 +1,15 @@ +### What it does +Lints for suspicious operations in impls of OpAssign, e.g. +subtracting elements in an AddAssign impl. + +### Why is this bad? +This is probably a typo or copy-and-paste error and not intended. + +### Example +``` +impl AddAssign for Foo { + fn add_assign(&mut self, other: Foo) { + *self = *self - other; + } +} +``` \ No newline at end of file diff --git a/src/docs/suspicious_operation_groupings.txt b/src/docs/suspicious_operation_groupings.txt new file mode 100644 index 00000000000..81ede5d3da5 --- /dev/null +++ b/src/docs/suspicious_operation_groupings.txt @@ -0,0 +1,41 @@ +### What it does +Checks for unlikely usages of binary operators that are almost +certainly typos and/or copy/paste errors, given the other usages +of binary operators nearby. + +### Why is this bad? +They are probably bugs and if they aren't then they look like bugs +and you should add a comment explaining why you are doing such an +odd set of operations. + +### Known problems +There may be some false positives if you are trying to do something +unusual that happens to look like a typo. + +### Example +``` +struct Vec3 { + x: f64, + y: f64, + z: f64, +} + +impl Eq for Vec3 {} + +impl PartialEq for Vec3 { + fn eq(&self, other: &Self) -> bool { + // This should trigger the lint because `self.x` is compared to `other.y` + self.x == other.y && self.y == other.y && self.z == other.z + } +} +``` +Use instead: +``` +// same as above except: +impl PartialEq for Vec3 { + fn eq(&self, other: &Self) -> bool { + // Note we now compare other.x to self.x + self.x == other.x && self.y == other.y && self.z == other.z + } +} +``` \ No newline at end of file diff --git a/src/docs/suspicious_splitn.txt b/src/docs/suspicious_splitn.txt new file mode 100644 index 00000000000..79a3dbfa6f4 --- /dev/null +++ b/src/docs/suspicious_splitn.txt @@ -0,0 +1,22 @@ +### What it does +Checks for calls to [`splitn`] +(https://doc.rust-lang.org/std/primitive.str.html#method.splitn) and +related functions with either zero or one splits. + +### Why is this bad? +These calls don't actually split the value and are +likely to be intended as a different number. + +### Example +``` +for x in s.splitn(1, ":") { + // .. +} +``` + +Use instead: +``` +for x in s.splitn(2, ":") { + // .. +} +``` \ No newline at end of file diff --git a/src/docs/suspicious_to_owned.txt b/src/docs/suspicious_to_owned.txt new file mode 100644 index 00000000000..8cbf61dc717 --- /dev/null +++ b/src/docs/suspicious_to_owned.txt @@ -0,0 +1,39 @@ +### What it does +Checks for the usage of `_.to_owned()`, on a `Cow<'_, _>`. + +### Why is this bad? +Calling `to_owned()` on a `Cow` creates a clone of the `Cow` +itself, without taking ownership of the `Cow` contents (i.e. +it's equivalent to calling `Cow::clone`). +The similarly named `into_owned` method, on the other hand, +clones the `Cow` contents, effectively turning any `Cow::Borrowed` +into a `Cow::Owned`. + +Given the potential ambiguity, consider replacing `to_owned` +with `clone` for better readability or, if getting a `Cow::Owned` +was the original intent, using `into_owned` instead. + +### Example +``` +let s = "Hello world!"; +let cow = Cow::Borrowed(s); + +let data = cow.to_owned(); +assert!(matches!(data, Cow::Borrowed(_))) +``` +Use instead: +``` +let s = "Hello world!"; +let cow = Cow::Borrowed(s); + +let data = cow.clone(); +assert!(matches!(data, Cow::Borrowed(_))) +``` +or +``` +let s = "Hello world!"; +let cow = Cow::Borrowed(s); + +let data = cow.into_owned(); +assert!(matches!(data, String)) +``` \ No newline at end of file diff --git a/src/docs/suspicious_unary_op_formatting.txt b/src/docs/suspicious_unary_op_formatting.txt new file mode 100644 index 00000000000..06fb09db76d --- /dev/null +++ b/src/docs/suspicious_unary_op_formatting.txt @@ -0,0 +1,18 @@ +### What it does +Checks the formatting of a unary operator on the right hand side +of a binary operator. It lints if there is no space between the binary and unary operators, +but there is a space between the unary and its operand. + +### Why is this bad? +This is either a typo in the binary operator or confusing. + +### Example +``` +// &&! looks like a different operator +if foo &&! bar {} +``` + +Use instead: +``` +if foo && !bar {} +``` \ No newline at end of file diff --git a/src/docs/swap_ptr_to_ref.txt b/src/docs/swap_ptr_to_ref.txt new file mode 100644 index 00000000000..0215d1e8a42 --- /dev/null +++ b/src/docs/swap_ptr_to_ref.txt @@ -0,0 +1,23 @@ +### What it does +Checks for calls to `core::mem::swap` where either parameter is derived from a pointer + +### Why is this bad? +When at least one parameter to `swap` is derived from a pointer it may overlap with the +other. This would then lead to undefined behavior. + +### Example +``` +unsafe fn swap(x: &[*mut u32], y: &[*mut u32]) { + for (&x, &y) in x.iter().zip(y) { + core::mem::swap(&mut *x, &mut *y); + } +} +``` +Use instead: +``` +unsafe fn swap(x: &[*mut u32], y: &[*mut u32]) { + for (&x, &y) in x.iter().zip(y) { + core::ptr::swap(x, y); + } +} +``` \ No newline at end of file diff --git a/src/docs/tabs_in_doc_comments.txt b/src/docs/tabs_in_doc_comments.txt new file mode 100644 index 00000000000..f83dbe2b73c --- /dev/null +++ b/src/docs/tabs_in_doc_comments.txt @@ -0,0 +1,44 @@ +### What it does +Checks doc comments for usage of tab characters. + +### Why is this bad? +The rust style-guide promotes spaces instead of tabs for indentation. +To keep a consistent view on the source, also doc comments should not have tabs. +Also, explaining ascii-diagrams containing tabs can get displayed incorrectly when the +display settings of the author and reader differ. + +### Example +``` +/// +/// Struct to hold two strings: +/// - first one +/// - second one +pub struct DoubleString { + /// + /// - First String: + /// - needs to be inside here + first_string: String, + /// + /// - Second String: + /// - needs to be inside here + second_string: String, +} +``` + +Will be converted to: +``` +/// +/// Struct to hold two strings: +/// - first one +/// - second one +pub struct DoubleString { + /// + /// - First String: + /// - needs to be inside here + first_string: String, + /// + /// - Second String: + /// - needs to be inside here + second_string: String, +} +``` \ No newline at end of file diff --git a/src/docs/temporary_assignment.txt b/src/docs/temporary_assignment.txt new file mode 100644 index 00000000000..195b42cf0d4 --- /dev/null +++ b/src/docs/temporary_assignment.txt @@ -0,0 +1,12 @@ +### What it does +Checks for construction of a structure or tuple just to +assign a value in it. + +### Why is this bad? +Readability. If the structure is only created to be +updated, why not write the structure you want in the first place? + +### Example +``` +(0, 0).0 = 1 +``` \ No newline at end of file diff --git a/src/docs/to_digit_is_some.txt b/src/docs/to_digit_is_some.txt new file mode 100644 index 00000000000..eee8375adf7 --- /dev/null +++ b/src/docs/to_digit_is_some.txt @@ -0,0 +1,15 @@ +### What it does +Checks for `.to_digit(..).is_some()` on `char`s. + +### Why is this bad? +This is a convoluted way of checking if a `char` is a digit. It's +more straight forward to use the dedicated `is_digit` method. + +### Example +``` +let is_digit = c.to_digit(radix).is_some(); +``` +can be written as: +``` +let is_digit = c.is_digit(radix); +``` \ No newline at end of file diff --git a/src/docs/to_string_in_format_args.txt b/src/docs/to_string_in_format_args.txt new file mode 100644 index 00000000000..34b20583585 --- /dev/null +++ b/src/docs/to_string_in_format_args.txt @@ -0,0 +1,17 @@ +### What it does +Checks for [`ToString::to_string`](https://doc.rust-lang.org/std/string/trait.ToString.html#tymethod.to_string) +applied to a type that implements [`Display`](https://doc.rust-lang.org/std/fmt/trait.Display.html) +in a macro that does formatting. + +### Why is this bad? +Since the type implements `Display`, the use of `to_string` is +unnecessary. + +### Example +``` +println!("error: something failed at {}", Location::caller().to_string()); +``` +Use instead: +``` +println!("error: something failed at {}", Location::caller()); +``` \ No newline at end of file diff --git a/src/docs/todo.txt b/src/docs/todo.txt new file mode 100644 index 00000000000..661eb1ac5cf --- /dev/null +++ b/src/docs/todo.txt @@ -0,0 +1,10 @@ +### What it does +Checks for usage of `todo!`. + +### Why is this bad? +This macro should not be present in production code + +### Example +``` +todo!(); +``` \ No newline at end of file diff --git a/src/docs/too_many_arguments.txt b/src/docs/too_many_arguments.txt new file mode 100644 index 00000000000..4669f9f82e6 --- /dev/null +++ b/src/docs/too_many_arguments.txt @@ -0,0 +1,14 @@ +### What it does +Checks for functions with too many parameters. + +### Why is this bad? +Functions with lots of parameters are considered bad +style and reduce readability (“what does the 5th parameter mean?”). Consider +grouping some parameters into a new type. + +### Example +``` +fn foo(x: u32, y: u32, name: &str, c: Color, w: f32, h: f32, a: f32, b: f32) { + // .. +} +``` \ No newline at end of file diff --git a/src/docs/too_many_lines.txt b/src/docs/too_many_lines.txt new file mode 100644 index 00000000000..425db348bbd --- /dev/null +++ b/src/docs/too_many_lines.txt @@ -0,0 +1,17 @@ +### What it does +Checks for functions with a large amount of lines. + +### Why is this bad? +Functions with a lot of lines are harder to understand +due to having to look at a larger amount of code to understand what the +function is doing. Consider splitting the body of the function into +multiple functions. + +### Example +``` +fn im_too_long() { + println!(""); + // ... 100 more LoC + println!(""); +} +``` \ No newline at end of file diff --git a/src/docs/toplevel_ref_arg.txt b/src/docs/toplevel_ref_arg.txt new file mode 100644 index 00000000000..96a9e2db8b7 --- /dev/null +++ b/src/docs/toplevel_ref_arg.txt @@ -0,0 +1,28 @@ +### What it does +Checks for function arguments and let bindings denoted as +`ref`. + +### Why is this bad? +The `ref` declaration makes the function take an owned +value, but turns the argument into a reference (which means that the value +is destroyed when exiting the function). This adds not much value: either +take a reference type, or take an owned value and create references in the +body. + +For let bindings, `let x = &foo;` is preferred over `let ref x = foo`. The +type of `x` is more obvious with the former. + +### Known problems +If the argument is dereferenced within the function, +removing the `ref` will lead to errors. This can be fixed by removing the +dereferences, e.g., changing `*x` to `x` within the function. + +### Example +``` +fn foo(ref _x: u8) {} +``` + +Use instead: +``` +fn foo(_x: &u8) {} +``` \ No newline at end of file diff --git a/src/docs/trailing_empty_array.txt b/src/docs/trailing_empty_array.txt new file mode 100644 index 00000000000..db1908cc96d --- /dev/null +++ b/src/docs/trailing_empty_array.txt @@ -0,0 +1,22 @@ +### What it does +Displays a warning when a struct with a trailing zero-sized array is declared without a `repr` attribute. + +### Why is this bad? +Zero-sized arrays aren't very useful in Rust itself, so such a struct is likely being created to pass to C code or in some other situation where control over memory layout matters (for example, in conjunction with manual allocation to make it easy to compute the offset of the array). Either way, `#[repr(C)]` (or another `repr` attribute) is needed. + +### Example +``` +struct RarelyUseful { + some_field: u32, + last: [u32; 0], +} +``` + +Use instead: +``` +#[repr(C)] +struct MoreOftenUseful { + some_field: usize, + last: [u32; 0], +} +``` \ No newline at end of file diff --git a/src/docs/trait_duplication_in_bounds.txt b/src/docs/trait_duplication_in_bounds.txt new file mode 100644 index 00000000000..509736bb364 --- /dev/null +++ b/src/docs/trait_duplication_in_bounds.txt @@ -0,0 +1,37 @@ +### What it does +Checks for cases where generics are being used and multiple +syntax specifications for trait bounds are used simultaneously. + +### Why is this bad? +Duplicate bounds makes the code +less readable than specifying them only once. + +### Example +``` +fn func(arg: T) where T: Clone + Default {} +``` + +Use instead: +``` +fn func(arg: T) {} + +// or + +fn func(arg: T) where T: Clone + Default {} +``` + +``` +fn foo(bar: T) {} +``` +Use instead: +``` +fn foo(bar: T) {} +``` + +``` +fn foo(bar: T) where T: Default + Default {} +``` +Use instead: +``` +fn foo(bar: T) where T: Default {} +``` \ No newline at end of file diff --git a/src/docs/transmute_bytes_to_str.txt b/src/docs/transmute_bytes_to_str.txt new file mode 100644 index 00000000000..75889b9c73a --- /dev/null +++ b/src/docs/transmute_bytes_to_str.txt @@ -0,0 +1,27 @@ +### What it does +Checks for transmutes from a `&[u8]` to a `&str`. + +### Why is this bad? +Not every byte slice is a valid UTF-8 string. + +### Known problems +- [`from_utf8`] which this lint suggests using is slower than `transmute` +as it needs to validate the input. +If you are certain that the input is always a valid UTF-8, +use [`from_utf8_unchecked`] which is as fast as `transmute` +but has a semantically meaningful name. +- You might want to handle errors returned from [`from_utf8`] instead of calling `unwrap`. + +[`from_utf8`]: https://doc.rust-lang.org/std/str/fn.from_utf8.html +[`from_utf8_unchecked`]: https://doc.rust-lang.org/std/str/fn.from_utf8_unchecked.html + +### Example +``` +let b: &[u8] = &[1_u8, 2_u8]; +unsafe { + let _: &str = std::mem::transmute(b); // where b: &[u8] +} + +// should be: +let _ = std::str::from_utf8(b).unwrap(); +``` \ No newline at end of file diff --git a/src/docs/transmute_float_to_int.txt b/src/docs/transmute_float_to_int.txt new file mode 100644 index 00000000000..1877e5a465a --- /dev/null +++ b/src/docs/transmute_float_to_int.txt @@ -0,0 +1,16 @@ +### What it does +Checks for transmutes from a float to an integer. + +### Why is this bad? +Transmutes are dangerous and error-prone, whereas `to_bits` is intuitive +and safe. + +### Example +``` +unsafe { + let _: u32 = std::mem::transmute(1f32); +} + +// should be: +let _: u32 = 1f32.to_bits(); +``` \ No newline at end of file diff --git a/src/docs/transmute_int_to_bool.txt b/src/docs/transmute_int_to_bool.txt new file mode 100644 index 00000000000..07c10f8d0bc --- /dev/null +++ b/src/docs/transmute_int_to_bool.txt @@ -0,0 +1,16 @@ +### What it does +Checks for transmutes from an integer to a `bool`. + +### Why is this bad? +This might result in an invalid in-memory representation of a `bool`. + +### Example +``` +let x = 1_u8; +unsafe { + let _: bool = std::mem::transmute(x); // where x: u8 +} + +// should be: +let _: bool = x != 0; +``` \ No newline at end of file diff --git a/src/docs/transmute_int_to_char.txt b/src/docs/transmute_int_to_char.txt new file mode 100644 index 00000000000..836d22d3f99 --- /dev/null +++ b/src/docs/transmute_int_to_char.txt @@ -0,0 +1,27 @@ +### What it does +Checks for transmutes from an integer to a `char`. + +### Why is this bad? +Not every integer is a Unicode scalar value. + +### Known problems +- [`from_u32`] which this lint suggests using is slower than `transmute` +as it needs to validate the input. +If you are certain that the input is always a valid Unicode scalar value, +use [`from_u32_unchecked`] which is as fast as `transmute` +but has a semantically meaningful name. +- You might want to handle `None` returned from [`from_u32`] instead of calling `unwrap`. + +[`from_u32`]: https://doc.rust-lang.org/std/char/fn.from_u32.html +[`from_u32_unchecked`]: https://doc.rust-lang.org/std/char/fn.from_u32_unchecked.html + +### Example +``` +let x = 1_u32; +unsafe { + let _: char = std::mem::transmute(x); // where x: u32 +} + +// should be: +let _ = std::char::from_u32(x).unwrap(); +``` \ No newline at end of file diff --git a/src/docs/transmute_int_to_float.txt b/src/docs/transmute_int_to_float.txt new file mode 100644 index 00000000000..75cdc62e972 --- /dev/null +++ b/src/docs/transmute_int_to_float.txt @@ -0,0 +1,16 @@ +### What it does +Checks for transmutes from an integer to a float. + +### Why is this bad? +Transmutes are dangerous and error-prone, whereas `from_bits` is intuitive +and safe. + +### Example +``` +unsafe { + let _: f32 = std::mem::transmute(1_u32); // where x: u32 +} + +// should be: +let _: f32 = f32::from_bits(1_u32); +``` \ No newline at end of file diff --git a/src/docs/transmute_num_to_bytes.txt b/src/docs/transmute_num_to_bytes.txt new file mode 100644 index 00000000000..a2c39a1b947 --- /dev/null +++ b/src/docs/transmute_num_to_bytes.txt @@ -0,0 +1,16 @@ +### What it does +Checks for transmutes from a number to an array of `u8` + +### Why this is bad? +Transmutes are dangerous and error-prone, whereas `to_ne_bytes` +is intuitive and safe. + +### Example +``` +unsafe { + let x: [u8; 8] = std::mem::transmute(1i64); +} + +// should be +let x: [u8; 8] = 0i64.to_ne_bytes(); +``` \ No newline at end of file diff --git a/src/docs/transmute_ptr_to_ptr.txt b/src/docs/transmute_ptr_to_ptr.txt new file mode 100644 index 00000000000..65777db9861 --- /dev/null +++ b/src/docs/transmute_ptr_to_ptr.txt @@ -0,0 +1,21 @@ +### What it does +Checks for transmutes from a pointer to a pointer, or +from a reference to a reference. + +### Why is this bad? +Transmutes are dangerous, and these can instead be +written as casts. + +### Example +``` +let ptr = &1u32 as *const u32; +unsafe { + // pointer-to-pointer transmute + let _: *const f32 = std::mem::transmute(ptr); + // ref-ref transmute + let _: &f32 = std::mem::transmute(&1u32); +} +// These can be respectively written: +let _ = ptr as *const f32; +let _ = unsafe{ &*(&1u32 as *const u32 as *const f32) }; +``` \ No newline at end of file diff --git a/src/docs/transmute_ptr_to_ref.txt b/src/docs/transmute_ptr_to_ref.txt new file mode 100644 index 00000000000..aca550f5036 --- /dev/null +++ b/src/docs/transmute_ptr_to_ref.txt @@ -0,0 +1,21 @@ +### What it does +Checks for transmutes from a pointer to a reference. + +### Why is this bad? +This can always be rewritten with `&` and `*`. + +### Known problems +- `mem::transmute` in statics and constants is stable from Rust 1.46.0, +while dereferencing raw pointer is not stable yet. +If you need to do this in those places, +you would have to use `transmute` instead. + +### Example +``` +unsafe { + let _: &T = std::mem::transmute(p); // where p: *const T +} + +// can be written: +let _: &T = &*p; +``` \ No newline at end of file diff --git a/src/docs/transmute_undefined_repr.txt b/src/docs/transmute_undefined_repr.txt new file mode 100644 index 00000000000..5ee6aaf4ca9 --- /dev/null +++ b/src/docs/transmute_undefined_repr.txt @@ -0,0 +1,22 @@ +### What it does +Checks for transmutes between types which do not have a representation defined relative to +each other. + +### Why is this bad? +The results of such a transmute are not defined. + +### Known problems +This lint has had multiple problems in the past and was moved to `nursery`. See issue +[#8496](https://github.com/rust-lang/rust-clippy/issues/8496) for more details. + +### Example +``` +struct Foo(u32, T); +let _ = unsafe { core::mem::transmute::, Foo>(Foo(0u32, 0u32)) }; +``` +Use instead: +``` +#[repr(C)] +struct Foo(u32, T); +let _ = unsafe { core::mem::transmute::, Foo>(Foo(0u32, 0u32)) }; +``` \ No newline at end of file diff --git a/src/docs/transmutes_expressible_as_ptr_casts.txt b/src/docs/transmutes_expressible_as_ptr_casts.txt new file mode 100644 index 00000000000..b68a8cda9c7 --- /dev/null +++ b/src/docs/transmutes_expressible_as_ptr_casts.txt @@ -0,0 +1,16 @@ +### What it does +Checks for transmutes that could be a pointer cast. + +### Why is this bad? +Readability. The code tricks people into thinking that +something complex is going on. + +### Example + +``` +unsafe { std::mem::transmute::<*const [i32], *const [u16]>(p) }; +``` +Use instead: +``` +p as *const [u16]; +``` \ No newline at end of file diff --git a/src/docs/transmuting_null.txt b/src/docs/transmuting_null.txt new file mode 100644 index 00000000000..f8bacfc0b90 --- /dev/null +++ b/src/docs/transmuting_null.txt @@ -0,0 +1,15 @@ +### What it does +Checks for transmute calls which would receive a null pointer. + +### Why is this bad? +Transmuting a null pointer is undefined behavior. + +### Known problems +Not all cases can be detected at the moment of this writing. +For example, variables which hold a null pointer and are then fed to a `transmute` +call, aren't detectable yet. + +### Example +``` +let null_ref: &u64 = unsafe { std::mem::transmute(0 as *const u64) }; +``` \ No newline at end of file diff --git a/src/docs/trim_split_whitespace.txt b/src/docs/trim_split_whitespace.txt new file mode 100644 index 00000000000..f7e3e7858f9 --- /dev/null +++ b/src/docs/trim_split_whitespace.txt @@ -0,0 +1,14 @@ +### What it does +Warns about calling `str::trim` (or variants) before `str::split_whitespace`. + +### Why is this bad? +`split_whitespace` already ignores leading and trailing whitespace. + +### Example +``` +" A B C ".trim().split_whitespace(); +``` +Use instead: +``` +" A B C ".split_whitespace(); +``` \ No newline at end of file diff --git a/src/docs/trivial_regex.txt b/src/docs/trivial_regex.txt new file mode 100644 index 00000000000..f71d667fd77 --- /dev/null +++ b/src/docs/trivial_regex.txt @@ -0,0 +1,18 @@ +### What it does +Checks for trivial [regex](https://crates.io/crates/regex) +creation (with `Regex::new`, `RegexBuilder::new`, or `RegexSet::new`). + +### Why is this bad? +Matching the regex can likely be replaced by `==` or +`str::starts_with`, `str::ends_with` or `std::contains` or other `str` +methods. + +### Known problems +If the same regex is going to be applied to multiple +inputs, the precomputations done by `Regex` construction can give +significantly better performance than any of the `str`-based methods. + +### Example +``` +Regex::new("^foobar") +``` \ No newline at end of file diff --git a/src/docs/trivially_copy_pass_by_ref.txt b/src/docs/trivially_copy_pass_by_ref.txt new file mode 100644 index 00000000000..f54cce5e2bd --- /dev/null +++ b/src/docs/trivially_copy_pass_by_ref.txt @@ -0,0 +1,43 @@ +### What it does +Checks for functions taking arguments by reference, where +the argument type is `Copy` and small enough to be more efficient to always +pass by value. + +### Why is this bad? +In many calling conventions instances of structs will +be passed through registers if they fit into two or less general purpose +registers. + +### Known problems +This lint is target register size dependent, it is +limited to 32-bit to try and reduce portability problems between 32 and +64-bit, but if you are compiling for 8 or 16-bit targets then the limit +will be different. + +The configuration option `trivial_copy_size_limit` can be set to override +this limit for a project. + +This lint attempts to allow passing arguments by reference if a reference +to that argument is returned. This is implemented by comparing the lifetime +of the argument and return value for equality. However, this can cause +false positives in cases involving multiple lifetimes that are bounded by +each other. + +Also, it does not take account of other similar cases where getting memory addresses +matters; namely, returning the pointer to the argument in question, +and passing the argument, as both references and pointers, +to a function that needs the memory address. For further details, refer to +[this issue](https://github.com/rust-lang/rust-clippy/issues/5953) +that explains a real case in which this false positive +led to an **undefined behavior** introduced with unsafe code. + +### Example + +``` +fn foo(v: &u32) {} +``` + +Use instead: +``` +fn foo(v: u32) {} +``` \ No newline at end of file diff --git a/src/docs/try_err.txt b/src/docs/try_err.txt new file mode 100644 index 00000000000..e3d4ef3a09d --- /dev/null +++ b/src/docs/try_err.txt @@ -0,0 +1,28 @@ +### What it does +Checks for usages of `Err(x)?`. + +### Why is this bad? +The `?` operator is designed to allow calls that +can fail to be easily chained. For example, `foo()?.bar()` or +`foo(bar()?)`. Because `Err(x)?` can't be used that way (it will +always return), it is more clear to write `return Err(x)`. + +### Example +``` +fn foo(fail: bool) -> Result { + if fail { + Err("failed")?; + } + Ok(0) +} +``` +Could be written: + +``` +fn foo(fail: bool) -> Result { + if fail { + return Err("failed".into()); + } + Ok(0) +} +``` \ No newline at end of file diff --git a/src/docs/type_complexity.txt b/src/docs/type_complexity.txt new file mode 100644 index 00000000000..69cd8750050 --- /dev/null +++ b/src/docs/type_complexity.txt @@ -0,0 +1,14 @@ +### What it does +Checks for types used in structs, parameters and `let` +declarations above a certain complexity threshold. + +### Why is this bad? +Too complex types make the code less readable. Consider +using a `type` definition to simplify them. + +### Example +``` +struct Foo { + inner: Rc>>>, +} +``` \ No newline at end of file diff --git a/src/docs/type_repetition_in_bounds.txt b/src/docs/type_repetition_in_bounds.txt new file mode 100644 index 00000000000..18ed372fd13 --- /dev/null +++ b/src/docs/type_repetition_in_bounds.txt @@ -0,0 +1,16 @@ +### What it does +This lint warns about unnecessary type repetitions in trait bounds + +### Why is this bad? +Repeating the type for every bound makes the code +less readable than combining the bounds + +### Example +``` +pub fn foo(t: T) where T: Copy, T: Clone {} +``` + +Use instead: +``` +pub fn foo(t: T) where T: Copy + Clone {} +``` \ No newline at end of file diff --git a/src/docs/undocumented_unsafe_blocks.txt b/src/docs/undocumented_unsafe_blocks.txt new file mode 100644 index 00000000000..f3af4753c5f --- /dev/null +++ b/src/docs/undocumented_unsafe_blocks.txt @@ -0,0 +1,43 @@ +### What it does +Checks for `unsafe` blocks and impls without a `// SAFETY: ` comment +explaining why the unsafe operations performed inside +the block are safe. + +Note the comment must appear on the line(s) preceding the unsafe block +with nothing appearing in between. The following is ok: +``` +foo( + // SAFETY: + // This is a valid safety comment + unsafe { *x } +) +``` +But neither of these are: +``` +// SAFETY: +// This is not a valid safety comment +foo( + /* SAFETY: Neither is this */ unsafe { *x }, +); +``` + +### Why is this bad? +Undocumented unsafe blocks and impls can make it difficult to +read and maintain code, as well as uncover unsoundness +and bugs. + +### Example +``` +use std::ptr::NonNull; +let a = &mut 42; + +let ptr = unsafe { NonNull::new_unchecked(a) }; +``` +Use instead: +``` +use std::ptr::NonNull; +let a = &mut 42; + +// SAFETY: references are guaranteed to be non-null. +let ptr = unsafe { NonNull::new_unchecked(a) }; +``` \ No newline at end of file diff --git a/src/docs/undropped_manually_drops.txt b/src/docs/undropped_manually_drops.txt new file mode 100644 index 00000000000..85e3ec56653 --- /dev/null +++ b/src/docs/undropped_manually_drops.txt @@ -0,0 +1,22 @@ +### What it does +Prevents the safe `std::mem::drop` function from being called on `std::mem::ManuallyDrop`. + +### Why is this bad? +The safe `drop` function does not drop the inner value of a `ManuallyDrop`. + +### Known problems +Does not catch cases if the user binds `std::mem::drop` +to a different name and calls it that way. + +### Example +``` +struct S; +drop(std::mem::ManuallyDrop::new(S)); +``` +Use instead: +``` +struct S; +unsafe { + std::mem::ManuallyDrop::drop(&mut std::mem::ManuallyDrop::new(S)); +} +``` \ No newline at end of file diff --git a/src/docs/unicode_not_nfc.txt b/src/docs/unicode_not_nfc.txt new file mode 100644 index 00000000000..c660c51dadb --- /dev/null +++ b/src/docs/unicode_not_nfc.txt @@ -0,0 +1,12 @@ +### What it does +Checks for string literals that contain Unicode in a form +that is not equal to its +[NFC-recomposition](http://www.unicode.org/reports/tr15/#Norm_Forms). + +### Why is this bad? +If such a string is compared to another, the results +may be surprising. + +### Example +You may not see it, but "à"" and "à"" aren't the same string. The +former when escaped is actually `"a\u{300}"` while the latter is `"\u{e0}"`. \ No newline at end of file diff --git a/src/docs/unimplemented.txt b/src/docs/unimplemented.txt new file mode 100644 index 00000000000..7095594fb2e --- /dev/null +++ b/src/docs/unimplemented.txt @@ -0,0 +1,10 @@ +### What it does +Checks for usage of `unimplemented!`. + +### Why is this bad? +This macro should not be present in production code + +### Example +``` +unimplemented!(); +``` \ No newline at end of file diff --git a/src/docs/uninit_assumed_init.txt b/src/docs/uninit_assumed_init.txt new file mode 100644 index 00000000000..cca24093d40 --- /dev/null +++ b/src/docs/uninit_assumed_init.txt @@ -0,0 +1,28 @@ +### What it does +Checks for `MaybeUninit::uninit().assume_init()`. + +### Why is this bad? +For most types, this is undefined behavior. + +### Known problems +For now, we accept empty tuples and tuples / arrays +of `MaybeUninit`. There may be other types that allow uninitialized +data, but those are not yet rigorously defined. + +### Example +``` +// Beware the UB +use std::mem::MaybeUninit; + +let _: usize = unsafe { MaybeUninit::uninit().assume_init() }; +``` + +Note that the following is OK: + +``` +use std::mem::MaybeUninit; + +let _: [MaybeUninit; 5] = unsafe { + MaybeUninit::uninit().assume_init() +}; +``` \ No newline at end of file diff --git a/src/docs/uninit_vec.txt b/src/docs/uninit_vec.txt new file mode 100644 index 00000000000..cd50afe78f6 --- /dev/null +++ b/src/docs/uninit_vec.txt @@ -0,0 +1,41 @@ +### What it does +Checks for `set_len()` call that creates `Vec` with uninitialized elements. +This is commonly caused by calling `set_len()` right after allocating or +reserving a buffer with `new()`, `default()`, `with_capacity()`, or `reserve()`. + +### Why is this bad? +It creates a `Vec` with uninitialized data, which leads to +undefined behavior with most safe operations. Notably, uninitialized +`Vec` must not be used with generic `Read`. + +Moreover, calling `set_len()` on a `Vec` created with `new()` or `default()` +creates out-of-bound values that lead to heap memory corruption when used. + +### Known Problems +This lint only checks directly adjacent statements. + +### Example +``` +let mut vec: Vec = Vec::with_capacity(1000); +unsafe { vec.set_len(1000); } +reader.read(&mut vec); // undefined behavior! +``` + +### How to fix? +1. Use an initialized buffer: + ```rust,ignore + let mut vec: Vec = vec![0; 1000]; + reader.read(&mut vec); + ``` +2. Wrap the content in `MaybeUninit`: + ```rust,ignore + let mut vec: Vec> = Vec::with_capacity(1000); + vec.set_len(1000); // `MaybeUninit` can be uninitialized + ``` +3. If you are on 1.60.0 or later, `Vec::spare_capacity_mut()` is available: + ```rust,ignore + let mut vec: Vec = Vec::with_capacity(1000); + let remaining = vec.spare_capacity_mut(); // `&mut [MaybeUninit]` + // perform initialization with `remaining` + vec.set_len(...); // Safe to call `set_len()` on initialized part + ``` \ No newline at end of file diff --git a/src/docs/unit_arg.txt b/src/docs/unit_arg.txt new file mode 100644 index 00000000000..eb83403bb27 --- /dev/null +++ b/src/docs/unit_arg.txt @@ -0,0 +1,14 @@ +### What it does +Checks for passing a unit value as an argument to a function without using a +unit literal (`()`). + +### Why is this bad? +This is likely the result of an accidental semicolon. + +### Example +``` +foo({ + let a = bar(); + baz(a); +}) +``` \ No newline at end of file diff --git a/src/docs/unit_cmp.txt b/src/docs/unit_cmp.txt new file mode 100644 index 00000000000..6f3d62010dc --- /dev/null +++ b/src/docs/unit_cmp.txt @@ -0,0 +1,33 @@ +### What it does +Checks for comparisons to unit. This includes all binary +comparisons (like `==` and `<`) and asserts. + +### Why is this bad? +Unit is always equal to itself, and thus is just a +clumsily written constant. Mostly this happens when someone accidentally +adds semicolons at the end of the operands. + +### Example +``` +if { + foo(); +} == { + bar(); +} { + baz(); +} +``` +is equal to +``` +{ + foo(); + bar(); + baz(); +} +``` + +For asserts: +``` +assert_eq!({ foo(); }, { bar(); }); +``` +will always succeed \ No newline at end of file diff --git a/src/docs/unit_hash.txt b/src/docs/unit_hash.txt new file mode 100644 index 00000000000..a22d2994602 --- /dev/null +++ b/src/docs/unit_hash.txt @@ -0,0 +1,20 @@ +### What it does +Detects `().hash(_)`. + +### Why is this bad? +Hashing a unit value doesn't do anything as the implementation of `Hash` for `()` is a no-op. + +### Example +``` +match my_enum { + Empty => ().hash(&mut state), + WithValue(x) => x.hash(&mut state), +} +``` +Use instead: +``` +match my_enum { + Empty => 0_u8.hash(&mut state), + WithValue(x) => x.hash(&mut state), +} +``` \ No newline at end of file diff --git a/src/docs/unit_return_expecting_ord.txt b/src/docs/unit_return_expecting_ord.txt new file mode 100644 index 00000000000..781feac5afc --- /dev/null +++ b/src/docs/unit_return_expecting_ord.txt @@ -0,0 +1,20 @@ +### What it does +Checks for functions that expect closures of type +Fn(...) -> Ord where the implemented closure returns the unit type. +The lint also suggests to remove the semi-colon at the end of the statement if present. + +### Why is this bad? +Likely, returning the unit type is unintentional, and +could simply be caused by an extra semi-colon. Since () implements Ord +it doesn't cause a compilation error. +This is the same reasoning behind the unit_cmp lint. + +### Known problems +If returning unit is intentional, then there is no +way of specifying this without triggering needless_return lint + +### Example +``` +let mut twins = vec!((1, 1), (2, 2)); +twins.sort_by_key(|x| { x.1; }); +``` \ No newline at end of file diff --git a/src/docs/unnecessary_cast.txt b/src/docs/unnecessary_cast.txt new file mode 100644 index 00000000000..603f2606099 --- /dev/null +++ b/src/docs/unnecessary_cast.txt @@ -0,0 +1,19 @@ +### What it does +Checks for casts to the same type, casts of int literals to integer types +and casts of float literals to float types. + +### Why is this bad? +It's just unnecessary. + +### Example +``` +let _ = 2i32 as i32; +let _ = 0.5 as f32; +``` + +Better: + +``` +let _ = 2_i32; +let _ = 0.5_f32; +``` \ No newline at end of file diff --git a/src/docs/unnecessary_filter_map.txt b/src/docs/unnecessary_filter_map.txt new file mode 100644 index 00000000000..b19341ecf66 --- /dev/null +++ b/src/docs/unnecessary_filter_map.txt @@ -0,0 +1,23 @@ +### What it does +Checks for `filter_map` calls that could be replaced by `filter` or `map`. +More specifically it checks if the closure provided is only performing one of the +filter or map operations and suggests the appropriate option. + +### Why is this bad? +Complexity. The intent is also clearer if only a single +operation is being performed. + +### Example +``` +let _ = (0..3).filter_map(|x| if x > 2 { Some(x) } else { None }); + +// As there is no transformation of the argument this could be written as: +let _ = (0..3).filter(|&x| x > 2); +``` + +``` +let _ = (0..4).filter_map(|x| Some(x + 1)); + +// As there is no conditional check on the argument this could be written as: +let _ = (0..4).map(|x| x + 1); +``` \ No newline at end of file diff --git a/src/docs/unnecessary_find_map.txt b/src/docs/unnecessary_find_map.txt new file mode 100644 index 00000000000..f9444dc48ad --- /dev/null +++ b/src/docs/unnecessary_find_map.txt @@ -0,0 +1,23 @@ +### What it does +Checks for `find_map` calls that could be replaced by `find` or `map`. More +specifically it checks if the closure provided is only performing one of the +find or map operations and suggests the appropriate option. + +### Why is this bad? +Complexity. The intent is also clearer if only a single +operation is being performed. + +### Example +``` +let _ = (0..3).find_map(|x| if x > 2 { Some(x) } else { None }); + +// As there is no transformation of the argument this could be written as: +let _ = (0..3).find(|&x| x > 2); +``` + +``` +let _ = (0..4).find_map(|x| Some(x + 1)); + +// As there is no conditional check on the argument this could be written as: +let _ = (0..4).map(|x| x + 1).next(); +``` \ No newline at end of file diff --git a/src/docs/unnecessary_fold.txt b/src/docs/unnecessary_fold.txt new file mode 100644 index 00000000000..e1b0e65f519 --- /dev/null +++ b/src/docs/unnecessary_fold.txt @@ -0,0 +1,17 @@ +### What it does +Checks for using `fold` when a more succinct alternative exists. +Specifically, this checks for `fold`s which could be replaced by `any`, `all`, +`sum` or `product`. + +### Why is this bad? +Readability. + +### Example +``` +(0..3).fold(false, |acc, x| acc || x > 2); +``` + +Use instead: +``` +(0..3).any(|x| x > 2); +``` \ No newline at end of file diff --git a/src/docs/unnecessary_join.txt b/src/docs/unnecessary_join.txt new file mode 100644 index 00000000000..ee4e78601f8 --- /dev/null +++ b/src/docs/unnecessary_join.txt @@ -0,0 +1,25 @@ +### What it does +Checks for use of `.collect::>().join("")` on iterators. + +### Why is this bad? +`.collect::()` is more concise and might be more performant + +### Example +``` +let vector = vec!["hello", "world"]; +let output = vector.iter().map(|item| item.to_uppercase()).collect::>().join(""); +println!("{}", output); +``` +The correct use would be: +``` +let vector = vec!["hello", "world"]; +let output = vector.iter().map(|item| item.to_uppercase()).collect::(); +println!("{}", output); +``` +### Known problems +While `.collect::()` is sometimes more performant, there are cases where +using `.collect::()` over `.collect::>().join("")` +will prevent loop unrolling and will result in a negative performance impact. + +Additionally, differences have been observed between aarch64 and x86_64 assembly output, +with aarch64 tending to producing faster assembly in more cases when using `.collect::()` \ No newline at end of file diff --git a/src/docs/unnecessary_lazy_evaluations.txt b/src/docs/unnecessary_lazy_evaluations.txt new file mode 100644 index 00000000000..208188ce971 --- /dev/null +++ b/src/docs/unnecessary_lazy_evaluations.txt @@ -0,0 +1,32 @@ +### What it does +As the counterpart to `or_fun_call`, this lint looks for unnecessary +lazily evaluated closures on `Option` and `Result`. + +This lint suggests changing the following functions, when eager evaluation results in +simpler code: + - `unwrap_or_else` to `unwrap_or` + - `and_then` to `and` + - `or_else` to `or` + - `get_or_insert_with` to `get_or_insert` + - `ok_or_else` to `ok_or` + +### Why is this bad? +Using eager evaluation is shorter and simpler in some cases. + +### Known problems +It is possible, but not recommended for `Deref` and `Index` to have +side effects. Eagerly evaluating them can change the semantics of the program. + +### Example +``` +// example code where clippy issues a warning +let opt: Option = None; + +opt.unwrap_or_else(|| 42); +``` +Use instead: +``` +let opt: Option = None; + +opt.unwrap_or(42); +``` \ No newline at end of file diff --git a/src/docs/unnecessary_mut_passed.txt b/src/docs/unnecessary_mut_passed.txt new file mode 100644 index 00000000000..2f8bdd113df --- /dev/null +++ b/src/docs/unnecessary_mut_passed.txt @@ -0,0 +1,17 @@ +### What it does +Detects passing a mutable reference to a function that only +requires an immutable reference. + +### Why is this bad? +The mutable reference rules out all other references to +the value. Also the code misleads about the intent of the call site. + +### Example +``` +vec.push(&mut value); +``` + +Use instead: +``` +vec.push(&value); +``` \ No newline at end of file diff --git a/src/docs/unnecessary_operation.txt b/src/docs/unnecessary_operation.txt new file mode 100644 index 00000000000..7f455e264cb --- /dev/null +++ b/src/docs/unnecessary_operation.txt @@ -0,0 +1,12 @@ +### What it does +Checks for expression statements that can be reduced to a +sub-expression. + +### Why is this bad? +Expressions by themselves often have no side-effects. +Having such expressions reduces readability. + +### Example +``` +compute_array()[0]; +``` \ No newline at end of file diff --git a/src/docs/unnecessary_owned_empty_strings.txt b/src/docs/unnecessary_owned_empty_strings.txt new file mode 100644 index 00000000000..8cd9fba603e --- /dev/null +++ b/src/docs/unnecessary_owned_empty_strings.txt @@ -0,0 +1,16 @@ +### What it does + +Detects cases of owned empty strings being passed as an argument to a function expecting `&str` + +### Why is this bad? + +This results in longer and less readable code + +### Example +``` +vec!["1", "2", "3"].join(&String::new()); +``` +Use instead: +``` +vec!["1", "2", "3"].join(""); +``` \ No newline at end of file diff --git a/src/docs/unnecessary_self_imports.txt b/src/docs/unnecessary_self_imports.txt new file mode 100644 index 00000000000..b909cd5a76d --- /dev/null +++ b/src/docs/unnecessary_self_imports.txt @@ -0,0 +1,19 @@ +### What it does +Checks for imports ending in `::{self}`. + +### Why is this bad? +In most cases, this can be written much more cleanly by omitting `::{self}`. + +### Known problems +Removing `::{self}` will cause any non-module items at the same path to also be imported. +This might cause a naming conflict (https://github.com/rust-lang/rustfmt/issues/3568). This lint makes no attempt +to detect this scenario and that is why it is a restriction lint. + +### Example +``` +use std::io::{self}; +``` +Use instead: +``` +use std::io; +``` \ No newline at end of file diff --git a/src/docs/unnecessary_sort_by.txt b/src/docs/unnecessary_sort_by.txt new file mode 100644 index 00000000000..6913b62c48e --- /dev/null +++ b/src/docs/unnecessary_sort_by.txt @@ -0,0 +1,21 @@ +### What it does +Detects uses of `Vec::sort_by` passing in a closure +which compares the two arguments, either directly or indirectly. + +### Why is this bad? +It is more clear to use `Vec::sort_by_key` (or `Vec::sort` if +possible) than to use `Vec::sort_by` and a more complicated +closure. + +### Known problems +If the suggested `Vec::sort_by_key` uses Reverse and it isn't already +imported by a use statement, then it will need to be added manually. + +### Example +``` +vec.sort_by(|a, b| a.foo().cmp(&b.foo())); +``` +Use instead: +``` +vec.sort_by_key(|a| a.foo()); +``` \ No newline at end of file diff --git a/src/docs/unnecessary_to_owned.txt b/src/docs/unnecessary_to_owned.txt new file mode 100644 index 00000000000..5d4213bdaf8 --- /dev/null +++ b/src/docs/unnecessary_to_owned.txt @@ -0,0 +1,24 @@ +### What it does +Checks for unnecessary calls to [`ToOwned::to_owned`](https://doc.rust-lang.org/std/borrow/trait.ToOwned.html#tymethod.to_owned) +and other `to_owned`-like functions. + +### Why is this bad? +The unnecessary calls result in useless allocations. + +### Known problems +`unnecessary_to_owned` can falsely trigger if `IntoIterator::into_iter` is applied to an +owned copy of a resource and the resource is later used mutably. See +[#8148](https://github.com/rust-lang/rust-clippy/issues/8148). + +### Example +``` +let path = std::path::Path::new("x"); +foo(&path.to_string_lossy().to_string()); +fn foo(s: &str) {} +``` +Use instead: +``` +let path = std::path::Path::new("x"); +foo(&path.to_string_lossy()); +fn foo(s: &str) {} +``` \ No newline at end of file diff --git a/src/docs/unnecessary_unwrap.txt b/src/docs/unnecessary_unwrap.txt new file mode 100644 index 00000000000..50ae845bb44 --- /dev/null +++ b/src/docs/unnecessary_unwrap.txt @@ -0,0 +1,20 @@ +### What it does +Checks for calls of `unwrap[_err]()` that cannot fail. + +### Why is this bad? +Using `if let` or `match` is more idiomatic. + +### Example +``` +if option.is_some() { + do_something_with(option.unwrap()) +} +``` + +Could be written: + +``` +if let Some(value) = option { + do_something_with(value) +} +``` \ No newline at end of file diff --git a/src/docs/unnecessary_wraps.txt b/src/docs/unnecessary_wraps.txt new file mode 100644 index 00000000000..c0a23d49288 --- /dev/null +++ b/src/docs/unnecessary_wraps.txt @@ -0,0 +1,36 @@ +### What it does +Checks for private functions that only return `Ok` or `Some`. + +### Why is this bad? +It is not meaningful to wrap values when no `None` or `Err` is returned. + +### Known problems +There can be false positives if the function signature is designed to +fit some external requirement. + +### Example +``` +fn get_cool_number(a: bool, b: bool) -> Option { + if a && b { + return Some(50); + } + if a { + Some(0) + } else { + Some(10) + } +} +``` +Use instead: +``` +fn get_cool_number(a: bool, b: bool) -> i32 { + if a && b { + return 50; + } + if a { + 0 + } else { + 10 + } +} +``` \ No newline at end of file diff --git a/src/docs/unneeded_field_pattern.txt b/src/docs/unneeded_field_pattern.txt new file mode 100644 index 00000000000..3cd00a0f3e3 --- /dev/null +++ b/src/docs/unneeded_field_pattern.txt @@ -0,0 +1,26 @@ +### What it does +Checks for structure field patterns bound to wildcards. + +### Why is this bad? +Using `..` instead is shorter and leaves the focus on +the fields that are actually bound. + +### Example +``` +let f = Foo { a: 0, b: 0, c: 0 }; + +match f { + Foo { a: _, b: 0, .. } => {}, + Foo { a: _, b: _, c: _ } => {}, +} +``` + +Use instead: +``` +let f = Foo { a: 0, b: 0, c: 0 }; + +match f { + Foo { b: 0, .. } => {}, + Foo { .. } => {}, +} +``` \ No newline at end of file diff --git a/src/docs/unneeded_wildcard_pattern.txt b/src/docs/unneeded_wildcard_pattern.txt new file mode 100644 index 00000000000..817061efd16 --- /dev/null +++ b/src/docs/unneeded_wildcard_pattern.txt @@ -0,0 +1,28 @@ +### What it does +Checks for tuple patterns with a wildcard +pattern (`_`) is next to a rest pattern (`..`). + +_NOTE_: While `_, ..` means there is at least one element left, `..` +means there are 0 or more elements left. This can make a difference +when refactoring, but shouldn't result in errors in the refactored code, +since the wildcard pattern isn't used anyway. + +### Why is this bad? +The wildcard pattern is unneeded as the rest pattern +can match that element as well. + +### Example +``` +match t { + TupleStruct(0, .., _) => (), + _ => (), +} +``` + +Use instead: +``` +match t { + TupleStruct(0, ..) => (), + _ => (), +} +``` \ No newline at end of file diff --git a/src/docs/unnested_or_patterns.txt b/src/docs/unnested_or_patterns.txt new file mode 100644 index 00000000000..49c45d4ee5e --- /dev/null +++ b/src/docs/unnested_or_patterns.txt @@ -0,0 +1,22 @@ +### What it does +Checks for unnested or-patterns, e.g., `Some(0) | Some(2)` and +suggests replacing the pattern with a nested one, `Some(0 | 2)`. + +Another way to think of this is that it rewrites patterns in +*disjunctive normal form (DNF)* into *conjunctive normal form (CNF)*. + +### Why is this bad? +In the example above, `Some` is repeated, which unnecessarily complicates the pattern. + +### Example +``` +fn main() { + if let Some(0) | Some(2) = Some(0) {} +} +``` +Use instead: +``` +fn main() { + if let Some(0 | 2) = Some(0) {} +} +``` \ No newline at end of file diff --git a/src/docs/unreachable.txt b/src/docs/unreachable.txt new file mode 100644 index 00000000000..10469ca7745 --- /dev/null +++ b/src/docs/unreachable.txt @@ -0,0 +1,10 @@ +### What it does +Checks for usage of `unreachable!`. + +### Why is this bad? +This macro can cause code to panic + +### Example +``` +unreachable!(); +``` \ No newline at end of file diff --git a/src/docs/unreadable_literal.txt b/src/docs/unreadable_literal.txt new file mode 100644 index 00000000000..e168f90a84c --- /dev/null +++ b/src/docs/unreadable_literal.txt @@ -0,0 +1,16 @@ +### What it does +Warns if a long integral or floating-point constant does +not contain underscores. + +### Why is this bad? +Reading long numbers is difficult without separators. + +### Example +``` +61864918973511 +``` + +Use instead: +``` +61_864_918_973_511 +``` \ No newline at end of file diff --git a/src/docs/unsafe_derive_deserialize.txt b/src/docs/unsafe_derive_deserialize.txt new file mode 100644 index 00000000000..f56c48044f4 --- /dev/null +++ b/src/docs/unsafe_derive_deserialize.txt @@ -0,0 +1,27 @@ +### What it does +Checks for deriving `serde::Deserialize` on a type that +has methods using `unsafe`. + +### Why is this bad? +Deriving `serde::Deserialize` will create a constructor +that may violate invariants hold by another constructor. + +### Example +``` +use serde::Deserialize; + +#[derive(Deserialize)] +pub struct Foo { + // .. +} + +impl Foo { + pub fn new() -> Self { + // setup here .. + } + + pub unsafe fn parts() -> (&str, &str) { + // assumes invariants hold + } +} +``` \ No newline at end of file diff --git a/src/docs/unsafe_removed_from_name.txt b/src/docs/unsafe_removed_from_name.txt new file mode 100644 index 00000000000..6f55c1815dd --- /dev/null +++ b/src/docs/unsafe_removed_from_name.txt @@ -0,0 +1,15 @@ +### What it does +Checks for imports that remove "unsafe" from an item's +name. + +### Why is this bad? +Renaming makes it less clear which traits and +structures are unsafe. + +### Example +``` +use std::cell::{UnsafeCell as TotallySafeCell}; + +extern crate crossbeam; +use crossbeam::{spawn_unsafe as spawn}; +``` \ No newline at end of file diff --git a/src/docs/unseparated_literal_suffix.txt b/src/docs/unseparated_literal_suffix.txt new file mode 100644 index 00000000000..d80248e34d0 --- /dev/null +++ b/src/docs/unseparated_literal_suffix.txt @@ -0,0 +1,18 @@ +### What it does +Warns if literal suffixes are not separated by an +underscore. +To enforce unseparated literal suffix style, +see the `separated_literal_suffix` lint. + +### Why is this bad? +Suffix style should be consistent. + +### Example +``` +123832i32 +``` + +Use instead: +``` +123832_i32 +``` \ No newline at end of file diff --git a/src/docs/unsound_collection_transmute.txt b/src/docs/unsound_collection_transmute.txt new file mode 100644 index 00000000000..29db9258e83 --- /dev/null +++ b/src/docs/unsound_collection_transmute.txt @@ -0,0 +1,25 @@ +### What it does +Checks for transmutes between collections whose +types have different ABI, size or alignment. + +### Why is this bad? +This is undefined behavior. + +### Known problems +Currently, we cannot know whether a type is a +collection, so we just lint the ones that come with `std`. + +### Example +``` +// different size, therefore likely out-of-bounds memory access +// You absolutely do not want this in your code! +unsafe { + std::mem::transmute::<_, Vec>(vec![2_u16]) +}; +``` + +You must always iterate, map and collect the values: + +``` +vec![2_u16].into_iter().map(u32::from).collect::>(); +``` \ No newline at end of file diff --git a/src/docs/unused_async.txt b/src/docs/unused_async.txt new file mode 100644 index 00000000000..26def11aa17 --- /dev/null +++ b/src/docs/unused_async.txt @@ -0,0 +1,23 @@ +### What it does +Checks for functions that are declared `async` but have no `.await`s inside of them. + +### Why is this bad? +Async functions with no async code create overhead, both mentally and computationally. +Callers of async methods either need to be calling from an async function themselves or run it on an executor, both of which +causes runtime overhead and hassle for the caller. + +### Example +``` +async fn get_random_number() -> i64 { + 4 // Chosen by fair dice roll. Guaranteed to be random. +} +let number_future = get_random_number(); +``` + +Use instead: +``` +fn get_random_number_improved() -> i64 { + 4 // Chosen by fair dice roll. Guaranteed to be random. +} +let number_future = async { get_random_number_improved() }; +``` \ No newline at end of file diff --git a/src/docs/unused_io_amount.txt b/src/docs/unused_io_amount.txt new file mode 100644 index 00000000000..fbc4c299c7b --- /dev/null +++ b/src/docs/unused_io_amount.txt @@ -0,0 +1,31 @@ +### What it does +Checks for unused written/read amount. + +### Why is this bad? +`io::Write::write(_vectored)` and +`io::Read::read(_vectored)` are not guaranteed to +process the entire buffer. They return how many bytes were processed, which +might be smaller +than a given buffer's length. If you don't need to deal with +partial-write/read, use +`write_all`/`read_exact` instead. + +When working with asynchronous code (either with the `futures` +crate or with `tokio`), a similar issue exists for +`AsyncWriteExt::write()` and `AsyncReadExt::read()` : these +functions are also not guaranteed to process the entire +buffer. Your code should either handle partial-writes/reads, or +call the `write_all`/`read_exact` methods on those traits instead. + +### Known problems +Detects only common patterns. + +### Examples +``` +use std::io; +fn foo(w: &mut W) -> io::Result<()> { + // must be `w.write_all(b"foo")?;` + w.write(b"foo")?; + Ok(()) +} +``` \ No newline at end of file diff --git a/src/docs/unused_peekable.txt b/src/docs/unused_peekable.txt new file mode 100644 index 00000000000..268de1ce3be --- /dev/null +++ b/src/docs/unused_peekable.txt @@ -0,0 +1,26 @@ +### What it does +Checks for the creation of a `peekable` iterator that is never `.peek()`ed + +### Why is this bad? +Creating a peekable iterator without using any of its methods is likely a mistake, +or just a leftover after a refactor. + +### Example +``` +let collection = vec![1, 2, 3]; +let iter = collection.iter().peekable(); + +for item in iter { + // ... +} +``` + +Use instead: +``` +let collection = vec![1, 2, 3]; +let iter = collection.iter(); + +for item in iter { + // ... +} +``` \ No newline at end of file diff --git a/src/docs/unused_rounding.txt b/src/docs/unused_rounding.txt new file mode 100644 index 00000000000..70947aceee7 --- /dev/null +++ b/src/docs/unused_rounding.txt @@ -0,0 +1,17 @@ +### What it does + +Detects cases where a whole-number literal float is being rounded, using +the `floor`, `ceil`, or `round` methods. + +### Why is this bad? + +This is unnecessary and confusing to the reader. Doing this is probably a mistake. + +### Example +``` +let x = 1f32.ceil(); +``` +Use instead: +``` +let x = 1f32; +``` \ No newline at end of file diff --git a/src/docs/unused_self.txt b/src/docs/unused_self.txt new file mode 100644 index 00000000000..a8d0fc75989 --- /dev/null +++ b/src/docs/unused_self.txt @@ -0,0 +1,23 @@ +### What it does +Checks methods that contain a `self` argument but don't use it + +### Why is this bad? +It may be clearer to define the method as an associated function instead +of an instance method if it doesn't require `self`. + +### Example +``` +struct A; +impl A { + fn method(&self) {} +} +``` + +Could be written: + +``` +struct A; +impl A { + fn method() {} +} +``` \ No newline at end of file diff --git a/src/docs/unused_unit.txt b/src/docs/unused_unit.txt new file mode 100644 index 00000000000..48d16ca6552 --- /dev/null +++ b/src/docs/unused_unit.txt @@ -0,0 +1,18 @@ +### What it does +Checks for unit (`()`) expressions that can be removed. + +### Why is this bad? +Such expressions add no value, but can make the code +less readable. Depending on formatting they can make a `break` or `return` +statement look like a function call. + +### Example +``` +fn return_unit() -> () { + () +} +``` +is equivalent to +``` +fn return_unit() {} +``` \ No newline at end of file diff --git a/src/docs/unusual_byte_groupings.txt b/src/docs/unusual_byte_groupings.txt new file mode 100644 index 00000000000..9a1f132a611 --- /dev/null +++ b/src/docs/unusual_byte_groupings.txt @@ -0,0 +1,12 @@ +### What it does +Warns if hexadecimal or binary literals are not grouped +by nibble or byte. + +### Why is this bad? +Negatively impacts readability. + +### Example +``` +let x: u32 = 0xFFF_FFF; +let y: u8 = 0b01_011_101; +``` \ No newline at end of file diff --git a/src/docs/unwrap_in_result.txt b/src/docs/unwrap_in_result.txt new file mode 100644 index 00000000000..7497dd863d3 --- /dev/null +++ b/src/docs/unwrap_in_result.txt @@ -0,0 +1,39 @@ +### What it does +Checks for functions of type `Result` that contain `expect()` or `unwrap()` + +### Why is this bad? +These functions promote recoverable errors to non-recoverable errors which may be undesirable in code bases which wish to avoid panics. + +### Known problems +This can cause false positives in functions that handle both recoverable and non recoverable errors. + +### Example +Before: +``` +fn divisible_by_3(i_str: String) -> Result<(), String> { + let i = i_str + .parse::() + .expect("cannot divide the input by three"); + + if i % 3 != 0 { + Err("Number is not divisible by 3")? + } + + Ok(()) +} +``` + +After: +``` +fn divisible_by_3(i_str: String) -> Result<(), String> { + let i = i_str + .parse::() + .map_err(|e| format!("cannot divide the input by three: {}", e))?; + + if i % 3 != 0 { + Err("Number is not divisible by 3")? + } + + Ok(()) +} +``` \ No newline at end of file diff --git a/src/docs/unwrap_or_else_default.txt b/src/docs/unwrap_or_else_default.txt new file mode 100644 index 00000000000..34b4cf08858 --- /dev/null +++ b/src/docs/unwrap_or_else_default.txt @@ -0,0 +1,18 @@ +### What it does +Checks for usages of `_.unwrap_or_else(Default::default)` on `Option` and +`Result` values. + +### Why is this bad? +Readability, these can be written as `_.unwrap_or_default`, which is +simpler and more concise. + +### Examples +``` +x.unwrap_or_else(Default::default); +x.unwrap_or_else(u32::default); +``` + +Use instead: +``` +x.unwrap_or_default(); +``` \ No newline at end of file diff --git a/src/docs/unwrap_used.txt b/src/docs/unwrap_used.txt new file mode 100644 index 00000000000..9b4713df515 --- /dev/null +++ b/src/docs/unwrap_used.txt @@ -0,0 +1,37 @@ +### What it does +Checks for `.unwrap()` or `.unwrap_err()` calls on `Result`s and `.unwrap()` call on `Option`s. + +### Why is this bad? +It is better to handle the `None` or `Err` case, +or at least call `.expect(_)` with a more helpful message. Still, for a lot of +quick-and-dirty code, `unwrap` is a good choice, which is why this lint is +`Allow` by default. + +`result.unwrap()` will let the thread panic on `Err` values. +Normally, you want to implement more sophisticated error handling, +and propagate errors upwards with `?` operator. + +Even if you want to panic on errors, not all `Error`s implement good +messages on display. Therefore, it may be beneficial to look at the places +where they may get displayed. Activate this lint to do just that. + +### Examples +``` +option.unwrap(); +result.unwrap(); +``` + +Use instead: +``` +option.expect("more helpful message"); +result.expect("more helpful message"); +``` + +If [expect_used](#expect_used) is enabled, instead: +``` +option?; + +// or + +result?; +``` \ No newline at end of file diff --git a/src/docs/upper_case_acronyms.txt b/src/docs/upper_case_acronyms.txt new file mode 100644 index 00000000000..a1e39c7e10c --- /dev/null +++ b/src/docs/upper_case_acronyms.txt @@ -0,0 +1,25 @@ +### What it does +Checks for fully capitalized names and optionally names containing a capitalized acronym. + +### Why is this bad? +In CamelCase, acronyms count as one word. +See [naming conventions](https://rust-lang.github.io/api-guidelines/naming.html#casing-conforms-to-rfc-430-c-case) +for more. + +By default, the lint only triggers on fully-capitalized names. +You can use the `upper-case-acronyms-aggressive: true` config option to enable linting +on all camel case names + +### Known problems +When two acronyms are contiguous, the lint can't tell where +the first acronym ends and the second starts, so it suggests to lowercase all of +the letters in the second acronym. + +### Example +``` +struct HTTPResponse; +``` +Use instead: +``` +struct HttpResponse; +``` \ No newline at end of file diff --git a/src/docs/use_debug.txt b/src/docs/use_debug.txt new file mode 100644 index 00000000000..94d4a6fd29a --- /dev/null +++ b/src/docs/use_debug.txt @@ -0,0 +1,12 @@ +### What it does +Checks for use of `Debug` formatting. The purpose of this +lint is to catch debugging remnants. + +### Why is this bad? +The purpose of the `Debug` trait is to facilitate +debugging Rust code. It should not be used in user-facing output. + +### Example +``` +println!("{:?}", foo); +``` \ No newline at end of file diff --git a/src/docs/use_self.txt b/src/docs/use_self.txt new file mode 100644 index 00000000000..bd37ed1e002 --- /dev/null +++ b/src/docs/use_self.txt @@ -0,0 +1,31 @@ +### What it does +Checks for unnecessary repetition of structure name when a +replacement with `Self` is applicable. + +### Why is this bad? +Unnecessary repetition. Mixed use of `Self` and struct +name +feels inconsistent. + +### Known problems +- Unaddressed false negative in fn bodies of trait implementations +- False positive with associated types in traits (#4140) + +### Example +``` +struct Foo; +impl Foo { + fn new() -> Foo { + Foo {} + } +} +``` +could be +``` +struct Foo; +impl Foo { + fn new() -> Self { + Self {} + } +} +``` \ No newline at end of file diff --git a/src/docs/used_underscore_binding.txt b/src/docs/used_underscore_binding.txt new file mode 100644 index 00000000000..ed67c41eb0d --- /dev/null +++ b/src/docs/used_underscore_binding.txt @@ -0,0 +1,19 @@ +### What it does +Checks for the use of bindings with a single leading +underscore. + +### Why is this bad? +A single leading underscore is usually used to indicate +that a binding will not be used. Using such a binding breaks this +expectation. + +### Known problems +The lint does not work properly with desugaring and +macro, it has been allowed in the mean time. + +### Example +``` +let _x = 0; +let y = _x + 1; // Here we are using `_x`, even though it has a leading + // underscore. We should rename `_x` to `x` +``` \ No newline at end of file diff --git a/src/docs/useless_asref.txt b/src/docs/useless_asref.txt new file mode 100644 index 00000000000..f777cd3775e --- /dev/null +++ b/src/docs/useless_asref.txt @@ -0,0 +1,17 @@ +### What it does +Checks for usage of `.as_ref()` or `.as_mut()` where the +types before and after the call are the same. + +### Why is this bad? +The call is unnecessary. + +### Example +``` +let x: &[i32] = &[1, 2, 3, 4, 5]; +do_stuff(x.as_ref()); +``` +The correct use would be: +``` +let x: &[i32] = &[1, 2, 3, 4, 5]; +do_stuff(x); +``` \ No newline at end of file diff --git a/src/docs/useless_attribute.txt b/src/docs/useless_attribute.txt new file mode 100644 index 00000000000..e02d4c90789 --- /dev/null +++ b/src/docs/useless_attribute.txt @@ -0,0 +1,36 @@ +### What it does +Checks for `extern crate` and `use` items annotated with +lint attributes. + +This lint permits lint attributes for lints emitted on the items themself. +For `use` items these lints are: +* deprecated +* unreachable_pub +* unused_imports +* clippy::enum_glob_use +* clippy::macro_use_imports +* clippy::wildcard_imports + +For `extern crate` items these lints are: +* `unused_imports` on items with `#[macro_use]` + +### Why is this bad? +Lint attributes have no effect on crate imports. Most +likely a `!` was forgotten. + +### Example +``` +#[deny(dead_code)] +extern crate foo; +#[forbid(dead_code)] +use foo::bar; +``` + +Use instead: +``` +#[allow(unused_imports)] +use foo::baz; +#[allow(unused_imports)] +#[macro_use] +extern crate baz; +``` \ No newline at end of file diff --git a/src/docs/useless_conversion.txt b/src/docs/useless_conversion.txt new file mode 100644 index 00000000000..06000a7ad98 --- /dev/null +++ b/src/docs/useless_conversion.txt @@ -0,0 +1,17 @@ +### What it does +Checks for `Into`, `TryInto`, `From`, `TryFrom`, or `IntoIter` calls +which uselessly convert to the same type. + +### Why is this bad? +Redundant code. + +### Example +``` +// format!() returns a `String` +let s: String = format!("hello").into(); +``` + +Use instead: +``` +let s: String = format!("hello"); +``` \ No newline at end of file diff --git a/src/docs/useless_format.txt b/src/docs/useless_format.txt new file mode 100644 index 00000000000..eb4819da1e9 --- /dev/null +++ b/src/docs/useless_format.txt @@ -0,0 +1,22 @@ +### What it does +Checks for the use of `format!("string literal with no +argument")` and `format!("{}", foo)` where `foo` is a string. + +### Why is this bad? +There is no point of doing that. `format!("foo")` can +be replaced by `"foo".to_owned()` if you really need a `String`. The even +worse `&format!("foo")` is often encountered in the wild. `format!("{}", +foo)` can be replaced by `foo.clone()` if `foo: String` or `foo.to_owned()` +if `foo: &str`. + +### Examples +``` +let foo = "foo"; +format!("{}", foo); +``` + +Use instead: +``` +let foo = "foo"; +foo.to_owned(); +``` \ No newline at end of file diff --git a/src/docs/useless_let_if_seq.txt b/src/docs/useless_let_if_seq.txt new file mode 100644 index 00000000000..c6dcd57eb2e --- /dev/null +++ b/src/docs/useless_let_if_seq.txt @@ -0,0 +1,39 @@ +### What it does +Checks for variable declarations immediately followed by a +conditional affectation. + +### Why is this bad? +This is not idiomatic Rust. + +### Example +``` +let foo; + +if bar() { + foo = 42; +} else { + foo = 0; +} + +let mut baz = None; + +if bar() { + baz = Some(42); +} +``` + +should be written + +``` +let foo = if bar() { + 42 +} else { + 0 +}; + +let baz = if bar() { + Some(42) +} else { + None +}; +``` \ No newline at end of file diff --git a/src/docs/useless_transmute.txt b/src/docs/useless_transmute.txt new file mode 100644 index 00000000000..1d3a1758814 --- /dev/null +++ b/src/docs/useless_transmute.txt @@ -0,0 +1,12 @@ +### What it does +Checks for transmutes to the original type of the object +and transmutes that could be a cast. + +### Why is this bad? +Readability. The code tricks people into thinking that +something complex is going on. + +### Example +``` +core::intrinsics::transmute(t); // where the result type is the same as `t`'s +``` \ No newline at end of file diff --git a/src/docs/useless_vec.txt b/src/docs/useless_vec.txt new file mode 100644 index 00000000000..ee5afc99e4b --- /dev/null +++ b/src/docs/useless_vec.txt @@ -0,0 +1,18 @@ +### What it does +Checks for usage of `&vec![..]` when using `&[..]` would +be possible. + +### Why is this bad? +This is less efficient. + +### Example +``` +fn foo(_x: &[u8]) {} + +foo(&vec![1, 2]); +``` + +Use instead: +``` +foo(&[1, 2]); +``` \ No newline at end of file diff --git a/src/docs/vec_box.txt b/src/docs/vec_box.txt new file mode 100644 index 00000000000..701b1c9ce9b --- /dev/null +++ b/src/docs/vec_box.txt @@ -0,0 +1,26 @@ +### What it does +Checks for use of `Vec>` where T: Sized anywhere in the code. +Check the [Box documentation](https://doc.rust-lang.org/std/boxed/index.html) for more information. + +### Why is this bad? +`Vec` already keeps its contents in a separate area on +the heap. So if you `Box` its contents, you just add another level of indirection. + +### Known problems +Vec> makes sense if T is a large type (see [#3530](https://github.com/rust-lang/rust-clippy/issues/3530), +1st comment). + +### Example +``` +struct X { + values: Vec>, +} +``` + +Better: + +``` +struct X { + values: Vec, +} +``` \ No newline at end of file diff --git a/src/docs/vec_init_then_push.txt b/src/docs/vec_init_then_push.txt new file mode 100644 index 00000000000..445f2874796 --- /dev/null +++ b/src/docs/vec_init_then_push.txt @@ -0,0 +1,23 @@ +### What it does +Checks for calls to `push` immediately after creating a new `Vec`. + +If the `Vec` is created using `with_capacity` this will only lint if the capacity is a +constant and the number of pushes is greater than or equal to the initial capacity. + +If the `Vec` is extended after the initial sequence of pushes and it was default initialized +then this will only lint after there were at least four pushes. This number may change in +the future. + +### Why is this bad? +The `vec![]` macro is both more performant and easier to read than +multiple `push` calls. + +### Example +``` +let mut v = Vec::new(); +v.push(0); +``` +Use instead: +``` +let v = vec![0]; +``` \ No newline at end of file diff --git a/src/docs/vec_resize_to_zero.txt b/src/docs/vec_resize_to_zero.txt new file mode 100644 index 00000000000..0b92686772b --- /dev/null +++ b/src/docs/vec_resize_to_zero.txt @@ -0,0 +1,15 @@ +### What it does +Finds occurrences of `Vec::resize(0, an_int)` + +### Why is this bad? +This is probably an argument inversion mistake. + +### Example +``` +vec!(1, 2, 3, 4, 5).resize(0, 5) +``` + +Use instead: +``` +vec!(1, 2, 3, 4, 5).clear() +``` \ No newline at end of file diff --git a/src/docs/verbose_bit_mask.txt b/src/docs/verbose_bit_mask.txt new file mode 100644 index 00000000000..87a84702925 --- /dev/null +++ b/src/docs/verbose_bit_mask.txt @@ -0,0 +1,15 @@ +### What it does +Checks for bit masks that can be replaced by a call +to `trailing_zeros` + +### Why is this bad? +`x.trailing_zeros() > 4` is much clearer than `x & 15 +== 0` + +### Known problems +llvm generates better code for `x & 15 == 0` on x86 + +### Example +``` +if x & 0b1111 == 0 { } +``` \ No newline at end of file diff --git a/src/docs/verbose_file_reads.txt b/src/docs/verbose_file_reads.txt new file mode 100644 index 00000000000..9703df423a5 --- /dev/null +++ b/src/docs/verbose_file_reads.txt @@ -0,0 +1,17 @@ +### What it does +Checks for use of File::read_to_end and File::read_to_string. + +### Why is this bad? +`fs::{read, read_to_string}` provide the same functionality when `buf` is empty with fewer imports and no intermediate values. +See also: [fs::read docs](https://doc.rust-lang.org/std/fs/fn.read.html), [fs::read_to_string docs](https://doc.rust-lang.org/std/fs/fn.read_to_string.html) + +### Example +``` +let mut f = File::open("foo.txt").unwrap(); +let mut bytes = Vec::new(); +f.read_to_end(&mut bytes).unwrap(); +``` +Can be written more concisely as +``` +let mut bytes = fs::read("foo.txt").unwrap(); +``` \ No newline at end of file diff --git a/src/docs/vtable_address_comparisons.txt b/src/docs/vtable_address_comparisons.txt new file mode 100644 index 00000000000..4a34e4ba78e --- /dev/null +++ b/src/docs/vtable_address_comparisons.txt @@ -0,0 +1,17 @@ +### What it does +Checks for comparisons with an address of a trait vtable. + +### Why is this bad? +Comparing trait objects pointers compares an vtable addresses which +are not guaranteed to be unique and could vary between different code generation units. +Furthermore vtables for different types could have the same address after being merged +together. + +### Example +``` +let a: Rc = ... +let b: Rc = ... +if Rc::ptr_eq(&a, &b) { + ... +} +``` \ No newline at end of file diff --git a/src/docs/while_immutable_condition.txt b/src/docs/while_immutable_condition.txt new file mode 100644 index 00000000000..71800701f48 --- /dev/null +++ b/src/docs/while_immutable_condition.txt @@ -0,0 +1,20 @@ +### What it does +Checks whether variables used within while loop condition +can be (and are) mutated in the body. + +### Why is this bad? +If the condition is unchanged, entering the body of the loop +will lead to an infinite loop. + +### Known problems +If the `while`-loop is in a closure, the check for mutation of the +condition variables in the body can cause false negatives. For example when only `Upvar` `a` is +in the condition and only `Upvar` `b` gets mutated in the body, the lint will not trigger. + +### Example +``` +let i = 0; +while i > 10 { + println!("let me loop forever!"); +} +``` \ No newline at end of file diff --git a/src/docs/while_let_loop.txt b/src/docs/while_let_loop.txt new file mode 100644 index 00000000000..ab7bf60975e --- /dev/null +++ b/src/docs/while_let_loop.txt @@ -0,0 +1,25 @@ +### What it does +Detects `loop + match` combinations that are easier +written as a `while let` loop. + +### Why is this bad? +The `while let` loop is usually shorter and more +readable. + +### Known problems +Sometimes the wrong binding is displayed ([#383](https://github.com/rust-lang/rust-clippy/issues/383)). + +### Example +``` +loop { + let x = match y { + Some(x) => x, + None => break, + }; + // .. do something with x +} +// is easier written as +while let Some(x) = y { + // .. do something with x +}; +``` \ No newline at end of file diff --git a/src/docs/while_let_on_iterator.txt b/src/docs/while_let_on_iterator.txt new file mode 100644 index 00000000000..af053c54119 --- /dev/null +++ b/src/docs/while_let_on_iterator.txt @@ -0,0 +1,20 @@ +### What it does +Checks for `while let` expressions on iterators. + +### Why is this bad? +Readability. A simple `for` loop is shorter and conveys +the intent better. + +### Example +``` +while let Some(val) = iter.next() { + .. +} +``` + +Use instead: +``` +for val in &mut iter { + .. +} +``` \ No newline at end of file diff --git a/src/docs/wildcard_dependencies.txt b/src/docs/wildcard_dependencies.txt new file mode 100644 index 00000000000..2affaf9740d --- /dev/null +++ b/src/docs/wildcard_dependencies.txt @@ -0,0 +1,13 @@ +### What it does +Checks for wildcard dependencies in the `Cargo.toml`. + +### Why is this bad? +[As the edition guide says](https://rust-lang-nursery.github.io/edition-guide/rust-2018/cargo-and-crates-io/crates-io-disallows-wildcard-dependencies.html), +it is highly unlikely that you work with any possible version of your dependency, +and wildcard dependencies would cause unnecessary breakage in the ecosystem. + +### Example +``` +[dependencies] +regex = "*" +``` \ No newline at end of file diff --git a/src/docs/wildcard_enum_match_arm.txt b/src/docs/wildcard_enum_match_arm.txt new file mode 100644 index 00000000000..09807c01c65 --- /dev/null +++ b/src/docs/wildcard_enum_match_arm.txt @@ -0,0 +1,25 @@ +### What it does +Checks for wildcard enum matches using `_`. + +### Why is this bad? +New enum variants added by library updates can be missed. + +### Known problems +Suggested replacements may be incorrect if guards exhaustively cover some +variants, and also may not use correct path to enum if it's not present in the current scope. + +### Example +``` +match x { + Foo::A(_) => {}, + _ => {}, +} +``` + +Use instead: +``` +match x { + Foo::A(_) => {}, + Foo::B(_) => {}, +} +``` \ No newline at end of file diff --git a/src/docs/wildcard_imports.txt b/src/docs/wildcard_imports.txt new file mode 100644 index 00000000000..bd56aa5b082 --- /dev/null +++ b/src/docs/wildcard_imports.txt @@ -0,0 +1,45 @@ +### What it does +Checks for wildcard imports `use _::*`. + +### Why is this bad? +wildcard imports can pollute the namespace. This is especially bad if +you try to import something through a wildcard, that already has been imported by name from +a different source: + +``` +use crate1::foo; // Imports a function named foo +use crate2::*; // Has a function named foo + +foo(); // Calls crate1::foo +``` + +This can lead to confusing error messages at best and to unexpected behavior at worst. + +### Exceptions +Wildcard imports are allowed from modules named `prelude`. Many crates (including the standard library) +provide modules named "prelude" specifically designed for wildcard import. + +`use super::*` is allowed in test modules. This is defined as any module with "test" in the name. + +These exceptions can be disabled using the `warn-on-all-wildcard-imports` configuration flag. + +### Known problems +If macros are imported through the wildcard, this macro is not included +by the suggestion and has to be added by hand. + +Applying the suggestion when explicit imports of the things imported with a glob import +exist, may result in `unused_imports` warnings. + +### Example +``` +use crate1::*; + +foo(); +``` + +Use instead: +``` +use crate1::foo; + +foo(); +``` \ No newline at end of file diff --git a/src/docs/wildcard_in_or_patterns.txt b/src/docs/wildcard_in_or_patterns.txt new file mode 100644 index 00000000000..70468ca41e0 --- /dev/null +++ b/src/docs/wildcard_in_or_patterns.txt @@ -0,0 +1,22 @@ +### What it does +Checks for wildcard pattern used with others patterns in same match arm. + +### Why is this bad? +Wildcard pattern already covers any other pattern as it will match anyway. +It makes the code less readable, especially to spot wildcard pattern use in match arm. + +### Example +``` +match s { + "a" => {}, + "bar" | _ => {}, +} +``` + +Use instead: +``` +match s { + "a" => {}, + _ => {}, +} +``` \ No newline at end of file diff --git a/src/docs/write_literal.txt b/src/docs/write_literal.txt new file mode 100644 index 00000000000..9c41a48f9f7 --- /dev/null +++ b/src/docs/write_literal.txt @@ -0,0 +1,21 @@ +### What it does +This lint warns about the use of literals as `write!`/`writeln!` args. + +### Why is this bad? +Using literals as `writeln!` args is inefficient +(c.f., https://github.com/matthiaskrgr/rust-str-bench) and unnecessary +(i.e., just put the literal in the format string) + +### Known problems +Will also warn with macro calls as arguments that expand to literals +-- e.g., `writeln!(buf, "{}", env!("FOO"))`. + +### Example +``` +writeln!(buf, "{}", "foo"); +``` + +Use instead: +``` +writeln!(buf, "foo"); +``` \ No newline at end of file diff --git a/src/docs/write_with_newline.txt b/src/docs/write_with_newline.txt new file mode 100644 index 00000000000..22845fd6515 --- /dev/null +++ b/src/docs/write_with_newline.txt @@ -0,0 +1,18 @@ +### What it does +This lint warns when you use `write!()` with a format +string that +ends in a newline. + +### Why is this bad? +You should use `writeln!()` instead, which appends the +newline. + +### Example +``` +write!(buf, "Hello {}!\n", name); +``` + +Use instead: +``` +writeln!(buf, "Hello {}!", name); +``` \ No newline at end of file diff --git a/src/docs/writeln_empty_string.txt b/src/docs/writeln_empty_string.txt new file mode 100644 index 00000000000..3b3aeb79a48 --- /dev/null +++ b/src/docs/writeln_empty_string.txt @@ -0,0 +1,16 @@ +### What it does +This lint warns when you use `writeln!(buf, "")` to +print a newline. + +### Why is this bad? +You should use `writeln!(buf)`, which is simpler. + +### Example +``` +writeln!(buf, ""); +``` + +Use instead: +``` +writeln!(buf); +``` \ No newline at end of file diff --git a/src/docs/wrong_self_convention.txt b/src/docs/wrong_self_convention.txt new file mode 100644 index 00000000000..d6b69ab87f8 --- /dev/null +++ b/src/docs/wrong_self_convention.txt @@ -0,0 +1,39 @@ +### What it does +Checks for methods with certain name prefixes and which +doesn't match how self is taken. The actual rules are: + +|Prefix |Postfix |`self` taken | `self` type | +|-------|------------|-------------------------------|--------------| +|`as_` | none |`&self` or `&mut self` | any | +|`from_`| none | none | any | +|`into_`| none |`self` | any | +|`is_` | none |`&mut self` or `&self` or none | any | +|`to_` | `_mut` |`&mut self` | any | +|`to_` | not `_mut` |`self` | `Copy` | +|`to_` | not `_mut` |`&self` | not `Copy` | + +Note: Clippy doesn't trigger methods with `to_` prefix in: +- Traits definition. +Clippy can not tell if a type that implements a trait is `Copy` or not. +- Traits implementation, when `&self` is taken. +The method signature is controlled by the trait and often `&self` is required for all types that implement the trait +(see e.g. the `std::string::ToString` trait). + +Clippy allows `Pin<&Self>` and `Pin<&mut Self>` if `&self` and `&mut self` is required. + +Please find more info here: +https://rust-lang.github.io/api-guidelines/naming.html#ad-hoc-conversions-follow-as_-to_-into_-conventions-c-conv + +### Why is this bad? +Consistency breeds readability. If you follow the +conventions, your users won't be surprised that they, e.g., need to supply a +mutable reference to a `as_..` function. + +### Example +``` +impl X { + fn as_str(self) -> &'static str { + // .. + } +} +``` \ No newline at end of file diff --git a/src/docs/wrong_transmute.txt b/src/docs/wrong_transmute.txt new file mode 100644 index 00000000000..9fc71e0e382 --- /dev/null +++ b/src/docs/wrong_transmute.txt @@ -0,0 +1,15 @@ +### What it does +Checks for transmutes that can't ever be correct on any +architecture. + +### Why is this bad? +It's basically guaranteed to be undefined behavior. + +### Known problems +When accessing C, users might want to store pointer +sized objects in `extradata` arguments to save an allocation. + +### Example +``` +let ptr: *const T = core::intrinsics::transmute('x') +``` \ No newline at end of file diff --git a/src/docs/zero_divided_by_zero.txt b/src/docs/zero_divided_by_zero.txt new file mode 100644 index 00000000000..394de20c0c0 --- /dev/null +++ b/src/docs/zero_divided_by_zero.txt @@ -0,0 +1,15 @@ +### What it does +Checks for `0.0 / 0.0`. + +### Why is this bad? +It's less readable than `f32::NAN` or `f64::NAN`. + +### Example +``` +let nan = 0.0f32 / 0.0; +``` + +Use instead: +``` +let nan = f32::NAN; +``` \ No newline at end of file diff --git a/src/docs/zero_prefixed_literal.txt b/src/docs/zero_prefixed_literal.txt new file mode 100644 index 00000000000..5c558872536 --- /dev/null +++ b/src/docs/zero_prefixed_literal.txt @@ -0,0 +1,32 @@ +### What it does +Warns if an integral constant literal starts with `0`. + +### Why is this bad? +In some languages (including the infamous C language +and most of its +family), this marks an octal constant. In Rust however, this is a decimal +constant. This could +be confusing for both the writer and a reader of the constant. + +### Example + +In Rust: +``` +fn main() { + let a = 0123; + println!("{}", a); +} +``` + +prints `123`, while in C: + +``` +#include + +int main() { + int a = 0123; + printf("%d\n", a); +} +``` + +prints `83` (as `83 == 0o123` while `123 == 0o173`). \ No newline at end of file diff --git a/src/docs/zero_ptr.txt b/src/docs/zero_ptr.txt new file mode 100644 index 00000000000..e768a023660 --- /dev/null +++ b/src/docs/zero_ptr.txt @@ -0,0 +1,16 @@ +### What it does +Catch casts from `0` to some pointer type + +### Why is this bad? +This generally means `null` and is better expressed as +{`std`, `core`}`::ptr::`{`null`, `null_mut`}. + +### Example +``` +let a = 0 as *const u32; +``` + +Use instead: +``` +let a = std::ptr::null::(); +``` \ No newline at end of file diff --git a/src/docs/zero_sized_map_values.txt b/src/docs/zero_sized_map_values.txt new file mode 100644 index 00000000000..0502bdbf395 --- /dev/null +++ b/src/docs/zero_sized_map_values.txt @@ -0,0 +1,24 @@ +### What it does +Checks for maps with zero-sized value types anywhere in the code. + +### Why is this bad? +Since there is only a single value for a zero-sized type, a map +containing zero sized values is effectively a set. Using a set in that case improves +readability and communicates intent more clearly. + +### Known problems +* A zero-sized type cannot be recovered later if it contains private fields. +* This lints the signature of public items + +### Example +``` +fn unique_words(text: &str) -> HashMap<&str, ()> { + todo!(); +} +``` +Use instead: +``` +fn unique_words(text: &str) -> HashSet<&str> { + todo!(); +} +``` \ No newline at end of file diff --git a/src/docs/zst_offset.txt b/src/docs/zst_offset.txt new file mode 100644 index 00000000000..5810455ee95 --- /dev/null +++ b/src/docs/zst_offset.txt @@ -0,0 +1,11 @@ +### What it does +Checks for `offset(_)`, `wrapping_`{`add`, `sub`}, etc. on raw pointers to +zero-sized types + +### Why is this bad? +This is a no-op, and likely unintended + +### Example +``` +unsafe { (&() as *const ()).offset(1) }; +``` \ No newline at end of file diff --git a/src/main.rs b/src/main.rs index 9ee4a40cbf2..4a32e0e54a8 100644 --- a/src/main.rs +++ b/src/main.rs @@ -7,6 +7,8 @@ use std::env; use std::path::PathBuf; use std::process::{self, Command}; +mod docs; + const CARGO_CLIPPY_HELP: &str = r#"Checks a package to catch common mistakes and improve your Rust code. Usage: @@ -17,6 +19,7 @@ Common options: --fix Automatically apply lint suggestions. This flag implies `--no-deps` -h, --help Print this message -V, --version Print version info and exit + --explain LINT Print the documentation for a given lint Other options are the same as `cargo check`. @@ -54,6 +57,16 @@ pub fn main() { return; } + if let Some(pos) = env::args().position(|a| a == "--explain") { + if let Some(mut lint) = env::args().nth(pos + 1) { + lint.make_ascii_lowercase(); + docs::explain(&lint.strip_prefix("clippy::").unwrap_or(&lint).replace('-', "_")); + } else { + show_help(); + } + return; + } + if let Err(code) = process(env::args().skip(2)) { process::exit(code); } -- cgit 1.4.1-3-g733a5 From 6d8959ea8374376ee38c972c61e8bfdacb71724f Mon Sep 17 00:00:00 2001 From: Alex Macleod Date: Fri, 16 Sep 2022 21:04:38 +0000 Subject: Add `#[allow(unused)]` to test in `cargo dev new_lint` --- book/src/development/adding_lints.md | 1 + clippy_dev/src/new_lint.rs | 1 + 2 files changed, 2 insertions(+) (limited to 'clippy_dev/src') diff --git a/book/src/development/adding_lints.md b/book/src/development/adding_lints.md index da781eb970d..b1e843bc7f4 100644 --- a/book/src/development/adding_lints.md +++ b/book/src/development/adding_lints.md @@ -90,6 +90,7 @@ We start by opening the test file created at `tests/ui/foo_functions.rs`. Update the file with some examples to get started: ```rust +#![allow(unused)] #![warn(clippy::foo_functions)] // Impl methods diff --git a/clippy_dev/src/new_lint.rs b/clippy_dev/src/new_lint.rs index be05e67d724..9a68c6e775d 100644 --- a/clippy_dev/src/new_lint.rs +++ b/clippy_dev/src/new_lint.rs @@ -186,6 +186,7 @@ pub(crate) fn get_stabilization_version() -> String { fn get_test_file_contents(lint_name: &str, header_commands: Option<&str>) -> String { let mut contents = format!( indoc! {" + #![allow(unused)] #![warn(clippy::{})] fn main() {{ -- cgit 1.4.1-3-g733a5 From 033dae9ecc676a1a6d7fa43665ebff3861f2fa15 Mon Sep 17 00:00:00 2001 From: Michael Schubart Date: Wed, 21 Sep 2022 19:04:31 +0100 Subject: Actually use the sorted vector --- clippy_dev/src/update_lints.rs | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/update_lints.rs b/clippy_dev/src/update_lints.rs index b95061bf81a..e77c70b6781 100644 --- a/clippy_dev/src/update_lints.rs +++ b/clippy_dev/src/update_lints.rs @@ -45,9 +45,8 @@ fn generate_lint_files( renamed_lints: &[RenamedLint], ) { let internal_lints = Lint::internal_lints(lints); - let usable_lints = Lint::usable_lints(lints); - let mut sorted_usable_lints = usable_lints.clone(); - sorted_usable_lints.sort_by_key(|lint| lint.name.clone()); + let mut usable_lints = Lint::usable_lints(lints); + usable_lints.sort_by_key(|lint| lint.name.clone()); replace_region_in_file( update_mode, -- cgit 1.4.1-3-g733a5 From 59d0e8cabaec24b564db8420ef630c6a5880688f Mon Sep 17 00:00:00 2001 From: Yuri Astrakhan Date: Fri, 23 Sep 2022 14:25:03 -0400 Subject: and a few more from other dirs --- clippy_dev/src/main.rs | 2 +- clippy_utils/src/attrs.rs | 4 +-- clippy_utils/src/diagnostics.rs | 5 ++- clippy_utils/src/lib.rs | 2 +- clippy_utils/src/macros.rs | 2 +- clippy_utils/src/qualify_min_const_fn.rs | 11 +++---- clippy_utils/src/source.rs | 8 ++--- clippy_utils/src/sugg.rs | 52 +++++++++++++++----------------- rustc_tools_util/src/lib.rs | 6 ++-- tests/integration.rs | 4 +-- 10 files changed, 46 insertions(+), 50 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index a417d3dd8a4..d3e03669204 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -41,7 +41,7 @@ fn main() { matches.contains_id("msrv"), ) { Ok(_) => update_lints::update(update_lints::UpdateMode::Change), - Err(e) => eprintln!("Unable to create lint: {}", e), + Err(e) => eprintln!("Unable to create lint: {e}"), } }, Some(("setup", sub_command)) => match sub_command.subcommand() { diff --git a/clippy_utils/src/attrs.rs b/clippy_utils/src/attrs.rs index 8ab77c88166..d9b22664fd2 100644 --- a/clippy_utils/src/attrs.rs +++ b/clippy_utils/src/attrs.rs @@ -131,12 +131,12 @@ pub fn get_unique_inner_attr(sess: &Session, attrs: &[ast::Attribute], name: &'s match attr.style { ast::AttrStyle::Inner if unique_attr.is_none() => unique_attr = Some(attr.clone()), ast::AttrStyle::Inner => { - sess.struct_span_err(attr.span, &format!("`{}` is defined multiple times", name)) + sess.struct_span_err(attr.span, &format!("`{name}` is defined multiple times")) .span_note(unique_attr.as_ref().unwrap().span, "first definition found here") .emit(); }, ast::AttrStyle::Outer => { - sess.span_err(attr.span, &format!("`{}` cannot be an outer attribute", name)); + sess.span_err(attr.span, &format!("`{name}` cannot be an outer attribute")); }, } } diff --git a/clippy_utils/src/diagnostics.rs b/clippy_utils/src/diagnostics.rs index ad95369b9ef..12e53e07c97 100644 --- a/clippy_utils/src/diagnostics.rs +++ b/clippy_utils/src/diagnostics.rs @@ -18,12 +18,11 @@ fn docs_link(diag: &mut Diagnostic, lint: &'static Lint) { if env::var("CLIPPY_DISABLE_DOCS_LINKS").is_err() { if let Some(lint) = lint.name_lower().strip_prefix("clippy::") { diag.help(&format!( - "for further information visit https://rust-lang.github.io/rust-clippy/{}/index.html#{}", + "for further information visit https://rust-lang.github.io/rust-clippy/{}/index.html#{lint}", &option_env!("RUST_RELEASE_NUM").map_or("master".to_string(), |n| { // extract just major + minor version and ignore patch versions format!("rust-{}", n.rsplit_once('.').unwrap().1) - }), - lint + }) )); } } diff --git a/clippy_utils/src/lib.rs b/clippy_utils/src/lib.rs index a1a716ebeca..f3c3fd73f39 100644 --- a/clippy_utils/src/lib.rs +++ b/clippy_utils/src/lib.rs @@ -121,7 +121,7 @@ pub fn parse_msrv(msrv: &str, sess: Option<&Session>, span: Option) -> Opt return Some(version); } else if let Some(sess) = sess { if let Some(span) = span { - sess.span_err(span, &format!("`{}` is not a valid Rust version", msrv)); + sess.span_err(span, &format!("`{msrv}` is not a valid Rust version")); } } None diff --git a/clippy_utils/src/macros.rs b/clippy_utils/src/macros.rs index a1808c09720..b9e6462a55e 100644 --- a/clippy_utils/src/macros.rs +++ b/clippy_utils/src/macros.rs @@ -392,7 +392,7 @@ impl FormatString { unescape_literal(inner, mode, &mut |_, ch| match ch { Ok(ch) => unescaped.push(ch), Err(e) if !e.is_fatal() => (), - Err(e) => panic!("{:?}", e), + Err(e) => panic!("{e:?}"), }); let mut parts = Vec::new(); diff --git a/clippy_utils/src/qualify_min_const_fn.rs b/clippy_utils/src/qualify_min_const_fn.rs index d5f64e5118f..efa7aaa40ee 100644 --- a/clippy_utils/src/qualify_min_const_fn.rs +++ b/clippy_utils/src/qualify_min_const_fn.rs @@ -33,10 +33,10 @@ pub fn is_min_const_fn<'a, 'tcx>(tcx: TyCtxt<'tcx>, body: &'a Body<'tcx>, msrv: | ty::PredicateKind::ConstEquate(..) | ty::PredicateKind::Trait(..) | ty::PredicateKind::TypeWellFormedFromEnv(..) => continue, - ty::PredicateKind::ObjectSafe(_) => panic!("object safe predicate on function: {:#?}", predicate), - ty::PredicateKind::ClosureKind(..) => panic!("closure kind predicate on function: {:#?}", predicate), - ty::PredicateKind::Subtype(_) => panic!("subtype predicate on function: {:#?}", predicate), - ty::PredicateKind::Coerce(_) => panic!("coerce predicate on function: {:#?}", predicate), + ty::PredicateKind::ObjectSafe(_) => panic!("object safe predicate on function: {predicate:#?}"), + ty::PredicateKind::ClosureKind(..) => panic!("closure kind predicate on function: {predicate:#?}"), + ty::PredicateKind::Subtype(_) => panic!("subtype predicate on function: {predicate:#?}"), + ty::PredicateKind::Coerce(_) => panic!("coerce predicate on function: {predicate:#?}"), } } match predicates.parent { @@ -315,8 +315,7 @@ fn check_terminator<'a, 'tcx>( span, format!( "can only call other `const fn` within a `const fn`, \ - but `{:?}` is not stable as `const fn`", - func, + but `{func:?}` is not stable as `const fn`", ) .into(), )); diff --git a/clippy_utils/src/source.rs b/clippy_utils/src/source.rs index d85f591fb9a..64c3f70efa5 100644 --- a/clippy_utils/src/source.rs +++ b/clippy_utils/src/source.rs @@ -25,11 +25,11 @@ pub fn expr_block<'a, T: LintContext>( if expr.span.from_expansion() { Cow::Owned(format!("{{ {} }}", snippet_with_macro_callsite(cx, expr.span, default))) } else if let ExprKind::Block(_, _) = expr.kind { - Cow::Owned(format!("{}{}", code, string)) + Cow::Owned(format!("{code}{string}")) } else if string.is_empty() { - Cow::Owned(format!("{{ {} }}", code)) + Cow::Owned(format!("{{ {code} }}")) } else { - Cow::Owned(format!("{{\n{};\n{}\n}}", code, string)) + Cow::Owned(format!("{{\n{code};\n{string}\n}}")) } } @@ -466,7 +466,7 @@ mod test { #[test] fn test_without_block_comments_lines_without_block_comments() { let result = without_block_comments(vec!["/*", "", "*/"]); - println!("result: {:?}", result); + println!("result: {result:?}"); assert!(result.is_empty()); let result = without_block_comments(vec!["", "/*", "", "*/", "#[crate_type = \"lib\"]", "/*", "", "*/", ""]); diff --git a/clippy_utils/src/sugg.rs b/clippy_utils/src/sugg.rs index f08275a4ac7..00a2409996a 100644 --- a/clippy_utils/src/sugg.rs +++ b/clippy_utils/src/sugg.rs @@ -310,19 +310,19 @@ impl<'a> Sugg<'a> { /// Convenience method to transform suggestion into a return call pub fn make_return(self) -> Sugg<'static> { - Sugg::NonParen(Cow::Owned(format!("return {}", self))) + Sugg::NonParen(Cow::Owned(format!("return {self}"))) } /// Convenience method to transform suggestion into a block /// where the suggestion is a trailing expression pub fn blockify(self) -> Sugg<'static> { - Sugg::NonParen(Cow::Owned(format!("{{ {} }}", self))) + Sugg::NonParen(Cow::Owned(format!("{{ {self} }}"))) } /// Convenience method to prefix the expression with the `async` keyword. /// Can be used after `blockify` to create an async block. pub fn asyncify(self) -> Sugg<'static> { - Sugg::NonParen(Cow::Owned(format!("async {}", self))) + Sugg::NonParen(Cow::Owned(format!("async {self}"))) } /// Convenience method to create the `..` or `...` @@ -346,12 +346,12 @@ impl<'a> Sugg<'a> { if has_enclosing_paren(&sugg) { Sugg::MaybeParen(sugg) } else { - Sugg::NonParen(format!("({})", sugg).into()) + Sugg::NonParen(format!("({sugg})").into()) } }, Sugg::BinOp(op, lhs, rhs) => { let sugg = binop_to_string(op, &lhs, &rhs); - Sugg::NonParen(format!("({})", sugg).into()) + Sugg::NonParen(format!("({sugg})").into()) }, } } @@ -379,20 +379,18 @@ fn binop_to_string(op: AssocOp, lhs: &str, rhs: &str) -> String { | AssocOp::Greater | AssocOp::GreaterEqual => { format!( - "{} {} {}", - lhs, - op.to_ast_binop().expect("Those are AST ops").to_string(), - rhs + "{lhs} {} {rhs}", + op.to_ast_binop().expect("Those are AST ops").to_string() ) }, - AssocOp::Assign => format!("{} = {}", lhs, rhs), + AssocOp::Assign => format!("{lhs} = {rhs}"), AssocOp::AssignOp(op) => { - format!("{} {}= {}", lhs, token_kind_to_string(&token::BinOp(op)), rhs) + format!("{lhs} {}= {rhs}", token_kind_to_string(&token::BinOp(op))) }, - AssocOp::As => format!("{} as {}", lhs, rhs), - AssocOp::DotDot => format!("{}..{}", lhs, rhs), - AssocOp::DotDotEq => format!("{}..={}", lhs, rhs), - AssocOp::Colon => format!("{}: {}", lhs, rhs), + AssocOp::As => format!("{lhs} as {rhs}"), + AssocOp::DotDot => format!("{lhs}..{rhs}"), + AssocOp::DotDotEq => format!("{lhs}..={rhs}"), + AssocOp::Colon => format!("{lhs}: {rhs}"), } } @@ -523,7 +521,7 @@ impl Display for ParenHelper { /// operators have the same /// precedence. pub fn make_unop(op: &str, expr: Sugg<'_>) -> Sugg<'static> { - Sugg::MaybeParen(format!("{}{}", op, expr.maybe_par()).into()) + Sugg::MaybeParen(format!("{op}{}", expr.maybe_par()).into()) } /// Builds the string for ` ` adding parenthesis when necessary. @@ -744,7 +742,7 @@ impl DiagnosticExt for rustc_errors::Diagnostic { if let Some(indent) = indentation(cx, item) { let span = item.with_hi(item.lo()); - self.span_suggestion(span, msg, format!("{}\n{}", attr, indent), applicability); + self.span_suggestion(span, msg, format!("{attr}\n{indent}"), applicability); } } @@ -758,14 +756,14 @@ impl DiagnosticExt for rustc_errors::Diagnostic { .map(|l| { if first { first = false; - format!("{}\n", l) + format!("{l}\n") } else { - format!("{}{}\n", indent, l) + format!("{indent}{l}\n") } }) .collect::(); - self.span_suggestion(span, msg, format!("{}\n{}", new_item, indent), applicability); + self.span_suggestion(span, msg, format!("{new_item}\n{indent}"), applicability); } } @@ -863,7 +861,7 @@ impl<'tcx> DerefDelegate<'_, 'tcx> { pub fn finish(&mut self) -> String { let end_span = Span::new(self.next_pos, self.closure_span.hi(), self.closure_span.ctxt(), None); let end_snip = snippet_with_applicability(self.cx, end_span, "..", &mut self.applicability); - let sugg = format!("{}{}", self.suggestion_start, end_snip); + let sugg = format!("{}{end_snip}", self.suggestion_start); if self.closure_arg_is_type_annotated_double_ref { sugg.replacen('&', "", 1) } else { @@ -925,7 +923,7 @@ impl<'tcx> Delegate<'tcx> for DerefDelegate<'_, 'tcx> { if cmt.place.projections.is_empty() { // handle item without any projection, that needs an explicit borrowing // i.e.: suggest `&x` instead of `x` - let _ = write!(self.suggestion_start, "{}&{}", start_snip, ident_str); + let _ = write!(self.suggestion_start, "{start_snip}&{ident_str}"); } else { // cases where a parent `Call` or `MethodCall` is using the item // i.e.: suggest `.contains(&x)` for `.find(|x| [1, 2, 3].contains(x)).is_none()` @@ -940,7 +938,7 @@ impl<'tcx> Delegate<'tcx> for DerefDelegate<'_, 'tcx> { // given expression is the self argument and will be handled completely by the compiler // i.e.: `|x| x.is_something()` ExprKind::MethodCall(_, self_expr, ..) if self_expr.hir_id == cmt.hir_id => { - let _ = write!(self.suggestion_start, "{}{}", start_snip, ident_str_with_proj); + let _ = write!(self.suggestion_start, "{start_snip}{ident_str_with_proj}"); self.next_pos = span.hi(); return; }, @@ -973,9 +971,9 @@ impl<'tcx> Delegate<'tcx> for DerefDelegate<'_, 'tcx> { } else { ident_str }; - format!("{}{}", start_snip, ident) + format!("{start_snip}{ident}") } else { - format!("{}&{}", start_snip, ident_str) + format!("{start_snip}&{ident_str}") }; self.suggestion_start.push_str(&ident_sugg); self.next_pos = span.hi(); @@ -1042,13 +1040,13 @@ impl<'tcx> Delegate<'tcx> for DerefDelegate<'_, 'tcx> { for item in projections { if item.kind == ProjectionKind::Deref { - replacement_str = format!("*{}", replacement_str); + replacement_str = format!("*{replacement_str}"); } } } } - let _ = write!(self.suggestion_start, "{}{}", start_snip, replacement_str); + let _ = write!(self.suggestion_start, "{start_snip}{replacement_str}"); } self.next_pos = span.hi(); } diff --git a/rustc_tools_util/src/lib.rs b/rustc_tools_util/src/lib.rs index 429dddc42ea..0f988601670 100644 --- a/rustc_tools_util/src/lib.rs +++ b/rustc_tools_util/src/lib.rs @@ -48,8 +48,8 @@ impl std::fmt::Display for VersionInfo { if (hash_trimmed.len() + date_trimmed.len()) > 0 { write!( f, - "{} {}.{}.{} ({} {})", - self.crate_name, self.major, self.minor, self.patch, hash_trimmed, date_trimmed, + "{} {}.{}.{} ({hash_trimmed} {date_trimmed})", + self.crate_name, self.major, self.minor, self.patch, )?; } else { write!(f, "{} {}.{}.{}", self.crate_name, self.major, self.minor, self.patch)?; @@ -153,7 +153,7 @@ mod test { #[test] fn test_debug_local() { let vi = get_version_info!(); - let s = format!("{:?}", vi); + let s = format!("{vi:?}"); assert_eq!( s, "VersionInfo { crate_name: \"rustc_tools_util\", major: 0, minor: 2, patch: 0 }" diff --git a/tests/integration.rs b/tests/integration.rs index 23a9bef3ccc..330460ff8a5 100644 --- a/tests/integration.rs +++ b/tests/integration.rs @@ -9,7 +9,7 @@ use std::process::Command; #[cfg_attr(feature = "integration", test)] fn integration_test() { let repo_name = env::var("INTEGRATION").expect("`INTEGRATION` var not set"); - let repo_url = format!("https://github.com/{}", repo_name); + let repo_url = format!("https://github.com/{repo_name}"); let crate_name = repo_name .split('/') .nth(1) @@ -83,7 +83,7 @@ fn integration_test() { match output.status.code() { Some(0) => println!("Compilation successful"), - Some(code) => eprintln!("Compilation failed. Exit code: {}", code), + Some(code) => eprintln!("Compilation failed. Exit code: {code}"), None => panic!("Process terminated by signal"), } } -- cgit 1.4.1-3-g733a5 From cc6b375cd3edcee65adc6a7aa3e45a7a50fe8112 Mon Sep 17 00:00:00 2001 From: Yuri Astrakhan Date: Fri, 23 Sep 2022 22:20:42 -0400 Subject: fallout2: rework clippy_dev & _lints fmt inlining * Inline format args where possible * simplify a few complex macros into format str * use formatdoc!() instead format!(indoc!(...)) --- clippy_dev/src/fmt.rs | 6 +- clippy_dev/src/new_lint.rs | 167 +++++++++------------ clippy_dev/src/serve.rs | 4 +- clippy_dev/src/setup/git_hook.rs | 7 +- clippy_dev/src/setup/intellij.rs | 25 ++- clippy_dev/src/setup/vscode.rs | 19 +-- clippy_dev/src/update_lints.rs | 98 ++++++------ clippy_lints/src/utils/internal_lints.rs | 24 +-- .../src/utils/internal_lints/metadata_collector.rs | 97 ++++-------- 9 files changed, 181 insertions(+), 266 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/fmt.rs b/clippy_dev/src/fmt.rs index 357cf6fc43a..25623144181 100644 --- a/clippy_dev/src/fmt.rs +++ b/clippy_dev/src/fmt.rs @@ -82,16 +82,16 @@ pub fn run(check: bool, verbose: bool) { fn output_err(err: CliError) { match err { CliError::CommandFailed(command, stderr) => { - eprintln!("error: A command failed! `{}`\nstderr: {}", command, stderr); + eprintln!("error: A command failed! `{command}`\nstderr: {stderr}"); }, CliError::IoError(err) => { - eprintln!("error: {}", err); + eprintln!("error: {err}"); }, CliError::RustfmtNotInstalled => { eprintln!("error: rustfmt nightly is not installed."); }, CliError::WalkDirError(err) => { - eprintln!("error: {}", err); + eprintln!("error: {err}"); }, CliError::IntellijSetupActive => { eprintln!( diff --git a/clippy_dev/src/new_lint.rs b/clippy_dev/src/new_lint.rs index 9a68c6e775d..cbb2ec7c836 100644 --- a/clippy_dev/src/new_lint.rs +++ b/clippy_dev/src/new_lint.rs @@ -1,5 +1,5 @@ use crate::clippy_project_root; -use indoc::{indoc, writedoc}; +use indoc::{formatdoc, writedoc}; use std::fmt::Write as _; use std::fs::{self, OpenOptions}; use std::io::prelude::*; @@ -23,7 +23,7 @@ impl Context for io::Result { match self { Ok(t) => Ok(t), Err(e) => { - let message = format!("{}: {}", text.as_ref(), e); + let message = format!("{}: {e}", text.as_ref()); Err(io::Error::new(ErrorKind::Other, message)) }, } @@ -72,7 +72,7 @@ fn create_lint(lint: &LintData<'_>, enable_msrv: bool) -> io::Result<()> { let lint_contents = get_lint_file_contents(lint, enable_msrv); let lint_path = format!("clippy_lints/src/{}.rs", lint.name); write_file(lint.project_root.join(&lint_path), lint_contents.as_bytes())?; - println!("Generated lint file: `{}`", lint_path); + println!("Generated lint file: `{lint_path}`"); Ok(()) } @@ -86,7 +86,7 @@ fn create_test(lint: &LintData<'_>) -> io::Result<()> { path.push("src"); fs::create_dir(&path)?; - let header = format!("// compile-flags: --crate-name={}", lint_name); + let header = format!("// compile-flags: --crate-name={lint_name}"); write_file(path.join("main.rs"), get_test_file_contents(lint_name, Some(&header)))?; Ok(()) @@ -106,7 +106,7 @@ fn create_test(lint: &LintData<'_>) -> io::Result<()> { let test_contents = get_test_file_contents(lint.name, None); write_file(lint.project_root.join(&test_path), test_contents)?; - println!("Generated test file: `{}`", test_path); + println!("Generated test file: `{test_path}`"); } Ok(()) @@ -184,38 +184,36 @@ pub(crate) fn get_stabilization_version() -> String { } fn get_test_file_contents(lint_name: &str, header_commands: Option<&str>) -> String { - let mut contents = format!( - indoc! {" - #![allow(unused)] - #![warn(clippy::{})] - - fn main() {{ - // test code goes here - }} - "}, - lint_name + let mut contents = formatdoc!( + r#" + #![allow(unused)] + #![warn(clippy::{lint_name})] + + fn main() {{ + // test code goes here + }} + "# ); if let Some(header) = header_commands { - contents = format!("{}\n{}", header, contents); + contents = format!("{header}\n{contents}"); } contents } fn get_manifest_contents(lint_name: &str, hint: &str) -> String { - format!( - indoc! {r#" - # {} - - [package] - name = "{}" - version = "0.1.0" - publish = false - - [workspace] - "#}, - hint, lint_name + formatdoc!( + r#" + # {hint} + + [package] + name = "{lint_name}" + version = "0.1.0" + publish = false + + [workspace] + "# ) } @@ -236,76 +234,61 @@ fn get_lint_file_contents(lint: &LintData<'_>, enable_msrv: bool) -> String { let name_upper = lint_name.to_uppercase(); result.push_str(&if enable_msrv { - format!( - indoc! {" - use clippy_utils::msrvs; - {pass_import} - use rustc_lint::{{{context_import}, {pass_type}, LintContext}}; - use rustc_semver::RustcVersion; - use rustc_session::{{declare_tool_lint, impl_lint_pass}}; + formatdoc!( + r#" + use clippy_utils::msrvs; + {pass_import} + use rustc_lint::{{{context_import}, {pass_type}, LintContext}}; + use rustc_semver::RustcVersion; + use rustc_session::{{declare_tool_lint, impl_lint_pass}}; - "}, - pass_type = pass_type, - pass_import = pass_import, - context_import = context_import, + "# ) } else { - format!( - indoc! {" - {pass_import} - use rustc_lint::{{{context_import}, {pass_type}}}; - use rustc_session::{{declare_lint_pass, declare_tool_lint}}; - - "}, - pass_import = pass_import, - pass_type = pass_type, - context_import = context_import + formatdoc!( + r#" + {pass_import} + use rustc_lint::{{{context_import}, {pass_type}}}; + use rustc_session::{{declare_lint_pass, declare_tool_lint}}; + + "# ) }); let _ = write!(result, "{}", get_lint_declaration(&name_upper, category)); result.push_str(&if enable_msrv { - format!( - indoc! {" - pub struct {name_camel} {{ - msrv: Option, - }} + formatdoc!( + r#" + pub struct {name_camel} {{ + msrv: Option, + }} - impl {name_camel} {{ - #[must_use] - pub fn new(msrv: Option) -> Self {{ - Self {{ msrv }} - }} + impl {name_camel} {{ + #[must_use] + pub fn new(msrv: Option) -> Self {{ + Self {{ msrv }} }} + }} - impl_lint_pass!({name_camel} => [{name_upper}]); + impl_lint_pass!({name_camel} => [{name_upper}]); - impl {pass_type}{pass_lifetimes} for {name_camel} {{ - extract_msrv_attr!({context_import}); - }} + impl {pass_type}{pass_lifetimes} for {name_camel} {{ + extract_msrv_attr!({context_import}); + }} - // TODO: Add MSRV level to `clippy_utils/src/msrvs.rs` if needed. - // TODO: Add MSRV test to `tests/ui/min_rust_version_attr.rs`. - // TODO: Update msrv config comment in `clippy_lints/src/utils/conf.rs` - "}, - pass_type = pass_type, - pass_lifetimes = pass_lifetimes, - name_upper = name_upper, - name_camel = name_camel, - context_import = context_import, + // TODO: Add MSRV level to `clippy_utils/src/msrvs.rs` if needed. + // TODO: Add MSRV test to `tests/ui/min_rust_version_attr.rs`. + // TODO: Update msrv config comment in `clippy_lints/src/utils/conf.rs` + "# ) } else { - format!( - indoc! {" - declare_lint_pass!({name_camel} => [{name_upper}]); + formatdoc!( + r#" + declare_lint_pass!({name_camel} => [{name_upper}]); - impl {pass_type}{pass_lifetimes} for {name_camel} {{}} - "}, - pass_type = pass_type, - pass_lifetimes = pass_lifetimes, - name_upper = name_upper, - name_camel = name_camel, + impl {pass_type}{pass_lifetimes} for {name_camel} {{}} + "# ) }); @@ -313,8 +296,8 @@ fn get_lint_file_contents(lint: &LintData<'_>, enable_msrv: bool) -> String { } fn get_lint_declaration(name_upper: &str, category: &str) -> String { - format!( - indoc! {r#" + formatdoc!( + r#" declare_clippy_lint! {{ /// ### What it does /// @@ -328,15 +311,13 @@ fn get_lint_declaration(name_upper: &str, category: &str) -> String { /// ```rust /// // example code which does not raise clippy warning /// ``` - #[clippy::version = "{version}"] + #[clippy::version = "{}"] pub {name_upper}, {category}, "default lint description" }} - "#}, - version = get_stabilization_version(), - name_upper = name_upper, - category = category, + "#, + get_stabilization_version(), ) } @@ -350,7 +331,7 @@ fn create_lint_for_ty(lint: &LintData<'_>, enable_msrv: bool, ty: &str) -> io::R _ => {}, } - let ty_dir = lint.project_root.join(format!("clippy_lints/src/{}", ty)); + let ty_dir = lint.project_root.join(format!("clippy_lints/src/{ty}")); assert!( ty_dir.exists() && ty_dir.is_dir(), "Directory `{}` does not exist!", @@ -410,10 +391,10 @@ fn create_lint_for_ty(lint: &LintData<'_>, enable_msrv: bool, ty: &str) -> io::R } write_file(lint_file_path.as_path(), lint_file_contents)?; - println!("Generated lint file: `clippy_lints/src/{}/{}.rs`", ty, lint.name); + println!("Generated lint file: `clippy_lints/src/{ty}/{}.rs`", lint.name); println!( - "Be sure to add a call to `{}::check` in `clippy_lints/src/{}/mod.rs`!", - lint.name, ty + "Be sure to add a call to `{}::check` in `clippy_lints/src/{ty}/mod.rs`!", + lint.name ); Ok(()) @@ -540,7 +521,7 @@ fn setup_mod_file(path: &Path, lint: &LintData<'_>) -> io::Result<&'static str> .chain(std::iter::once(&*lint_name_upper)) .filter(|s| !s.is_empty()) { - let _ = write!(new_arr_content, "\n {},", ident); + let _ = write!(new_arr_content, "\n {ident},"); } new_arr_content.push('\n'); diff --git a/clippy_dev/src/serve.rs b/clippy_dev/src/serve.rs index f15f24da946..2e0794f12fa 100644 --- a/clippy_dev/src/serve.rs +++ b/clippy_dev/src/serve.rs @@ -10,8 +10,8 @@ use std::time::{Duration, SystemTime}; /// Panics if the python commands could not be spawned pub fn run(port: u16, lint: Option<&String>) -> ! { let mut url = Some(match lint { - None => format!("http://localhost:{}", port), - Some(lint) => format!("http://localhost:{}/#{}", port, lint), + None => format!("http://localhost:{port}"), + Some(lint) => format!("http://localhost:{port}/#{lint}"), }); loop { diff --git a/clippy_dev/src/setup/git_hook.rs b/clippy_dev/src/setup/git_hook.rs index 3fbb77d5923..1de5b1940ba 100644 --- a/clippy_dev/src/setup/git_hook.rs +++ b/clippy_dev/src/setup/git_hook.rs @@ -30,10 +30,7 @@ pub fn install_hook(force_override: bool) { println!("info: the hook can be removed with `cargo dev remove git-hook`"); println!("git hook successfully installed"); }, - Err(err) => eprintln!( - "error: unable to copy `{}` to `{}` ({})", - HOOK_SOURCE_FILE, HOOK_TARGET_FILE, err - ), + Err(err) => eprintln!("error: unable to copy `{HOOK_SOURCE_FILE}` to `{HOOK_TARGET_FILE}` ({err})"), } } @@ -77,7 +74,7 @@ pub fn remove_hook() { fn delete_git_hook_file(path: &Path) -> bool { if let Err(err) = fs::remove_file(path) { - eprintln!("error: unable to delete existing pre-commit git hook ({})", err); + eprintln!("error: unable to delete existing pre-commit git hook ({err})"); false } else { true diff --git a/clippy_dev/src/setup/intellij.rs b/clippy_dev/src/setup/intellij.rs index bf741e6d121..b64e79733eb 100644 --- a/clippy_dev/src/setup/intellij.rs +++ b/clippy_dev/src/setup/intellij.rs @@ -60,7 +60,7 @@ fn check_and_get_rustc_dir(rustc_path: &str) -> Result { path = absolute_path; }, Err(err) => { - eprintln!("error: unable to get the absolute path of rustc ({})", err); + eprintln!("error: unable to get the absolute path of rustc ({err})"); return Err(()); }, }; @@ -103,14 +103,14 @@ fn inject_deps_into_project(rustc_source_dir: &Path, project: &ClippyProjectInfo fn read_project_file(file_path: &str) -> Result { let path = Path::new(file_path); if !path.exists() { - eprintln!("error: unable to find the file `{}`", file_path); + eprintln!("error: unable to find the file `{file_path}`"); return Err(()); } match fs::read_to_string(path) { Ok(content) => Ok(content), Err(err) => { - eprintln!("error: the file `{}` could not be read ({})", file_path, err); + eprintln!("error: the file `{file_path}` could not be read ({err})"); Err(()) }, } @@ -124,10 +124,7 @@ fn inject_deps_into_manifest( ) -> std::io::Result<()> { // do not inject deps if we have already done so if cargo_toml.contains(RUSTC_PATH_SECTION) { - eprintln!( - "warn: dependencies are already setup inside {}, skipping file", - manifest_path - ); + eprintln!("warn: dependencies are already setup inside {manifest_path}, skipping file"); return Ok(()); } @@ -142,11 +139,7 @@ fn inject_deps_into_manifest( let new_deps = extern_crates.map(|dep| { // format the dependencies that are going to be put inside the Cargo.toml - format!( - "{dep} = {{ path = \"{source_path}/{dep}\" }}\n", - dep = dep, - source_path = rustc_source_dir.display() - ) + format!("{dep} = {{ path = \"{}/{dep}\" }}\n", rustc_source_dir.display()) }); // format a new [dependencies]-block with the new deps we need to inject @@ -163,11 +156,11 @@ fn inject_deps_into_manifest( // etc let new_manifest = cargo_toml.replacen("[dependencies]\n", &all_deps, 1); - // println!("{}", new_manifest); + // println!("{new_manifest}"); let mut file = File::create(manifest_path)?; file.write_all(new_manifest.as_bytes())?; - println!("info: successfully setup dependencies inside {}", manifest_path); + println!("info: successfully setup dependencies inside {manifest_path}"); Ok(()) } @@ -214,8 +207,8 @@ fn remove_rustc_src_from_project(project: &ClippyProjectInfo) -> bool { }, Err(err) => { eprintln!( - "error: unable to open file `{}` to remove rustc dependencies for {} ({})", - project.cargo_file, project.name, err + "error: unable to open file `{}` to remove rustc dependencies for {} ({err})", + project.cargo_file, project.name ); false }, diff --git a/clippy_dev/src/setup/vscode.rs b/clippy_dev/src/setup/vscode.rs index d59001b2c66..dbcdc9b59e5 100644 --- a/clippy_dev/src/setup/vscode.rs +++ b/clippy_dev/src/setup/vscode.rs @@ -17,10 +17,7 @@ pub fn install_tasks(force_override: bool) { println!("info: the task file can be removed with `cargo dev remove vscode-tasks`"); println!("vscode tasks successfully installed"); }, - Err(err) => eprintln!( - "error: unable to copy `{}` to `{}` ({})", - TASK_SOURCE_FILE, TASK_TARGET_FILE, err - ), + Err(err) => eprintln!("error: unable to copy `{TASK_SOURCE_FILE}` to `{TASK_TARGET_FILE}` ({err})"), } } @@ -44,23 +41,17 @@ fn check_install_precondition(force_override: bool) -> bool { return delete_vs_task_file(path); } - eprintln!( - "error: there is already a `task.json` file inside the `{}` directory", - VSCODE_DIR - ); + eprintln!("error: there is already a `task.json` file inside the `{VSCODE_DIR}` directory"); println!("info: use the `--force-override` flag to override the existing `task.json` file"); return false; } } else { match fs::create_dir(vs_dir_path) { Ok(_) => { - println!("info: created `{}` directory for clippy", VSCODE_DIR); + println!("info: created `{VSCODE_DIR}` directory for clippy"); }, Err(err) => { - eprintln!( - "error: the task target directory `{}` could not be created ({})", - VSCODE_DIR, err - ); + eprintln!("error: the task target directory `{VSCODE_DIR}` could not be created ({err})"); }, } } @@ -82,7 +73,7 @@ pub fn remove_tasks() { fn delete_vs_task_file(path: &Path) -> bool { if let Err(err) = fs::remove_file(path) { - eprintln!("error: unable to delete the existing `tasks.json` file ({})", err); + eprintln!("error: unable to delete the existing `tasks.json` file ({err})"); return false; } diff --git a/clippy_dev/src/update_lints.rs b/clippy_dev/src/update_lints.rs index b95061bf81a..93955bee3f4 100644 --- a/clippy_dev/src/update_lints.rs +++ b/clippy_dev/src/update_lints.rs @@ -86,7 +86,7 @@ fn generate_lint_files( ) .sorted() { - writeln!(res, "[`{}`]: {}#{}", lint, DOCS_LINK, lint).unwrap(); + writeln!(res, "[`{lint}`]: {DOCS_LINK}#{lint}").unwrap(); } }, ); @@ -99,7 +99,7 @@ fn generate_lint_files( "// end lints modules, do not remove this comment, it’s used in `update_lints`", |res| { for lint_mod in usable_lints.iter().map(|l| &l.module).unique().sorted() { - writeln!(res, "mod {};", lint_mod).unwrap(); + writeln!(res, "mod {lint_mod};").unwrap(); } }, ); @@ -129,7 +129,7 @@ fn generate_lint_files( for (lint_group, lints) in Lint::by_lint_group(usable_lints.into_iter().chain(internal_lints)) { let content = gen_lint_group_list(&lint_group, lints.iter()); process_file( - &format!("clippy_lints/src/lib.register_{}.rs", lint_group), + &format!("clippy_lints/src/lib.register_{lint_group}.rs"), update_mode, &content, ); @@ -190,9 +190,9 @@ fn print_lint_names(header: &str, lints: &BTreeSet) -> bool { if lints.is_empty() { return false; } - println!("{}", header); + println!("{header}"); for lint in lints.iter().sorted() { - println!(" {}", lint); + println!(" {lint}"); } println!(); true @@ -205,16 +205,16 @@ pub fn print_lints() { let grouped_by_lint_group = Lint::by_lint_group(usable_lints.into_iter()); for (lint_group, mut lints) in grouped_by_lint_group { - println!("\n## {}", lint_group); + println!("\n## {lint_group}"); lints.sort_by_key(|l| l.name.clone()); for lint in lints { - println!("* [{}]({}#{}) ({})", lint.name, DOCS_LINK, lint.name, lint.desc); + println!("* [{}]({DOCS_LINK}#{}) ({})", lint.name, lint.name, lint.desc); } } - println!("there are {} lints", usable_lint_count); + println!("there are {usable_lint_count} lints"); } /// Runs the `rename_lint` command. @@ -235,10 +235,10 @@ pub fn print_lints() { #[allow(clippy::too_many_lines)] pub fn rename(old_name: &str, new_name: &str, uplift: bool) { if let Some((prefix, _)) = old_name.split_once("::") { - panic!("`{}` should not contain the `{}` prefix", old_name, prefix); + panic!("`{old_name}` should not contain the `{prefix}` prefix"); } if let Some((prefix, _)) = new_name.split_once("::") { - panic!("`{}` should not contain the `{}` prefix", new_name, prefix); + panic!("`{new_name}` should not contain the `{prefix}` prefix"); } let (mut lints, deprecated_lints, mut renamed_lints) = gather_all(); @@ -251,14 +251,14 @@ pub fn rename(old_name: &str, new_name: &str, uplift: bool) { found_new_name = true; } } - let old_lint_index = old_lint_index.unwrap_or_else(|| panic!("could not find lint `{}`", old_name)); + let old_lint_index = old_lint_index.unwrap_or_else(|| panic!("could not find lint `{old_name}`")); let lint = RenamedLint { - old_name: format!("clippy::{}", old_name), + old_name: format!("clippy::{old_name}"), new_name: if uplift { new_name.into() } else { - format!("clippy::{}", new_name) + format!("clippy::{new_name}") }, }; @@ -266,13 +266,11 @@ pub fn rename(old_name: &str, new_name: &str, uplift: bool) { // case. assert!( !renamed_lints.iter().any(|l| lint.old_name == l.old_name), - "`{}` has already been renamed", - old_name + "`{old_name}` has already been renamed" ); assert!( !deprecated_lints.iter().any(|l| lint.old_name == l.name), - "`{}` has already been deprecated", - old_name + "`{old_name}` has already been deprecated" ); // Update all lint level attributes. (`clippy::lint_name`) @@ -309,14 +307,12 @@ pub fn rename(old_name: &str, new_name: &str, uplift: bool) { if uplift { write_file(Path::new("tests/ui/rename.rs"), &gen_renamed_lints_test(&renamed_lints)); println!( - "`{}` has be uplifted. All the code inside `clippy_lints` related to it needs to be removed manually.", - old_name + "`{old_name}` has be uplifted. All the code inside `clippy_lints` related to it needs to be removed manually." ); } else if found_new_name { write_file(Path::new("tests/ui/rename.rs"), &gen_renamed_lints_test(&renamed_lints)); println!( - "`{}` is already defined. The old linting code inside `clippy_lints` needs to be updated/removed manually.", - new_name + "`{new_name}` is already defined. The old linting code inside `clippy_lints` needs to be updated/removed manually." ); } else { // Rename the lint struct and source files sharing a name with the lint. @@ -327,16 +323,16 @@ pub fn rename(old_name: &str, new_name: &str, uplift: bool) { // Rename test files. only rename `.stderr` and `.fixed` files if the new test name doesn't exist. if try_rename_file( - Path::new(&format!("tests/ui/{}.rs", old_name)), - Path::new(&format!("tests/ui/{}.rs", new_name)), + Path::new(&format!("tests/ui/{old_name}.rs")), + Path::new(&format!("tests/ui/{new_name}.rs")), ) { try_rename_file( - Path::new(&format!("tests/ui/{}.stderr", old_name)), - Path::new(&format!("tests/ui/{}.stderr", new_name)), + Path::new(&format!("tests/ui/{old_name}.stderr")), + Path::new(&format!("tests/ui/{new_name}.stderr")), ); try_rename_file( - Path::new(&format!("tests/ui/{}.fixed", old_name)), - Path::new(&format!("tests/ui/{}.fixed", new_name)), + Path::new(&format!("tests/ui/{old_name}.fixed")), + Path::new(&format!("tests/ui/{new_name}.fixed")), ); } @@ -344,8 +340,8 @@ pub fn rename(old_name: &str, new_name: &str, uplift: bool) { let replacements; let replacements = if lint.module == old_name && try_rename_file( - Path::new(&format!("clippy_lints/src/{}.rs", old_name)), - Path::new(&format!("clippy_lints/src/{}.rs", new_name)), + Path::new(&format!("clippy_lints/src/{old_name}.rs")), + Path::new(&format!("clippy_lints/src/{new_name}.rs")), ) { // Edit the module name in the lint list. Note there could be multiple lints. for lint in lints.iter_mut().filter(|l| l.module == old_name) { @@ -356,14 +352,14 @@ pub fn rename(old_name: &str, new_name: &str, uplift: bool) { } else if !lint.module.contains("::") // Catch cases like `methods/lint_name.rs` where the lint is stored in `methods/mod.rs` && try_rename_file( - Path::new(&format!("clippy_lints/src/{}/{}.rs", lint.module, old_name)), - Path::new(&format!("clippy_lints/src/{}/{}.rs", lint.module, new_name)), + Path::new(&format!("clippy_lints/src/{}/{old_name}.rs", lint.module)), + Path::new(&format!("clippy_lints/src/{}/{new_name}.rs", lint.module)), ) { // Edit the module name in the lint list. Note there could be multiple lints, or none. - let renamed_mod = format!("{}::{}", lint.module, old_name); + let renamed_mod = format!("{}::{old_name}", lint.module); for lint in lints.iter_mut().filter(|l| l.module == renamed_mod) { - lint.module = format!("{}::{}", lint.module, new_name); + lint.module = format!("{}::{new_name}", lint.module); } replacements = [(&*old_name_upper, &*new_name_upper), (old_name, new_name)]; replacements.as_slice() @@ -379,7 +375,7 @@ pub fn rename(old_name: &str, new_name: &str, uplift: bool) { } generate_lint_files(UpdateMode::Change, &lints, &deprecated_lints, &renamed_lints); - println!("{} has been successfully renamed", old_name); + println!("{old_name} has been successfully renamed"); } println!("note: `cargo uitest` still needs to be run to update the test results"); @@ -408,7 +404,7 @@ pub fn deprecate(name: &str, reason: Option<&String>) { }); generate_lint_files(UpdateMode::Change, &lints, &deprecated_lints, &renamed_lints); - println!("info: `{}` has successfully been deprecated", name); + println!("info: `{name}` has successfully been deprecated"); if reason == DEFAULT_DEPRECATION_REASON { println!("note: the deprecation reason must be updated in `clippy_lints/src/deprecated_lints.rs`"); @@ -421,7 +417,7 @@ pub fn deprecate(name: &str, reason: Option<&String>) { let name_upper = name.to_uppercase(); let (mut lints, deprecated_lints, renamed_lints) = gather_all(); - let Some(lint) = lints.iter().find(|l| l.name == name_lower) else { eprintln!("error: failed to find lint `{}`", name); return; }; + let Some(lint) = lints.iter().find(|l| l.name == name_lower) else { eprintln!("error: failed to find lint `{name}`"); return; }; let mod_path = { let mut mod_path = PathBuf::from(format!("clippy_lints/src/{}", lint.module)); @@ -450,7 +446,7 @@ fn remove_lint_declaration(name: &str, path: &Path, lints: &mut Vec) -> io } fn remove_test_assets(name: &str) { - let test_file_stem = format!("tests/ui/{}", name); + let test_file_stem = format!("tests/ui/{name}"); let path = Path::new(&test_file_stem); // Some lints have their own directories, delete them @@ -512,8 +508,7 @@ fn remove_lint_declaration(name: &str, path: &Path, lints: &mut Vec) -> io fs::read_to_string(path).unwrap_or_else(|_| panic!("failed to read `{}`", path.to_string_lossy())); eprintln!( - "warn: you will have to manually remove any code related to `{}` from `{}`", - name, + "warn: you will have to manually remove any code related to `{name}` from `{}`", path.display() ); @@ -528,7 +523,7 @@ fn remove_lint_declaration(name: &str, path: &Path, lints: &mut Vec) -> io content.replace_range(lint.declaration_range.clone(), ""); // Remove the module declaration (mod xyz;) - let mod_decl = format!("\nmod {};", name); + let mod_decl = format!("\nmod {name};"); content = content.replacen(&mod_decl, "", 1); remove_impl_lint_pass(&lint.name.to_uppercase(), &mut content); @@ -621,13 +616,13 @@ fn round_to_fifty(count: usize) -> usize { fn process_file(path: impl AsRef, update_mode: UpdateMode, content: &str) { if update_mode == UpdateMode::Check { let old_content = - fs::read_to_string(&path).unwrap_or_else(|e| panic!("Cannot read from {}: {}", path.as_ref().display(), e)); + fs::read_to_string(&path).unwrap_or_else(|e| panic!("Cannot read from {}: {e}", path.as_ref().display())); if content != old_content { exit_with_failure(); } } else { fs::write(&path, content.as_bytes()) - .unwrap_or_else(|e| panic!("Cannot write to {}: {}", path.as_ref().display(), e)); + .unwrap_or_else(|e| panic!("Cannot write to {}: {e}", path.as_ref().display())); } } @@ -731,11 +726,10 @@ fn gen_lint_group_list<'a>(group_name: &str, lints: impl Iterator( if !is_public { output.push_str(" #[cfg(feature = \"internal\")]\n"); } - let _ = writeln!(output, " {}::{},", module_name, lint_name); + let _ = writeln!(output, " {module_name}::{lint_name},"); } output.push_str("])\n"); @@ -841,7 +835,7 @@ fn gather_all() -> (Vec, Vec, Vec) { for (rel_path, file) in clippy_lints_src_files() { let path = file.path(); let contents = - fs::read_to_string(path).unwrap_or_else(|e| panic!("Cannot read from `{}`: {}", path.display(), e)); + fs::read_to_string(path).unwrap_or_else(|e| panic!("Cannot read from `{}`: {e}", path.display())); let module = rel_path .components() .map(|c| c.as_os_str().to_str().unwrap()) @@ -1050,7 +1044,7 @@ fn remove_line_splices(s: &str) -> String { .trim_matches('#') .strip_prefix('"') .and_then(|s| s.strip_suffix('"')) - .unwrap_or_else(|| panic!("expected quoted string, found `{}`", s)); + .unwrap_or_else(|| panic!("expected quoted string, found `{s}`")); let mut res = String::with_capacity(s.len()); unescape::unescape_literal(s, unescape::Mode::Str, &mut |range, ch| { if ch.is_ok() { @@ -1076,10 +1070,10 @@ fn replace_region_in_file( end: &str, write_replacement: impl FnMut(&mut String), ) { - let contents = fs::read_to_string(path).unwrap_or_else(|e| panic!("Cannot read from `{}`: {}", path.display(), e)); + let contents = fs::read_to_string(path).unwrap_or_else(|e| panic!("Cannot read from `{}`: {e}", path.display())); let new_contents = match replace_region_in_text(&contents, start, end, write_replacement) { Ok(x) => x, - Err(delim) => panic!("Couldn't find `{}` in file `{}`", delim, path.display()), + Err(delim) => panic!("Couldn't find `{delim}` in file `{}`", path.display()), }; match update_mode { @@ -1087,7 +1081,7 @@ fn replace_region_in_file( UpdateMode::Check => (), UpdateMode::Change => { if let Err(e) = fs::write(path, new_contents.as_bytes()) { - panic!("Cannot write to `{}`: {}", path.display(), e); + panic!("Cannot write to `{}`: {e}", path.display()); } }, } @@ -1135,7 +1129,7 @@ fn try_rename_file(old_name: &Path, new_name: &Path) -> bool { #[allow(clippy::needless_pass_by_value)] fn panic_file(error: io::Error, name: &Path, action: &str) -> ! { - panic!("failed to {} file `{}`: {}", action, name.display(), error) + panic!("failed to {action} file `{}`: {error}", name.display()) } fn rewrite_file(path: &Path, f: impl FnOnce(&str) -> Option) { diff --git a/clippy_lints/src/utils/internal_lints.rs b/clippy_lints/src/utils/internal_lints.rs index 17d9a041857..5332779c1c0 100644 --- a/clippy_lints/src/utils/internal_lints.rs +++ b/clippy_lints/src/utils/internal_lints.rs @@ -530,7 +530,7 @@ impl<'tcx> LateLintPass<'tcx> for LintWithoutLintPass { cx, LINT_WITHOUT_LINT_PASS, lint_span, - &format!("the lint `{}` is not added to any `LintPass`", lint_name), + &format!("the lint `{lint_name}` is not added to any `LintPass`"), ); } } @@ -666,7 +666,7 @@ impl<'tcx> LateLintPass<'tcx> for CompilerLintFunctions { path.ident.span, "usage of a compiler lint function", None, - &format!("please use the Clippy variant of this function: `{}`", sugg), + &format!("please use the Clippy variant of this function: `{sugg}`"), ); } } @@ -854,13 +854,8 @@ fn suggest_help( "this call is collapsible", "collapse into", format!( - "span_lint_and_help({}, {}, {}, {}, {}, {})", - and_then_snippets.cx, - and_then_snippets.lint, - and_then_snippets.span, - and_then_snippets.msg, - &option_span, - help + "span_lint_and_help({}, {}, {}, {}, {}, {help})", + and_then_snippets.cx, and_then_snippets.lint, and_then_snippets.span, and_then_snippets.msg, &option_span, ), Applicability::MachineApplicable, ); @@ -886,13 +881,8 @@ fn suggest_note( "this call is collapsible", "collapse into", format!( - "span_lint_and_note({}, {}, {}, {}, {}, {})", - and_then_snippets.cx, - and_then_snippets.lint, - and_then_snippets.span, - and_then_snippets.msg, - note_span, - note + "span_lint_and_note({}, {}, {}, {}, {note_span}, {note})", + and_then_snippets.cx, and_then_snippets.lint, and_then_snippets.span, and_then_snippets.msg, ), Applicability::MachineApplicable, ); @@ -927,7 +917,7 @@ impl<'tcx> LateLintPass<'tcx> for MatchTypeOnDiagItem { expr.span, "usage of `clippy_utils::ty::match_type()` on a type diagnostic item", "try", - format!("clippy_utils::ty::is_type_diagnostic_item({}, {}, sym::{})", cx_snippet, ty_snippet, item_name), + format!("clippy_utils::ty::is_type_diagnostic_item({cx_snippet}, {ty_snippet}, sym::{item_name})"), Applicability::MaybeIncorrect, ); } diff --git a/clippy_lints/src/utils/internal_lints/metadata_collector.rs b/clippy_lints/src/utils/internal_lints/metadata_collector.rs index 342f627e382..c84191bb010 100644 --- a/clippy_lints/src/utils/internal_lints/metadata_collector.rs +++ b/clippy_lints/src/utils/internal_lints/metadata_collector.rs @@ -64,46 +64,6 @@ const DEFAULT_LINT_LEVELS: &[(&str, &str)] = &[ /// This prefix is in front of the lint groups in the lint store. The prefix will be trimmed /// to only keep the actual lint group in the output. const CLIPPY_LINT_GROUP_PREFIX: &str = "clippy::"; - -/// This template will be used to format the configuration section in the lint documentation. -/// The `configurations` parameter will be replaced with one or multiple formatted -/// `ClippyConfiguration` instances. See `CONFIGURATION_VALUE_TEMPLATE` for further customizations -macro_rules! CONFIGURATION_SECTION_TEMPLATE { - () => { - r#" -### Configuration -This lint has the following configuration variables: - -{configurations} -"# - }; -} -/// This template will be used to format an individual `ClippyConfiguration` instance in the -/// lint documentation. -/// -/// The format function will provide strings for the following parameters: `name`, `ty`, `doc` and -/// `default` -macro_rules! CONFIGURATION_VALUE_TEMPLATE { - () => { - "* `{name}`: `{ty}`: {doc} (defaults to `{default}`)\n" - }; -} - -macro_rules! RENAMES_SECTION_TEMPLATE { - () => { - r#" -### Past names - -{names} -"# - }; -} -macro_rules! RENAME_VALUE_TEMPLATE { - () => { - "* `{name}`\n" - }; -} - const LINT_EMISSION_FUNCTIONS: [&[&str]; 7] = [ &["clippy_utils", "diagnostics", "span_lint"], &["clippy_utils", "diagnostics", "span_lint_and_help"], @@ -205,7 +165,16 @@ impl MetadataCollector { .filter(|config| config.lints.iter().any(|lint| lint == lint_name)) .map(ToString::to_string) .reduce(|acc, x| acc + &x) - .map(|configurations| format!(CONFIGURATION_SECTION_TEMPLATE!(), configurations = configurations)) + .map(|configurations| { + format!( + r#" +### Configuration +This lint has the following configuration variables: + +{configurations} +"# + ) + }) } } @@ -291,16 +260,13 @@ fn replace_produces(lint_name: &str, docs: &mut String, clippy_project_root: &Pa continue; } - panic!("lint `{}` has an unterminated code block", lint_name) + panic!("lint `{lint_name}` has an unterminated code block") } break; }, Some(line) if line.trim_start() == "{{produces}}" => { - panic!( - "lint `{}` has marker {{{{produces}}}} with an ignored or missing code block", - lint_name - ) + panic!("lint `{lint_name}` has marker {{{{produces}}}} with an ignored or missing code block") }, Some(line) => { let line = line.trim(); @@ -319,7 +285,7 @@ fn replace_produces(lint_name: &str, docs: &mut String, clippy_project_root: &Pa match lines.next() { Some(line) if line.trim_start() == "```" => break, Some(line) => example.push(line), - None => panic!("lint `{}` has an unterminated code block", lint_name), + None => panic!("lint `{lint_name}` has an unterminated code block"), } } @@ -336,10 +302,9 @@ fn replace_produces(lint_name: &str, docs: &mut String, clippy_project_root: &Pa Produces\n\ \n\ ```text\n\ - {}\n\ + {output}\n\ ```\n\ - ", - output + " ), ); @@ -394,7 +359,7 @@ fn get_lint_output(lint_name: &str, example: &[&mut String], clippy_project_root panic!("failed to write to `{}`: {e}", file.as_path().to_string_lossy()); } - let prefixed_name = format!("{}{lint_name}", CLIPPY_LINT_GROUP_PREFIX); + let prefixed_name = format!("{CLIPPY_LINT_GROUP_PREFIX}{lint_name}"); let mut cmd = Command::new("cargo"); @@ -417,7 +382,7 @@ fn get_lint_output(lint_name: &str, example: &[&mut String], clippy_project_root let output = cmd .arg(file.as_path()) .output() - .unwrap_or_else(|e| panic!("failed to run `{:?}`: {e}", cmd)); + .unwrap_or_else(|e| panic!("failed to run `{cmd:?}`: {e}")); let tmp_file_path = file.to_string_lossy(); let stderr = std::str::from_utf8(&output.stderr).unwrap(); @@ -441,8 +406,7 @@ fn get_lint_output(lint_name: &str, example: &[&mut String], clippy_project_root let rendered: Vec<&str> = msgs.iter().filter_map(|msg| msg["rendered"].as_str()).collect(); let non_json: Vec<&str> = stderr.lines().filter(|line| !line.starts_with('{')).collect(); panic!( - "did not find lint `{}` in output of example, got:\n{}\n{}", - lint_name, + "did not find lint `{lint_name}` in output of example, got:\n{}\n{}", non_json.join("\n"), rendered.join("\n") ); @@ -588,13 +552,10 @@ fn to_kebab(config_name: &str) -> String { impl fmt::Display for ClippyConfiguration { fn fmt(&self, f: &mut std::fmt::Formatter<'_>) -> fmt::Result { - write!( + writeln!( f, - CONFIGURATION_VALUE_TEMPLATE!(), - name = self.name, - ty = self.config_type, - doc = self.doc, - default = self.default + "* `{}`: `{}`: {} (defaults to `{}`)", + self.name, self.config_type, self.doc, self.default ) } } @@ -811,7 +772,7 @@ fn get_lint_group_and_level_or_lint( lint_collection_error_item( cx, item, - &format!("Unable to determine lint level for found group `{}`", group), + &format!("Unable to determine lint level for found group `{group}`"), ); None } @@ -869,7 +830,7 @@ fn collect_renames(lints: &mut Vec) { if name == lint_name; if let Some(past_name) = k.strip_prefix(CLIPPY_LINT_GROUP_PREFIX); then { - write!(collected, RENAME_VALUE_TEMPLATE!(), name = past_name).unwrap(); + writeln!(collected, "* `{past_name}`").unwrap(); names.push(past_name.to_string()); } } @@ -882,7 +843,15 @@ fn collect_renames(lints: &mut Vec) { } if !collected.is_empty() { - write!(&mut lint.docs, RENAMES_SECTION_TEMPLATE!(), names = collected).unwrap(); + write!( + &mut lint.docs, + r#" +### Past names + +{collected} +"# + ) + .unwrap(); } } } @@ -895,7 +864,7 @@ fn lint_collection_error_item(cx: &LateContext<'_>, item: &Item<'_>, message: &s cx, INTERNAL_METADATA_COLLECTOR, item.ident.span, - &format!("metadata collection error for `{}`: {}", item.ident.name, message), + &format!("metadata collection error for `{}`: {message}", item.ident.name), ); } -- cgit 1.4.1-3-g733a5 From 9cc8da222b3893bc13bc13c8827e93f8ea246854 Mon Sep 17 00:00:00 2001 From: Samuel Moelius Date: Fri, 7 Oct 2022 05:07:09 -0400 Subject: Fix adjacent code --- clippy_dev/src/serve.rs | 2 +- clippy_dev/src/update_lints.rs | 2 +- clippy_lints/src/lib.rs | 8 ++++---- clippy_lints/src/nonstandard_macro_braces.rs | 2 +- clippy_utils/src/attrs.rs | 2 +- clippy_utils/src/lib.rs | 2 +- lintcheck/src/main.rs | 30 ++++++++++++---------------- tests/compile-test.rs | 2 +- tests/versioncheck.rs | 2 +- 9 files changed, 24 insertions(+), 28 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/serve.rs b/clippy_dev/src/serve.rs index 2e0794f12fa..535c25e69f1 100644 --- a/clippy_dev/src/serve.rs +++ b/clippy_dev/src/serve.rs @@ -49,7 +49,7 @@ fn mtime(path: impl AsRef) -> SystemTime { .into_iter() .flatten() .flatten() - .map(|entry| mtime(&entry.path())) + .map(|entry| mtime(entry.path())) .max() .unwrap_or(SystemTime::UNIX_EPOCH) } else { diff --git a/clippy_dev/src/update_lints.rs b/clippy_dev/src/update_lints.rs index 0eb443167ec..8d1bfacd1dc 100644 --- a/clippy_dev/src/update_lints.rs +++ b/clippy_dev/src/update_lints.rs @@ -128,7 +128,7 @@ fn generate_lint_files( for (lint_group, lints) in Lint::by_lint_group(usable_lints.into_iter().chain(internal_lints)) { let content = gen_lint_group_list(&lint_group, lints.iter()); process_file( - &format!("clippy_lints/src/lib.register_{lint_group}.rs"), + format!("clippy_lints/src/lib.register_{lint_group}.rs"), update_mode, &content, ); diff --git a/clippy_lints/src/lib.rs b/clippy_lints/src/lib.rs index d9dfb4fc4e0..ebb0f14fef5 100644 --- a/clippy_lints/src/lib.rs +++ b/clippy_lints/src/lib.rs @@ -417,7 +417,7 @@ pub fn register_pre_expansion_lints(store: &mut rustc_lint::LintStore, sess: &Se let msrv = conf.msrv.as_ref().and_then(|s| { parse_msrv(s, None, None).or_else(|| { - sess.err(&format!( + sess.err(format!( "error reading Clippy's configuration file. `{s}` is not a valid Rust version" )); None @@ -433,7 +433,7 @@ fn read_msrv(conf: &Conf, sess: &Session) -> Option { .and_then(|v| parse_msrv(&v, None, None)); let clippy_msrv = conf.msrv.as_ref().and_then(|s| { parse_msrv(s, None, None).or_else(|| { - sess.err(&format!( + sess.err(format!( "error reading Clippy's configuration file. `{s}` is not a valid Rust version" )); None @@ -444,7 +444,7 @@ fn read_msrv(conf: &Conf, sess: &Session) -> Option { if let Some(clippy_msrv) = clippy_msrv { // if both files have an msrv, let's compare them and emit a warning if they differ if clippy_msrv != cargo_msrv { - sess.warn(&format!( + sess.warn(format!( "the MSRV in `clippy.toml` and `Cargo.toml` differ; using `{clippy_msrv}` from `clippy.toml`" )); } @@ -473,7 +473,7 @@ pub fn read_conf(sess: &Session) -> Conf { let TryConf { conf, errors, warnings } = utils::conf::read(&file_name); // all conf errors are non-fatal, we just use the default conf in case of error for error in errors { - sess.err(&format!( + sess.err(format!( "error reading Clippy's configuration file `{}`: {}", file_name.display(), format_error(error) diff --git a/clippy_lints/src/nonstandard_macro_braces.rs b/clippy_lints/src/nonstandard_macro_braces.rs index 0ca0befc135..6c909e5ed73 100644 --- a/clippy_lints/src/nonstandard_macro_braces.rs +++ b/clippy_lints/src/nonstandard_macro_braces.rs @@ -266,7 +266,7 @@ impl<'de> Deserialize<'de> for MacroMatcher { .iter() .find(|b| b.0 == brace) .map(|(o, c)| ((*o).to_owned(), (*c).to_owned())) - .ok_or_else(|| de::Error::custom(&format!("expected one of `(`, `{{`, `[` found `{brace}`")))?, + .ok_or_else(|| de::Error::custom(format!("expected one of `(`, `{{`, `[` found `{brace}`")))?, }) } } diff --git a/clippy_utils/src/attrs.rs b/clippy_utils/src/attrs.rs index d9b22664fd2..cd8575c90e8 100644 --- a/clippy_utils/src/attrs.rs +++ b/clippy_utils/src/attrs.rs @@ -136,7 +136,7 @@ pub fn get_unique_inner_attr(sess: &Session, attrs: &[ast::Attribute], name: &'s .emit(); }, ast::AttrStyle::Outer => { - sess.span_err(attr.span, &format!("`{name}` cannot be an outer attribute")); + sess.span_err(attr.span, format!("`{name}` cannot be an outer attribute")); }, } } diff --git a/clippy_utils/src/lib.rs b/clippy_utils/src/lib.rs index 3597c58e072..5c8ffffc8c8 100644 --- a/clippy_utils/src/lib.rs +++ b/clippy_utils/src/lib.rs @@ -125,7 +125,7 @@ pub fn parse_msrv(msrv: &str, sess: Option<&Session>, span: Option) -> Opt return Some(version); } else if let Some(sess) = sess { if let Some(span) = span { - sess.span_err(span, &format!("`{msrv}` is not a valid Rust version")); + sess.span_err(span, format!("`{msrv}` is not a valid Rust version")); } } None diff --git a/lintcheck/src/main.rs b/lintcheck/src/main.rs index cc2b3e1acec..95b20d7f024 100644 --- a/lintcheck/src/main.rs +++ b/lintcheck/src/main.rs @@ -345,7 +345,7 @@ impl Crate { clippy_args.push(opt); } } else { - clippy_args.extend(&["-Wclippy::pedantic", "-Wclippy::cargo"]) + clippy_args.extend(["-Wclippy::pedantic", "-Wclippy::cargo"]) } if lint_filter.is_empty() { @@ -457,15 +457,11 @@ fn build_clippy() { /// Read a `lintcheck_crates.toml` file fn read_crates(toml_path: &Path) -> (Vec, RecursiveOptions) { let toml_content: String = - std::fs::read_to_string(&toml_path).unwrap_or_else(|_| panic!("Failed to read {}", toml_path.display())); + std::fs::read_to_string(toml_path).unwrap_or_else(|_| panic!("Failed to read {}", toml_path.display())); let crate_list: SourceList = toml::from_str(&toml_content).unwrap_or_else(|e| panic!("Failed to parse {}: \n{}", toml_path.display(), e)); // parse the hashmap of the toml file into a list of crates - let tomlcrates: Vec = crate_list - .crates - .into_iter() - .map(|(_cratename, tomlcrate)| tomlcrate) - .collect(); + let tomlcrates: Vec = crate_list.crates.into_values().collect(); // flatten TomlCrates into CrateSources (one TomlCrates may represent several versions of a crate => // multiple Cratesources) @@ -602,10 +598,10 @@ fn main() { ) { let shared_target_dir = "target/lintcheck/shared_target_dir"; // if we get an Err here, the shared target dir probably does simply not exist - if let Ok(metadata) = std::fs::metadata(&shared_target_dir) { + if let Ok(metadata) = std::fs::metadata(shared_target_dir) { if metadata.is_dir() { println!("Clippy is newer than lint check logs, clearing lintcheck shared target dir..."); - std::fs::remove_dir_all(&shared_target_dir) + std::fs::remove_dir_all(shared_target_dir) .expect("failed to remove target/lintcheck/shared_target_dir"); } } @@ -779,7 +775,7 @@ fn read_stats_from_file(file_path: &Path) -> HashMap { fn print_stats(old_stats: HashMap, new_stats: HashMap<&String, usize>, lint_filter: &Vec) { let same_in_both_hashmaps = old_stats .iter() - .filter(|(old_key, old_val)| new_stats.get::<&String>(&old_key) == Some(old_val)) + .filter(|(old_key, old_val)| new_stats.get::<&String>(old_key) == Some(old_val)) .map(|(k, v)| (k.to_string(), *v)) .collect::>(); @@ -797,7 +793,7 @@ fn print_stats(old_stats: HashMap, new_stats: HashMap<&String, us // list all new counts (key is in new stats but not in old stats) new_stats_deduped .iter() - .filter(|(new_key, _)| old_stats_deduped.get::(&new_key).is_none()) + .filter(|(new_key, _)| old_stats_deduped.get::(new_key).is_none()) .for_each(|(new_key, new_value)| { println!("{} 0 => {}", new_key, new_value); }); @@ -805,16 +801,16 @@ fn print_stats(old_stats: HashMap, new_stats: HashMap<&String, us // list all changed counts (key is in both maps but value differs) new_stats_deduped .iter() - .filter(|(new_key, _new_val)| old_stats_deduped.get::(&new_key).is_some()) + .filter(|(new_key, _new_val)| old_stats_deduped.get::(new_key).is_some()) .for_each(|(new_key, new_val)| { - let old_val = old_stats_deduped.get::(&new_key).unwrap(); + let old_val = old_stats_deduped.get::(new_key).unwrap(); println!("{} {} => {}", new_key, old_val, new_val); }); // list all gone counts (key is in old status but not in new stats) old_stats_deduped .iter() - .filter(|(old_key, _)| new_stats_deduped.get::<&String>(&old_key).is_none()) + .filter(|(old_key, _)| new_stats_deduped.get::<&String>(old_key).is_none()) .filter(|(old_key, _)| lint_filter.is_empty() || lint_filter.contains(old_key)) .for_each(|(old_key, old_value)| { println!("{} {} => 0", old_key, old_value); @@ -832,12 +828,12 @@ fn create_dirs(krate_download_dir: &Path, extract_dir: &Path) { panic!("cannot create lintcheck target dir"); } }); - std::fs::create_dir(&krate_download_dir).unwrap_or_else(|err| { + std::fs::create_dir(krate_download_dir).unwrap_or_else(|err| { if err.kind() != ErrorKind::AlreadyExists { panic!("cannot create crate download dir"); } }); - std::fs::create_dir(&extract_dir).unwrap_or_else(|err| { + std::fs::create_dir(extract_dir).unwrap_or_else(|err| { if err.kind() != ErrorKind::AlreadyExists { panic!("cannot create crate extraction dir"); } @@ -863,7 +859,7 @@ fn lintcheck_test() { "lintcheck/test_sources.toml", ]; let status = std::process::Command::new("cargo") - .args(&args) + .args(args) .current_dir("..") // repo root .status(); //.output(); diff --git a/tests/compile-test.rs b/tests/compile-test.rs index fa769222d1a..c10ee969c01 100644 --- a/tests/compile-test.rs +++ b/tests/compile-test.rs @@ -283,7 +283,7 @@ fn run_ui_cargo() { env::set_current_dir(&src_path)?; let cargo_toml_path = case.path().join("Cargo.toml"); - let cargo_content = fs::read(&cargo_toml_path)?; + let cargo_content = fs::read(cargo_toml_path)?; let cargo_parsed: toml::Value = toml::from_str( std::str::from_utf8(&cargo_content).expect("`Cargo.toml` is not a valid utf-8 file!"), ) diff --git a/tests/versioncheck.rs b/tests/versioncheck.rs index 9e07769a8e4..a6d8d0307ce 100644 --- a/tests/versioncheck.rs +++ b/tests/versioncheck.rs @@ -48,7 +48,7 @@ fn check_that_clippy_has_the_same_major_version_as_rustc() { // `RUSTC_REAL` if Clippy is build in the Rust repo with `./x.py`. let rustc = std::env::var("RUSTC_REAL").unwrap_or_else(|_| "rustc".to_string()); let rustc_version = String::from_utf8( - std::process::Command::new(&rustc) + std::process::Command::new(rustc) .arg("--version") .output() .expect("failed to run `rustc --version`") -- cgit 1.4.1-3-g733a5 From f48d13f8d1b442c38755cfe87c28f56e1dca10cc Mon Sep 17 00:00:00 2001 From: est31 Date: Mon, 10 Oct 2022 22:37:42 +0200 Subject: Replace manual let else patterns with let else --- clippy_dev/src/setup/intellij.rs | 17 +++++------------ clippy_dev/src/update_lints.rs | 8 +++----- clippy_lints/src/derive.rs | 5 +---- clippy_lints/src/disallowed_methods.rs | 5 ++--- clippy_lints/src/entry.rs | 20 ++++++++------------ clippy_lints/src/eta_reduction.rs | 5 ++--- clippy_lints/src/functions/too_many_lines.rs | 5 ++--- clippy_lints/src/invalid_upcast_comparisons.rs | 4 +--- clippy_lints/src/large_enum_variant.rs | 5 ++--- clippy_lints/src/loops/while_let_on_iterator.rs | 5 ++--- clippy_lints/src/matches/manual_utils.rs | 5 ++--- clippy_lints/src/matches/match_same_arms.rs | 6 ++---- clippy_lints/src/methods/into_iter_on_ref.rs | 5 ++--- .../src/methods/manual_saturating_arithmetic.rs | 10 ++-------- clippy_lints/src/methods/mod.rs | 5 ++--- clippy_lints/src/methods/str_splitn.rs | 4 +--- clippy_lints/src/misc_early/literal_suffix.rs | 4 +--- .../src/misc_early/mixed_case_hex_literals.rs | 4 +--- clippy_lints/src/mismatching_type_param_order.rs | 5 ++--- clippy_lints/src/mixed_read_write_in_expression.rs | 5 +---- clippy_lints/src/needless_for_each.rs | 5 ++--- clippy_lints/src/non_copy_const.rs | 5 ++--- clippy_lints/src/non_octal_unix_permissions.rs | 17 +++++------------ clippy_lints/src/ptr.rs | 9 +++------ clippy_lints/src/ptr_offset_with_cast.rs | 10 ++++------ clippy_lints/src/shadow.rs | 5 +---- clippy_lints/src/types/rc_buffer.rs | 10 ++-------- clippy_lints/src/types/redundant_allocation.rs | 5 ++--- clippy_lints/src/unnested_or_patterns.rs | 5 ++--- clippy_lints/src/unused_io_amount.rs | 5 ++--- clippy_lints/src/useless_conversion.rs | 5 ++--- clippy_lints/src/utils/internal_lints.rs | 10 ++-------- 32 files changed, 73 insertions(+), 150 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/setup/intellij.rs b/clippy_dev/src/setup/intellij.rs index b64e79733eb..efdb158c21e 100644 --- a/clippy_dev/src/setup/intellij.rs +++ b/clippy_dev/src/setup/intellij.rs @@ -36,9 +36,8 @@ impl ClippyProjectInfo { } pub fn setup_rustc_src(rustc_path: &str) { - let rustc_source_dir = match check_and_get_rustc_dir(rustc_path) { - Ok(path) => path, - Err(_) => return, + let Ok(rustc_source_dir) = check_and_get_rustc_dir(rustc_path) else { + return }; for project in CLIPPY_PROJECTS { @@ -172,14 +171,10 @@ pub fn remove_rustc_src() { } fn remove_rustc_src_from_project(project: &ClippyProjectInfo) -> bool { - let mut cargo_content = if let Ok(content) = read_project_file(project.cargo_file) { - content - } else { + let Ok(mut cargo_content) = read_project_file(project.cargo_file) else { return false; }; - let section_start = if let Some(section_start) = cargo_content.find(RUSTC_PATH_SECTION) { - section_start - } else { + let Some(section_start) = cargo_content.find(RUSTC_PATH_SECTION) else { println!( "info: dependencies could not be found in `{}` for {}, skipping file", project.cargo_file, project.name @@ -187,9 +182,7 @@ fn remove_rustc_src_from_project(project: &ClippyProjectInfo) -> bool { return true; }; - let end_point = if let Some(end_point) = cargo_content.find(DEPENDENCIES_SECTION) { - end_point - } else { + let Some(end_point) = cargo_content.find(DEPENDENCIES_SECTION) else { eprintln!( "error: the end of the rustc dependencies section could not be found in `{}`", project.cargo_file diff --git a/clippy_dev/src/update_lints.rs b/clippy_dev/src/update_lints.rs index 8d1bfacd1dc..e690bc369cd 100644 --- a/clippy_dev/src/update_lints.rs +++ b/clippy_dev/src/update_lints.rs @@ -869,13 +869,11 @@ fn clippy_lints_src_files() -> impl Iterator { macro_rules! match_tokens { ($iter:ident, $($token:ident $({$($fields:tt)*})? $(($capture:ident))?)*) => { { - $($(let $capture =)? if let Some(LintDeclSearchResult { + $(#[allow(clippy::redundant_pattern)] let Some(LintDeclSearchResult { token_kind: TokenKind::$token $({$($fields)*})?, - content: _x, + content: $($capture @)? _, .. - }) = $iter.next() { - _x - } else { + }) = $iter.next() else { continue; };)* #[allow(clippy::unused_unit)] diff --git a/clippy_lints/src/derive.rs b/clippy_lints/src/derive.rs index 3fac93dcc90..fad984d05ca 100644 --- a/clippy_lints/src/derive.rs +++ b/clippy_lints/src/derive.rs @@ -339,10 +339,7 @@ fn check_copy_clone<'tcx>(cx: &LateContext<'tcx>, item: &Item<'_>, trait_ref: &h Some(id) if trait_ref.trait_def_id() == Some(id) => id, _ => return, }; - let copy_id = match cx.tcx.lang_items().copy_trait() { - Some(id) => id, - None => return, - }; + let Some(copy_id) = cx.tcx.lang_items().copy_trait() else { return }; let (ty_adt, ty_subs) = match *ty.kind() { // Unions can't derive clone. ty::Adt(adt, subs) if !adt.is_union() => (adt, subs), diff --git a/clippy_lints/src/disallowed_methods.rs b/clippy_lints/src/disallowed_methods.rs index 1a381f92c03..6ac85606d9c 100644 --- a/clippy_lints/src/disallowed_methods.rs +++ b/clippy_lints/src/disallowed_methods.rs @@ -94,9 +94,8 @@ impl<'tcx> LateLintPass<'tcx> for DisallowedMethods { } else { path_def_id(cx, expr) }; - let def_id = match uncalled_path.or_else(|| fn_def_id(cx, expr)) { - Some(def_id) => def_id, - None => return, + let Some(def_id) = uncalled_path.or_else(|| fn_def_id(cx, expr)) else { + return }; let conf = match self.disallowed.get(&def_id) { Some(&index) => &self.conf_disallowed[index], diff --git a/clippy_lints/src/entry.rs b/clippy_lints/src/entry.rs index 9c834cf0144..b44e6243588 100644 --- a/clippy_lints/src/entry.rs +++ b/clippy_lints/src/entry.rs @@ -65,28 +65,24 @@ declare_lint_pass!(HashMapPass => [MAP_ENTRY]); impl<'tcx> LateLintPass<'tcx> for HashMapPass { #[expect(clippy::too_many_lines)] fn check_expr(&mut self, cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) { - let (cond_expr, then_expr, else_expr) = match higher::If::hir(expr) { - Some(higher::If { cond, then, r#else }) => (cond, then, r#else), - _ => return, + let Some(higher::If { cond: cond_expr, then: then_expr, r#else: else_expr }) = higher::If::hir(expr) else { + return }; - let (map_ty, contains_expr) = match try_parse_contains(cx, cond_expr) { - Some(x) => x, - None => return, + let Some((map_ty, contains_expr)) = try_parse_contains(cx, cond_expr) else { + return }; - let then_search = match find_insert_calls(cx, &contains_expr, then_expr) { - Some(x) => x, - None => return, + let Some(then_search) = find_insert_calls(cx, &contains_expr, then_expr) else { + return }; let mut app = Applicability::MachineApplicable; let map_str = snippet_with_context(cx, contains_expr.map.span, contains_expr.call_ctxt, "..", &mut app).0; let key_str = snippet_with_context(cx, contains_expr.key.span, contains_expr.call_ctxt, "..", &mut app).0; let sugg = if let Some(else_expr) = else_expr { - let else_search = match find_insert_calls(cx, &contains_expr, else_expr) { - Some(search) => search, - None => return, + let Some(else_search) = find_insert_calls(cx, &contains_expr, else_expr) else { + return; }; if then_search.edits.is_empty() && else_search.edits.is_empty() { diff --git a/clippy_lints/src/eta_reduction.rs b/clippy_lints/src/eta_reduction.rs index 3732410e71e..7b9786d7e57 100644 --- a/clippy_lints/src/eta_reduction.rs +++ b/clippy_lints/src/eta_reduction.rs @@ -213,9 +213,8 @@ fn check_sig<'tcx>(cx: &LateContext<'tcx>, closure_ty: Ty<'tcx>, call_ty: Ty<'tc if !closure_ty.has_late_bound_regions() { return true; } - let substs = match closure_ty.kind() { - ty::Closure(_, substs) => substs, - _ => return false, + let ty::Closure(_, substs) = closure_ty.kind() else { + return false; }; let closure_sig = cx.tcx.signature_unclosure(substs.as_closure().sig(), Unsafety::Normal); cx.tcx.erase_late_bound_regions(closure_sig) == cx.tcx.erase_late_bound_regions(call_sig) diff --git a/clippy_lints/src/functions/too_many_lines.rs b/clippy_lints/src/functions/too_many_lines.rs index f83f8b40f94..bd473ac7e51 100644 --- a/clippy_lints/src/functions/too_many_lines.rs +++ b/clippy_lints/src/functions/too_many_lines.rs @@ -22,9 +22,8 @@ pub(super) fn check_fn( return; } - let code_snippet = match snippet_opt(cx, body.value.span) { - Some(s) => s, - _ => return, + let Some(code_snippet) = snippet_opt(cx, body.value.span) else { + return }; let mut line_count: u64 = 0; let mut in_comment = false; diff --git a/clippy_lints/src/invalid_upcast_comparisons.rs b/clippy_lints/src/invalid_upcast_comparisons.rs index 36e03e50a8e..0ef77e03de9 100644 --- a/clippy_lints/src/invalid_upcast_comparisons.rs +++ b/clippy_lints/src/invalid_upcast_comparisons.rs @@ -145,9 +145,7 @@ impl<'tcx> LateLintPass<'tcx> for InvalidUpcastComparisons { fn check_expr(&mut self, cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) { if let ExprKind::Binary(ref cmp, lhs, rhs) = expr.kind { let normalized = comparisons::normalize_comparison(cmp.node, lhs, rhs); - let (rel, normalized_lhs, normalized_rhs) = if let Some(val) = normalized { - val - } else { + let Some((rel, normalized_lhs, normalized_rhs)) = normalized else { return; }; diff --git a/clippy_lints/src/large_enum_variant.rs b/clippy_lints/src/large_enum_variant.rs index eb13d0869c0..8ed7e4bb196 100644 --- a/clippy_lints/src/large_enum_variant.rs +++ b/clippy_lints/src/large_enum_variant.rs @@ -124,9 +124,8 @@ impl<'tcx> LateLintPass<'tcx> for LargeEnumVariant { } if let ItemKind::Enum(ref def, _) = item.kind { let ty = cx.tcx.type_of(item.def_id); - let (adt, subst) = match ty.kind() { - Adt(adt, subst) => (adt, subst), - _ => panic!("already checked whether this is an enum"), + let Adt(adt, subst) = ty.kind() else { + panic!("already checked whether this is an enum") }; if adt.variants().len() <= 1 { return; diff --git a/clippy_lints/src/loops/while_let_on_iterator.rs b/clippy_lints/src/loops/while_let_on_iterator.rs index 153f97e4e66..55989f8a446 100644 --- a/clippy_lints/src/loops/while_let_on_iterator.rs +++ b/clippy_lints/src/loops/while_let_on_iterator.rs @@ -331,9 +331,8 @@ fn needs_mutable_borrow(cx: &LateContext<'_>, iter_expr: &IterExpr, loop_expr: & } if let Some(e) = get_enclosing_loop_or_multi_call_closure(cx, loop_expr) { - let local_id = match iter_expr.path { - Res::Local(id) => id, - _ => return true, + let Res::Local(local_id) = iter_expr.path else { + return true }; let mut v = NestedLoopVisitor { cx, diff --git a/clippy_lints/src/matches/manual_utils.rs b/clippy_lints/src/matches/manual_utils.rs index 792908aa7df..5b7644a5383 100644 --- a/clippy_lints/src/matches/manual_utils.rs +++ b/clippy_lints/src/matches/manual_utils.rs @@ -60,9 +60,8 @@ where return None; } - let some_expr = match get_some_expr_fn(cx, some_pat, some_expr, expr_ctxt) { - Some(expr) => expr, - None => return None, + let Some(some_expr) = get_some_expr_fn(cx, some_pat, some_expr, expr_ctxt) else { + return None; }; // These two lints will go back and forth with each other. diff --git a/clippy_lints/src/matches/match_same_arms.rs b/clippy_lints/src/matches/match_same_arms.rs index 37049f83577..168c1e4d2e6 100644 --- a/clippy_lints/src/matches/match_same_arms.rs +++ b/clippy_lints/src/matches/match_same_arms.rs @@ -221,7 +221,6 @@ fn iter_matching_struct_fields<'a>( #[expect(clippy::similar_names)] impl<'a> NormalizedPat<'a> { - #[expect(clippy::too_many_lines)] fn from_pat(cx: &LateContext<'_>, arena: &'a DroplessArena, pat: &'a Pat<'_>) -> Self { match pat.kind { PatKind::Wild | PatKind::Binding(.., None) => Self::Wild, @@ -235,9 +234,8 @@ impl<'a> NormalizedPat<'a> { Self::Struct(cx.qpath_res(path, pat.hir_id).opt_def_id(), fields) }, PatKind::TupleStruct(ref path, pats, wild_idx) => { - let adt = match cx.typeck_results().pat_ty(pat).ty_adt_def() { - Some(x) => x, - None => return Self::Wild, + let Some(adt) = cx.typeck_results().pat_ty(pat).ty_adt_def() else { + return Self::Wild }; let (var_id, variant) = if adt.is_enum() { match cx.qpath_res(path, pat.hir_id).opt_def_id() { diff --git a/clippy_lints/src/methods/into_iter_on_ref.rs b/clippy_lints/src/methods/into_iter_on_ref.rs index be56b63506a..8adf9e37059 100644 --- a/clippy_lints/src/methods/into_iter_on_ref.rs +++ b/clippy_lints/src/methods/into_iter_on_ref.rs @@ -42,9 +42,8 @@ pub(super) fn check( fn ty_has_iter_method(cx: &LateContext<'_>, self_ref_ty: Ty<'_>) -> Option<(Symbol, &'static str)> { has_iter_method(cx, self_ref_ty).map(|ty_name| { - let mutbl = match self_ref_ty.kind() { - ty::Ref(_, _, mutbl) => mutbl, - _ => unreachable!(), + let ty::Ref(_, _, mutbl) = self_ref_ty.kind() else { + unreachable!() }; let method_name = match mutbl { hir::Mutability::Not => "iter", diff --git a/clippy_lints/src/methods/manual_saturating_arithmetic.rs b/clippy_lints/src/methods/manual_saturating_arithmetic.rs index ec694cf6882..b80541b8647 100644 --- a/clippy_lints/src/methods/manual_saturating_arithmetic.rs +++ b/clippy_lints/src/methods/manual_saturating_arithmetic.rs @@ -21,11 +21,7 @@ pub fn check( return; } - let mm = if let Some(mm) = is_min_or_max(cx, unwrap_arg) { - mm - } else { - return; - }; + let Some(mm) = is_min_or_max(cx, unwrap_arg) else { return }; if ty.is_signed() { use self::{ @@ -33,9 +29,7 @@ pub fn check( Sign::{Neg, Pos}, }; - let sign = if let Some(sign) = lit_sign(arith_rhs) { - sign - } else { + let Some(sign) = lit_sign(arith_rhs) else { return; }; diff --git a/clippy_lints/src/methods/mod.rs b/clippy_lints/src/methods/mod.rs index cfcf9596c50..78c1b33ed97 100644 --- a/clippy_lints/src/methods/mod.rs +++ b/clippy_lints/src/methods/mod.rs @@ -3851,9 +3851,8 @@ impl SelfKind { hir::Mutability::Mut => &paths::ASMUT_TRAIT, }; - let trait_def_id = match get_trait_def_id(cx, trait_path) { - Some(did) => did, - None => return false, + let Some(trait_def_id) = get_trait_def_id(cx, trait_path) else { + return false }; implements_trait(cx, ty, trait_def_id, &[parent_ty.into()]) } diff --git a/clippy_lints/src/methods/str_splitn.rs b/clippy_lints/src/methods/str_splitn.rs index ae3594bd36c..1acac59144c 100644 --- a/clippy_lints/src/methods/str_splitn.rs +++ b/clippy_lints/src/methods/str_splitn.rs @@ -289,9 +289,7 @@ fn parse_iter_usage<'tcx>( ) -> Option { let (kind, span) = match iter.next() { Some((_, Node::Expr(e))) if e.span.ctxt() == ctxt => { - let (name, args) = if let ExprKind::MethodCall(name, _, [args @ ..], _) = e.kind { - (name, args) - } else { + let ExprKind::MethodCall(name, _, [args @ ..], _) = e.kind else { return None; }; let did = cx.typeck_results().type_dependent_def_id(e.hir_id)?; diff --git a/clippy_lints/src/misc_early/literal_suffix.rs b/clippy_lints/src/misc_early/literal_suffix.rs index 62c6ca32d31..27e7f8505eb 100644 --- a/clippy_lints/src/misc_early/literal_suffix.rs +++ b/clippy_lints/src/misc_early/literal_suffix.rs @@ -6,9 +6,7 @@ use rustc_lint::EarlyContext; use super::{SEPARATED_LITERAL_SUFFIX, UNSEPARATED_LITERAL_SUFFIX}; pub(super) fn check(cx: &EarlyContext<'_>, lit: &Lit, lit_snip: &str, suffix: &str, sugg_type: &str) { - let maybe_last_sep_idx = if let Some(val) = lit_snip.len().checked_sub(suffix.len() + 1) { - val - } else { + let Some(maybe_last_sep_idx) = lit_snip.len().checked_sub(suffix.len() + 1) else { return; // It's useless so shouldn't lint. }; // Do not lint when literal is unsuffixed. diff --git a/clippy_lints/src/misc_early/mixed_case_hex_literals.rs b/clippy_lints/src/misc_early/mixed_case_hex_literals.rs index 80e24213100..263ee1e945a 100644 --- a/clippy_lints/src/misc_early/mixed_case_hex_literals.rs +++ b/clippy_lints/src/misc_early/mixed_case_hex_literals.rs @@ -5,9 +5,7 @@ use rustc_lint::EarlyContext; use super::MIXED_CASE_HEX_LITERALS; pub(super) fn check(cx: &EarlyContext<'_>, lit: &Lit, suffix: &str, lit_snip: &str) { - let maybe_last_sep_idx = if let Some(val) = lit_snip.len().checked_sub(suffix.len() + 1) { - val - } else { + let Some(maybe_last_sep_idx) = lit_snip.len().checked_sub(suffix.len() + 1) else { return; // It's useless so shouldn't lint. }; if maybe_last_sep_idx <= 2 { diff --git a/clippy_lints/src/mismatching_type_param_order.rs b/clippy_lints/src/mismatching_type_param_order.rs index 6dd76a6531e..9de4b56b77b 100644 --- a/clippy_lints/src/mismatching_type_param_order.rs +++ b/clippy_lints/src/mismatching_type_param_order.rs @@ -70,9 +70,8 @@ impl<'tcx> LateLintPass<'tcx> for TypeParamMismatch { // find the type that the Impl is for // only lint on struct/enum/union for now - let defid = match path.res { - Res::Def(DefKind::Struct | DefKind::Enum | DefKind::Union, defid) => defid, - _ => return, + let Res::Def(DefKind::Struct | DefKind::Enum | DefKind::Union, defid) = path.res else { + return }; // get the names of the generic parameters in the type diff --git a/clippy_lints/src/mixed_read_write_in_expression.rs b/clippy_lints/src/mixed_read_write_in_expression.rs index a2419c277e9..6752976348f 100644 --- a/clippy_lints/src/mixed_read_write_in_expression.rs +++ b/clippy_lints/src/mixed_read_write_in_expression.rs @@ -190,10 +190,7 @@ fn check_for_unsequenced_reads(vis: &mut ReadVisitor<'_, '_>) { if parent_id == cur_id { break; } - let parent_node = match map.find(parent_id) { - Some(parent) => parent, - None => break, - }; + let Some(parent_node) = map.find(parent_id) else { break }; let stop_early = match parent_node { Node::Expr(expr) => check_expr(vis, expr), diff --git a/clippy_lints/src/needless_for_each.rs b/clippy_lints/src/needless_for_each.rs index 3233d87c073..c3b633fd6a0 100644 --- a/clippy_lints/src/needless_for_each.rs +++ b/clippy_lints/src/needless_for_each.rs @@ -49,9 +49,8 @@ declare_lint_pass!(NeedlessForEach => [NEEDLESS_FOR_EACH]); impl<'tcx> LateLintPass<'tcx> for NeedlessForEach { fn check_stmt(&mut self, cx: &LateContext<'tcx>, stmt: &'tcx Stmt<'_>) { - let expr = match stmt.kind { - StmtKind::Expr(expr) | StmtKind::Semi(expr) => expr, - _ => return, + let (StmtKind::Expr(expr) | StmtKind::Semi(expr)) = stmt.kind else { + return }; if_chain! { diff --git a/clippy_lints/src/non_copy_const.rs b/clippy_lints/src/non_copy_const.rs index 2c839d029c6..a6742824bc5 100644 --- a/clippy_lints/src/non_copy_const.rs +++ b/clippy_lints/src/non_copy_const.rs @@ -357,9 +357,8 @@ impl<'tcx> LateLintPass<'tcx> for NonCopyConst { } // Make sure it is a const item. - let item_def_id = match cx.qpath_res(qpath, expr.hir_id) { - Res::Def(DefKind::Const | DefKind::AssocConst, did) => did, - _ => return, + let Res::Def(DefKind::Const | DefKind::AssocConst, item_def_id) = cx.qpath_res(qpath, expr.hir_id) else { + return }; // Climb up to resolve any field access and explicit referencing. diff --git a/clippy_lints/src/non_octal_unix_permissions.rs b/clippy_lints/src/non_octal_unix_permissions.rs index 1a765b14892..2ecb0487484 100644 --- a/clippy_lints/src/non_octal_unix_permissions.rs +++ b/clippy_lints/src/non_octal_unix_permissions.rs @@ -55,9 +55,8 @@ impl<'tcx> LateLintPass<'tcx> for NonOctalUnixPermissions { if let ExprKind::Lit(_) = param.kind; then { - let snip = match snippet_opt(cx, param.span) { - Some(s) => s, - _ => return, + let Some(snip) = snippet_opt(cx, param.span) else { + return }; if !snip.starts_with("0o") { @@ -72,16 +71,10 @@ impl<'tcx> LateLintPass<'tcx> for NonOctalUnixPermissions { if let Some(def_id) = cx.qpath_res(path, func.hir_id).opt_def_id(); if match_def_path(cx, def_id, &paths::PERMISSIONS_FROM_MODE); if let ExprKind::Lit(_) = param.kind; - + if let Some(snip) = snippet_opt(cx, param.span); + if !snip.starts_with("0o"); then { - let snip = match snippet_opt(cx, param.span) { - Some(s) => s, - _ => return, - }; - - if !snip.starts_with("0o") { - show_error(cx, param); - } + show_error(cx, param); } } }, diff --git a/clippy_lints/src/ptr.rs b/clippy_lints/src/ptr.rs index d296a150b46..2d80236327a 100644 --- a/clippy_lints/src/ptr.rs +++ b/clippy_lints/src/ptr.rs @@ -552,9 +552,8 @@ fn check_ptr_arg_usage<'tcx>(cx: &LateContext<'tcx>, body: &'tcx Body<'_>, args: } // Check if this is local we care about - let args_idx = match path_to_local(e).and_then(|id| self.bindings.get(&id)) { - Some(&i) => i, - None => return walk_expr(self, e), + let Some(&args_idx) = path_to_local(e).and_then(|id| self.bindings.get(&id)) else { + return walk_expr(self, e); }; let args = &self.args[args_idx]; let result = &mut self.results[args_idx]; @@ -609,9 +608,7 @@ fn check_ptr_arg_usage<'tcx>(cx: &LateContext<'tcx>, body: &'tcx Body<'_>, args: } } - let id = if let Some(x) = self.cx.typeck_results().type_dependent_def_id(e.hir_id) { - x - } else { + let Some(id) = self.cx.typeck_results().type_dependent_def_id(e.hir_id) else { set_skip_flag(); return; }; diff --git a/clippy_lints/src/ptr_offset_with_cast.rs b/clippy_lints/src/ptr_offset_with_cast.rs index b0a5d1a6758..72dda67c72b 100644 --- a/clippy_lints/src/ptr_offset_with_cast.rs +++ b/clippy_lints/src/ptr_offset_with_cast.rs @@ -49,15 +49,13 @@ declare_lint_pass!(PtrOffsetWithCast => [PTR_OFFSET_WITH_CAST]); impl<'tcx> LateLintPass<'tcx> for PtrOffsetWithCast { fn check_expr(&mut self, cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) { // Check if the expressions is a ptr.offset or ptr.wrapping_offset method call - let (receiver_expr, arg_expr, method) = match expr_as_ptr_offset_call(cx, expr) { - Some(call_arg) => call_arg, - None => return, + let Some((receiver_expr, arg_expr, method)) = expr_as_ptr_offset_call(cx, expr) else { + return }; // Check if the argument to the method call is a cast from usize - let cast_lhs_expr = match expr_as_cast_from_usize(cx, arg_expr) { - Some(cast_lhs_expr) => cast_lhs_expr, - None => return, + let Some(cast_lhs_expr) = expr_as_cast_from_usize(cx, arg_expr) else { + return }; let msg = format!("use of `{method}` with a `usize` casted to an `isize`"); diff --git a/clippy_lints/src/shadow.rs b/clippy_lints/src/shadow.rs index 5dcdab5b8ab..87f966ced0d 100644 --- a/clippy_lints/src/shadow.rs +++ b/clippy_lints/src/shadow.rs @@ -106,10 +106,7 @@ impl_lint_pass!(Shadow => [SHADOW_SAME, SHADOW_REUSE, SHADOW_UNRELATED]); impl<'tcx> LateLintPass<'tcx> for Shadow { fn check_pat(&mut self, cx: &LateContext<'tcx>, pat: &'tcx Pat<'_>) { - let (id, ident) = match pat.kind { - PatKind::Binding(_, hir_id, ident, _) => (hir_id, ident), - _ => return, - }; + let PatKind::Binding(_, id, ident, _) = pat.kind else { return }; if pat.span.desugaring_kind().is_some() { return; diff --git a/clippy_lints/src/types/rc_buffer.rs b/clippy_lints/src/types/rc_buffer.rs index 6b9de64e24c..e39fdc1ea70 100644 --- a/clippy_lints/src/types/rc_buffer.rs +++ b/clippy_lints/src/types/rc_buffer.rs @@ -26,10 +26,7 @@ pub(super) fn check(cx: &LateContext<'_>, hir_ty: &hir::Ty<'_>, qpath: &QPath<'_ if !cx.tcx.is_diagnostic_item(sym::Vec, id) { return false; } - let qpath = match &ty.kind { - TyKind::Path(qpath) => qpath, - _ => return false, - }; + let TyKind::Path(qpath) = &ty.kind else { return false }; let inner_span = match qpath_generic_tys(qpath).next() { Some(ty) => ty.span, None => return false, @@ -65,10 +62,7 @@ pub(super) fn check(cx: &LateContext<'_>, hir_ty: &hir::Ty<'_>, qpath: &QPath<'_ if !cx.tcx.is_diagnostic_item(sym::Vec, id) { return false; } - let qpath = match &ty.kind { - TyKind::Path(qpath) => qpath, - _ => return false, - }; + let TyKind::Path(qpath) = &ty.kind else { return false }; let inner_span = match qpath_generic_tys(qpath).next() { Some(ty) => ty.span, None => return false, diff --git a/clippy_lints/src/types/redundant_allocation.rs b/clippy_lints/src/types/redundant_allocation.rs index ecb67200539..92d2c48a589 100644 --- a/clippy_lints/src/types/redundant_allocation.rs +++ b/clippy_lints/src/types/redundant_allocation.rs @@ -47,9 +47,8 @@ pub(super) fn check(cx: &LateContext<'_>, hir_ty: &hir::Ty<'_>, qpath: &QPath<'_ _ => return false, }; - let inner_qpath = match &ty.kind { - TyKind::Path(inner_qpath) => inner_qpath, - _ => return false, + let TyKind::Path(inner_qpath) = &ty.kind else { + return false }; let inner_span = match qpath_generic_tys(inner_qpath).next() { Some(ty) => { diff --git a/clippy_lints/src/unnested_or_patterns.rs b/clippy_lints/src/unnested_or_patterns.rs index fb73c386640..b305dae7608 100644 --- a/clippy_lints/src/unnested_or_patterns.rs +++ b/clippy_lints/src/unnested_or_patterns.rs @@ -163,9 +163,8 @@ fn unnest_or_patterns(pat: &mut P) -> bool { noop_visit_pat(p, self); // Don't have an or-pattern? Just quit early on. - let alternatives = match &mut p.kind { - Or(ps) => ps, - _ => return, + let Or(alternatives) = &mut p.kind else { + return }; // Collapse or-patterns directly nested in or-patterns. diff --git a/clippy_lints/src/unused_io_amount.rs b/clippy_lints/src/unused_io_amount.rs index 8bcdff66331..92053cec59f 100644 --- a/clippy_lints/src/unused_io_amount.rs +++ b/clippy_lints/src/unused_io_amount.rs @@ -47,9 +47,8 @@ declare_lint_pass!(UnusedIoAmount => [UNUSED_IO_AMOUNT]); impl<'tcx> LateLintPass<'tcx> for UnusedIoAmount { fn check_stmt(&mut self, cx: &LateContext<'_>, s: &hir::Stmt<'_>) { - let expr = match s.kind { - hir::StmtKind::Semi(expr) | hir::StmtKind::Expr(expr) => expr, - _ => return, + let (hir::StmtKind::Semi(expr) | hir::StmtKind::Expr(expr)) = s.kind else { + return }; match expr.kind { diff --git a/clippy_lints/src/useless_conversion.rs b/clippy_lints/src/useless_conversion.rs index a82643a59f9..1f69db1cbca 100644 --- a/clippy_lints/src/useless_conversion.rs +++ b/clippy_lints/src/useless_conversion.rs @@ -55,9 +55,8 @@ impl<'tcx> LateLintPass<'tcx> for UselessConversion { match e.kind { ExprKind::Match(_, arms, MatchSource::TryDesugar) => { - let e = match arms[0].body.kind { - ExprKind::Ret(Some(e)) | ExprKind::Break(_, Some(e)) => e, - _ => return, + let (ExprKind::Ret(Some(e)) | ExprKind::Break(_, Some(e))) = arms[0].body.kind else { + return }; if let ExprKind::Call(_, [arg, ..]) = e.kind { self.try_desugar_arm.push(arg.hir_id); diff --git a/clippy_lints/src/utils/internal_lints.rs b/clippy_lints/src/utils/internal_lints.rs index 85bcbc7ad23..0d908bf2a83 100644 --- a/clippy_lints/src/utils/internal_lints.rs +++ b/clippy_lints/src/utils/internal_lints.rs @@ -1402,18 +1402,12 @@ impl<'tcx> LateLintPass<'tcx> for IfChainStyle { } else { return; }; - let then_block = match then.kind { - ExprKind::Block(block, _) => block, - _ => return, - }; + let ExprKind::Block(then_block, _) = then.kind else { return }; let if_chain_span = is_expn_of(expr.span, "if_chain"); if !els { check_nested_if_chains(cx, expr, then_block, if_chain_span); } - let if_chain_span = match if_chain_span { - None => return, - Some(span) => span, - }; + let Some(if_chain_span) = if_chain_span else { return }; // check for `if a && b;` if_chain! { if let ExprKind::Binary(op, _, _) = cond.kind; -- cgit 1.4.1-3-g733a5 From a201518a8a1f52c8893fdd3bcd259e2258fbb4d9 Mon Sep 17 00:00:00 2001 From: Alex Macleod Date: Sun, 23 Oct 2022 20:32:26 +0000 Subject: Generate lint categories and explanations with `declare_clippy_lint` Changes it to be a proc_macro rather than macro_rules --- clippy_dev/src/update_lints.rs | 253 ++--------- clippy_lints/Cargo.toml | 1 + clippy_lints/src/declared_lints.rs | 620 +++++++++++++++++++++++++++ clippy_lints/src/lib.register_all.rs | 370 ---------------- clippy_lints/src/lib.register_cargo.rs | 11 - clippy_lints/src/lib.register_complexity.rs | 111 ----- clippy_lints/src/lib.register_correctness.rs | 78 ---- clippy_lints/src/lib.register_internal.rs | 22 - clippy_lints/src/lib.register_lints.rs | 620 --------------------------- clippy_lints/src/lib.register_nursery.rs | 41 -- clippy_lints/src/lib.register_pedantic.rs | 100 ----- clippy_lints/src/lib.register_perf.rs | 34 -- clippy_lints/src/lib.register_restriction.rs | 90 ---- clippy_lints/src/lib.register_style.rs | 132 ------ clippy_lints/src/lib.register_suspicious.rs | 39 -- clippy_lints/src/lib.rs | 231 +++++----- declare_clippy_lint/Cargo.toml | 13 + declare_clippy_lint/src/lib.rs | 173 ++++++++ src/docs.rs | 606 -------------------------- src/main.rs | 4 +- tests/versioncheck.rs | 15 +- 21 files changed, 958 insertions(+), 2606 deletions(-) create mode 100644 clippy_lints/src/declared_lints.rs delete mode 100644 clippy_lints/src/lib.register_all.rs delete mode 100644 clippy_lints/src/lib.register_cargo.rs delete mode 100644 clippy_lints/src/lib.register_complexity.rs delete mode 100644 clippy_lints/src/lib.register_correctness.rs delete mode 100644 clippy_lints/src/lib.register_internal.rs delete mode 100644 clippy_lints/src/lib.register_lints.rs delete mode 100644 clippy_lints/src/lib.register_nursery.rs delete mode 100644 clippy_lints/src/lib.register_pedantic.rs delete mode 100644 clippy_lints/src/lib.register_perf.rs delete mode 100644 clippy_lints/src/lib.register_restriction.rs delete mode 100644 clippy_lints/src/lib.register_style.rs delete mode 100644 clippy_lints/src/lib.register_suspicious.rs create mode 100644 declare_clippy_lint/Cargo.toml create mode 100644 declare_clippy_lint/src/lib.rs delete mode 100644 src/docs.rs (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/update_lints.rs b/clippy_dev/src/update_lints.rs index e690bc369cd..3cdbb42d44d 100644 --- a/clippy_dev/src/update_lints.rs +++ b/clippy_dev/src/update_lints.rs @@ -3,7 +3,7 @@ use aho_corasick::AhoCorasickBuilder; use indoc::writedoc; use itertools::Itertools; use rustc_lexer::{tokenize, unescape, LiteralKind, TokenKind}; -use std::collections::{BTreeSet, HashMap, HashSet}; +use std::collections::{HashMap, HashSet}; use std::ffi::OsStr; use std::fmt::Write; use std::fs::{self, OpenOptions}; @@ -104,9 +104,9 @@ fn generate_lint_files( ); process_file( - "clippy_lints/src/lib.register_lints.rs", + "clippy_lints/src/declared_lints.rs", update_mode, - &gen_register_lint_list(internal_lints.iter(), usable_lints.iter()), + &gen_declared_lints(internal_lints.iter(), usable_lints.iter()), ); process_file( "clippy_lints/src/lib.deprecated.rs", @@ -114,26 +114,6 @@ fn generate_lint_files( &gen_deprecated(deprecated_lints), ); - let all_group_lints = usable_lints.iter().filter(|l| { - matches!( - &*l.group, - "correctness" | "suspicious" | "style" | "complexity" | "perf" - ) - }); - let content = gen_lint_group_list("all", all_group_lints); - process_file("clippy_lints/src/lib.register_all.rs", update_mode, &content); - - update_docs(update_mode, &usable_lints); - - for (lint_group, lints) in Lint::by_lint_group(usable_lints.into_iter().chain(internal_lints)) { - let content = gen_lint_group_list(&lint_group, lints.iter()); - process_file( - format!("clippy_lints/src/lib.register_{lint_group}.rs"), - update_mode, - &content, - ); - } - let content = gen_deprecated_lints_test(deprecated_lints); process_file("tests/ui/deprecated.rs", update_mode, &content); @@ -141,62 +121,6 @@ fn generate_lint_files( process_file("tests/ui/rename.rs", update_mode, &content); } -fn update_docs(update_mode: UpdateMode, usable_lints: &[Lint]) { - replace_region_in_file(update_mode, Path::new("src/docs.rs"), "docs! {\n", "\n}\n", |res| { - for name in usable_lints.iter().map(|lint| lint.name.clone()).sorted() { - writeln!(res, r#" "{name}","#).unwrap(); - } - }); - - if update_mode == UpdateMode::Check { - let mut extra = BTreeSet::new(); - let mut lint_names = usable_lints - .iter() - .map(|lint| lint.name.clone()) - .collect::>(); - for file in std::fs::read_dir("src/docs").unwrap() { - let filename = file.unwrap().file_name().into_string().unwrap(); - if let Some(name) = filename.strip_suffix(".txt") { - if !lint_names.remove(name) { - extra.insert(name.to_string()); - } - } - } - - let failed = print_lint_names("extra lint docs:", &extra) | print_lint_names("missing lint docs:", &lint_names); - - if failed { - exit_with_failure(); - } - } else { - if std::fs::remove_dir_all("src/docs").is_err() { - eprintln!("could not remove src/docs directory"); - } - if std::fs::create_dir("src/docs").is_err() { - eprintln!("could not recreate src/docs directory"); - } - } - for lint in usable_lints { - process_file( - Path::new("src/docs").join(lint.name.clone() + ".txt"), - update_mode, - &lint.documentation, - ); - } -} - -fn print_lint_names(header: &str, lints: &BTreeSet) -> bool { - if lints.is_empty() { - return false; - } - println!("{header}"); - for lint in lints.iter().sorted() { - println!(" {lint}"); - } - println!(); - true -} - pub fn print_lints() { let (lint_list, _, _) = gather_all(); let usable_lints = Lint::usable_lints(&lint_list); @@ -641,26 +565,17 @@ struct Lint { desc: String, module: String, declaration_range: Range, - documentation: String, } impl Lint { #[must_use] - fn new( - name: &str, - group: &str, - desc: &str, - module: &str, - declaration_range: Range, - documentation: String, - ) -> Self { + fn new(name: &str, group: &str, desc: &str, module: &str, declaration_range: Range) -> Self { Self { name: name.to_lowercase(), group: group.into(), desc: remove_line_splices(desc), module: module.into(), declaration_range, - documentation, } } @@ -716,25 +631,6 @@ impl RenamedLint { } } -/// Generates the code for registering a group -fn gen_lint_group_list<'a>(group_name: &str, lints: impl Iterator) -> String { - let mut details: Vec<_> = lints.map(|l| (&l.module, l.name.to_uppercase())).collect(); - details.sort_unstable(); - - let mut output = GENERATED_FILE_COMMENT.to_string(); - - let _ = writeln!( - output, - "store.register_group(true, \"clippy::{group_name}\", Some(\"clippy_{group_name}\"), vec![", - ); - for (module, name) in details { - let _ = writeln!(output, " LintId::of({module}::{name}),"); - } - output.push_str("])\n"); - - output -} - /// Generates the `register_removed` code #[must_use] fn gen_deprecated(lints: &[DeprecatedLint]) -> String { @@ -759,7 +655,7 @@ fn gen_deprecated(lints: &[DeprecatedLint]) -> String { /// Generates the code for registering lints #[must_use] -fn gen_register_lint_list<'a>( +fn gen_declared_lints<'a>( internal_lints: impl Iterator, usable_lints: impl Iterator, ) -> String { @@ -770,15 +666,15 @@ fn gen_register_lint_list<'a>( details.sort_unstable(); let mut output = GENERATED_FILE_COMMENT.to_string(); - output.push_str("store.register_lints(&[\n"); + output.push_str("pub(crate) static LINTS: &[&crate::LintInfo] = &[\n"); for (is_public, module_name, lint_name) in details { if !is_public { output.push_str(" #[cfg(feature = \"internal\")]\n"); } - let _ = writeln!(output, " {module_name}::{lint_name},"); + let _ = writeln!(output, " crate::{module_name}::{lint_name}_INFO,"); } - output.push_str("])\n"); + output.push_str("];\n"); output } @@ -910,35 +806,26 @@ fn parse_contents(contents: &str, module: &str, lints: &mut Vec) { }| token_kind == &TokenKind::Ident && *content == "declare_clippy_lint", ) { let start = range.start; - let mut docs = String::with_capacity(128); - let mut iter = iter.by_ref().filter(|t| !matches!(t.token_kind, TokenKind::Whitespace)); + let mut iter = iter + .by_ref() + .filter(|t| !matches!(t.token_kind, TokenKind::Whitespace | TokenKind::LineComment { .. })); // matches `!{` match_tokens!(iter, Bang OpenBrace); - let mut in_code = false; - while let Some(t) = iter.next() { - match t.token_kind { - TokenKind::LineComment { .. } => { - if let Some(line) = t.content.strip_prefix("/// ").or_else(|| t.content.strip_prefix("///")) { - if line.starts_with("```") { - docs += "```\n"; - in_code = !in_code; - } else if !(in_code && line.starts_with("# ")) { - docs += line; - docs.push('\n'); - } - } - }, - TokenKind::Pound => { - match_tokens!(iter, OpenBracket Ident Colon Colon Ident Eq Literal{..} CloseBracket Ident); - break; - }, - TokenKind::Ident => { - break; - }, - _ => {}, - } + match iter.next() { + // #[clippy::version = "version"] pub + Some(LintDeclSearchResult { + token_kind: TokenKind::Pound, + .. + }) => { + match_tokens!(iter, OpenBracket Ident Colon Colon Ident Eq Literal{..} CloseBracket Ident); + }, + // pub + Some(LintDeclSearchResult { + token_kind: TokenKind::Ident, + .. + }) => (), + _ => continue, } - docs.pop(); // remove final newline let (name, group, desc) = match_tokens!( iter, @@ -956,7 +843,7 @@ fn parse_contents(contents: &str, module: &str, lints: &mut Vec) { .. }) = iter.next() { - lints.push(Lint::new(name, group, desc, module, start..range.end, docs)); + lints.push(Lint::new(name, group, desc, module, start..range.end)); } } } @@ -1186,7 +1073,6 @@ mod tests { "\"really long text\"", "module_name", Range::default(), - String::new(), ), Lint::new( "doc_markdown", @@ -1194,7 +1080,6 @@ mod tests { "\"single line\"", "module_name", Range::default(), - String::new(), ), ]; assert_eq!(expected, result); @@ -1234,7 +1119,6 @@ mod tests { "\"abc\"", "module_name", Range::default(), - String::new(), ), Lint::new( "should_assert_eq2", @@ -1242,7 +1126,6 @@ mod tests { "\"abc\"", "module_name", Range::default(), - String::new(), ), Lint::new( "should_assert_eq2", @@ -1250,7 +1133,6 @@ mod tests { "\"abc\"", "module_name", Range::default(), - String::new(), ), ]; let expected = vec![Lint::new( @@ -1259,7 +1141,6 @@ mod tests { "\"abc\"", "module_name", Range::default(), - String::new(), )]; assert_eq!(expected, Lint::usable_lints(&lints)); } @@ -1267,51 +1148,22 @@ mod tests { #[test] fn test_by_lint_group() { let lints = vec![ - Lint::new( - "should_assert_eq", - "group1", - "\"abc\"", - "module_name", - Range::default(), - String::new(), - ), + Lint::new("should_assert_eq", "group1", "\"abc\"", "module_name", Range::default()), Lint::new( "should_assert_eq2", "group2", "\"abc\"", "module_name", Range::default(), - String::new(), - ), - Lint::new( - "incorrect_match", - "group1", - "\"abc\"", - "module_name", - Range::default(), - String::new(), ), + Lint::new("incorrect_match", "group1", "\"abc\"", "module_name", Range::default()), ]; let mut expected: HashMap> = HashMap::new(); expected.insert( "group1".to_string(), vec![ - Lint::new( - "should_assert_eq", - "group1", - "\"abc\"", - "module_name", - Range::default(), - String::new(), - ), - Lint::new( - "incorrect_match", - "group1", - "\"abc\"", - "module_name", - Range::default(), - String::new(), - ), + Lint::new("should_assert_eq", "group1", "\"abc\"", "module_name", Range::default()), + Lint::new("incorrect_match", "group1", "\"abc\"", "module_name", Range::default()), ], ); expected.insert( @@ -1322,7 +1174,6 @@ mod tests { "\"abc\"", "module_name", Range::default(), - String::new(), )], ); assert_eq!(expected, Lint::by_lint_group(lints.into_iter())); @@ -1357,48 +1208,4 @@ mod tests { assert_eq!(expected, gen_deprecated(&lints)); } - - #[test] - fn test_gen_lint_group_list() { - let lints = vec![ - Lint::new( - "abc", - "group1", - "\"abc\"", - "module_name", - Range::default(), - String::new(), - ), - Lint::new( - "should_assert_eq", - "group1", - "\"abc\"", - "module_name", - Range::default(), - String::new(), - ), - Lint::new( - "internal", - "internal_style", - "\"abc\"", - "module_name", - Range::default(), - String::new(), - ), - ]; - let expected = GENERATED_FILE_COMMENT.to_string() - + &[ - "store.register_group(true, \"clippy::group1\", Some(\"clippy_group1\"), vec![", - " LintId::of(module_name::ABC),", - " LintId::of(module_name::INTERNAL),", - " LintId::of(module_name::SHOULD_ASSERT_EQ),", - "])", - ] - .join("\n") - + "\n"; - - let result = gen_lint_group_list("group1", lints.iter()); - - assert_eq!(expected, result); - } } diff --git a/clippy_lints/Cargo.toml b/clippy_lints/Cargo.toml index 1ff976f48f6..5368932b352 100644 --- a/clippy_lints/Cargo.toml +++ b/clippy_lints/Cargo.toml @@ -11,6 +11,7 @@ edition = "2021" [dependencies] cargo_metadata = "0.14" clippy_utils = { path = "../clippy_utils" } +declare_clippy_lint = { path = "../declare_clippy_lint" } if_chain = "1.0" itertools = "0.10.1" pulldown-cmark = { version = "0.9", default-features = false } diff --git a/clippy_lints/src/declared_lints.rs b/clippy_lints/src/declared_lints.rs new file mode 100644 index 00000000000..c6ae0bddc5a --- /dev/null +++ b/clippy_lints/src/declared_lints.rs @@ -0,0 +1,620 @@ +// This file was generated by `cargo dev update_lints`. +// Use that command to update this file and do not edit by hand. +// Manual edits will be overwritten. + +pub(crate) static LINTS: &[&crate::LintInfo] = &[ + #[cfg(feature = "internal")] + crate::utils::internal_lints::clippy_lints_internal::CLIPPY_LINTS_INTERNAL_INFO, + #[cfg(feature = "internal")] + crate::utils::internal_lints::collapsible_calls::COLLAPSIBLE_SPAN_LINT_CALLS_INFO, + #[cfg(feature = "internal")] + crate::utils::internal_lints::compiler_lint_functions::COMPILER_LINT_FUNCTIONS_INFO, + #[cfg(feature = "internal")] + crate::utils::internal_lints::if_chain_style::IF_CHAIN_STYLE_INFO, + #[cfg(feature = "internal")] + crate::utils::internal_lints::interning_defined_symbol::INTERNING_DEFINED_SYMBOL_INFO, + #[cfg(feature = "internal")] + crate::utils::internal_lints::interning_defined_symbol::UNNECESSARY_SYMBOL_STR_INFO, + #[cfg(feature = "internal")] + crate::utils::internal_lints::invalid_paths::INVALID_PATHS_INFO, + #[cfg(feature = "internal")] + crate::utils::internal_lints::lint_without_lint_pass::DEFAULT_DEPRECATION_REASON_INFO, + #[cfg(feature = "internal")] + crate::utils::internal_lints::lint_without_lint_pass::DEFAULT_LINT_INFO, + #[cfg(feature = "internal")] + crate::utils::internal_lints::lint_without_lint_pass::INVALID_CLIPPY_VERSION_ATTRIBUTE_INFO, + #[cfg(feature = "internal")] + crate::utils::internal_lints::lint_without_lint_pass::LINT_WITHOUT_LINT_PASS_INFO, + #[cfg(feature = "internal")] + crate::utils::internal_lints::lint_without_lint_pass::MISSING_CLIPPY_VERSION_ATTRIBUTE_INFO, + #[cfg(feature = "internal")] + crate::utils::internal_lints::msrv_attr_impl::MISSING_MSRV_ATTR_IMPL_INFO, + #[cfg(feature = "internal")] + crate::utils::internal_lints::outer_expn_data_pass::OUTER_EXPN_EXPN_DATA_INFO, + #[cfg(feature = "internal")] + crate::utils::internal_lints::produce_ice::PRODUCE_ICE_INFO, + #[cfg(feature = "internal")] + crate::utils::internal_lints::unnecessary_def_path::UNNECESSARY_DEF_PATH_INFO, + crate::almost_complete_letter_range::ALMOST_COMPLETE_LETTER_RANGE_INFO, + crate::approx_const::APPROX_CONSTANT_INFO, + crate::as_conversions::AS_CONVERSIONS_INFO, + crate::asm_syntax::INLINE_ASM_X86_ATT_SYNTAX_INFO, + crate::asm_syntax::INLINE_ASM_X86_INTEL_SYNTAX_INFO, + crate::assertions_on_constants::ASSERTIONS_ON_CONSTANTS_INFO, + crate::assertions_on_result_states::ASSERTIONS_ON_RESULT_STATES_INFO, + crate::async_yields_async::ASYNC_YIELDS_ASYNC_INFO, + crate::attrs::ALLOW_ATTRIBUTES_WITHOUT_REASON_INFO, + crate::attrs::BLANKET_CLIPPY_RESTRICTION_LINTS_INFO, + crate::attrs::DEPRECATED_CFG_ATTR_INFO, + crate::attrs::DEPRECATED_SEMVER_INFO, + crate::attrs::EMPTY_LINE_AFTER_OUTER_ATTR_INFO, + crate::attrs::INLINE_ALWAYS_INFO, + crate::attrs::MISMATCHED_TARGET_OS_INFO, + crate::attrs::USELESS_ATTRIBUTE_INFO, + crate::await_holding_invalid::AWAIT_HOLDING_INVALID_TYPE_INFO, + crate::await_holding_invalid::AWAIT_HOLDING_LOCK_INFO, + crate::await_holding_invalid::AWAIT_HOLDING_REFCELL_REF_INFO, + crate::blocks_in_if_conditions::BLOCKS_IN_IF_CONDITIONS_INFO, + crate::bool_assert_comparison::BOOL_ASSERT_COMPARISON_INFO, + crate::bool_to_int_with_if::BOOL_TO_INT_WITH_IF_INFO, + crate::booleans::NONMINIMAL_BOOL_INFO, + crate::booleans::OVERLY_COMPLEX_BOOL_EXPR_INFO, + crate::borrow_deref_ref::BORROW_DEREF_REF_INFO, + crate::box_default::BOX_DEFAULT_INFO, + crate::cargo::CARGO_COMMON_METADATA_INFO, + crate::cargo::MULTIPLE_CRATE_VERSIONS_INFO, + crate::cargo::NEGATIVE_FEATURE_NAMES_INFO, + crate::cargo::REDUNDANT_FEATURE_NAMES_INFO, + crate::cargo::WILDCARD_DEPENDENCIES_INFO, + crate::casts::AS_PTR_CAST_MUT_INFO, + crate::casts::AS_UNDERSCORE_INFO, + crate::casts::BORROW_AS_PTR_INFO, + crate::casts::CAST_ABS_TO_UNSIGNED_INFO, + crate::casts::CAST_ENUM_CONSTRUCTOR_INFO, + crate::casts::CAST_ENUM_TRUNCATION_INFO, + crate::casts::CAST_LOSSLESS_INFO, + crate::casts::CAST_NAN_TO_INT_INFO, + crate::casts::CAST_POSSIBLE_TRUNCATION_INFO, + crate::casts::CAST_POSSIBLE_WRAP_INFO, + crate::casts::CAST_PRECISION_LOSS_INFO, + crate::casts::CAST_PTR_ALIGNMENT_INFO, + crate::casts::CAST_REF_TO_MUT_INFO, + crate::casts::CAST_SIGN_LOSS_INFO, + crate::casts::CAST_SLICE_DIFFERENT_SIZES_INFO, + crate::casts::CAST_SLICE_FROM_RAW_PARTS_INFO, + crate::casts::CHAR_LIT_AS_U8_INFO, + crate::casts::FN_TO_NUMERIC_CAST_INFO, + crate::casts::FN_TO_NUMERIC_CAST_ANY_INFO, + crate::casts::FN_TO_NUMERIC_CAST_WITH_TRUNCATION_INFO, + crate::casts::PTR_AS_PTR_INFO, + crate::casts::UNNECESSARY_CAST_INFO, + crate::checked_conversions::CHECKED_CONVERSIONS_INFO, + crate::cognitive_complexity::COGNITIVE_COMPLEXITY_INFO, + crate::collapsible_if::COLLAPSIBLE_ELSE_IF_INFO, + crate::collapsible_if::COLLAPSIBLE_IF_INFO, + crate::comparison_chain::COMPARISON_CHAIN_INFO, + crate::copies::BRANCHES_SHARING_CODE_INFO, + crate::copies::IFS_SAME_COND_INFO, + crate::copies::IF_SAME_THEN_ELSE_INFO, + crate::copies::SAME_FUNCTIONS_IN_IF_CONDITION_INFO, + crate::copy_iterator::COPY_ITERATOR_INFO, + crate::crate_in_macro_def::CRATE_IN_MACRO_DEF_INFO, + crate::create_dir::CREATE_DIR_INFO, + crate::dbg_macro::DBG_MACRO_INFO, + crate::default::DEFAULT_TRAIT_ACCESS_INFO, + crate::default::FIELD_REASSIGN_WITH_DEFAULT_INFO, + crate::default_instead_of_iter_empty::DEFAULT_INSTEAD_OF_ITER_EMPTY_INFO, + crate::default_numeric_fallback::DEFAULT_NUMERIC_FALLBACK_INFO, + crate::default_union_representation::DEFAULT_UNION_REPRESENTATION_INFO, + crate::dereference::EXPLICIT_AUTO_DEREF_INFO, + crate::dereference::EXPLICIT_DEREF_METHODS_INFO, + crate::dereference::NEEDLESS_BORROW_INFO, + crate::dereference::REF_BINDING_TO_REFERENCE_INFO, + crate::derivable_impls::DERIVABLE_IMPLS_INFO, + crate::derive::DERIVE_HASH_XOR_EQ_INFO, + crate::derive::DERIVE_ORD_XOR_PARTIAL_ORD_INFO, + crate::derive::DERIVE_PARTIAL_EQ_WITHOUT_EQ_INFO, + crate::derive::EXPL_IMPL_CLONE_ON_COPY_INFO, + crate::derive::UNSAFE_DERIVE_DESERIALIZE_INFO, + crate::disallowed_macros::DISALLOWED_MACROS_INFO, + crate::disallowed_methods::DISALLOWED_METHODS_INFO, + crate::disallowed_names::DISALLOWED_NAMES_INFO, + crate::disallowed_script_idents::DISALLOWED_SCRIPT_IDENTS_INFO, + crate::disallowed_types::DISALLOWED_TYPES_INFO, + crate::doc::DOC_LINK_WITH_QUOTES_INFO, + crate::doc::DOC_MARKDOWN_INFO, + crate::doc::MISSING_ERRORS_DOC_INFO, + crate::doc::MISSING_PANICS_DOC_INFO, + crate::doc::MISSING_SAFETY_DOC_INFO, + crate::doc::NEEDLESS_DOCTEST_MAIN_INFO, + crate::double_parens::DOUBLE_PARENS_INFO, + crate::drop_forget_ref::DROP_COPY_INFO, + crate::drop_forget_ref::DROP_NON_DROP_INFO, + crate::drop_forget_ref::DROP_REF_INFO, + crate::drop_forget_ref::FORGET_COPY_INFO, + crate::drop_forget_ref::FORGET_NON_DROP_INFO, + crate::drop_forget_ref::FORGET_REF_INFO, + crate::drop_forget_ref::UNDROPPED_MANUALLY_DROPS_INFO, + crate::duplicate_mod::DUPLICATE_MOD_INFO, + crate::else_if_without_else::ELSE_IF_WITHOUT_ELSE_INFO, + crate::empty_drop::EMPTY_DROP_INFO, + crate::empty_enum::EMPTY_ENUM_INFO, + crate::empty_structs_with_brackets::EMPTY_STRUCTS_WITH_BRACKETS_INFO, + crate::entry::MAP_ENTRY_INFO, + crate::enum_clike::ENUM_CLIKE_UNPORTABLE_VARIANT_INFO, + crate::enum_variants::ENUM_VARIANT_NAMES_INFO, + crate::enum_variants::MODULE_INCEPTION_INFO, + crate::enum_variants::MODULE_NAME_REPETITIONS_INFO, + crate::equatable_if_let::EQUATABLE_IF_LET_INFO, + crate::escape::BOXED_LOCAL_INFO, + crate::eta_reduction::REDUNDANT_CLOSURE_INFO, + crate::eta_reduction::REDUNDANT_CLOSURE_FOR_METHOD_CALLS_INFO, + crate::excessive_bools::FN_PARAMS_EXCESSIVE_BOOLS_INFO, + crate::excessive_bools::STRUCT_EXCESSIVE_BOOLS_INFO, + crate::exhaustive_items::EXHAUSTIVE_ENUMS_INFO, + crate::exhaustive_items::EXHAUSTIVE_STRUCTS_INFO, + crate::exit::EXIT_INFO, + crate::explicit_write::EXPLICIT_WRITE_INFO, + crate::fallible_impl_from::FALLIBLE_IMPL_FROM_INFO, + crate::float_literal::EXCESSIVE_PRECISION_INFO, + crate::float_literal::LOSSY_FLOAT_LITERAL_INFO, + crate::floating_point_arithmetic::IMPRECISE_FLOPS_INFO, + crate::floating_point_arithmetic::SUBOPTIMAL_FLOPS_INFO, + crate::format::USELESS_FORMAT_INFO, + crate::format_args::FORMAT_IN_FORMAT_ARGS_INFO, + crate::format_args::TO_STRING_IN_FORMAT_ARGS_INFO, + crate::format_args::UNINLINED_FORMAT_ARGS_INFO, + crate::format_args::UNUSED_FORMAT_SPECS_INFO, + crate::format_impl::PRINT_IN_FORMAT_IMPL_INFO, + crate::format_impl::RECURSIVE_FORMAT_IMPL_INFO, + crate::format_push_string::FORMAT_PUSH_STRING_INFO, + crate::formatting::POSSIBLE_MISSING_COMMA_INFO, + crate::formatting::SUSPICIOUS_ASSIGNMENT_FORMATTING_INFO, + crate::formatting::SUSPICIOUS_ELSE_FORMATTING_INFO, + crate::formatting::SUSPICIOUS_UNARY_OP_FORMATTING_INFO, + crate::from_over_into::FROM_OVER_INTO_INFO, + crate::from_raw_with_void_ptr::FROM_RAW_WITH_VOID_PTR_INFO, + crate::from_str_radix_10::FROM_STR_RADIX_10_INFO, + crate::functions::DOUBLE_MUST_USE_INFO, + crate::functions::MUST_USE_CANDIDATE_INFO, + crate::functions::MUST_USE_UNIT_INFO, + crate::functions::NOT_UNSAFE_PTR_ARG_DEREF_INFO, + crate::functions::RESULT_LARGE_ERR_INFO, + crate::functions::RESULT_UNIT_ERR_INFO, + crate::functions::TOO_MANY_ARGUMENTS_INFO, + crate::functions::TOO_MANY_LINES_INFO, + crate::future_not_send::FUTURE_NOT_SEND_INFO, + crate::if_let_mutex::IF_LET_MUTEX_INFO, + crate::if_not_else::IF_NOT_ELSE_INFO, + crate::if_then_some_else_none::IF_THEN_SOME_ELSE_NONE_INFO, + crate::implicit_hasher::IMPLICIT_HASHER_INFO, + crate::implicit_return::IMPLICIT_RETURN_INFO, + crate::implicit_saturating_add::IMPLICIT_SATURATING_ADD_INFO, + crate::implicit_saturating_sub::IMPLICIT_SATURATING_SUB_INFO, + crate::inconsistent_struct_constructor::INCONSISTENT_STRUCT_CONSTRUCTOR_INFO, + crate::index_refutable_slice::INDEX_REFUTABLE_SLICE_INFO, + crate::indexing_slicing::INDEXING_SLICING_INFO, + crate::indexing_slicing::OUT_OF_BOUNDS_INDEXING_INFO, + crate::infinite_iter::INFINITE_ITER_INFO, + crate::infinite_iter::MAYBE_INFINITE_ITER_INFO, + crate::inherent_impl::MULTIPLE_INHERENT_IMPL_INFO, + crate::inherent_to_string::INHERENT_TO_STRING_INFO, + crate::inherent_to_string::INHERENT_TO_STRING_SHADOW_DISPLAY_INFO, + crate::init_numbered_fields::INIT_NUMBERED_FIELDS_INFO, + crate::inline_fn_without_body::INLINE_FN_WITHOUT_BODY_INFO, + crate::int_plus_one::INT_PLUS_ONE_INFO, + crate::invalid_upcast_comparisons::INVALID_UPCAST_COMPARISONS_INFO, + crate::invalid_utf8_in_unchecked::INVALID_UTF8_IN_UNCHECKED_INFO, + crate::items_after_statements::ITEMS_AFTER_STATEMENTS_INFO, + crate::iter_not_returning_iterator::ITER_NOT_RETURNING_ITERATOR_INFO, + crate::large_const_arrays::LARGE_CONST_ARRAYS_INFO, + crate::large_enum_variant::LARGE_ENUM_VARIANT_INFO, + crate::large_include_file::LARGE_INCLUDE_FILE_INFO, + crate::large_stack_arrays::LARGE_STACK_ARRAYS_INFO, + crate::len_zero::COMPARISON_TO_EMPTY_INFO, + crate::len_zero::LEN_WITHOUT_IS_EMPTY_INFO, + crate::len_zero::LEN_ZERO_INFO, + crate::let_if_seq::USELESS_LET_IF_SEQ_INFO, + crate::let_underscore::LET_UNDERSCORE_LOCK_INFO, + crate::let_underscore::LET_UNDERSCORE_MUST_USE_INFO, + crate::lifetimes::EXTRA_UNUSED_LIFETIMES_INFO, + crate::lifetimes::NEEDLESS_LIFETIMES_INFO, + crate::literal_representation::DECIMAL_LITERAL_REPRESENTATION_INFO, + crate::literal_representation::INCONSISTENT_DIGIT_GROUPING_INFO, + crate::literal_representation::LARGE_DIGIT_GROUPS_INFO, + crate::literal_representation::MISTYPED_LITERAL_SUFFIXES_INFO, + crate::literal_representation::UNREADABLE_LITERAL_INFO, + crate::literal_representation::UNUSUAL_BYTE_GROUPINGS_INFO, + crate::loops::EMPTY_LOOP_INFO, + crate::loops::EXPLICIT_COUNTER_LOOP_INFO, + crate::loops::EXPLICIT_INTO_ITER_LOOP_INFO, + crate::loops::EXPLICIT_ITER_LOOP_INFO, + crate::loops::FOR_KV_MAP_INFO, + crate::loops::ITER_NEXT_LOOP_INFO, + crate::loops::MANUAL_FIND_INFO, + crate::loops::MANUAL_FLATTEN_INFO, + crate::loops::MANUAL_MEMCPY_INFO, + crate::loops::MISSING_SPIN_LOOP_INFO, + crate::loops::MUT_RANGE_BOUND_INFO, + crate::loops::NEEDLESS_COLLECT_INFO, + crate::loops::NEEDLESS_RANGE_LOOP_INFO, + crate::loops::NEVER_LOOP_INFO, + crate::loops::SAME_ITEM_PUSH_INFO, + crate::loops::SINGLE_ELEMENT_LOOP_INFO, + crate::loops::WHILE_IMMUTABLE_CONDITION_INFO, + crate::loops::WHILE_LET_LOOP_INFO, + crate::loops::WHILE_LET_ON_ITERATOR_INFO, + crate::macro_use::MACRO_USE_IMPORTS_INFO, + crate::main_recursion::MAIN_RECURSION_INFO, + crate::manual_assert::MANUAL_ASSERT_INFO, + crate::manual_async_fn::MANUAL_ASYNC_FN_INFO, + crate::manual_bits::MANUAL_BITS_INFO, + crate::manual_clamp::MANUAL_CLAMP_INFO, + crate::manual_instant_elapsed::MANUAL_INSTANT_ELAPSED_INFO, + crate::manual_non_exhaustive::MANUAL_NON_EXHAUSTIVE_INFO, + crate::manual_rem_euclid::MANUAL_REM_EUCLID_INFO, + crate::manual_retain::MANUAL_RETAIN_INFO, + crate::manual_string_new::MANUAL_STRING_NEW_INFO, + crate::manual_strip::MANUAL_STRIP_INFO, + crate::map_unit_fn::OPTION_MAP_UNIT_FN_INFO, + crate::map_unit_fn::RESULT_MAP_UNIT_FN_INFO, + crate::match_result_ok::MATCH_RESULT_OK_INFO, + crate::matches::COLLAPSIBLE_MATCH_INFO, + crate::matches::INFALLIBLE_DESTRUCTURING_MATCH_INFO, + crate::matches::MANUAL_FILTER_INFO, + crate::matches::MANUAL_MAP_INFO, + crate::matches::MANUAL_UNWRAP_OR_INFO, + crate::matches::MATCH_AS_REF_INFO, + crate::matches::MATCH_BOOL_INFO, + crate::matches::MATCH_LIKE_MATCHES_MACRO_INFO, + crate::matches::MATCH_ON_VEC_ITEMS_INFO, + crate::matches::MATCH_OVERLAPPING_ARM_INFO, + crate::matches::MATCH_REF_PATS_INFO, + crate::matches::MATCH_SAME_ARMS_INFO, + crate::matches::MATCH_SINGLE_BINDING_INFO, + crate::matches::MATCH_STR_CASE_MISMATCH_INFO, + crate::matches::MATCH_WILDCARD_FOR_SINGLE_VARIANTS_INFO, + crate::matches::MATCH_WILD_ERR_ARM_INFO, + crate::matches::NEEDLESS_MATCH_INFO, + crate::matches::REDUNDANT_PATTERN_MATCHING_INFO, + crate::matches::REST_PAT_IN_FULLY_BOUND_STRUCTS_INFO, + crate::matches::SIGNIFICANT_DROP_IN_SCRUTINEE_INFO, + crate::matches::SINGLE_MATCH_INFO, + crate::matches::SINGLE_MATCH_ELSE_INFO, + crate::matches::TRY_ERR_INFO, + crate::matches::WILDCARD_ENUM_MATCH_ARM_INFO, + crate::matches::WILDCARD_IN_OR_PATTERNS_INFO, + crate::mem_forget::MEM_FORGET_INFO, + crate::mem_replace::MEM_REPLACE_OPTION_WITH_NONE_INFO, + crate::mem_replace::MEM_REPLACE_WITH_DEFAULT_INFO, + crate::mem_replace::MEM_REPLACE_WITH_UNINIT_INFO, + crate::methods::BIND_INSTEAD_OF_MAP_INFO, + crate::methods::BYTES_COUNT_TO_LEN_INFO, + crate::methods::BYTES_NTH_INFO, + crate::methods::CASE_SENSITIVE_FILE_EXTENSION_COMPARISONS_INFO, + crate::methods::CHARS_LAST_CMP_INFO, + crate::methods::CHARS_NEXT_CMP_INFO, + crate::methods::CLONED_INSTEAD_OF_COPIED_INFO, + crate::methods::CLONE_DOUBLE_REF_INFO, + crate::methods::CLONE_ON_COPY_INFO, + crate::methods::CLONE_ON_REF_PTR_INFO, + crate::methods::COLLAPSIBLE_STR_REPLACE_INFO, + crate::methods::ERR_EXPECT_INFO, + crate::methods::EXPECT_FUN_CALL_INFO, + crate::methods::EXPECT_USED_INFO, + crate::methods::EXTEND_WITH_DRAIN_INFO, + crate::methods::FILETYPE_IS_FILE_INFO, + crate::methods::FILTER_MAP_IDENTITY_INFO, + crate::methods::FILTER_MAP_NEXT_INFO, + crate::methods::FILTER_NEXT_INFO, + crate::methods::FLAT_MAP_IDENTITY_INFO, + crate::methods::FLAT_MAP_OPTION_INFO, + crate::methods::FROM_ITER_INSTEAD_OF_COLLECT_INFO, + crate::methods::GET_FIRST_INFO, + crate::methods::GET_LAST_WITH_LEN_INFO, + crate::methods::GET_UNWRAP_INFO, + crate::methods::IMPLICIT_CLONE_INFO, + crate::methods::INEFFICIENT_TO_STRING_INFO, + crate::methods::INSPECT_FOR_EACH_INFO, + crate::methods::INTO_ITER_ON_REF_INFO, + crate::methods::IS_DIGIT_ASCII_RADIX_INFO, + crate::methods::ITERATOR_STEP_BY_ZERO_INFO, + crate::methods::ITER_CLONED_COLLECT_INFO, + crate::methods::ITER_COUNT_INFO, + crate::methods::ITER_KV_MAP_INFO, + crate::methods::ITER_NEXT_SLICE_INFO, + crate::methods::ITER_NTH_INFO, + crate::methods::ITER_NTH_ZERO_INFO, + crate::methods::ITER_ON_EMPTY_COLLECTIONS_INFO, + crate::methods::ITER_ON_SINGLE_ITEMS_INFO, + crate::methods::ITER_OVEREAGER_CLONED_INFO, + crate::methods::ITER_SKIP_NEXT_INFO, + crate::methods::ITER_WITH_DRAIN_INFO, + crate::methods::MANUAL_FILTER_MAP_INFO, + crate::methods::MANUAL_FIND_MAP_INFO, + crate::methods::MANUAL_OK_OR_INFO, + crate::methods::MANUAL_SATURATING_ARITHMETIC_INFO, + crate::methods::MANUAL_SPLIT_ONCE_INFO, + crate::methods::MANUAL_STR_REPEAT_INFO, + crate::methods::MAP_CLONE_INFO, + crate::methods::MAP_COLLECT_RESULT_UNIT_INFO, + crate::methods::MAP_ERR_IGNORE_INFO, + crate::methods::MAP_FLATTEN_INFO, + crate::methods::MAP_IDENTITY_INFO, + crate::methods::MAP_UNWRAP_OR_INFO, + crate::methods::MUT_MUTEX_LOCK_INFO, + crate::methods::NAIVE_BYTECOUNT_INFO, + crate::methods::NEEDLESS_OPTION_AS_DEREF_INFO, + crate::methods::NEEDLESS_OPTION_TAKE_INFO, + crate::methods::NEEDLESS_SPLITN_INFO, + crate::methods::NEW_RET_NO_SELF_INFO, + crate::methods::NONSENSICAL_OPEN_OPTIONS_INFO, + crate::methods::NO_EFFECT_REPLACE_INFO, + crate::methods::OBFUSCATED_IF_ELSE_INFO, + crate::methods::OK_EXPECT_INFO, + crate::methods::OPTION_AS_REF_DEREF_INFO, + crate::methods::OPTION_FILTER_MAP_INFO, + crate::methods::OPTION_MAP_OR_NONE_INFO, + crate::methods::OR_FUN_CALL_INFO, + crate::methods::OR_THEN_UNWRAP_INFO, + crate::methods::PATH_BUF_PUSH_OVERWRITE_INFO, + crate::methods::RANGE_ZIP_WITH_LEN_INFO, + crate::methods::REPEAT_ONCE_INFO, + crate::methods::RESULT_MAP_OR_INTO_OPTION_INFO, + crate::methods::SEARCH_IS_SOME_INFO, + crate::methods::SHOULD_IMPLEMENT_TRAIT_INFO, + crate::methods::SINGLE_CHAR_ADD_STR_INFO, + crate::methods::SINGLE_CHAR_PATTERN_INFO, + crate::methods::SKIP_WHILE_NEXT_INFO, + crate::methods::STABLE_SORT_PRIMITIVE_INFO, + crate::methods::STRING_EXTEND_CHARS_INFO, + crate::methods::SUSPICIOUS_MAP_INFO, + crate::methods::SUSPICIOUS_SPLITN_INFO, + crate::methods::SUSPICIOUS_TO_OWNED_INFO, + crate::methods::UNINIT_ASSUMED_INIT_INFO, + crate::methods::UNIT_HASH_INFO, + crate::methods::UNNECESSARY_FILTER_MAP_INFO, + crate::methods::UNNECESSARY_FIND_MAP_INFO, + crate::methods::UNNECESSARY_FOLD_INFO, + crate::methods::UNNECESSARY_JOIN_INFO, + crate::methods::UNNECESSARY_LAZY_EVALUATIONS_INFO, + crate::methods::UNNECESSARY_SORT_BY_INFO, + crate::methods::UNNECESSARY_TO_OWNED_INFO, + crate::methods::UNWRAP_OR_ELSE_DEFAULT_INFO, + crate::methods::UNWRAP_USED_INFO, + crate::methods::USELESS_ASREF_INFO, + crate::methods::VEC_RESIZE_TO_ZERO_INFO, + crate::methods::VERBOSE_FILE_READS_INFO, + crate::methods::WRONG_SELF_CONVENTION_INFO, + crate::methods::ZST_OFFSET_INFO, + crate::minmax::MIN_MAX_INFO, + crate::misc::SHORT_CIRCUIT_STATEMENT_INFO, + crate::misc::TOPLEVEL_REF_ARG_INFO, + crate::misc::USED_UNDERSCORE_BINDING_INFO, + crate::misc::ZERO_PTR_INFO, + crate::misc_early::BUILTIN_TYPE_SHADOW_INFO, + crate::misc_early::DOUBLE_NEG_INFO, + crate::misc_early::DUPLICATE_UNDERSCORE_ARGUMENT_INFO, + crate::misc_early::MIXED_CASE_HEX_LITERALS_INFO, + crate::misc_early::REDUNDANT_PATTERN_INFO, + crate::misc_early::SEPARATED_LITERAL_SUFFIX_INFO, + crate::misc_early::UNNEEDED_FIELD_PATTERN_INFO, + crate::misc_early::UNNEEDED_WILDCARD_PATTERN_INFO, + crate::misc_early::UNSEPARATED_LITERAL_SUFFIX_INFO, + crate::misc_early::ZERO_PREFIXED_LITERAL_INFO, + crate::mismatching_type_param_order::MISMATCHING_TYPE_PARAM_ORDER_INFO, + crate::missing_const_for_fn::MISSING_CONST_FOR_FN_INFO, + crate::missing_doc::MISSING_DOCS_IN_PRIVATE_ITEMS_INFO, + crate::missing_enforced_import_rename::MISSING_ENFORCED_IMPORT_RENAMES_INFO, + crate::missing_inline::MISSING_INLINE_IN_PUBLIC_ITEMS_INFO, + crate::missing_trait_methods::MISSING_TRAIT_METHODS_INFO, + crate::mixed_read_write_in_expression::DIVERGING_SUB_EXPRESSION_INFO, + crate::mixed_read_write_in_expression::MIXED_READ_WRITE_IN_EXPRESSION_INFO, + crate::module_style::MOD_MODULE_FILES_INFO, + crate::module_style::SELF_NAMED_MODULE_FILES_INFO, + crate::multi_assignments::MULTI_ASSIGNMENTS_INFO, + crate::mut_key::MUTABLE_KEY_TYPE_INFO, + crate::mut_mut::MUT_MUT_INFO, + crate::mut_reference::UNNECESSARY_MUT_PASSED_INFO, + crate::mutable_debug_assertion::DEBUG_ASSERT_WITH_MUT_CALL_INFO, + crate::mutex_atomic::MUTEX_ATOMIC_INFO, + crate::mutex_atomic::MUTEX_INTEGER_INFO, + crate::needless_arbitrary_self_type::NEEDLESS_ARBITRARY_SELF_TYPE_INFO, + crate::needless_bool::BOOL_COMPARISON_INFO, + crate::needless_bool::NEEDLESS_BOOL_INFO, + crate::needless_borrowed_ref::NEEDLESS_BORROWED_REFERENCE_INFO, + crate::needless_continue::NEEDLESS_CONTINUE_INFO, + crate::needless_for_each::NEEDLESS_FOR_EACH_INFO, + crate::needless_late_init::NEEDLESS_LATE_INIT_INFO, + crate::needless_parens_on_range_literals::NEEDLESS_PARENS_ON_RANGE_LITERALS_INFO, + crate::needless_pass_by_value::NEEDLESS_PASS_BY_VALUE_INFO, + crate::needless_question_mark::NEEDLESS_QUESTION_MARK_INFO, + crate::needless_update::NEEDLESS_UPDATE_INFO, + crate::neg_cmp_op_on_partial_ord::NEG_CMP_OP_ON_PARTIAL_ORD_INFO, + crate::neg_multiply::NEG_MULTIPLY_INFO, + crate::new_without_default::NEW_WITHOUT_DEFAULT_INFO, + crate::no_effect::NO_EFFECT_INFO, + crate::no_effect::NO_EFFECT_UNDERSCORE_BINDING_INFO, + crate::no_effect::UNNECESSARY_OPERATION_INFO, + crate::non_copy_const::BORROW_INTERIOR_MUTABLE_CONST_INFO, + crate::non_copy_const::DECLARE_INTERIOR_MUTABLE_CONST_INFO, + crate::non_expressive_names::JUST_UNDERSCORES_AND_DIGITS_INFO, + crate::non_expressive_names::MANY_SINGLE_CHAR_NAMES_INFO, + crate::non_expressive_names::SIMILAR_NAMES_INFO, + crate::non_octal_unix_permissions::NON_OCTAL_UNIX_PERMISSIONS_INFO, + crate::non_send_fields_in_send_ty::NON_SEND_FIELDS_IN_SEND_TY_INFO, + crate::nonstandard_macro_braces::NONSTANDARD_MACRO_BRACES_INFO, + crate::octal_escapes::OCTAL_ESCAPES_INFO, + crate::only_used_in_recursion::ONLY_USED_IN_RECURSION_INFO, + crate::operators::ABSURD_EXTREME_COMPARISONS_INFO, + crate::operators::ARITHMETIC_SIDE_EFFECTS_INFO, + crate::operators::ASSIGN_OP_PATTERN_INFO, + crate::operators::BAD_BIT_MASK_INFO, + crate::operators::CMP_NAN_INFO, + crate::operators::CMP_OWNED_INFO, + crate::operators::DOUBLE_COMPARISONS_INFO, + crate::operators::DURATION_SUBSEC_INFO, + crate::operators::EQ_OP_INFO, + crate::operators::ERASING_OP_INFO, + crate::operators::FLOAT_ARITHMETIC_INFO, + crate::operators::FLOAT_CMP_INFO, + crate::operators::FLOAT_CMP_CONST_INFO, + crate::operators::FLOAT_EQUALITY_WITHOUT_ABS_INFO, + crate::operators::IDENTITY_OP_INFO, + crate::operators::INEFFECTIVE_BIT_MASK_INFO, + crate::operators::INTEGER_ARITHMETIC_INFO, + crate::operators::INTEGER_DIVISION_INFO, + crate::operators::MISREFACTORED_ASSIGN_OP_INFO, + crate::operators::MODULO_ARITHMETIC_INFO, + crate::operators::MODULO_ONE_INFO, + crate::operators::NEEDLESS_BITWISE_BOOL_INFO, + crate::operators::OP_REF_INFO, + crate::operators::PTR_EQ_INFO, + crate::operators::SELF_ASSIGNMENT_INFO, + crate::operators::VERBOSE_BIT_MASK_INFO, + crate::option_env_unwrap::OPTION_ENV_UNWRAP_INFO, + crate::option_if_let_else::OPTION_IF_LET_ELSE_INFO, + crate::overflow_check_conditional::OVERFLOW_CHECK_CONDITIONAL_INFO, + crate::panic_in_result_fn::PANIC_IN_RESULT_FN_INFO, + crate::panic_unimplemented::PANIC_INFO, + crate::panic_unimplemented::TODO_INFO, + crate::panic_unimplemented::UNIMPLEMENTED_INFO, + crate::panic_unimplemented::UNREACHABLE_INFO, + crate::partial_pub_fields::PARTIAL_PUB_FIELDS_INFO, + crate::partialeq_ne_impl::PARTIALEQ_NE_IMPL_INFO, + crate::partialeq_to_none::PARTIALEQ_TO_NONE_INFO, + crate::pass_by_ref_or_value::LARGE_TYPES_PASSED_BY_VALUE_INFO, + crate::pass_by_ref_or_value::TRIVIALLY_COPY_PASS_BY_REF_INFO, + crate::pattern_type_mismatch::PATTERN_TYPE_MISMATCH_INFO, + crate::precedence::PRECEDENCE_INFO, + crate::ptr::CMP_NULL_INFO, + crate::ptr::INVALID_NULL_PTR_USAGE_INFO, + crate::ptr::MUT_FROM_REF_INFO, + crate::ptr::PTR_ARG_INFO, + crate::ptr_offset_with_cast::PTR_OFFSET_WITH_CAST_INFO, + crate::pub_use::PUB_USE_INFO, + crate::question_mark::QUESTION_MARK_INFO, + crate::ranges::MANUAL_RANGE_CONTAINS_INFO, + crate::ranges::RANGE_MINUS_ONE_INFO, + crate::ranges::RANGE_PLUS_ONE_INFO, + crate::ranges::REVERSED_EMPTY_RANGES_INFO, + crate::rc_clone_in_vec_init::RC_CLONE_IN_VEC_INIT_INFO, + crate::read_zero_byte_vec::READ_ZERO_BYTE_VEC_INFO, + crate::redundant_clone::REDUNDANT_CLONE_INFO, + crate::redundant_closure_call::REDUNDANT_CLOSURE_CALL_INFO, + crate::redundant_else::REDUNDANT_ELSE_INFO, + crate::redundant_field_names::REDUNDANT_FIELD_NAMES_INFO, + crate::redundant_pub_crate::REDUNDANT_PUB_CRATE_INFO, + crate::redundant_slicing::DEREF_BY_SLICING_INFO, + crate::redundant_slicing::REDUNDANT_SLICING_INFO, + crate::redundant_static_lifetimes::REDUNDANT_STATIC_LIFETIMES_INFO, + crate::ref_option_ref::REF_OPTION_REF_INFO, + crate::reference::DEREF_ADDROF_INFO, + crate::regex::INVALID_REGEX_INFO, + crate::regex::TRIVIAL_REGEX_INFO, + crate::return_self_not_must_use::RETURN_SELF_NOT_MUST_USE_INFO, + crate::returns::LET_AND_RETURN_INFO, + crate::returns::NEEDLESS_RETURN_INFO, + crate::same_name_method::SAME_NAME_METHOD_INFO, + crate::self_named_constructors::SELF_NAMED_CONSTRUCTORS_INFO, + crate::semicolon_if_nothing_returned::SEMICOLON_IF_NOTHING_RETURNED_INFO, + crate::serde_api::SERDE_API_MISUSE_INFO, + crate::shadow::SHADOW_REUSE_INFO, + crate::shadow::SHADOW_SAME_INFO, + crate::shadow::SHADOW_UNRELATED_INFO, + crate::single_char_lifetime_names::SINGLE_CHAR_LIFETIME_NAMES_INFO, + crate::single_component_path_imports::SINGLE_COMPONENT_PATH_IMPORTS_INFO, + crate::size_of_in_element_count::SIZE_OF_IN_ELEMENT_COUNT_INFO, + crate::slow_vector_initialization::SLOW_VECTOR_INITIALIZATION_INFO, + crate::std_instead_of_core::ALLOC_INSTEAD_OF_CORE_INFO, + crate::std_instead_of_core::STD_INSTEAD_OF_ALLOC_INFO, + crate::std_instead_of_core::STD_INSTEAD_OF_CORE_INFO, + crate::strings::STRING_ADD_INFO, + crate::strings::STRING_ADD_ASSIGN_INFO, + crate::strings::STRING_FROM_UTF8_AS_BYTES_INFO, + crate::strings::STRING_LIT_AS_BYTES_INFO, + crate::strings::STRING_SLICE_INFO, + crate::strings::STRING_TO_STRING_INFO, + crate::strings::STR_TO_STRING_INFO, + crate::strings::TRIM_SPLIT_WHITESPACE_INFO, + crate::strlen_on_c_strings::STRLEN_ON_C_STRINGS_INFO, + crate::suspicious_operation_groupings::SUSPICIOUS_OPERATION_GROUPINGS_INFO, + crate::suspicious_trait_impl::SUSPICIOUS_ARITHMETIC_IMPL_INFO, + crate::suspicious_trait_impl::SUSPICIOUS_OP_ASSIGN_IMPL_INFO, + crate::swap::ALMOST_SWAPPED_INFO, + crate::swap::MANUAL_SWAP_INFO, + crate::swap_ptr_to_ref::SWAP_PTR_TO_REF_INFO, + crate::tabs_in_doc_comments::TABS_IN_DOC_COMMENTS_INFO, + crate::temporary_assignment::TEMPORARY_ASSIGNMENT_INFO, + crate::to_digit_is_some::TO_DIGIT_IS_SOME_INFO, + crate::trailing_empty_array::TRAILING_EMPTY_ARRAY_INFO, + crate::trait_bounds::TRAIT_DUPLICATION_IN_BOUNDS_INFO, + crate::trait_bounds::TYPE_REPETITION_IN_BOUNDS_INFO, + crate::transmute::CROSSPOINTER_TRANSMUTE_INFO, + crate::transmute::TRANSMUTES_EXPRESSIBLE_AS_PTR_CASTS_INFO, + crate::transmute::TRANSMUTE_BYTES_TO_STR_INFO, + crate::transmute::TRANSMUTE_FLOAT_TO_INT_INFO, + crate::transmute::TRANSMUTE_INT_TO_BOOL_INFO, + crate::transmute::TRANSMUTE_INT_TO_CHAR_INFO, + crate::transmute::TRANSMUTE_INT_TO_FLOAT_INFO, + crate::transmute::TRANSMUTE_NUM_TO_BYTES_INFO, + crate::transmute::TRANSMUTE_PTR_TO_PTR_INFO, + crate::transmute::TRANSMUTE_PTR_TO_REF_INFO, + crate::transmute::TRANSMUTE_UNDEFINED_REPR_INFO, + crate::transmute::TRANSMUTING_NULL_INFO, + crate::transmute::UNSOUND_COLLECTION_TRANSMUTE_INFO, + crate::transmute::USELESS_TRANSMUTE_INFO, + crate::transmute::WRONG_TRANSMUTE_INFO, + crate::types::BORROWED_BOX_INFO, + crate::types::BOX_COLLECTION_INFO, + crate::types::LINKEDLIST_INFO, + crate::types::OPTION_OPTION_INFO, + crate::types::RC_BUFFER_INFO, + crate::types::RC_MUTEX_INFO, + crate::types::REDUNDANT_ALLOCATION_INFO, + crate::types::TYPE_COMPLEXITY_INFO, + crate::types::VEC_BOX_INFO, + crate::undocumented_unsafe_blocks::UNDOCUMENTED_UNSAFE_BLOCKS_INFO, + crate::unicode::INVISIBLE_CHARACTERS_INFO, + crate::unicode::NON_ASCII_LITERAL_INFO, + crate::unicode::UNICODE_NOT_NFC_INFO, + crate::uninit_vec::UNINIT_VEC_INFO, + crate::unit_return_expecting_ord::UNIT_RETURN_EXPECTING_ORD_INFO, + crate::unit_types::LET_UNIT_VALUE_INFO, + crate::unit_types::UNIT_ARG_INFO, + crate::unit_types::UNIT_CMP_INFO, + crate::unnamed_address::FN_ADDRESS_COMPARISONS_INFO, + crate::unnamed_address::VTABLE_ADDRESS_COMPARISONS_INFO, + crate::unnecessary_owned_empty_strings::UNNECESSARY_OWNED_EMPTY_STRINGS_INFO, + crate::unnecessary_self_imports::UNNECESSARY_SELF_IMPORTS_INFO, + crate::unnecessary_wraps::UNNECESSARY_WRAPS_INFO, + crate::unnested_or_patterns::UNNESTED_OR_PATTERNS_INFO, + crate::unsafe_removed_from_name::UNSAFE_REMOVED_FROM_NAME_INFO, + crate::unused_async::UNUSED_ASYNC_INFO, + crate::unused_io_amount::UNUSED_IO_AMOUNT_INFO, + crate::unused_peekable::UNUSED_PEEKABLE_INFO, + crate::unused_rounding::UNUSED_ROUNDING_INFO, + crate::unused_self::UNUSED_SELF_INFO, + crate::unused_unit::UNUSED_UNIT_INFO, + crate::unwrap::PANICKING_UNWRAP_INFO, + crate::unwrap::UNNECESSARY_UNWRAP_INFO, + crate::unwrap_in_result::UNWRAP_IN_RESULT_INFO, + crate::upper_case_acronyms::UPPER_CASE_ACRONYMS_INFO, + crate::use_self::USE_SELF_INFO, + crate::useless_conversion::USELESS_CONVERSION_INFO, + crate::vec::USELESS_VEC_INFO, + crate::vec_init_then_push::VEC_INIT_THEN_PUSH_INFO, + crate::wildcard_imports::ENUM_GLOB_USE_INFO, + crate::wildcard_imports::WILDCARD_IMPORTS_INFO, + crate::write::PRINTLN_EMPTY_STRING_INFO, + crate::write::PRINT_LITERAL_INFO, + crate::write::PRINT_STDERR_INFO, + crate::write::PRINT_STDOUT_INFO, + crate::write::PRINT_WITH_NEWLINE_INFO, + crate::write::USE_DEBUG_INFO, + crate::write::WRITELN_EMPTY_STRING_INFO, + crate::write::WRITE_LITERAL_INFO, + crate::write::WRITE_WITH_NEWLINE_INFO, + crate::zero_div_zero::ZERO_DIVIDED_BY_ZERO_INFO, + crate::zero_sized_map_values::ZERO_SIZED_MAP_VALUES_INFO, +]; diff --git a/clippy_lints/src/lib.register_all.rs b/clippy_lints/src/lib.register_all.rs deleted file mode 100644 index 34fded26cfc..00000000000 --- a/clippy_lints/src/lib.register_all.rs +++ /dev/null @@ -1,370 +0,0 @@ -// This file was generated by `cargo dev update_lints`. -// Use that command to update this file and do not edit by hand. -// Manual edits will be overwritten. - -store.register_group(true, "clippy::all", Some("clippy_all"), vec![ - LintId::of(almost_complete_letter_range::ALMOST_COMPLETE_LETTER_RANGE), - LintId::of(approx_const::APPROX_CONSTANT), - LintId::of(assertions_on_constants::ASSERTIONS_ON_CONSTANTS), - LintId::of(async_yields_async::ASYNC_YIELDS_ASYNC), - LintId::of(attrs::BLANKET_CLIPPY_RESTRICTION_LINTS), - LintId::of(attrs::DEPRECATED_CFG_ATTR), - LintId::of(attrs::DEPRECATED_SEMVER), - LintId::of(attrs::MISMATCHED_TARGET_OS), - LintId::of(attrs::USELESS_ATTRIBUTE), - LintId::of(await_holding_invalid::AWAIT_HOLDING_INVALID_TYPE), - LintId::of(await_holding_invalid::AWAIT_HOLDING_LOCK), - LintId::of(await_holding_invalid::AWAIT_HOLDING_REFCELL_REF), - LintId::of(blocks_in_if_conditions::BLOCKS_IN_IF_CONDITIONS), - LintId::of(bool_assert_comparison::BOOL_ASSERT_COMPARISON), - LintId::of(bool_to_int_with_if::BOOL_TO_INT_WITH_IF), - LintId::of(booleans::NONMINIMAL_BOOL), - LintId::of(booleans::OVERLY_COMPLEX_BOOL_EXPR), - LintId::of(borrow_deref_ref::BORROW_DEREF_REF), - LintId::of(box_default::BOX_DEFAULT), - LintId::of(casts::CAST_ABS_TO_UNSIGNED), - LintId::of(casts::CAST_ENUM_CONSTRUCTOR), - LintId::of(casts::CAST_ENUM_TRUNCATION), - LintId::of(casts::CAST_NAN_TO_INT), - LintId::of(casts::CAST_REF_TO_MUT), - LintId::of(casts::CAST_SLICE_DIFFERENT_SIZES), - LintId::of(casts::CAST_SLICE_FROM_RAW_PARTS), - LintId::of(casts::CHAR_LIT_AS_U8), - LintId::of(casts::FN_TO_NUMERIC_CAST), - LintId::of(casts::FN_TO_NUMERIC_CAST_WITH_TRUNCATION), - LintId::of(casts::UNNECESSARY_CAST), - LintId::of(collapsible_if::COLLAPSIBLE_ELSE_IF), - LintId::of(collapsible_if::COLLAPSIBLE_IF), - LintId::of(comparison_chain::COMPARISON_CHAIN), - LintId::of(copies::IFS_SAME_COND), - LintId::of(copies::IF_SAME_THEN_ELSE), - LintId::of(crate_in_macro_def::CRATE_IN_MACRO_DEF), - LintId::of(default::FIELD_REASSIGN_WITH_DEFAULT), - LintId::of(default_instead_of_iter_empty::DEFAULT_INSTEAD_OF_ITER_EMPTY), - LintId::of(dereference::EXPLICIT_AUTO_DEREF), - LintId::of(dereference::NEEDLESS_BORROW), - LintId::of(derivable_impls::DERIVABLE_IMPLS), - LintId::of(derive::DERIVE_HASH_XOR_EQ), - LintId::of(derive::DERIVE_ORD_XOR_PARTIAL_ORD), - LintId::of(disallowed_macros::DISALLOWED_MACROS), - LintId::of(disallowed_methods::DISALLOWED_METHODS), - LintId::of(disallowed_names::DISALLOWED_NAMES), - LintId::of(disallowed_types::DISALLOWED_TYPES), - LintId::of(doc::MISSING_SAFETY_DOC), - LintId::of(doc::NEEDLESS_DOCTEST_MAIN), - LintId::of(double_parens::DOUBLE_PARENS), - LintId::of(drop_forget_ref::DROP_COPY), - LintId::of(drop_forget_ref::DROP_NON_DROP), - LintId::of(drop_forget_ref::DROP_REF), - LintId::of(drop_forget_ref::FORGET_COPY), - LintId::of(drop_forget_ref::FORGET_NON_DROP), - LintId::of(drop_forget_ref::FORGET_REF), - LintId::of(drop_forget_ref::UNDROPPED_MANUALLY_DROPS), - LintId::of(duplicate_mod::DUPLICATE_MOD), - LintId::of(entry::MAP_ENTRY), - LintId::of(enum_clike::ENUM_CLIKE_UNPORTABLE_VARIANT), - LintId::of(enum_variants::ENUM_VARIANT_NAMES), - LintId::of(enum_variants::MODULE_INCEPTION), - LintId::of(escape::BOXED_LOCAL), - LintId::of(eta_reduction::REDUNDANT_CLOSURE), - LintId::of(explicit_write::EXPLICIT_WRITE), - LintId::of(float_literal::EXCESSIVE_PRECISION), - LintId::of(format::USELESS_FORMAT), - LintId::of(format_args::FORMAT_IN_FORMAT_ARGS), - LintId::of(format_args::TO_STRING_IN_FORMAT_ARGS), - LintId::of(format_args::UNINLINED_FORMAT_ARGS), - LintId::of(format_args::UNUSED_FORMAT_SPECS), - LintId::of(format_impl::PRINT_IN_FORMAT_IMPL), - LintId::of(format_impl::RECURSIVE_FORMAT_IMPL), - LintId::of(formatting::POSSIBLE_MISSING_COMMA), - LintId::of(formatting::SUSPICIOUS_ASSIGNMENT_FORMATTING), - LintId::of(formatting::SUSPICIOUS_ELSE_FORMATTING), - LintId::of(formatting::SUSPICIOUS_UNARY_OP_FORMATTING), - LintId::of(from_over_into::FROM_OVER_INTO), - LintId::of(from_raw_with_void_ptr::FROM_RAW_WITH_VOID_PTR), - LintId::of(from_str_radix_10::FROM_STR_RADIX_10), - LintId::of(functions::DOUBLE_MUST_USE), - LintId::of(functions::MUST_USE_UNIT), - LintId::of(functions::NOT_UNSAFE_PTR_ARG_DEREF), - LintId::of(functions::RESULT_LARGE_ERR), - LintId::of(functions::RESULT_UNIT_ERR), - LintId::of(functions::TOO_MANY_ARGUMENTS), - LintId::of(if_let_mutex::IF_LET_MUTEX), - LintId::of(implicit_saturating_add::IMPLICIT_SATURATING_ADD), - LintId::of(implicit_saturating_sub::IMPLICIT_SATURATING_SUB), - LintId::of(indexing_slicing::OUT_OF_BOUNDS_INDEXING), - LintId::of(infinite_iter::INFINITE_ITER), - LintId::of(inherent_to_string::INHERENT_TO_STRING), - LintId::of(inherent_to_string::INHERENT_TO_STRING_SHADOW_DISPLAY), - LintId::of(init_numbered_fields::INIT_NUMBERED_FIELDS), - LintId::of(inline_fn_without_body::INLINE_FN_WITHOUT_BODY), - LintId::of(int_plus_one::INT_PLUS_ONE), - LintId::of(invalid_utf8_in_unchecked::INVALID_UTF8_IN_UNCHECKED), - LintId::of(large_const_arrays::LARGE_CONST_ARRAYS), - LintId::of(large_enum_variant::LARGE_ENUM_VARIANT), - LintId::of(len_zero::COMPARISON_TO_EMPTY), - LintId::of(len_zero::LEN_WITHOUT_IS_EMPTY), - LintId::of(len_zero::LEN_ZERO), - LintId::of(let_underscore::LET_UNDERSCORE_LOCK), - LintId::of(lifetimes::EXTRA_UNUSED_LIFETIMES), - LintId::of(lifetimes::NEEDLESS_LIFETIMES), - LintId::of(literal_representation::INCONSISTENT_DIGIT_GROUPING), - LintId::of(literal_representation::MISTYPED_LITERAL_SUFFIXES), - LintId::of(literal_representation::UNUSUAL_BYTE_GROUPINGS), - LintId::of(loops::EMPTY_LOOP), - LintId::of(loops::EXPLICIT_COUNTER_LOOP), - LintId::of(loops::FOR_KV_MAP), - LintId::of(loops::ITER_NEXT_LOOP), - LintId::of(loops::MANUAL_FIND), - LintId::of(loops::MANUAL_FLATTEN), - LintId::of(loops::MANUAL_MEMCPY), - LintId::of(loops::MISSING_SPIN_LOOP), - LintId::of(loops::MUT_RANGE_BOUND), - LintId::of(loops::NEEDLESS_COLLECT), - LintId::of(loops::NEEDLESS_RANGE_LOOP), - LintId::of(loops::NEVER_LOOP), - LintId::of(loops::SAME_ITEM_PUSH), - LintId::of(loops::SINGLE_ELEMENT_LOOP), - LintId::of(loops::WHILE_IMMUTABLE_CONDITION), - LintId::of(loops::WHILE_LET_LOOP), - LintId::of(loops::WHILE_LET_ON_ITERATOR), - LintId::of(main_recursion::MAIN_RECURSION), - LintId::of(manual_async_fn::MANUAL_ASYNC_FN), - LintId::of(manual_bits::MANUAL_BITS), - LintId::of(manual_clamp::MANUAL_CLAMP), - LintId::of(manual_non_exhaustive::MANUAL_NON_EXHAUSTIVE), - LintId::of(manual_rem_euclid::MANUAL_REM_EUCLID), - LintId::of(manual_retain::MANUAL_RETAIN), - LintId::of(manual_strip::MANUAL_STRIP), - LintId::of(map_unit_fn::OPTION_MAP_UNIT_FN), - LintId::of(map_unit_fn::RESULT_MAP_UNIT_FN), - LintId::of(match_result_ok::MATCH_RESULT_OK), - LintId::of(matches::COLLAPSIBLE_MATCH), - LintId::of(matches::INFALLIBLE_DESTRUCTURING_MATCH), - LintId::of(matches::MANUAL_FILTER), - LintId::of(matches::MANUAL_MAP), - LintId::of(matches::MANUAL_UNWRAP_OR), - LintId::of(matches::MATCH_AS_REF), - LintId::of(matches::MATCH_LIKE_MATCHES_MACRO), - LintId::of(matches::MATCH_OVERLAPPING_ARM), - LintId::of(matches::MATCH_REF_PATS), - LintId::of(matches::MATCH_SINGLE_BINDING), - LintId::of(matches::MATCH_STR_CASE_MISMATCH), - LintId::of(matches::NEEDLESS_MATCH), - LintId::of(matches::REDUNDANT_PATTERN_MATCHING), - LintId::of(matches::SINGLE_MATCH), - LintId::of(matches::WILDCARD_IN_OR_PATTERNS), - LintId::of(mem_replace::MEM_REPLACE_OPTION_WITH_NONE), - LintId::of(mem_replace::MEM_REPLACE_WITH_DEFAULT), - LintId::of(mem_replace::MEM_REPLACE_WITH_UNINIT), - LintId::of(methods::BIND_INSTEAD_OF_MAP), - LintId::of(methods::BYTES_COUNT_TO_LEN), - LintId::of(methods::BYTES_NTH), - LintId::of(methods::CHARS_LAST_CMP), - LintId::of(methods::CHARS_NEXT_CMP), - LintId::of(methods::CLONE_DOUBLE_REF), - LintId::of(methods::CLONE_ON_COPY), - LintId::of(methods::COLLAPSIBLE_STR_REPLACE), - LintId::of(methods::ERR_EXPECT), - LintId::of(methods::EXPECT_FUN_CALL), - LintId::of(methods::EXTEND_WITH_DRAIN), - LintId::of(methods::FILTER_MAP_IDENTITY), - LintId::of(methods::FILTER_NEXT), - LintId::of(methods::FLAT_MAP_IDENTITY), - LintId::of(methods::GET_FIRST), - LintId::of(methods::GET_LAST_WITH_LEN), - LintId::of(methods::INSPECT_FOR_EACH), - LintId::of(methods::INTO_ITER_ON_REF), - LintId::of(methods::IS_DIGIT_ASCII_RADIX), - LintId::of(methods::ITERATOR_STEP_BY_ZERO), - LintId::of(methods::ITER_CLONED_COLLECT), - LintId::of(methods::ITER_COUNT), - LintId::of(methods::ITER_KV_MAP), - LintId::of(methods::ITER_NEXT_SLICE), - LintId::of(methods::ITER_NTH), - LintId::of(methods::ITER_NTH_ZERO), - LintId::of(methods::ITER_OVEREAGER_CLONED), - LintId::of(methods::ITER_SKIP_NEXT), - LintId::of(methods::MANUAL_FILTER_MAP), - LintId::of(methods::MANUAL_FIND_MAP), - LintId::of(methods::MANUAL_SATURATING_ARITHMETIC), - LintId::of(methods::MANUAL_SPLIT_ONCE), - LintId::of(methods::MANUAL_STR_REPEAT), - LintId::of(methods::MAP_CLONE), - LintId::of(methods::MAP_COLLECT_RESULT_UNIT), - LintId::of(methods::MAP_FLATTEN), - LintId::of(methods::MAP_IDENTITY), - LintId::of(methods::MUT_MUTEX_LOCK), - LintId::of(methods::NEEDLESS_OPTION_AS_DEREF), - LintId::of(methods::NEEDLESS_OPTION_TAKE), - LintId::of(methods::NEEDLESS_SPLITN), - LintId::of(methods::NEW_RET_NO_SELF), - LintId::of(methods::NONSENSICAL_OPEN_OPTIONS), - LintId::of(methods::NO_EFFECT_REPLACE), - LintId::of(methods::OBFUSCATED_IF_ELSE), - LintId::of(methods::OK_EXPECT), - LintId::of(methods::OPTION_AS_REF_DEREF), - LintId::of(methods::OPTION_FILTER_MAP), - LintId::of(methods::OPTION_MAP_OR_NONE), - LintId::of(methods::OR_FUN_CALL), - LintId::of(methods::OR_THEN_UNWRAP), - LintId::of(methods::RANGE_ZIP_WITH_LEN), - LintId::of(methods::REPEAT_ONCE), - LintId::of(methods::RESULT_MAP_OR_INTO_OPTION), - LintId::of(methods::SEARCH_IS_SOME), - LintId::of(methods::SHOULD_IMPLEMENT_TRAIT), - LintId::of(methods::SINGLE_CHAR_ADD_STR), - LintId::of(methods::SINGLE_CHAR_PATTERN), - LintId::of(methods::SKIP_WHILE_NEXT), - LintId::of(methods::STRING_EXTEND_CHARS), - LintId::of(methods::SUSPICIOUS_MAP), - LintId::of(methods::SUSPICIOUS_SPLITN), - LintId::of(methods::SUSPICIOUS_TO_OWNED), - LintId::of(methods::UNINIT_ASSUMED_INIT), - LintId::of(methods::UNIT_HASH), - LintId::of(methods::UNNECESSARY_FILTER_MAP), - LintId::of(methods::UNNECESSARY_FIND_MAP), - LintId::of(methods::UNNECESSARY_FOLD), - LintId::of(methods::UNNECESSARY_LAZY_EVALUATIONS), - LintId::of(methods::UNNECESSARY_SORT_BY), - LintId::of(methods::UNNECESSARY_TO_OWNED), - LintId::of(methods::UNWRAP_OR_ELSE_DEFAULT), - LintId::of(methods::USELESS_ASREF), - LintId::of(methods::VEC_RESIZE_TO_ZERO), - LintId::of(methods::WRONG_SELF_CONVENTION), - LintId::of(methods::ZST_OFFSET), - LintId::of(minmax::MIN_MAX), - LintId::of(misc::SHORT_CIRCUIT_STATEMENT), - LintId::of(misc::TOPLEVEL_REF_ARG), - LintId::of(misc::ZERO_PTR), - LintId::of(misc_early::BUILTIN_TYPE_SHADOW), - LintId::of(misc_early::DOUBLE_NEG), - LintId::of(misc_early::DUPLICATE_UNDERSCORE_ARGUMENT), - LintId::of(misc_early::MIXED_CASE_HEX_LITERALS), - LintId::of(misc_early::REDUNDANT_PATTERN), - LintId::of(misc_early::UNNEEDED_WILDCARD_PATTERN), - LintId::of(misc_early::ZERO_PREFIXED_LITERAL), - LintId::of(mixed_read_write_in_expression::DIVERGING_SUB_EXPRESSION), - LintId::of(multi_assignments::MULTI_ASSIGNMENTS), - LintId::of(mut_key::MUTABLE_KEY_TYPE), - LintId::of(mut_reference::UNNECESSARY_MUT_PASSED), - LintId::of(needless_arbitrary_self_type::NEEDLESS_ARBITRARY_SELF_TYPE), - LintId::of(needless_bool::BOOL_COMPARISON), - LintId::of(needless_bool::NEEDLESS_BOOL), - LintId::of(needless_borrowed_ref::NEEDLESS_BORROWED_REFERENCE), - LintId::of(needless_late_init::NEEDLESS_LATE_INIT), - LintId::of(needless_parens_on_range_literals::NEEDLESS_PARENS_ON_RANGE_LITERALS), - LintId::of(needless_question_mark::NEEDLESS_QUESTION_MARK), - LintId::of(needless_update::NEEDLESS_UPDATE), - LintId::of(neg_cmp_op_on_partial_ord::NEG_CMP_OP_ON_PARTIAL_ORD), - LintId::of(neg_multiply::NEG_MULTIPLY), - LintId::of(new_without_default::NEW_WITHOUT_DEFAULT), - LintId::of(no_effect::NO_EFFECT), - LintId::of(no_effect::UNNECESSARY_OPERATION), - LintId::of(non_copy_const::BORROW_INTERIOR_MUTABLE_CONST), - LintId::of(non_copy_const::DECLARE_INTERIOR_MUTABLE_CONST), - LintId::of(non_expressive_names::JUST_UNDERSCORES_AND_DIGITS), - LintId::of(non_octal_unix_permissions::NON_OCTAL_UNIX_PERMISSIONS), - LintId::of(octal_escapes::OCTAL_ESCAPES), - LintId::of(only_used_in_recursion::ONLY_USED_IN_RECURSION), - LintId::of(operators::ABSURD_EXTREME_COMPARISONS), - LintId::of(operators::ASSIGN_OP_PATTERN), - LintId::of(operators::BAD_BIT_MASK), - LintId::of(operators::CMP_NAN), - LintId::of(operators::CMP_OWNED), - LintId::of(operators::DOUBLE_COMPARISONS), - LintId::of(operators::DURATION_SUBSEC), - LintId::of(operators::EQ_OP), - LintId::of(operators::ERASING_OP), - LintId::of(operators::FLOAT_EQUALITY_WITHOUT_ABS), - LintId::of(operators::IDENTITY_OP), - LintId::of(operators::INEFFECTIVE_BIT_MASK), - LintId::of(operators::MISREFACTORED_ASSIGN_OP), - LintId::of(operators::MODULO_ONE), - LintId::of(operators::OP_REF), - LintId::of(operators::PTR_EQ), - LintId::of(operators::SELF_ASSIGNMENT), - LintId::of(option_env_unwrap::OPTION_ENV_UNWRAP), - LintId::of(overflow_check_conditional::OVERFLOW_CHECK_CONDITIONAL), - LintId::of(partialeq_ne_impl::PARTIALEQ_NE_IMPL), - LintId::of(partialeq_to_none::PARTIALEQ_TO_NONE), - LintId::of(precedence::PRECEDENCE), - LintId::of(ptr::CMP_NULL), - LintId::of(ptr::INVALID_NULL_PTR_USAGE), - LintId::of(ptr::MUT_FROM_REF), - LintId::of(ptr::PTR_ARG), - LintId::of(ptr_offset_with_cast::PTR_OFFSET_WITH_CAST), - LintId::of(question_mark::QUESTION_MARK), - LintId::of(ranges::MANUAL_RANGE_CONTAINS), - LintId::of(ranges::REVERSED_EMPTY_RANGES), - LintId::of(rc_clone_in_vec_init::RC_CLONE_IN_VEC_INIT), - LintId::of(read_zero_byte_vec::READ_ZERO_BYTE_VEC), - LintId::of(redundant_clone::REDUNDANT_CLONE), - LintId::of(redundant_closure_call::REDUNDANT_CLOSURE_CALL), - LintId::of(redundant_field_names::REDUNDANT_FIELD_NAMES), - LintId::of(redundant_slicing::REDUNDANT_SLICING), - LintId::of(redundant_static_lifetimes::REDUNDANT_STATIC_LIFETIMES), - LintId::of(reference::DEREF_ADDROF), - LintId::of(regex::INVALID_REGEX), - LintId::of(returns::LET_AND_RETURN), - LintId::of(returns::NEEDLESS_RETURN), - LintId::of(self_named_constructors::SELF_NAMED_CONSTRUCTORS), - LintId::of(serde_api::SERDE_API_MISUSE), - LintId::of(single_component_path_imports::SINGLE_COMPONENT_PATH_IMPORTS), - LintId::of(size_of_in_element_count::SIZE_OF_IN_ELEMENT_COUNT), - LintId::of(slow_vector_initialization::SLOW_VECTOR_INITIALIZATION), - LintId::of(strings::STRING_FROM_UTF8_AS_BYTES), - LintId::of(strings::TRIM_SPLIT_WHITESPACE), - LintId::of(strlen_on_c_strings::STRLEN_ON_C_STRINGS), - LintId::of(suspicious_trait_impl::SUSPICIOUS_ARITHMETIC_IMPL), - LintId::of(suspicious_trait_impl::SUSPICIOUS_OP_ASSIGN_IMPL), - LintId::of(swap::ALMOST_SWAPPED), - LintId::of(swap::MANUAL_SWAP), - LintId::of(swap_ptr_to_ref::SWAP_PTR_TO_REF), - LintId::of(tabs_in_doc_comments::TABS_IN_DOC_COMMENTS), - LintId::of(temporary_assignment::TEMPORARY_ASSIGNMENT), - LintId::of(to_digit_is_some::TO_DIGIT_IS_SOME), - LintId::of(transmute::CROSSPOINTER_TRANSMUTE), - LintId::of(transmute::TRANSMUTES_EXPRESSIBLE_AS_PTR_CASTS), - LintId::of(transmute::TRANSMUTE_BYTES_TO_STR), - LintId::of(transmute::TRANSMUTE_FLOAT_TO_INT), - LintId::of(transmute::TRANSMUTE_INT_TO_BOOL), - LintId::of(transmute::TRANSMUTE_INT_TO_CHAR), - LintId::of(transmute::TRANSMUTE_INT_TO_FLOAT), - LintId::of(transmute::TRANSMUTE_NUM_TO_BYTES), - LintId::of(transmute::TRANSMUTE_PTR_TO_REF), - LintId::of(transmute::TRANSMUTING_NULL), - LintId::of(transmute::UNSOUND_COLLECTION_TRANSMUTE), - LintId::of(transmute::USELESS_TRANSMUTE), - LintId::of(transmute::WRONG_TRANSMUTE), - LintId::of(types::BORROWED_BOX), - LintId::of(types::BOX_COLLECTION), - LintId::of(types::REDUNDANT_ALLOCATION), - LintId::of(types::TYPE_COMPLEXITY), - LintId::of(types::VEC_BOX), - LintId::of(unicode::INVISIBLE_CHARACTERS), - LintId::of(uninit_vec::UNINIT_VEC), - LintId::of(unit_return_expecting_ord::UNIT_RETURN_EXPECTING_ORD), - LintId::of(unit_types::LET_UNIT_VALUE), - LintId::of(unit_types::UNIT_ARG), - LintId::of(unit_types::UNIT_CMP), - LintId::of(unnamed_address::FN_ADDRESS_COMPARISONS), - LintId::of(unnamed_address::VTABLE_ADDRESS_COMPARISONS), - LintId::of(unnecessary_owned_empty_strings::UNNECESSARY_OWNED_EMPTY_STRINGS), - LintId::of(unsafe_removed_from_name::UNSAFE_REMOVED_FROM_NAME), - LintId::of(unused_io_amount::UNUSED_IO_AMOUNT), - LintId::of(unused_unit::UNUSED_UNIT), - LintId::of(unwrap::PANICKING_UNWRAP), - LintId::of(unwrap::UNNECESSARY_UNWRAP), - LintId::of(upper_case_acronyms::UPPER_CASE_ACRONYMS), - LintId::of(useless_conversion::USELESS_CONVERSION), - LintId::of(vec::USELESS_VEC), - LintId::of(vec_init_then_push::VEC_INIT_THEN_PUSH), - LintId::of(write::PRINTLN_EMPTY_STRING), - LintId::of(write::PRINT_LITERAL), - LintId::of(write::PRINT_WITH_NEWLINE), - LintId::of(write::WRITELN_EMPTY_STRING), - LintId::of(write::WRITE_LITERAL), - LintId::of(write::WRITE_WITH_NEWLINE), - LintId::of(zero_div_zero::ZERO_DIVIDED_BY_ZERO), -]) diff --git a/clippy_lints/src/lib.register_cargo.rs b/clippy_lints/src/lib.register_cargo.rs deleted file mode 100644 index c890523fe5a..00000000000 --- a/clippy_lints/src/lib.register_cargo.rs +++ /dev/null @@ -1,11 +0,0 @@ -// This file was generated by `cargo dev update_lints`. -// Use that command to update this file and do not edit by hand. -// Manual edits will be overwritten. - -store.register_group(true, "clippy::cargo", Some("clippy_cargo"), vec![ - LintId::of(cargo::CARGO_COMMON_METADATA), - LintId::of(cargo::MULTIPLE_CRATE_VERSIONS), - LintId::of(cargo::NEGATIVE_FEATURE_NAMES), - LintId::of(cargo::REDUNDANT_FEATURE_NAMES), - LintId::of(cargo::WILDCARD_DEPENDENCIES), -]) diff --git a/clippy_lints/src/lib.register_complexity.rs b/clippy_lints/src/lib.register_complexity.rs deleted file mode 100644 index 8be9dc4baf1..00000000000 --- a/clippy_lints/src/lib.register_complexity.rs +++ /dev/null @@ -1,111 +0,0 @@ -// This file was generated by `cargo dev update_lints`. -// Use that command to update this file and do not edit by hand. -// Manual edits will be overwritten. - -store.register_group(true, "clippy::complexity", Some("clippy_complexity"), vec![ - LintId::of(attrs::DEPRECATED_CFG_ATTR), - LintId::of(booleans::NONMINIMAL_BOOL), - LintId::of(borrow_deref_ref::BORROW_DEREF_REF), - LintId::of(casts::CHAR_LIT_AS_U8), - LintId::of(casts::UNNECESSARY_CAST), - LintId::of(dereference::EXPLICIT_AUTO_DEREF), - LintId::of(derivable_impls::DERIVABLE_IMPLS), - LintId::of(double_parens::DOUBLE_PARENS), - LintId::of(explicit_write::EXPLICIT_WRITE), - LintId::of(format::USELESS_FORMAT), - LintId::of(format_args::UNUSED_FORMAT_SPECS), - LintId::of(functions::TOO_MANY_ARGUMENTS), - LintId::of(int_plus_one::INT_PLUS_ONE), - LintId::of(lifetimes::EXTRA_UNUSED_LIFETIMES), - LintId::of(lifetimes::NEEDLESS_LIFETIMES), - LintId::of(loops::EXPLICIT_COUNTER_LOOP), - LintId::of(loops::MANUAL_FIND), - LintId::of(loops::MANUAL_FLATTEN), - LintId::of(loops::SINGLE_ELEMENT_LOOP), - LintId::of(loops::WHILE_LET_LOOP), - LintId::of(manual_clamp::MANUAL_CLAMP), - LintId::of(manual_rem_euclid::MANUAL_REM_EUCLID), - LintId::of(manual_strip::MANUAL_STRIP), - LintId::of(map_unit_fn::OPTION_MAP_UNIT_FN), - LintId::of(map_unit_fn::RESULT_MAP_UNIT_FN), - LintId::of(matches::MANUAL_FILTER), - LintId::of(matches::MANUAL_UNWRAP_OR), - LintId::of(matches::MATCH_AS_REF), - LintId::of(matches::MATCH_SINGLE_BINDING), - LintId::of(matches::NEEDLESS_MATCH), - LintId::of(matches::WILDCARD_IN_OR_PATTERNS), - LintId::of(methods::BIND_INSTEAD_OF_MAP), - LintId::of(methods::BYTES_COUNT_TO_LEN), - LintId::of(methods::CLONE_ON_COPY), - LintId::of(methods::FILTER_MAP_IDENTITY), - LintId::of(methods::FILTER_NEXT), - LintId::of(methods::FLAT_MAP_IDENTITY), - LintId::of(methods::GET_LAST_WITH_LEN), - LintId::of(methods::INSPECT_FOR_EACH), - LintId::of(methods::ITER_COUNT), - LintId::of(methods::ITER_KV_MAP), - LintId::of(methods::MANUAL_FILTER_MAP), - LintId::of(methods::MANUAL_FIND_MAP), - LintId::of(methods::MANUAL_SPLIT_ONCE), - LintId::of(methods::MAP_FLATTEN), - LintId::of(methods::MAP_IDENTITY), - LintId::of(methods::NEEDLESS_OPTION_AS_DEREF), - LintId::of(methods::NEEDLESS_OPTION_TAKE), - LintId::of(methods::NEEDLESS_SPLITN), - LintId::of(methods::OPTION_AS_REF_DEREF), - LintId::of(methods::OPTION_FILTER_MAP), - LintId::of(methods::OR_THEN_UNWRAP), - LintId::of(methods::RANGE_ZIP_WITH_LEN), - LintId::of(methods::REPEAT_ONCE), - LintId::of(methods::SEARCH_IS_SOME), - LintId::of(methods::SKIP_WHILE_NEXT), - LintId::of(methods::UNNECESSARY_FILTER_MAP), - LintId::of(methods::UNNECESSARY_FIND_MAP), - LintId::of(methods::UNNECESSARY_SORT_BY), - LintId::of(methods::USELESS_ASREF), - LintId::of(misc::SHORT_CIRCUIT_STATEMENT), - LintId::of(misc_early::UNNEEDED_WILDCARD_PATTERN), - LintId::of(misc_early::ZERO_PREFIXED_LITERAL), - LintId::of(mixed_read_write_in_expression::DIVERGING_SUB_EXPRESSION), - LintId::of(needless_arbitrary_self_type::NEEDLESS_ARBITRARY_SELF_TYPE), - LintId::of(needless_bool::BOOL_COMPARISON), - LintId::of(needless_bool::NEEDLESS_BOOL), - LintId::of(needless_borrowed_ref::NEEDLESS_BORROWED_REFERENCE), - LintId::of(needless_question_mark::NEEDLESS_QUESTION_MARK), - LintId::of(needless_update::NEEDLESS_UPDATE), - LintId::of(neg_cmp_op_on_partial_ord::NEG_CMP_OP_ON_PARTIAL_ORD), - LintId::of(no_effect::NO_EFFECT), - LintId::of(no_effect::UNNECESSARY_OPERATION), - LintId::of(only_used_in_recursion::ONLY_USED_IN_RECURSION), - LintId::of(operators::DOUBLE_COMPARISONS), - LintId::of(operators::DURATION_SUBSEC), - LintId::of(operators::IDENTITY_OP), - LintId::of(overflow_check_conditional::OVERFLOW_CHECK_CONDITIONAL), - LintId::of(partialeq_ne_impl::PARTIALEQ_NE_IMPL), - LintId::of(precedence::PRECEDENCE), - LintId::of(ptr_offset_with_cast::PTR_OFFSET_WITH_CAST), - LintId::of(redundant_closure_call::REDUNDANT_CLOSURE_CALL), - LintId::of(redundant_slicing::REDUNDANT_SLICING), - LintId::of(reference::DEREF_ADDROF), - LintId::of(strings::STRING_FROM_UTF8_AS_BYTES), - LintId::of(strlen_on_c_strings::STRLEN_ON_C_STRINGS), - LintId::of(swap::MANUAL_SWAP), - LintId::of(temporary_assignment::TEMPORARY_ASSIGNMENT), - LintId::of(transmute::CROSSPOINTER_TRANSMUTE), - LintId::of(transmute::TRANSMUTES_EXPRESSIBLE_AS_PTR_CASTS), - LintId::of(transmute::TRANSMUTE_BYTES_TO_STR), - LintId::of(transmute::TRANSMUTE_FLOAT_TO_INT), - LintId::of(transmute::TRANSMUTE_INT_TO_BOOL), - LintId::of(transmute::TRANSMUTE_INT_TO_CHAR), - LintId::of(transmute::TRANSMUTE_INT_TO_FLOAT), - LintId::of(transmute::TRANSMUTE_NUM_TO_BYTES), - LintId::of(transmute::TRANSMUTE_PTR_TO_REF), - LintId::of(transmute::USELESS_TRANSMUTE), - LintId::of(types::BORROWED_BOX), - LintId::of(types::TYPE_COMPLEXITY), - LintId::of(types::VEC_BOX), - LintId::of(unit_types::UNIT_ARG), - LintId::of(unwrap::UNNECESSARY_UNWRAP), - LintId::of(useless_conversion::USELESS_CONVERSION), - LintId::of(zero_div_zero::ZERO_DIVIDED_BY_ZERO), -]) diff --git a/clippy_lints/src/lib.register_correctness.rs b/clippy_lints/src/lib.register_correctness.rs deleted file mode 100644 index bb94037ec2e..00000000000 --- a/clippy_lints/src/lib.register_correctness.rs +++ /dev/null @@ -1,78 +0,0 @@ -// This file was generated by `cargo dev update_lints`. -// Use that command to update this file and do not edit by hand. -// Manual edits will be overwritten. - -store.register_group(true, "clippy::correctness", Some("clippy_correctness"), vec![ - LintId::of(approx_const::APPROX_CONSTANT), - LintId::of(async_yields_async::ASYNC_YIELDS_ASYNC), - LintId::of(attrs::DEPRECATED_SEMVER), - LintId::of(attrs::MISMATCHED_TARGET_OS), - LintId::of(attrs::USELESS_ATTRIBUTE), - LintId::of(booleans::OVERLY_COMPLEX_BOOL_EXPR), - LintId::of(casts::CAST_REF_TO_MUT), - LintId::of(casts::CAST_SLICE_DIFFERENT_SIZES), - LintId::of(copies::IFS_SAME_COND), - LintId::of(copies::IF_SAME_THEN_ELSE), - LintId::of(derive::DERIVE_HASH_XOR_EQ), - LintId::of(derive::DERIVE_ORD_XOR_PARTIAL_ORD), - LintId::of(drop_forget_ref::DROP_COPY), - LintId::of(drop_forget_ref::DROP_REF), - LintId::of(drop_forget_ref::FORGET_COPY), - LintId::of(drop_forget_ref::FORGET_REF), - LintId::of(drop_forget_ref::UNDROPPED_MANUALLY_DROPS), - LintId::of(enum_clike::ENUM_CLIKE_UNPORTABLE_VARIANT), - LintId::of(format_impl::RECURSIVE_FORMAT_IMPL), - LintId::of(formatting::POSSIBLE_MISSING_COMMA), - LintId::of(functions::NOT_UNSAFE_PTR_ARG_DEREF), - LintId::of(if_let_mutex::IF_LET_MUTEX), - LintId::of(indexing_slicing::OUT_OF_BOUNDS_INDEXING), - LintId::of(infinite_iter::INFINITE_ITER), - LintId::of(inherent_to_string::INHERENT_TO_STRING_SHADOW_DISPLAY), - LintId::of(inline_fn_without_body::INLINE_FN_WITHOUT_BODY), - LintId::of(invalid_utf8_in_unchecked::INVALID_UTF8_IN_UNCHECKED), - LintId::of(let_underscore::LET_UNDERSCORE_LOCK), - LintId::of(literal_representation::MISTYPED_LITERAL_SUFFIXES), - LintId::of(loops::ITER_NEXT_LOOP), - LintId::of(loops::NEVER_LOOP), - LintId::of(loops::WHILE_IMMUTABLE_CONDITION), - LintId::of(matches::MATCH_STR_CASE_MISMATCH), - LintId::of(mem_replace::MEM_REPLACE_WITH_UNINIT), - LintId::of(methods::CLONE_DOUBLE_REF), - LintId::of(methods::ITERATOR_STEP_BY_ZERO), - LintId::of(methods::NONSENSICAL_OPEN_OPTIONS), - LintId::of(methods::SUSPICIOUS_SPLITN), - LintId::of(methods::UNINIT_ASSUMED_INIT), - LintId::of(methods::UNIT_HASH), - LintId::of(methods::VEC_RESIZE_TO_ZERO), - LintId::of(methods::ZST_OFFSET), - LintId::of(minmax::MIN_MAX), - LintId::of(non_octal_unix_permissions::NON_OCTAL_UNIX_PERMISSIONS), - LintId::of(operators::ABSURD_EXTREME_COMPARISONS), - LintId::of(operators::BAD_BIT_MASK), - LintId::of(operators::CMP_NAN), - LintId::of(operators::EQ_OP), - LintId::of(operators::ERASING_OP), - LintId::of(operators::INEFFECTIVE_BIT_MASK), - LintId::of(operators::MODULO_ONE), - LintId::of(operators::SELF_ASSIGNMENT), - LintId::of(option_env_unwrap::OPTION_ENV_UNWRAP), - LintId::of(ptr::INVALID_NULL_PTR_USAGE), - LintId::of(ptr::MUT_FROM_REF), - LintId::of(ranges::REVERSED_EMPTY_RANGES), - LintId::of(read_zero_byte_vec::READ_ZERO_BYTE_VEC), - LintId::of(regex::INVALID_REGEX), - LintId::of(serde_api::SERDE_API_MISUSE), - LintId::of(size_of_in_element_count::SIZE_OF_IN_ELEMENT_COUNT), - LintId::of(swap::ALMOST_SWAPPED), - LintId::of(transmute::TRANSMUTING_NULL), - LintId::of(transmute::UNSOUND_COLLECTION_TRANSMUTE), - LintId::of(transmute::WRONG_TRANSMUTE), - LintId::of(unicode::INVISIBLE_CHARACTERS), - LintId::of(uninit_vec::UNINIT_VEC), - LintId::of(unit_return_expecting_ord::UNIT_RETURN_EXPECTING_ORD), - LintId::of(unit_types::UNIT_CMP), - LintId::of(unnamed_address::FN_ADDRESS_COMPARISONS), - LintId::of(unnamed_address::VTABLE_ADDRESS_COMPARISONS), - LintId::of(unused_io_amount::UNUSED_IO_AMOUNT), - LintId::of(unwrap::PANICKING_UNWRAP), -]) diff --git a/clippy_lints/src/lib.register_internal.rs b/clippy_lints/src/lib.register_internal.rs deleted file mode 100644 index 40c94c6e8d3..00000000000 --- a/clippy_lints/src/lib.register_internal.rs +++ /dev/null @@ -1,22 +0,0 @@ -// This file was generated by `cargo dev update_lints`. -// Use that command to update this file and do not edit by hand. -// Manual edits will be overwritten. - -store.register_group(true, "clippy::internal", Some("clippy_internal"), vec![ - LintId::of(utils::internal_lints::clippy_lints_internal::CLIPPY_LINTS_INTERNAL), - LintId::of(utils::internal_lints::collapsible_calls::COLLAPSIBLE_SPAN_LINT_CALLS), - LintId::of(utils::internal_lints::compiler_lint_functions::COMPILER_LINT_FUNCTIONS), - LintId::of(utils::internal_lints::if_chain_style::IF_CHAIN_STYLE), - LintId::of(utils::internal_lints::interning_defined_symbol::INTERNING_DEFINED_SYMBOL), - LintId::of(utils::internal_lints::interning_defined_symbol::UNNECESSARY_SYMBOL_STR), - LintId::of(utils::internal_lints::invalid_paths::INVALID_PATHS), - LintId::of(utils::internal_lints::lint_without_lint_pass::DEFAULT_DEPRECATION_REASON), - LintId::of(utils::internal_lints::lint_without_lint_pass::DEFAULT_LINT), - LintId::of(utils::internal_lints::lint_without_lint_pass::INVALID_CLIPPY_VERSION_ATTRIBUTE), - LintId::of(utils::internal_lints::lint_without_lint_pass::LINT_WITHOUT_LINT_PASS), - LintId::of(utils::internal_lints::lint_without_lint_pass::MISSING_CLIPPY_VERSION_ATTRIBUTE), - LintId::of(utils::internal_lints::msrv_attr_impl::MISSING_MSRV_ATTR_IMPL), - LintId::of(utils::internal_lints::outer_expn_data_pass::OUTER_EXPN_EXPN_DATA), - LintId::of(utils::internal_lints::produce_ice::PRODUCE_ICE), - LintId::of(utils::internal_lints::unnecessary_def_path::UNNECESSARY_DEF_PATH), -]) diff --git a/clippy_lints/src/lib.register_lints.rs b/clippy_lints/src/lib.register_lints.rs deleted file mode 100644 index 6eaf17709a8..00000000000 --- a/clippy_lints/src/lib.register_lints.rs +++ /dev/null @@ -1,620 +0,0 @@ -// This file was generated by `cargo dev update_lints`. -// Use that command to update this file and do not edit by hand. -// Manual edits will be overwritten. - -store.register_lints(&[ - #[cfg(feature = "internal")] - utils::internal_lints::clippy_lints_internal::CLIPPY_LINTS_INTERNAL, - #[cfg(feature = "internal")] - utils::internal_lints::collapsible_calls::COLLAPSIBLE_SPAN_LINT_CALLS, - #[cfg(feature = "internal")] - utils::internal_lints::compiler_lint_functions::COMPILER_LINT_FUNCTIONS, - #[cfg(feature = "internal")] - utils::internal_lints::if_chain_style::IF_CHAIN_STYLE, - #[cfg(feature = "internal")] - utils::internal_lints::interning_defined_symbol::INTERNING_DEFINED_SYMBOL, - #[cfg(feature = "internal")] - utils::internal_lints::interning_defined_symbol::UNNECESSARY_SYMBOL_STR, - #[cfg(feature = "internal")] - utils::internal_lints::invalid_paths::INVALID_PATHS, - #[cfg(feature = "internal")] - utils::internal_lints::lint_without_lint_pass::DEFAULT_DEPRECATION_REASON, - #[cfg(feature = "internal")] - utils::internal_lints::lint_without_lint_pass::DEFAULT_LINT, - #[cfg(feature = "internal")] - utils::internal_lints::lint_without_lint_pass::INVALID_CLIPPY_VERSION_ATTRIBUTE, - #[cfg(feature = "internal")] - utils::internal_lints::lint_without_lint_pass::LINT_WITHOUT_LINT_PASS, - #[cfg(feature = "internal")] - utils::internal_lints::lint_without_lint_pass::MISSING_CLIPPY_VERSION_ATTRIBUTE, - #[cfg(feature = "internal")] - utils::internal_lints::msrv_attr_impl::MISSING_MSRV_ATTR_IMPL, - #[cfg(feature = "internal")] - utils::internal_lints::outer_expn_data_pass::OUTER_EXPN_EXPN_DATA, - #[cfg(feature = "internal")] - utils::internal_lints::produce_ice::PRODUCE_ICE, - #[cfg(feature = "internal")] - utils::internal_lints::unnecessary_def_path::UNNECESSARY_DEF_PATH, - almost_complete_letter_range::ALMOST_COMPLETE_LETTER_RANGE, - approx_const::APPROX_CONSTANT, - as_conversions::AS_CONVERSIONS, - asm_syntax::INLINE_ASM_X86_ATT_SYNTAX, - asm_syntax::INLINE_ASM_X86_INTEL_SYNTAX, - assertions_on_constants::ASSERTIONS_ON_CONSTANTS, - assertions_on_result_states::ASSERTIONS_ON_RESULT_STATES, - async_yields_async::ASYNC_YIELDS_ASYNC, - attrs::ALLOW_ATTRIBUTES_WITHOUT_REASON, - attrs::BLANKET_CLIPPY_RESTRICTION_LINTS, - attrs::DEPRECATED_CFG_ATTR, - attrs::DEPRECATED_SEMVER, - attrs::EMPTY_LINE_AFTER_OUTER_ATTR, - attrs::INLINE_ALWAYS, - attrs::MISMATCHED_TARGET_OS, - attrs::USELESS_ATTRIBUTE, - await_holding_invalid::AWAIT_HOLDING_INVALID_TYPE, - await_holding_invalid::AWAIT_HOLDING_LOCK, - await_holding_invalid::AWAIT_HOLDING_REFCELL_REF, - blocks_in_if_conditions::BLOCKS_IN_IF_CONDITIONS, - bool_assert_comparison::BOOL_ASSERT_COMPARISON, - bool_to_int_with_if::BOOL_TO_INT_WITH_IF, - booleans::NONMINIMAL_BOOL, - booleans::OVERLY_COMPLEX_BOOL_EXPR, - borrow_deref_ref::BORROW_DEREF_REF, - box_default::BOX_DEFAULT, - cargo::CARGO_COMMON_METADATA, - cargo::MULTIPLE_CRATE_VERSIONS, - cargo::NEGATIVE_FEATURE_NAMES, - cargo::REDUNDANT_FEATURE_NAMES, - cargo::WILDCARD_DEPENDENCIES, - casts::AS_PTR_CAST_MUT, - casts::AS_UNDERSCORE, - casts::BORROW_AS_PTR, - casts::CAST_ABS_TO_UNSIGNED, - casts::CAST_ENUM_CONSTRUCTOR, - casts::CAST_ENUM_TRUNCATION, - casts::CAST_LOSSLESS, - casts::CAST_NAN_TO_INT, - casts::CAST_POSSIBLE_TRUNCATION, - casts::CAST_POSSIBLE_WRAP, - casts::CAST_PRECISION_LOSS, - casts::CAST_PTR_ALIGNMENT, - casts::CAST_REF_TO_MUT, - casts::CAST_SIGN_LOSS, - casts::CAST_SLICE_DIFFERENT_SIZES, - casts::CAST_SLICE_FROM_RAW_PARTS, - casts::CHAR_LIT_AS_U8, - casts::FN_TO_NUMERIC_CAST, - casts::FN_TO_NUMERIC_CAST_ANY, - casts::FN_TO_NUMERIC_CAST_WITH_TRUNCATION, - casts::PTR_AS_PTR, - casts::UNNECESSARY_CAST, - checked_conversions::CHECKED_CONVERSIONS, - cognitive_complexity::COGNITIVE_COMPLEXITY, - collapsible_if::COLLAPSIBLE_ELSE_IF, - collapsible_if::COLLAPSIBLE_IF, - comparison_chain::COMPARISON_CHAIN, - copies::BRANCHES_SHARING_CODE, - copies::IFS_SAME_COND, - copies::IF_SAME_THEN_ELSE, - copies::SAME_FUNCTIONS_IN_IF_CONDITION, - copy_iterator::COPY_ITERATOR, - crate_in_macro_def::CRATE_IN_MACRO_DEF, - create_dir::CREATE_DIR, - dbg_macro::DBG_MACRO, - default::DEFAULT_TRAIT_ACCESS, - default::FIELD_REASSIGN_WITH_DEFAULT, - default_instead_of_iter_empty::DEFAULT_INSTEAD_OF_ITER_EMPTY, - default_numeric_fallback::DEFAULT_NUMERIC_FALLBACK, - default_union_representation::DEFAULT_UNION_REPRESENTATION, - dereference::EXPLICIT_AUTO_DEREF, - dereference::EXPLICIT_DEREF_METHODS, - dereference::NEEDLESS_BORROW, - dereference::REF_BINDING_TO_REFERENCE, - derivable_impls::DERIVABLE_IMPLS, - derive::DERIVE_HASH_XOR_EQ, - derive::DERIVE_ORD_XOR_PARTIAL_ORD, - derive::DERIVE_PARTIAL_EQ_WITHOUT_EQ, - derive::EXPL_IMPL_CLONE_ON_COPY, - derive::UNSAFE_DERIVE_DESERIALIZE, - disallowed_macros::DISALLOWED_MACROS, - disallowed_methods::DISALLOWED_METHODS, - disallowed_names::DISALLOWED_NAMES, - disallowed_script_idents::DISALLOWED_SCRIPT_IDENTS, - disallowed_types::DISALLOWED_TYPES, - doc::DOC_LINK_WITH_QUOTES, - doc::DOC_MARKDOWN, - doc::MISSING_ERRORS_DOC, - doc::MISSING_PANICS_DOC, - doc::MISSING_SAFETY_DOC, - doc::NEEDLESS_DOCTEST_MAIN, - double_parens::DOUBLE_PARENS, - drop_forget_ref::DROP_COPY, - drop_forget_ref::DROP_NON_DROP, - drop_forget_ref::DROP_REF, - drop_forget_ref::FORGET_COPY, - drop_forget_ref::FORGET_NON_DROP, - drop_forget_ref::FORGET_REF, - drop_forget_ref::UNDROPPED_MANUALLY_DROPS, - duplicate_mod::DUPLICATE_MOD, - else_if_without_else::ELSE_IF_WITHOUT_ELSE, - empty_drop::EMPTY_DROP, - empty_enum::EMPTY_ENUM, - empty_structs_with_brackets::EMPTY_STRUCTS_WITH_BRACKETS, - entry::MAP_ENTRY, - enum_clike::ENUM_CLIKE_UNPORTABLE_VARIANT, - enum_variants::ENUM_VARIANT_NAMES, - enum_variants::MODULE_INCEPTION, - enum_variants::MODULE_NAME_REPETITIONS, - equatable_if_let::EQUATABLE_IF_LET, - escape::BOXED_LOCAL, - eta_reduction::REDUNDANT_CLOSURE, - eta_reduction::REDUNDANT_CLOSURE_FOR_METHOD_CALLS, - excessive_bools::FN_PARAMS_EXCESSIVE_BOOLS, - excessive_bools::STRUCT_EXCESSIVE_BOOLS, - exhaustive_items::EXHAUSTIVE_ENUMS, - exhaustive_items::EXHAUSTIVE_STRUCTS, - exit::EXIT, - explicit_write::EXPLICIT_WRITE, - fallible_impl_from::FALLIBLE_IMPL_FROM, - float_literal::EXCESSIVE_PRECISION, - float_literal::LOSSY_FLOAT_LITERAL, - floating_point_arithmetic::IMPRECISE_FLOPS, - floating_point_arithmetic::SUBOPTIMAL_FLOPS, - format::USELESS_FORMAT, - format_args::FORMAT_IN_FORMAT_ARGS, - format_args::TO_STRING_IN_FORMAT_ARGS, - format_args::UNINLINED_FORMAT_ARGS, - format_args::UNUSED_FORMAT_SPECS, - format_impl::PRINT_IN_FORMAT_IMPL, - format_impl::RECURSIVE_FORMAT_IMPL, - format_push_string::FORMAT_PUSH_STRING, - formatting::POSSIBLE_MISSING_COMMA, - formatting::SUSPICIOUS_ASSIGNMENT_FORMATTING, - formatting::SUSPICIOUS_ELSE_FORMATTING, - formatting::SUSPICIOUS_UNARY_OP_FORMATTING, - from_over_into::FROM_OVER_INTO, - from_raw_with_void_ptr::FROM_RAW_WITH_VOID_PTR, - from_str_radix_10::FROM_STR_RADIX_10, - functions::DOUBLE_MUST_USE, - functions::MUST_USE_CANDIDATE, - functions::MUST_USE_UNIT, - functions::NOT_UNSAFE_PTR_ARG_DEREF, - functions::RESULT_LARGE_ERR, - functions::RESULT_UNIT_ERR, - functions::TOO_MANY_ARGUMENTS, - functions::TOO_MANY_LINES, - future_not_send::FUTURE_NOT_SEND, - if_let_mutex::IF_LET_MUTEX, - if_not_else::IF_NOT_ELSE, - if_then_some_else_none::IF_THEN_SOME_ELSE_NONE, - implicit_hasher::IMPLICIT_HASHER, - implicit_return::IMPLICIT_RETURN, - implicit_saturating_add::IMPLICIT_SATURATING_ADD, - implicit_saturating_sub::IMPLICIT_SATURATING_SUB, - inconsistent_struct_constructor::INCONSISTENT_STRUCT_CONSTRUCTOR, - index_refutable_slice::INDEX_REFUTABLE_SLICE, - indexing_slicing::INDEXING_SLICING, - indexing_slicing::OUT_OF_BOUNDS_INDEXING, - infinite_iter::INFINITE_ITER, - infinite_iter::MAYBE_INFINITE_ITER, - inherent_impl::MULTIPLE_INHERENT_IMPL, - inherent_to_string::INHERENT_TO_STRING, - inherent_to_string::INHERENT_TO_STRING_SHADOW_DISPLAY, - init_numbered_fields::INIT_NUMBERED_FIELDS, - inline_fn_without_body::INLINE_FN_WITHOUT_BODY, - int_plus_one::INT_PLUS_ONE, - invalid_upcast_comparisons::INVALID_UPCAST_COMPARISONS, - invalid_utf8_in_unchecked::INVALID_UTF8_IN_UNCHECKED, - items_after_statements::ITEMS_AFTER_STATEMENTS, - iter_not_returning_iterator::ITER_NOT_RETURNING_ITERATOR, - large_const_arrays::LARGE_CONST_ARRAYS, - large_enum_variant::LARGE_ENUM_VARIANT, - large_include_file::LARGE_INCLUDE_FILE, - large_stack_arrays::LARGE_STACK_ARRAYS, - len_zero::COMPARISON_TO_EMPTY, - len_zero::LEN_WITHOUT_IS_EMPTY, - len_zero::LEN_ZERO, - let_if_seq::USELESS_LET_IF_SEQ, - let_underscore::LET_UNDERSCORE_LOCK, - let_underscore::LET_UNDERSCORE_MUST_USE, - lifetimes::EXTRA_UNUSED_LIFETIMES, - lifetimes::NEEDLESS_LIFETIMES, - literal_representation::DECIMAL_LITERAL_REPRESENTATION, - literal_representation::INCONSISTENT_DIGIT_GROUPING, - literal_representation::LARGE_DIGIT_GROUPS, - literal_representation::MISTYPED_LITERAL_SUFFIXES, - literal_representation::UNREADABLE_LITERAL, - literal_representation::UNUSUAL_BYTE_GROUPINGS, - loops::EMPTY_LOOP, - loops::EXPLICIT_COUNTER_LOOP, - loops::EXPLICIT_INTO_ITER_LOOP, - loops::EXPLICIT_ITER_LOOP, - loops::FOR_KV_MAP, - loops::ITER_NEXT_LOOP, - loops::MANUAL_FIND, - loops::MANUAL_FLATTEN, - loops::MANUAL_MEMCPY, - loops::MISSING_SPIN_LOOP, - loops::MUT_RANGE_BOUND, - loops::NEEDLESS_COLLECT, - loops::NEEDLESS_RANGE_LOOP, - loops::NEVER_LOOP, - loops::SAME_ITEM_PUSH, - loops::SINGLE_ELEMENT_LOOP, - loops::WHILE_IMMUTABLE_CONDITION, - loops::WHILE_LET_LOOP, - loops::WHILE_LET_ON_ITERATOR, - macro_use::MACRO_USE_IMPORTS, - main_recursion::MAIN_RECURSION, - manual_assert::MANUAL_ASSERT, - manual_async_fn::MANUAL_ASYNC_FN, - manual_bits::MANUAL_BITS, - manual_clamp::MANUAL_CLAMP, - manual_instant_elapsed::MANUAL_INSTANT_ELAPSED, - manual_non_exhaustive::MANUAL_NON_EXHAUSTIVE, - manual_rem_euclid::MANUAL_REM_EUCLID, - manual_retain::MANUAL_RETAIN, - manual_string_new::MANUAL_STRING_NEW, - manual_strip::MANUAL_STRIP, - map_unit_fn::OPTION_MAP_UNIT_FN, - map_unit_fn::RESULT_MAP_UNIT_FN, - match_result_ok::MATCH_RESULT_OK, - matches::COLLAPSIBLE_MATCH, - matches::INFALLIBLE_DESTRUCTURING_MATCH, - matches::MANUAL_FILTER, - matches::MANUAL_MAP, - matches::MANUAL_UNWRAP_OR, - matches::MATCH_AS_REF, - matches::MATCH_BOOL, - matches::MATCH_LIKE_MATCHES_MACRO, - matches::MATCH_ON_VEC_ITEMS, - matches::MATCH_OVERLAPPING_ARM, - matches::MATCH_REF_PATS, - matches::MATCH_SAME_ARMS, - matches::MATCH_SINGLE_BINDING, - matches::MATCH_STR_CASE_MISMATCH, - matches::MATCH_WILDCARD_FOR_SINGLE_VARIANTS, - matches::MATCH_WILD_ERR_ARM, - matches::NEEDLESS_MATCH, - matches::REDUNDANT_PATTERN_MATCHING, - matches::REST_PAT_IN_FULLY_BOUND_STRUCTS, - matches::SIGNIFICANT_DROP_IN_SCRUTINEE, - matches::SINGLE_MATCH, - matches::SINGLE_MATCH_ELSE, - matches::TRY_ERR, - matches::WILDCARD_ENUM_MATCH_ARM, - matches::WILDCARD_IN_OR_PATTERNS, - mem_forget::MEM_FORGET, - mem_replace::MEM_REPLACE_OPTION_WITH_NONE, - mem_replace::MEM_REPLACE_WITH_DEFAULT, - mem_replace::MEM_REPLACE_WITH_UNINIT, - methods::BIND_INSTEAD_OF_MAP, - methods::BYTES_COUNT_TO_LEN, - methods::BYTES_NTH, - methods::CASE_SENSITIVE_FILE_EXTENSION_COMPARISONS, - methods::CHARS_LAST_CMP, - methods::CHARS_NEXT_CMP, - methods::CLONED_INSTEAD_OF_COPIED, - methods::CLONE_DOUBLE_REF, - methods::CLONE_ON_COPY, - methods::CLONE_ON_REF_PTR, - methods::COLLAPSIBLE_STR_REPLACE, - methods::ERR_EXPECT, - methods::EXPECT_FUN_CALL, - methods::EXPECT_USED, - methods::EXTEND_WITH_DRAIN, - methods::FILETYPE_IS_FILE, - methods::FILTER_MAP_IDENTITY, - methods::FILTER_MAP_NEXT, - methods::FILTER_NEXT, - methods::FLAT_MAP_IDENTITY, - methods::FLAT_MAP_OPTION, - methods::FROM_ITER_INSTEAD_OF_COLLECT, - methods::GET_FIRST, - methods::GET_LAST_WITH_LEN, - methods::GET_UNWRAP, - methods::IMPLICIT_CLONE, - methods::INEFFICIENT_TO_STRING, - methods::INSPECT_FOR_EACH, - methods::INTO_ITER_ON_REF, - methods::IS_DIGIT_ASCII_RADIX, - methods::ITERATOR_STEP_BY_ZERO, - methods::ITER_CLONED_COLLECT, - methods::ITER_COUNT, - methods::ITER_KV_MAP, - methods::ITER_NEXT_SLICE, - methods::ITER_NTH, - methods::ITER_NTH_ZERO, - methods::ITER_ON_EMPTY_COLLECTIONS, - methods::ITER_ON_SINGLE_ITEMS, - methods::ITER_OVEREAGER_CLONED, - methods::ITER_SKIP_NEXT, - methods::ITER_WITH_DRAIN, - methods::MANUAL_FILTER_MAP, - methods::MANUAL_FIND_MAP, - methods::MANUAL_OK_OR, - methods::MANUAL_SATURATING_ARITHMETIC, - methods::MANUAL_SPLIT_ONCE, - methods::MANUAL_STR_REPEAT, - methods::MAP_CLONE, - methods::MAP_COLLECT_RESULT_UNIT, - methods::MAP_ERR_IGNORE, - methods::MAP_FLATTEN, - methods::MAP_IDENTITY, - methods::MAP_UNWRAP_OR, - methods::MUT_MUTEX_LOCK, - methods::NAIVE_BYTECOUNT, - methods::NEEDLESS_OPTION_AS_DEREF, - methods::NEEDLESS_OPTION_TAKE, - methods::NEEDLESS_SPLITN, - methods::NEW_RET_NO_SELF, - methods::NONSENSICAL_OPEN_OPTIONS, - methods::NO_EFFECT_REPLACE, - methods::OBFUSCATED_IF_ELSE, - methods::OK_EXPECT, - methods::OPTION_AS_REF_DEREF, - methods::OPTION_FILTER_MAP, - methods::OPTION_MAP_OR_NONE, - methods::OR_FUN_CALL, - methods::OR_THEN_UNWRAP, - methods::PATH_BUF_PUSH_OVERWRITE, - methods::RANGE_ZIP_WITH_LEN, - methods::REPEAT_ONCE, - methods::RESULT_MAP_OR_INTO_OPTION, - methods::SEARCH_IS_SOME, - methods::SHOULD_IMPLEMENT_TRAIT, - methods::SINGLE_CHAR_ADD_STR, - methods::SINGLE_CHAR_PATTERN, - methods::SKIP_WHILE_NEXT, - methods::STABLE_SORT_PRIMITIVE, - methods::STRING_EXTEND_CHARS, - methods::SUSPICIOUS_MAP, - methods::SUSPICIOUS_SPLITN, - methods::SUSPICIOUS_TO_OWNED, - methods::UNINIT_ASSUMED_INIT, - methods::UNIT_HASH, - methods::UNNECESSARY_FILTER_MAP, - methods::UNNECESSARY_FIND_MAP, - methods::UNNECESSARY_FOLD, - methods::UNNECESSARY_JOIN, - methods::UNNECESSARY_LAZY_EVALUATIONS, - methods::UNNECESSARY_SORT_BY, - methods::UNNECESSARY_TO_OWNED, - methods::UNWRAP_OR_ELSE_DEFAULT, - methods::UNWRAP_USED, - methods::USELESS_ASREF, - methods::VEC_RESIZE_TO_ZERO, - methods::VERBOSE_FILE_READS, - methods::WRONG_SELF_CONVENTION, - methods::ZST_OFFSET, - minmax::MIN_MAX, - misc::SHORT_CIRCUIT_STATEMENT, - misc::TOPLEVEL_REF_ARG, - misc::USED_UNDERSCORE_BINDING, - misc::ZERO_PTR, - misc_early::BUILTIN_TYPE_SHADOW, - misc_early::DOUBLE_NEG, - misc_early::DUPLICATE_UNDERSCORE_ARGUMENT, - misc_early::MIXED_CASE_HEX_LITERALS, - misc_early::REDUNDANT_PATTERN, - misc_early::SEPARATED_LITERAL_SUFFIX, - misc_early::UNNEEDED_FIELD_PATTERN, - misc_early::UNNEEDED_WILDCARD_PATTERN, - misc_early::UNSEPARATED_LITERAL_SUFFIX, - misc_early::ZERO_PREFIXED_LITERAL, - mismatching_type_param_order::MISMATCHING_TYPE_PARAM_ORDER, - missing_const_for_fn::MISSING_CONST_FOR_FN, - missing_doc::MISSING_DOCS_IN_PRIVATE_ITEMS, - missing_enforced_import_rename::MISSING_ENFORCED_IMPORT_RENAMES, - missing_inline::MISSING_INLINE_IN_PUBLIC_ITEMS, - missing_trait_methods::MISSING_TRAIT_METHODS, - mixed_read_write_in_expression::DIVERGING_SUB_EXPRESSION, - mixed_read_write_in_expression::MIXED_READ_WRITE_IN_EXPRESSION, - module_style::MOD_MODULE_FILES, - module_style::SELF_NAMED_MODULE_FILES, - multi_assignments::MULTI_ASSIGNMENTS, - mut_key::MUTABLE_KEY_TYPE, - mut_mut::MUT_MUT, - mut_reference::UNNECESSARY_MUT_PASSED, - mutable_debug_assertion::DEBUG_ASSERT_WITH_MUT_CALL, - mutex_atomic::MUTEX_ATOMIC, - mutex_atomic::MUTEX_INTEGER, - needless_arbitrary_self_type::NEEDLESS_ARBITRARY_SELF_TYPE, - needless_bool::BOOL_COMPARISON, - needless_bool::NEEDLESS_BOOL, - needless_borrowed_ref::NEEDLESS_BORROWED_REFERENCE, - needless_continue::NEEDLESS_CONTINUE, - needless_for_each::NEEDLESS_FOR_EACH, - needless_late_init::NEEDLESS_LATE_INIT, - needless_parens_on_range_literals::NEEDLESS_PARENS_ON_RANGE_LITERALS, - needless_pass_by_value::NEEDLESS_PASS_BY_VALUE, - needless_question_mark::NEEDLESS_QUESTION_MARK, - needless_update::NEEDLESS_UPDATE, - neg_cmp_op_on_partial_ord::NEG_CMP_OP_ON_PARTIAL_ORD, - neg_multiply::NEG_MULTIPLY, - new_without_default::NEW_WITHOUT_DEFAULT, - no_effect::NO_EFFECT, - no_effect::NO_EFFECT_UNDERSCORE_BINDING, - no_effect::UNNECESSARY_OPERATION, - non_copy_const::BORROW_INTERIOR_MUTABLE_CONST, - non_copy_const::DECLARE_INTERIOR_MUTABLE_CONST, - non_expressive_names::JUST_UNDERSCORES_AND_DIGITS, - non_expressive_names::MANY_SINGLE_CHAR_NAMES, - non_expressive_names::SIMILAR_NAMES, - non_octal_unix_permissions::NON_OCTAL_UNIX_PERMISSIONS, - non_send_fields_in_send_ty::NON_SEND_FIELDS_IN_SEND_TY, - nonstandard_macro_braces::NONSTANDARD_MACRO_BRACES, - octal_escapes::OCTAL_ESCAPES, - only_used_in_recursion::ONLY_USED_IN_RECURSION, - operators::ABSURD_EXTREME_COMPARISONS, - operators::ARITHMETIC_SIDE_EFFECTS, - operators::ASSIGN_OP_PATTERN, - operators::BAD_BIT_MASK, - operators::CMP_NAN, - operators::CMP_OWNED, - operators::DOUBLE_COMPARISONS, - operators::DURATION_SUBSEC, - operators::EQ_OP, - operators::ERASING_OP, - operators::FLOAT_ARITHMETIC, - operators::FLOAT_CMP, - operators::FLOAT_CMP_CONST, - operators::FLOAT_EQUALITY_WITHOUT_ABS, - operators::IDENTITY_OP, - operators::INEFFECTIVE_BIT_MASK, - operators::INTEGER_ARITHMETIC, - operators::INTEGER_DIVISION, - operators::MISREFACTORED_ASSIGN_OP, - operators::MODULO_ARITHMETIC, - operators::MODULO_ONE, - operators::NEEDLESS_BITWISE_BOOL, - operators::OP_REF, - operators::PTR_EQ, - operators::SELF_ASSIGNMENT, - operators::VERBOSE_BIT_MASK, - option_env_unwrap::OPTION_ENV_UNWRAP, - option_if_let_else::OPTION_IF_LET_ELSE, - overflow_check_conditional::OVERFLOW_CHECK_CONDITIONAL, - panic_in_result_fn::PANIC_IN_RESULT_FN, - panic_unimplemented::PANIC, - panic_unimplemented::TODO, - panic_unimplemented::UNIMPLEMENTED, - panic_unimplemented::UNREACHABLE, - partial_pub_fields::PARTIAL_PUB_FIELDS, - partialeq_ne_impl::PARTIALEQ_NE_IMPL, - partialeq_to_none::PARTIALEQ_TO_NONE, - pass_by_ref_or_value::LARGE_TYPES_PASSED_BY_VALUE, - pass_by_ref_or_value::TRIVIALLY_COPY_PASS_BY_REF, - pattern_type_mismatch::PATTERN_TYPE_MISMATCH, - precedence::PRECEDENCE, - ptr::CMP_NULL, - ptr::INVALID_NULL_PTR_USAGE, - ptr::MUT_FROM_REF, - ptr::PTR_ARG, - ptr_offset_with_cast::PTR_OFFSET_WITH_CAST, - pub_use::PUB_USE, - question_mark::QUESTION_MARK, - ranges::MANUAL_RANGE_CONTAINS, - ranges::RANGE_MINUS_ONE, - ranges::RANGE_PLUS_ONE, - ranges::REVERSED_EMPTY_RANGES, - rc_clone_in_vec_init::RC_CLONE_IN_VEC_INIT, - read_zero_byte_vec::READ_ZERO_BYTE_VEC, - redundant_clone::REDUNDANT_CLONE, - redundant_closure_call::REDUNDANT_CLOSURE_CALL, - redundant_else::REDUNDANT_ELSE, - redundant_field_names::REDUNDANT_FIELD_NAMES, - redundant_pub_crate::REDUNDANT_PUB_CRATE, - redundant_slicing::DEREF_BY_SLICING, - redundant_slicing::REDUNDANT_SLICING, - redundant_static_lifetimes::REDUNDANT_STATIC_LIFETIMES, - ref_option_ref::REF_OPTION_REF, - reference::DEREF_ADDROF, - regex::INVALID_REGEX, - regex::TRIVIAL_REGEX, - return_self_not_must_use::RETURN_SELF_NOT_MUST_USE, - returns::LET_AND_RETURN, - returns::NEEDLESS_RETURN, - same_name_method::SAME_NAME_METHOD, - self_named_constructors::SELF_NAMED_CONSTRUCTORS, - semicolon_if_nothing_returned::SEMICOLON_IF_NOTHING_RETURNED, - serde_api::SERDE_API_MISUSE, - shadow::SHADOW_REUSE, - shadow::SHADOW_SAME, - shadow::SHADOW_UNRELATED, - single_char_lifetime_names::SINGLE_CHAR_LIFETIME_NAMES, - single_component_path_imports::SINGLE_COMPONENT_PATH_IMPORTS, - size_of_in_element_count::SIZE_OF_IN_ELEMENT_COUNT, - slow_vector_initialization::SLOW_VECTOR_INITIALIZATION, - std_instead_of_core::ALLOC_INSTEAD_OF_CORE, - std_instead_of_core::STD_INSTEAD_OF_ALLOC, - std_instead_of_core::STD_INSTEAD_OF_CORE, - strings::STRING_ADD, - strings::STRING_ADD_ASSIGN, - strings::STRING_FROM_UTF8_AS_BYTES, - strings::STRING_LIT_AS_BYTES, - strings::STRING_SLICE, - strings::STRING_TO_STRING, - strings::STR_TO_STRING, - strings::TRIM_SPLIT_WHITESPACE, - strlen_on_c_strings::STRLEN_ON_C_STRINGS, - suspicious_operation_groupings::SUSPICIOUS_OPERATION_GROUPINGS, - suspicious_trait_impl::SUSPICIOUS_ARITHMETIC_IMPL, - suspicious_trait_impl::SUSPICIOUS_OP_ASSIGN_IMPL, - swap::ALMOST_SWAPPED, - swap::MANUAL_SWAP, - swap_ptr_to_ref::SWAP_PTR_TO_REF, - tabs_in_doc_comments::TABS_IN_DOC_COMMENTS, - temporary_assignment::TEMPORARY_ASSIGNMENT, - to_digit_is_some::TO_DIGIT_IS_SOME, - trailing_empty_array::TRAILING_EMPTY_ARRAY, - trait_bounds::TRAIT_DUPLICATION_IN_BOUNDS, - trait_bounds::TYPE_REPETITION_IN_BOUNDS, - transmute::CROSSPOINTER_TRANSMUTE, - transmute::TRANSMUTES_EXPRESSIBLE_AS_PTR_CASTS, - transmute::TRANSMUTE_BYTES_TO_STR, - transmute::TRANSMUTE_FLOAT_TO_INT, - transmute::TRANSMUTE_INT_TO_BOOL, - transmute::TRANSMUTE_INT_TO_CHAR, - transmute::TRANSMUTE_INT_TO_FLOAT, - transmute::TRANSMUTE_NUM_TO_BYTES, - transmute::TRANSMUTE_PTR_TO_PTR, - transmute::TRANSMUTE_PTR_TO_REF, - transmute::TRANSMUTE_UNDEFINED_REPR, - transmute::TRANSMUTING_NULL, - transmute::UNSOUND_COLLECTION_TRANSMUTE, - transmute::USELESS_TRANSMUTE, - transmute::WRONG_TRANSMUTE, - types::BORROWED_BOX, - types::BOX_COLLECTION, - types::LINKEDLIST, - types::OPTION_OPTION, - types::RC_BUFFER, - types::RC_MUTEX, - types::REDUNDANT_ALLOCATION, - types::TYPE_COMPLEXITY, - types::VEC_BOX, - undocumented_unsafe_blocks::UNDOCUMENTED_UNSAFE_BLOCKS, - unicode::INVISIBLE_CHARACTERS, - unicode::NON_ASCII_LITERAL, - unicode::UNICODE_NOT_NFC, - uninit_vec::UNINIT_VEC, - unit_return_expecting_ord::UNIT_RETURN_EXPECTING_ORD, - unit_types::LET_UNIT_VALUE, - unit_types::UNIT_ARG, - unit_types::UNIT_CMP, - unnamed_address::FN_ADDRESS_COMPARISONS, - unnamed_address::VTABLE_ADDRESS_COMPARISONS, - unnecessary_owned_empty_strings::UNNECESSARY_OWNED_EMPTY_STRINGS, - unnecessary_self_imports::UNNECESSARY_SELF_IMPORTS, - unnecessary_wraps::UNNECESSARY_WRAPS, - unnested_or_patterns::UNNESTED_OR_PATTERNS, - unsafe_removed_from_name::UNSAFE_REMOVED_FROM_NAME, - unused_async::UNUSED_ASYNC, - unused_io_amount::UNUSED_IO_AMOUNT, - unused_peekable::UNUSED_PEEKABLE, - unused_rounding::UNUSED_ROUNDING, - unused_self::UNUSED_SELF, - unused_unit::UNUSED_UNIT, - unwrap::PANICKING_UNWRAP, - unwrap::UNNECESSARY_UNWRAP, - unwrap_in_result::UNWRAP_IN_RESULT, - upper_case_acronyms::UPPER_CASE_ACRONYMS, - use_self::USE_SELF, - useless_conversion::USELESS_CONVERSION, - vec::USELESS_VEC, - vec_init_then_push::VEC_INIT_THEN_PUSH, - wildcard_imports::ENUM_GLOB_USE, - wildcard_imports::WILDCARD_IMPORTS, - write::PRINTLN_EMPTY_STRING, - write::PRINT_LITERAL, - write::PRINT_STDERR, - write::PRINT_STDOUT, - write::PRINT_WITH_NEWLINE, - write::USE_DEBUG, - write::WRITELN_EMPTY_STRING, - write::WRITE_LITERAL, - write::WRITE_WITH_NEWLINE, - zero_div_zero::ZERO_DIVIDED_BY_ZERO, - zero_sized_map_values::ZERO_SIZED_MAP_VALUES, -]) diff --git a/clippy_lints/src/lib.register_nursery.rs b/clippy_lints/src/lib.register_nursery.rs deleted file mode 100644 index a75bc81b222..00000000000 --- a/clippy_lints/src/lib.register_nursery.rs +++ /dev/null @@ -1,41 +0,0 @@ -// This file was generated by `cargo dev update_lints`. -// Use that command to update this file and do not edit by hand. -// Manual edits will be overwritten. - -store.register_group(true, "clippy::nursery", Some("clippy_nursery"), vec![ - LintId::of(attrs::EMPTY_LINE_AFTER_OUTER_ATTR), - LintId::of(casts::AS_PTR_CAST_MUT), - LintId::of(cognitive_complexity::COGNITIVE_COMPLEXITY), - LintId::of(copies::BRANCHES_SHARING_CODE), - LintId::of(derive::DERIVE_PARTIAL_EQ_WITHOUT_EQ), - LintId::of(equatable_if_let::EQUATABLE_IF_LET), - LintId::of(fallible_impl_from::FALLIBLE_IMPL_FROM), - LintId::of(floating_point_arithmetic::IMPRECISE_FLOPS), - LintId::of(floating_point_arithmetic::SUBOPTIMAL_FLOPS), - LintId::of(future_not_send::FUTURE_NOT_SEND), - LintId::of(index_refutable_slice::INDEX_REFUTABLE_SLICE), - LintId::of(let_if_seq::USELESS_LET_IF_SEQ), - LintId::of(matches::SIGNIFICANT_DROP_IN_SCRUTINEE), - LintId::of(methods::ITER_ON_EMPTY_COLLECTIONS), - LintId::of(methods::ITER_ON_SINGLE_ITEMS), - LintId::of(methods::ITER_WITH_DRAIN), - LintId::of(methods::PATH_BUF_PUSH_OVERWRITE), - LintId::of(missing_const_for_fn::MISSING_CONST_FOR_FN), - LintId::of(mutable_debug_assertion::DEBUG_ASSERT_WITH_MUT_CALL), - LintId::of(mutex_atomic::MUTEX_ATOMIC), - LintId::of(mutex_atomic::MUTEX_INTEGER), - LintId::of(non_send_fields_in_send_ty::NON_SEND_FIELDS_IN_SEND_TY), - LintId::of(nonstandard_macro_braces::NONSTANDARD_MACRO_BRACES), - LintId::of(option_if_let_else::OPTION_IF_LET_ELSE), - LintId::of(redundant_pub_crate::REDUNDANT_PUB_CRATE), - LintId::of(regex::TRIVIAL_REGEX), - LintId::of(strings::STRING_LIT_AS_BYTES), - LintId::of(suspicious_operation_groupings::SUSPICIOUS_OPERATION_GROUPINGS), - LintId::of(trailing_empty_array::TRAILING_EMPTY_ARRAY), - LintId::of(trait_bounds::TRAIT_DUPLICATION_IN_BOUNDS), - LintId::of(trait_bounds::TYPE_REPETITION_IN_BOUNDS), - LintId::of(transmute::TRANSMUTE_UNDEFINED_REPR), - LintId::of(unused_peekable::UNUSED_PEEKABLE), - LintId::of(unused_rounding::UNUSED_ROUNDING), - LintId::of(use_self::USE_SELF), -]) diff --git a/clippy_lints/src/lib.register_pedantic.rs b/clippy_lints/src/lib.register_pedantic.rs deleted file mode 100644 index 768b3347c2a..00000000000 --- a/clippy_lints/src/lib.register_pedantic.rs +++ /dev/null @@ -1,100 +0,0 @@ -// This file was generated by `cargo dev update_lints`. -// Use that command to update this file and do not edit by hand. -// Manual edits will be overwritten. - -store.register_group(true, "clippy::pedantic", Some("clippy_pedantic"), vec![ - LintId::of(attrs::INLINE_ALWAYS), - LintId::of(casts::BORROW_AS_PTR), - LintId::of(casts::CAST_LOSSLESS), - LintId::of(casts::CAST_POSSIBLE_TRUNCATION), - LintId::of(casts::CAST_POSSIBLE_WRAP), - LintId::of(casts::CAST_PRECISION_LOSS), - LintId::of(casts::CAST_PTR_ALIGNMENT), - LintId::of(casts::CAST_SIGN_LOSS), - LintId::of(casts::PTR_AS_PTR), - LintId::of(checked_conversions::CHECKED_CONVERSIONS), - LintId::of(copies::SAME_FUNCTIONS_IN_IF_CONDITION), - LintId::of(copy_iterator::COPY_ITERATOR), - LintId::of(default::DEFAULT_TRAIT_ACCESS), - LintId::of(dereference::EXPLICIT_DEREF_METHODS), - LintId::of(dereference::REF_BINDING_TO_REFERENCE), - LintId::of(derive::EXPL_IMPL_CLONE_ON_COPY), - LintId::of(derive::UNSAFE_DERIVE_DESERIALIZE), - LintId::of(doc::DOC_LINK_WITH_QUOTES), - LintId::of(doc::DOC_MARKDOWN), - LintId::of(doc::MISSING_ERRORS_DOC), - LintId::of(doc::MISSING_PANICS_DOC), - LintId::of(empty_enum::EMPTY_ENUM), - LintId::of(enum_variants::MODULE_NAME_REPETITIONS), - LintId::of(eta_reduction::REDUNDANT_CLOSURE_FOR_METHOD_CALLS), - LintId::of(excessive_bools::FN_PARAMS_EXCESSIVE_BOOLS), - LintId::of(excessive_bools::STRUCT_EXCESSIVE_BOOLS), - LintId::of(functions::MUST_USE_CANDIDATE), - LintId::of(functions::TOO_MANY_LINES), - LintId::of(if_not_else::IF_NOT_ELSE), - LintId::of(implicit_hasher::IMPLICIT_HASHER), - LintId::of(inconsistent_struct_constructor::INCONSISTENT_STRUCT_CONSTRUCTOR), - LintId::of(infinite_iter::MAYBE_INFINITE_ITER), - LintId::of(invalid_upcast_comparisons::INVALID_UPCAST_COMPARISONS), - LintId::of(items_after_statements::ITEMS_AFTER_STATEMENTS), - LintId::of(iter_not_returning_iterator::ITER_NOT_RETURNING_ITERATOR), - LintId::of(large_stack_arrays::LARGE_STACK_ARRAYS), - LintId::of(literal_representation::LARGE_DIGIT_GROUPS), - LintId::of(literal_representation::UNREADABLE_LITERAL), - LintId::of(loops::EXPLICIT_INTO_ITER_LOOP), - LintId::of(loops::EXPLICIT_ITER_LOOP), - LintId::of(macro_use::MACRO_USE_IMPORTS), - LintId::of(manual_assert::MANUAL_ASSERT), - LintId::of(manual_instant_elapsed::MANUAL_INSTANT_ELAPSED), - LintId::of(manual_string_new::MANUAL_STRING_NEW), - LintId::of(matches::MATCH_BOOL), - LintId::of(matches::MATCH_ON_VEC_ITEMS), - LintId::of(matches::MATCH_SAME_ARMS), - LintId::of(matches::MATCH_WILDCARD_FOR_SINGLE_VARIANTS), - LintId::of(matches::MATCH_WILD_ERR_ARM), - LintId::of(matches::SINGLE_MATCH_ELSE), - LintId::of(methods::CASE_SENSITIVE_FILE_EXTENSION_COMPARISONS), - LintId::of(methods::CLONED_INSTEAD_OF_COPIED), - LintId::of(methods::FILTER_MAP_NEXT), - LintId::of(methods::FLAT_MAP_OPTION), - LintId::of(methods::FROM_ITER_INSTEAD_OF_COLLECT), - LintId::of(methods::IMPLICIT_CLONE), - LintId::of(methods::INEFFICIENT_TO_STRING), - LintId::of(methods::MANUAL_OK_OR), - LintId::of(methods::MAP_UNWRAP_OR), - LintId::of(methods::NAIVE_BYTECOUNT), - LintId::of(methods::STABLE_SORT_PRIMITIVE), - LintId::of(methods::UNNECESSARY_JOIN), - LintId::of(misc::USED_UNDERSCORE_BINDING), - LintId::of(mismatching_type_param_order::MISMATCHING_TYPE_PARAM_ORDER), - LintId::of(mut_mut::MUT_MUT), - LintId::of(needless_continue::NEEDLESS_CONTINUE), - LintId::of(needless_for_each::NEEDLESS_FOR_EACH), - LintId::of(needless_pass_by_value::NEEDLESS_PASS_BY_VALUE), - LintId::of(no_effect::NO_EFFECT_UNDERSCORE_BINDING), - LintId::of(non_expressive_names::MANY_SINGLE_CHAR_NAMES), - LintId::of(non_expressive_names::SIMILAR_NAMES), - LintId::of(operators::FLOAT_CMP), - LintId::of(operators::NEEDLESS_BITWISE_BOOL), - LintId::of(operators::VERBOSE_BIT_MASK), - LintId::of(pass_by_ref_or_value::LARGE_TYPES_PASSED_BY_VALUE), - LintId::of(pass_by_ref_or_value::TRIVIALLY_COPY_PASS_BY_REF), - LintId::of(ranges::RANGE_MINUS_ONE), - LintId::of(ranges::RANGE_PLUS_ONE), - LintId::of(redundant_else::REDUNDANT_ELSE), - LintId::of(ref_option_ref::REF_OPTION_REF), - LintId::of(return_self_not_must_use::RETURN_SELF_NOT_MUST_USE), - LintId::of(semicolon_if_nothing_returned::SEMICOLON_IF_NOTHING_RETURNED), - LintId::of(strings::STRING_ADD_ASSIGN), - LintId::of(transmute::TRANSMUTE_PTR_TO_PTR), - LintId::of(types::LINKEDLIST), - LintId::of(types::OPTION_OPTION), - LintId::of(unicode::UNICODE_NOT_NFC), - LintId::of(unnecessary_wraps::UNNECESSARY_WRAPS), - LintId::of(unnested_or_patterns::UNNESTED_OR_PATTERNS), - LintId::of(unused_async::UNUSED_ASYNC), - LintId::of(unused_self::UNUSED_SELF), - LintId::of(wildcard_imports::ENUM_GLOB_USE), - LintId::of(wildcard_imports::WILDCARD_IMPORTS), - LintId::of(zero_sized_map_values::ZERO_SIZED_MAP_VALUES), -]) diff --git a/clippy_lints/src/lib.register_perf.rs b/clippy_lints/src/lib.register_perf.rs deleted file mode 100644 index 8e927470e02..00000000000 --- a/clippy_lints/src/lib.register_perf.rs +++ /dev/null @@ -1,34 +0,0 @@ -// This file was generated by `cargo dev update_lints`. -// Use that command to update this file and do not edit by hand. -// Manual edits will be overwritten. - -store.register_group(true, "clippy::perf", Some("clippy_perf"), vec![ - LintId::of(box_default::BOX_DEFAULT), - LintId::of(entry::MAP_ENTRY), - LintId::of(escape::BOXED_LOCAL), - LintId::of(format_args::FORMAT_IN_FORMAT_ARGS), - LintId::of(format_args::TO_STRING_IN_FORMAT_ARGS), - LintId::of(functions::RESULT_LARGE_ERR), - LintId::of(large_const_arrays::LARGE_CONST_ARRAYS), - LintId::of(large_enum_variant::LARGE_ENUM_VARIANT), - LintId::of(loops::MANUAL_MEMCPY), - LintId::of(loops::MISSING_SPIN_LOOP), - LintId::of(loops::NEEDLESS_COLLECT), - LintId::of(manual_retain::MANUAL_RETAIN), - LintId::of(methods::COLLAPSIBLE_STR_REPLACE), - LintId::of(methods::EXPECT_FUN_CALL), - LintId::of(methods::EXTEND_WITH_DRAIN), - LintId::of(methods::ITER_NTH), - LintId::of(methods::ITER_OVEREAGER_CLONED), - LintId::of(methods::MANUAL_STR_REPEAT), - LintId::of(methods::OR_FUN_CALL), - LintId::of(methods::SINGLE_CHAR_PATTERN), - LintId::of(methods::UNNECESSARY_TO_OWNED), - LintId::of(operators::CMP_OWNED), - LintId::of(redundant_clone::REDUNDANT_CLONE), - LintId::of(slow_vector_initialization::SLOW_VECTOR_INITIALIZATION), - LintId::of(types::BOX_COLLECTION), - LintId::of(types::REDUNDANT_ALLOCATION), - LintId::of(vec::USELESS_VEC), - LintId::of(vec_init_then_push::VEC_INIT_THEN_PUSH), -]) diff --git a/clippy_lints/src/lib.register_restriction.rs b/clippy_lints/src/lib.register_restriction.rs deleted file mode 100644 index f62d57af5b4..00000000000 --- a/clippy_lints/src/lib.register_restriction.rs +++ /dev/null @@ -1,90 +0,0 @@ -// This file was generated by `cargo dev update_lints`. -// Use that command to update this file and do not edit by hand. -// Manual edits will be overwritten. - -store.register_group(true, "clippy::restriction", Some("clippy_restriction"), vec![ - LintId::of(as_conversions::AS_CONVERSIONS), - LintId::of(asm_syntax::INLINE_ASM_X86_ATT_SYNTAX), - LintId::of(asm_syntax::INLINE_ASM_X86_INTEL_SYNTAX), - LintId::of(assertions_on_result_states::ASSERTIONS_ON_RESULT_STATES), - LintId::of(attrs::ALLOW_ATTRIBUTES_WITHOUT_REASON), - LintId::of(casts::AS_UNDERSCORE), - LintId::of(casts::FN_TO_NUMERIC_CAST_ANY), - LintId::of(create_dir::CREATE_DIR), - LintId::of(dbg_macro::DBG_MACRO), - LintId::of(default_numeric_fallback::DEFAULT_NUMERIC_FALLBACK), - LintId::of(default_union_representation::DEFAULT_UNION_REPRESENTATION), - LintId::of(disallowed_script_idents::DISALLOWED_SCRIPT_IDENTS), - LintId::of(else_if_without_else::ELSE_IF_WITHOUT_ELSE), - LintId::of(empty_drop::EMPTY_DROP), - LintId::of(empty_structs_with_brackets::EMPTY_STRUCTS_WITH_BRACKETS), - LintId::of(exhaustive_items::EXHAUSTIVE_ENUMS), - LintId::of(exhaustive_items::EXHAUSTIVE_STRUCTS), - LintId::of(exit::EXIT), - LintId::of(float_literal::LOSSY_FLOAT_LITERAL), - LintId::of(format_push_string::FORMAT_PUSH_STRING), - LintId::of(if_then_some_else_none::IF_THEN_SOME_ELSE_NONE), - LintId::of(implicit_return::IMPLICIT_RETURN), - LintId::of(indexing_slicing::INDEXING_SLICING), - LintId::of(inherent_impl::MULTIPLE_INHERENT_IMPL), - LintId::of(large_include_file::LARGE_INCLUDE_FILE), - LintId::of(let_underscore::LET_UNDERSCORE_MUST_USE), - LintId::of(literal_representation::DECIMAL_LITERAL_REPRESENTATION), - LintId::of(matches::REST_PAT_IN_FULLY_BOUND_STRUCTS), - LintId::of(matches::TRY_ERR), - LintId::of(matches::WILDCARD_ENUM_MATCH_ARM), - LintId::of(mem_forget::MEM_FORGET), - LintId::of(methods::CLONE_ON_REF_PTR), - LintId::of(methods::EXPECT_USED), - LintId::of(methods::FILETYPE_IS_FILE), - LintId::of(methods::GET_UNWRAP), - LintId::of(methods::MAP_ERR_IGNORE), - LintId::of(methods::UNWRAP_USED), - LintId::of(methods::VERBOSE_FILE_READS), - LintId::of(misc_early::SEPARATED_LITERAL_SUFFIX), - LintId::of(misc_early::UNNEEDED_FIELD_PATTERN), - LintId::of(misc_early::UNSEPARATED_LITERAL_SUFFIX), - LintId::of(missing_doc::MISSING_DOCS_IN_PRIVATE_ITEMS), - LintId::of(missing_enforced_import_rename::MISSING_ENFORCED_IMPORT_RENAMES), - LintId::of(missing_inline::MISSING_INLINE_IN_PUBLIC_ITEMS), - LintId::of(missing_trait_methods::MISSING_TRAIT_METHODS), - LintId::of(mixed_read_write_in_expression::MIXED_READ_WRITE_IN_EXPRESSION), - LintId::of(module_style::MOD_MODULE_FILES), - LintId::of(module_style::SELF_NAMED_MODULE_FILES), - LintId::of(operators::ARITHMETIC_SIDE_EFFECTS), - LintId::of(operators::FLOAT_ARITHMETIC), - LintId::of(operators::FLOAT_CMP_CONST), - LintId::of(operators::INTEGER_ARITHMETIC), - LintId::of(operators::INTEGER_DIVISION), - LintId::of(operators::MODULO_ARITHMETIC), - LintId::of(panic_in_result_fn::PANIC_IN_RESULT_FN), - LintId::of(panic_unimplemented::PANIC), - LintId::of(panic_unimplemented::TODO), - LintId::of(panic_unimplemented::UNIMPLEMENTED), - LintId::of(panic_unimplemented::UNREACHABLE), - LintId::of(partial_pub_fields::PARTIAL_PUB_FIELDS), - LintId::of(pattern_type_mismatch::PATTERN_TYPE_MISMATCH), - LintId::of(pub_use::PUB_USE), - LintId::of(redundant_slicing::DEREF_BY_SLICING), - LintId::of(same_name_method::SAME_NAME_METHOD), - LintId::of(shadow::SHADOW_REUSE), - LintId::of(shadow::SHADOW_SAME), - LintId::of(shadow::SHADOW_UNRELATED), - LintId::of(single_char_lifetime_names::SINGLE_CHAR_LIFETIME_NAMES), - LintId::of(std_instead_of_core::ALLOC_INSTEAD_OF_CORE), - LintId::of(std_instead_of_core::STD_INSTEAD_OF_ALLOC), - LintId::of(std_instead_of_core::STD_INSTEAD_OF_CORE), - LintId::of(strings::STRING_ADD), - LintId::of(strings::STRING_SLICE), - LintId::of(strings::STRING_TO_STRING), - LintId::of(strings::STR_TO_STRING), - LintId::of(types::RC_BUFFER), - LintId::of(types::RC_MUTEX), - LintId::of(undocumented_unsafe_blocks::UNDOCUMENTED_UNSAFE_BLOCKS), - LintId::of(unicode::NON_ASCII_LITERAL), - LintId::of(unnecessary_self_imports::UNNECESSARY_SELF_IMPORTS), - LintId::of(unwrap_in_result::UNWRAP_IN_RESULT), - LintId::of(write::PRINT_STDERR), - LintId::of(write::PRINT_STDOUT), - LintId::of(write::USE_DEBUG), -]) diff --git a/clippy_lints/src/lib.register_style.rs b/clippy_lints/src/lib.register_style.rs deleted file mode 100644 index 6894d69e928..00000000000 --- a/clippy_lints/src/lib.register_style.rs +++ /dev/null @@ -1,132 +0,0 @@ -// This file was generated by `cargo dev update_lints`. -// Use that command to update this file and do not edit by hand. -// Manual edits will be overwritten. - -store.register_group(true, "clippy::style", Some("clippy_style"), vec![ - LintId::of(assertions_on_constants::ASSERTIONS_ON_CONSTANTS), - LintId::of(blocks_in_if_conditions::BLOCKS_IN_IF_CONDITIONS), - LintId::of(bool_assert_comparison::BOOL_ASSERT_COMPARISON), - LintId::of(bool_to_int_with_if::BOOL_TO_INT_WITH_IF), - LintId::of(casts::FN_TO_NUMERIC_CAST), - LintId::of(casts::FN_TO_NUMERIC_CAST_WITH_TRUNCATION), - LintId::of(collapsible_if::COLLAPSIBLE_ELSE_IF), - LintId::of(collapsible_if::COLLAPSIBLE_IF), - LintId::of(comparison_chain::COMPARISON_CHAIN), - LintId::of(default::FIELD_REASSIGN_WITH_DEFAULT), - LintId::of(default_instead_of_iter_empty::DEFAULT_INSTEAD_OF_ITER_EMPTY), - LintId::of(dereference::NEEDLESS_BORROW), - LintId::of(disallowed_macros::DISALLOWED_MACROS), - LintId::of(disallowed_methods::DISALLOWED_METHODS), - LintId::of(disallowed_names::DISALLOWED_NAMES), - LintId::of(disallowed_types::DISALLOWED_TYPES), - LintId::of(doc::MISSING_SAFETY_DOC), - LintId::of(doc::NEEDLESS_DOCTEST_MAIN), - LintId::of(enum_variants::ENUM_VARIANT_NAMES), - LintId::of(enum_variants::MODULE_INCEPTION), - LintId::of(eta_reduction::REDUNDANT_CLOSURE), - LintId::of(float_literal::EXCESSIVE_PRECISION), - LintId::of(format_args::UNINLINED_FORMAT_ARGS), - LintId::of(from_over_into::FROM_OVER_INTO), - LintId::of(from_str_radix_10::FROM_STR_RADIX_10), - LintId::of(functions::DOUBLE_MUST_USE), - LintId::of(functions::MUST_USE_UNIT), - LintId::of(functions::RESULT_UNIT_ERR), - LintId::of(implicit_saturating_add::IMPLICIT_SATURATING_ADD), - LintId::of(implicit_saturating_sub::IMPLICIT_SATURATING_SUB), - LintId::of(inherent_to_string::INHERENT_TO_STRING), - LintId::of(init_numbered_fields::INIT_NUMBERED_FIELDS), - LintId::of(len_zero::COMPARISON_TO_EMPTY), - LintId::of(len_zero::LEN_WITHOUT_IS_EMPTY), - LintId::of(len_zero::LEN_ZERO), - LintId::of(literal_representation::INCONSISTENT_DIGIT_GROUPING), - LintId::of(literal_representation::UNUSUAL_BYTE_GROUPINGS), - LintId::of(loops::FOR_KV_MAP), - LintId::of(loops::NEEDLESS_RANGE_LOOP), - LintId::of(loops::SAME_ITEM_PUSH), - LintId::of(loops::WHILE_LET_ON_ITERATOR), - LintId::of(main_recursion::MAIN_RECURSION), - LintId::of(manual_async_fn::MANUAL_ASYNC_FN), - LintId::of(manual_bits::MANUAL_BITS), - LintId::of(manual_non_exhaustive::MANUAL_NON_EXHAUSTIVE), - LintId::of(match_result_ok::MATCH_RESULT_OK), - LintId::of(matches::COLLAPSIBLE_MATCH), - LintId::of(matches::INFALLIBLE_DESTRUCTURING_MATCH), - LintId::of(matches::MANUAL_MAP), - LintId::of(matches::MATCH_LIKE_MATCHES_MACRO), - LintId::of(matches::MATCH_OVERLAPPING_ARM), - LintId::of(matches::MATCH_REF_PATS), - LintId::of(matches::REDUNDANT_PATTERN_MATCHING), - LintId::of(matches::SINGLE_MATCH), - LintId::of(mem_replace::MEM_REPLACE_OPTION_WITH_NONE), - LintId::of(mem_replace::MEM_REPLACE_WITH_DEFAULT), - LintId::of(methods::BYTES_NTH), - LintId::of(methods::CHARS_LAST_CMP), - LintId::of(methods::CHARS_NEXT_CMP), - LintId::of(methods::ERR_EXPECT), - LintId::of(methods::GET_FIRST), - LintId::of(methods::INTO_ITER_ON_REF), - LintId::of(methods::IS_DIGIT_ASCII_RADIX), - LintId::of(methods::ITER_CLONED_COLLECT), - LintId::of(methods::ITER_NEXT_SLICE), - LintId::of(methods::ITER_NTH_ZERO), - LintId::of(methods::ITER_SKIP_NEXT), - LintId::of(methods::MANUAL_SATURATING_ARITHMETIC), - LintId::of(methods::MAP_CLONE), - LintId::of(methods::MAP_COLLECT_RESULT_UNIT), - LintId::of(methods::MUT_MUTEX_LOCK), - LintId::of(methods::NEW_RET_NO_SELF), - LintId::of(methods::OBFUSCATED_IF_ELSE), - LintId::of(methods::OK_EXPECT), - LintId::of(methods::OPTION_MAP_OR_NONE), - LintId::of(methods::RESULT_MAP_OR_INTO_OPTION), - LintId::of(methods::SHOULD_IMPLEMENT_TRAIT), - LintId::of(methods::SINGLE_CHAR_ADD_STR), - LintId::of(methods::STRING_EXTEND_CHARS), - LintId::of(methods::UNNECESSARY_FOLD), - LintId::of(methods::UNNECESSARY_LAZY_EVALUATIONS), - LintId::of(methods::UNWRAP_OR_ELSE_DEFAULT), - LintId::of(methods::WRONG_SELF_CONVENTION), - LintId::of(misc::TOPLEVEL_REF_ARG), - LintId::of(misc::ZERO_PTR), - LintId::of(misc_early::BUILTIN_TYPE_SHADOW), - LintId::of(misc_early::DOUBLE_NEG), - LintId::of(misc_early::DUPLICATE_UNDERSCORE_ARGUMENT), - LintId::of(misc_early::MIXED_CASE_HEX_LITERALS), - LintId::of(misc_early::REDUNDANT_PATTERN), - LintId::of(mut_reference::UNNECESSARY_MUT_PASSED), - LintId::of(needless_late_init::NEEDLESS_LATE_INIT), - LintId::of(needless_parens_on_range_literals::NEEDLESS_PARENS_ON_RANGE_LITERALS), - LintId::of(neg_multiply::NEG_MULTIPLY), - LintId::of(new_without_default::NEW_WITHOUT_DEFAULT), - LintId::of(non_copy_const::BORROW_INTERIOR_MUTABLE_CONST), - LintId::of(non_copy_const::DECLARE_INTERIOR_MUTABLE_CONST), - LintId::of(non_expressive_names::JUST_UNDERSCORES_AND_DIGITS), - LintId::of(operators::ASSIGN_OP_PATTERN), - LintId::of(operators::OP_REF), - LintId::of(operators::PTR_EQ), - LintId::of(partialeq_to_none::PARTIALEQ_TO_NONE), - LintId::of(ptr::CMP_NULL), - LintId::of(ptr::PTR_ARG), - LintId::of(question_mark::QUESTION_MARK), - LintId::of(ranges::MANUAL_RANGE_CONTAINS), - LintId::of(redundant_field_names::REDUNDANT_FIELD_NAMES), - LintId::of(redundant_static_lifetimes::REDUNDANT_STATIC_LIFETIMES), - LintId::of(returns::LET_AND_RETURN), - LintId::of(returns::NEEDLESS_RETURN), - LintId::of(self_named_constructors::SELF_NAMED_CONSTRUCTORS), - LintId::of(single_component_path_imports::SINGLE_COMPONENT_PATH_IMPORTS), - LintId::of(strings::TRIM_SPLIT_WHITESPACE), - LintId::of(tabs_in_doc_comments::TABS_IN_DOC_COMMENTS), - LintId::of(to_digit_is_some::TO_DIGIT_IS_SOME), - LintId::of(unit_types::LET_UNIT_VALUE), - LintId::of(unnecessary_owned_empty_strings::UNNECESSARY_OWNED_EMPTY_STRINGS), - LintId::of(unsafe_removed_from_name::UNSAFE_REMOVED_FROM_NAME), - LintId::of(unused_unit::UNUSED_UNIT), - LintId::of(upper_case_acronyms::UPPER_CASE_ACRONYMS), - LintId::of(write::PRINTLN_EMPTY_STRING), - LintId::of(write::PRINT_LITERAL), - LintId::of(write::PRINT_WITH_NEWLINE), - LintId::of(write::WRITELN_EMPTY_STRING), - LintId::of(write::WRITE_LITERAL), - LintId::of(write::WRITE_WITH_NEWLINE), -]) diff --git a/clippy_lints/src/lib.register_suspicious.rs b/clippy_lints/src/lib.register_suspicious.rs deleted file mode 100644 index 61af098c59a..00000000000 --- a/clippy_lints/src/lib.register_suspicious.rs +++ /dev/null @@ -1,39 +0,0 @@ -// This file was generated by `cargo dev update_lints`. -// Use that command to update this file and do not edit by hand. -// Manual edits will be overwritten. - -store.register_group(true, "clippy::suspicious", Some("clippy_suspicious"), vec![ - LintId::of(almost_complete_letter_range::ALMOST_COMPLETE_LETTER_RANGE), - LintId::of(attrs::BLANKET_CLIPPY_RESTRICTION_LINTS), - LintId::of(await_holding_invalid::AWAIT_HOLDING_INVALID_TYPE), - LintId::of(await_holding_invalid::AWAIT_HOLDING_LOCK), - LintId::of(await_holding_invalid::AWAIT_HOLDING_REFCELL_REF), - LintId::of(casts::CAST_ABS_TO_UNSIGNED), - LintId::of(casts::CAST_ENUM_CONSTRUCTOR), - LintId::of(casts::CAST_ENUM_TRUNCATION), - LintId::of(casts::CAST_NAN_TO_INT), - LintId::of(casts::CAST_SLICE_FROM_RAW_PARTS), - LintId::of(crate_in_macro_def::CRATE_IN_MACRO_DEF), - LintId::of(drop_forget_ref::DROP_NON_DROP), - LintId::of(drop_forget_ref::FORGET_NON_DROP), - LintId::of(duplicate_mod::DUPLICATE_MOD), - LintId::of(format_impl::PRINT_IN_FORMAT_IMPL), - LintId::of(formatting::SUSPICIOUS_ASSIGNMENT_FORMATTING), - LintId::of(formatting::SUSPICIOUS_ELSE_FORMATTING), - LintId::of(formatting::SUSPICIOUS_UNARY_OP_FORMATTING), - LintId::of(from_raw_with_void_ptr::FROM_RAW_WITH_VOID_PTR), - LintId::of(loops::EMPTY_LOOP), - LintId::of(loops::MUT_RANGE_BOUND), - LintId::of(methods::NO_EFFECT_REPLACE), - LintId::of(methods::SUSPICIOUS_MAP), - LintId::of(methods::SUSPICIOUS_TO_OWNED), - LintId::of(multi_assignments::MULTI_ASSIGNMENTS), - LintId::of(mut_key::MUTABLE_KEY_TYPE), - LintId::of(octal_escapes::OCTAL_ESCAPES), - LintId::of(operators::FLOAT_EQUALITY_WITHOUT_ABS), - LintId::of(operators::MISREFACTORED_ASSIGN_OP), - LintId::of(rc_clone_in_vec_init::RC_CLONE_IN_VEC_INIT), - LintId::of(suspicious_trait_impl::SUSPICIOUS_ARITHMETIC_IMPL), - LintId::of(suspicious_trait_impl::SUSPICIOUS_OP_ASSIGN_IMPL), - LintId::of(swap_ptr_to_ref::SWAP_PTR_TO_REF), -]) diff --git a/clippy_lints/src/lib.rs b/clippy_lints/src/lib.rs index 28248d01b64..7837e04bca1 100644 --- a/clippy_lints/src/lib.rs +++ b/clippy_lints/src/lib.rs @@ -46,122 +46,21 @@ extern crate rustc_trait_selection; #[macro_use] extern crate clippy_utils; +#[macro_use] +extern crate declare_clippy_lint; use clippy_utils::parse_msrv; use rustc_data_structures::fx::FxHashSet; -use rustc_lint::LintId; +use rustc_lint::{Lint, LintId}; use rustc_semver::RustcVersion; use rustc_session::Session; -/// Macro used to declare a Clippy lint. -/// -/// Every lint declaration consists of 4 parts: -/// -/// 1. The documentation, which is used for the website -/// 2. The `LINT_NAME`. See [lint naming][lint_naming] on lint naming conventions. -/// 3. The `lint_level`, which is a mapping from *one* of our lint groups to `Allow`, `Warn` or -/// `Deny`. The lint level here has nothing to do with what lint groups the lint is a part of. -/// 4. The `description` that contains a short explanation on what's wrong with code where the -/// lint is triggered. -/// -/// Currently the categories `style`, `correctness`, `suspicious`, `complexity` and `perf` are -/// enabled by default. As said in the README.md of this repository, if the lint level mapping -/// changes, please update README.md. -/// -/// # Example -/// -/// ``` -/// #![feature(rustc_private)] -/// extern crate rustc_session; -/// use rustc_session::declare_tool_lint; -/// use clippy_lints::declare_clippy_lint; -/// -/// declare_clippy_lint! { -/// /// ### What it does -/// /// Checks for ... (describe what the lint matches). -/// /// -/// /// ### Why is this bad? -/// /// Supply the reason for linting the code. -/// /// -/// /// ### Example -/// /// ```rust -/// /// Insert a short example of code that triggers the lint -/// /// ``` -/// /// -/// /// Use instead: -/// /// ```rust -/// /// Insert a short example of improved code that doesn't trigger the lint -/// /// ``` -/// pub LINT_NAME, -/// pedantic, -/// "description" -/// } -/// ``` -/// [lint_naming]: https://rust-lang.github.io/rfcs/0344-conventions-galore.html#lints -#[macro_export] -macro_rules! declare_clippy_lint { - { $(#[$attr:meta])* pub $name:tt, style, $description:tt } => { - declare_tool_lint! { - $(#[$attr])* pub clippy::$name, Warn, $description, report_in_external_macro: true - } - }; - { $(#[$attr:meta])* pub $name:tt, correctness, $description:tt } => { - declare_tool_lint! { - $(#[$attr])* pub clippy::$name, Deny, $description, report_in_external_macro: true - } - }; - { $(#[$attr:meta])* pub $name:tt, suspicious, $description:tt } => { - declare_tool_lint! { - $(#[$attr])* pub clippy::$name, Warn, $description, report_in_external_macro: true - } - }; - { $(#[$attr:meta])* pub $name:tt, complexity, $description:tt } => { - declare_tool_lint! { - $(#[$attr])* pub clippy::$name, Warn, $description, report_in_external_macro: true - } - }; - { $(#[$attr:meta])* pub $name:tt, perf, $description:tt } => { - declare_tool_lint! { - $(#[$attr])* pub clippy::$name, Warn, $description, report_in_external_macro: true - } - }; - { $(#[$attr:meta])* pub $name:tt, pedantic, $description:tt } => { - declare_tool_lint! { - $(#[$attr])* pub clippy::$name, Allow, $description, report_in_external_macro: true - } - }; - { $(#[$attr:meta])* pub $name:tt, restriction, $description:tt } => { - declare_tool_lint! { - $(#[$attr])* pub clippy::$name, Allow, $description, report_in_external_macro: true - } - }; - { $(#[$attr:meta])* pub $name:tt, cargo, $description:tt } => { - declare_tool_lint! { - $(#[$attr])* pub clippy::$name, Allow, $description, report_in_external_macro: true - } - }; - { $(#[$attr:meta])* pub $name:tt, nursery, $description:tt } => { - declare_tool_lint! { - $(#[$attr])* pub clippy::$name, Allow, $description, report_in_external_macro: true - } - }; - { $(#[$attr:meta])* pub $name:tt, internal, $description:tt } => { - declare_tool_lint! { - $(#[$attr])* pub clippy::$name, Allow, $description, report_in_external_macro: true - } - }; - { $(#[$attr:meta])* pub $name:tt, internal_warn, $description:tt } => { - declare_tool_lint! { - $(#[$attr])* pub clippy::$name, Warn, $description, report_in_external_macro: true - } - }; -} - #[cfg(feature = "internal")] pub mod deprecated_lints; #[cfg_attr(feature = "internal", allow(clippy::missing_clippy_version_attribute))] mod utils; +mod declared_lints; mod renamed_lints; // begin lints modules, do not remove this comment, it’s used in `update_lints` @@ -495,31 +394,121 @@ pub fn read_conf(sess: &Session) -> Conf { conf } +#[derive(Default)] +struct RegistrationGroups { + all: Vec, + cargo: Vec, + complexity: Vec, + correctness: Vec, + nursery: Vec, + pedantic: Vec, + perf: Vec, + restriction: Vec, + style: Vec, + suspicious: Vec, + #[cfg(feature = "internal")] + internal: Vec, +} + +impl RegistrationGroups { + #[rustfmt::skip] + fn register(self, store: &mut rustc_lint::LintStore) { + store.register_group(true, "clippy::all", Some("clippy_all"), self.all); + store.register_group(true, "clippy::cargo", Some("clippy_cargo"), self.cargo); + store.register_group(true, "clippy::complexity", Some("clippy_complexity"), self.complexity); + store.register_group(true, "clippy::correctness", Some("clippy_correctness"), self.correctness); + store.register_group(true, "clippy::nursery", Some("clippy_nursery"), self.nursery); + store.register_group(true, "clippy::pedantic", Some("clippy_pedantic"), self.pedantic); + store.register_group(true, "clippy::perf", Some("clippy_perf"), self.perf); + store.register_group(true, "clippy::restriction", Some("clippy_restriction"), self.restriction); + store.register_group(true, "clippy::style", Some("clippy_style"), self.style); + store.register_group(true, "clippy::suspicious", Some("clippy_suspicious"), self.suspicious); + #[cfg(feature = "internal")] + store.register_group(true, "clippy::internal", Some("clippy_internal"), self.internal); + } +} + +#[derive(Copy, Clone)] +pub(crate) enum LintCategory { + Cargo, + Complexity, + Correctness, + Nursery, + Pedantic, + Perf, + Restriction, + Style, + Suspicious, + #[cfg(feature = "internal")] + Internal, +} +#[allow(clippy::enum_glob_use)] +use LintCategory::*; + +impl LintCategory { + fn is_all(self) -> bool { + matches!(self, Correctness | Suspicious | Style | Complexity | Perf) + } + + fn group(self, groups: &mut RegistrationGroups) -> &mut Vec { + match self { + Cargo => &mut groups.cargo, + Complexity => &mut groups.complexity, + Correctness => &mut groups.correctness, + Nursery => &mut groups.nursery, + Pedantic => &mut groups.pedantic, + Perf => &mut groups.perf, + Restriction => &mut groups.restriction, + Style => &mut groups.style, + Suspicious => &mut groups.suspicious, + #[cfg(feature = "internal")] + Internal => &mut groups.internal, + } + } +} + +pub(crate) struct LintInfo { + /// Double reference to maintain pointer equality + lint: &'static &'static Lint, + category: LintCategory, + explanation: &'static str, +} + +pub fn explain(name: &str) { + let target = format!("clippy::{}", name.to_ascii_uppercase()); + match declared_lints::LINTS.iter().find(|info| info.lint.name == target) { + Some(info) => print!("{}", info.explanation), + None => println!("unknown lint: {name}"), + } +} + +fn register_categories(store: &mut rustc_lint::LintStore) { + let mut groups = RegistrationGroups::default(); + + for LintInfo { lint, category, .. } in declared_lints::LINTS { + if category.is_all() { + groups.all.push(LintId::of(lint)); + } + + category.group(&mut groups).push(LintId::of(lint)); + } + + let lints: Vec<&'static Lint> = declared_lints::LINTS.iter().map(|info| *info.lint).collect(); + + store.register_lints(&lints); + groups.register(store); +} + /// Register all lints and lint groups with the rustc plugin registry /// /// Used in `./src/driver.rs`. #[expect(clippy::too_many_lines)] pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf: &Conf) { register_removed_non_tool_lints(store); + register_categories(store); include!("lib.deprecated.rs"); - include!("lib.register_lints.rs"); - include!("lib.register_restriction.rs"); - include!("lib.register_pedantic.rs"); - - #[cfg(feature = "internal")] - include!("lib.register_internal.rs"); - - include!("lib.register_all.rs"); - include!("lib.register_style.rs"); - include!("lib.register_complexity.rs"); - include!("lib.register_correctness.rs"); - include!("lib.register_suspicious.rs"); - include!("lib.register_perf.rs"); - include!("lib.register_cargo.rs"); - include!("lib.register_nursery.rs"); - #[cfg(feature = "internal")] { if std::env::var("ENABLE_METADATA_COLLECTION").eq(&Ok("1".to_string())) { diff --git a/declare_clippy_lint/Cargo.toml b/declare_clippy_lint/Cargo.toml new file mode 100644 index 00000000000..68bb0be67a7 --- /dev/null +++ b/declare_clippy_lint/Cargo.toml @@ -0,0 +1,13 @@ +[package] +name = "declare_clippy_lint" +version = "0.1.66" +edition = "2021" +publish = false + +[lib] +proc-macro = true + +[dependencies] +itertools = "0.10.1" +quote = "1.0.21" +syn = "1.0.100" diff --git a/declare_clippy_lint/src/lib.rs b/declare_clippy_lint/src/lib.rs new file mode 100644 index 00000000000..962766916dd --- /dev/null +++ b/declare_clippy_lint/src/lib.rs @@ -0,0 +1,173 @@ +#![feature(let_chains)] +#![cfg_attr(feature = "deny-warnings", deny(warnings))] + +use proc_macro::TokenStream; +use quote::{format_ident, quote}; +use syn::parse::{Parse, ParseStream}; +use syn::{parse_macro_input, Attribute, Error, Ident, Lit, LitStr, Meta, Result, Token}; + +fn parse_attr(path: [&'static str; LEN], attr: &Attribute) -> Option { + if let Meta::NameValue(name_value) = attr.parse_meta().ok()? { + let path_idents = name_value.path.segments.iter().map(|segment| &segment.ident); + + if itertools::equal(path_idents, path) + && let Lit::Str(lit) = name_value.lit + { + return Some(lit); + } + } + + None +} + +struct ClippyLint { + attrs: Vec, + explanation: String, + name: Ident, + category: Ident, + description: LitStr, +} + +impl Parse for ClippyLint { + fn parse(input: ParseStream) -> Result { + let attrs = input.call(Attribute::parse_outer)?; + + let mut in_code = false; + let mut explanation = String::new(); + let mut version = None; + for attr in &attrs { + if let Some(lit) = parse_attr(["doc"], attr) { + let value = lit.value(); + let line = value.strip_prefix(' ').unwrap_or(&value); + + if line.starts_with("```") { + explanation += "```\n"; + in_code = !in_code; + } else if !(in_code && line.starts_with("# ")) { + explanation += line; + explanation.push('\n'); + } + } else if let Some(lit) = parse_attr(["clippy", "version"], attr) { + if let Some(duplicate) = version.replace(lit) { + return Err(Error::new_spanned(duplicate, "duplicate clippy::version")); + } + } else { + return Err(Error::new_spanned(attr, "unexpected attribute")); + } + } + + input.parse::()?; + let name = input.parse()?; + input.parse::()?; + + let category = input.parse()?; + input.parse::()?; + + let description = input.parse()?; + + Ok(Self { + attrs, + explanation, + name, + category, + description, + }) + } +} + +/// Macro used to declare a Clippy lint. +/// +/// Every lint declaration consists of 4 parts: +/// +/// 1. The documentation, which is used for the website and `cargo clippy --explain` +/// 2. The `LINT_NAME`. See [lint naming][lint_naming] on lint naming conventions. +/// 3. The `lint_level`, which is a mapping from *one* of our lint groups to `Allow`, `Warn` or +/// `Deny`. The lint level here has nothing to do with what lint groups the lint is a part of. +/// 4. The `description` that contains a short explanation on what's wrong with code where the +/// lint is triggered. +/// +/// Currently the categories `style`, `correctness`, `suspicious`, `complexity` and `perf` are +/// enabled by default. As said in the README.md of this repository, if the lint level mapping +/// changes, please update README.md. +/// +/// # Example +/// +/// ``` +/// use rustc_session::declare_tool_lint; +/// +/// declare_clippy_lint! { +/// /// ### What it does +/// /// Checks for ... (describe what the lint matches). +/// /// +/// /// ### Why is this bad? +/// /// Supply the reason for linting the code. +/// /// +/// /// ### Example +/// /// ```rust +/// /// Insert a short example of code that triggers the lint +/// /// ``` +/// /// +/// /// Use instead: +/// /// ```rust +/// /// Insert a short example of improved code that doesn't trigger the lint +/// /// ``` +/// #[clippy::version = "1.65.0"] +/// pub LINT_NAME, +/// pedantic, +/// "description" +/// } +/// ``` +/// [lint_naming]: https://rust-lang.github.io/rfcs/0344-conventions-galore.html#lints +#[proc_macro] +pub fn declare_clippy_lint(input: TokenStream) -> TokenStream { + let ClippyLint { + attrs, + explanation, + name, + category, + description, + } = parse_macro_input!(input as ClippyLint); + + let mut category = category.to_string(); + + let level = format_ident!( + "{}", + match category.as_str() { + "correctness" => "Deny", + "style" | "suspicious" | "complexity" | "perf" | "internal_warn" => "Warn", + "pedantic" | "restriction" | "cargo" | "nursery" | "internal" => "Allow", + _ => panic!("unknown category {category}"), + }, + ); + + let info = if category == "internal_warn" { + None + } else { + let info_name = format_ident!("{name}_INFO"); + + (&mut category[0..1]).make_ascii_uppercase(); + let category_variant = format_ident!("{category}"); + + Some(quote! { + pub(crate) static #info_name: &'static crate::LintInfo = &crate::LintInfo { + lint: &#name, + category: crate::LintCategory::#category_variant, + explanation: #explanation, + }; + }) + }; + + let output = quote! { + declare_tool_lint! { + #(#attrs)* + pub clippy::#name, + #level, + #description, + report_in_external_macro: true + } + + #info + }; + + TokenStream::from(output) +} diff --git a/src/docs.rs b/src/docs.rs deleted file mode 100644 index d9c34a6c049..00000000000 --- a/src/docs.rs +++ /dev/null @@ -1,606 +0,0 @@ -// autogenerated. Please look at /clippy_dev/src/update_lints.rs - -macro_rules! include_lint { - ($file_name: expr) => { - include_str!($file_name) - }; -} - -macro_rules! docs { - ($($lint_name: expr,)*) => { - pub fn explain(lint: &str) { - println!("{}", match lint { - $( - $lint_name => include_lint!(concat!("docs/", concat!($lint_name, ".txt"))), - )* - _ => "unknown lint", - }) - } - } -} - -docs! { - "absurd_extreme_comparisons", - "alloc_instead_of_core", - "allow_attributes_without_reason", - "almost_complete_letter_range", - "almost_swapped", - "approx_constant", - "arithmetic_side_effects", - "as_conversions", - "as_ptr_cast_mut", - "as_underscore", - "assertions_on_constants", - "assertions_on_result_states", - "assign_op_pattern", - "async_yields_async", - "await_holding_invalid_type", - "await_holding_lock", - "await_holding_refcell_ref", - "bad_bit_mask", - "bind_instead_of_map", - "blanket_clippy_restriction_lints", - "blocks_in_if_conditions", - "bool_assert_comparison", - "bool_comparison", - "bool_to_int_with_if", - "borrow_as_ptr", - "borrow_deref_ref", - "borrow_interior_mutable_const", - "borrowed_box", - "box_collection", - "box_default", - "boxed_local", - "branches_sharing_code", - "builtin_type_shadow", - "bytes_count_to_len", - "bytes_nth", - "cargo_common_metadata", - "case_sensitive_file_extension_comparisons", - "cast_abs_to_unsigned", - "cast_enum_constructor", - "cast_enum_truncation", - "cast_lossless", - "cast_nan_to_int", - "cast_possible_truncation", - "cast_possible_wrap", - "cast_precision_loss", - "cast_ptr_alignment", - "cast_ref_to_mut", - "cast_sign_loss", - "cast_slice_different_sizes", - "cast_slice_from_raw_parts", - "char_lit_as_u8", - "chars_last_cmp", - "chars_next_cmp", - "checked_conversions", - "clone_double_ref", - "clone_on_copy", - "clone_on_ref_ptr", - "cloned_instead_of_copied", - "cmp_nan", - "cmp_null", - "cmp_owned", - "cognitive_complexity", - "collapsible_else_if", - "collapsible_if", - "collapsible_match", - "collapsible_str_replace", - "comparison_chain", - "comparison_to_empty", - "copy_iterator", - "crate_in_macro_def", - "create_dir", - "crosspointer_transmute", - "dbg_macro", - "debug_assert_with_mut_call", - "decimal_literal_representation", - "declare_interior_mutable_const", - "default_instead_of_iter_empty", - "default_numeric_fallback", - "default_trait_access", - "default_union_representation", - "deprecated_cfg_attr", - "deprecated_semver", - "deref_addrof", - "deref_by_slicing", - "derivable_impls", - "derive_hash_xor_eq", - "derive_ord_xor_partial_ord", - "derive_partial_eq_without_eq", - "disallowed_macros", - "disallowed_methods", - "disallowed_names", - "disallowed_script_idents", - "disallowed_types", - "diverging_sub_expression", - "doc_link_with_quotes", - "doc_markdown", - "double_comparisons", - "double_must_use", - "double_neg", - "double_parens", - "drop_copy", - "drop_non_drop", - "drop_ref", - "duplicate_mod", - "duplicate_underscore_argument", - "duration_subsec", - "else_if_without_else", - "empty_drop", - "empty_enum", - "empty_line_after_outer_attr", - "empty_loop", - "empty_structs_with_brackets", - "enum_clike_unportable_variant", - "enum_glob_use", - "enum_variant_names", - "eq_op", - "equatable_if_let", - "erasing_op", - "err_expect", - "excessive_precision", - "exhaustive_enums", - "exhaustive_structs", - "exit", - "expect_fun_call", - "expect_used", - "expl_impl_clone_on_copy", - "explicit_auto_deref", - "explicit_counter_loop", - "explicit_deref_methods", - "explicit_into_iter_loop", - "explicit_iter_loop", - "explicit_write", - "extend_with_drain", - "extra_unused_lifetimes", - "fallible_impl_from", - "field_reassign_with_default", - "filetype_is_file", - "filter_map_identity", - "filter_map_next", - "filter_next", - "flat_map_identity", - "flat_map_option", - "float_arithmetic", - "float_cmp", - "float_cmp_const", - "float_equality_without_abs", - "fn_address_comparisons", - "fn_params_excessive_bools", - "fn_to_numeric_cast", - "fn_to_numeric_cast_any", - "fn_to_numeric_cast_with_truncation", - "for_kv_map", - "forget_copy", - "forget_non_drop", - "forget_ref", - "format_in_format_args", - "format_push_string", - "from_iter_instead_of_collect", - "from_over_into", - "from_raw_with_void_ptr", - "from_str_radix_10", - "future_not_send", - "get_first", - "get_last_with_len", - "get_unwrap", - "identity_op", - "if_let_mutex", - "if_not_else", - "if_same_then_else", - "if_then_some_else_none", - "ifs_same_cond", - "implicit_clone", - "implicit_hasher", - "implicit_return", - "implicit_saturating_add", - "implicit_saturating_sub", - "imprecise_flops", - "inconsistent_digit_grouping", - "inconsistent_struct_constructor", - "index_refutable_slice", - "indexing_slicing", - "ineffective_bit_mask", - "inefficient_to_string", - "infallible_destructuring_match", - "infinite_iter", - "inherent_to_string", - "inherent_to_string_shadow_display", - "init_numbered_fields", - "inline_always", - "inline_asm_x86_att_syntax", - "inline_asm_x86_intel_syntax", - "inline_fn_without_body", - "inspect_for_each", - "int_plus_one", - "integer_arithmetic", - "integer_division", - "into_iter_on_ref", - "invalid_null_ptr_usage", - "invalid_regex", - "invalid_upcast_comparisons", - "invalid_utf8_in_unchecked", - "invisible_characters", - "is_digit_ascii_radix", - "items_after_statements", - "iter_cloned_collect", - "iter_count", - "iter_kv_map", - "iter_next_loop", - "iter_next_slice", - "iter_not_returning_iterator", - "iter_nth", - "iter_nth_zero", - "iter_on_empty_collections", - "iter_on_single_items", - "iter_overeager_cloned", - "iter_skip_next", - "iter_with_drain", - "iterator_step_by_zero", - "just_underscores_and_digits", - "large_const_arrays", - "large_digit_groups", - "large_enum_variant", - "large_include_file", - "large_stack_arrays", - "large_types_passed_by_value", - "len_without_is_empty", - "len_zero", - "let_and_return", - "let_underscore_lock", - "let_underscore_must_use", - "let_unit_value", - "linkedlist", - "lossy_float_literal", - "macro_use_imports", - "main_recursion", - "manual_assert", - "manual_async_fn", - "manual_bits", - "manual_clamp", - "manual_filter", - "manual_filter_map", - "manual_find", - "manual_find_map", - "manual_flatten", - "manual_instant_elapsed", - "manual_map", - "manual_memcpy", - "manual_non_exhaustive", - "manual_ok_or", - "manual_range_contains", - "manual_rem_euclid", - "manual_retain", - "manual_saturating_arithmetic", - "manual_split_once", - "manual_str_repeat", - "manual_string_new", - "manual_strip", - "manual_swap", - "manual_unwrap_or", - "many_single_char_names", - "map_clone", - "map_collect_result_unit", - "map_entry", - "map_err_ignore", - "map_flatten", - "map_identity", - "map_unwrap_or", - "match_as_ref", - "match_bool", - "match_like_matches_macro", - "match_on_vec_items", - "match_overlapping_arm", - "match_ref_pats", - "match_result_ok", - "match_same_arms", - "match_single_binding", - "match_str_case_mismatch", - "match_wild_err_arm", - "match_wildcard_for_single_variants", - "maybe_infinite_iter", - "mem_forget", - "mem_replace_option_with_none", - "mem_replace_with_default", - "mem_replace_with_uninit", - "min_max", - "mismatched_target_os", - "mismatching_type_param_order", - "misrefactored_assign_op", - "missing_const_for_fn", - "missing_docs_in_private_items", - "missing_enforced_import_renames", - "missing_errors_doc", - "missing_inline_in_public_items", - "missing_panics_doc", - "missing_safety_doc", - "missing_spin_loop", - "missing_trait_methods", - "mistyped_literal_suffixes", - "mixed_case_hex_literals", - "mixed_read_write_in_expression", - "mod_module_files", - "module_inception", - "module_name_repetitions", - "modulo_arithmetic", - "modulo_one", - "multi_assignments", - "multiple_crate_versions", - "multiple_inherent_impl", - "must_use_candidate", - "must_use_unit", - "mut_from_ref", - "mut_mut", - "mut_mutex_lock", - "mut_range_bound", - "mutable_key_type", - "mutex_atomic", - "mutex_integer", - "naive_bytecount", - "needless_arbitrary_self_type", - "needless_bitwise_bool", - "needless_bool", - "needless_borrow", - "needless_borrowed_reference", - "needless_collect", - "needless_continue", - "needless_doctest_main", - "needless_for_each", - "needless_late_init", - "needless_lifetimes", - "needless_match", - "needless_option_as_deref", - "needless_option_take", - "needless_parens_on_range_literals", - "needless_pass_by_value", - "needless_question_mark", - "needless_range_loop", - "needless_return", - "needless_splitn", - "needless_update", - "neg_cmp_op_on_partial_ord", - "neg_multiply", - "negative_feature_names", - "never_loop", - "new_ret_no_self", - "new_without_default", - "no_effect", - "no_effect_replace", - "no_effect_underscore_binding", - "non_ascii_literal", - "non_octal_unix_permissions", - "non_send_fields_in_send_ty", - "nonminimal_bool", - "nonsensical_open_options", - "nonstandard_macro_braces", - "not_unsafe_ptr_arg_deref", - "obfuscated_if_else", - "octal_escapes", - "ok_expect", - "only_used_in_recursion", - "op_ref", - "option_as_ref_deref", - "option_env_unwrap", - "option_filter_map", - "option_if_let_else", - "option_map_or_none", - "option_map_unit_fn", - "option_option", - "or_fun_call", - "or_then_unwrap", - "out_of_bounds_indexing", - "overflow_check_conditional", - "overly_complex_bool_expr", - "panic", - "panic_in_result_fn", - "panicking_unwrap", - "partial_pub_fields", - "partialeq_ne_impl", - "partialeq_to_none", - "path_buf_push_overwrite", - "pattern_type_mismatch", - "possible_missing_comma", - "precedence", - "print_in_format_impl", - "print_literal", - "print_stderr", - "print_stdout", - "print_with_newline", - "println_empty_string", - "ptr_arg", - "ptr_as_ptr", - "ptr_eq", - "ptr_offset_with_cast", - "pub_use", - "question_mark", - "range_minus_one", - "range_plus_one", - "range_zip_with_len", - "rc_buffer", - "rc_clone_in_vec_init", - "rc_mutex", - "read_zero_byte_vec", - "recursive_format_impl", - "redundant_allocation", - "redundant_clone", - "redundant_closure", - "redundant_closure_call", - "redundant_closure_for_method_calls", - "redundant_else", - "redundant_feature_names", - "redundant_field_names", - "redundant_pattern", - "redundant_pattern_matching", - "redundant_pub_crate", - "redundant_slicing", - "redundant_static_lifetimes", - "ref_binding_to_reference", - "ref_option_ref", - "repeat_once", - "rest_pat_in_fully_bound_structs", - "result_large_err", - "result_map_or_into_option", - "result_map_unit_fn", - "result_unit_err", - "return_self_not_must_use", - "reversed_empty_ranges", - "same_functions_in_if_condition", - "same_item_push", - "same_name_method", - "search_is_some", - "self_assignment", - "self_named_constructors", - "self_named_module_files", - "semicolon_if_nothing_returned", - "separated_literal_suffix", - "serde_api_misuse", - "shadow_reuse", - "shadow_same", - "shadow_unrelated", - "short_circuit_statement", - "should_implement_trait", - "significant_drop_in_scrutinee", - "similar_names", - "single_char_add_str", - "single_char_lifetime_names", - "single_char_pattern", - "single_component_path_imports", - "single_element_loop", - "single_match", - "single_match_else", - "size_of_in_element_count", - "skip_while_next", - "slow_vector_initialization", - "stable_sort_primitive", - "std_instead_of_alloc", - "std_instead_of_core", - "str_to_string", - "string_add", - "string_add_assign", - "string_extend_chars", - "string_from_utf8_as_bytes", - "string_lit_as_bytes", - "string_slice", - "string_to_string", - "strlen_on_c_strings", - "struct_excessive_bools", - "suboptimal_flops", - "suspicious_arithmetic_impl", - "suspicious_assignment_formatting", - "suspicious_else_formatting", - "suspicious_map", - "suspicious_op_assign_impl", - "suspicious_operation_groupings", - "suspicious_splitn", - "suspicious_to_owned", - "suspicious_unary_op_formatting", - "swap_ptr_to_ref", - "tabs_in_doc_comments", - "temporary_assignment", - "to_digit_is_some", - "to_string_in_format_args", - "todo", - "too_many_arguments", - "too_many_lines", - "toplevel_ref_arg", - "trailing_empty_array", - "trait_duplication_in_bounds", - "transmute_bytes_to_str", - "transmute_float_to_int", - "transmute_int_to_bool", - "transmute_int_to_char", - "transmute_int_to_float", - "transmute_num_to_bytes", - "transmute_ptr_to_ptr", - "transmute_ptr_to_ref", - "transmute_undefined_repr", - "transmutes_expressible_as_ptr_casts", - "transmuting_null", - "trim_split_whitespace", - "trivial_regex", - "trivially_copy_pass_by_ref", - "try_err", - "type_complexity", - "type_repetition_in_bounds", - "undocumented_unsafe_blocks", - "undropped_manually_drops", - "unicode_not_nfc", - "unimplemented", - "uninit_assumed_init", - "uninit_vec", - "uninlined_format_args", - "unit_arg", - "unit_cmp", - "unit_hash", - "unit_return_expecting_ord", - "unnecessary_cast", - "unnecessary_filter_map", - "unnecessary_find_map", - "unnecessary_fold", - "unnecessary_join", - "unnecessary_lazy_evaluations", - "unnecessary_mut_passed", - "unnecessary_operation", - "unnecessary_owned_empty_strings", - "unnecessary_self_imports", - "unnecessary_sort_by", - "unnecessary_to_owned", - "unnecessary_unwrap", - "unnecessary_wraps", - "unneeded_field_pattern", - "unneeded_wildcard_pattern", - "unnested_or_patterns", - "unreachable", - "unreadable_literal", - "unsafe_derive_deserialize", - "unsafe_removed_from_name", - "unseparated_literal_suffix", - "unsound_collection_transmute", - "unused_async", - "unused_format_specs", - "unused_io_amount", - "unused_peekable", - "unused_rounding", - "unused_self", - "unused_unit", - "unusual_byte_groupings", - "unwrap_in_result", - "unwrap_or_else_default", - "unwrap_used", - "upper_case_acronyms", - "use_debug", - "use_self", - "used_underscore_binding", - "useless_asref", - "useless_attribute", - "useless_conversion", - "useless_format", - "useless_let_if_seq", - "useless_transmute", - "useless_vec", - "vec_box", - "vec_init_then_push", - "vec_resize_to_zero", - "verbose_bit_mask", - "verbose_file_reads", - "vtable_address_comparisons", - "while_immutable_condition", - "while_let_loop", - "while_let_on_iterator", - "wildcard_dependencies", - "wildcard_enum_match_arm", - "wildcard_imports", - "wildcard_in_or_patterns", - "write_literal", - "write_with_newline", - "writeln_empty_string", - "wrong_self_convention", - "wrong_transmute", - "zero_divided_by_zero", - "zero_prefixed_literal", - "zero_ptr", - "zero_sized_map_values", - "zst_offset", - -} diff --git a/src/main.rs b/src/main.rs index fce3cdfc462..d418d2daa31 100644 --- a/src/main.rs +++ b/src/main.rs @@ -7,8 +7,6 @@ use std::env; use std::path::PathBuf; use std::process::{self, Command}; -mod docs; - const CARGO_CLIPPY_HELP: &str = r#"Checks a package to catch common mistakes and improve your Rust code. Usage: @@ -60,7 +58,7 @@ pub fn main() { if let Some(pos) = env::args().position(|a| a == "--explain") { if let Some(mut lint) = env::args().nth(pos + 1) { lint.make_ascii_lowercase(); - docs::explain(&lint.strip_prefix("clippy::").unwrap_or(&lint).replace('-', "_")); + clippy_lints::explain(&lint.strip_prefix("clippy::").unwrap_or(&lint).replace('-', "_")); } else { show_help(); } diff --git a/tests/versioncheck.rs b/tests/versioncheck.rs index a6d8d0307ce..7a85386a3df 100644 --- a/tests/versioncheck.rs +++ b/tests/versioncheck.rs @@ -6,7 +6,7 @@ use rustc_tools_util::VersionInfo; use std::fs; #[test] -fn check_that_clippy_lints_and_clippy_utils_have_the_same_version_as_clippy() { +fn consistent_clippy_crate_versions() { fn read_version(path: &str) -> String { let contents = fs::read_to_string(path).unwrap_or_else(|e| panic!("error reading `{path}`: {e:?}")); contents @@ -24,11 +24,16 @@ fn check_that_clippy_lints_and_clippy_utils_have_the_same_version_as_clippy() { } let clippy_version = read_version("Cargo.toml"); - let clippy_lints_version = read_version("clippy_lints/Cargo.toml"); - let clippy_utils_version = read_version("clippy_utils/Cargo.toml"); - assert_eq!(clippy_version, clippy_lints_version); - assert_eq!(clippy_version, clippy_utils_version); + let paths = [ + "declare_clippy_lint/Cargo.toml", + "clippy_lints/Cargo.toml", + "clippy_utils/Cargo.toml", + ]; + + for path in paths { + assert_eq!(clippy_version, read_version(path), "{path} version differs"); + } } #[test] -- cgit 1.4.1-3-g733a5 From bd8369089c38c190533b41ce76b073f5478f17d4 Mon Sep 17 00:00:00 2001 From: Alex Macleod Date: Tue, 25 Oct 2022 11:32:49 +0000 Subject: Track `clippy.toml` and `Cargo.toml` in `file_depinfo` Causes cargo to re-run clippy when those paths are modified Also tracks the path to `clippy-driver` in debug mode to remove the workarounds in `cargo dev lint` and `lintcheck` --- clippy_dev/Cargo.toml | 1 - clippy_dev/src/lint.rs | 8 -------- clippy_lints/src/lib.rs | 11 +++++++---- clippy_lints/src/utils/conf.rs | 4 ++++ lintcheck/src/main.rs | 45 ------------------------------------------ src/driver.rs | 37 +++++++++++++++++++++++++++++++++- 6 files changed, 47 insertions(+), 59 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/Cargo.toml b/clippy_dev/Cargo.toml index 2ac3b4fe2ed..510c7e852af 100644 --- a/clippy_dev/Cargo.toml +++ b/clippy_dev/Cargo.toml @@ -10,7 +10,6 @@ indoc = "1.0" itertools = "0.10.1" opener = "0.5" shell-escape = "0.1" -tempfile = "3.2" walkdir = "2.3" [features] diff --git a/clippy_dev/src/lint.rs b/clippy_dev/src/lint.rs index 71005449b4d..aafd0f71a59 100644 --- a/clippy_dev/src/lint.rs +++ b/clippy_dev/src/lint.rs @@ -36,20 +36,12 @@ pub fn run<'a>(path: &str, args: impl Iterator) { } else { exit_if_err(Command::new("cargo").arg("build").status()); - // Run in a tempdir as changes to clippy do not retrigger linting - let target = tempfile::Builder::new() - .prefix("clippy") - .tempdir() - .expect("failed to create tempdir"); - let status = Command::new(cargo_clippy_path()) .arg("clippy") .args(args) .current_dir(path) - .env("CARGO_TARGET_DIR", target.as_ref()) .status(); - target.close().expect("failed to remove tempdir"); exit_if_err(status); } } diff --git a/clippy_lints/src/lib.rs b/clippy_lints/src/lib.rs index 7837e04bca1..85a28d1fd9e 100644 --- a/clippy_lints/src/lib.rs +++ b/clippy_lints/src/lib.rs @@ -49,6 +49,9 @@ extern crate clippy_utils; #[macro_use] extern crate declare_clippy_lint; +use std::io; +use std::path::PathBuf; + use clippy_utils::parse_msrv; use rustc_data_structures::fx::FxHashSet; use rustc_lint::{Lint, LintId}; @@ -303,8 +306,8 @@ mod zero_div_zero; mod zero_sized_map_values; // end lints modules, do not remove this comment, it’s used in `update_lints` -pub use crate::utils::conf::Conf; use crate::utils::conf::{format_error, TryConf}; +pub use crate::utils::conf::{lookup_conf_file, Conf}; /// Register all pre expansion lints /// @@ -361,8 +364,8 @@ fn read_msrv(conf: &Conf, sess: &Session) -> Option { } #[doc(hidden)] -pub fn read_conf(sess: &Session) -> Conf { - let file_name = match utils::conf::lookup_conf_file() { +pub fn read_conf(sess: &Session, path: &io::Result>) -> Conf { + let file_name = match path { Ok(Some(path)) => path, Ok(None) => return Conf::default(), Err(error) => { @@ -372,7 +375,7 @@ pub fn read_conf(sess: &Session) -> Conf { }, }; - let TryConf { conf, errors, warnings } = utils::conf::read(&file_name); + let TryConf { conf, errors, warnings } = utils::conf::read(file_name); // all conf errors are non-fatal, we just use the default conf in case of error for error in errors { sess.err(format!( diff --git a/clippy_lints/src/utils/conf.rs b/clippy_lints/src/utils/conf.rs index a10de31556c..65788f51a26 100644 --- a/clippy_lints/src/utils/conf.rs +++ b/clippy_lints/src/utils/conf.rs @@ -390,6 +390,10 @@ define_Conf! { } /// Search for the configuration file. +/// +/// # Errors +/// +/// Returns any unexpected filesystem error encountered when searching for the config file pub fn lookup_conf_file() -> io::Result> { /// Possible filename to search for. const CONFIG_FILE_NAMES: [&str; 2] = [".clippy.toml", "clippy.toml"]; diff --git a/lintcheck/src/main.rs b/lintcheck/src/main.rs index 8385a4744ca..ee8ab7c1d7c 100644 --- a/lintcheck/src/main.rs +++ b/lintcheck/src/main.rs @@ -544,34 +544,6 @@ fn gather_stats(clippy_warnings: &[ClippyWarning]) -> (String, HashMap<&String, (stats_string, counter) } -/// check if the latest modification of the logfile is older than the modification date of the -/// clippy binary, if this is true, we should clean the lintchec shared target directory and recheck -fn lintcheck_needs_rerun(lintcheck_logs_path: &Path, paths: [&Path; 2]) -> bool { - if !lintcheck_logs_path.exists() { - return true; - } - - let clippy_modified: std::time::SystemTime = { - let [cargo, driver] = paths.map(|p| { - std::fs::metadata(p) - .expect("failed to get metadata of file") - .modified() - .expect("failed to get modification date") - }); - // the oldest modification of either of the binaries - std::cmp::max(cargo, driver) - }; - - let logs_modified: std::time::SystemTime = std::fs::metadata(lintcheck_logs_path) - .expect("failed to get metadata of file") - .modified() - .expect("failed to get modification date"); - - // time is represented in seconds since X - // logs_modified 2 and clippy_modified 5 means clippy binary is older and we need to recheck - logs_modified < clippy_modified -} - #[allow(clippy::too_many_lines)] fn main() { // We're being executed as a `RUSTC_WRAPPER` as part of `--recursive` @@ -594,23 +566,6 @@ fn main() { let cargo_clippy_path = fs::canonicalize(format!("target/debug/cargo-clippy{EXE_SUFFIX}")).unwrap(); let clippy_driver_path = fs::canonicalize(format!("target/debug/clippy-driver{EXE_SUFFIX}")).unwrap(); - // if the clippy bin is newer than our logs, throw away target dirs to force clippy to - // refresh the logs - if lintcheck_needs_rerun( - &config.lintcheck_results_path, - [&cargo_clippy_path, &clippy_driver_path], - ) { - let shared_target_dir = "target/lintcheck/shared_target_dir"; - // if we get an Err here, the shared target dir probably does simply not exist - if let Ok(metadata) = std::fs::metadata(shared_target_dir) { - if metadata.is_dir() { - println!("Clippy is newer than lint check logs, clearing lintcheck shared target dir..."); - std::fs::remove_dir_all(shared_target_dir) - .expect("failed to remove target/lintcheck/shared_target_dir"); - } - } - } - // assert that clippy is found assert!( cargo_clippy_path.is_file(), diff --git a/src/driver.rs b/src/driver.rs index b12208ac62a..2601cab8c85 100644 --- a/src/driver.rs +++ b/src/driver.rs @@ -1,4 +1,5 @@ #![feature(rustc_private)] +#![feature(let_chains)] #![feature(once_cell)] #![cfg_attr(feature = "deny-warnings", deny(warnings))] // warn on lints, that are included in `rust-lang/rust`s bootstrap @@ -71,6 +72,32 @@ fn track_clippy_args(parse_sess: &mut ParseSess, args_env_var: &Option) )); } +/// Track files that may be accessed at runtime in `file_depinfo` so that cargo will re-run clippy +/// when any of them are modified +fn track_files(parse_sess: &mut ParseSess, conf_path_string: Option) { + let file_depinfo = parse_sess.file_depinfo.get_mut(); + + // Used by `clippy::cargo` lints and to determine the MSRV. `cargo clippy` executes `clippy-driver` + // with the current directory set to `CARGO_MANIFEST_DIR` so a relative path is fine + if Path::new("Cargo.toml").exists() { + file_depinfo.insert(Symbol::intern("Cargo.toml")); + } + + // `clippy.toml` + if let Some(path) = conf_path_string { + file_depinfo.insert(Symbol::intern(&path)); + } + + // During development track the `clippy-driver` executable so that cargo will re-run clippy whenever + // it is rebuilt + if cfg!(debug_assertions) + && let Ok(current_exe) = env::current_exe() + && let Some(current_exe) = current_exe.to_str() + { + file_depinfo.insert(Symbol::intern(current_exe)); + } +} + struct DefaultCallbacks; impl rustc_driver::Callbacks for DefaultCallbacks {} @@ -97,10 +124,18 @@ impl rustc_driver::Callbacks for ClippyCallbacks { // JUSTIFICATION: necessary in clippy driver to set `mir_opt_level` #[allow(rustc::bad_opt_access)] fn config(&mut self, config: &mut interface::Config) { + let conf_path = clippy_lints::lookup_conf_file(); + let conf_path_string = if let Ok(Some(path)) = &conf_path { + path.to_str().map(String::from) + } else { + None + }; + let previous = config.register_lints.take(); let clippy_args_var = self.clippy_args_var.take(); config.parse_sess_created = Some(Box::new(move |parse_sess| { track_clippy_args(parse_sess, &clippy_args_var); + track_files(parse_sess, conf_path_string); })); config.register_lints = Some(Box::new(move |sess, lint_store| { // technically we're ~guaranteed that this is none but might as well call anything that @@ -109,7 +144,7 @@ impl rustc_driver::Callbacks for ClippyCallbacks { (previous)(sess, lint_store); } - let conf = clippy_lints::read_conf(sess); + let conf = clippy_lints::read_conf(sess, &conf_path); clippy_lints::register_plugins(lint_store, sess, &conf); clippy_lints::register_pre_expansion_lints(lint_store, sess, &conf); clippy_lints::register_renamed(lint_store); -- cgit 1.4.1-3-g733a5 From 22d435b26627c1085c5b761846ca08870288794f Mon Sep 17 00:00:00 2001 From: Alex Macleod Date: Tue, 25 Oct 2022 13:18:50 +0000 Subject: Remove `lib.register_*` and `src/docs*` in `cargo dev update_lints` --- clippy_dev/src/update_lints.rs | 54 ++++++++++++++++++++++++++++++++++++++++++ 1 file changed, 54 insertions(+) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/update_lints.rs b/clippy_dev/src/update_lints.rs index 3cdbb42d44d..837618c9294 100644 --- a/clippy_dev/src/update_lints.rs +++ b/clippy_dev/src/update_lints.rs @@ -36,6 +36,60 @@ pub enum UpdateMode { pub fn update(update_mode: UpdateMode) { let (lints, deprecated_lints, renamed_lints) = gather_all(); generate_lint_files(update_mode, &lints, &deprecated_lints, &renamed_lints); + remove_old_files(update_mode); +} + +/// Remove files no longer needed after +/// that may be reintroduced unintentionally +/// +/// FIXME: This is a temporary measure that should be removed when there are no more PRs that +/// include the stray files +fn remove_old_files(update_mode: UpdateMode) { + let mut failed = false; + let mut remove_file = |path: &Path| match update_mode { + UpdateMode::Check => { + if path.exists() { + failed = true; + println!("unexpected file: {}", path.display()); + } + }, + UpdateMode::Change => { + if fs::remove_file(path).is_ok() { + println!("removed file: {}", path.display()); + } + }, + }; + + let files = [ + "clippy_lints/src/lib.register_all.rs", + "clippy_lints/src/lib.register_cargo.rs", + "clippy_lints/src/lib.register_complexity.rs", + "clippy_lints/src/lib.register_correctness.rs", + "clippy_lints/src/lib.register_internal.rs", + "clippy_lints/src/lib.register_lints.rs", + "clippy_lints/src/lib.register_nursery.rs", + "clippy_lints/src/lib.register_pedantic.rs", + "clippy_lints/src/lib.register_perf.rs", + "clippy_lints/src/lib.register_restriction.rs", + "clippy_lints/src/lib.register_style.rs", + "clippy_lints/src/lib.register_suspicious.rs", + "src/docs.rs", + ]; + + for file in files { + remove_file(Path::new(file)); + } + + if let Ok(docs_dir) = fs::read_dir("src/docs") { + for doc_file in docs_dir { + let path = doc_file.unwrap().path(); + remove_file(&path); + } + } + + if failed { + exit_with_failure(); + } } fn generate_lint_files( -- cgit 1.4.1-3-g733a5 From 637139d2ff4202f9296777f8f4750bcc233b09f8 Mon Sep 17 00:00:00 2001 From: Alex Macleod Date: Mon, 21 Nov 2022 14:37:51 +0000 Subject: Add `clippy_utils::msrv::Msrv` to keep track of the current MSRV --- book/src/development/adding_lints.md | 8 +- clippy_dev/src/new_lint.rs | 16 ++- clippy_lints/src/almost_complete_letter_range.rs | 11 +-- clippy_lints/src/approx_const.rs | 8 +- clippy_lints/src/attrs.rs | 12 +-- clippy_lints/src/casts/cast_abs_to_unsigned.rs | 7 +- clippy_lints/src/casts/cast_lossless.rs | 16 +-- .../src/casts/cast_slice_different_sizes.rs | 8 +- .../src/casts/cast_slice_from_raw_parts.rs | 14 +-- clippy_lints/src/casts/mod.rs | 22 ++--- clippy_lints/src/casts/ptr_as_ptr.rs | 7 +- clippy_lints/src/checked_conversions.rs | 10 +- clippy_lints/src/dereference.rs | 18 ++-- clippy_lints/src/format_args.rs | 10 +- clippy_lints/src/from_over_into.rs | 10 +- clippy_lints/src/if_then_some_else_none.rs | 14 ++- clippy_lints/src/index_refutable_slice.rs | 11 +-- clippy_lints/src/instant_subtraction.rs | 18 ++-- clippy_lints/src/lib.rs | 108 +++++++-------------- clippy_lints/src/manual_bits.rs | 10 +- clippy_lints/src/manual_clamp.rs | 33 +++---- clippy_lints/src/manual_is_ascii_check.rs | 15 ++- clippy_lints/src/manual_let_else.rs | 10 +- clippy_lints/src/manual_non_exhaustive.rs | 16 +-- clippy_lints/src/manual_rem_euclid.rs | 12 +-- clippy_lints/src/manual_retain.rs | 24 ++--- clippy_lints/src/manual_strip.rs | 10 +- clippy_lints/src/matches/mod.rs | 14 ++- clippy_lints/src/mem_replace.rs | 10 +- .../src/methods/cloned_instead_of_copied.rs | 10 +- clippy_lints/src/methods/err_expect.rs | 8 +- clippy_lints/src/methods/filter_map_next.rs | 8 +- clippy_lints/src/methods/is_digit_ascii_radix.rs | 9 +- clippy_lints/src/methods/map_clone.rs | 16 +-- clippy_lints/src/methods/map_unwrap_or.rs | 7 +- clippy_lints/src/methods/mod.rs | 36 +++---- clippy_lints/src/methods/option_as_ref_deref.rs | 8 +- clippy_lints/src/methods/str_splitn.rs | 8 +- clippy_lints/src/methods/unnecessary_to_owned.rs | 9 +- clippy_lints/src/missing_const_for_fn.rs | 14 ++- clippy_lints/src/ranges.rs | 10 +- clippy_lints/src/redundant_field_names.rs | 9 +- clippy_lints/src/redundant_static_lifetimes.rs | 9 +- clippy_lints/src/transmute/mod.rs | 8 +- clippy_lints/src/transmute/transmute_ptr_to_ref.rs | 10 +- clippy_lints/src/unnested_or_patterns.rs | 17 ++-- clippy_lints/src/use_self.rs | 14 +-- .../src/utils/internal_lints/msrv_attr_impl.rs | 2 +- clippy_utils/src/lib.rs | 33 ++----- clippy_utils/src/msrvs.rs | 101 +++++++++++++++++++ clippy_utils/src/paths.rs | 4 +- clippy_utils/src/qualify_min_const_fn.rs | 18 ++-- tests/ui-internal/invalid_msrv_attr_impl.fixed | 4 +- tests/ui-internal/invalid_msrv_attr_impl.rs | 4 +- tests/ui/min_rust_version_attr.rs | 23 +++++ tests/ui/min_rust_version_attr.stderr | 18 +++- 56 files changed, 466 insertions(+), 433 deletions(-) (limited to 'clippy_dev/src') diff --git a/book/src/development/adding_lints.md b/book/src/development/adding_lints.md index 3c3f368a529..29d0d45dcc9 100644 --- a/book/src/development/adding_lints.md +++ b/book/src/development/adding_lints.md @@ -443,22 +443,22 @@ value is passed to the constructor in `clippy_lints/lib.rs`. ```rust pub struct ManualStrip { - msrv: Option, + msrv: Msrv, } impl ManualStrip { #[must_use] - pub fn new(msrv: Option) -> Self { + pub fn new(msrv: Msrv) -> Self { Self { msrv } } } ``` The project's MSRV can then be matched against the feature MSRV in the LintPass -using the `meets_msrv` utility function. +using the `Msrv::meets` method. ``` rust -if !meets_msrv(self.msrv, msrvs::STR_STRIP_PREFIX) { +if !self.msrv.meets(msrvs::STR_STRIP_PREFIX) { return; } ``` diff --git a/clippy_dev/src/new_lint.rs b/clippy_dev/src/new_lint.rs index 9e15f1504fa..ec7f1dd0d84 100644 --- a/clippy_dev/src/new_lint.rs +++ b/clippy_dev/src/new_lint.rs @@ -120,7 +120,7 @@ fn add_lint(lint: &LintData<'_>, enable_msrv: bool) -> io::Result<()> { let new_lint = if enable_msrv { format!( - "store.register_{lint_pass}_pass(move |{ctor_arg}| Box::new({module_name}::{camel_name}::new(msrv)));\n ", + "store.register_{lint_pass}_pass(move |{ctor_arg}| Box::new({module_name}::{camel_name}::new(msrv())));\n ", lint_pass = lint.pass, ctor_arg = if lint.pass == "late" { "_" } else { "" }, module_name = lint.name, @@ -238,10 +238,9 @@ fn get_lint_file_contents(lint: &LintData<'_>, enable_msrv: bool) -> String { result.push_str(&if enable_msrv { formatdoc!( r#" - use clippy_utils::msrvs; + use clippy_utils::msrvs::{{self, Msrv}}; {pass_import} use rustc_lint::{{{context_import}, {pass_type}, LintContext}}; - use rustc_semver::RustcVersion; use rustc_session::{{declare_tool_lint, impl_lint_pass}}; "# @@ -263,12 +262,12 @@ fn get_lint_file_contents(lint: &LintData<'_>, enable_msrv: bool) -> String { formatdoc!( r#" pub struct {name_camel} {{ - msrv: Option, + msrv: Msrv, }} impl {name_camel} {{ #[must_use] - pub fn new(msrv: Option) -> Self {{ + pub fn new(msrv: Msrv) -> Self {{ Self {{ msrv }} }} }} @@ -357,15 +356,14 @@ fn create_lint_for_ty(lint: &LintData<'_>, enable_msrv: bool, ty: &str) -> io::R let _ = writedoc!( lint_file_contents, r#" - use clippy_utils::{{meets_msrv, msrvs}}; + use clippy_utils::msrvs::{{self, Msrv}}; use rustc_lint::{{{context_import}, LintContext}}; - use rustc_semver::RustcVersion; use super::{name_upper}; // TODO: Adjust the parameters as necessary - pub(super) fn check(cx: &{context_import}, msrv: Option) {{ - if !meets_msrv(msrv, todo!("Add a new entry in `clippy_utils/src/msrvs`")) {{ + pub(super) fn check(cx: &{context_import}, msrv: &Msrv) {{ + if !msrv.meets(todo!("Add a new entry in `clippy_utils/src/msrvs`")) {{ return; }} todo!(); diff --git a/clippy_lints/src/almost_complete_letter_range.rs b/clippy_lints/src/almost_complete_letter_range.rs index 073e4af1318..3cf8ba0a521 100644 --- a/clippy_lints/src/almost_complete_letter_range.rs +++ b/clippy_lints/src/almost_complete_letter_range.rs @@ -1,11 +1,10 @@ use clippy_utils::diagnostics::span_lint_and_then; +use clippy_utils::msrvs::{self, Msrv}; use clippy_utils::source::{trim_span, walk_span_to_context}; -use clippy_utils::{meets_msrv, msrvs}; use rustc_ast::ast::{Expr, ExprKind, LitKind, Pat, PatKind, RangeEnd, RangeLimits}; use rustc_errors::Applicability; use rustc_lint::{EarlyContext, EarlyLintPass, LintContext}; use rustc_middle::lint::in_external_macro; -use rustc_semver::RustcVersion; use rustc_session::{declare_tool_lint, impl_lint_pass}; use rustc_span::Span; @@ -33,10 +32,10 @@ declare_clippy_lint! { impl_lint_pass!(AlmostCompleteLetterRange => [ALMOST_COMPLETE_LETTER_RANGE]); pub struct AlmostCompleteLetterRange { - msrv: Option, + msrv: Msrv, } impl AlmostCompleteLetterRange { - pub fn new(msrv: Option) -> Self { + pub fn new(msrv: Msrv) -> Self { Self { msrv } } } @@ -46,7 +45,7 @@ impl EarlyLintPass for AlmostCompleteLetterRange { let ctxt = e.span.ctxt(); let sugg = if let Some(start) = walk_span_to_context(start.span, ctxt) && let Some(end) = walk_span_to_context(end.span, ctxt) - && meets_msrv(self.msrv, msrvs::RANGE_INCLUSIVE) + && self.msrv.meets(msrvs::RANGE_INCLUSIVE) { Some((trim_span(cx.sess().source_map(), start.between(end)), "..=")) } else { @@ -60,7 +59,7 @@ impl EarlyLintPass for AlmostCompleteLetterRange { if let PatKind::Range(Some(start), Some(end), kind) = &p.kind && matches!(kind.node, RangeEnd::Excluded) { - let sugg = if meets_msrv(self.msrv, msrvs::RANGE_INCLUSIVE) { + let sugg = if self.msrv.meets(msrvs::RANGE_INCLUSIVE) { "..=" } else { "..." diff --git a/clippy_lints/src/approx_const.rs b/clippy_lints/src/approx_const.rs index 724490fb495..ccf82f132f4 100644 --- a/clippy_lints/src/approx_const.rs +++ b/clippy_lints/src/approx_const.rs @@ -1,5 +1,5 @@ use clippy_utils::diagnostics::span_lint_and_help; -use clippy_utils::{meets_msrv, msrvs}; +use clippy_utils::msrvs::{self, Msrv}; use rustc_ast::ast::{FloatTy, LitFloatType, LitKind}; use rustc_hir::{Expr, ExprKind}; use rustc_lint::{LateContext, LateLintPass}; @@ -63,12 +63,12 @@ const KNOWN_CONSTS: [(f64, &str, usize, Option); 19] = [ ]; pub struct ApproxConstant { - msrv: Option, + msrv: Msrv, } impl ApproxConstant { #[must_use] - pub fn new(msrv: Option) -> Self { + pub fn new(msrv: Msrv) -> Self { Self { msrv } } @@ -87,7 +87,7 @@ impl ApproxConstant { let s = s.as_str(); if s.parse::().is_ok() { for &(constant, name, min_digits, msrv) in &KNOWN_CONSTS { - if is_approx_const(constant, s, min_digits) && msrv.map_or(true, |msrv| meets_msrv(self.msrv, msrv)) { + if is_approx_const(constant, s, min_digits) && msrv.map_or(true, |msrv| self.msrv.meets(msrv)) { span_lint_and_help( cx, APPROX_CONSTANT, diff --git a/clippy_lints/src/attrs.rs b/clippy_lints/src/attrs.rs index ecf8e83375d..54364f9dab2 100644 --- a/clippy_lints/src/attrs.rs +++ b/clippy_lints/src/attrs.rs @@ -2,9 +2,8 @@ use clippy_utils::diagnostics::{span_lint, span_lint_and_help, span_lint_and_sugg, span_lint_and_then}; use clippy_utils::macros::{is_panic, macro_backtrace}; -use clippy_utils::msrvs; +use clippy_utils::msrvs::{self, Msrv}; use clippy_utils::source::{first_line_of_span, is_present_in_source, snippet_opt, without_block_comments}; -use clippy_utils::{extract_msrv_attr, meets_msrv}; use if_chain::if_chain; use rustc_ast::{AttrKind, AttrStyle, Attribute, Lit, LitKind, MetaItemKind, NestedMetaItem}; use rustc_errors::Applicability; @@ -14,7 +13,6 @@ use rustc_hir::{ use rustc_lint::{EarlyContext, EarlyLintPass, LateContext, LateLintPass, Level, LintContext}; use rustc_middle::lint::in_external_macro; use rustc_middle::ty; -use rustc_semver::RustcVersion; use rustc_session::{declare_lint_pass, declare_tool_lint, impl_lint_pass}; use rustc_span::source_map::Span; use rustc_span::symbol::Symbol; @@ -599,7 +597,7 @@ fn is_word(nmi: &NestedMetaItem, expected: Symbol) -> bool { } pub struct EarlyAttributes { - pub msrv: Option, + pub msrv: Msrv, } impl_lint_pass!(EarlyAttributes => [ @@ -614,7 +612,7 @@ impl EarlyLintPass for EarlyAttributes { } fn check_attribute(&mut self, cx: &EarlyContext<'_>, attr: &Attribute) { - check_deprecated_cfg_attr(cx, attr, self.msrv); + check_deprecated_cfg_attr(cx, attr, &self.msrv); check_mismatched_target_os(cx, attr); } @@ -654,9 +652,9 @@ fn check_empty_line_after_outer_attr(cx: &EarlyContext<'_>, item: &rustc_ast::It } } -fn check_deprecated_cfg_attr(cx: &EarlyContext<'_>, attr: &Attribute, msrv: Option) { +fn check_deprecated_cfg_attr(cx: &EarlyContext<'_>, attr: &Attribute, msrv: &Msrv) { if_chain! { - if meets_msrv(msrv, msrvs::TOOL_ATTRIBUTES); + if msrv.meets(msrvs::TOOL_ATTRIBUTES); // check cfg_attr if attr.has_name(sym::cfg_attr); if let Some(items) = attr.meta_item_list(); diff --git a/clippy_lints/src/casts/cast_abs_to_unsigned.rs b/clippy_lints/src/casts/cast_abs_to_unsigned.rs index 3f1edabe6c5..44226298333 100644 --- a/clippy_lints/src/casts/cast_abs_to_unsigned.rs +++ b/clippy_lints/src/casts/cast_abs_to_unsigned.rs @@ -1,11 +1,10 @@ use clippy_utils::diagnostics::span_lint_and_sugg; +use clippy_utils::msrvs::{self, Msrv}; use clippy_utils::sugg::Sugg; -use clippy_utils::{meets_msrv, msrvs}; use rustc_errors::Applicability; use rustc_hir::{Expr, ExprKind}; use rustc_lint::LateContext; use rustc_middle::ty::{self, Ty}; -use rustc_semver::RustcVersion; use super::CAST_ABS_TO_UNSIGNED; @@ -15,9 +14,9 @@ pub(super) fn check( cast_expr: &Expr<'_>, cast_from: Ty<'_>, cast_to: Ty<'_>, - msrv: Option, + msrv: &Msrv, ) { - if meets_msrv(msrv, msrvs::UNSIGNED_ABS) + if msrv.meets(msrvs::UNSIGNED_ABS) && let ty::Int(from) = cast_from.kind() && let ty::Uint(to) = cast_to.kind() && let ExprKind::MethodCall(method_path, receiver, ..) = cast_expr.kind diff --git a/clippy_lints/src/casts/cast_lossless.rs b/clippy_lints/src/casts/cast_lossless.rs index 13c403234da..cf07e050ccc 100644 --- a/clippy_lints/src/casts/cast_lossless.rs +++ b/clippy_lints/src/casts/cast_lossless.rs @@ -1,12 +1,12 @@ use clippy_utils::diagnostics::span_lint_and_sugg; +use clippy_utils::in_constant; +use clippy_utils::msrvs::{self, Msrv}; use clippy_utils::source::snippet_opt; use clippy_utils::ty::is_isize_or_usize; -use clippy_utils::{in_constant, meets_msrv, msrvs}; use rustc_errors::Applicability; use rustc_hir::{Expr, ExprKind}; use rustc_lint::LateContext; use rustc_middle::ty::{self, FloatTy, Ty}; -use rustc_semver::RustcVersion; use super::{utils, CAST_LOSSLESS}; @@ -16,7 +16,7 @@ pub(super) fn check( cast_op: &Expr<'_>, cast_from: Ty<'_>, cast_to: Ty<'_>, - msrv: Option, + msrv: &Msrv, ) { if !should_lint(cx, expr, cast_from, cast_to, msrv) { return; @@ -57,13 +57,7 @@ pub(super) fn check( ); } -fn should_lint( - cx: &LateContext<'_>, - expr: &Expr<'_>, - cast_from: Ty<'_>, - cast_to: Ty<'_>, - msrv: Option, -) -> bool { +fn should_lint(cx: &LateContext<'_>, expr: &Expr<'_>, cast_from: Ty<'_>, cast_to: Ty<'_>, msrv: &Msrv) -> bool { // Do not suggest using From in consts/statics until it is valid to do so (see #2267). if in_constant(cx, expr.hir_id) { return false; @@ -89,7 +83,7 @@ fn should_lint( }; !is_isize_or_usize(cast_from) && from_nbits < to_nbits }, - (false, true) if matches!(cast_from.kind(), ty::Bool) && meets_msrv(msrv, msrvs::FROM_BOOL) => true, + (false, true) if matches!(cast_from.kind(), ty::Bool) && msrv.meets(msrvs::FROM_BOOL) => true, (_, _) => { matches!(cast_from.kind(), ty::Float(FloatTy::F32)) && matches!(cast_to.kind(), ty::Float(FloatTy::F64)) }, diff --git a/clippy_lints/src/casts/cast_slice_different_sizes.rs b/clippy_lints/src/casts/cast_slice_different_sizes.rs index d31d10d22b9..e862f13e69f 100644 --- a/clippy_lints/src/casts/cast_slice_different_sizes.rs +++ b/clippy_lints/src/casts/cast_slice_different_sizes.rs @@ -1,16 +1,16 @@ -use clippy_utils::{diagnostics::span_lint_and_then, meets_msrv, msrvs, source}; +use clippy_utils::msrvs::{self, Msrv}; +use clippy_utils::{diagnostics::span_lint_and_then, source}; use if_chain::if_chain; use rustc_ast::Mutability; use rustc_hir::{Expr, ExprKind, Node}; use rustc_lint::LateContext; use rustc_middle::ty::{self, layout::LayoutOf, Ty, TypeAndMut}; -use rustc_semver::RustcVersion; use super::CAST_SLICE_DIFFERENT_SIZES; -pub(super) fn check<'tcx>(cx: &LateContext<'tcx>, expr: &Expr<'tcx>, msrv: Option) { +pub(super) fn check<'tcx>(cx: &LateContext<'tcx>, expr: &Expr<'tcx>, msrv: &Msrv) { // suggestion is invalid if `ptr::slice_from_raw_parts` does not exist - if !meets_msrv(msrv, msrvs::PTR_SLICE_RAW_PARTS) { + if !msrv.meets(msrvs::PTR_SLICE_RAW_PARTS) { return; } diff --git a/clippy_lints/src/casts/cast_slice_from_raw_parts.rs b/clippy_lints/src/casts/cast_slice_from_raw_parts.rs index 284ef165998..627b795d6ed 100644 --- a/clippy_lints/src/casts/cast_slice_from_raw_parts.rs +++ b/clippy_lints/src/casts/cast_slice_from_raw_parts.rs @@ -1,12 +1,12 @@ use clippy_utils::diagnostics::span_lint_and_sugg; +use clippy_utils::msrvs::{self, Msrv}; use clippy_utils::source::snippet_with_applicability; -use clippy_utils::{match_def_path, meets_msrv, msrvs, paths}; +use clippy_utils::{match_def_path, paths}; use if_chain::if_chain; use rustc_errors::Applicability; use rustc_hir::{def_id::DefId, Expr, ExprKind}; use rustc_lint::LateContext; use rustc_middle::ty::{self, Ty}; -use rustc_semver::RustcVersion; use super::CAST_SLICE_FROM_RAW_PARTS; @@ -25,15 +25,9 @@ fn raw_parts_kind(cx: &LateContext<'_>, did: DefId) -> Option { } } -pub(super) fn check( - cx: &LateContext<'_>, - expr: &Expr<'_>, - cast_expr: &Expr<'_>, - cast_to: Ty<'_>, - msrv: Option, -) { +pub(super) fn check(cx: &LateContext<'_>, expr: &Expr<'_>, cast_expr: &Expr<'_>, cast_to: Ty<'_>, msrv: &Msrv) { if_chain! { - if meets_msrv(msrv, msrvs::PTR_SLICE_RAW_PARTS); + if msrv.meets(msrvs::PTR_SLICE_RAW_PARTS); if let ty::RawPtr(ptrty) = cast_to.kind(); if let ty::Slice(_) = ptrty.ty.kind(); if let ExprKind::Call(fun, [ptr_arg, len_arg]) = cast_expr.peel_blocks().kind; diff --git a/clippy_lints/src/casts/mod.rs b/clippy_lints/src/casts/mod.rs index 7148b5e6ebf..c6d505c4a18 100644 --- a/clippy_lints/src/casts/mod.rs +++ b/clippy_lints/src/casts/mod.rs @@ -21,11 +21,11 @@ mod ptr_as_ptr; mod unnecessary_cast; mod utils; -use clippy_utils::{is_hir_ty_cfg_dependant, meets_msrv, msrvs}; +use clippy_utils::is_hir_ty_cfg_dependant; +use clippy_utils::msrvs::{self, Msrv}; use rustc_hir::{Expr, ExprKind}; use rustc_lint::{LateContext, LateLintPass, LintContext}; use rustc_middle::lint::in_external_macro; -use rustc_semver::RustcVersion; use rustc_session::{declare_tool_lint, impl_lint_pass}; declare_clippy_lint! { @@ -648,12 +648,12 @@ declare_clippy_lint! { } pub struct Casts { - msrv: Option, + msrv: Msrv, } impl Casts { #[must_use] - pub fn new(msrv: Option) -> Self { + pub fn new(msrv: Msrv) -> Self { Self { msrv } } } @@ -686,7 +686,7 @@ impl_lint_pass!(Casts => [ impl<'tcx> LateLintPass<'tcx> for Casts { fn check_expr(&mut self, cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) { if !in_external_macro(cx.sess(), expr.span) { - ptr_as_ptr::check(cx, expr, self.msrv); + ptr_as_ptr::check(cx, expr, &self.msrv); } if expr.span.from_expansion() { @@ -705,7 +705,7 @@ impl<'tcx> LateLintPass<'tcx> for Casts { if unnecessary_cast::check(cx, expr, cast_expr, cast_from, cast_to) { return; } - cast_slice_from_raw_parts::check(cx, expr, cast_expr, cast_to, self.msrv); + cast_slice_from_raw_parts::check(cx, expr, cast_expr, cast_to, &self.msrv); as_ptr_cast_mut::check(cx, expr, cast_expr, cast_to); fn_to_numeric_cast_any::check(cx, expr, cast_expr, cast_from, cast_to); fn_to_numeric_cast::check(cx, expr, cast_expr, cast_from, cast_to); @@ -717,16 +717,16 @@ impl<'tcx> LateLintPass<'tcx> for Casts { cast_possible_wrap::check(cx, expr, cast_from, cast_to); cast_precision_loss::check(cx, expr, cast_from, cast_to); cast_sign_loss::check(cx, expr, cast_expr, cast_from, cast_to); - cast_abs_to_unsigned::check(cx, expr, cast_expr, cast_from, cast_to, self.msrv); + cast_abs_to_unsigned::check(cx, expr, cast_expr, cast_from, cast_to, &self.msrv); cast_nan_to_int::check(cx, expr, cast_expr, cast_from, cast_to); } - cast_lossless::check(cx, expr, cast_expr, cast_from, cast_to, self.msrv); + cast_lossless::check(cx, expr, cast_expr, cast_from, cast_to, &self.msrv); cast_enum_constructor::check(cx, expr, cast_expr, cast_from); } as_underscore::check(cx, expr, cast_to_hir); - if meets_msrv(self.msrv, msrvs::BORROW_AS_PTR) { + if self.msrv.meets(msrvs::BORROW_AS_PTR) { borrow_as_ptr::check(cx, expr, cast_expr, cast_to_hir); } } @@ -734,8 +734,8 @@ impl<'tcx> LateLintPass<'tcx> for Casts { cast_ref_to_mut::check(cx, expr); cast_ptr_alignment::check(cx, expr); char_lit_as_u8::check(cx, expr); - ptr_as_ptr::check(cx, expr, self.msrv); - cast_slice_different_sizes::check(cx, expr, self.msrv); + ptr_as_ptr::check(cx, expr, &self.msrv); + cast_slice_different_sizes::check(cx, expr, &self.msrv); } extract_msrv_attr!(LateContext); diff --git a/clippy_lints/src/casts/ptr_as_ptr.rs b/clippy_lints/src/casts/ptr_as_ptr.rs index c2b9253ec35..43d75a03235 100644 --- a/clippy_lints/src/casts/ptr_as_ptr.rs +++ b/clippy_lints/src/casts/ptr_as_ptr.rs @@ -1,19 +1,18 @@ use std::borrow::Cow; use clippy_utils::diagnostics::span_lint_and_sugg; +use clippy_utils::msrvs::{self, Msrv}; use clippy_utils::sugg::Sugg; -use clippy_utils::{meets_msrv, msrvs}; use if_chain::if_chain; use rustc_errors::Applicability; use rustc_hir::{Expr, ExprKind, Mutability, TyKind}; use rustc_lint::LateContext; use rustc_middle::ty::{self, TypeAndMut}; -use rustc_semver::RustcVersion; use super::PTR_AS_PTR; -pub(super) fn check(cx: &LateContext<'_>, expr: &Expr<'_>, msrv: Option) { - if !meets_msrv(msrv, msrvs::POINTER_CAST) { +pub(super) fn check(cx: &LateContext<'_>, expr: &Expr<'_>, msrv: &Msrv) { + if !msrv.meets(msrvs::POINTER_CAST) { return; } diff --git a/clippy_lints/src/checked_conversions.rs b/clippy_lints/src/checked_conversions.rs index 78e9921f036..9102a89e377 100644 --- a/clippy_lints/src/checked_conversions.rs +++ b/clippy_lints/src/checked_conversions.rs @@ -1,14 +1,14 @@ //! lint on manually implemented checked conversions that could be transformed into `try_from` use clippy_utils::diagnostics::span_lint_and_sugg; +use clippy_utils::msrvs::{self, Msrv}; use clippy_utils::source::snippet_with_applicability; -use clippy_utils::{in_constant, is_integer_literal, meets_msrv, msrvs, SpanlessEq}; +use clippy_utils::{in_constant, is_integer_literal, SpanlessEq}; use if_chain::if_chain; use rustc_errors::Applicability; use rustc_hir::{BinOp, BinOpKind, Expr, ExprKind, QPath, TyKind}; use rustc_lint::{LateContext, LateLintPass, LintContext}; use rustc_middle::lint::in_external_macro; -use rustc_semver::RustcVersion; use rustc_session::{declare_tool_lint, impl_lint_pass}; declare_clippy_lint! { @@ -37,12 +37,12 @@ declare_clippy_lint! { } pub struct CheckedConversions { - msrv: Option, + msrv: Msrv, } impl CheckedConversions { #[must_use] - pub fn new(msrv: Option) -> Self { + pub fn new(msrv: Msrv) -> Self { Self { msrv } } } @@ -51,7 +51,7 @@ impl_lint_pass!(CheckedConversions => [CHECKED_CONVERSIONS]); impl<'tcx> LateLintPass<'tcx> for CheckedConversions { fn check_expr(&mut self, cx: &LateContext<'_>, item: &Expr<'_>) { - if !meets_msrv(self.msrv, msrvs::TRY_FROM) { + if !self.msrv.meets(msrvs::TRY_FROM) { return; } diff --git a/clippy_lints/src/dereference.rs b/clippy_lints/src/dereference.rs index 0eee7f23982..faa8467d266 100644 --- a/clippy_lints/src/dereference.rs +++ b/clippy_lints/src/dereference.rs @@ -1,12 +1,13 @@ use clippy_utils::diagnostics::{span_lint_and_sugg, span_lint_hir_and_then}; use clippy_utils::mir::{enclosing_mir, expr_local, local_assignments, used_exactly_once, PossibleBorrowerMap}; +use clippy_utils::msrvs::{self, Msrv}; use clippy_utils::source::{snippet_with_applicability, snippet_with_context}; use clippy_utils::sugg::has_enclosing_paren; use clippy_utils::ty::{expr_sig, is_copy, peel_mid_ty_refs, ty_sig, variant_of_res}; use clippy_utils::{ - fn_def_id, get_parent_expr, get_parent_expr_for_hir, is_lint_allowed, meets_msrv, msrvs, path_to_local, - walk_to_expr_usage, + fn_def_id, get_parent_expr, get_parent_expr_for_hir, is_lint_allowed, path_to_local, walk_to_expr_usage, }; + use rustc_ast::util::parser::{PREC_POSTFIX, PREC_PREFIX}; use rustc_data_structures::fx::FxIndexMap; use rustc_data_structures::graph::iterate::{CycleDetector, TriColorDepthFirstSearch}; @@ -28,7 +29,6 @@ use rustc_middle::ty::{ self, Binder, BoundVariableKind, EarlyBinder, FnSig, GenericArgKind, List, ParamTy, PredicateKind, ProjectionPredicate, Ty, TyCtxt, TypeVisitable, TypeckResults, }; -use rustc_semver::RustcVersion; use rustc_session::{declare_tool_lint, impl_lint_pass}; use rustc_span::{symbol::sym, Span, Symbol, DUMMY_SP}; use rustc_trait_selection::infer::InferCtxtExt as _; @@ -181,12 +181,12 @@ pub struct Dereferencing<'tcx> { possible_borrowers: Vec<(LocalDefId, PossibleBorrowerMap<'tcx, 'tcx>)>, // `IntoIterator` for arrays requires Rust 1.53. - msrv: Option, + msrv: Msrv, } impl<'tcx> Dereferencing<'tcx> { #[must_use] - pub fn new(msrv: Option) -> Self { + pub fn new(msrv: Msrv) -> Self { Self { msrv, ..Dereferencing::default() @@ -286,7 +286,7 @@ impl<'tcx> LateLintPass<'tcx> for Dereferencing<'tcx> { match (self.state.take(), kind) { (None, kind) => { let expr_ty = typeck.expr_ty(expr); - let (position, adjustments) = walk_parents(cx, &mut self.possible_borrowers, expr, self.msrv); + let (position, adjustments) = walk_parents(cx, &mut self.possible_borrowers, expr, &self.msrv); match kind { RefOp::Deref => { if let Position::FieldAccess { @@ -698,7 +698,7 @@ fn walk_parents<'tcx>( cx: &LateContext<'tcx>, possible_borrowers: &mut Vec<(LocalDefId, PossibleBorrowerMap<'tcx, 'tcx>)>, e: &'tcx Expr<'_>, - msrv: Option, + msrv: &Msrv, ) -> (Position, &'tcx [Adjustment<'tcx>]) { let mut adjustments = [].as_slice(); let mut precedence = 0i8; @@ -1082,7 +1082,7 @@ fn needless_borrow_impl_arg_position<'tcx>( param_ty: ParamTy, mut expr: &Expr<'tcx>, precedence: i8, - msrv: Option, + msrv: &Msrv, ) -> Position { let destruct_trait_def_id = cx.tcx.lang_items().destruct_trait(); let sized_trait_def_id = cx.tcx.lang_items().sized_trait(); @@ -1182,7 +1182,7 @@ fn needless_borrow_impl_arg_position<'tcx>( && let ty::Param(param_ty) = trait_predicate.self_ty().kind() && let GenericArgKind::Type(ty) = substs_with_referent_ty[param_ty.index as usize].unpack() && ty.is_array() - && !meets_msrv(msrv, msrvs::ARRAY_INTO_ITERATOR) + && !msrv.meets(msrvs::ARRAY_INTO_ITERATOR) { return false; } diff --git a/clippy_lints/src/format_args.rs b/clippy_lints/src/format_args.rs index a73453bf027..ec45be558f1 100644 --- a/clippy_lints/src/format_args.rs +++ b/clippy_lints/src/format_args.rs @@ -1,11 +1,12 @@ use clippy_utils::diagnostics::{span_lint_and_sugg, span_lint_and_then}; +use clippy_utils::is_diag_trait_item; use clippy_utils::macros::FormatParamKind::{Implicit, Named, Numbered, Starred}; use clippy_utils::macros::{ is_format_macro, is_panic, root_macro_call, Count, FormatArg, FormatArgsExpn, FormatParam, FormatParamUsage, }; +use clippy_utils::msrvs::{self, Msrv}; use clippy_utils::source::snippet_opt; use clippy_utils::ty::{implements_trait, is_type_diagnostic_item}; -use clippy_utils::{is_diag_trait_item, meets_msrv, msrvs}; use if_chain::if_chain; use itertools::Itertools; use rustc_errors::Applicability; @@ -13,7 +14,6 @@ use rustc_hir::{Expr, ExprKind, HirId, QPath}; use rustc_lint::{LateContext, LateLintPass, LintContext}; use rustc_middle::ty::adjustment::{Adjust, Adjustment}; use rustc_middle::ty::Ty; -use rustc_semver::RustcVersion; use rustc_session::{declare_tool_lint, impl_lint_pass}; use rustc_span::def_id::DefId; use rustc_span::edition::Edition::Edition2021; @@ -158,12 +158,12 @@ impl_lint_pass!(FormatArgs => [ ]); pub struct FormatArgs { - msrv: Option, + msrv: Msrv, } impl FormatArgs { #[must_use] - pub fn new(msrv: Option) -> Self { + pub fn new(msrv: Msrv) -> Self { Self { msrv } } } @@ -188,7 +188,7 @@ impl<'tcx> LateLintPass<'tcx> for FormatArgs { check_format_in_format_args(cx, outermost_expn_data.call_site, name, arg.param.value); check_to_string_in_format_args(cx, name, arg.param.value); } - if meets_msrv(self.msrv, msrvs::FORMAT_ARGS_CAPTURE) { + if self.msrv.meets(msrvs::FORMAT_ARGS_CAPTURE) { check_uninlined_args(cx, &format_args, outermost_expn_data.call_site, macro_def_id); } } diff --git a/clippy_lints/src/from_over_into.rs b/clippy_lints/src/from_over_into.rs index 95eda4ea882..7ff4a05fcdd 100644 --- a/clippy_lints/src/from_over_into.rs +++ b/clippy_lints/src/from_over_into.rs @@ -1,7 +1,8 @@ use clippy_utils::diagnostics::span_lint_and_then; use clippy_utils::macros::span_is_local; +use clippy_utils::msrvs::{self, Msrv}; +use clippy_utils::path_def_id; use clippy_utils::source::snippet_opt; -use clippy_utils::{meets_msrv, msrvs, path_def_id}; use rustc_errors::Applicability; use rustc_hir::intravisit::{walk_path, Visitor}; use rustc_hir::{ @@ -10,7 +11,6 @@ use rustc_hir::{ }; use rustc_lint::{LateContext, LateLintPass}; use rustc_middle::hir::nested_filter::OnlyBodies; -use rustc_semver::RustcVersion; use rustc_session::{declare_tool_lint, impl_lint_pass}; use rustc_span::symbol::{kw, sym}; use rustc_span::{Span, Symbol}; @@ -49,12 +49,12 @@ declare_clippy_lint! { } pub struct FromOverInto { - msrv: Option, + msrv: Msrv, } impl FromOverInto { #[must_use] - pub fn new(msrv: Option) -> Self { + pub fn new(msrv: Msrv) -> Self { FromOverInto { msrv } } } @@ -63,7 +63,7 @@ impl_lint_pass!(FromOverInto => [FROM_OVER_INTO]); impl<'tcx> LateLintPass<'tcx> for FromOverInto { fn check_item(&mut self, cx: &LateContext<'tcx>, item: &'tcx Item<'_>) { - if !meets_msrv(self.msrv, msrvs::RE_REBALANCING_COHERENCE) || !span_is_local(item.span) { + if !self.msrv.meets(msrvs::RE_REBALANCING_COHERENCE) || !span_is_local(item.span) { return; } diff --git a/clippy_lints/src/if_then_some_else_none.rs b/clippy_lints/src/if_then_some_else_none.rs index 0d6718c168a..9cadaaa493e 100644 --- a/clippy_lints/src/if_then_some_else_none.rs +++ b/clippy_lints/src/if_then_some_else_none.rs @@ -1,14 +1,12 @@ use clippy_utils::diagnostics::span_lint_and_help; use clippy_utils::eager_or_lazy::switch_to_eager_eval; +use clippy_utils::msrvs::{self, Msrv}; use clippy_utils::source::snippet_with_macro_callsite; -use clippy_utils::{ - contains_return, higher, is_else_clause, is_res_lang_ctor, meets_msrv, msrvs, path_res, peel_blocks, -}; +use clippy_utils::{contains_return, higher, is_else_clause, is_res_lang_ctor, path_res, peel_blocks}; use rustc_hir::LangItem::{OptionNone, OptionSome}; use rustc_hir::{Expr, ExprKind, Stmt, StmtKind}; use rustc_lint::{LateContext, LateLintPass, LintContext}; use rustc_middle::lint::in_external_macro; -use rustc_semver::RustcVersion; use rustc_session::{declare_tool_lint, impl_lint_pass}; declare_clippy_lint! { @@ -47,12 +45,12 @@ declare_clippy_lint! { } pub struct IfThenSomeElseNone { - msrv: Option, + msrv: Msrv, } impl IfThenSomeElseNone { #[must_use] - pub fn new(msrv: Option) -> Self { + pub fn new(msrv: Msrv) -> Self { Self { msrv } } } @@ -61,7 +59,7 @@ impl_lint_pass!(IfThenSomeElseNone => [IF_THEN_SOME_ELSE_NONE]); impl<'tcx> LateLintPass<'tcx> for IfThenSomeElseNone { fn check_expr(&mut self, cx: &LateContext<'tcx>, expr: &'tcx Expr<'tcx>) { - if !meets_msrv(self.msrv, msrvs::BOOL_THEN) { + if !self.msrv.meets(msrvs::BOOL_THEN) { return; } @@ -94,7 +92,7 @@ impl<'tcx> LateLintPass<'tcx> for IfThenSomeElseNone { } else { format!("{{ /* snippet */ {arg_snip} }}") }; - let method_name = if switch_to_eager_eval(cx, expr) && meets_msrv(self.msrv, msrvs::BOOL_THEN_SOME) { + let method_name = if switch_to_eager_eval(cx, expr) && self.msrv.meets(msrvs::BOOL_THEN_SOME) { "then_some" } else { method_body.insert_str(0, "|| "); diff --git a/clippy_lints/src/index_refutable_slice.rs b/clippy_lints/src/index_refutable_slice.rs index 0d5099bde6d..ee5f10da5b8 100644 --- a/clippy_lints/src/index_refutable_slice.rs +++ b/clippy_lints/src/index_refutable_slice.rs @@ -1,8 +1,9 @@ use clippy_utils::consts::{constant, Constant}; use clippy_utils::diagnostics::span_lint_and_then; use clippy_utils::higher::IfLet; +use clippy_utils::msrvs::{self, Msrv}; use clippy_utils::ty::is_copy; -use clippy_utils::{is_expn_of, is_lint_allowed, meets_msrv, msrvs, path_to_local}; +use clippy_utils::{is_expn_of, is_lint_allowed, path_to_local}; use if_chain::if_chain; use rustc_data_structures::fx::{FxHashSet, FxIndexMap}; use rustc_errors::Applicability; @@ -11,7 +12,6 @@ use rustc_hir::intravisit::{self, Visitor}; use rustc_lint::{LateContext, LateLintPass}; use rustc_middle::hir::nested_filter; use rustc_middle::ty; -use rustc_semver::RustcVersion; use rustc_session::{declare_tool_lint, impl_lint_pass}; use rustc_span::{symbol::Ident, Span}; @@ -51,14 +51,13 @@ declare_clippy_lint! { "avoid indexing on slices which could be destructed" } -#[derive(Copy, Clone)] pub struct IndexRefutableSlice { max_suggested_slice: u64, - msrv: Option, + msrv: Msrv, } impl IndexRefutableSlice { - pub fn new(max_suggested_slice_pattern_length: u64, msrv: Option) -> Self { + pub fn new(max_suggested_slice_pattern_length: u64, msrv: Msrv) -> Self { Self { max_suggested_slice: max_suggested_slice_pattern_length, msrv, @@ -74,7 +73,7 @@ impl<'tcx> LateLintPass<'tcx> for IndexRefutableSlice { if !expr.span.from_expansion() || is_expn_of(expr.span, "if_chain").is_some(); if let Some(IfLet {let_pat, if_then, ..}) = IfLet::hir(cx, expr); if !is_lint_allowed(cx, INDEX_REFUTABLE_SLICE, expr.hir_id); - if meets_msrv(self.msrv, msrvs::SLICE_PATTERNS); + if self.msrv.meets(msrvs::SLICE_PATTERNS); let found_slices = find_slice_values(cx, let_pat); if !found_slices.is_empty(); diff --git a/clippy_lints/src/instant_subtraction.rs b/clippy_lints/src/instant_subtraction.rs index 60754b224fc..dd1b23e7d9d 100644 --- a/clippy_lints/src/instant_subtraction.rs +++ b/clippy_lints/src/instant_subtraction.rs @@ -1,13 +1,11 @@ -use clippy_utils::{ - diagnostics::{self, span_lint_and_sugg}, - meets_msrv, msrvs, source, - sugg::Sugg, - ty, -}; +use clippy_utils::diagnostics::{self, span_lint_and_sugg}; +use clippy_utils::msrvs::{self, Msrv}; +use clippy_utils::source; +use clippy_utils::sugg::Sugg; +use clippy_utils::ty; use rustc_errors::Applicability; use rustc_hir::{BinOpKind, Expr, ExprKind}; use rustc_lint::{LateContext, LateLintPass}; -use rustc_semver::RustcVersion; use rustc_session::{declare_tool_lint, impl_lint_pass}; use rustc_span::{source_map::Spanned, sym}; @@ -68,12 +66,12 @@ declare_clippy_lint! { } pub struct InstantSubtraction { - msrv: Option, + msrv: Msrv, } impl InstantSubtraction { #[must_use] - pub fn new(msrv: Option) -> Self { + pub fn new(msrv: Msrv) -> Self { Self { msrv } } } @@ -101,7 +99,7 @@ impl LateLintPass<'_> for InstantSubtraction { } else { if_chain! { if !expr.span.from_expansion(); - if meets_msrv(self.msrv, msrvs::TRY_FROM); + if self.msrv.meets(msrvs::TRY_FROM); if is_an_instant(cx, lhs); if is_a_duration(cx, rhs); diff --git a/clippy_lints/src/lib.rs b/clippy_lints/src/lib.rs index 3ab5031696d..46acc9679f5 100644 --- a/clippy_lints/src/lib.rs +++ b/clippy_lints/src/lib.rs @@ -52,10 +52,9 @@ extern crate declare_clippy_lint; use std::io; use std::path::PathBuf; -use clippy_utils::parse_msrv; +use clippy_utils::msrvs::Msrv; use rustc_data_structures::fx::FxHashSet; use rustc_lint::{Lint, LintId}; -use rustc_semver::RustcVersion; use rustc_session::Session; #[cfg(feature = "internal")] @@ -322,48 +321,10 @@ pub use crate::utils::conf::{lookup_conf_file, Conf}; /// Used in `./src/driver.rs`. pub fn register_pre_expansion_lints(store: &mut rustc_lint::LintStore, sess: &Session, conf: &Conf) { // NOTE: Do not add any more pre-expansion passes. These should be removed eventually. + let msrv = Msrv::read(&conf.msrv, sess); + let msrv = move || msrv.clone(); - let msrv = conf.msrv.as_ref().and_then(|s| { - parse_msrv(s, None, None).or_else(|| { - sess.err(format!( - "error reading Clippy's configuration file. `{s}` is not a valid Rust version" - )); - None - }) - }); - - store.register_pre_expansion_pass(move || Box::new(attrs::EarlyAttributes { msrv })); -} - -fn read_msrv(conf: &Conf, sess: &Session) -> Option { - let cargo_msrv = std::env::var("CARGO_PKG_RUST_VERSION") - .ok() - .and_then(|v| parse_msrv(&v, None, None)); - let clippy_msrv = conf.msrv.as_ref().and_then(|s| { - parse_msrv(s, None, None).or_else(|| { - sess.err(format!( - "error reading Clippy's configuration file. `{s}` is not a valid Rust version" - )); - None - }) - }); - - if let Some(cargo_msrv) = cargo_msrv { - if let Some(clippy_msrv) = clippy_msrv { - // if both files have an msrv, let's compare them and emit a warning if they differ - if clippy_msrv != cargo_msrv { - sess.warn(format!( - "the MSRV in `clippy.toml` and `Cargo.toml` differ; using `{clippy_msrv}` from `clippy.toml`" - )); - } - - Some(clippy_msrv) - } else { - Some(cargo_msrv) - } - } else { - clippy_msrv - } + store.register_pre_expansion_pass(move || Box::new(attrs::EarlyAttributes { msrv: msrv() })); } #[doc(hidden)] @@ -595,43 +556,44 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf: store.register_late_pass(|_| Box::new(non_octal_unix_permissions::NonOctalUnixPermissions)); store.register_early_pass(|| Box::new(unnecessary_self_imports::UnnecessarySelfImports)); - let msrv = read_msrv(conf, sess); + let msrv = Msrv::read(&conf.msrv, sess); + let msrv = move || msrv.clone(); let avoid_breaking_exported_api = conf.avoid_breaking_exported_api; let allow_expect_in_tests = conf.allow_expect_in_tests; let allow_unwrap_in_tests = conf.allow_unwrap_in_tests; - store.register_late_pass(move |_| Box::new(approx_const::ApproxConstant::new(msrv))); + store.register_late_pass(move |_| Box::new(approx_const::ApproxConstant::new(msrv()))); store.register_late_pass(move |_| { Box::new(methods::Methods::new( avoid_breaking_exported_api, - msrv, + msrv(), allow_expect_in_tests, allow_unwrap_in_tests, )) }); - store.register_late_pass(move |_| Box::new(matches::Matches::new(msrv))); + store.register_late_pass(move |_| Box::new(matches::Matches::new(msrv()))); let matches_for_let_else = conf.matches_for_let_else; - store.register_late_pass(move |_| Box::new(manual_let_else::ManualLetElse::new(msrv, matches_for_let_else))); - store.register_early_pass(move || Box::new(manual_non_exhaustive::ManualNonExhaustiveStruct::new(msrv))); - store.register_late_pass(move |_| Box::new(manual_non_exhaustive::ManualNonExhaustiveEnum::new(msrv))); - store.register_late_pass(move |_| Box::new(manual_strip::ManualStrip::new(msrv))); - store.register_early_pass(move || Box::new(redundant_static_lifetimes::RedundantStaticLifetimes::new(msrv))); - store.register_early_pass(move || Box::new(redundant_field_names::RedundantFieldNames::new(msrv))); - store.register_late_pass(move |_| Box::new(checked_conversions::CheckedConversions::new(msrv))); - store.register_late_pass(move |_| Box::new(mem_replace::MemReplace::new(msrv))); - store.register_late_pass(move |_| Box::new(ranges::Ranges::new(msrv))); - store.register_late_pass(move |_| Box::new(from_over_into::FromOverInto::new(msrv))); - store.register_late_pass(move |_| Box::new(use_self::UseSelf::new(msrv))); - store.register_late_pass(move |_| Box::new(missing_const_for_fn::MissingConstForFn::new(msrv))); + store.register_late_pass(move |_| Box::new(manual_let_else::ManualLetElse::new(msrv(), matches_for_let_else))); + store.register_early_pass(move || Box::new(manual_non_exhaustive::ManualNonExhaustiveStruct::new(msrv()))); + store.register_late_pass(move |_| Box::new(manual_non_exhaustive::ManualNonExhaustiveEnum::new(msrv()))); + store.register_late_pass(move |_| Box::new(manual_strip::ManualStrip::new(msrv()))); + store.register_early_pass(move || Box::new(redundant_static_lifetimes::RedundantStaticLifetimes::new(msrv()))); + store.register_early_pass(move || Box::new(redundant_field_names::RedundantFieldNames::new(msrv()))); + store.register_late_pass(move |_| Box::new(checked_conversions::CheckedConversions::new(msrv()))); + store.register_late_pass(move |_| Box::new(mem_replace::MemReplace::new(msrv()))); + store.register_late_pass(move |_| Box::new(ranges::Ranges::new(msrv()))); + store.register_late_pass(move |_| Box::new(from_over_into::FromOverInto::new(msrv()))); + store.register_late_pass(move |_| Box::new(use_self::UseSelf::new(msrv()))); + store.register_late_pass(move |_| Box::new(missing_const_for_fn::MissingConstForFn::new(msrv()))); store.register_late_pass(move |_| Box::new(needless_question_mark::NeedlessQuestionMark)); - store.register_late_pass(move |_| Box::new(casts::Casts::new(msrv))); - store.register_early_pass(move || Box::new(unnested_or_patterns::UnnestedOrPatterns::new(msrv))); + store.register_late_pass(move |_| Box::new(casts::Casts::new(msrv()))); + store.register_early_pass(move || Box::new(unnested_or_patterns::UnnestedOrPatterns::new(msrv()))); store.register_late_pass(|_| Box::new(size_of_in_element_count::SizeOfInElementCount)); store.register_late_pass(|_| Box::new(same_name_method::SameNameMethod)); let max_suggested_slice_pattern_length = conf.max_suggested_slice_pattern_length; store.register_late_pass(move |_| { Box::new(index_refutable_slice::IndexRefutableSlice::new( max_suggested_slice_pattern_length, - msrv, + msrv(), )) }); store.register_late_pass(|_| Box::::default()); @@ -648,7 +610,7 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf: store.register_late_pass(|_| Box::new(borrow_deref_ref::BorrowDerefRef)); store.register_late_pass(|_| Box::new(no_effect::NoEffect)); store.register_late_pass(|_| Box::new(temporary_assignment::TemporaryAssignment)); - store.register_late_pass(move |_| Box::new(transmute::Transmute::new(msrv))); + store.register_late_pass(move |_| Box::new(transmute::Transmute::new(msrv()))); let cognitive_complexity_threshold = conf.cognitive_complexity_threshold; store.register_late_pass(move |_| { Box::new(cognitive_complexity::CognitiveComplexity::new( @@ -806,7 +768,7 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf: store.register_late_pass(move |_| Box::new(wildcard_imports::WildcardImports::new(warn_on_all_wildcard_imports))); store.register_late_pass(|_| Box::::default()); store.register_late_pass(|_| Box::new(unnamed_address::UnnamedAddress)); - store.register_late_pass(move |_| Box::new(dereference::Dereferencing::new(msrv))); + store.register_late_pass(move |_| Box::new(dereference::Dereferencing::new(msrv()))); store.register_late_pass(|_| Box::new(option_if_let_else::OptionIfLetElse)); store.register_late_pass(|_| Box::new(future_not_send::FutureNotSend)); store.register_late_pass(|_| Box::new(if_let_mutex::IfLetMutex)); @@ -840,7 +802,7 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf: store.register_late_pass(|_| Box::::default()); store.register_late_pass(|_| Box::new(redundant_slicing::RedundantSlicing)); store.register_late_pass(|_| Box::new(from_str_radix_10::FromStrRadix10)); - store.register_late_pass(move |_| Box::new(if_then_some_else_none::IfThenSomeElseNone::new(msrv))); + store.register_late_pass(move |_| Box::new(if_then_some_else_none::IfThenSomeElseNone::new(msrv()))); store.register_late_pass(|_| Box::new(bool_assert_comparison::BoolAssertComparison)); store.register_early_pass(move || Box::new(module_style::ModStyle)); store.register_late_pass(|_| Box::new(unused_async::UnusedAsync)); @@ -865,14 +827,14 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf: )) }); store.register_late_pass(move |_| Box::new(undocumented_unsafe_blocks::UndocumentedUnsafeBlocks)); - store.register_late_pass(move |_| Box::new(format_args::FormatArgs::new(msrv))); + store.register_late_pass(move |_| Box::new(format_args::FormatArgs::new(msrv()))); store.register_late_pass(|_| Box::new(trailing_empty_array::TrailingEmptyArray)); store.register_early_pass(|| Box::new(octal_escapes::OctalEscapes)); store.register_late_pass(|_| Box::new(needless_late_init::NeedlessLateInit)); store.register_late_pass(|_| Box::new(return_self_not_must_use::ReturnSelfNotMustUse)); store.register_late_pass(|_| Box::new(init_numbered_fields::NumberedFields)); store.register_early_pass(|| Box::new(single_char_lifetime_names::SingleCharLifetimeNames)); - store.register_late_pass(move |_| Box::new(manual_bits::ManualBits::new(msrv))); + store.register_late_pass(move |_| Box::new(manual_bits::ManualBits::new(msrv()))); store.register_late_pass(|_| Box::new(default_union_representation::DefaultUnionRepresentation)); store.register_late_pass(|_| Box::::default()); let allow_dbg_in_tests = conf.allow_dbg_in_tests; @@ -896,20 +858,20 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf: store.register_late_pass(|_| Box::new(rc_clone_in_vec_init::RcCloneInVecInit)); store.register_early_pass(|| Box::::default()); store.register_early_pass(|| Box::new(unused_rounding::UnusedRounding)); - store.register_early_pass(move || Box::new(almost_complete_letter_range::AlmostCompleteLetterRange::new(msrv))); + store.register_early_pass(move || Box::new(almost_complete_letter_range::AlmostCompleteLetterRange::new(msrv()))); store.register_late_pass(|_| Box::new(swap_ptr_to_ref::SwapPtrToRef)); store.register_late_pass(|_| Box::new(mismatching_type_param_order::TypeParamMismatch)); store.register_late_pass(|_| Box::new(read_zero_byte_vec::ReadZeroByteVec)); store.register_late_pass(|_| Box::new(default_instead_of_iter_empty::DefaultIterEmpty)); - store.register_late_pass(move |_| Box::new(manual_rem_euclid::ManualRemEuclid::new(msrv))); - store.register_late_pass(move |_| Box::new(manual_retain::ManualRetain::new(msrv))); + store.register_late_pass(move |_| Box::new(manual_rem_euclid::ManualRemEuclid::new(msrv()))); + store.register_late_pass(move |_| Box::new(manual_retain::ManualRetain::new(msrv()))); let verbose_bit_mask_threshold = conf.verbose_bit_mask_threshold; store.register_late_pass(move |_| Box::new(operators::Operators::new(verbose_bit_mask_threshold))); store.register_late_pass(|_| Box::new(invalid_utf8_in_unchecked::InvalidUtf8InUnchecked)); store.register_late_pass(|_| Box::::default()); - store.register_late_pass(move |_| Box::new(instant_subtraction::InstantSubtraction::new(msrv))); + store.register_late_pass(move |_| Box::new(instant_subtraction::InstantSubtraction::new(msrv()))); store.register_late_pass(|_| Box::new(partialeq_to_none::PartialeqToNone)); - store.register_late_pass(move |_| Box::new(manual_clamp::ManualClamp::new(msrv))); + store.register_late_pass(move |_| Box::new(manual_clamp::ManualClamp::new(msrv()))); store.register_late_pass(|_| Box::new(manual_string_new::ManualStringNew)); store.register_late_pass(|_| Box::new(unused_peekable::UnusedPeekable)); store.register_early_pass(|| Box::new(multi_assignments::MultiAssignments)); @@ -920,7 +882,7 @@ pub fn register_plugins(store: &mut rustc_lint::LintStore, sess: &Session, conf: store.register_late_pass(|_| Box::new(missing_trait_methods::MissingTraitMethods)); store.register_late_pass(|_| Box::new(from_raw_with_void_ptr::FromRawWithVoidPtr)); store.register_late_pass(|_| Box::new(suspicious_xor_used_as_pow::ConfusingXorAndPow)); - store.register_late_pass(move |_| Box::new(manual_is_ascii_check::ManualIsAsciiCheck::new(msrv))); + store.register_late_pass(move |_| Box::new(manual_is_ascii_check::ManualIsAsciiCheck::new(msrv()))); // add lints here, do not remove this comment, it's used in `new_lint` } diff --git a/clippy_lints/src/manual_bits.rs b/clippy_lints/src/manual_bits.rs index 6655c92b1da..462d73cf0b9 100644 --- a/clippy_lints/src/manual_bits.rs +++ b/clippy_lints/src/manual_bits.rs @@ -1,12 +1,12 @@ use clippy_utils::diagnostics::span_lint_and_sugg; +use clippy_utils::get_parent_expr; +use clippy_utils::msrvs::{self, Msrv}; use clippy_utils::source::snippet_with_applicability; -use clippy_utils::{get_parent_expr, meets_msrv, msrvs}; use rustc_ast::ast::LitKind; use rustc_errors::Applicability; use rustc_hir::{BinOpKind, Expr, ExprKind, GenericArg, QPath}; use rustc_lint::{LateContext, LateLintPass}; use rustc_middle::ty::{self, Ty}; -use rustc_semver::RustcVersion; use rustc_session::{declare_tool_lint, impl_lint_pass}; use rustc_span::sym; @@ -34,12 +34,12 @@ declare_clippy_lint! { #[derive(Clone)] pub struct ManualBits { - msrv: Option, + msrv: Msrv, } impl ManualBits { #[must_use] - pub fn new(msrv: Option) -> Self { + pub fn new(msrv: Msrv) -> Self { Self { msrv } } } @@ -48,7 +48,7 @@ impl_lint_pass!(ManualBits => [MANUAL_BITS]); impl<'tcx> LateLintPass<'tcx> for ManualBits { fn check_expr(&mut self, cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) { - if !meets_msrv(self.msrv, msrvs::MANUAL_BITS) { + if !self.msrv.meets(msrvs::MANUAL_BITS) { return; } diff --git a/clippy_lints/src/manual_clamp.rs b/clippy_lints/src/manual_clamp.rs index 02dc8755dd6..bb6d628af3b 100644 --- a/clippy_lints/src/manual_clamp.rs +++ b/clippy_lints/src/manual_clamp.rs @@ -1,28 +1,25 @@ +use clippy_utils::diagnostics::{span_lint_and_then, span_lint_hir_and_then}; +use clippy_utils::higher::If; +use clippy_utils::msrvs::{self, Msrv}; +use clippy_utils::sugg::Sugg; +use clippy_utils::ty::implements_trait; +use clippy_utils::visitors::is_const_evaluatable; +use clippy_utils::MaybePath; +use clippy_utils::{ + eq_expr_value, is_diag_trait_item, is_trait_method, path_res, path_to_local_id, peel_blocks, peel_blocks_with_stmt, +}; use itertools::Itertools; +use rustc_errors::Applicability; use rustc_errors::Diagnostic; use rustc_hir::{ def::Res, Arm, BinOpKind, Block, Expr, ExprKind, Guard, HirId, PatKind, PathSegment, PrimTy, QPath, StmtKind, }; use rustc_lint::{LateContext, LateLintPass}; use rustc_middle::ty::Ty; -use rustc_semver::RustcVersion; use rustc_session::{declare_tool_lint, impl_lint_pass}; use rustc_span::{symbol::sym, Span}; use std::ops::Deref; -use clippy_utils::{ - diagnostics::{span_lint_and_then, span_lint_hir_and_then}, - eq_expr_value, - higher::If, - is_diag_trait_item, is_trait_method, meets_msrv, msrvs, path_res, path_to_local_id, peel_blocks, - peel_blocks_with_stmt, - sugg::Sugg, - ty::implements_trait, - visitors::is_const_evaluatable, - MaybePath, -}; -use rustc_errors::Applicability; - declare_clippy_lint! { /// ### What it does /// Identifies good opportunities for a clamp function from std or core, and suggests using it. @@ -87,11 +84,11 @@ declare_clippy_lint! { impl_lint_pass!(ManualClamp => [MANUAL_CLAMP]); pub struct ManualClamp { - msrv: Option, + msrv: Msrv, } impl ManualClamp { - pub fn new(msrv: Option) -> Self { + pub fn new(msrv: Msrv) -> Self { Self { msrv } } } @@ -114,7 +111,7 @@ struct InputMinMax<'tcx> { impl<'tcx> LateLintPass<'tcx> for ManualClamp { fn check_expr(&mut self, cx: &LateContext<'tcx>, expr: &'tcx Expr<'tcx>) { - if !meets_msrv(self.msrv, msrvs::CLAMP) { + if !self.msrv.meets(msrvs::CLAMP) { return; } if !expr.span.from_expansion() { @@ -130,7 +127,7 @@ impl<'tcx> LateLintPass<'tcx> for ManualClamp { } fn check_block(&mut self, cx: &LateContext<'tcx>, block: &'tcx Block<'tcx>) { - if !meets_msrv(self.msrv, msrvs::CLAMP) { + if !self.msrv.meets(msrvs::CLAMP) { return; } for suggestion in is_two_if_pattern(cx, block) { diff --git a/clippy_lints/src/manual_is_ascii_check.rs b/clippy_lints/src/manual_is_ascii_check.rs index bb8c142f8e4..5ab049d8d13 100644 --- a/clippy_lints/src/manual_is_ascii_check.rs +++ b/clippy_lints/src/manual_is_ascii_check.rs @@ -1,15 +1,12 @@ +use clippy_utils::msrvs::{self, Msrv}; +use clippy_utils::{diagnostics::span_lint_and_sugg, in_constant, macros::root_macro_call, source::snippet}; use rustc_ast::LitKind::{Byte, Char}; use rustc_errors::Applicability; use rustc_hir::{Expr, ExprKind, PatKind, RangeEnd}; use rustc_lint::{LateContext, LateLintPass}; -use rustc_semver::RustcVersion; use rustc_session::{declare_tool_lint, impl_lint_pass}; use rustc_span::{def_id::DefId, sym}; -use clippy_utils::{ - diagnostics::span_lint_and_sugg, in_constant, macros::root_macro_call, meets_msrv, msrvs, source::snippet, -}; - declare_clippy_lint! { /// ### What it does /// Suggests to use dedicated built-in methods, @@ -45,12 +42,12 @@ declare_clippy_lint! { impl_lint_pass!(ManualIsAsciiCheck => [MANUAL_IS_ASCII_CHECK]); pub struct ManualIsAsciiCheck { - msrv: Option, + msrv: Msrv, } impl ManualIsAsciiCheck { #[must_use] - pub fn new(msrv: Option) -> Self { + pub fn new(msrv: Msrv) -> Self { Self { msrv } } } @@ -70,11 +67,11 @@ enum CharRange { impl<'tcx> LateLintPass<'tcx> for ManualIsAsciiCheck { fn check_expr(&mut self, cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) { - if !meets_msrv(self.msrv, msrvs::IS_ASCII_DIGIT) { + if !self.msrv.meets(msrvs::IS_ASCII_DIGIT) { return; } - if in_constant(cx, expr.hir_id) && !meets_msrv(self.msrv, msrvs::IS_ASCII_DIGIT_CONST) { + if in_constant(cx, expr.hir_id) && !self.msrv.meets(msrvs::IS_ASCII_DIGIT_CONST) { return; } diff --git a/clippy_lints/src/manual_let_else.rs b/clippy_lints/src/manual_let_else.rs index 1846596fa4c..20f06830952 100644 --- a/clippy_lints/src/manual_let_else.rs +++ b/clippy_lints/src/manual_let_else.rs @@ -1,16 +1,16 @@ use clippy_utils::diagnostics::span_lint_and_then; use clippy_utils::higher::IfLetOrMatch; +use clippy_utils::msrvs::{self, Msrv}; +use clippy_utils::peel_blocks; use clippy_utils::source::snippet_opt; use clippy_utils::ty::is_type_diagnostic_item; use clippy_utils::visitors::{for_each_expr, Descend}; -use clippy_utils::{meets_msrv, msrvs, peel_blocks}; use if_chain::if_chain; use rustc_data_structures::fx::FxHashSet; use rustc_errors::Applicability; use rustc_hir::{Expr, ExprKind, MatchSource, Pat, PatKind, QPath, Stmt, StmtKind}; use rustc_lint::{LateContext, LateLintPass, LintContext}; use rustc_middle::lint::in_external_macro; -use rustc_semver::RustcVersion; use rustc_session::{declare_tool_lint, impl_lint_pass}; use rustc_span::symbol::sym; use rustc_span::Span; @@ -50,13 +50,13 @@ declare_clippy_lint! { } pub struct ManualLetElse { - msrv: Option, + msrv: Msrv, matches_behaviour: MatchLintBehaviour, } impl ManualLetElse { #[must_use] - pub fn new(msrv: Option, matches_behaviour: MatchLintBehaviour) -> Self { + pub fn new(msrv: Msrv, matches_behaviour: MatchLintBehaviour) -> Self { Self { msrv, matches_behaviour, @@ -69,7 +69,7 @@ impl_lint_pass!(ManualLetElse => [MANUAL_LET_ELSE]); impl<'tcx> LateLintPass<'tcx> for ManualLetElse { fn check_stmt(&mut self, cx: &LateContext<'_>, stmt: &'tcx Stmt<'tcx>) { let if_let_or_match = if_chain! { - if meets_msrv(self.msrv, msrvs::LET_ELSE); + if self.msrv.meets(msrvs::LET_ELSE); if !in_external_macro(cx.sess(), stmt.span); if let StmtKind::Local(local) = stmt.kind; if let Some(init) = local.init; diff --git a/clippy_lints/src/manual_non_exhaustive.rs b/clippy_lints/src/manual_non_exhaustive.rs index 6a42275322b..d32fa1121f4 100644 --- a/clippy_lints/src/manual_non_exhaustive.rs +++ b/clippy_lints/src/manual_non_exhaustive.rs @@ -1,6 +1,7 @@ use clippy_utils::diagnostics::{span_lint_and_then, span_lint_hir_and_then}; +use clippy_utils::is_doc_hidden; +use clippy_utils::msrvs::{self, Msrv}; use clippy_utils::source::snippet_opt; -use clippy_utils::{is_doc_hidden, meets_msrv, msrvs}; use rustc_ast::ast::{self, VisibilityKind}; use rustc_data_structures::fx::FxHashSet; use rustc_errors::Applicability; @@ -8,7 +9,6 @@ use rustc_hir::def::{CtorKind, CtorOf, DefKind, Res}; use rustc_hir::{self as hir, Expr, ExprKind, QPath}; use rustc_lint::{EarlyContext, EarlyLintPass, LateContext, LateLintPass, LintContext}; use rustc_middle::ty::DefIdTree; -use rustc_semver::RustcVersion; use rustc_session::{declare_tool_lint, impl_lint_pass}; use rustc_span::def_id::{DefId, LocalDefId}; use rustc_span::{sym, Span}; @@ -63,12 +63,12 @@ declare_clippy_lint! { #[expect(clippy::module_name_repetitions)] pub struct ManualNonExhaustiveStruct { - msrv: Option, + msrv: Msrv, } impl ManualNonExhaustiveStruct { #[must_use] - pub fn new(msrv: Option) -> Self { + pub fn new(msrv: Msrv) -> Self { Self { msrv } } } @@ -77,14 +77,14 @@ impl_lint_pass!(ManualNonExhaustiveStruct => [MANUAL_NON_EXHAUSTIVE]); #[expect(clippy::module_name_repetitions)] pub struct ManualNonExhaustiveEnum { - msrv: Option, + msrv: Msrv, constructed_enum_variants: FxHashSet<(DefId, DefId)>, potential_enums: Vec<(LocalDefId, LocalDefId, Span, Span)>, } impl ManualNonExhaustiveEnum { #[must_use] - pub fn new(msrv: Option) -> Self { + pub fn new(msrv: Msrv) -> Self { Self { msrv, constructed_enum_variants: FxHashSet::default(), @@ -97,7 +97,7 @@ impl_lint_pass!(ManualNonExhaustiveEnum => [MANUAL_NON_EXHAUSTIVE]); impl EarlyLintPass for ManualNonExhaustiveStruct { fn check_item(&mut self, cx: &EarlyContext<'_>, item: &ast::Item) { - if !meets_msrv(self.msrv, msrvs::NON_EXHAUSTIVE) { + if !self.msrv.meets(msrvs::NON_EXHAUSTIVE) { return; } @@ -149,7 +149,7 @@ impl EarlyLintPass for ManualNonExhaustiveStruct { impl<'tcx> LateLintPass<'tcx> for ManualNonExhaustiveEnum { fn check_item(&mut self, cx: &LateContext<'tcx>, item: &'tcx hir::Item<'_>) { - if !meets_msrv(self.msrv, msrvs::NON_EXHAUSTIVE) { + if !self.msrv.meets(msrvs::NON_EXHAUSTIVE) { return; } diff --git a/clippy_lints/src/manual_rem_euclid.rs b/clippy_lints/src/manual_rem_euclid.rs index 6f25a2ed8e4..8d447c37150 100644 --- a/clippy_lints/src/manual_rem_euclid.rs +++ b/clippy_lints/src/manual_rem_euclid.rs @@ -1,12 +1,12 @@ use clippy_utils::consts::{constant_full_int, FullInt}; use clippy_utils::diagnostics::span_lint_and_sugg; +use clippy_utils::msrvs::{self, Msrv}; use clippy_utils::source::snippet_with_applicability; -use clippy_utils::{in_constant, meets_msrv, msrvs, path_to_local}; +use clippy_utils::{in_constant, path_to_local}; use rustc_errors::Applicability; use rustc_hir::{BinOpKind, Expr, ExprKind, Node, TyKind}; use rustc_lint::{LateContext, LateLintPass, LintContext}; use rustc_middle::lint::in_external_macro; -use rustc_semver::RustcVersion; use rustc_session::{declare_tool_lint, impl_lint_pass}; declare_clippy_lint! { @@ -34,12 +34,12 @@ declare_clippy_lint! { } pub struct ManualRemEuclid { - msrv: Option, + msrv: Msrv, } impl ManualRemEuclid { #[must_use] - pub fn new(msrv: Option) -> Self { + pub fn new(msrv: Msrv) -> Self { Self { msrv } } } @@ -48,11 +48,11 @@ impl_lint_pass!(ManualRemEuclid => [MANUAL_REM_EUCLID]); impl<'tcx> LateLintPass<'tcx> for ManualRemEuclid { fn check_expr(&mut self, cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) { - if !meets_msrv(self.msrv, msrvs::REM_EUCLID) { + if !self.msrv.meets(msrvs::REM_EUCLID) { return; } - if in_constant(cx, expr.hir_id) && !meets_msrv(self.msrv, msrvs::REM_EUCLID_CONST) { + if in_constant(cx, expr.hir_id) && !self.msrv.meets(msrvs::REM_EUCLID_CONST) { return; } diff --git a/clippy_lints/src/manual_retain.rs b/clippy_lints/src/manual_retain.rs index 3181bc86d17..4907f02b5a3 100644 --- a/clippy_lints/src/manual_retain.rs +++ b/clippy_lints/src/manual_retain.rs @@ -1,8 +1,8 @@ use clippy_utils::diagnostics::span_lint_and_sugg; +use clippy_utils::msrvs::{self, Msrv}; use clippy_utils::source::snippet; use clippy_utils::ty::is_type_diagnostic_item; use clippy_utils::{get_parent_expr, match_def_path, paths, SpanlessEq}; -use clippy_utils::{meets_msrv, msrvs}; use rustc_errors::Applicability; use rustc_hir as hir; use rustc_hir::def_id::DefId; @@ -50,12 +50,12 @@ declare_clippy_lint! { } pub struct ManualRetain { - msrv: Option, + msrv: Msrv, } impl ManualRetain { #[must_use] - pub fn new(msrv: Option) -> Self { + pub fn new(msrv: Msrv) -> Self { Self { msrv } } } @@ -71,9 +71,9 @@ impl<'tcx> LateLintPass<'tcx> for ManualRetain { && let hir::ExprKind::MethodCall(_, target_expr, [], _) = &collect_expr.kind && let Some(collect_def_id) = cx.typeck_results().type_dependent_def_id(collect_expr.hir_id) && match_def_path(cx, collect_def_id, &paths::CORE_ITER_COLLECT) { - check_into_iter(cx, parent_expr, left_expr, target_expr, self.msrv); - check_iter(cx, parent_expr, left_expr, target_expr, self.msrv); - check_to_owned(cx, parent_expr, left_expr, target_expr, self.msrv); + check_into_iter(cx, parent_expr, left_expr, target_expr, &self.msrv); + check_iter(cx, parent_expr, left_expr, target_expr, &self.msrv); + check_to_owned(cx, parent_expr, left_expr, target_expr, &self.msrv); } } @@ -85,7 +85,7 @@ fn check_into_iter( parent_expr: &hir::Expr<'_>, left_expr: &hir::Expr<'_>, target_expr: &hir::Expr<'_>, - msrv: Option, + msrv: &Msrv, ) { if let hir::ExprKind::MethodCall(_, into_iter_expr, [_], _) = &target_expr.kind && let Some(filter_def_id) = cx.typeck_results().type_dependent_def_id(target_expr.hir_id) @@ -104,7 +104,7 @@ fn check_iter( parent_expr: &hir::Expr<'_>, left_expr: &hir::Expr<'_>, target_expr: &hir::Expr<'_>, - msrv: Option, + msrv: &Msrv, ) { if let hir::ExprKind::MethodCall(_, filter_expr, [], _) = &target_expr.kind && let Some(copied_def_id) = cx.typeck_results().type_dependent_def_id(target_expr.hir_id) @@ -127,9 +127,9 @@ fn check_to_owned( parent_expr: &hir::Expr<'_>, left_expr: &hir::Expr<'_>, target_expr: &hir::Expr<'_>, - msrv: Option, + msrv: &Msrv, ) { - if meets_msrv(msrv, msrvs::STRING_RETAIN) + if msrv.meets(msrvs::STRING_RETAIN) && let hir::ExprKind::MethodCall(_, filter_expr, [], _) = &target_expr.kind && let Some(to_owned_def_id) = cx.typeck_results().type_dependent_def_id(target_expr.hir_id) && match_def_path(cx, to_owned_def_id, &paths::TO_OWNED_METHOD) @@ -215,10 +215,10 @@ fn match_acceptable_def_path(cx: &LateContext<'_>, collect_def_id: DefId) -> boo .any(|&method| match_def_path(cx, collect_def_id, method)) } -fn match_acceptable_type(cx: &LateContext<'_>, expr: &hir::Expr<'_>, msrv: Option) -> bool { +fn match_acceptable_type(cx: &LateContext<'_>, expr: &hir::Expr<'_>, msrv: &Msrv) -> bool { let expr_ty = cx.typeck_results().expr_ty(expr).peel_refs(); ACCEPTABLE_TYPES.iter().any(|(ty, acceptable_msrv)| { is_type_diagnostic_item(cx, expr_ty, *ty) - && acceptable_msrv.map_or(true, |acceptable_msrv| meets_msrv(msrv, acceptable_msrv)) + && acceptable_msrv.map_or(true, |acceptable_msrv| msrv.meets(acceptable_msrv)) }) } diff --git a/clippy_lints/src/manual_strip.rs b/clippy_lints/src/manual_strip.rs index 0976940afac..de166b9765f 100644 --- a/clippy_lints/src/manual_strip.rs +++ b/clippy_lints/src/manual_strip.rs @@ -1,8 +1,9 @@ use clippy_utils::consts::{constant, Constant}; use clippy_utils::diagnostics::{multispan_sugg, span_lint_and_then}; +use clippy_utils::msrvs::{self, Msrv}; use clippy_utils::source::snippet; use clippy_utils::usage::mutated_variables; -use clippy_utils::{eq_expr_value, higher, match_def_path, meets_msrv, msrvs, paths}; +use clippy_utils::{eq_expr_value, higher, match_def_path, paths}; use if_chain::if_chain; use rustc_ast::ast::LitKind; use rustc_hir::def::Res; @@ -11,7 +12,6 @@ use rustc_hir::BinOpKind; use rustc_hir::{BorrowKind, Expr, ExprKind}; use rustc_lint::{LateContext, LateLintPass}; use rustc_middle::ty; -use rustc_semver::RustcVersion; use rustc_session::{declare_tool_lint, impl_lint_pass}; use rustc_span::source_map::Spanned; use rustc_span::Span; @@ -48,12 +48,12 @@ declare_clippy_lint! { } pub struct ManualStrip { - msrv: Option, + msrv: Msrv, } impl ManualStrip { #[must_use] - pub fn new(msrv: Option) -> Self { + pub fn new(msrv: Msrv) -> Self { Self { msrv } } } @@ -68,7 +68,7 @@ enum StripKind { impl<'tcx> LateLintPass<'tcx> for ManualStrip { fn check_expr(&mut self, cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) { - if !meets_msrv(self.msrv, msrvs::STR_STRIP_PREFIX) { + if !self.msrv.meets(msrvs::STR_STRIP_PREFIX) { return; } diff --git a/clippy_lints/src/matches/mod.rs b/clippy_lints/src/matches/mod.rs index 7d8171ead89..7b15a307fec 100644 --- a/clippy_lints/src/matches/mod.rs +++ b/clippy_lints/src/matches/mod.rs @@ -23,13 +23,13 @@ mod single_match; mod try_err; mod wild_in_or_pats; +use clippy_utils::msrvs::{self, Msrv}; use clippy_utils::source::{snippet_opt, walk_span_to_context}; -use clippy_utils::{higher, in_constant, is_span_match, meets_msrv, msrvs}; +use clippy_utils::{higher, in_constant, is_span_match}; use rustc_hir::{Arm, Expr, ExprKind, Local, MatchSource, Pat}; use rustc_lexer::{tokenize, TokenKind}; use rustc_lint::{LateContext, LateLintPass, LintContext}; use rustc_middle::lint::in_external_macro; -use rustc_semver::RustcVersion; use rustc_session::{declare_tool_lint, impl_lint_pass}; use rustc_span::{Span, SpanData, SyntaxContext}; @@ -930,13 +930,13 @@ declare_clippy_lint! { #[derive(Default)] pub struct Matches { - msrv: Option, + msrv: Msrv, infallible_destructuring_match_linted: bool, } impl Matches { #[must_use] - pub fn new(msrv: Option) -> Self { + pub fn new(msrv: Msrv) -> Self { Self { msrv, ..Matches::default() @@ -1000,9 +1000,7 @@ impl<'tcx> LateLintPass<'tcx> for Matches { if !from_expansion && !contains_cfg_arm(cx, expr, ex, arms) { if source == MatchSource::Normal { - if !(meets_msrv(self.msrv, msrvs::MATCHES_MACRO) - && match_like_matches::check_match(cx, expr, ex, arms)) - { + if !(self.msrv.meets(msrvs::MATCHES_MACRO) && match_like_matches::check_match(cx, expr, ex, arms)) { match_same_arms::check(cx, arms); } @@ -1034,7 +1032,7 @@ impl<'tcx> LateLintPass<'tcx> for Matches { collapsible_match::check_if_let(cx, if_let.let_pat, if_let.if_then, if_let.if_else); if !from_expansion { if let Some(else_expr) = if_let.if_else { - if meets_msrv(self.msrv, msrvs::MATCHES_MACRO) { + if self.msrv.meets(msrvs::MATCHES_MACRO) { match_like_matches::check_if_let( cx, expr, diff --git a/clippy_lints/src/mem_replace.rs b/clippy_lints/src/mem_replace.rs index 0c4d9f100f7..35024ec1224 100644 --- a/clippy_lints/src/mem_replace.rs +++ b/clippy_lints/src/mem_replace.rs @@ -1,14 +1,14 @@ use clippy_utils::diagnostics::{span_lint_and_help, span_lint_and_sugg, span_lint_and_then}; +use clippy_utils::msrvs::{self, Msrv}; use clippy_utils::source::{snippet, snippet_with_applicability}; use clippy_utils::ty::is_non_aggregate_primitive_type; -use clippy_utils::{is_default_equivalent, is_res_lang_ctor, meets_msrv, msrvs, path_res}; +use clippy_utils::{is_default_equivalent, is_res_lang_ctor, path_res}; use if_chain::if_chain; use rustc_errors::Applicability; use rustc_hir::LangItem::OptionNone; use rustc_hir::{BorrowKind, Expr, ExprKind, Mutability, QPath}; use rustc_lint::{LateContext, LateLintPass}; use rustc_middle::lint::in_external_macro; -use rustc_semver::RustcVersion; use rustc_session::{declare_tool_lint, impl_lint_pass}; use rustc_span::source_map::Span; use rustc_span::symbol::sym; @@ -227,12 +227,12 @@ fn check_replace_with_default(cx: &LateContext<'_>, src: &Expr<'_>, dest: &Expr< } pub struct MemReplace { - msrv: Option, + msrv: Msrv, } impl MemReplace { #[must_use] - pub fn new(msrv: Option) -> Self { + pub fn new(msrv: Msrv) -> Self { Self { msrv } } } @@ -248,7 +248,7 @@ impl<'tcx> LateLintPass<'tcx> for MemReplace { then { check_replace_option_with_none(cx, src, dest, expr.span); check_replace_with_uninit(cx, src, dest, expr.span); - if meets_msrv(self.msrv, msrvs::MEM_TAKE) { + if self.msrv.meets(msrvs::MEM_TAKE) { check_replace_with_default(cx, src, dest, expr.span); } } diff --git a/clippy_lints/src/methods/cloned_instead_of_copied.rs b/clippy_lints/src/methods/cloned_instead_of_copied.rs index e9aeab2d5b6..4e6ec61f6a8 100644 --- a/clippy_lints/src/methods/cloned_instead_of_copied.rs +++ b/clippy_lints/src/methods/cloned_instead_of_copied.rs @@ -1,25 +1,25 @@ use clippy_utils::diagnostics::span_lint_and_sugg; +use clippy_utils::is_trait_method; +use clippy_utils::msrvs::{self, Msrv}; use clippy_utils::ty::{get_iterator_item_ty, is_copy}; -use clippy_utils::{is_trait_method, meets_msrv, msrvs}; use rustc_errors::Applicability; use rustc_hir::Expr; use rustc_lint::LateContext; use rustc_middle::ty; -use rustc_semver::RustcVersion; use rustc_span::{sym, Span}; use super::CLONED_INSTEAD_OF_COPIED; -pub fn check(cx: &LateContext<'_>, expr: &Expr<'_>, recv: &Expr<'_>, span: Span, msrv: Option) { +pub fn check(cx: &LateContext<'_>, expr: &Expr<'_>, recv: &Expr<'_>, span: Span, msrv: &Msrv) { let recv_ty = cx.typeck_results().expr_ty_adjusted(recv); let inner_ty = match recv_ty.kind() { // `Option` -> `T` ty::Adt(adt, subst) - if cx.tcx.is_diagnostic_item(sym::Option, adt.did()) && meets_msrv(msrv, msrvs::OPTION_COPIED) => + if cx.tcx.is_diagnostic_item(sym::Option, adt.did()) && msrv.meets(msrvs::OPTION_COPIED) => { subst.type_at(0) }, - _ if is_trait_method(cx, expr, sym::Iterator) && meets_msrv(msrv, msrvs::ITERATOR_COPIED) => { + _ if is_trait_method(cx, expr, sym::Iterator) && msrv.meets(msrvs::ITERATOR_COPIED) => { match get_iterator_item_ty(cx, recv_ty) { // ::Item Some(ty) => ty, diff --git a/clippy_lints/src/methods/err_expect.rs b/clippy_lints/src/methods/err_expect.rs index 720d9a68c85..ae03da0d3f9 100644 --- a/clippy_lints/src/methods/err_expect.rs +++ b/clippy_lints/src/methods/err_expect.rs @@ -1,27 +1,27 @@ use super::ERR_EXPECT; use clippy_utils::diagnostics::span_lint_and_sugg; +use clippy_utils::msrvs::{self, Msrv}; use clippy_utils::ty::has_debug_impl; -use clippy_utils::{meets_msrv, msrvs, ty::is_type_diagnostic_item}; +use clippy_utils::ty::is_type_diagnostic_item; use rustc_errors::Applicability; use rustc_lint::LateContext; use rustc_middle::ty; use rustc_middle::ty::Ty; -use rustc_semver::RustcVersion; use rustc_span::{sym, Span}; pub(super) fn check( cx: &LateContext<'_>, _expr: &rustc_hir::Expr<'_>, recv: &rustc_hir::Expr<'_>, - msrv: Option, expect_span: Span, err_span: Span, + msrv: &Msrv, ) { if_chain! { if is_type_diagnostic_item(cx, cx.typeck_results().expr_ty(recv), sym::Result); // Test the version to make sure the lint can be showed (expect_err has been // introduced in rust 1.17.0 : https://github.com/rust-lang/rust/pull/38982) - if meets_msrv(msrv, msrvs::EXPECT_ERR); + if msrv.meets(msrvs::EXPECT_ERR); // Grabs the `Result` type let result_type = cx.typeck_results().expr_ty(recv); diff --git a/clippy_lints/src/methods/filter_map_next.rs b/clippy_lints/src/methods/filter_map_next.rs index ddf8a1f09b8..175e04f8ac0 100644 --- a/clippy_lints/src/methods/filter_map_next.rs +++ b/clippy_lints/src/methods/filter_map_next.rs @@ -1,10 +1,10 @@ use clippy_utils::diagnostics::{span_lint, span_lint_and_sugg}; +use clippy_utils::is_trait_method; +use clippy_utils::msrvs::{self, Msrv}; use clippy_utils::source::snippet; -use clippy_utils::{is_trait_method, meets_msrv, msrvs}; use rustc_errors::Applicability; use rustc_hir as hir; use rustc_lint::LateContext; -use rustc_semver::RustcVersion; use rustc_span::sym; use super::FILTER_MAP_NEXT; @@ -14,10 +14,10 @@ pub(super) fn check<'tcx>( expr: &'tcx hir::Expr<'_>, recv: &'tcx hir::Expr<'_>, arg: &'tcx hir::Expr<'_>, - msrv: Option, + msrv: &Msrv, ) { if is_trait_method(cx, expr, sym::Iterator) { - if !meets_msrv(msrv, msrvs::ITERATOR_FIND_MAP) { + if !msrv.meets(msrvs::ITERATOR_FIND_MAP) { return; } diff --git a/clippy_lints/src/methods/is_digit_ascii_radix.rs b/clippy_lints/src/methods/is_digit_ascii_radix.rs index 304024e8066..301aff5ae6a 100644 --- a/clippy_lints/src/methods/is_digit_ascii_radix.rs +++ b/clippy_lints/src/methods/is_digit_ascii_radix.rs @@ -1,23 +1,22 @@ //! Lint for `c.is_digit(10)` use super::IS_DIGIT_ASCII_RADIX; +use clippy_utils::msrvs::{self, Msrv}; use clippy_utils::{ - consts::constant_full_int, consts::FullInt, diagnostics::span_lint_and_sugg, meets_msrv, msrvs, - source::snippet_with_applicability, + consts::constant_full_int, consts::FullInt, diagnostics::span_lint_and_sugg, source::snippet_with_applicability, }; use rustc_errors::Applicability; use rustc_hir::Expr; use rustc_lint::LateContext; -use rustc_semver::RustcVersion; pub(super) fn check<'tcx>( cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>, self_arg: &'tcx Expr<'_>, radix: &'tcx Expr<'_>, - msrv: Option, + msrv: &Msrv, ) { - if !meets_msrv(msrv, msrvs::IS_ASCII_DIGIT) { + if !msrv.meets(msrvs::IS_ASCII_DIGIT) { return; } diff --git a/clippy_lints/src/methods/map_clone.rs b/clippy_lints/src/methods/map_clone.rs index 6bc783c6d50..52cc1e0464b 100644 --- a/clippy_lints/src/methods/map_clone.rs +++ b/clippy_lints/src/methods/map_clone.rs @@ -1,7 +1,8 @@ use clippy_utils::diagnostics::span_lint_and_sugg; +use clippy_utils::msrvs::{self, Msrv}; use clippy_utils::source::snippet_with_applicability; use clippy_utils::ty::{is_copy, is_type_diagnostic_item}; -use clippy_utils::{is_diag_trait_item, meets_msrv, msrvs, peel_blocks}; +use clippy_utils::{is_diag_trait_item, peel_blocks}; use if_chain::if_chain; use rustc_errors::Applicability; use rustc_hir as hir; @@ -9,19 +10,12 @@ use rustc_lint::LateContext; use rustc_middle::mir::Mutability; use rustc_middle::ty; use rustc_middle::ty::adjustment::Adjust; -use rustc_semver::RustcVersion; use rustc_span::symbol::Ident; use rustc_span::{sym, Span}; use super::MAP_CLONE; -pub(super) fn check( - cx: &LateContext<'_>, - e: &hir::Expr<'_>, - recv: &hir::Expr<'_>, - arg: &hir::Expr<'_>, - msrv: Option, -) { +pub(super) fn check(cx: &LateContext<'_>, e: &hir::Expr<'_>, recv: &hir::Expr<'_>, arg: &hir::Expr<'_>, msrv: &Msrv) { if_chain! { if let Some(method_id) = cx.typeck_results().type_dependent_def_id(e.hir_id); if cx.tcx.impl_of_method(method_id) @@ -97,10 +91,10 @@ fn lint_needless_cloning(cx: &LateContext<'_>, root: Span, receiver: Span) { ); } -fn lint_explicit_closure(cx: &LateContext<'_>, replace: Span, root: Span, is_copy: bool, msrv: Option) { +fn lint_explicit_closure(cx: &LateContext<'_>, replace: Span, root: Span, is_copy: bool, msrv: &Msrv) { let mut applicability = Applicability::MachineApplicable; - let (message, sugg_method) = if is_copy && meets_msrv(msrv, msrvs::ITERATOR_COPIED) { + let (message, sugg_method) = if is_copy && msrv.meets(msrvs::ITERATOR_COPIED) { ("you are using an explicit closure for copying elements", "copied") } else { ("you are using an explicit closure for cloning elements", "cloned") diff --git a/clippy_lints/src/methods/map_unwrap_or.rs b/clippy_lints/src/methods/map_unwrap_or.rs index 74fdead216b..3122f72ee91 100644 --- a/clippy_lints/src/methods/map_unwrap_or.rs +++ b/clippy_lints/src/methods/map_unwrap_or.rs @@ -1,12 +1,11 @@ use clippy_utils::diagnostics::{span_lint, span_lint_and_sugg}; +use clippy_utils::msrvs::{self, Msrv}; use clippy_utils::source::snippet; use clippy_utils::ty::is_type_diagnostic_item; use clippy_utils::usage::mutated_variables; -use clippy_utils::{meets_msrv, msrvs}; use rustc_errors::Applicability; use rustc_hir as hir; use rustc_lint::LateContext; -use rustc_semver::RustcVersion; use rustc_span::symbol::sym; use super::MAP_UNWRAP_OR; @@ -19,13 +18,13 @@ pub(super) fn check<'tcx>( recv: &'tcx hir::Expr<'_>, map_arg: &'tcx hir::Expr<'_>, unwrap_arg: &'tcx hir::Expr<'_>, - msrv: Option, + msrv: &Msrv, ) -> bool { // lint if the caller of `map()` is an `Option` let is_option = is_type_diagnostic_item(cx, cx.typeck_results().expr_ty(recv), sym::Option); let is_result = is_type_diagnostic_item(cx, cx.typeck_results().expr_ty(recv), sym::Result); - if is_result && !meets_msrv(msrv, msrvs::RESULT_MAP_OR_ELSE) { + if is_result && !msrv.meets(msrvs::RESULT_MAP_OR_ELSE) { return false; } diff --git a/clippy_lints/src/methods/mod.rs b/clippy_lints/src/methods/mod.rs index acb3b20a61b..c5451195727 100644 --- a/clippy_lints/src/methods/mod.rs +++ b/clippy_lints/src/methods/mod.rs @@ -104,8 +104,9 @@ mod zst_offset; use bind_instead_of_map::BindInsteadOfMap; use clippy_utils::consts::{constant, Constant}; use clippy_utils::diagnostics::{span_lint, span_lint_and_help}; +use clippy_utils::msrvs::{self, Msrv}; use clippy_utils::ty::{contains_ty_adt_constructor_opaque, implements_trait, is_copy, is_type_diagnostic_item}; -use clippy_utils::{contains_return, is_bool, is_trait_method, iter_input_pats, meets_msrv, msrvs, return_ty}; +use clippy_utils::{contains_return, is_bool, is_trait_method, iter_input_pats, return_ty}; use if_chain::if_chain; use rustc_hir as hir; use rustc_hir::{Expr, ExprKind, TraitItem, TraitItemKind}; @@ -113,7 +114,6 @@ use rustc_hir_analysis::hir_ty_to_ty; use rustc_lint::{LateContext, LateLintPass, LintContext}; use rustc_middle::lint::in_external_macro; use rustc_middle::ty::{self, TraitRef, Ty}; -use rustc_semver::RustcVersion; use rustc_session::{declare_tool_lint, impl_lint_pass}; use rustc_span::{sym, Span}; @@ -3163,7 +3163,7 @@ declare_clippy_lint! { pub struct Methods { avoid_breaking_exported_api: bool, - msrv: Option, + msrv: Msrv, allow_expect_in_tests: bool, allow_unwrap_in_tests: bool, } @@ -3172,7 +3172,7 @@ impl Methods { #[must_use] pub fn new( avoid_breaking_exported_api: bool, - msrv: Option, + msrv: Msrv, allow_expect_in_tests: bool, allow_unwrap_in_tests: bool, ) -> Self { @@ -3325,7 +3325,7 @@ impl<'tcx> LateLintPass<'tcx> for Methods { single_char_add_str::check(cx, expr, receiver, args); into_iter_on_ref::check(cx, expr, method_span, method_call.ident.name, receiver); single_char_pattern::check(cx, expr, method_call.ident.name, receiver, args); - unnecessary_to_owned::check(cx, expr, method_call.ident.name, receiver, args, self.msrv); + unnecessary_to_owned::check(cx, expr, method_call.ident.name, receiver, args, &self.msrv); }, hir::ExprKind::Binary(op, lhs, rhs) if op.node == hir::BinOpKind::Eq || op.node == hir::BinOpKind::Ne => { let mut info = BinaryExprInfo { @@ -3501,7 +3501,7 @@ impl Methods { ("as_mut", []) => useless_asref::check(cx, expr, "as_mut", recv), ("as_ref", []) => useless_asref::check(cx, expr, "as_ref", recv), ("assume_init", []) => uninit_assumed_init::check(cx, expr, recv), - ("cloned", []) => cloned_instead_of_copied::check(cx, expr, recv, span, self.msrv), + ("cloned", []) => cloned_instead_of_copied::check(cx, expr, recv, span, &self.msrv), ("collect", []) if is_trait_method(cx, expr, sym::Iterator) => { needless_collect::check(cx, span, expr, recv, call_span); match method_call(recv) { @@ -3512,7 +3512,7 @@ impl Methods { map_collect_result_unit::check(cx, expr, m_recv, m_arg); }, Some(("take", take_self_arg, [take_arg], _, _)) => { - if meets_msrv(self.msrv, msrvs::STR_REPEAT) { + if self.msrv.meets(msrvs::STR_REPEAT) { manual_str_repeat::check(cx, expr, recv, take_self_arg, take_arg); } }, @@ -3539,7 +3539,7 @@ impl Methods { }, ("expect", [_]) => match method_call(recv) { Some(("ok", recv, [], _, _)) => ok_expect::check(cx, expr, recv), - Some(("err", recv, [], err_span, _)) => err_expect::check(cx, expr, recv, self.msrv, span, err_span), + Some(("err", recv, [], err_span, _)) => err_expect::check(cx, expr, recv, span, err_span, &self.msrv), _ => expect_used::check(cx, expr, recv, false, self.allow_expect_in_tests), }, ("expect_err", [_]) => expect_used::check(cx, expr, recv, true, self.allow_expect_in_tests), @@ -3578,7 +3578,7 @@ impl Methods { unit_hash::check(cx, expr, recv, arg); }, ("is_file", []) => filetype_is_file::check(cx, expr, recv), - ("is_digit", [radix]) => is_digit_ascii_radix::check(cx, expr, recv, radix, self.msrv), + ("is_digit", [radix]) => is_digit_ascii_radix::check(cx, expr, recv, radix, &self.msrv), ("is_none", []) => check_is_some_is_none(cx, expr, recv, false), ("is_some", []) => check_is_some_is_none(cx, expr, recv, true), ("iter" | "iter_mut" | "into_iter", []) => { @@ -3601,7 +3601,7 @@ impl Methods { }, (name @ ("map" | "map_err"), [m_arg]) => { if name == "map" { - map_clone::check(cx, expr, recv, m_arg, self.msrv); + map_clone::check(cx, expr, recv, m_arg, &self.msrv); if let Some((map_name @ ("iter" | "into_iter"), recv2, _, _, _)) = method_call(recv) { iter_kv_map::check(cx, map_name, expr, recv2, m_arg); } @@ -3610,8 +3610,8 @@ impl Methods { } if let Some((name, recv2, args, span2,_)) = method_call(recv) { match (name, args) { - ("as_mut", []) => option_as_ref_deref::check(cx, expr, recv2, m_arg, true, self.msrv), - ("as_ref", []) => option_as_ref_deref::check(cx, expr, recv2, m_arg, false, self.msrv), + ("as_mut", []) => option_as_ref_deref::check(cx, expr, recv2, m_arg, true, &self.msrv), + ("as_ref", []) => option_as_ref_deref::check(cx, expr, recv2, m_arg, false, &self.msrv), ("filter", [f_arg]) => { filter_map::check(cx, expr, recv2, f_arg, span2, recv, m_arg, span, false); }, @@ -3632,7 +3632,7 @@ impl Methods { match (name2, args2) { ("cloned", []) => iter_overeager_cloned::check(cx, expr, recv, recv2, false, false), ("filter", [arg]) => filter_next::check(cx, expr, recv2, arg), - ("filter_map", [arg]) => filter_map_next::check(cx, expr, recv2, arg, self.msrv), + ("filter_map", [arg]) => filter_map_next::check(cx, expr, recv2, arg, &self.msrv), ("iter", []) => iter_next_slice::check(cx, expr, recv2), ("skip", [arg]) => iter_skip_next::check(cx, expr, recv2, arg), ("skip_while", [_]) => skip_while_next::check(cx, expr), @@ -3680,10 +3680,10 @@ impl Methods { vec_resize_to_zero::check(cx, expr, count_arg, default_arg, span); }, ("seek", [arg]) => { - if meets_msrv(self.msrv, msrvs::SEEK_FROM_CURRENT) { + if self.msrv.meets(msrvs::SEEK_FROM_CURRENT) { seek_from_current::check(cx, expr, recv, arg); } - if meets_msrv(self.msrv, msrvs::SEEK_REWIND) { + if self.msrv.meets(msrvs::SEEK_REWIND) { seek_to_start_instead_of_rewind::check(cx, expr, recv, arg, span); } }, @@ -3699,7 +3699,7 @@ impl Methods { ("splitn" | "rsplitn", [count_arg, pat_arg]) => { if let Some((Constant::Int(count), _)) = constant(cx, cx.typeck_results(), count_arg) { suspicious_splitn::check(cx, name, expr, recv, count); - str_splitn::check(cx, name, expr, recv, pat_arg, count, self.msrv); + str_splitn::check(cx, name, expr, recv, pat_arg, count, &self.msrv); } }, ("splitn_mut" | "rsplitn_mut", [count_arg, _]) => { @@ -3717,7 +3717,7 @@ impl Methods { }, ("take", []) => needless_option_take::check(cx, expr, recv), ("then", [arg]) => { - if !meets_msrv(self.msrv, msrvs::BOOL_THEN_SOME) { + if !self.msrv.meets(msrvs::BOOL_THEN_SOME) { return; } unnecessary_lazy_eval::check(cx, expr, recv, arg, "then_some"); @@ -3760,7 +3760,7 @@ impl Methods { }, ("unwrap_or_else", [u_arg]) => match method_call(recv) { Some(("map", recv, [map_arg], _, _)) - if map_unwrap_or::check(cx, expr, recv, map_arg, u_arg, self.msrv) => {}, + if map_unwrap_or::check(cx, expr, recv, map_arg, u_arg, &self.msrv) => {}, _ => { unwrap_or_else_default::check(cx, expr, recv, u_arg); unnecessary_lazy_eval::check(cx, expr, recv, u_arg, "unwrap_or"); diff --git a/clippy_lints/src/methods/option_as_ref_deref.rs b/clippy_lints/src/methods/option_as_ref_deref.rs index e6eb64bcbde..3e33f919337 100644 --- a/clippy_lints/src/methods/option_as_ref_deref.rs +++ b/clippy_lints/src/methods/option_as_ref_deref.rs @@ -1,13 +1,13 @@ use clippy_utils::diagnostics::span_lint_and_sugg; +use clippy_utils::msrvs::{self, Msrv}; use clippy_utils::source::snippet; use clippy_utils::ty::is_type_diagnostic_item; -use clippy_utils::{match_def_path, meets_msrv, msrvs, path_to_local_id, paths, peel_blocks}; +use clippy_utils::{match_def_path, path_to_local_id, paths, peel_blocks}; use if_chain::if_chain; use rustc_errors::Applicability; use rustc_hir as hir; use rustc_lint::LateContext; use rustc_middle::ty; -use rustc_semver::RustcVersion; use rustc_span::sym; use super::OPTION_AS_REF_DEREF; @@ -19,9 +19,9 @@ pub(super) fn check( as_ref_recv: &hir::Expr<'_>, map_arg: &hir::Expr<'_>, is_mut: bool, - msrv: Option, + msrv: &Msrv, ) { - if !meets_msrv(msrv, msrvs::OPTION_AS_DEREF) { + if !msrv.meets(msrvs::OPTION_AS_DEREF) { return; } diff --git a/clippy_lints/src/methods/str_splitn.rs b/clippy_lints/src/methods/str_splitn.rs index 1acac59144c..3c01ce1fecd 100644 --- a/clippy_lints/src/methods/str_splitn.rs +++ b/clippy_lints/src/methods/str_splitn.rs @@ -1,9 +1,10 @@ use clippy_utils::consts::{constant, Constant}; use clippy_utils::diagnostics::{span_lint_and_sugg, span_lint_and_then}; +use clippy_utils::msrvs::{self, Msrv}; use clippy_utils::source::snippet_with_context; use clippy_utils::usage::local_used_after_expr; use clippy_utils::visitors::{for_each_expr_with_closures, Descend}; -use clippy_utils::{is_diag_item_method, match_def_path, meets_msrv, msrvs, path_to_local_id, paths}; +use clippy_utils::{is_diag_item_method, match_def_path, path_to_local_id, paths}; use core::ops::ControlFlow; use if_chain::if_chain; use rustc_errors::Applicability; @@ -12,7 +13,6 @@ use rustc_hir::{ }; use rustc_lint::LateContext; use rustc_middle::ty; -use rustc_semver::RustcVersion; use rustc_span::{sym, Span, Symbol, SyntaxContext}; use super::{MANUAL_SPLIT_ONCE, NEEDLESS_SPLITN}; @@ -24,7 +24,7 @@ pub(super) fn check( self_arg: &Expr<'_>, pat_arg: &Expr<'_>, count: u128, - msrv: Option, + msrv: &Msrv, ) { if count < 2 || !cx.typeck_results().expr_ty_adjusted(self_arg).peel_refs().is_str() { return; @@ -34,7 +34,7 @@ pub(super) fn check( IterUsageKind::Nth(n) => count > n + 1, IterUsageKind::NextTuple => count > 2, }; - let manual = count == 2 && meets_msrv(msrv, msrvs::STR_SPLIT_ONCE); + let manual = count == 2 && msrv.meets(msrvs::STR_SPLIT_ONCE); match parse_iter_usage(cx, expr.span.ctxt(), cx.tcx.hir().parent_iter(expr.hir_id)) { Some(usage) if needless(usage.kind) => lint_needless(cx, method_name, expr, self_arg, pat_arg), diff --git a/clippy_lints/src/methods/unnecessary_to_owned.rs b/clippy_lints/src/methods/unnecessary_to_owned.rs index 4b4f2f47b1d..21d1df4d0c2 100644 --- a/clippy_lints/src/methods/unnecessary_to_owned.rs +++ b/clippy_lints/src/methods/unnecessary_to_owned.rs @@ -1,11 +1,11 @@ use super::implicit_clone::is_clone_like; use super::unnecessary_iter_cloned::{self, is_into_iter}; use clippy_utils::diagnostics::span_lint_and_sugg; +use clippy_utils::msrvs::{self, Msrv}; use clippy_utils::source::snippet_opt; use clippy_utils::ty::{get_associated_type, get_iterator_item_ty, implements_trait, is_copy, peel_mid_ty_refs}; use clippy_utils::visitors::find_all_ret_expressions; use clippy_utils::{fn_def_id, get_parent_expr, is_diag_item_method, is_diag_trait_item, return_ty}; -use clippy_utils::{meets_msrv, msrvs}; use rustc_errors::Applicability; use rustc_hir::{def_id::DefId, BorrowKind, Expr, ExprKind, ItemKind, LangItem, Node}; use rustc_hir_analysis::check::{FnCtxt, Inherited}; @@ -16,7 +16,6 @@ use rustc_middle::ty::adjustment::{Adjust, Adjustment, OverloadedDeref}; use rustc_middle::ty::subst::{GenericArg, GenericArgKind, SubstsRef}; use rustc_middle::ty::EarlyBinder; use rustc_middle::ty::{self, ParamTy, PredicateKind, ProjectionPredicate, TraitPredicate, Ty}; -use rustc_semver::RustcVersion; use rustc_span::{sym, Symbol}; use rustc_trait_selection::traits::{query::evaluate_obligation::InferCtxtExt as _, Obligation, ObligationCause}; use std::cmp::max; @@ -29,7 +28,7 @@ pub fn check<'tcx>( method_name: Symbol, receiver: &'tcx Expr<'_>, args: &'tcx [Expr<'_>], - msrv: Option, + msrv: &Msrv, ) { if_chain! { if let Some(method_def_id) = cx.typeck_results().type_dependent_def_id(expr.hir_id); @@ -200,7 +199,7 @@ fn check_into_iter_call_arg( expr: &Expr<'_>, method_name: Symbol, receiver: &Expr<'_>, - msrv: Option, + msrv: &Msrv, ) -> bool { if_chain! { if let Some(parent) = get_parent_expr(cx, expr); @@ -215,7 +214,7 @@ fn check_into_iter_call_arg( if unnecessary_iter_cloned::check_for_loop_iter(cx, parent, method_name, receiver, true) { return true; } - let cloned_or_copied = if is_copy(cx, item_ty) && meets_msrv(msrv, msrvs::ITERATOR_COPIED) { + let cloned_or_copied = if is_copy(cx, item_ty) && msrv.meets(msrvs::ITERATOR_COPIED) { "copied" } else { "cloned" diff --git a/clippy_lints/src/missing_const_for_fn.rs b/clippy_lints/src/missing_const_for_fn.rs index 71cc0d0a81c..5bc04bc17fb 100644 --- a/clippy_lints/src/missing_const_for_fn.rs +++ b/clippy_lints/src/missing_const_for_fn.rs @@ -1,9 +1,8 @@ use clippy_utils::diagnostics::span_lint; +use clippy_utils::msrvs::{self, Msrv}; use clippy_utils::qualify_min_const_fn::is_min_const_fn; use clippy_utils::ty::has_drop; -use clippy_utils::{ - fn_has_unsatisfiable_preds, is_entrypoint_fn, is_from_proc_macro, meets_msrv, msrvs, trait_ref_of_method, -}; +use clippy_utils::{fn_has_unsatisfiable_preds, is_entrypoint_fn, is_from_proc_macro, trait_ref_of_method}; use rustc_hir as hir; use rustc_hir::def_id::CRATE_DEF_ID; use rustc_hir::intravisit::FnKind; @@ -11,7 +10,6 @@ use rustc_hir::{Body, Constness, FnDecl, GenericParamKind, HirId}; use rustc_hir_analysis::hir_ty_to_ty; use rustc_lint::{LateContext, LateLintPass}; use rustc_middle::lint::in_external_macro; -use rustc_semver::RustcVersion; use rustc_session::{declare_tool_lint, impl_lint_pass}; use rustc_span::Span; @@ -75,12 +73,12 @@ declare_clippy_lint! { impl_lint_pass!(MissingConstForFn => [MISSING_CONST_FOR_FN]); pub struct MissingConstForFn { - msrv: Option, + msrv: Msrv, } impl MissingConstForFn { #[must_use] - pub fn new(msrv: Option) -> Self { + pub fn new(msrv: Msrv) -> Self { Self { msrv } } } @@ -95,7 +93,7 @@ impl<'tcx> LateLintPass<'tcx> for MissingConstForFn { span: Span, hir_id: HirId, ) { - if !meets_msrv(self.msrv, msrvs::CONST_IF_MATCH) { + if !self.msrv.meets(msrvs::CONST_IF_MATCH) { return; } @@ -152,7 +150,7 @@ impl<'tcx> LateLintPass<'tcx> for MissingConstForFn { let mir = cx.tcx.optimized_mir(def_id); - if let Err((span, err)) = is_min_const_fn(cx.tcx, mir, self.msrv) { + if let Err((span, err)) = is_min_const_fn(cx.tcx, mir, &self.msrv) { if cx.tcx.is_const_fn_raw(def_id.to_def_id()) { cx.tcx.sess.span_err(span, err.as_ref()); } diff --git a/clippy_lints/src/ranges.rs b/clippy_lints/src/ranges.rs index c6fbb5e805a..0a1b9d173cf 100644 --- a/clippy_lints/src/ranges.rs +++ b/clippy_lints/src/ranges.rs @@ -1,16 +1,16 @@ use clippy_utils::consts::{constant, Constant}; use clippy_utils::diagnostics::{span_lint, span_lint_and_sugg, span_lint_and_then}; use clippy_utils::higher; +use clippy_utils::msrvs::{self, Msrv}; use clippy_utils::source::{snippet, snippet_opt, snippet_with_applicability}; use clippy_utils::sugg::Sugg; -use clippy_utils::{get_parent_expr, in_constant, is_integer_const, meets_msrv, msrvs, path_to_local}; +use clippy_utils::{get_parent_expr, in_constant, is_integer_const, path_to_local}; use if_chain::if_chain; use rustc_ast::ast::RangeLimits; use rustc_errors::Applicability; use rustc_hir::{BinOpKind, Expr, ExprKind, HirId}; use rustc_lint::{LateContext, LateLintPass}; use rustc_middle::ty; -use rustc_semver::RustcVersion; use rustc_session::{declare_tool_lint, impl_lint_pass}; use rustc_span::source_map::{Span, Spanned}; use std::cmp::Ordering; @@ -161,12 +161,12 @@ declare_clippy_lint! { } pub struct Ranges { - msrv: Option, + msrv: Msrv, } impl Ranges { #[must_use] - pub fn new(msrv: Option) -> Self { + pub fn new(msrv: Msrv) -> Self { Self { msrv } } } @@ -181,7 +181,7 @@ impl_lint_pass!(Ranges => [ impl<'tcx> LateLintPass<'tcx> for Ranges { fn check_expr(&mut self, cx: &LateContext<'tcx>, expr: &'tcx Expr<'_>) { if let ExprKind::Binary(ref op, l, r) = expr.kind { - if meets_msrv(self.msrv, msrvs::RANGE_CONTAINS) { + if self.msrv.meets(msrvs::RANGE_CONTAINS) { check_possible_range_contains(cx, op.node, l, r, expr, expr.span); } } diff --git a/clippy_lints/src/redundant_field_names.rs b/clippy_lints/src/redundant_field_names.rs index 40b03068f6c..61bff4a0e38 100644 --- a/clippy_lints/src/redundant_field_names.rs +++ b/clippy_lints/src/redundant_field_names.rs @@ -1,10 +1,9 @@ use clippy_utils::diagnostics::span_lint_and_sugg; -use clippy_utils::{meets_msrv, msrvs}; +use clippy_utils::msrvs::{self, Msrv}; use rustc_ast::ast::{Expr, ExprKind}; use rustc_errors::Applicability; use rustc_lint::{EarlyContext, EarlyLintPass, LintContext}; use rustc_middle::lint::in_external_macro; -use rustc_semver::RustcVersion; use rustc_session::{declare_tool_lint, impl_lint_pass}; declare_clippy_lint! { @@ -37,12 +36,12 @@ declare_clippy_lint! { } pub struct RedundantFieldNames { - msrv: Option, + msrv: Msrv, } impl RedundantFieldNames { #[must_use] - pub fn new(msrv: Option) -> Self { + pub fn new(msrv: Msrv) -> Self { Self { msrv } } } @@ -51,7 +50,7 @@ impl_lint_pass!(RedundantFieldNames => [REDUNDANT_FIELD_NAMES]); impl EarlyLintPass for RedundantFieldNames { fn check_expr(&mut self, cx: &EarlyContext<'_>, expr: &Expr) { - if !meets_msrv(self.msrv, msrvs::FIELD_INIT_SHORTHAND) { + if !self.msrv.meets(msrvs::FIELD_INIT_SHORTHAND) { return; } diff --git a/clippy_lints/src/redundant_static_lifetimes.rs b/clippy_lints/src/redundant_static_lifetimes.rs index 60ba62c4a43..3aa2490bc44 100644 --- a/clippy_lints/src/redundant_static_lifetimes.rs +++ b/clippy_lints/src/redundant_static_lifetimes.rs @@ -1,10 +1,9 @@ use clippy_utils::diagnostics::span_lint_and_then; +use clippy_utils::msrvs::{self, Msrv}; use clippy_utils::source::snippet; -use clippy_utils::{meets_msrv, msrvs}; use rustc_ast::ast::{Item, ItemKind, Ty, TyKind}; use rustc_errors::Applicability; use rustc_lint::{EarlyContext, EarlyLintPass}; -use rustc_semver::RustcVersion; use rustc_session::{declare_tool_lint, impl_lint_pass}; declare_clippy_lint! { @@ -34,12 +33,12 @@ declare_clippy_lint! { } pub struct RedundantStaticLifetimes { - msrv: Option, + msrv: Msrv, } impl RedundantStaticLifetimes { #[must_use] - pub fn new(msrv: Option) -> Self { + pub fn new(msrv: Msrv) -> Self { Self { msrv } } } @@ -96,7 +95,7 @@ impl RedundantStaticLifetimes { impl EarlyLintPass for RedundantStaticLifetimes { fn check_item(&mut self, cx: &EarlyContext<'_>, item: &Item) { - if !meets_msrv(self.msrv, msrvs::STATIC_IN_CONST) { + if !self.msrv.meets(msrvs::STATIC_IN_CONST) { return; } diff --git a/clippy_lints/src/transmute/mod.rs b/clippy_lints/src/transmute/mod.rs index 424a6e9264e..83e651aba8e 100644 --- a/clippy_lints/src/transmute/mod.rs +++ b/clippy_lints/src/transmute/mod.rs @@ -16,10 +16,10 @@ mod utils; mod wrong_transmute; use clippy_utils::in_constant; +use clippy_utils::msrvs::Msrv; use if_chain::if_chain; use rustc_hir::{Expr, ExprKind, QPath}; use rustc_lint::{LateContext, LateLintPass}; -use rustc_semver::RustcVersion; use rustc_session::{declare_tool_lint, impl_lint_pass}; use rustc_span::symbol::sym; @@ -410,7 +410,7 @@ declare_clippy_lint! { } pub struct Transmute { - msrv: Option, + msrv: Msrv, } impl_lint_pass!(Transmute => [ CROSSPOINTER_TRANSMUTE, @@ -431,7 +431,7 @@ impl_lint_pass!(Transmute => [ ]); impl Transmute { #[must_use] - pub fn new(msrv: Option) -> Self { + pub fn new(msrv: Msrv) -> Self { Self { msrv } } } @@ -461,7 +461,7 @@ impl<'tcx> LateLintPass<'tcx> for Transmute { let linted = wrong_transmute::check(cx, e, from_ty, to_ty) | crosspointer_transmute::check(cx, e, from_ty, to_ty) | transmuting_null::check(cx, e, arg, to_ty) - | transmute_ptr_to_ref::check(cx, e, from_ty, to_ty, arg, path, self.msrv) + | transmute_ptr_to_ref::check(cx, e, from_ty, to_ty, arg, path, &self.msrv) | transmute_int_to_char::check(cx, e, from_ty, to_ty, arg, const_context) | transmute_ref_to_ref::check(cx, e, from_ty, to_ty, arg, const_context) | transmute_ptr_to_ptr::check(cx, e, from_ty, to_ty, arg) diff --git a/clippy_lints/src/transmute/transmute_ptr_to_ref.rs b/clippy_lints/src/transmute/transmute_ptr_to_ref.rs index 12d0b866e1c..3dde4eee671 100644 --- a/clippy_lints/src/transmute/transmute_ptr_to_ref.rs +++ b/clippy_lints/src/transmute/transmute_ptr_to_ref.rs @@ -1,12 +1,12 @@ use super::TRANSMUTE_PTR_TO_REF; use clippy_utils::diagnostics::span_lint_and_then; +use clippy_utils::msrvs::{self, Msrv}; use clippy_utils::source::snippet_with_applicability; -use clippy_utils::{meets_msrv, msrvs, sugg}; +use clippy_utils::sugg; use rustc_errors::Applicability; use rustc_hir::{self as hir, Expr, GenericArg, Mutability, Path, TyKind}; use rustc_lint::LateContext; use rustc_middle::ty::{self, Ty, TypeVisitable}; -use rustc_semver::RustcVersion; /// Checks for `transmute_ptr_to_ref` lint. /// Returns `true` if it's triggered, otherwise returns `false`. @@ -17,7 +17,7 @@ pub(super) fn check<'tcx>( to_ty: Ty<'tcx>, arg: &'tcx Expr<'_>, path: &'tcx Path<'_>, - msrv: Option, + msrv: &Msrv, ) -> bool { match (&from_ty.kind(), &to_ty.kind()) { (ty::RawPtr(from_ptr_ty), ty::Ref(_, to_ref_ty, mutbl)) => { @@ -37,7 +37,7 @@ pub(super) fn check<'tcx>( let sugg = if let Some(ty) = get_explicit_type(path) { let ty_snip = snippet_with_applicability(cx, ty.span, "..", &mut app); - if meets_msrv(msrv, msrvs::POINTER_CAST) { + if msrv.meets(msrvs::POINTER_CAST) { format!("{deref}{}.cast::<{ty_snip}>()", arg.maybe_par()) } else if from_ptr_ty.has_erased_regions() { sugg::make_unop(deref, arg.as_ty(format!("{cast} () as {cast} {ty_snip}"))).to_string() @@ -46,7 +46,7 @@ pub(super) fn check<'tcx>( } } else if from_ptr_ty.ty == *to_ref_ty { if from_ptr_ty.has_erased_regions() { - if meets_msrv(msrv, msrvs::POINTER_CAST) { + if msrv.meets(msrvs::POINTER_CAST) { format!("{deref}{}.cast::<{to_ref_ty}>()", arg.maybe_par()) } else { sugg::make_unop(deref, arg.as_ty(format!("{cast} () as {cast} {to_ref_ty}"))) diff --git a/clippy_lints/src/unnested_or_patterns.rs b/clippy_lints/src/unnested_or_patterns.rs index b305dae7608..2c2730267db 100644 --- a/clippy_lints/src/unnested_or_patterns.rs +++ b/clippy_lints/src/unnested_or_patterns.rs @@ -2,14 +2,14 @@ use clippy_utils::ast_utils::{eq_field_pat, eq_id, eq_maybe_qself, eq_pat, eq_path}; use clippy_utils::diagnostics::span_lint_and_then; -use clippy_utils::{meets_msrv, msrvs, over}; +use clippy_utils::msrvs::{self, Msrv}; +use clippy_utils::over; use rustc_ast::mut_visit::*; use rustc_ast::ptr::P; use rustc_ast::{self as ast, Mutability, Pat, PatKind, PatKind::*, DUMMY_NODE_ID}; use rustc_ast_pretty::pprust; use rustc_errors::Applicability; use rustc_lint::{EarlyContext, EarlyLintPass}; -use rustc_semver::RustcVersion; use rustc_session::{declare_tool_lint, impl_lint_pass}; use rustc_span::DUMMY_SP; @@ -45,14 +45,13 @@ declare_clippy_lint! { "unnested or-patterns, e.g., `Foo(Bar) | Foo(Baz) instead of `Foo(Bar | Baz)`" } -#[derive(Clone, Copy)] pub struct UnnestedOrPatterns { - msrv: Option, + msrv: Msrv, } impl UnnestedOrPatterns { #[must_use] - pub fn new(msrv: Option) -> Self { + pub fn new(msrv: Msrv) -> Self { Self { msrv } } } @@ -61,13 +60,13 @@ impl_lint_pass!(UnnestedOrPatterns => [UNNESTED_OR_PATTERNS]); impl EarlyLintPass for UnnestedOrPatterns { fn check_arm(&mut self, cx: &EarlyContext<'_>, a: &ast::Arm) { - if meets_msrv(self.msrv, msrvs::OR_PATTERNS) { + if self.msrv.meets(msrvs::OR_PATTERNS) { lint_unnested_or_patterns(cx, &a.pat); } } fn check_expr(&mut self, cx: &EarlyContext<'_>, e: &ast::Expr) { - if meets_msrv(self.msrv, msrvs::OR_PATTERNS) { + if self.msrv.meets(msrvs::OR_PATTERNS) { if let ast::ExprKind::Let(pat, _, _) = &e.kind { lint_unnested_or_patterns(cx, pat); } @@ -75,13 +74,13 @@ impl EarlyLintPass for UnnestedOrPatterns { } fn check_param(&mut self, cx: &EarlyContext<'_>, p: &ast::Param) { - if meets_msrv(self.msrv, msrvs::OR_PATTERNS) { + if self.msrv.meets(msrvs::OR_PATTERNS) { lint_unnested_or_patterns(cx, &p.pat); } } fn check_local(&mut self, cx: &EarlyContext<'_>, l: &ast::Local) { - if meets_msrv(self.msrv, msrvs::OR_PATTERNS) { + if self.msrv.meets(msrvs::OR_PATTERNS) { lint_unnested_or_patterns(cx, &l.pat); } } diff --git a/clippy_lints/src/use_self.rs b/clippy_lints/src/use_self.rs index 464ffdc0a2a..06975443d8f 100644 --- a/clippy_lints/src/use_self.rs +++ b/clippy_lints/src/use_self.rs @@ -1,6 +1,7 @@ use clippy_utils::diagnostics::span_lint_and_sugg; +use clippy_utils::is_from_proc_macro; +use clippy_utils::msrvs::{self, Msrv}; use clippy_utils::ty::same_type_and_consts; -use clippy_utils::{is_from_proc_macro, meets_msrv, msrvs}; use if_chain::if_chain; use rustc_data_structures::fx::FxHashSet; use rustc_errors::Applicability; @@ -14,7 +15,6 @@ use rustc_hir::{ }; use rustc_hir_analysis::hir_ty_to_ty; use rustc_lint::{LateContext, LateLintPass}; -use rustc_semver::RustcVersion; use rustc_session::{declare_tool_lint, impl_lint_pass}; use rustc_span::Span; @@ -57,13 +57,13 @@ declare_clippy_lint! { #[derive(Default)] pub struct UseSelf { - msrv: Option, + msrv: Msrv, stack: Vec, } impl UseSelf { #[must_use] - pub fn new(msrv: Option) -> Self { + pub fn new(msrv: Msrv) -> Self { Self { msrv, ..Self::default() @@ -199,7 +199,7 @@ impl<'tcx> LateLintPass<'tcx> for UseSelf { fn check_ty(&mut self, cx: &LateContext<'_>, hir_ty: &hir::Ty<'_>) { if_chain! { if !hir_ty.span.from_expansion(); - if meets_msrv(self.msrv, msrvs::TYPE_ALIAS_ENUM_VARIANTS); + if self.msrv.meets(msrvs::TYPE_ALIAS_ENUM_VARIANTS); if let Some(&StackItem::Check { impl_id, in_body, @@ -228,7 +228,7 @@ impl<'tcx> LateLintPass<'tcx> for UseSelf { fn check_expr(&mut self, cx: &LateContext<'_>, expr: &Expr<'_>) { if_chain! { if !expr.span.from_expansion(); - if meets_msrv(self.msrv, msrvs::TYPE_ALIAS_ENUM_VARIANTS); + if self.msrv.meets(msrvs::TYPE_ALIAS_ENUM_VARIANTS); if let Some(&StackItem::Check { impl_id, .. }) = self.stack.last(); if cx.typeck_results().expr_ty(expr) == cx.tcx.type_of(impl_id); then {} else { return; } @@ -248,7 +248,7 @@ impl<'tcx> LateLintPass<'tcx> for UseSelf { fn check_pat(&mut self, cx: &LateContext<'_>, pat: &Pat<'_>) { if_chain! { if !pat.span.from_expansion(); - if meets_msrv(self.msrv, msrvs::TYPE_ALIAS_ENUM_VARIANTS); + if self.msrv.meets(msrvs::TYPE_ALIAS_ENUM_VARIANTS); if let Some(&StackItem::Check { impl_id, .. }) = self.stack.last(); // get the path from the pattern if let PatKind::Path(QPath::Resolved(_, path)) diff --git a/clippy_lints/src/utils/internal_lints/msrv_attr_impl.rs b/clippy_lints/src/utils/internal_lints/msrv_attr_impl.rs index 1e994e3f2b1..9876a8a765c 100644 --- a/clippy_lints/src/utils/internal_lints/msrv_attr_impl.rs +++ b/clippy_lints/src/utils/internal_lints/msrv_attr_impl.rs @@ -41,7 +41,7 @@ impl LateLintPass<'_> for MsrvAttrImpl { .type_of(f.did) .walk() .filter(|t| matches!(t.unpack(), GenericArgKind::Type(_))) - .any(|t| match_type(cx, t.expect_ty(), &paths::RUSTC_VERSION)) + .any(|t| match_type(cx, t.expect_ty(), &paths::MSRV)) }); if !items.iter().any(|item| item.ident.name == sym!(enter_lint_attrs)); then { diff --git a/clippy_utils/src/lib.rs b/clippy_utils/src/lib.rs index b0063758dce..86ee172cb28 100644 --- a/clippy_utils/src/lib.rs +++ b/clippy_utils/src/lib.rs @@ -105,8 +105,6 @@ use rustc_middle::ty::{ layout::IntegerExt, BorrowKind, ClosureKind, DefIdTree, Ty, TyCtxt, TypeAndMut, TypeVisitable, UpvarCapture, }; use rustc_middle::ty::{FloatTy, IntTy, UintTy}; -use rustc_semver::RustcVersion; -use rustc_session::Session; use rustc_span::hygiene::{ExpnKind, MacroKind}; use rustc_span::source_map::SourceMap; use rustc_span::sym; @@ -118,36 +116,17 @@ use crate::consts::{constant, Constant}; use crate::ty::{can_partially_move_ty, expr_sig, is_copy, is_recursively_primitive_type, ty_is_fn_once_param}; use crate::visitors::for_each_expr; -pub fn parse_msrv(msrv: &str, sess: Option<&Session>, span: Option) -> Option { - if let Ok(version) = RustcVersion::parse(msrv) { - return Some(version); - } else if let Some(sess) = sess { - if let Some(span) = span { - sess.span_err(span, format!("`{msrv}` is not a valid Rust version")); - } - } - None -} - -pub fn meets_msrv(msrv: Option, lint_msrv: RustcVersion) -> bool { - msrv.map_or(true, |msrv| msrv.meets(lint_msrv)) -} - #[macro_export] macro_rules! extract_msrv_attr { ($context:ident) => { fn enter_lint_attrs(&mut self, cx: &rustc_lint::$context<'_>, attrs: &[rustc_ast::ast::Attribute]) { let sess = rustc_lint::LintContext::sess(cx); - match $crate::get_unique_inner_attr(sess, attrs, "msrv") { - Some(msrv_attr) => { - if let Some(msrv) = msrv_attr.value_str() { - self.msrv = $crate::parse_msrv(&msrv.to_string(), Some(sess), Some(msrv_attr.span)); - } else { - sess.span_err(msrv_attr.span, "bad clippy attribute"); - } - }, - _ => (), - } + self.msrv.enter_lint_attrs(sess, attrs); + } + + fn exit_lint_attrs(&mut self, cx: &rustc_lint::$context<'_>, attrs: &[rustc_ast::ast::Attribute]) { + let sess = rustc_lint::LintContext::sess(cx); + self.msrv.exit_lint_attrs(sess, attrs); } }; } diff --git a/clippy_utils/src/msrvs.rs b/clippy_utils/src/msrvs.rs index 79b19e6fb3e..2c9f75736e5 100644 --- a/clippy_utils/src/msrvs.rs +++ b/clippy_utils/src/msrvs.rs @@ -1,4 +1,11 @@ +use std::sync::OnceLock; + +use rustc_ast::Attribute; use rustc_semver::RustcVersion; +use rustc_session::Session; +use rustc_span::Span; + +use crate::attrs::get_unique_inner_attr; macro_rules! msrv_aliases { ($($major:literal,$minor:literal,$patch:literal { @@ -40,3 +47,97 @@ msrv_aliases! { 1,16,0 { STR_REPEAT } 1,55,0 { SEEK_REWIND } } + +fn parse_msrv(msrv: &str, sess: Option<&Session>, span: Option) -> Option { + if let Ok(version) = RustcVersion::parse(msrv) { + return Some(version); + } else if let Some(sess) = sess { + if let Some(span) = span { + sess.span_err(span, format!("`{msrv}` is not a valid Rust version")); + } + } + None +} + +/// Tracks the current MSRV from `clippy.toml`, `Cargo.toml` or set via `#[clippy::msrv]` +#[derive(Debug, Clone, Default)] +pub struct Msrv { + stack: Vec, +} + +impl Msrv { + fn new(initial: Option) -> Self { + Self { + stack: Vec::from_iter(initial), + } + } + + fn read_inner(conf_msrv: &Option, sess: &Session) -> Self { + let cargo_msrv = std::env::var("CARGO_PKG_RUST_VERSION") + .ok() + .and_then(|v| parse_msrv(&v, None, None)); + let clippy_msrv = conf_msrv.as_ref().and_then(|s| { + parse_msrv(s, None, None).or_else(|| { + sess.err(format!( + "error reading Clippy's configuration file. `{s}` is not a valid Rust version" + )); + None + }) + }); + + // if both files have an msrv, let's compare them and emit a warning if they differ + if let Some(cargo_msrv) = cargo_msrv + && let Some(clippy_msrv) = clippy_msrv + && clippy_msrv != cargo_msrv + { + sess.warn(format!( + "the MSRV in `clippy.toml` and `Cargo.toml` differ; using `{clippy_msrv}` from `clippy.toml`" + )); + } + + Self::new(clippy_msrv.or(cargo_msrv)) + } + + /// Set the initial MSRV from the Clippy config file or from Cargo due to the `rust-version` + /// field in `Cargo.toml` + /// + /// Returns a `&'static Msrv` as `Copy` types are more easily passed to the + /// `register_{late,early}_pass` callbacks + pub fn read(conf_msrv: &Option, sess: &Session) -> &'static Self { + static PARSED: OnceLock = OnceLock::new(); + + PARSED.get_or_init(|| Self::read_inner(conf_msrv, sess)) + } + + pub fn current(&self) -> Option { + self.stack.last().copied() + } + + pub fn meets(&self, required: RustcVersion) -> bool { + self.current().map_or(true, |version| version.meets(required)) + } + + fn parse_attr(sess: &Session, attrs: &[Attribute]) -> Option { + if let Some(msrv_attr) = get_unique_inner_attr(sess, attrs, "msrv") { + if let Some(msrv) = msrv_attr.value_str() { + return parse_msrv(&msrv.to_string(), Some(sess), Some(msrv_attr.span)); + } + + sess.span_err(msrv_attr.span, "bad clippy attribute"); + } + + None + } + + pub fn enter_lint_attrs(&mut self, sess: &Session, attrs: &[Attribute]) { + if let Some(version) = Self::parse_attr(sess, attrs) { + self.stack.push(version); + } + } + + pub fn exit_lint_attrs(&mut self, sess: &Session, attrs: &[Attribute]) { + if Self::parse_attr(sess, attrs).is_some() { + self.stack.pop(); + } + } +} diff --git a/clippy_utils/src/paths.rs b/clippy_utils/src/paths.rs index 6c09c146082..3cf8cb76651 100644 --- a/clippy_utils/src/paths.rs +++ b/clippy_utils/src/paths.rs @@ -60,6 +60,8 @@ pub const LATE_LINT_PASS: [&str; 3] = ["rustc_lint", "passes", "LateLintPass"]; #[cfg(feature = "internal")] pub const LINT: [&str; 2] = ["rustc_lint_defs", "Lint"]; pub const MEM_SWAP: [&str; 3] = ["core", "mem", "swap"]; +#[cfg(feature = "internal")] +pub const MSRV: [&str; 3] = ["clippy_utils", "msrvs", "Msrv"]; pub const OPEN_OPTIONS: [&str; 3] = ["std", "fs", "OpenOptions"]; pub const OS_STRING_AS_OS_STR: [&str; 5] = ["std", "ffi", "os_str", "OsString", "as_os_str"]; pub const OS_STR_TO_OS_STRING: [&str; 5] = ["std", "ffi", "os_str", "OsStr", "to_os_string"]; @@ -101,8 +103,6 @@ pub const REGEX_BYTES_NEW: [&str; 4] = ["regex", "re_bytes", "Regex", "new"]; pub const REGEX_BYTES_SET_NEW: [&str; 5] = ["regex", "re_set", "bytes", "RegexSet", "new"]; pub const REGEX_NEW: [&str; 4] = ["regex", "re_unicode", "Regex", "new"]; pub const REGEX_SET_NEW: [&str; 5] = ["regex", "re_set", "unicode", "RegexSet", "new"]; -#[cfg(feature = "internal")] -pub const RUSTC_VERSION: [&str; 2] = ["rustc_semver", "RustcVersion"]; pub const SERDE_DESERIALIZE: [&str; 3] = ["serde", "de", "Deserialize"]; pub const SERDE_DE_VISITOR: [&str; 3] = ["serde", "de", "Visitor"]; pub const SLICE_FROM_RAW_PARTS: [&str; 4] = ["core", "slice", "raw", "from_raw_parts"]; diff --git a/clippy_utils/src/qualify_min_const_fn.rs b/clippy_utils/src/qualify_min_const_fn.rs index 65722f142aa..0def1245615 100644 --- a/clippy_utils/src/qualify_min_const_fn.rs +++ b/clippy_utils/src/qualify_min_const_fn.rs @@ -3,6 +3,7 @@ // of terminologies might not be relevant in the context of Clippy. Note that its behavior might // differ from the time of `rustc` even if the name stays the same. +use crate::msrvs::Msrv; use rustc_hir as hir; use rustc_hir::def_id::DefId; use rustc_middle::mir::{ @@ -18,7 +19,7 @@ use std::borrow::Cow; type McfResult = Result<(), (Span, Cow<'static, str>)>; -pub fn is_min_const_fn<'tcx>(tcx: TyCtxt<'tcx>, body: &Body<'tcx>, msrv: Option) -> McfResult { +pub fn is_min_const_fn<'tcx>(tcx: TyCtxt<'tcx>, body: &Body<'tcx>, msrv: &Msrv) -> McfResult { let def_id = body.source.def_id(); let mut current = def_id; loop { @@ -280,7 +281,7 @@ fn check_terminator<'tcx>( tcx: TyCtxt<'tcx>, body: &Body<'tcx>, terminator: &Terminator<'tcx>, - msrv: Option, + msrv: &Msrv, ) -> McfResult { let span = terminator.source_info.span; match &terminator.kind { @@ -364,7 +365,7 @@ fn check_terminator<'tcx>( } } -fn is_const_fn(tcx: TyCtxt<'_>, def_id: DefId, msrv: Option) -> bool { +fn is_const_fn(tcx: TyCtxt<'_>, def_id: DefId, msrv: &Msrv) -> bool { tcx.is_const_fn(def_id) && tcx.lookup_const_stability(def_id).map_or(true, |const_stab| { if let rustc_attr::StabilityLevel::Stable { since, .. } = const_stab.level { @@ -383,15 +384,12 @@ fn is_const_fn(tcx: TyCtxt<'_>, def_id: DefId, msrv: Option) -> bo let since = rustc_span::Symbol::intern(short_version); - crate::meets_msrv( - msrv, - RustcVersion::parse(since.as_str()).unwrap_or_else(|err| { - panic!("`rustc_attr::StabilityLevel::Stable::since` is ill-formatted: `{since}`, {err:?}") - }), - ) + msrv.meets(RustcVersion::parse(since.as_str()).unwrap_or_else(|err| { + panic!("`rustc_attr::StabilityLevel::Stable::since` is ill-formatted: `{since}`, {err:?}") + })) } else { // Unstable const fn with the feature enabled. - msrv.is_none() + msrv.current().is_none() } }) } diff --git a/tests/ui-internal/invalid_msrv_attr_impl.fixed b/tests/ui-internal/invalid_msrv_attr_impl.fixed index 900a8fffd40..08634063a57 100644 --- a/tests/ui-internal/invalid_msrv_attr_impl.fixed +++ b/tests/ui-internal/invalid_msrv_attr_impl.fixed @@ -11,9 +11,9 @@ extern crate rustc_middle; #[macro_use] extern crate rustc_session; use clippy_utils::extract_msrv_attr; +use clippy_utils::msrvs::Msrv; use rustc_hir::Expr; use rustc_lint::{EarlyContext, EarlyLintPass, LateContext, LateLintPass}; -use rustc_semver::RustcVersion; declare_lint! { pub TEST_LINT, @@ -22,7 +22,7 @@ declare_lint! { } struct Pass { - msrv: Option, + msrv: Msrv, } impl_lint_pass!(Pass => [TEST_LINT]); diff --git a/tests/ui-internal/invalid_msrv_attr_impl.rs b/tests/ui-internal/invalid_msrv_attr_impl.rs index 4bc8164db67..f8af77e6d39 100644 --- a/tests/ui-internal/invalid_msrv_attr_impl.rs +++ b/tests/ui-internal/invalid_msrv_attr_impl.rs @@ -11,9 +11,9 @@ extern crate rustc_middle; #[macro_use] extern crate rustc_session; use clippy_utils::extract_msrv_attr; +use clippy_utils::msrvs::Msrv; use rustc_hir::Expr; use rustc_lint::{EarlyContext, EarlyLintPass, LateContext, LateLintPass}; -use rustc_semver::RustcVersion; declare_lint! { pub TEST_LINT, @@ -22,7 +22,7 @@ declare_lint! { } struct Pass { - msrv: Option, + msrv: Msrv, } impl_lint_pass!(Pass => [TEST_LINT]); diff --git a/tests/ui/min_rust_version_attr.rs b/tests/ui/min_rust_version_attr.rs index cd148063bf0..28ab132394b 100644 --- a/tests/ui/min_rust_version_attr.rs +++ b/tests/ui/min_rust_version_attr.rs @@ -27,3 +27,26 @@ fn no_patch_meets() { #![clippy::msrv = "1.43"] let log2_10 = 3.321928094887362; } + +// https://github.com/rust-lang/rust-clippy/issues/6920 +fn scoping() { + mod m { + #![clippy::msrv = "1.42.0"] + } + + // Should warn + let log2_10 = 3.321928094887362; + + mod a { + #![clippy::msrv = "1.42.0"] + + fn should_warn() { + #![clippy::msrv = "1.43.0"] + let log2_10 = 3.321928094887362; + } + + fn should_not_warn() { + let log2_10 = 3.321928094887362; + } + } +} diff --git a/tests/ui/min_rust_version_attr.stderr b/tests/ui/min_rust_version_attr.stderr index 68aa5874819..6174443372f 100644 --- a/tests/ui/min_rust_version_attr.stderr +++ b/tests/ui/min_rust_version_attr.stderr @@ -23,5 +23,21 @@ LL | let log2_10 = 3.321928094887362; | = help: consider using the constant directly -error: aborting due to 3 previous errors +error: approximate value of `f{32, 64}::consts::LOG2_10` found + --> $DIR/min_rust_version_attr.rs:38:19 + | +LL | let log2_10 = 3.321928094887362; + | ^^^^^^^^^^^^^^^^^ + | + = help: consider using the constant directly + +error: approximate value of `f{32, 64}::consts::LOG2_10` found + --> $DIR/min_rust_version_attr.rs:45:27 + | +LL | let log2_10 = 3.321928094887362; + | ^^^^^^^^^^^^^^^^^ + | + = help: consider using the constant directly + +error: aborting due to 5 previous errors -- cgit 1.4.1-3-g733a5 From ef2596155d8659b9546af9af6360e0ffd6ffa5a2 Mon Sep 17 00:00:00 2001 From: KaDiWa Date: Tue, 31 Jan 2023 23:23:37 +0100 Subject: update some dependencies --- Cargo.toml | 2 +- clippy_dev/Cargo.toml | 2 +- clippy_dev/src/main.rs | 99 +++++++++++++++++++++++++++---------------------- clippy_lints/Cargo.toml | 2 +- lintcheck/Cargo.toml | 4 +- 5 files changed, 60 insertions(+), 49 deletions(-) (limited to 'clippy_dev/src') diff --git a/Cargo.toml b/Cargo.toml index dc94b104524..70d1268090f 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -42,7 +42,7 @@ filetime = "0.2" rustc-workspace-hack = "1.0" # UI test dependencies -clap = { version = "3.1", features = ["derive"] } +clap = { version = "4.1.4", features = ["derive"] } clippy_utils = { path = "clippy_utils" } derive-new = "0.5" if_chain = "1.0" diff --git a/clippy_dev/Cargo.toml b/clippy_dev/Cargo.toml index 510c7e852af..c3f8a782d27 100644 --- a/clippy_dev/Cargo.toml +++ b/clippy_dev/Cargo.toml @@ -5,7 +5,7 @@ edition = "2021" [dependencies] aho-corasick = "0.7" -clap = "3.2" +clap = "4.1.4" indoc = "1.0" itertools = "0.10.1" opener = "0.5" diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index d3e03669204..b2d67a72fd2 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -2,7 +2,7 @@ // warn on lints, that are included in `rust-lang/rust`s bootstrap #![warn(rust_2018_idioms, unused_lifetimes)] -use clap::{Arg, ArgAction, ArgMatches, Command, PossibleValue}; +use clap::{Arg, ArgAction, ArgMatches, Command}; use clippy_dev::{bless, dogfood, fmt, lint, new_lint, serve, setup, update_lints}; use indoc::indoc; @@ -110,24 +110,37 @@ fn get_clap_config() -> ArgMatches { Command::new("bless").about("bless the test output changes").arg( Arg::new("ignore-timestamp") .long("ignore-timestamp") + .action(ArgAction::SetTrue) .help("Include files updated before clippy was built"), ), Command::new("dogfood").about("Runs the dogfood test").args([ - Arg::new("fix").long("fix").help("Apply the suggestions when possible"), + Arg::new("fix") + .long("fix") + .action(ArgAction::SetTrue) + .help("Apply the suggestions when possible"), Arg::new("allow-dirty") .long("allow-dirty") + .action(ArgAction::SetTrue) .help("Fix code even if the working directory has changes") .requires("fix"), Arg::new("allow-staged") .long("allow-staged") + .action(ArgAction::SetTrue) .help("Fix code even if the working directory has staged changes") .requires("fix"), ]), Command::new("fmt") .about("Run rustfmt on all projects and tests") .args([ - Arg::new("check").long("check").help("Use the rustfmt --check option"), - Arg::new("verbose").short('v').long("verbose").help("Echo commands run"), + Arg::new("check") + .long("check") + .action(ArgAction::SetTrue) + .help("Use the rustfmt --check option"), + Arg::new("verbose") + .short('v') + .long("verbose") + .action(ArgAction::SetTrue) + .help("Echo commands run"), ]), Command::new("update_lints") .about("Updates lint registration and information from the source code") @@ -140,13 +153,17 @@ fn get_clap_config() -> ArgMatches { * all lints are registered in the lint store", ) .args([ - Arg::new("print-only").long("print-only").help( - "Print a table of lints to STDOUT. \ - This does not include deprecated and internal lints. \ - (Does not modify any files)", - ), + Arg::new("print-only") + .long("print-only") + .action(ArgAction::SetTrue) + .help( + "Print a table of lints to STDOUT. \ + This does not include deprecated and internal lints. \ + (Does not modify any files)", + ), Arg::new("check") .long("check") + .action(ArgAction::SetTrue) .help("Checks that `cargo dev update_lints` has been run. Used on CI."), ]), Command::new("new_lint") @@ -156,15 +173,13 @@ fn get_clap_config() -> ArgMatches { .short('p') .long("pass") .help("Specify whether the lint runs during the early or late pass") - .takes_value(true) - .value_parser([PossibleValue::new("early"), PossibleValue::new("late")]) + .value_parser(["early", "late"]) .conflicts_with("type") .required_unless_present("type"), Arg::new("name") .short('n') .long("name") .help("Name of the new lint in snake case, ex: fn_too_long") - .takes_value(true) .required(true), Arg::new("category") .short('c') @@ -172,25 +187,23 @@ fn get_clap_config() -> ArgMatches { .help("What category the lint belongs to") .default_value("nursery") .value_parser([ - PossibleValue::new("style"), - PossibleValue::new("correctness"), - PossibleValue::new("suspicious"), - PossibleValue::new("complexity"), - PossibleValue::new("perf"), - PossibleValue::new("pedantic"), - PossibleValue::new("restriction"), - PossibleValue::new("cargo"), - PossibleValue::new("nursery"), - PossibleValue::new("internal"), - PossibleValue::new("internal_warn"), - ]) - .takes_value(true), - Arg::new("type") - .long("type") - .help("What directory the lint belongs in") - .takes_value(true) - .required(false), - Arg::new("msrv").long("msrv").help("Add MSRV config code to the lint"), + "style", + "correctness", + "suspicious", + "complexity", + "perf", + "pedantic", + "restriction", + "cargo", + "nursery", + "internal", + "internal_warn", + ]), + Arg::new("type").long("type").help("What directory the lint belongs in"), + Arg::new("msrv") + .long("msrv") + .action(ArgAction::SetTrue) + .help("Add MSRV config code to the lint"), ]), Command::new("setup") .about("Support for setting up your personal development environment") @@ -201,13 +214,12 @@ fn get_clap_config() -> ArgMatches { .args([ Arg::new("remove") .long("remove") - .help("Remove the dependencies added with 'cargo dev setup intellij'") - .required(false), + .action(ArgAction::SetTrue) + .help("Remove the dependencies added with 'cargo dev setup intellij'"), Arg::new("rustc-repo-path") .long("repo-path") .short('r') .help("The path to a rustc repo that will be used for setting the dependencies") - .takes_value(true) .value_name("path") .conflicts_with("remove") .required(true), @@ -217,26 +229,26 @@ fn get_clap_config() -> ArgMatches { .args([ Arg::new("remove") .long("remove") - .help("Remove the pre-commit hook added with 'cargo dev setup git-hook'") - .required(false), + .action(ArgAction::SetTrue) + .help("Remove the pre-commit hook added with 'cargo dev setup git-hook'"), Arg::new("force-override") .long("force-override") .short('f') - .help("Forces the override of an existing git pre-commit hook") - .required(false), + .action(ArgAction::SetTrue) + .help("Forces the override of an existing git pre-commit hook"), ]), Command::new("vscode-tasks") .about("Add several tasks to vscode for formatting, validation and testing") .args([ Arg::new("remove") .long("remove") - .help("Remove the tasks added with 'cargo dev setup vscode-tasks'") - .required(false), + .action(ArgAction::SetTrue) + .help("Remove the tasks added with 'cargo dev setup vscode-tasks'"), Arg::new("force-override") .long("force-override") .short('f') - .help("Forces the override of existing vscode tasks") - .required(false), + .action(ArgAction::SetTrue) + .help("Forces the override of existing vscode tasks"), ]), ]), Command::new("remove") @@ -295,6 +307,7 @@ fn get_clap_config() -> ArgMatches { .help("The new name of the lint"), Arg::new("uplift") .long("uplift") + .action(ArgAction::SetTrue) .help("This lint will be uplifted into rustc"), ]), Command::new("deprecate").about("Deprecates the given lint").args([ @@ -305,8 +318,6 @@ fn get_clap_config() -> ArgMatches { Arg::new("reason") .long("reason") .short('r') - .required(false) - .takes_value(true) .help("The reason for deprecation"), ]), ]) diff --git a/clippy_lints/Cargo.toml b/clippy_lints/Cargo.toml index 7278ad13d56..989e4d3fa56 100644 --- a/clippy_lints/Cargo.toml +++ b/clippy_lints/Cargo.toml @@ -9,7 +9,7 @@ keywords = ["clippy", "lint", "plugin"] edition = "2021" [dependencies] -cargo_metadata = "0.14" +cargo_metadata = "0.15.3" clippy_utils = { path = "../clippy_utils" } declare_clippy_lint = { path = "../declare_clippy_lint" } if_chain = "1.0" diff --git a/lintcheck/Cargo.toml b/lintcheck/Cargo.toml index de31c16b819..653121af54d 100644 --- a/lintcheck/Cargo.toml +++ b/lintcheck/Cargo.toml @@ -10,8 +10,8 @@ edition = "2021" publish = false [dependencies] -cargo_metadata = "0.14" -clap = "3.2" +cargo_metadata = "0.15.3" +clap = "4.1.4" crossbeam-channel = "0.5.6" flate2 = "1.0" rayon = "1.5.1" -- cgit 1.4.1-3-g733a5 From fabada0c816de9bc2780afad3a1f1bcf50159b08 Mon Sep 17 00:00:00 2001 From: Philipp Krones Date: Fri, 10 Feb 2023 11:38:56 +0100 Subject: Fix CLI of clippy_dev Clap was updated in rust-lang/rust-clippy#10270, which broke the command line of clippy_dev. This swaps out contains_id, which now returns always true in the places it was used with get_flag. --- clippy_dev/src/main.rs | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index b2d67a72fd2..e2457e5a8a5 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -11,22 +11,22 @@ fn main() { match matches.subcommand() { Some(("bless", matches)) => { - bless::bless(matches.contains_id("ignore-timestamp")); + bless::bless(matches.get_flag("ignore-timestamp")); }, Some(("dogfood", matches)) => { dogfood::dogfood( - matches.contains_id("fix"), - matches.contains_id("allow-dirty"), - matches.contains_id("allow-staged"), + matches.get_flag("fix"), + matches.get_flag("allow-dirty"), + matches.get_flag("allow-staged"), ); }, Some(("fmt", matches)) => { - fmt::run(matches.contains_id("check"), matches.contains_id("verbose")); + fmt::run(matches.get_flag("check"), matches.get_flag("verbose")); }, Some(("update_lints", matches)) => { - if matches.contains_id("print-only") { + if matches.get_flag("print-only") { update_lints::print_lints(); - } else if matches.contains_id("check") { + } else if matches.get_flag("check") { update_lints::update(update_lints::UpdateMode::Check); } else { update_lints::update(update_lints::UpdateMode::Change); @@ -38,7 +38,7 @@ fn main() { matches.get_one::("name"), matches.get_one::("category").map(String::as_str), matches.get_one::("type").map(String::as_str), - matches.contains_id("msrv"), + matches.get_flag("msrv"), ) { Ok(_) => update_lints::update(update_lints::UpdateMode::Change), Err(e) => eprintln!("Unable to create lint: {e}"), @@ -46,7 +46,7 @@ fn main() { }, Some(("setup", sub_command)) => match sub_command.subcommand() { Some(("intellij", matches)) => { - if matches.contains_id("remove") { + if matches.get_flag("remove") { setup::intellij::remove_rustc_src(); } else { setup::intellij::setup_rustc_src( @@ -57,17 +57,17 @@ fn main() { } }, Some(("git-hook", matches)) => { - if matches.contains_id("remove") { + if matches.get_flag("remove") { setup::git_hook::remove_hook(); } else { - setup::git_hook::install_hook(matches.contains_id("force-override")); + setup::git_hook::install_hook(matches.get_flag("force-override")); } }, Some(("vscode-tasks", matches)) => { - if matches.contains_id("remove") { + if matches.get_flag("remove") { setup::vscode::remove_tasks(); } else { - setup::vscode::install_tasks(matches.contains_id("force-override")); + setup::vscode::install_tasks(matches.get_flag("force-override")); } }, _ => {}, @@ -91,7 +91,7 @@ fn main() { Some(("rename_lint", matches)) => { let old_name = matches.get_one::("old_name").unwrap(); let new_name = matches.get_one::("new_name").unwrap_or(old_name); - let uplift = matches.contains_id("uplift"); + let uplift = matches.get_flag("uplift"); update_lints::rename(old_name, new_name, uplift); }, Some(("deprecate", matches)) => { -- cgit 1.4.1-3-g733a5 From 0b1ae20365f4363fdc5462fae3b3a3bd8ee214e6 Mon Sep 17 00:00:00 2001 From: Jirka Vebr Date: Thu, 16 Feb 2023 13:29:38 +0100 Subject: Fix dogfood tests by adding type annotations --- clippy_dev/src/new_lint.rs | 9 +++++---- clippy_dev/src/update_lints.rs | 6 +++--- clippy_lints/src/entry.rs | 8 ++++---- clippy_lints/src/inconsistent_struct_constructor.rs | 4 ++-- clippy_lints/src/literal_representation.rs | 2 +- clippy_lints/src/module_style.rs | 2 +- clippy_utils/src/numeric_literal.rs | 2 +- clippy_utils/src/sugg.rs | 8 ++++---- lintcheck/src/main.rs | 12 ++++++------ 9 files changed, 27 insertions(+), 26 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/new_lint.rs b/clippy_dev/src/new_lint.rs index ec7f1dd0d84..420214d9256 100644 --- a/clippy_dev/src/new_lint.rs +++ b/clippy_dev/src/new_lint.rs @@ -1,5 +1,6 @@ use crate::clippy_project_root; use indoc::{formatdoc, writedoc}; +use std::fmt; use std::fmt::Write as _; use std::fs::{self, OpenOptions}; use std::io::prelude::*; @@ -256,7 +257,7 @@ fn get_lint_file_contents(lint: &LintData<'_>, enable_msrv: bool) -> String { ) }); - let _ = write!(result, "{}", get_lint_declaration(&name_upper, category)); + let _: fmt::Result = write!(result, "{}", get_lint_declaration(&name_upper, category)); result.push_str(&if enable_msrv { formatdoc!( @@ -353,7 +354,7 @@ fn create_lint_for_ty(lint: &LintData<'_>, enable_msrv: bool, ty: &str) -> io::R let mut lint_file_contents = String::new(); if enable_msrv { - let _ = writedoc!( + let _: fmt::Result = writedoc!( lint_file_contents, r#" use clippy_utils::msrvs::{{self, Msrv}}; @@ -373,7 +374,7 @@ fn create_lint_for_ty(lint: &LintData<'_>, enable_msrv: bool, ty: &str) -> io::R name_upper = name_upper, ); } else { - let _ = writedoc!( + let _: fmt::Result = writedoc!( lint_file_contents, r#" use rustc_lint::{{{context_import}, LintContext}}; @@ -521,7 +522,7 @@ fn setup_mod_file(path: &Path, lint: &LintData<'_>) -> io::Result<&'static str> .chain(std::iter::once(&*lint_name_upper)) .filter(|s| !s.is_empty()) { - let _ = write!(new_arr_content, "\n {ident},"); + let _: fmt::Result = write!(new_arr_content, "\n {ident},"); } new_arr_content.push('\n'); diff --git a/clippy_dev/src/update_lints.rs b/clippy_dev/src/update_lints.rs index 837618c9294..779e4d0e1e3 100644 --- a/clippy_dev/src/update_lints.rs +++ b/clippy_dev/src/update_lints.rs @@ -5,7 +5,7 @@ use itertools::Itertools; use rustc_lexer::{tokenize, unescape, LiteralKind, TokenKind}; use std::collections::{HashMap, HashSet}; use std::ffi::OsStr; -use std::fmt::Write; +use std::fmt::{self, Write}; use std::fs::{self, OpenOptions}; use std::io::{self, Read, Seek, SeekFrom, Write as _}; use std::ops::Range; @@ -691,7 +691,7 @@ fn gen_deprecated(lints: &[DeprecatedLint]) -> String { let mut output = GENERATED_FILE_COMMENT.to_string(); output.push_str("{\n"); for lint in lints { - let _ = write!( + let _: fmt::Result = write!( output, concat!( " store.register_removed(\n", @@ -726,7 +726,7 @@ fn gen_declared_lints<'a>( if !is_public { output.push_str(" #[cfg(feature = \"internal\")]\n"); } - let _ = writeln!(output, " crate::{module_name}::{lint_name}_INFO,"); + let _: fmt::Result = writeln!(output, " crate::{module_name}::{lint_name}_INFO,"); } output.push_str("];\n"); diff --git a/clippy_lints/src/entry.rs b/clippy_lints/src/entry.rs index ed9d94cdec3..48a54f60253 100644 --- a/clippy_lints/src/entry.rs +++ b/clippy_lints/src/entry.rs @@ -6,7 +6,7 @@ use clippy_utils::{ source::{reindent_multiline, snippet_indent, snippet_with_applicability, snippet_with_context}, SpanlessEq, }; -use core::fmt::Write; +use core::fmt::{self, Write}; use rustc_errors::Applicability; use rustc_hir::{ hir_id::HirIdSet, @@ -536,7 +536,7 @@ impl<'tcx> InsertSearchResults<'tcx> { if is_expr_used_or_unified(cx.tcx, insertion.call) { write_wrapped(&mut res, insertion, ctxt, app); } else { - let _ = write!( + let _: fmt::Result = write!( res, "e.insert({})", snippet_with_context(cx, insertion.value.span, ctxt, "..", app).0 @@ -552,7 +552,7 @@ impl<'tcx> InsertSearchResults<'tcx> { ( self.snippet(cx, span, app, |res, insertion, ctxt, app| { // Insertion into a map would return `Some(&mut value)`, but the entry returns `&mut value` - let _ = write!( + let _: fmt::Result = write!( res, "Some(e.insert({}))", snippet_with_context(cx, insertion.value.span, ctxt, "..", app).0 @@ -566,7 +566,7 @@ impl<'tcx> InsertSearchResults<'tcx> { ( self.snippet(cx, span, app, |res, insertion, ctxt, app| { // Insertion into a map would return `None`, but the entry returns a mutable reference. - let _ = if is_expr_final_block_expr(cx.tcx, insertion.call) { + let _: fmt::Result = if is_expr_final_block_expr(cx.tcx, insertion.call) { write!( res, "e.insert({});\n{}None", diff --git a/clippy_lints/src/inconsistent_struct_constructor.rs b/clippy_lints/src/inconsistent_struct_constructor.rs index e2f2d3d42e6..1ad886f2cf3 100644 --- a/clippy_lints/src/inconsistent_struct_constructor.rs +++ b/clippy_lints/src/inconsistent_struct_constructor.rs @@ -7,7 +7,7 @@ use rustc_hir::{self as hir, ExprKind}; use rustc_lint::{LateContext, LateLintPass}; use rustc_session::{declare_lint_pass, declare_tool_lint}; use rustc_span::symbol::Symbol; -use std::fmt::Write as _; +use std::fmt::{self, Write as _}; declare_clippy_lint! { /// ### What it does @@ -90,7 +90,7 @@ impl<'tcx> LateLintPass<'tcx> for InconsistentStructConstructor { let mut fields_snippet = String::new(); let (last_ident, idents) = ordered_fields.split_last().unwrap(); for ident in idents { - let _ = write!(fields_snippet, "{ident}, "); + let _: fmt::Result = write!(fields_snippet, "{ident}, "); } fields_snippet.push_str(&last_ident.to_string()); diff --git a/clippy_lints/src/literal_representation.rs b/clippy_lints/src/literal_representation.rs index 3a7b7835c99..8097627c869 100644 --- a/clippy_lints/src/literal_representation.rs +++ b/clippy_lints/src/literal_representation.rs @@ -484,7 +484,7 @@ impl DecimalLiteralRepresentation { then { let hex = format!("{val:#X}"); let num_lit = NumericLiteral::new(&hex, num_lit.suffix, false); - let _ = Self::do_lint(num_lit.integer).map_err(|warning_type| { + let _: Result<(), ()> = Self::do_lint(num_lit.integer).map_err(|warning_type| { warning_type.display(num_lit.format(), cx, span); }); } diff --git a/clippy_lints/src/module_style.rs b/clippy_lints/src/module_style.rs index 0742943dff2..349fcd2274d 100644 --- a/clippy_lints/src/module_style.rs +++ b/clippy_lints/src/module_style.rs @@ -134,7 +134,7 @@ fn process_paths_for_mod_files<'a>( mod_folders: &mut FxHashSet<&'a OsStr>, ) { let mut comp = path.components().rev().peekable(); - let _ = comp.next(); + let _: Option<_> = comp.next(); if path.ends_with("mod.rs") { mod_folders.insert(comp.peek().map(|c| c.as_os_str()).unwrap_or_default()); } diff --git a/clippy_utils/src/numeric_literal.rs b/clippy_utils/src/numeric_literal.rs index 42bdfd4827f..c225398ad2a 100644 --- a/clippy_utils/src/numeric_literal.rs +++ b/clippy_utils/src/numeric_literal.rs @@ -186,7 +186,7 @@ impl<'a> NumericLiteral<'a> { // The exponent may have a sign, output it early, otherwise it will be // treated as a digit if digits.clone().next() == Some('-') { - let _ = digits.next(); + let _: Option = digits.next(); output.push('-'); } diff --git a/clippy_utils/src/sugg.rs b/clippy_utils/src/sugg.rs index 78fb2e0eb7e..51e270d330c 100644 --- a/clippy_utils/src/sugg.rs +++ b/clippy_utils/src/sugg.rs @@ -20,7 +20,7 @@ use rustc_middle::mir::{FakeReadCause, Mutability}; use rustc_middle::ty; use rustc_span::source_map::{BytePos, CharPos, Pos, Span, SyntaxContext}; use std::borrow::Cow; -use std::fmt::{Display, Write as _}; +use std::fmt::{self, Display, Write as _}; use std::ops::{Add, Neg, Not, Sub}; /// A helper type to build suggestion correctly handling parentheses. @@ -932,7 +932,7 @@ impl<'tcx> Delegate<'tcx> for DerefDelegate<'_, 'tcx> { if cmt.place.projections.is_empty() { // handle item without any projection, that needs an explicit borrowing // i.e.: suggest `&x` instead of `x` - let _ = write!(self.suggestion_start, "{start_snip}&{ident_str}"); + let _: fmt::Result = write!(self.suggestion_start, "{start_snip}&{ident_str}"); } else { // cases where a parent `Call` or `MethodCall` is using the item // i.e.: suggest `.contains(&x)` for `.find(|x| [1, 2, 3].contains(x)).is_none()` @@ -947,7 +947,7 @@ impl<'tcx> Delegate<'tcx> for DerefDelegate<'_, 'tcx> { // given expression is the self argument and will be handled completely by the compiler // i.e.: `|x| x.is_something()` ExprKind::MethodCall(_, self_expr, ..) if self_expr.hir_id == cmt.hir_id => { - let _ = write!(self.suggestion_start, "{start_snip}{ident_str_with_proj}"); + let _: fmt::Result = write!(self.suggestion_start, "{start_snip}{ident_str_with_proj}"); self.next_pos = span.hi(); return; }, @@ -1055,7 +1055,7 @@ impl<'tcx> Delegate<'tcx> for DerefDelegate<'_, 'tcx> { } } - let _ = write!(self.suggestion_start, "{start_snip}{replacement_str}"); + let _: fmt::Result = write!(self.suggestion_start, "{start_snip}{replacement_str}"); } self.next_pos = span.hi(); } diff --git a/lintcheck/src/main.rs b/lintcheck/src/main.rs index bd49f096072..23c85298027 100644 --- a/lintcheck/src/main.rs +++ b/lintcheck/src/main.rs @@ -17,9 +17,9 @@ use crate::recursive::LintcheckServer; use std::collections::{HashMap, HashSet}; use std::env; use std::env::consts::EXE_SUFFIX; -use std::fmt::Write as _; +use std::fmt::{self, Write as _}; use std::fs; -use std::io::ErrorKind; +use std::io::{self, ErrorKind}; use std::path::{Path, PathBuf}; use std::process::Command; use std::sync::atomic::{AtomicUsize, Ordering}; @@ -145,8 +145,8 @@ impl ClippyWarning { } let mut output = String::from("| "); - let _ = write!(output, "[`{file_with_pos}`]({file}#L{})", self.line); - let _ = write!(output, r#" | `{:<50}` | "{}" |"#, self.lint_type, self.message); + let _: fmt::Result = write!(output, "[`{file_with_pos}`]({file}#L{})", self.line); + let _: fmt::Result = write!(output, r#" | `{:<50}` | "{}" |"#, self.lint_type, self.message); output.push('\n'); output } else { @@ -632,7 +632,7 @@ fn main() { .unwrap(); let server = config.recursive.then(|| { - let _ = fs::remove_dir_all("target/lintcheck/shared_target_dir/recursive"); + let _: io::Result<()> = fs::remove_dir_all("target/lintcheck/shared_target_dir/recursive"); LintcheckServer::spawn(recursive_options) }); @@ -689,7 +689,7 @@ fn main() { write!(text, "{}", all_msgs.join("")).unwrap(); text.push_str("\n\n### ICEs:\n"); for (cratename, msg) in &ices { - let _ = write!(text, "{cratename}: '{msg}'"); + let _: fmt::Result = write!(text, "{cratename}: '{msg}'"); } println!("Writing logs to {}", config.lintcheck_results_path.display()); -- cgit 1.4.1-3-g733a5 From 783879e6fe48b5bd776bf2b1c9314fda3e30447d Mon Sep 17 00:00:00 2001 From: Yuri Astrakhan Date: Tue, 28 Mar 2023 20:52:55 -0400 Subject: Partial no-op refactoring of #9948 This contains preparatory work for #9948 to keep that change to the minimum, and make it easier to review it. --- clippy_dev/src/new_lint.rs | 8 +--- clippy_dev/src/update_lints.rs | 14 ++---- tests/ui/format_args_unfixable.rs | 44 ++++++++++++++++++ tests/ui/format_args_unfixable.stderr | 36 +++++++-------- tests/ui/uninlined_format_args.fixed | 86 ++++++++++++++++++++++++++++++++++- tests/ui/uninlined_format_args.rs | 86 ++++++++++++++++++++++++++++++++++- 6 files changed, 239 insertions(+), 35 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/new_lint.rs b/clippy_dev/src/new_lint.rs index 420214d9256..13a27703427 100644 --- a/clippy_dev/src/new_lint.rs +++ b/clippy_dev/src/new_lint.rs @@ -369,9 +369,7 @@ fn create_lint_for_ty(lint: &LintData<'_>, enable_msrv: bool, ty: &str) -> io::R }} todo!(); }} - "#, - context_import = context_import, - name_upper = name_upper, + "# ); } else { let _: fmt::Result = writedoc!( @@ -385,9 +383,7 @@ fn create_lint_for_ty(lint: &LintData<'_>, enable_msrv: bool, ty: &str) -> io::R pub(super) fn check(cx: &{context_import}) {{ todo!(); }} - "#, - context_import = context_import, - name_upper = name_upper, + "# ); } diff --git a/clippy_dev/src/update_lints.rs b/clippy_dev/src/update_lints.rs index 779e4d0e1e3..95222a9acdf 100644 --- a/clippy_dev/src/update_lints.rs +++ b/clippy_dev/src/update_lints.rs @@ -537,17 +537,13 @@ fn declare_deprecated(name: &str, path: &Path, reason: &str) -> io::Result<()> { /// Nothing. This lint has been deprecated. /// /// ### Deprecation reason - /// {} - #[clippy::version = \"{}\"] - pub {}, - \"{}\" + /// {deprecation_reason} + #[clippy::version = \"{version}\"] + pub {name}, + \"{reason}\" }} - ", - deprecation_reason, - version, - name, - reason, + " ) } diff --git a/tests/ui/format_args_unfixable.rs b/tests/ui/format_args_unfixable.rs index eb0ac15bfbf..423bfaf9796 100644 --- a/tests/ui/format_args_unfixable.rs +++ b/tests/ui/format_args_unfixable.rs @@ -1,4 +1,5 @@ #![warn(clippy::format_in_format_args, clippy::to_string_in_format_args)] +#![allow(unused)] #![allow(clippy::assertions_on_constants, clippy::eq_op, clippy::uninlined_format_args)] use std::io::{stdout, Error, ErrorKind, Write}; @@ -57,3 +58,46 @@ fn main() { my_macro!(); println!("error: {}", my_other_macro!()); } + +macro_rules! _internal { + ($($args:tt)*) => { + println!("{}", format_args!($($args)*)) + }; +} + +macro_rules! my_println2 { + ($target:expr, $($args:tt)+) => {{ + if $target { + _internal!($($args)+) + } + }}; +} + +macro_rules! my_println2_args { + ($target:expr, $($args:tt)+) => {{ + if $target { + _internal!("foo: {}", format_args!($($args)+)) + } + }}; +} + +fn test2() { + let error = Error::new(ErrorKind::Other, "bad thing"); + + // None of these should be linted without the config change + my_println2!(true, "error: {}", format!("something failed at {}", Location::caller())); + my_println2!( + true, + "{}: {}", + error, + format!("something failed at {}", Location::caller()) + ); + + my_println2_args!(true, "error: {}", format!("something failed at {}", Location::caller())); + my_println2_args!( + true, + "{}: {}", + error, + format!("something failed at {}", Location::caller()) + ); +} diff --git a/tests/ui/format_args_unfixable.stderr b/tests/ui/format_args_unfixable.stderr index b291d475ad9..c1be48c3b72 100644 --- a/tests/ui/format_args_unfixable.stderr +++ b/tests/ui/format_args_unfixable.stderr @@ -1,5 +1,5 @@ error: `format!` in `println!` args - --> $DIR/format_args_unfixable.rs:25:5 + --> $DIR/format_args_unfixable.rs:26:5 | LL | println!("error: {}", format!("something failed at {}", Location::caller())); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ @@ -9,7 +9,7 @@ LL | println!("error: {}", format!("something failed at {}", Location::calle = note: `-D clippy::format-in-format-args` implied by `-D warnings` error: `format!` in `println!` args - --> $DIR/format_args_unfixable.rs:26:5 + --> $DIR/format_args_unfixable.rs:27:5 | LL | println!("{}: {}", error, format!("something failed at {}", Location::caller())); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ @@ -18,7 +18,7 @@ LL | println!("{}: {}", error, format!("something failed at {}", Location::c = help: or consider changing `format!` to `format_args!` error: `format!` in `println!` args - --> $DIR/format_args_unfixable.rs:27:5 + --> $DIR/format_args_unfixable.rs:28:5 | LL | println!("{:?}: {}", error, format!("something failed at {}", Location::caller())); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ @@ -27,7 +27,7 @@ LL | println!("{:?}: {}", error, format!("something failed at {}", Location: = help: or consider changing `format!` to `format_args!` error: `format!` in `println!` args - --> $DIR/format_args_unfixable.rs:28:5 + --> $DIR/format_args_unfixable.rs:29:5 | LL | println!("{{}}: {}", format!("something failed at {}", Location::caller())); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ @@ -36,7 +36,7 @@ LL | println!("{{}}: {}", format!("something failed at {}", Location::caller = help: or consider changing `format!` to `format_args!` error: `format!` in `println!` args - --> $DIR/format_args_unfixable.rs:29:5 + --> $DIR/format_args_unfixable.rs:30:5 | LL | println!(r#"error: "{}""#, format!("something failed at {}", Location::caller())); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ @@ -45,7 +45,7 @@ LL | println!(r#"error: "{}""#, format!("something failed at {}", Location:: = help: or consider changing `format!` to `format_args!` error: `format!` in `println!` args - --> $DIR/format_args_unfixable.rs:30:5 + --> $DIR/format_args_unfixable.rs:31:5 | LL | println!("error: {}", format!(r#"something failed at "{}""#, Location::caller())); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ @@ -54,7 +54,7 @@ LL | println!("error: {}", format!(r#"something failed at "{}""#, Location:: = help: or consider changing `format!` to `format_args!` error: `format!` in `println!` args - --> $DIR/format_args_unfixable.rs:31:5 + --> $DIR/format_args_unfixable.rs:32:5 | LL | println!("error: {}", format!("something failed at {} {0}", Location::caller())); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ @@ -63,7 +63,7 @@ LL | println!("error: {}", format!("something failed at {} {0}", Location::c = help: or consider changing `format!` to `format_args!` error: `format!` in `format!` args - --> $DIR/format_args_unfixable.rs:32:13 + --> $DIR/format_args_unfixable.rs:33:13 | LL | let _ = format!("error: {}", format!("something failed at {}", Location::caller())); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ @@ -72,7 +72,7 @@ LL | let _ = format!("error: {}", format!("something failed at {}", Location = help: or consider changing `format!` to `format_args!` error: `format!` in `write!` args - --> $DIR/format_args_unfixable.rs:33:13 + --> $DIR/format_args_unfixable.rs:34:13 | LL | let _ = write!( | _____________^ @@ -86,7 +86,7 @@ LL | | ); = help: or consider changing `format!` to `format_args!` error: `format!` in `writeln!` args - --> $DIR/format_args_unfixable.rs:38:13 + --> $DIR/format_args_unfixable.rs:39:13 | LL | let _ = writeln!( | _____________^ @@ -100,7 +100,7 @@ LL | | ); = help: or consider changing `format!` to `format_args!` error: `format!` in `print!` args - --> $DIR/format_args_unfixable.rs:43:5 + --> $DIR/format_args_unfixable.rs:44:5 | LL | print!("error: {}", format!("something failed at {}", Location::caller())); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ @@ -109,7 +109,7 @@ LL | print!("error: {}", format!("something failed at {}", Location::caller( = help: or consider changing `format!` to `format_args!` error: `format!` in `eprint!` args - --> $DIR/format_args_unfixable.rs:44:5 + --> $DIR/format_args_unfixable.rs:45:5 | LL | eprint!("error: {}", format!("something failed at {}", Location::caller())); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ @@ -118,7 +118,7 @@ LL | eprint!("error: {}", format!("something failed at {}", Location::caller = help: or consider changing `format!` to `format_args!` error: `format!` in `eprintln!` args - --> $DIR/format_args_unfixable.rs:45:5 + --> $DIR/format_args_unfixable.rs:46:5 | LL | eprintln!("error: {}", format!("something failed at {}", Location::caller())); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ @@ -127,7 +127,7 @@ LL | eprintln!("error: {}", format!("something failed at {}", Location::call = help: or consider changing `format!` to `format_args!` error: `format!` in `format_args!` args - --> $DIR/format_args_unfixable.rs:46:13 + --> $DIR/format_args_unfixable.rs:47:13 | LL | let _ = format_args!("error: {}", format!("something failed at {}", Location::caller())); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ @@ -136,7 +136,7 @@ LL | let _ = format_args!("error: {}", format!("something failed at {}", Loc = help: or consider changing `format!` to `format_args!` error: `format!` in `assert!` args - --> $DIR/format_args_unfixable.rs:47:5 + --> $DIR/format_args_unfixable.rs:48:5 | LL | assert!(true, "error: {}", format!("something failed at {}", Location::caller())); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ @@ -145,7 +145,7 @@ LL | assert!(true, "error: {}", format!("something failed at {}", Location:: = help: or consider changing `format!` to `format_args!` error: `format!` in `assert_eq!` args - --> $DIR/format_args_unfixable.rs:48:5 + --> $DIR/format_args_unfixable.rs:49:5 | LL | assert_eq!(0, 0, "error: {}", format!("something failed at {}", Location::caller())); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ @@ -154,7 +154,7 @@ LL | assert_eq!(0, 0, "error: {}", format!("something failed at {}", Locatio = help: or consider changing `format!` to `format_args!` error: `format!` in `assert_ne!` args - --> $DIR/format_args_unfixable.rs:49:5 + --> $DIR/format_args_unfixable.rs:50:5 | LL | assert_ne!(0, 0, "error: {}", format!("something failed at {}", Location::caller())); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ @@ -163,7 +163,7 @@ LL | assert_ne!(0, 0, "error: {}", format!("something failed at {}", Locatio = help: or consider changing `format!` to `format_args!` error: `format!` in `panic!` args - --> $DIR/format_args_unfixable.rs:50:5 + --> $DIR/format_args_unfixable.rs:51:5 | LL | panic!("error: {}", format!("something failed at {}", Location::caller())); | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ diff --git a/tests/ui/uninlined_format_args.fixed b/tests/ui/uninlined_format_args.fixed index 5ecb9a5bf9e..3122081a44f 100644 --- a/tests/ui/uninlined_format_args.fixed +++ b/tests/ui/uninlined_format_args.fixed @@ -1,7 +1,7 @@ // aux-build:proc_macros.rs // run-rustfix #![warn(clippy::uninlined_format_args)] -#![allow(named_arguments_used_positionally, unused_imports, unused_macros, unused_variables)] +#![allow(named_arguments_used_positionally, unused)] #![allow(clippy::eq_op, clippy::format_in_format_args, clippy::print_literal)] extern crate proc_macros; @@ -178,3 +178,87 @@ fn _meets_msrv() { fn _do_not_fire() { println!("{:?}", None::<()>); } + +macro_rules! _internal { + ($($args:tt)*) => { + println!("{}", format_args!($($args)*)) + }; +} + +macro_rules! my_println2 { + ($target:expr, $($args:tt)+) => {{ + if $target { + _internal!($($args)+) + } + }}; +} + +macro_rules! my_println2_args { + ($target:expr, $($args:tt)+) => {{ + if $target { + _internal!("foo: {}", format_args!($($args)+)) + } + }}; +} + +macro_rules! my_concat { + ($fmt:literal $(, $e:expr)*) => { + println!(concat!("ERROR: ", $fmt), $($e,)*) + } +} + +macro_rules! my_good_macro { + ($fmt:literal $(, $e:expr)* $(,)?) => { + println!($fmt $(, $e)*) + } +} + +macro_rules! my_bad_macro { + ($fmt:literal, $($e:expr),*) => { + println!($fmt, $($e,)*) + } +} + +macro_rules! my_bad_macro2 { + ($fmt:literal) => { + let s = $fmt.clone(); + println!("{}", s); + }; + ($fmt:literal, $($e:expr)+) => { + println!($fmt, $($e,)*) + }; +} + +// This abomination was suggested by @Alexendoo, may the Rust gods have mercy on their soul... +// https://github.com/rust-lang/rust-clippy/pull/9948#issuecomment-1327965962 +macro_rules! used_twice { + ( + large = $large:literal, + small = $small:literal, + $val:expr, + ) => { + if $val < 5 { + println!($small, $val); + } else { + println!($large, $val); + } + }; +} + +fn tester2() { + let local_i32 = 1; + my_println2_args!(true, "{}", local_i32); + my_println2!(true, "{}", local_i32); + my_concat!("{}", local_i32); + my_good_macro!("{}", local_i32); + my_good_macro!("{}", local_i32,); + + // FIXME: Broken false positives, currently unhandled + my_bad_macro!("{}", local_i32); + my_bad_macro2!("{}", local_i32); + used_twice! { + large = "large value: {}", + small = "small value: {}", + local_i32, + }; +} diff --git a/tests/ui/uninlined_format_args.rs b/tests/ui/uninlined_format_args.rs index 835afac393f..b153ef256e0 100644 --- a/tests/ui/uninlined_format_args.rs +++ b/tests/ui/uninlined_format_args.rs @@ -1,7 +1,7 @@ // aux-build:proc_macros.rs // run-rustfix #![warn(clippy::uninlined_format_args)] -#![allow(named_arguments_used_positionally, unused_imports, unused_macros, unused_variables)] +#![allow(named_arguments_used_positionally, unused)] #![allow(clippy::eq_op, clippy::format_in_format_args, clippy::print_literal)] extern crate proc_macros; @@ -183,3 +183,87 @@ fn _meets_msrv() { fn _do_not_fire() { println!("{:?}", None::<()>); } + +macro_rules! _internal { + ($($args:tt)*) => { + println!("{}", format_args!($($args)*)) + }; +} + +macro_rules! my_println2 { + ($target:expr, $($args:tt)+) => {{ + if $target { + _internal!($($args)+) + } + }}; +} + +macro_rules! my_println2_args { + ($target:expr, $($args:tt)+) => {{ + if $target { + _internal!("foo: {}", format_args!($($args)+)) + } + }}; +} + +macro_rules! my_concat { + ($fmt:literal $(, $e:expr)*) => { + println!(concat!("ERROR: ", $fmt), $($e,)*) + } +} + +macro_rules! my_good_macro { + ($fmt:literal $(, $e:expr)* $(,)?) => { + println!($fmt $(, $e)*) + } +} + +macro_rules! my_bad_macro { + ($fmt:literal, $($e:expr),*) => { + println!($fmt, $($e,)*) + } +} + +macro_rules! my_bad_macro2 { + ($fmt:literal) => { + let s = $fmt.clone(); + println!("{}", s); + }; + ($fmt:literal, $($e:expr)+) => { + println!($fmt, $($e,)*) + }; +} + +// This abomination was suggested by @Alexendoo, may the Rust gods have mercy on their soul... +// https://github.com/rust-lang/rust-clippy/pull/9948#issuecomment-1327965962 +macro_rules! used_twice { + ( + large = $large:literal, + small = $small:literal, + $val:expr, + ) => { + if $val < 5 { + println!($small, $val); + } else { + println!($large, $val); + } + }; +} + +fn tester2() { + let local_i32 = 1; + my_println2_args!(true, "{}", local_i32); + my_println2!(true, "{}", local_i32); + my_concat!("{}", local_i32); + my_good_macro!("{}", local_i32); + my_good_macro!("{}", local_i32,); + + // FIXME: Broken false positives, currently unhandled + my_bad_macro!("{}", local_i32); + my_bad_macro2!("{}", local_i32); + used_twice! { + large = "large value: {}", + small = "small value: {}", + local_i32, + }; +} -- cgit 1.4.1-3-g733a5 From def1705a271e317da4ae67d3a92e99fc699c9209 Mon Sep 17 00:00:00 2001 From: Oli Scherer Date: Thu, 20 Apr 2023 14:37:15 +0000 Subject: Update to a compiletest-rs version that requires `//@` for commands --- Cargo.toml | 2 +- book/src/development/adding_lints.md | 2 +- clippy_dev/src/update_lints.rs | 2 +- clippy_lints/src/methods/obfuscated_if_else.rs | 2 - tests/compile-test.rs | 3 +- .../cargo_common_metadata/fail/src/main.rs | 2 +- .../cargo_common_metadata/fail_publish/src/main.rs | 2 +- .../fail_publish_true/src/main.rs | 2 +- .../cargo_common_metadata/pass/src/main.rs | 2 +- .../pass_publish_empty/src/main.rs | 2 +- .../pass_publish_false/src/main.rs | 2 +- tests/ui-cargo/feature_name/fail/src/main.rs | 2 +- tests/ui-cargo/feature_name/pass/src/main.rs | 2 +- .../module_style/fail_mod_remap/src/main.rs | 2 +- .../5041_allow_dev_build/src/main.rs | 2 +- .../multiple_crate_versions/fail/src/main.rs | 2 +- .../multiple_crate_versions/pass/src/main.rs | 2 +- .../wildcard_dependencies/fail/src/main.rs | 2 +- .../wildcard_dependencies/pass/src/main.rs | 2 +- .../ui-internal/collapsible_span_lint_calls.fixed | 2 +- tests/ui-internal/collapsible_span_lint_calls.rs | 2 +- tests/ui-internal/custom_ice_message.rs | 12 +- tests/ui-internal/interning_defined_symbol.fixed | 2 +- tests/ui-internal/interning_defined_symbol.rs | 2 +- tests/ui-internal/invalid_msrv_attr_impl.fixed | 2 +- tests/ui-internal/invalid_msrv_attr_impl.rs | 2 +- tests/ui-internal/outer_expn_data.fixed | 2 +- tests/ui-internal/outer_expn_data.rs | 2 +- tests/ui-internal/unnecessary_def_path.fixed | 4 +- tests/ui-internal/unnecessary_def_path.rs | 4 +- tests/ui-internal/unnecessary_symbol_str.fixed | 2 +- tests/ui-internal/unnecessary_symbol_str.rs | 2 +- .../uninlined_format_args.fixed | 2 +- .../uninlined_format_args.rs | 2 +- tests/ui-toml/dbg_macro/dbg_macro.rs | 2 +- .../ui-toml/disallowed_macros/disallowed_macros.rs | 2 +- tests/ui-toml/expect_used/expect_used.rs | 2 +- tests/ui-toml/mut_key/mut_key.rs | 2 +- .../auxiliary/proc_macro_derive.rs | 4 +- .../conf_nonstandard_macro_braces.fixed | 4 +- .../conf_nonstandard_macro_braces.rs | 4 +- tests/ui-toml/print_macro/print_macro.rs | 2 +- .../conf_disallowed_methods.rs | 2 +- tests/ui-toml/toml_trivially_copy/test.rs | 4 +- tests/ui-toml/toml_unknown_key/conf_unknown_key.rs | 2 + tests/ui-toml/unwrap_used/unwrap_used.rs | 2 +- tests/ui/allow_attributes.fixed | 2 +- tests/ui/allow_attributes.rs | 2 +- tests/ui/almost_complete_range.fixed | 6 +- tests/ui/almost_complete_range.rs | 6 +- tests/ui/arithmetic_side_effects.rs | 2 +- tests/ui/as_conversions.rs | 2 +- tests/ui/as_underscore.fixed | 2 +- tests/ui/as_underscore.rs | 2 +- tests/ui/asm_syntax.rs | 4 +- tests/ui/assertions_on_result_states.fixed | 2 +- tests/ui/assertions_on_result_states.rs | 2 +- tests/ui/assign_ops.fixed | 2 +- tests/ui/assign_ops.rs | 2 +- tests/ui/async_yields_async.fixed | 2 +- tests/ui/async_yields_async.rs | 2 +- tests/ui/author/blocks.rs | 2 +- tests/ui/auxiliary/proc_macro_attr.rs | 4 +- tests/ui/auxiliary/proc_macro_derive.rs | 4 +- .../proc_macro_suspicious_else_formatting.rs | 4 +- tests/ui/auxiliary/proc_macro_unsafe.rs | 4 +- tests/ui/auxiliary/proc_macros.rs | 4 +- tests/ui/bind_instead_of_map.fixed | 2 +- tests/ui/bind_instead_of_map.rs | 2 +- tests/ui/bind_instead_of_map_multipart.fixed | 2 +- tests/ui/bind_instead_of_map_multipart.rs | 2 +- tests/ui/blanket_clippy_restriction_lints.rs | 2 +- tests/ui/blocks_in_if_conditions.fixed | 2 +- tests/ui/blocks_in_if_conditions.rs | 2 +- tests/ui/bool_assert_comparison.fixed | 2 +- tests/ui/bool_assert_comparison.rs | 2 +- tests/ui/bool_comparison.fixed | 2 +- tests/ui/bool_comparison.rs | 2 +- tests/ui/bool_to_int_with_if.fixed | 2 +- tests/ui/bool_to_int_with_if.rs | 2 +- tests/ui/borrow_as_ptr.fixed | 2 +- tests/ui/borrow_as_ptr.rs | 2 +- tests/ui/borrow_as_ptr_no_std.fixed | 2 +- tests/ui/borrow_as_ptr_no_std.rs | 2 +- tests/ui/borrow_deref_ref.fixed | 2 +- tests/ui/borrow_deref_ref.rs | 2 +- tests/ui/borrow_interior_mutable_const/enums.rs | 2 +- tests/ui/box_default.fixed | 2 +- tests/ui/box_default.rs | 2 +- tests/ui/bytes_count_to_len.fixed | 2 +- tests/ui/bytes_count_to_len.rs | 2 +- tests/ui/bytes_nth.fixed | 2 +- tests/ui/bytes_nth.rs | 2 +- ...case_sensitive_file_extension_comparisons.fixed | 2 +- .../case_sensitive_file_extension_comparisons.rs | 2 +- tests/ui/cast_abs_to_unsigned.fixed | 2 +- tests/ui/cast_abs_to_unsigned.rs | 2 +- tests/ui/cast_lossless_bool.fixed | 2 +- tests/ui/cast_lossless_bool.rs | 2 +- tests/ui/cast_lossless_float.fixed | 2 +- tests/ui/cast_lossless_float.rs | 2 +- tests/ui/cast_lossless_integer.fixed | 2 +- tests/ui/cast_lossless_integer.rs | 2 +- tests/ui/cast_raw_slice_pointer_cast.fixed | 2 +- tests/ui/cast_raw_slice_pointer_cast.rs | 2 +- tests/ui/cast_size.rs | 2 +- tests/ui/cast_size_32bit.rs | 2 +- tests/ui/cast_size_32bit.stderr | 53 +++++++++ tests/ui/cfg_attr_rustfmt.fixed | 2 +- tests/ui/cfg_attr_rustfmt.rs | 2 +- tests/ui/char_lit_as_u8_suggestions.fixed | 2 +- tests/ui/char_lit_as_u8_suggestions.rs | 2 +- tests/ui/checked_conversions.fixed | 2 +- tests/ui/checked_conversions.rs | 2 +- tests/ui/clear_with_drain.fixed | 2 +- tests/ui/clear_with_drain.rs | 2 +- tests/ui/clone_on_copy.fixed | 2 +- tests/ui/clone_on_copy.rs | 2 +- tests/ui/cloned_instead_of_copied.fixed | 2 +- tests/ui/cloned_instead_of_copied.rs | 2 +- tests/ui/cmp_owned/asymmetric_partial_eq.fixed | 2 +- tests/ui/cmp_owned/asymmetric_partial_eq.rs | 2 +- tests/ui/cmp_owned/comparison_flip.fixed | 2 +- tests/ui/cmp_owned/comparison_flip.rs | 2 +- tests/ui/cmp_owned/with_suggestion.fixed | 2 +- tests/ui/cmp_owned/with_suggestion.rs | 2 +- tests/ui/collapsible_else_if.fixed | 2 +- tests/ui/collapsible_else_if.rs | 2 +- tests/ui/collapsible_if.fixed | 2 +- tests/ui/collapsible_if.rs | 2 +- tests/ui/collapsible_str_replace.fixed | 2 +- tests/ui/collapsible_str_replace.rs | 2 +- tests/ui/comparison_to_empty.fixed | 2 +- tests/ui/comparison_to_empty.rs | 2 +- tests/ui/crashes/auxiliary/proc_macro_crash.rs | 4 +- tests/ui/crashes/ice-10148.rs | 2 +- tests/ui/crashes/ice-3741.rs | 2 +- tests/ui/crashes/ice-4968.rs | 2 +- tests/ui/crashes/ice-7272.rs | 2 +- tests/ui/crashes/ice-7410.rs | 6 +- tests/ui/crashes/ice-8681.rs | 2 +- tests/ui/crate_in_macro_def.fixed | 2 +- tests/ui/crate_in_macro_def.rs | 2 +- .../ui/crate_level_checks/entrypoint_recursion.rs | 2 +- .../ui/crate_level_checks/no_std_main_recursion.rs | 4 +- tests/ui/create_dir.fixed | 2 +- tests/ui/create_dir.rs | 2 +- tests/ui/dbg_macro.rs | 2 +- tests/ui/decimal_literal_representation.fixed | 2 +- tests/ui/decimal_literal_representation.rs | 2 +- tests/ui/def_id_nocore.rs | 2 +- tests/ui/default_instead_of_iter_empty.fixed | 2 +- tests/ui/default_instead_of_iter_empty.rs | 2 +- tests/ui/default_numeric_fallback_f64.fixed | 4 +- tests/ui/default_numeric_fallback_f64.rs | 4 +- tests/ui/default_numeric_fallback_i32.fixed | 4 +- tests/ui/default_numeric_fallback_i32.rs | 4 +- tests/ui/default_trait_access.fixed | 4 +- tests/ui/default_trait_access.rs | 4 +- tests/ui/deref_addrof.fixed | 4 +- tests/ui/deref_addrof.rs | 4 +- tests/ui/deref_addrof_macro.rs | 2 +- tests/ui/deref_by_slicing.fixed | 2 +- tests/ui/deref_by_slicing.rs | 2 +- tests/ui/derivable_impls.fixed | 2 +- tests/ui/derivable_impls.rs | 2 +- tests/ui/derive_partial_eq_without_eq.fixed | 2 +- tests/ui/derive_partial_eq_without_eq.rs | 2 +- tests/ui/doc/doc-fixable.fixed | 2 +- tests/ui/doc/doc-fixable.rs | 2 +- tests/ui/doc_unsafe.rs | 2 +- tests/ui/double_comparison.fixed | 2 +- tests/ui/double_comparison.rs | 2 +- tests/ui/duration_subsec.fixed | 2 +- tests/ui/duration_subsec.rs | 2 +- tests/ui/empty_drop.fixed | 2 +- tests/ui/empty_drop.rs | 2 +- tests/ui/empty_line_after_outer_attribute.rs | 2 +- tests/ui/empty_loop.rs | 2 +- tests/ui/empty_loop_no_std.rs | 4 +- tests/ui/empty_structs_with_brackets.fixed | 2 +- tests/ui/empty_structs_with_brackets.rs | 2 +- tests/ui/entry.fixed | 4 +- tests/ui/entry.rs | 4 +- tests/ui/entry_btree.fixed | 2 +- tests/ui/entry_btree.rs | 2 +- tests/ui/entry_with_else.fixed | 2 +- tests/ui/entry_with_else.rs | 2 +- tests/ui/enum_clike_unportable_variant.rs | 2 +- tests/ui/enum_glob_use.fixed | 2 +- tests/ui/enum_glob_use.rs | 2 +- tests/ui/eq_op.rs | 2 +- tests/ui/equatable_if_let.fixed | 4 +- tests/ui/equatable_if_let.rs | 4 +- tests/ui/err_expect.fixed | 2 +- tests/ui/err_expect.rs | 2 +- tests/ui/eta.fixed | 2 +- tests/ui/eta.rs | 2 +- tests/ui/excessive_precision.fixed | 2 +- tests/ui/excessive_precision.rs | 2 +- tests/ui/exhaustive_items.fixed | 2 +- tests/ui/exhaustive_items.rs | 2 +- tests/ui/expect_fun_call.fixed | 2 +- tests/ui/expect_fun_call.rs | 2 +- tests/ui/explicit_auto_deref.fixed | 2 +- tests/ui/explicit_auto_deref.rs | 2 +- tests/ui/explicit_deref_methods.fixed | 2 +- tests/ui/explicit_deref_methods.rs | 2 +- tests/ui/explicit_write.fixed | 2 +- tests/ui/explicit_write.rs | 2 +- tests/ui/extend_with_drain.fixed | 2 +- tests/ui/extend_with_drain.rs | 2 +- tests/ui/extra_unused_lifetimes.rs | 2 +- tests/ui/extra_unused_type_parameters.fixed | 2 +- tests/ui/extra_unused_type_parameters.rs | 2 +- tests/ui/field_reassign_with_default.rs | 4 +- tests/ui/filter_map_identity.fixed | 2 +- tests/ui/filter_map_identity.rs | 2 +- tests/ui/filter_map_next_fixable.fixed | 2 +- tests/ui/filter_map_next_fixable.rs | 2 +- tests/ui/flat_map_identity.fixed | 2 +- tests/ui/flat_map_identity.rs | 2 +- tests/ui/flat_map_option.fixed | 2 +- tests/ui/flat_map_option.rs | 2 +- tests/ui/floating_point_abs.fixed | 2 +- tests/ui/floating_point_abs.rs | 2 +- tests/ui/floating_point_exp.fixed | 2 +- tests/ui/floating_point_exp.rs | 2 +- tests/ui/floating_point_hypot.fixed | 2 +- tests/ui/floating_point_hypot.rs | 2 +- tests/ui/floating_point_log.fixed | 2 +- tests/ui/floating_point_log.rs | 2 +- tests/ui/floating_point_logbase.fixed | 2 +- tests/ui/floating_point_logbase.rs | 2 +- tests/ui/floating_point_mul_add.fixed | 2 +- tests/ui/floating_point_mul_add.rs | 2 +- tests/ui/floating_point_powf.fixed | 2 +- tests/ui/floating_point_powf.rs | 2 +- tests/ui/floating_point_powi.fixed | 2 +- tests/ui/floating_point_powi.rs | 2 +- tests/ui/floating_point_rad.fixed | 2 +- tests/ui/floating_point_rad.rs | 2 +- tests/ui/fn_to_numeric_cast.rs | 2 +- tests/ui/fn_to_numeric_cast_32bit.rs | 2 +- tests/ui/fn_to_numeric_cast_32bit.stderr | 14 +-- tests/ui/for_loop_fixable.fixed | 2 +- tests/ui/for_loop_fixable.rs | 2 +- tests/ui/format.fixed | 2 +- tests/ui/format.rs | 2 +- tests/ui/format_args.fixed | 2 +- tests/ui/format_args.rs | 2 +- tests/ui/from_iter_instead_of_collect.fixed | 2 +- tests/ui/from_iter_instead_of_collect.rs | 2 +- tests/ui/from_over_into.fixed | 2 +- tests/ui/from_over_into.rs | 2 +- tests/ui/get_first.fixed | 2 +- tests/ui/get_first.rs | 2 +- tests/ui/get_last_with_len.fixed | 2 +- tests/ui/get_last_with_len.rs | 2 +- tests/ui/get_unwrap.fixed | 2 +- tests/ui/get_unwrap.rs | 2 +- tests/ui/identity_op.fixed | 2 +- tests/ui/identity_op.rs | 2 +- tests/ui/implicit_clone.fixed | 2 +- tests/ui/implicit_clone.rs | 2 +- tests/ui/implicit_hasher.rs | 2 +- tests/ui/implicit_return.fixed | 2 +- tests/ui/implicit_return.rs | 2 +- tests/ui/implicit_saturating_add.fixed | 2 +- tests/ui/implicit_saturating_add.rs | 2 +- tests/ui/implicit_saturating_sub.fixed | 2 +- tests/ui/implicit_saturating_sub.rs | 2 +- tests/ui/inconsistent_digit_grouping.fixed | 2 +- tests/ui/inconsistent_digit_grouping.rs | 2 +- tests/ui/inconsistent_struct_constructor.fixed | 4 +- tests/ui/inconsistent_struct_constructor.rs | 4 +- tests/ui/inefficient_to_string.fixed | 2 +- tests/ui/inefficient_to_string.rs | 2 +- tests/ui/infallible_destructuring_match.fixed | 2 +- tests/ui/infallible_destructuring_match.rs | 2 +- tests/ui/inline_fn_without_body.fixed | 2 +- tests/ui/inline_fn_without_body.rs | 2 +- tests/ui/int_plus_one.fixed | 2 +- tests/ui/int_plus_one.rs | 2 +- tests/ui/integer_arithmetic.rs | 2 +- tests/ui/into_iter_on_ref.fixed | 2 +- tests/ui/into_iter_on_ref.rs | 2 +- tests/ui/invalid_null_ptr_usage.fixed | 2 +- tests/ui/invalid_null_ptr_usage.rs | 2 +- tests/ui/is_digit_ascii_radix.fixed | 2 +- tests/ui/is_digit_ascii_radix.rs | 2 +- tests/ui/issue_2356.fixed | 2 +- tests/ui/issue_2356.rs | 2 +- tests/ui/iter_cloned_collect.fixed | 2 +- tests/ui/iter_cloned_collect.rs | 2 +- tests/ui/iter_count.fixed | 4 +- tests/ui/iter_count.rs | 4 +- tests/ui/iter_kv_map.fixed | 2 +- tests/ui/iter_kv_map.rs | 2 +- tests/ui/iter_next_slice.fixed | 2 +- tests/ui/iter_next_slice.rs | 2 +- tests/ui/iter_nth.rs | 2 +- tests/ui/iter_nth_zero.fixed | 2 +- tests/ui/iter_nth_zero.rs | 2 +- tests/ui/iter_on_empty_collections.fixed | 2 +- tests/ui/iter_on_empty_collections.rs | 2 +- tests/ui/iter_on_single_items.fixed | 2 +- tests/ui/iter_on_single_items.rs | 2 +- tests/ui/iter_overeager_cloned.fixed | 2 +- tests/ui/iter_overeager_cloned.rs | 2 +- tests/ui/iter_skip_next.fixed | 4 +- tests/ui/iter_skip_next.rs | 4 +- tests/ui/iter_with_drain.fixed | 2 +- tests/ui/iter_with_drain.rs | 2 +- tests/ui/large_const_arrays.fixed | 2 +- tests/ui/large_const_arrays.rs | 2 +- tests/ui/large_digit_groups.fixed | 2 +- tests/ui/large_digit_groups.rs | 2 +- tests/ui/large_enum_variant.rs | 2 +- tests/ui/large_types_passed_by_value.rs | 4 +- tests/ui/len_zero.fixed | 2 +- tests/ui/len_zero.rs | 2 +- tests/ui/len_zero_ranges.fixed | 2 +- tests/ui/len_zero_ranges.rs | 2 +- tests/ui/let_unit.fixed | 2 +- tests/ui/let_unit.rs | 2 +- tests/ui/lines_filter_map_ok.fixed | 2 +- tests/ui/lines_filter_map_ok.rs | 2 +- tests/ui/lossy_float_literal.fixed | 2 +- tests/ui/lossy_float_literal.rs | 2 +- tests/ui/macro_use_imports.fixed | 10 +- tests/ui/macro_use_imports.rs | 10 +- tests/ui/macro_use_imports_expect.rs | 8 +- tests/ui/manual_assert.edition2018.fixed | 8 +- tests/ui/manual_assert.edition2021.fixed | 8 +- tests/ui/manual_assert.rs | 8 +- tests/ui/manual_async_fn.fixed | 2 +- tests/ui/manual_async_fn.rs | 2 +- tests/ui/manual_bits.fixed | 2 +- tests/ui/manual_bits.rs | 2 +- tests/ui/manual_filter.fixed | 2 +- tests/ui/manual_filter.rs | 2 +- tests/ui/manual_filter_map.fixed | 2 +- tests/ui/manual_filter_map.rs | 2 +- tests/ui/manual_find_fixable.fixed | 2 +- tests/ui/manual_find_fixable.rs | 2 +- tests/ui/manual_find_map.fixed | 2 +- tests/ui/manual_find_map.rs | 2 +- tests/ui/manual_instant_elapsed.fixed | 2 +- tests/ui/manual_instant_elapsed.rs | 2 +- tests/ui/manual_is_ascii_check.fixed | 2 +- tests/ui/manual_is_ascii_check.rs | 2 +- tests/ui/manual_main_separator_str.fixed | 2 +- tests/ui/manual_main_separator_str.rs | 2 +- tests/ui/manual_map_option.fixed | 2 +- tests/ui/manual_map_option.rs | 2 +- tests/ui/manual_map_option_2.fixed | 2 +- tests/ui/manual_map_option_2.rs | 2 +- tests/ui/manual_ok_or.fixed | 2 +- tests/ui/manual_ok_or.rs | 2 +- tests/ui/manual_rem_euclid.fixed | 4 +- tests/ui/manual_rem_euclid.rs | 4 +- tests/ui/manual_retain.fixed | 2 +- tests/ui/manual_retain.rs | 2 +- tests/ui/manual_saturating_arithmetic.fixed | 2 +- tests/ui/manual_saturating_arithmetic.rs | 2 +- tests/ui/manual_slice_size_calculation.fixed | 4 +- tests/ui/manual_slice_size_calculation.rs | 4 +- tests/ui/manual_split_once.fixed | 2 +- tests/ui/manual_split_once.rs | 2 +- tests/ui/manual_str_repeat.fixed | 2 +- tests/ui/manual_str_repeat.rs | 2 +- tests/ui/manual_string_new.fixed | 2 +- tests/ui/manual_string_new.rs | 2 +- tests/ui/manual_unwrap_or.fixed | 2 +- tests/ui/manual_unwrap_or.rs | 2 +- tests/ui/map_clone.fixed | 2 +- tests/ui/map_clone.rs | 2 +- tests/ui/map_collect_result_unit.fixed | 2 +- tests/ui/map_collect_result_unit.rs | 2 +- tests/ui/map_flatten_fixable.fixed | 2 +- tests/ui/map_flatten_fixable.rs | 2 +- tests/ui/map_identity.fixed | 2 +- tests/ui/map_identity.rs | 2 +- tests/ui/map_unwrap_or.rs | 2 +- tests/ui/map_unwrap_or_fixable.fixed | 4 +- tests/ui/map_unwrap_or_fixable.rs | 4 +- tests/ui/match_as_ref.fixed | 2 +- tests/ui/match_as_ref.rs | 2 +- tests/ui/match_expr_like_matches_macro.fixed | 2 +- tests/ui/match_expr_like_matches_macro.rs | 2 +- tests/ui/match_ref_pats.fixed | 2 +- tests/ui/match_ref_pats.rs | 2 +- tests/ui/match_result_ok.fixed | 2 +- tests/ui/match_result_ok.rs | 2 +- tests/ui/match_single_binding.fixed | 2 +- tests/ui/match_single_binding.rs | 2 +- tests/ui/match_single_binding2.fixed | 2 +- tests/ui/match_single_binding2.rs | 2 +- tests/ui/match_str_case_mismatch.fixed | 2 +- tests/ui/match_str_case_mismatch.rs | 2 +- tests/ui/match_wildcard_for_single_variants.fixed | 2 +- tests/ui/match_wildcard_for_single_variants.rs | 2 +- tests/ui/mem_replace.fixed | 2 +- tests/ui/mem_replace.rs | 2 +- tests/ui/mem_replace_macro.rs | 2 +- tests/ui/methods.rs | 2 +- tests/ui/methods_fixable.fixed | 2 +- tests/ui/methods_fixable.rs | 2 +- tests/ui/mismatched_target_os_non_unix.fixed | 2 +- tests/ui/mismatched_target_os_non_unix.rs | 2 +- tests/ui/mismatched_target_os_unix.fixed | 2 +- tests/ui/mismatched_target_os_unix.rs | 2 +- tests/ui/missing_const_for_fn/cant_be_const.rs | 4 +- tests/ui/missing_doc.rs | 4 +- tests/ui/missing_doc_impl.rs | 2 +- tests/ui/missing_spin_loop.fixed | 2 +- tests/ui/missing_spin_loop.rs | 2 +- tests/ui/missing_spin_loop_no_std.fixed | 2 +- tests/ui/missing_spin_loop_no_std.rs | 2 +- tests/ui/mistyped_literal_suffix.fixed | 4 +- tests/ui/mistyped_literal_suffix.rs | 4 +- tests/ui/module_name_repetitions.rs | 2 +- tests/ui/multiple_unsafe_ops_per_block.rs | 2 +- tests/ui/must_use_candidates.fixed | 2 +- tests/ui/must_use_candidates.rs | 2 +- tests/ui/must_use_unit.fixed | 4 +- tests/ui/must_use_unit.rs | 4 +- tests/ui/mut_mut.rs | 2 +- tests/ui/mut_mutex_lock.fixed | 2 +- tests/ui/mut_mutex_lock.rs | 2 +- tests/ui/needless_arbitrary_self_type.fixed | 2 +- tests/ui/needless_arbitrary_self_type.rs | 2 +- tests/ui/needless_arbitrary_self_type_unfixable.rs | 2 +- tests/ui/needless_bitwise_bool.fixed | 2 +- tests/ui/needless_bitwise_bool.rs | 2 +- tests/ui/needless_bool/fixable.fixed | 2 +- tests/ui/needless_bool/fixable.rs | 2 +- tests/ui/needless_borrow.fixed | 2 +- tests/ui/needless_borrow.rs | 2 +- tests/ui/needless_borrowed_ref.fixed | 2 +- tests/ui/needless_borrowed_ref.rs | 2 +- tests/ui/needless_collect.fixed | 2 +- tests/ui/needless_collect.rs | 2 +- tests/ui/needless_for_each_fixable.fixed | 2 +- tests/ui/needless_for_each_fixable.rs | 2 +- tests/ui/needless_late_init.fixed | 4 +- tests/ui/needless_late_init.rs | 4 +- tests/ui/needless_lifetimes.fixed | 4 +- tests/ui/needless_lifetimes.rs | 4 +- tests/ui/needless_match.fixed | 2 +- tests/ui/needless_match.rs | 2 +- tests/ui/needless_option_as_deref.fixed | 2 +- tests/ui/needless_option_as_deref.rs | 2 +- tests/ui/needless_option_take.fixed | 2 +- tests/ui/needless_option_take.rs | 2 +- tests/ui/needless_parens_on_range_literals.fixed | 4 +- tests/ui/needless_parens_on_range_literals.rs | 4 +- tests/ui/needless_question_mark.fixed | 2 +- tests/ui/needless_question_mark.rs | 2 +- tests/ui/needless_return.fixed | 2 +- tests/ui/needless_return.rs | 2 +- tests/ui/needless_splitn.fixed | 4 +- tests/ui/needless_splitn.rs | 4 +- tests/ui/neg_multiply.fixed | 2 +- tests/ui/neg_multiply.rs | 2 +- tests/ui/non_octal_unix_permissions.fixed | 4 +- tests/ui/non_octal_unix_permissions.rs | 4 +- tests/ui/nonminimal_bool_methods.fixed | 2 +- tests/ui/nonminimal_bool_methods.rs | 2 +- tests/ui/numbered_fields.fixed | 2 +- tests/ui/numbered_fields.rs | 2 +- tests/ui/obfuscated_if_else.fixed | 2 +- tests/ui/obfuscated_if_else.rs | 2 +- tests/ui/option_as_ref_deref.fixed | 2 +- tests/ui/option_as_ref_deref.rs | 2 +- tests/ui/option_env_unwrap.rs | 2 +- tests/ui/option_filter_map.fixed | 2 +- tests/ui/option_filter_map.rs | 2 +- tests/ui/option_if_let_else.fixed | 2 +- tests/ui/option_if_let_else.rs | 2 +- tests/ui/option_map_or_none.fixed | 2 +- tests/ui/option_map_or_none.rs | 2 +- tests/ui/option_map_unit_fn_fixable.fixed | 2 +- tests/ui/option_map_unit_fn_fixable.rs | 2 +- tests/ui/or_fun_call.fixed | 2 +- tests/ui/or_fun_call.rs | 2 +- tests/ui/or_then_unwrap.fixed | 2 +- tests/ui/or_then_unwrap.rs | 2 +- tests/ui/partialeq_to_none.fixed | 2 +- tests/ui/partialeq_to_none.rs | 2 +- tests/ui/path_buf_push_overwrite.fixed | 2 +- tests/ui/path_buf_push_overwrite.rs | 2 +- tests/ui/patterns.fixed | 2 +- tests/ui/patterns.rs | 2 +- tests/ui/precedence.fixed | 2 +- tests/ui/precedence.rs | 2 +- tests/ui/print_stdout_build_script.rs | 2 +- tests/ui/print_with_newline.rs | 2 +- tests/ui/println_empty_string.fixed | 2 +- tests/ui/println_empty_string.rs | 2 +- tests/ui/ptr_as_ptr.fixed | 4 +- tests/ui/ptr_as_ptr.rs | 4 +- tests/ui/ptr_eq.fixed | 2 +- tests/ui/ptr_eq.rs | 2 +- tests/ui/ptr_offset_with_cast.fixed | 2 +- tests/ui/ptr_offset_with_cast.rs | 2 +- tests/ui/question_mark.fixed | 2 +- tests/ui/question_mark.rs | 2 +- tests/ui/range_contains.fixed | 2 +- tests/ui/range_contains.rs | 2 +- tests/ui/range_plus_minus_one.fixed | 2 +- tests/ui/range_plus_minus_one.rs | 2 +- tests/ui/rc_buffer.fixed | 2 +- tests/ui/rc_buffer.rs | 2 +- tests/ui/rc_buffer_arc.fixed | 2 +- tests/ui/rc_buffer_arc.rs | 2 +- tests/ui/redundant_allocation_fixable.fixed | 2 +- tests/ui/redundant_allocation_fixable.rs | 2 +- tests/ui/redundant_async_block.fixed | 2 +- tests/ui/redundant_async_block.rs | 2 +- tests/ui/redundant_clone.fixed | 2 +- tests/ui/redundant_clone.rs | 2 +- tests/ui/redundant_closure_call_fixable.fixed | 2 +- tests/ui/redundant_closure_call_fixable.rs | 2 +- tests/ui/redundant_field_names.fixed | 2 +- tests/ui/redundant_field_names.rs | 2 +- .../ui/redundant_pattern_matching_drop_order.fixed | 2 +- tests/ui/redundant_pattern_matching_drop_order.rs | 2 +- tests/ui/redundant_pattern_matching_ipaddr.fixed | 2 +- tests/ui/redundant_pattern_matching_ipaddr.rs | 2 +- tests/ui/redundant_pattern_matching_option.fixed | 2 +- tests/ui/redundant_pattern_matching_option.rs | 2 +- tests/ui/redundant_pattern_matching_poll.fixed | 2 +- tests/ui/redundant_pattern_matching_poll.rs | 2 +- tests/ui/redundant_pattern_matching_result.fixed | 2 +- tests/ui/redundant_pattern_matching_result.rs | 2 +- tests/ui/redundant_pub_crate.fixed | 2 +- tests/ui/redundant_pub_crate.rs | 2 +- tests/ui/redundant_slicing.fixed | 2 +- tests/ui/redundant_slicing.rs | 2 +- tests/ui/redundant_static_lifetimes.fixed | 2 +- tests/ui/redundant_static_lifetimes.rs | 2 +- tests/ui/rename.fixed | 2 +- tests/ui/rename.rs | 2 +- tests/ui/renamed_builtin_attr.fixed | 2 +- tests/ui/renamed_builtin_attr.rs | 2 +- tests/ui/repeat_once.fixed | 2 +- tests/ui/repeat_once.rs | 2 +- tests/ui/result_map_or_into_option.fixed | 2 +- tests/ui/result_map_or_into_option.rs | 2 +- tests/ui/result_map_unit_fn_fixable.fixed | 2 +- tests/ui/result_map_unit_fn_fixable.rs | 2 +- tests/ui/reversed_empty_ranges_fixable.fixed | 2 +- tests/ui/reversed_empty_ranges_fixable.rs | 2 +- tests/ui/reversed_empty_ranges_loops_fixable.fixed | 2 +- tests/ui/reversed_empty_ranges_loops_fixable.rs | 2 +- tests/ui/same_functions_in_if_condition.rs | 2 +- tests/ui/same_functions_in_if_condition.stderr | 6 +- tests/ui/search_is_some.rs | 2 +- tests/ui/search_is_some_fixable_none.fixed | 2 +- tests/ui/search_is_some_fixable_none.rs | 2 +- tests/ui/search_is_some_fixable_some.fixed | 2 +- tests/ui/search_is_some_fixable_some.rs | 2 +- tests/ui/seek_from_current.fixed | 2 +- tests/ui/seek_from_current.rs | 2 +- tests/ui/seek_to_start_instead_of_rewind.fixed | 2 +- tests/ui/seek_to_start_instead_of_rewind.rs | 2 +- tests/ui/semicolon_inside_block.fixed | 2 +- tests/ui/semicolon_inside_block.rs | 2 +- tests/ui/semicolon_outside_block.fixed | 2 +- tests/ui/semicolon_outside_block.rs | 2 +- tests/ui/shadow.rs | 2 +- tests/ui/short_circuit_statement.fixed | 2 +- tests/ui/short_circuit_statement.rs | 2 +- tests/ui/significant_drop_in_scrutinee.rs | 2 +- tests/ui/significant_drop_tightening.fixed | 2 +- tests/ui/significant_drop_tightening.rs | 2 +- tests/ui/single_char_add_str.fixed | 2 +- tests/ui/single_char_add_str.rs | 2 +- tests/ui/single_char_pattern.fixed | 2 +- tests/ui/single_char_pattern.rs | 2 +- tests/ui/single_component_path_imports.fixed | 2 +- tests/ui/single_component_path_imports.rs | 2 +- tests/ui/single_element_loop.fixed | 2 +- tests/ui/single_element_loop.rs | 2 +- tests/ui/single_match_else.rs | 2 +- tests/ui/skip_while_next.rs | 2 +- tests/ui/stable_sort_primitive.fixed | 2 +- tests/ui/stable_sort_primitive.rs | 2 +- tests/ui/starts_ends_with.fixed | 2 +- tests/ui/starts_ends_with.rs | 2 +- tests/ui/string_add.rs | 2 +- tests/ui/string_add_assign.fixed | 2 +- tests/ui/string_add_assign.rs | 2 +- tests/ui/string_extend.fixed | 2 +- tests/ui/string_extend.rs | 2 +- tests/ui/string_from_utf8_as_bytes.fixed | 2 +- tests/ui/string_from_utf8_as_bytes.rs | 2 +- tests/ui/string_lit_as_bytes.fixed | 2 +- tests/ui/string_lit_as_bytes.rs | 2 +- tests/ui/strlen_on_c_strings.fixed | 2 +- tests/ui/strlen_on_c_strings.rs | 2 +- tests/ui/suspicious_doc_comments.fixed | 2 +- tests/ui/suspicious_doc_comments.rs | 2 +- tests/ui/suspicious_else_formatting.rs | 2 +- tests/ui/suspicious_operation_groupings.fixed | 2 +- tests/ui/suspicious_operation_groupings.rs | 2 +- tests/ui/swap.fixed | 4 +- tests/ui/swap.rs | 4 +- tests/ui/swap_ptr_to_ref.fixed | 2 +- tests/ui/swap_ptr_to_ref.rs | 2 +- tests/ui/tabs_in_doc_comments.fixed | 2 +- tests/ui/tabs_in_doc_comments.rs | 2 +- tests/ui/tests_outside_test_module.rs | 2 +- tests/ui/to_digit_is_some.fixed | 2 +- tests/ui/to_digit_is_some.rs | 2 +- tests/ui/toplevel_ref_arg.fixed | 4 +- tests/ui/toplevel_ref_arg.rs | 4 +- tests/ui/toplevel_ref_arg_non_rustfix.rs | 2 +- tests/ui/track-diagnostics.rs | 5 +- tests/ui/trait_duplication_in_bounds.fixed | 2 +- tests/ui/trait_duplication_in_bounds.rs | 2 +- tests/ui/transmute_32bit.rs | 2 +- tests/ui/transmute_32bit.stderr | 29 +++-- tests/ui/transmute_64bit.rs | 2 +- tests/ui/transmute_ptr_to_ref.fixed | 2 +- tests/ui/transmute_ptr_to_ref.rs | 2 +- tests/ui/transmutes_expressible_as_ptr_casts.fixed | 2 +- tests/ui/transmutes_expressible_as_ptr_casts.rs | 2 +- tests/ui/trim_split_whitespace.fixed | 2 +- tests/ui/trim_split_whitespace.rs | 2 +- tests/ui/trivially_copy_pass_by_ref.rs | 4 +- tests/ui/try_err.fixed | 4 +- tests/ui/try_err.rs | 4 +- tests/ui/types.fixed | 2 +- tests/ui/types.rs | 2 +- tests/ui/unchecked_duration_subtraction.fixed | 2 +- tests/ui/unchecked_duration_subtraction.rs | 2 +- tests/ui/undocumented_unsafe_blocks.rs | 2 +- tests/ui/unicode.fixed | 4 +- tests/ui/unicode.rs | 4 +- tests/ui/uninlined_format_args.fixed | 4 +- tests/ui/uninlined_format_args.rs | 4 +- .../uninlined_format_args_panic.edition2018.fixed | 8 +- .../uninlined_format_args_panic.edition2021.fixed | 8 +- tests/ui/uninlined_format_args_panic.rs | 8 +- tests/ui/unit_arg.rs | 2 +- tests/ui/unit_arg_empty_blocks.fixed | 2 +- tests/ui/unit_arg_empty_blocks.rs | 2 +- tests/ui/unknown_clippy_lints.fixed | 2 +- tests/ui/unknown_clippy_lints.rs | 2 +- tests/ui/unnecessary_cast.fixed | 2 +- tests/ui/unnecessary_cast.rs | 2 +- tests/ui/unnecessary_fold.fixed | 2 +- tests/ui/unnecessary_fold.rs | 2 +- tests/ui/unnecessary_iter_cloned.fixed | 2 +- tests/ui/unnecessary_iter_cloned.rs | 2 +- tests/ui/unnecessary_join.fixed | 2 +- tests/ui/unnecessary_join.rs | 2 +- tests/ui/unnecessary_lazy_eval.fixed | 4 +- tests/ui/unnecessary_lazy_eval.rs | 4 +- tests/ui/unnecessary_operation.fixed | 2 +- tests/ui/unnecessary_operation.rs | 2 +- tests/ui/unnecessary_owned_empty_strings.fixed | 2 +- tests/ui/unnecessary_owned_empty_strings.rs | 2 +- tests/ui/unnecessary_self_imports.fixed | 2 +- tests/ui/unnecessary_self_imports.rs | 2 +- tests/ui/unnecessary_sort_by.fixed | 2 +- tests/ui/unnecessary_sort_by.rs | 2 +- tests/ui/unnecessary_struct_initialization.fixed | 2 +- tests/ui/unnecessary_struct_initialization.rs | 2 +- tests/ui/unnecessary_to_owned.fixed | 2 +- tests/ui/unnecessary_to_owned.rs | 2 +- tests/ui/unnecessary_unsafety_doc.rs | 2 +- tests/ui/unneeded_wildcard_pattern.fixed | 2 +- tests/ui/unneeded_wildcard_pattern.rs | 2 +- tests/ui/unnested_or_patterns.fixed | 2 +- tests/ui/unnested_or_patterns.rs | 2 +- tests/ui/unnested_or_patterns2.fixed | 2 +- tests/ui/unnested_or_patterns2.rs | 2 +- tests/ui/unreadable_literal.fixed | 2 +- tests/ui/unreadable_literal.rs | 2 +- tests/ui/unseparated_prefix_literals.fixed | 4 +- tests/ui/unseparated_prefix_literals.rs | 4 +- tests/ui/unused_rounding.fixed | 2 +- tests/ui/unused_rounding.rs | 2 +- tests/ui/unused_unit.fixed | 2 +- tests/ui/unused_unit.rs | 2 +- tests/ui/unwrap_or_else_default.fixed | 2 +- tests/ui/unwrap_or_else_default.rs | 2 +- tests/ui/use_self.fixed | 4 +- tests/ui/use_self.rs | 4 +- tests/ui/use_self_trait.fixed | 2 +- tests/ui/use_self_trait.rs | 2 +- tests/ui/used_underscore_binding.rs | 2 +- tests/ui/useless_asref.fixed | 2 +- tests/ui/useless_asref.rs | 2 +- tests/ui/useless_attribute.fixed | 4 +- tests/ui/useless_attribute.rs | 4 +- tests/ui/useless_conversion.fixed | 2 +- tests/ui/useless_conversion.rs | 2 +- tests/ui/vec.fixed | 2 +- tests/ui/vec.rs | 2 +- tests/ui/vec_box_sized.fixed | 2 +- tests/ui/vec_box_sized.rs | 2 +- tests/ui/while_let_on_iterator.fixed | 2 +- tests/ui/while_let_on_iterator.rs | 2 +- tests/ui/wildcard_enum_match_arm.fixed | 4 +- tests/ui/wildcard_enum_match_arm.rs | 4 +- tests/ui/wildcard_imports.fixed | 6 +- tests/ui/wildcard_imports.rs | 6 +- tests/ui/wildcard_imports_2021.edition2018.fixed | 10 +- tests/ui/wildcard_imports_2021.edition2021.fixed | 10 +- tests/ui/wildcard_imports_2021.rs | 10 +- tests/ui/wildcard_imports_2021.stderr | 132 --------------------- tests/ui/write_with_newline.rs | 4 +- tests/ui/write_with_newline.stderr | 6 +- tests/ui/writeln_empty_string.fixed | 2 +- tests/ui/writeln_empty_string.rs | 2 +- tests/ui/zero_ptr.fixed | 2 +- tests/ui/zero_ptr.rs | 2 +- tests/ui/zero_ptr_no_std.fixed | 2 +- tests/ui/zero_ptr_no_std.rs | 2 +- 724 files changed, 945 insertions(+), 1009 deletions(-) delete mode 100644 tests/ui/wildcard_imports_2021.stderr (limited to 'clippy_dev/src') diff --git a/Cargo.toml b/Cargo.toml index 5bb9f527081..1ec168737b8 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -28,7 +28,7 @@ tempfile = { version = "3.2", optional = true } termize = "0.1" [dev-dependencies] -compiletest_rs = { version = "0.9", features = ["tmp"] } +compiletest_rs = { version = "0.10", features = ["tmp"] } tester = "0.9" regex = "1.5" toml = "0.5" diff --git a/book/src/development/adding_lints.md b/book/src/development/adding_lints.md index 9dacaaaae5c..ccae8d37420 100644 --- a/book/src/development/adding_lints.md +++ b/book/src/development/adding_lints.md @@ -164,7 +164,7 @@ The process of generating the `.stderr` file is the same, and prepending the ## Rustfix tests If the lint you are working on is making use of structured suggestions, the test -file should include a `// run-rustfix` comment at the top. This will +file should include a `//@run-rustfix` comment at the top. This will additionally run [rustfix] for that test. Rustfix will apply the suggestions from the lint to the code of the test file and compare that to the contents of a `.fixed` file. diff --git a/clippy_dev/src/update_lints.rs b/clippy_dev/src/update_lints.rs index 95222a9acdf..dd90a38f757 100644 --- a/clippy_dev/src/update_lints.rs +++ b/clippy_dev/src/update_lints.rs @@ -741,7 +741,7 @@ fn gen_deprecated_lints_test(lints: &[DeprecatedLint]) -> String { fn gen_renamed_lints_test(lints: &[RenamedLint]) -> String { let mut seen_lints = HashSet::new(); let mut res: String = GENERATED_FILE_COMMENT.into(); - res.push_str("// run-rustfix\n\n"); + res.push_str("//@run-rustfix\n\n"); for lint in lints { if seen_lints.insert(&lint.new_name) { writeln!(res, "#![allow({})]", lint.new_name).unwrap(); diff --git a/clippy_lints/src/methods/obfuscated_if_else.rs b/clippy_lints/src/methods/obfuscated_if_else.rs index 4d7427b2662..eada530d670 100644 --- a/clippy_lints/src/methods/obfuscated_if_else.rs +++ b/clippy_lints/src/methods/obfuscated_if_else.rs @@ -1,5 +1,3 @@ -// run-rustfix - use super::OBFUSCATED_IF_ELSE; use clippy_utils::{diagnostics::span_lint_and_sugg, source::snippet_with_applicability}; use rustc_errors::Applicability; diff --git a/tests/compile-test.rs b/tests/compile-test.rs index 57890ff3173..35d75cc51c2 100644 --- a/tests/compile-test.rs +++ b/tests/compile-test.rs @@ -126,6 +126,7 @@ fn base_config(test_dir: &str) -> compiletest::Config { let mut config = compiletest::Config { edition: Some("2021".into()), mode: TestMode::Ui, + strict_headers: true, ..Default::default() }; @@ -424,7 +425,7 @@ fn check_rustfix_coverage() { .binary_search_by_key(&filename, Path::new) .is_ok(), "`{rs_file}` runs `MachineApplicable` diagnostics but is missing a `run-rustfix` annotation. \ - Please either add `// run-rustfix` at the top of the file or add the file to \ + Please either add `//@run-rustfix` at the top of the file or add the file to \ `RUSTFIX_COVERAGE_KNOWN_EXCEPTIONS` in `tests/compile-test.rs`.", ); } diff --git a/tests/ui-cargo/cargo_common_metadata/fail/src/main.rs b/tests/ui-cargo/cargo_common_metadata/fail/src/main.rs index 27841e18aa9..1a69bb24101 100644 --- a/tests/ui-cargo/cargo_common_metadata/fail/src/main.rs +++ b/tests/ui-cargo/cargo_common_metadata/fail/src/main.rs @@ -1,4 +1,4 @@ -// compile-flags: --crate-name=cargo_common_metadata +//@compile-flags: --crate-name=cargo_common_metadata #![warn(clippy::cargo_common_metadata)] fn main() {} diff --git a/tests/ui-cargo/cargo_common_metadata/fail_publish/src/main.rs b/tests/ui-cargo/cargo_common_metadata/fail_publish/src/main.rs index 27841e18aa9..1a69bb24101 100644 --- a/tests/ui-cargo/cargo_common_metadata/fail_publish/src/main.rs +++ b/tests/ui-cargo/cargo_common_metadata/fail_publish/src/main.rs @@ -1,4 +1,4 @@ -// compile-flags: --crate-name=cargo_common_metadata +//@compile-flags: --crate-name=cargo_common_metadata #![warn(clippy::cargo_common_metadata)] fn main() {} diff --git a/tests/ui-cargo/cargo_common_metadata/fail_publish_true/src/main.rs b/tests/ui-cargo/cargo_common_metadata/fail_publish_true/src/main.rs index 27841e18aa9..1a69bb24101 100644 --- a/tests/ui-cargo/cargo_common_metadata/fail_publish_true/src/main.rs +++ b/tests/ui-cargo/cargo_common_metadata/fail_publish_true/src/main.rs @@ -1,4 +1,4 @@ -// compile-flags: --crate-name=cargo_common_metadata +//@compile-flags: --crate-name=cargo_common_metadata #![warn(clippy::cargo_common_metadata)] fn main() {} diff --git a/tests/ui-cargo/cargo_common_metadata/pass/src/main.rs b/tests/ui-cargo/cargo_common_metadata/pass/src/main.rs index 27841e18aa9..1a69bb24101 100644 --- a/tests/ui-cargo/cargo_common_metadata/pass/src/main.rs +++ b/tests/ui-cargo/cargo_common_metadata/pass/src/main.rs @@ -1,4 +1,4 @@ -// compile-flags: --crate-name=cargo_common_metadata +//@compile-flags: --crate-name=cargo_common_metadata #![warn(clippy::cargo_common_metadata)] fn main() {} diff --git a/tests/ui-cargo/cargo_common_metadata/pass_publish_empty/src/main.rs b/tests/ui-cargo/cargo_common_metadata/pass_publish_empty/src/main.rs index 27841e18aa9..1a69bb24101 100644 --- a/tests/ui-cargo/cargo_common_metadata/pass_publish_empty/src/main.rs +++ b/tests/ui-cargo/cargo_common_metadata/pass_publish_empty/src/main.rs @@ -1,4 +1,4 @@ -// compile-flags: --crate-name=cargo_common_metadata +//@compile-flags: --crate-name=cargo_common_metadata #![warn(clippy::cargo_common_metadata)] fn main() {} diff --git a/tests/ui-cargo/cargo_common_metadata/pass_publish_false/src/main.rs b/tests/ui-cargo/cargo_common_metadata/pass_publish_false/src/main.rs index 27841e18aa9..1a69bb24101 100644 --- a/tests/ui-cargo/cargo_common_metadata/pass_publish_false/src/main.rs +++ b/tests/ui-cargo/cargo_common_metadata/pass_publish_false/src/main.rs @@ -1,4 +1,4 @@ -// compile-flags: --crate-name=cargo_common_metadata +//@compile-flags: --crate-name=cargo_common_metadata #![warn(clippy::cargo_common_metadata)] fn main() {} diff --git a/tests/ui-cargo/feature_name/fail/src/main.rs b/tests/ui-cargo/feature_name/fail/src/main.rs index 64f01a98c90..4dd9582aff8 100644 --- a/tests/ui-cargo/feature_name/fail/src/main.rs +++ b/tests/ui-cargo/feature_name/fail/src/main.rs @@ -1,4 +1,4 @@ -// compile-flags: --crate-name=feature_name +//@compile-flags: --crate-name=feature_name #![warn(clippy::redundant_feature_names)] #![warn(clippy::negative_feature_names)] diff --git a/tests/ui-cargo/feature_name/pass/src/main.rs b/tests/ui-cargo/feature_name/pass/src/main.rs index 64f01a98c90..4dd9582aff8 100644 --- a/tests/ui-cargo/feature_name/pass/src/main.rs +++ b/tests/ui-cargo/feature_name/pass/src/main.rs @@ -1,4 +1,4 @@ -// compile-flags: --crate-name=feature_name +//@compile-flags: --crate-name=feature_name #![warn(clippy::redundant_feature_names)] #![warn(clippy::negative_feature_names)] diff --git a/tests/ui-cargo/module_style/fail_mod_remap/src/main.rs b/tests/ui-cargo/module_style/fail_mod_remap/src/main.rs index ba4c8c873dd..c70d92e359e 100644 --- a/tests/ui-cargo/module_style/fail_mod_remap/src/main.rs +++ b/tests/ui-cargo/module_style/fail_mod_remap/src/main.rs @@ -1,4 +1,4 @@ -// compile-flags: --remap-path-prefix {{src-base}}=/remapped +//@compile-flags: --remap-path-prefix {{src-base}}=/remapped #![warn(clippy::self_named_module_files)] diff --git a/tests/ui-cargo/multiple_crate_versions/5041_allow_dev_build/src/main.rs b/tests/ui-cargo/multiple_crate_versions/5041_allow_dev_build/src/main.rs index 1b2d3ec9459..ece260b743d 100644 --- a/tests/ui-cargo/multiple_crate_versions/5041_allow_dev_build/src/main.rs +++ b/tests/ui-cargo/multiple_crate_versions/5041_allow_dev_build/src/main.rs @@ -1,4 +1,4 @@ -// compile-flags: --crate-name=multiple_crate_versions +//@compile-flags: --crate-name=multiple_crate_versions #![warn(clippy::multiple_crate_versions)] fn main() {} diff --git a/tests/ui-cargo/multiple_crate_versions/fail/src/main.rs b/tests/ui-cargo/multiple_crate_versions/fail/src/main.rs index 1b2d3ec9459..ece260b743d 100644 --- a/tests/ui-cargo/multiple_crate_versions/fail/src/main.rs +++ b/tests/ui-cargo/multiple_crate_versions/fail/src/main.rs @@ -1,4 +1,4 @@ -// compile-flags: --crate-name=multiple_crate_versions +//@compile-flags: --crate-name=multiple_crate_versions #![warn(clippy::multiple_crate_versions)] fn main() {} diff --git a/tests/ui-cargo/multiple_crate_versions/pass/src/main.rs b/tests/ui-cargo/multiple_crate_versions/pass/src/main.rs index 1b2d3ec9459..ece260b743d 100644 --- a/tests/ui-cargo/multiple_crate_versions/pass/src/main.rs +++ b/tests/ui-cargo/multiple_crate_versions/pass/src/main.rs @@ -1,4 +1,4 @@ -// compile-flags: --crate-name=multiple_crate_versions +//@compile-flags: --crate-name=multiple_crate_versions #![warn(clippy::multiple_crate_versions)] fn main() {} diff --git a/tests/ui-cargo/wildcard_dependencies/fail/src/main.rs b/tests/ui-cargo/wildcard_dependencies/fail/src/main.rs index 581babfeacb..bb3a39d0720 100644 --- a/tests/ui-cargo/wildcard_dependencies/fail/src/main.rs +++ b/tests/ui-cargo/wildcard_dependencies/fail/src/main.rs @@ -1,4 +1,4 @@ -// compile-flags: --crate-name=wildcard_dependencies +//@compile-flags: --crate-name=wildcard_dependencies #![warn(clippy::wildcard_dependencies)] fn main() {} diff --git a/tests/ui-cargo/wildcard_dependencies/pass/src/main.rs b/tests/ui-cargo/wildcard_dependencies/pass/src/main.rs index 581babfeacb..bb3a39d0720 100644 --- a/tests/ui-cargo/wildcard_dependencies/pass/src/main.rs +++ b/tests/ui-cargo/wildcard_dependencies/pass/src/main.rs @@ -1,4 +1,4 @@ -// compile-flags: --crate-name=wildcard_dependencies +//@compile-flags: --crate-name=wildcard_dependencies #![warn(clippy::wildcard_dependencies)] fn main() {} diff --git a/tests/ui-internal/collapsible_span_lint_calls.fixed b/tests/ui-internal/collapsible_span_lint_calls.fixed index 9f299d7dec7..72c04bf80b6 100644 --- a/tests/ui-internal/collapsible_span_lint_calls.fixed +++ b/tests/ui-internal/collapsible_span_lint_calls.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![deny(clippy::internal)] #![allow(clippy::missing_clippy_version_attribute)] #![feature(rustc_private)] diff --git a/tests/ui-internal/collapsible_span_lint_calls.rs b/tests/ui-internal/collapsible_span_lint_calls.rs index 2b113f555e4..76f7c3ce94d 100644 --- a/tests/ui-internal/collapsible_span_lint_calls.rs +++ b/tests/ui-internal/collapsible_span_lint_calls.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![deny(clippy::internal)] #![allow(clippy::missing_clippy_version_attribute)] #![feature(rustc_private)] diff --git a/tests/ui-internal/custom_ice_message.rs b/tests/ui-internal/custom_ice_message.rs index 837811bdf1e..acb98d7ba98 100644 --- a/tests/ui-internal/custom_ice_message.rs +++ b/tests/ui-internal/custom_ice_message.rs @@ -1,9 +1,9 @@ -// rustc-env:RUST_BACKTRACE=0 -// normalize-stderr-test: "Clippy version: .*" -> "Clippy version: foo" -// normalize-stderr-test: "produce_ice.rs:\d*:\d*" -> "produce_ice.rs" -// normalize-stderr-test: "', .*clippy_lints" -> "', clippy_lints" -// normalize-stderr-test: "'rustc'" -> "''" -// normalize-stderr-test: "(?ms)query stack during panic:\n.*end of query stack\n" -> "" +//@rustc-env:RUST_BACKTRACE=0 +//@normalize-stderr-test: "Clippy version: .*" -> "Clippy version: foo" +//@normalize-stderr-test: "produce_ice.rs:\d*:\d*" -> "produce_ice.rs" +//@normalize-stderr-test: "', .*clippy_lints" -> "', clippy_lints" +//@normalize-stderr-test: "'rustc'" -> "''" +//@normalize-stderr-test: "(?ms)query stack during panic:\n.*end of query stack\n" -> "" #![deny(clippy::internal)] #![allow(clippy::missing_clippy_version_attribute)] diff --git a/tests/ui-internal/interning_defined_symbol.fixed b/tests/ui-internal/interning_defined_symbol.fixed index eaea218e128..a1a10c0798e 100644 --- a/tests/ui-internal/interning_defined_symbol.fixed +++ b/tests/ui-internal/interning_defined_symbol.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![deny(clippy::internal)] #![allow(clippy::missing_clippy_version_attribute, clippy::let_unit_value)] #![feature(rustc_private)] diff --git a/tests/ui-internal/interning_defined_symbol.rs b/tests/ui-internal/interning_defined_symbol.rs index 7efebb8fae4..32dbfe5dcac 100644 --- a/tests/ui-internal/interning_defined_symbol.rs +++ b/tests/ui-internal/interning_defined_symbol.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![deny(clippy::internal)] #![allow(clippy::missing_clippy_version_attribute, clippy::let_unit_value)] #![feature(rustc_private)] diff --git a/tests/ui-internal/invalid_msrv_attr_impl.fixed b/tests/ui-internal/invalid_msrv_attr_impl.fixed index 08634063a57..ac0752774f3 100644 --- a/tests/ui-internal/invalid_msrv_attr_impl.fixed +++ b/tests/ui-internal/invalid_msrv_attr_impl.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![deny(clippy::internal)] #![allow(clippy::missing_clippy_version_attribute)] diff --git a/tests/ui-internal/invalid_msrv_attr_impl.rs b/tests/ui-internal/invalid_msrv_attr_impl.rs index f8af77e6d39..56f778621a4 100644 --- a/tests/ui-internal/invalid_msrv_attr_impl.rs +++ b/tests/ui-internal/invalid_msrv_attr_impl.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![deny(clippy::internal)] #![allow(clippy::missing_clippy_version_attribute)] diff --git a/tests/ui-internal/outer_expn_data.fixed b/tests/ui-internal/outer_expn_data.fixed index bb82faf0c90..d8a08bc9997 100644 --- a/tests/ui-internal/outer_expn_data.fixed +++ b/tests/ui-internal/outer_expn_data.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![deny(clippy::internal)] #![allow(clippy::missing_clippy_version_attribute)] diff --git a/tests/ui-internal/outer_expn_data.rs b/tests/ui-internal/outer_expn_data.rs index 187d468b392..f7af0e9d8be 100644 --- a/tests/ui-internal/outer_expn_data.rs +++ b/tests/ui-internal/outer_expn_data.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![deny(clippy::internal)] #![allow(clippy::missing_clippy_version_attribute)] diff --git a/tests/ui-internal/unnecessary_def_path.fixed b/tests/ui-internal/unnecessary_def_path.fixed index e474f370a5d..fce24412f84 100644 --- a/tests/ui-internal/unnecessary_def_path.fixed +++ b/tests/ui-internal/unnecessary_def_path.fixed @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build:paths.rs +//@run-rustfix +//@aux-build:paths.rs #![deny(clippy::internal)] #![feature(rustc_private)] diff --git a/tests/ui-internal/unnecessary_def_path.rs b/tests/ui-internal/unnecessary_def_path.rs index f17fed6c653..b10bc9e46e2 100644 --- a/tests/ui-internal/unnecessary_def_path.rs +++ b/tests/ui-internal/unnecessary_def_path.rs @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build:paths.rs +//@run-rustfix +//@aux-build:paths.rs #![deny(clippy::internal)] #![feature(rustc_private)] diff --git a/tests/ui-internal/unnecessary_symbol_str.fixed b/tests/ui-internal/unnecessary_symbol_str.fixed index 6033d06e4f6..b802de1cbc6 100644 --- a/tests/ui-internal/unnecessary_symbol_str.fixed +++ b/tests/ui-internal/unnecessary_symbol_str.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![feature(rustc_private)] #![deny(clippy::internal)] #![allow( diff --git a/tests/ui-internal/unnecessary_symbol_str.rs b/tests/ui-internal/unnecessary_symbol_str.rs index 1bb5d55f0b6..c1bead5bdc9 100644 --- a/tests/ui-internal/unnecessary_symbol_str.rs +++ b/tests/ui-internal/unnecessary_symbol_str.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![feature(rustc_private)] #![deny(clippy::internal)] #![allow( diff --git a/tests/ui-toml/allow_mixed_uninlined_format_args/uninlined_format_args.fixed b/tests/ui-toml/allow_mixed_uninlined_format_args/uninlined_format_args.fixed index aa8b45b5fe7..23e7bc16d23 100644 --- a/tests/ui-toml/allow_mixed_uninlined_format_args/uninlined_format_args.fixed +++ b/tests/ui-toml/allow_mixed_uninlined_format_args/uninlined_format_args.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::uninlined_format_args)] fn main() { diff --git a/tests/ui-toml/allow_mixed_uninlined_format_args/uninlined_format_args.rs b/tests/ui-toml/allow_mixed_uninlined_format_args/uninlined_format_args.rs index ad2e4863ee8..d66b2b8ff6a 100644 --- a/tests/ui-toml/allow_mixed_uninlined_format_args/uninlined_format_args.rs +++ b/tests/ui-toml/allow_mixed_uninlined_format_args/uninlined_format_args.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::uninlined_format_args)] fn main() { diff --git a/tests/ui-toml/dbg_macro/dbg_macro.rs b/tests/ui-toml/dbg_macro/dbg_macro.rs index 5d9ce18f631..21e4fce26e4 100644 --- a/tests/ui-toml/dbg_macro/dbg_macro.rs +++ b/tests/ui-toml/dbg_macro/dbg_macro.rs @@ -1,4 +1,4 @@ -// compile-flags: --test +//@compile-flags: --test #![warn(clippy::dbg_macro)] fn foo(n: u32) -> u32 { diff --git a/tests/ui-toml/disallowed_macros/disallowed_macros.rs b/tests/ui-toml/disallowed_macros/disallowed_macros.rs index 2bb5376076e..ba919b48788 100644 --- a/tests/ui-toml/disallowed_macros/disallowed_macros.rs +++ b/tests/ui-toml/disallowed_macros/disallowed_macros.rs @@ -1,4 +1,4 @@ -// aux-build:macros.rs +//@aux-build:macros.rs #![allow(unused)] diff --git a/tests/ui-toml/expect_used/expect_used.rs b/tests/ui-toml/expect_used/expect_used.rs index 89f142a150d..9e267c89300 100644 --- a/tests/ui-toml/expect_used/expect_used.rs +++ b/tests/ui-toml/expect_used/expect_used.rs @@ -1,4 +1,4 @@ -// compile-flags: --test +//@compile-flags: --test #![warn(clippy::expect_used)] fn expect_option() { diff --git a/tests/ui-toml/mut_key/mut_key.rs b/tests/ui-toml/mut_key/mut_key.rs index 667c51cb4a3..095e0d15448 100644 --- a/tests/ui-toml/mut_key/mut_key.rs +++ b/tests/ui-toml/mut_key/mut_key.rs @@ -1,4 +1,4 @@ -// compile-flags: --crate-name mut_key +//@compile-flags: --crate-name mut_key #![warn(clippy::mutable_key_type)] diff --git a/tests/ui-toml/nonstandard_macro_braces/auxiliary/proc_macro_derive.rs b/tests/ui-toml/nonstandard_macro_braces/auxiliary/proc_macro_derive.rs index 6452189a461..f5761c6afeb 100644 --- a/tests/ui-toml/nonstandard_macro_braces/auxiliary/proc_macro_derive.rs +++ b/tests/ui-toml/nonstandard_macro_braces/auxiliary/proc_macro_derive.rs @@ -1,5 +1,5 @@ -// compile-flags: --emit=link -// no-prefer-dynamic +//@compile-flags: --emit=link +//@no-prefer-dynamic #![crate_type = "proc-macro"] diff --git a/tests/ui-toml/nonstandard_macro_braces/conf_nonstandard_macro_braces.fixed b/tests/ui-toml/nonstandard_macro_braces/conf_nonstandard_macro_braces.fixed index 01d135764df..e4747bedddb 100644 --- a/tests/ui-toml/nonstandard_macro_braces/conf_nonstandard_macro_braces.fixed +++ b/tests/ui-toml/nonstandard_macro_braces/conf_nonstandard_macro_braces.fixed @@ -1,5 +1,5 @@ -// aux-build:proc_macro_derive.rs -// run-rustfix +//@aux-build:proc_macro_derive.rs +//@run-rustfix #![warn(clippy::nonstandard_macro_braces)] diff --git a/tests/ui-toml/nonstandard_macro_braces/conf_nonstandard_macro_braces.rs b/tests/ui-toml/nonstandard_macro_braces/conf_nonstandard_macro_braces.rs index 72883e8270c..54edded99f4 100644 --- a/tests/ui-toml/nonstandard_macro_braces/conf_nonstandard_macro_braces.rs +++ b/tests/ui-toml/nonstandard_macro_braces/conf_nonstandard_macro_braces.rs @@ -1,5 +1,5 @@ -// aux-build:proc_macro_derive.rs -// run-rustfix +//@aux-build:proc_macro_derive.rs +//@run-rustfix #![warn(clippy::nonstandard_macro_braces)] diff --git a/tests/ui-toml/print_macro/print_macro.rs b/tests/ui-toml/print_macro/print_macro.rs index 5aefb6a6b4d..3a8b30cca36 100644 --- a/tests/ui-toml/print_macro/print_macro.rs +++ b/tests/ui-toml/print_macro/print_macro.rs @@ -1,4 +1,4 @@ -// compile-flags: --test +//@compile-flags: --test #![warn(clippy::print_stdout)] #![warn(clippy::print_stderr)] diff --git a/tests/ui-toml/toml_disallowed_methods/conf_disallowed_methods.rs b/tests/ui-toml/toml_disallowed_methods/conf_disallowed_methods.rs index 2f3160c8338..8e1a1710a6c 100644 --- a/tests/ui-toml/toml_disallowed_methods/conf_disallowed_methods.rs +++ b/tests/ui-toml/toml_disallowed_methods/conf_disallowed_methods.rs @@ -1,4 +1,4 @@ -// compile-flags: --crate-name conf_disallowed_methods +//@compile-flags: --crate-name conf_disallowed_methods #![warn(clippy::disallowed_methods)] diff --git a/tests/ui-toml/toml_trivially_copy/test.rs b/tests/ui-toml/toml_trivially_copy/test.rs index fb0e226f3aa..179b1266169 100644 --- a/tests/ui-toml/toml_trivially_copy/test.rs +++ b/tests/ui-toml/toml_trivially_copy/test.rs @@ -1,5 +1,5 @@ -// normalize-stderr-test "\(\d+ byte\)" -> "(N byte)" -// normalize-stderr-test "\(limit: \d+ byte\)" -> "(limit: N byte)" +//@normalize-stderr-test: "\(\d+ byte\)" -> "(N byte)" +//@normalize-stderr-test: "\(limit: \d+ byte\)" -> "(limit: N byte)" #![deny(clippy::trivially_copy_pass_by_ref)] diff --git a/tests/ui-toml/toml_unknown_key/conf_unknown_key.rs b/tests/ui-toml/toml_unknown_key/conf_unknown_key.rs index f328e4d9d04..569fd2c3553 100644 --- a/tests/ui-toml/toml_unknown_key/conf_unknown_key.rs +++ b/tests/ui-toml/toml_unknown_key/conf_unknown_key.rs @@ -1 +1,3 @@ +//@error-pattern: unknown field `foobar`, expected one of + fn main() {} diff --git a/tests/ui-toml/unwrap_used/unwrap_used.rs b/tests/ui-toml/unwrap_used/unwrap_used.rs index 6525ea5bfc3..5d3e800cadd 100644 --- a/tests/ui-toml/unwrap_used/unwrap_used.rs +++ b/tests/ui-toml/unwrap_used/unwrap_used.rs @@ -1,4 +1,4 @@ -// compile-flags: --test +//@compile-flags: --test #![allow(unused_mut, clippy::get_first, clippy::from_iter_instead_of_collect)] #![warn(clippy::unwrap_used)] diff --git a/tests/ui/allow_attributes.fixed b/tests/ui/allow_attributes.fixed index b8dd0619e6d..f0936b2608e 100644 --- a/tests/ui/allow_attributes.fixed +++ b/tests/ui/allow_attributes.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused)] #![warn(clippy::allow_attributes)] #![feature(lint_reasons)] diff --git a/tests/ui/allow_attributes.rs b/tests/ui/allow_attributes.rs index 295f560906a..2fb9e86126e 100644 --- a/tests/ui/allow_attributes.rs +++ b/tests/ui/allow_attributes.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused)] #![warn(clippy::allow_attributes)] #![feature(lint_reasons)] diff --git a/tests/ui/almost_complete_range.fixed b/tests/ui/almost_complete_range.fixed index a4bf7fe18d5..5cd0dcce6f7 100644 --- a/tests/ui/almost_complete_range.fixed +++ b/tests/ui/almost_complete_range.fixed @@ -1,6 +1,6 @@ -// run-rustfix -// edition:2018 -// aux-build:proc_macros.rs +//@run-rustfix +//@edition:2018 +//@aux-build:proc_macros.rs #![feature(exclusive_range_pattern)] #![feature(stmt_expr_attributes)] diff --git a/tests/ui/almost_complete_range.rs b/tests/ui/almost_complete_range.rs index 8237c3a1361..db0bfc8afc3 100644 --- a/tests/ui/almost_complete_range.rs +++ b/tests/ui/almost_complete_range.rs @@ -1,6 +1,6 @@ -// run-rustfix -// edition:2018 -// aux-build:proc_macros.rs +//@run-rustfix +//@edition:2018 +//@aux-build:proc_macros.rs #![feature(exclusive_range_pattern)] #![feature(stmt_expr_attributes)] diff --git a/tests/ui/arithmetic_side_effects.rs b/tests/ui/arithmetic_side_effects.rs index ab7e66a264d..d864fe05800 100644 --- a/tests/ui/arithmetic_side_effects.rs +++ b/tests/ui/arithmetic_side_effects.rs @@ -1,4 +1,4 @@ -// aux-build:proc_macro_derive.rs +//@aux-build:proc_macro_derive.rs #![allow( clippy::assign_op_pattern, diff --git a/tests/ui/as_conversions.rs b/tests/ui/as_conversions.rs index c50d4088b5e..890bf0b0a7e 100644 --- a/tests/ui/as_conversions.rs +++ b/tests/ui/as_conversions.rs @@ -1,4 +1,4 @@ -// aux-build:proc_macros.rs +//@aux-build:proc_macros.rs #![warn(clippy::as_conversions)] #![allow(clippy::borrow_as_ptr)] diff --git a/tests/ui/as_underscore.fixed b/tests/ui/as_underscore.fixed index 948f6d8e6b1..69af84a0eae 100644 --- a/tests/ui/as_underscore.fixed +++ b/tests/ui/as_underscore.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::as_underscore)] diff --git a/tests/ui/as_underscore.rs b/tests/ui/as_underscore.rs index 97785ed08a8..a8cfb81d9a3 100644 --- a/tests/ui/as_underscore.rs +++ b/tests/ui/as_underscore.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::as_underscore)] diff --git a/tests/ui/asm_syntax.rs b/tests/ui/asm_syntax.rs index 0220bf3331f..c93995f939a 100644 --- a/tests/ui/asm_syntax.rs +++ b/tests/ui/asm_syntax.rs @@ -1,5 +1,5 @@ -// only-x86_64 -// ignore-aarch64 +//@only-x86_64 +//@ignore-aarch64 #[warn(clippy::inline_asm_x86_intel_syntax)] mod warn_intel { diff --git a/tests/ui/assertions_on_result_states.fixed b/tests/ui/assertions_on_result_states.fixed index 2bb755290c5..ea8b895664c 100644 --- a/tests/ui/assertions_on_result_states.fixed +++ b/tests/ui/assertions_on_result_states.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::assertions_on_result_states)] use std::result::Result; diff --git a/tests/ui/assertions_on_result_states.rs b/tests/ui/assertions_on_result_states.rs index d8a9bd2f1c4..6fc20f85988 100644 --- a/tests/ui/assertions_on_result_states.rs +++ b/tests/ui/assertions_on_result_states.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::assertions_on_result_states)] use std::result::Result; diff --git a/tests/ui/assign_ops.fixed b/tests/ui/assign_ops.fixed index da034b51cfd..b50682ea00c 100644 --- a/tests/ui/assign_ops.fixed +++ b/tests/ui/assign_ops.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix use core::num::Wrapping; diff --git a/tests/ui/assign_ops.rs b/tests/ui/assign_ops.rs index 337bb02c8a6..780d2d040f1 100644 --- a/tests/ui/assign_ops.rs +++ b/tests/ui/assign_ops.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix use core::num::Wrapping; diff --git a/tests/ui/async_yields_async.fixed b/tests/ui/async_yields_async.fixed index 579a63ea477..8d9b023893f 100644 --- a/tests/ui/async_yields_async.fixed +++ b/tests/ui/async_yields_async.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![feature(lint_reasons)] #![feature(async_closure)] #![warn(clippy::async_yields_async)] diff --git a/tests/ui/async_yields_async.rs b/tests/ui/async_yields_async.rs index 5aec2fb50f6..bed79062f01 100644 --- a/tests/ui/async_yields_async.rs +++ b/tests/ui/async_yields_async.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![feature(lint_reasons)] #![feature(async_closure)] #![warn(clippy::async_yields_async)] diff --git a/tests/ui/author/blocks.rs b/tests/ui/author/blocks.rs index a7335c01baa..164f7d0d9d6 100644 --- a/tests/ui/author/blocks.rs +++ b/tests/ui/author/blocks.rs @@ -1,4 +1,4 @@ -// edition:2018 +//@edition:2018 #![allow(redundant_semicolons, clippy::no_effect)] #![feature(stmt_expr_attributes)] diff --git a/tests/ui/auxiliary/proc_macro_attr.rs b/tests/ui/auxiliary/proc_macro_attr.rs index b498fece513..92c47b41a38 100644 --- a/tests/ui/auxiliary/proc_macro_attr.rs +++ b/tests/ui/auxiliary/proc_macro_attr.rs @@ -1,5 +1,5 @@ -// compile-flags: --emit=link -// no-prefer-dynamic +//@compile-flags: --emit=link +//@no-prefer-dynamic #![crate_type = "proc-macro"] #![feature(repr128, proc_macro_hygiene, proc_macro_quote, box_patterns)] diff --git a/tests/ui/auxiliary/proc_macro_derive.rs b/tests/ui/auxiliary/proc_macro_derive.rs index 13d93f5c275..5a924ca1830 100644 --- a/tests/ui/auxiliary/proc_macro_derive.rs +++ b/tests/ui/auxiliary/proc_macro_derive.rs @@ -1,5 +1,5 @@ -// compile-flags: --emit=link -// no-prefer-dynamic +//@compile-flags: --emit=link +//@no-prefer-dynamic #![crate_type = "proc-macro"] #![feature(repr128, proc_macro_quote)] diff --git a/tests/ui/auxiliary/proc_macro_suspicious_else_formatting.rs b/tests/ui/auxiliary/proc_macro_suspicious_else_formatting.rs index a2ef0fe827c..f13b76e44b0 100644 --- a/tests/ui/auxiliary/proc_macro_suspicious_else_formatting.rs +++ b/tests/ui/auxiliary/proc_macro_suspicious_else_formatting.rs @@ -1,5 +1,5 @@ -// compile-flags: --emit=link -// no-prefer-dynamic +//@compile-flags: --emit=link +//@no-prefer-dynamic #![crate_type = "proc-macro"] diff --git a/tests/ui/auxiliary/proc_macro_unsafe.rs b/tests/ui/auxiliary/proc_macro_unsafe.rs index 3c40f77469b..c2326678d0d 100644 --- a/tests/ui/auxiliary/proc_macro_unsafe.rs +++ b/tests/ui/auxiliary/proc_macro_unsafe.rs @@ -1,5 +1,5 @@ -// compile-flags: --emit=link -// no-prefer-dynamic +//@compile-flags: --emit=link +//@no-prefer-dynamic #![crate_type = "proc-macro"] diff --git a/tests/ui/auxiliary/proc_macros.rs b/tests/ui/auxiliary/proc_macros.rs index 3d5beab1eff..94f075ed09c 100644 --- a/tests/ui/auxiliary/proc_macros.rs +++ b/tests/ui/auxiliary/proc_macros.rs @@ -1,5 +1,5 @@ -// compile-flags: --emit=link -// no-prefer-dynamic +//@compile-flags: --emit=link +//@no-prefer-dynamic #![crate_type = "proc-macro"] #![feature(let_chains)] diff --git a/tests/ui/bind_instead_of_map.fixed b/tests/ui/bind_instead_of_map.fixed index d94e2ac6072..ea2dc2e2293 100644 --- a/tests/ui/bind_instead_of_map.fixed +++ b/tests/ui/bind_instead_of_map.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![deny(clippy::bind_instead_of_map)] #![allow(clippy::uninlined_format_args)] diff --git a/tests/ui/bind_instead_of_map.rs b/tests/ui/bind_instead_of_map.rs index 86f31f58284..1db58dae538 100644 --- a/tests/ui/bind_instead_of_map.rs +++ b/tests/ui/bind_instead_of_map.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![deny(clippy::bind_instead_of_map)] #![allow(clippy::uninlined_format_args)] diff --git a/tests/ui/bind_instead_of_map_multipart.fixed b/tests/ui/bind_instead_of_map_multipart.fixed index e1589843226..63c7aafcddb 100644 --- a/tests/ui/bind_instead_of_map_multipart.fixed +++ b/tests/ui/bind_instead_of_map_multipart.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![deny(clippy::bind_instead_of_map)] #![allow(clippy::blocks_in_if_conditions)] diff --git a/tests/ui/bind_instead_of_map_multipart.rs b/tests/ui/bind_instead_of_map_multipart.rs index 49944403f6d..69b982fa8a2 100644 --- a/tests/ui/bind_instead_of_map_multipart.rs +++ b/tests/ui/bind_instead_of_map_multipart.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![deny(clippy::bind_instead_of_map)] #![allow(clippy::blocks_in_if_conditions)] diff --git a/tests/ui/blanket_clippy_restriction_lints.rs b/tests/ui/blanket_clippy_restriction_lints.rs index 554745368bc..e1ff25c54cf 100644 --- a/tests/ui/blanket_clippy_restriction_lints.rs +++ b/tests/ui/blanket_clippy_restriction_lints.rs @@ -1,4 +1,4 @@ -// compile-flags: -W clippy::restriction +//@compile-flags: -W clippy::restriction #![warn(clippy::blanket_clippy_restriction_lints)] diff --git a/tests/ui/blocks_in_if_conditions.fixed b/tests/ui/blocks_in_if_conditions.fixed index e6e40a9948c..a9f18782e58 100644 --- a/tests/ui/blocks_in_if_conditions.fixed +++ b/tests/ui/blocks_in_if_conditions.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::blocks_in_if_conditions)] #![allow(unused, clippy::let_and_return)] #![warn(clippy::nonminimal_bool)] diff --git a/tests/ui/blocks_in_if_conditions.rs b/tests/ui/blocks_in_if_conditions.rs index 69387ff5782..0a70317c4d4 100644 --- a/tests/ui/blocks_in_if_conditions.rs +++ b/tests/ui/blocks_in_if_conditions.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::blocks_in_if_conditions)] #![allow(unused, clippy::let_and_return)] #![warn(clippy::nonminimal_bool)] diff --git a/tests/ui/bool_assert_comparison.fixed b/tests/ui/bool_assert_comparison.fixed index b8dd92906c8..53f63444aef 100644 --- a/tests/ui/bool_assert_comparison.fixed +++ b/tests/ui/bool_assert_comparison.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused, clippy::assertions_on_constants)] #![warn(clippy::bool_assert_comparison)] diff --git a/tests/ui/bool_assert_comparison.rs b/tests/ui/bool_assert_comparison.rs index 0a8ad34fda5..151d93a9233 100644 --- a/tests/ui/bool_assert_comparison.rs +++ b/tests/ui/bool_assert_comparison.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused, clippy::assertions_on_constants)] #![warn(clippy::bool_assert_comparison)] diff --git a/tests/ui/bool_comparison.fixed b/tests/ui/bool_comparison.fixed index 5a012ff4d27..670eef6a21d 100644 --- a/tests/ui/bool_comparison.fixed +++ b/tests/ui/bool_comparison.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::bool_comparison)] diff --git a/tests/ui/bool_comparison.rs b/tests/ui/bool_comparison.rs index c534bc25c20..72851be635d 100644 --- a/tests/ui/bool_comparison.rs +++ b/tests/ui/bool_comparison.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::bool_comparison)] diff --git a/tests/ui/bool_to_int_with_if.fixed b/tests/ui/bool_to_int_with_if.fixed index 37d3e3286a4..9831c3373d4 100644 --- a/tests/ui/bool_to_int_with_if.fixed +++ b/tests/ui/bool_to_int_with_if.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![feature(let_chains)] #![warn(clippy::bool_to_int_with_if)] diff --git a/tests/ui/bool_to_int_with_if.rs b/tests/ui/bool_to_int_with_if.rs index ebdf86fd185..5e3047bb32c 100644 --- a/tests/ui/bool_to_int_with_if.rs +++ b/tests/ui/bool_to_int_with_if.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![feature(let_chains)] #![warn(clippy::bool_to_int_with_if)] diff --git a/tests/ui/borrow_as_ptr.fixed b/tests/ui/borrow_as_ptr.fixed index ff5c6a8c377..3f440ce0045 100644 --- a/tests/ui/borrow_as_ptr.fixed +++ b/tests/ui/borrow_as_ptr.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::borrow_as_ptr)] fn main() { diff --git a/tests/ui/borrow_as_ptr.rs b/tests/ui/borrow_as_ptr.rs index 0f62ec6ee58..c1ca9180eef 100644 --- a/tests/ui/borrow_as_ptr.rs +++ b/tests/ui/borrow_as_ptr.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::borrow_as_ptr)] fn main() { diff --git a/tests/ui/borrow_as_ptr_no_std.fixed b/tests/ui/borrow_as_ptr_no_std.fixed index eaba3b1c20c..10f2727c793 100644 --- a/tests/ui/borrow_as_ptr_no_std.fixed +++ b/tests/ui/borrow_as_ptr_no_std.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::borrow_as_ptr)] #![feature(lang_items, start, libc)] #![no_std] diff --git a/tests/ui/borrow_as_ptr_no_std.rs b/tests/ui/borrow_as_ptr_no_std.rs index d83f9d1f875..311e9341aac 100644 --- a/tests/ui/borrow_as_ptr_no_std.rs +++ b/tests/ui/borrow_as_ptr_no_std.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::borrow_as_ptr)] #![feature(lang_items, start, libc)] #![no_std] diff --git a/tests/ui/borrow_deref_ref.fixed b/tests/ui/borrow_deref_ref.fixed index bf4691c5bc9..165e4bc8272 100644 --- a/tests/ui/borrow_deref_ref.fixed +++ b/tests/ui/borrow_deref_ref.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(dead_code, unused_variables)] diff --git a/tests/ui/borrow_deref_ref.rs b/tests/ui/borrow_deref_ref.rs index 28c005fdbef..66c8d69bef9 100644 --- a/tests/ui/borrow_deref_ref.rs +++ b/tests/ui/borrow_deref_ref.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(dead_code, unused_variables)] diff --git a/tests/ui/borrow_interior_mutable_const/enums.rs b/tests/ui/borrow_interior_mutable_const/enums.rs index 5027db44561..29b08ab3643 100644 --- a/tests/ui/borrow_interior_mutable_const/enums.rs +++ b/tests/ui/borrow_interior_mutable_const/enums.rs @@ -1,4 +1,4 @@ -// aux-build:helper.rs +//@aux-build:helper.rs #![warn(clippy::borrow_interior_mutable_const)] #![allow(clippy::declare_interior_mutable_const)] diff --git a/tests/ui/box_default.fixed b/tests/ui/box_default.fixed index 59c0baf8718..6afce208769 100644 --- a/tests/ui/box_default.fixed +++ b/tests/ui/box_default.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::box_default)] #[derive(Default)] diff --git a/tests/ui/box_default.rs b/tests/ui/box_default.rs index f7d832193a3..09365618e63 100644 --- a/tests/ui/box_default.rs +++ b/tests/ui/box_default.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::box_default)] #[derive(Default)] diff --git a/tests/ui/bytes_count_to_len.fixed b/tests/ui/bytes_count_to_len.fixed index 860642363b5..fb3d521badd 100644 --- a/tests/ui/bytes_count_to_len.fixed +++ b/tests/ui/bytes_count_to_len.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::bytes_count_to_len)] use std::fs::File; use std::io::Read; diff --git a/tests/ui/bytes_count_to_len.rs b/tests/ui/bytes_count_to_len.rs index 162730c2842..8e256b8f0b8 100644 --- a/tests/ui/bytes_count_to_len.rs +++ b/tests/ui/bytes_count_to_len.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::bytes_count_to_len)] use std::fs::File; use std::io::Read; diff --git a/tests/ui/bytes_nth.fixed b/tests/ui/bytes_nth.fixed index a35c679afb7..d3e0f676b29 100644 --- a/tests/ui/bytes_nth.fixed +++ b/tests/ui/bytes_nth.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(clippy::unnecessary_operation)] #![warn(clippy::bytes_nth)] diff --git a/tests/ui/bytes_nth.rs b/tests/ui/bytes_nth.rs index 1ecffea5303..b7d813fe296 100644 --- a/tests/ui/bytes_nth.rs +++ b/tests/ui/bytes_nth.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(clippy::unnecessary_operation)] #![warn(clippy::bytes_nth)] diff --git a/tests/ui/case_sensitive_file_extension_comparisons.fixed b/tests/ui/case_sensitive_file_extension_comparisons.fixed index 5fbaa64db39..d5af22aefe5 100644 --- a/tests/ui/case_sensitive_file_extension_comparisons.fixed +++ b/tests/ui/case_sensitive_file_extension_comparisons.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::case_sensitive_file_extension_comparisons)] use std::string::String; diff --git a/tests/ui/case_sensitive_file_extension_comparisons.rs b/tests/ui/case_sensitive_file_extension_comparisons.rs index 3c0d4821f9f..f5f0a0022a4 100644 --- a/tests/ui/case_sensitive_file_extension_comparisons.rs +++ b/tests/ui/case_sensitive_file_extension_comparisons.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::case_sensitive_file_extension_comparisons)] use std::string::String; diff --git a/tests/ui/cast_abs_to_unsigned.fixed b/tests/ui/cast_abs_to_unsigned.fixed index 8676b562b4f..ef0a93b01d1 100644 --- a/tests/ui/cast_abs_to_unsigned.fixed +++ b/tests/ui/cast_abs_to_unsigned.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::cast_abs_to_unsigned)] #![allow(clippy::uninlined_format_args, unused)] diff --git a/tests/ui/cast_abs_to_unsigned.rs b/tests/ui/cast_abs_to_unsigned.rs index 5775af874f8..96ced670a05 100644 --- a/tests/ui/cast_abs_to_unsigned.rs +++ b/tests/ui/cast_abs_to_unsigned.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::cast_abs_to_unsigned)] #![allow(clippy::uninlined_format_args, unused)] diff --git a/tests/ui/cast_lossless_bool.fixed b/tests/ui/cast_lossless_bool.fixed index 13b3cf838c9..c321cc64437 100644 --- a/tests/ui/cast_lossless_bool.fixed +++ b/tests/ui/cast_lossless_bool.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(dead_code)] #![warn(clippy::cast_lossless)] diff --git a/tests/ui/cast_lossless_bool.rs b/tests/ui/cast_lossless_bool.rs index 3eed2135562..632a718920d 100644 --- a/tests/ui/cast_lossless_bool.rs +++ b/tests/ui/cast_lossless_bool.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(dead_code)] #![warn(clippy::cast_lossless)] diff --git a/tests/ui/cast_lossless_float.fixed b/tests/ui/cast_lossless_float.fixed index 32a9c1c4ae1..e72a0096acc 100644 --- a/tests/ui/cast_lossless_float.fixed +++ b/tests/ui/cast_lossless_float.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(clippy::no_effect, clippy::unnecessary_operation, dead_code)] #![warn(clippy::cast_lossless)] diff --git a/tests/ui/cast_lossless_float.rs b/tests/ui/cast_lossless_float.rs index 6f5ddcfe09c..dbcbaa9b815 100644 --- a/tests/ui/cast_lossless_float.rs +++ b/tests/ui/cast_lossless_float.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(clippy::no_effect, clippy::unnecessary_operation, dead_code)] #![warn(clippy::cast_lossless)] diff --git a/tests/ui/cast_lossless_integer.fixed b/tests/ui/cast_lossless_integer.fixed index 925cbf25368..7dab02084fc 100644 --- a/tests/ui/cast_lossless_integer.fixed +++ b/tests/ui/cast_lossless_integer.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(clippy::no_effect, clippy::unnecessary_operation, dead_code)] #![warn(clippy::cast_lossless)] diff --git a/tests/ui/cast_lossless_integer.rs b/tests/ui/cast_lossless_integer.rs index c82bd9108d2..c24f73960b0 100644 --- a/tests/ui/cast_lossless_integer.rs +++ b/tests/ui/cast_lossless_integer.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(clippy::no_effect, clippy::unnecessary_operation, dead_code)] #![warn(clippy::cast_lossless)] diff --git a/tests/ui/cast_raw_slice_pointer_cast.fixed b/tests/ui/cast_raw_slice_pointer_cast.fixed index b70c1912951..9b6fee270ee 100644 --- a/tests/ui/cast_raw_slice_pointer_cast.fixed +++ b/tests/ui/cast_raw_slice_pointer_cast.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::cast_slice_from_raw_parts)] #[allow(unused_imports, unused_unsafe)] diff --git a/tests/ui/cast_raw_slice_pointer_cast.rs b/tests/ui/cast_raw_slice_pointer_cast.rs index c1b316765c9..c0bb8137990 100644 --- a/tests/ui/cast_raw_slice_pointer_cast.rs +++ b/tests/ui/cast_raw_slice_pointer_cast.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::cast_slice_from_raw_parts)] #[allow(unused_imports, unused_unsafe)] diff --git a/tests/ui/cast_size.rs b/tests/ui/cast_size.rs index 595109be46b..cd2184aea38 100644 --- a/tests/ui/cast_size.rs +++ b/tests/ui/cast_size.rs @@ -1,4 +1,4 @@ -// ignore-32bit +//@ignore-32bit #[warn( clippy::cast_precision_loss, clippy::cast_possible_truncation, diff --git a/tests/ui/cast_size_32bit.rs b/tests/ui/cast_size_32bit.rs index 99aac6deca3..7ca20d3ca4a 100644 --- a/tests/ui/cast_size_32bit.rs +++ b/tests/ui/cast_size_32bit.rs @@ -1,4 +1,4 @@ -// ignore-64bit +//@ignore-64bit #[warn( clippy::cast_precision_loss, clippy::cast_possible_truncation, diff --git a/tests/ui/cast_size_32bit.stderr b/tests/ui/cast_size_32bit.stderr index 8990c3ba739..fb51783a487 100644 --- a/tests/ui/cast_size_32bit.stderr +++ b/tests/ui/cast_size_32bit.stderr @@ -4,7 +4,12 @@ error: casting `isize` to `i8` may truncate the value LL | 1isize as i8; | ^^^^^^^^^^^^ | + = help: if this is intentional allow the lint with `#[allow(clippy::cast_possible_truncation)]` ... = note: `-D clippy::cast-possible-truncation` implied by `-D warnings` +help: ... or use `try_from` and handle the error accordingly + | +LL | i8::try_from(1isize); + | ~~~~~~~~~~~~~~~~~~~~ error: casting `isize` to `f64` causes a loss of precision on targets with 64-bit wide pointers (`isize` is 64 bits wide, but `f64`'s mantissa is only 52 bits wide) --> $DIR/cast_size_32bit.rs:15:5 @@ -37,24 +42,48 @@ error: casting `isize` to `i32` may truncate the value on targets with 64-bit wi | LL | 1isize as i32; | ^^^^^^^^^^^^^ + | + = help: if this is intentional allow the lint with `#[allow(clippy::cast_possible_truncation)]` ... +help: ... or use `try_from` and handle the error accordingly + | +LL | i32::try_from(1isize); + | ~~~~~~~~~~~~~~~~~~~~~ error: casting `isize` to `u32` may truncate the value on targets with 64-bit wide pointers --> $DIR/cast_size_32bit.rs:20:5 | LL | 1isize as u32; | ^^^^^^^^^^^^^ + | + = help: if this is intentional allow the lint with `#[allow(clippy::cast_possible_truncation)]` ... +help: ... or use `try_from` and handle the error accordingly + | +LL | u32::try_from(1isize); + | ~~~~~~~~~~~~~~~~~~~~~ error: casting `usize` to `u32` may truncate the value on targets with 64-bit wide pointers --> $DIR/cast_size_32bit.rs:21:5 | LL | 1usize as u32; | ^^^^^^^^^^^^^ + | + = help: if this is intentional allow the lint with `#[allow(clippy::cast_possible_truncation)]` ... +help: ... or use `try_from` and handle the error accordingly + | +LL | u32::try_from(1usize); + | ~~~~~~~~~~~~~~~~~~~~~ error: casting `usize` to `i32` may truncate the value on targets with 64-bit wide pointers --> $DIR/cast_size_32bit.rs:22:5 | LL | 1usize as i32; | ^^^^^^^^^^^^^ + | + = help: if this is intentional allow the lint with `#[allow(clippy::cast_possible_truncation)]` ... +help: ... or use `try_from` and handle the error accordingly + | +LL | i32::try_from(1usize); + | ~~~~~~~~~~~~~~~~~~~~~ error: casting `usize` to `i32` may wrap around the value on targets with 32-bit wide pointers --> $DIR/cast_size_32bit.rs:22:5 @@ -69,18 +98,36 @@ error: casting `i64` to `isize` may truncate the value on targets with 32-bit wi | LL | 1i64 as isize; | ^^^^^^^^^^^^^ + | + = help: if this is intentional allow the lint with `#[allow(clippy::cast_possible_truncation)]` ... +help: ... or use `try_from` and handle the error accordingly + | +LL | isize::try_from(1i64); + | ~~~~~~~~~~~~~~~~~~~~~ error: casting `i64` to `usize` may truncate the value on targets with 32-bit wide pointers --> $DIR/cast_size_32bit.rs:25:5 | LL | 1i64 as usize; | ^^^^^^^^^^^^^ + | + = help: if this is intentional allow the lint with `#[allow(clippy::cast_possible_truncation)]` ... +help: ... or use `try_from` and handle the error accordingly + | +LL | usize::try_from(1i64); + | ~~~~~~~~~~~~~~~~~~~~~ error: casting `u64` to `isize` may truncate the value on targets with 32-bit wide pointers --> $DIR/cast_size_32bit.rs:26:5 | LL | 1u64 as isize; | ^^^^^^^^^^^^^ + | + = help: if this is intentional allow the lint with `#[allow(clippy::cast_possible_truncation)]` ... +help: ... or use `try_from` and handle the error accordingly + | +LL | isize::try_from(1u64); + | ~~~~~~~~~~~~~~~~~~~~~ error: casting `u64` to `isize` may wrap around the value on targets with 64-bit wide pointers --> $DIR/cast_size_32bit.rs:26:5 @@ -93,6 +140,12 @@ error: casting `u64` to `usize` may truncate the value on targets with 32-bit wi | LL | 1u64 as usize; | ^^^^^^^^^^^^^ + | + = help: if this is intentional allow the lint with `#[allow(clippy::cast_possible_truncation)]` ... +help: ... or use `try_from` and handle the error accordingly + | +LL | usize::try_from(1u64); + | ~~~~~~~~~~~~~~~~~~~~~ error: casting `u32` to `isize` may wrap around the value on targets with 32-bit wide pointers --> $DIR/cast_size_32bit.rs:28:5 diff --git a/tests/ui/cfg_attr_rustfmt.fixed b/tests/ui/cfg_attr_rustfmt.fixed index b970b1209b6..13aadb7d330 100644 --- a/tests/ui/cfg_attr_rustfmt.fixed +++ b/tests/ui/cfg_attr_rustfmt.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![feature(stmt_expr_attributes)] #![allow(unused, clippy::no_effect, clippy::unnecessary_operation)] diff --git a/tests/ui/cfg_attr_rustfmt.rs b/tests/ui/cfg_attr_rustfmt.rs index 0a8e6a89d8a..769c5d22b9d 100644 --- a/tests/ui/cfg_attr_rustfmt.rs +++ b/tests/ui/cfg_attr_rustfmt.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![feature(stmt_expr_attributes)] #![allow(unused, clippy::no_effect, clippy::unnecessary_operation)] diff --git a/tests/ui/char_lit_as_u8_suggestions.fixed b/tests/ui/char_lit_as_u8_suggestions.fixed index 3dc3cb4e757..ce2f149dc05 100644 --- a/tests/ui/char_lit_as_u8_suggestions.fixed +++ b/tests/ui/char_lit_as_u8_suggestions.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::char_lit_as_u8)] diff --git a/tests/ui/char_lit_as_u8_suggestions.rs b/tests/ui/char_lit_as_u8_suggestions.rs index d379a023494..ffad12fc6f9 100644 --- a/tests/ui/char_lit_as_u8_suggestions.rs +++ b/tests/ui/char_lit_as_u8_suggestions.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::char_lit_as_u8)] diff --git a/tests/ui/checked_conversions.fixed b/tests/ui/checked_conversions.fixed index e279ba3147b..188e6d97595 100644 --- a/tests/ui/checked_conversions.fixed +++ b/tests/ui/checked_conversions.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow( clippy::cast_lossless, diff --git a/tests/ui/checked_conversions.rs b/tests/ui/checked_conversions.rs index 9d7a40995c3..70f0f0975ac 100644 --- a/tests/ui/checked_conversions.rs +++ b/tests/ui/checked_conversions.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow( clippy::cast_lossless, diff --git a/tests/ui/clear_with_drain.fixed b/tests/ui/clear_with_drain.fixed index 2d9545eeed1..b68c7d867ec 100644 --- a/tests/ui/clear_with_drain.fixed +++ b/tests/ui/clear_with_drain.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused)] #![warn(clippy::clear_with_drain)] diff --git a/tests/ui/clear_with_drain.rs b/tests/ui/clear_with_drain.rs index 4d60ee46e18..0f6562ecad5 100644 --- a/tests/ui/clear_with_drain.rs +++ b/tests/ui/clear_with_drain.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused)] #![warn(clippy::clear_with_drain)] diff --git a/tests/ui/clone_on_copy.fixed b/tests/ui/clone_on_copy.fixed index 72b12227098..a720711585b 100644 --- a/tests/ui/clone_on_copy.fixed +++ b/tests/ui/clone_on_copy.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow( unused, diff --git a/tests/ui/clone_on_copy.rs b/tests/ui/clone_on_copy.rs index 03e210ebad9..2c5fac8faf5 100644 --- a/tests/ui/clone_on_copy.rs +++ b/tests/ui/clone_on_copy.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow( unused, diff --git a/tests/ui/cloned_instead_of_copied.fixed b/tests/ui/cloned_instead_of_copied.fixed index ecbfc1feedf..b6e09ab3190 100644 --- a/tests/ui/cloned_instead_of_copied.fixed +++ b/tests/ui/cloned_instead_of_copied.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::cloned_instead_of_copied)] #![allow(unused)] diff --git a/tests/ui/cloned_instead_of_copied.rs b/tests/ui/cloned_instead_of_copied.rs index 163dc3dddce..fa9e1a99613 100644 --- a/tests/ui/cloned_instead_of_copied.rs +++ b/tests/ui/cloned_instead_of_copied.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::cloned_instead_of_copied)] #![allow(unused)] diff --git a/tests/ui/cmp_owned/asymmetric_partial_eq.fixed b/tests/ui/cmp_owned/asymmetric_partial_eq.fixed index abd059c2308..3bf3deb9b91 100644 --- a/tests/ui/cmp_owned/asymmetric_partial_eq.fixed +++ b/tests/ui/cmp_owned/asymmetric_partial_eq.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused, clippy::redundant_clone, clippy::derive_partial_eq_without_eq)] // See #5700 // Define the types in each module to avoid trait impls leaking between modules. diff --git a/tests/ui/cmp_owned/asymmetric_partial_eq.rs b/tests/ui/cmp_owned/asymmetric_partial_eq.rs index 020ef5f840b..10107dc8f86 100644 --- a/tests/ui/cmp_owned/asymmetric_partial_eq.rs +++ b/tests/ui/cmp_owned/asymmetric_partial_eq.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused, clippy::redundant_clone, clippy::derive_partial_eq_without_eq)] // See #5700 // Define the types in each module to avoid trait impls leaking between modules. diff --git a/tests/ui/cmp_owned/comparison_flip.fixed b/tests/ui/cmp_owned/comparison_flip.fixed index 44e41bdd114..b1133f2a59f 100644 --- a/tests/ui/cmp_owned/comparison_flip.fixed +++ b/tests/ui/cmp_owned/comparison_flip.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix use std::fmt::{self, Display}; diff --git a/tests/ui/cmp_owned/comparison_flip.rs b/tests/ui/cmp_owned/comparison_flip.rs index 662673abb62..091a9aa65c0 100644 --- a/tests/ui/cmp_owned/comparison_flip.rs +++ b/tests/ui/cmp_owned/comparison_flip.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix use std::fmt::{self, Display}; diff --git a/tests/ui/cmp_owned/with_suggestion.fixed b/tests/ui/cmp_owned/with_suggestion.fixed index b28c4378e33..76f90ab2a9d 100644 --- a/tests/ui/cmp_owned/with_suggestion.fixed +++ b/tests/ui/cmp_owned/with_suggestion.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #[warn(clippy::cmp_owned)] #[allow(clippy::unnecessary_operation, clippy::no_effect, unused_must_use, clippy::eq_op)] diff --git a/tests/ui/cmp_owned/with_suggestion.rs b/tests/ui/cmp_owned/with_suggestion.rs index c1089010fe1..f3f663670eb 100644 --- a/tests/ui/cmp_owned/with_suggestion.rs +++ b/tests/ui/cmp_owned/with_suggestion.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #[warn(clippy::cmp_owned)] #[allow(clippy::unnecessary_operation, clippy::no_effect, unused_must_use, clippy::eq_op)] diff --git a/tests/ui/collapsible_else_if.fixed b/tests/ui/collapsible_else_if.fixed index d6a5a785067..8302cec45e7 100644 --- a/tests/ui/collapsible_else_if.fixed +++ b/tests/ui/collapsible_else_if.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(clippy::assertions_on_constants, clippy::equatable_if_let)] #[rustfmt::skip] diff --git a/tests/ui/collapsible_else_if.rs b/tests/ui/collapsible_else_if.rs index 4399fc8b2bd..5913dcf41ca 100644 --- a/tests/ui/collapsible_else_if.rs +++ b/tests/ui/collapsible_else_if.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(clippy::assertions_on_constants, clippy::equatable_if_let)] #[rustfmt::skip] diff --git a/tests/ui/collapsible_if.fixed b/tests/ui/collapsible_if.fixed index 6bb7682bae9..d2aba2ac59b 100644 --- a/tests/ui/collapsible_if.fixed +++ b/tests/ui/collapsible_if.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(clippy::assertions_on_constants, clippy::equatable_if_let)] #[rustfmt::skip] diff --git a/tests/ui/collapsible_if.rs b/tests/ui/collapsible_if.rs index e216a9ee54c..e0bef7f9c97 100644 --- a/tests/ui/collapsible_if.rs +++ b/tests/ui/collapsible_if.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(clippy::assertions_on_constants, clippy::equatable_if_let)] #[rustfmt::skip] diff --git a/tests/ui/collapsible_str_replace.fixed b/tests/ui/collapsible_str_replace.fixed index 9792ae9ed6b..ba6c1769a9a 100644 --- a/tests/ui/collapsible_str_replace.fixed +++ b/tests/ui/collapsible_str_replace.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused)] #![warn(clippy::collapsible_str_replace)] diff --git a/tests/ui/collapsible_str_replace.rs b/tests/ui/collapsible_str_replace.rs index baee185b79e..f5871be65be 100644 --- a/tests/ui/collapsible_str_replace.rs +++ b/tests/ui/collapsible_str_replace.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused)] #![warn(clippy::collapsible_str_replace)] diff --git a/tests/ui/comparison_to_empty.fixed b/tests/ui/comparison_to_empty.fixed index 261024caca7..dd2615ab25c 100644 --- a/tests/ui/comparison_to_empty.fixed +++ b/tests/ui/comparison_to_empty.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::comparison_to_empty)] diff --git a/tests/ui/comparison_to_empty.rs b/tests/ui/comparison_to_empty.rs index 98ddd974951..5462784c6ac 100644 --- a/tests/ui/comparison_to_empty.rs +++ b/tests/ui/comparison_to_empty.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::comparison_to_empty)] diff --git a/tests/ui/crashes/auxiliary/proc_macro_crash.rs b/tests/ui/crashes/auxiliary/proc_macro_crash.rs index 5ff2af7cd82..66419656a32 100644 --- a/tests/ui/crashes/auxiliary/proc_macro_crash.rs +++ b/tests/ui/crashes/auxiliary/proc_macro_crash.rs @@ -1,5 +1,5 @@ -// compile-flags: --emit=link -// no-prefer-dynamic +//@compile-flags: --emit=link +//@no-prefer-dynamic // ^ compiletest by default builds all aux files as dylibs, but we don't want that for proc-macro // crates. If we don't set this, compiletest will override the `crate_type` attribute below and // compile this as dylib. Removing this then causes the test to fail because a `dylib` crate can't diff --git a/tests/ui/crashes/ice-10148.rs b/tests/ui/crashes/ice-10148.rs index 1ab3570c907..c7f0224820e 100644 --- a/tests/ui/crashes/ice-10148.rs +++ b/tests/ui/crashes/ice-10148.rs @@ -1,4 +1,4 @@ -// aux-build:../../auxiliary/proc_macros.rs +//@aux-build:../../auxiliary/proc_macros.rs extern crate proc_macros; diff --git a/tests/ui/crashes/ice-3741.rs b/tests/ui/crashes/ice-3741.rs index 1253ddcfaeb..3106a2e7216 100644 --- a/tests/ui/crashes/ice-3741.rs +++ b/tests/ui/crashes/ice-3741.rs @@ -1,4 +1,4 @@ -// aux-build:proc_macro_crash.rs +//@aux-build:proc_macro_crash.rs #![warn(clippy::suspicious_else_formatting)] diff --git a/tests/ui/crashes/ice-4968.rs b/tests/ui/crashes/ice-4968.rs index e0510d942c2..ac724ac93e3 100644 --- a/tests/ui/crashes/ice-4968.rs +++ b/tests/ui/crashes/ice-4968.rs @@ -1,4 +1,4 @@ -// check-pass +//@check-pass // Test for https://github.com/rust-lang/rust-clippy/issues/4968 diff --git a/tests/ui/crashes/ice-7272.rs b/tests/ui/crashes/ice-7272.rs index 57ab6ca14f8..e949038c8d0 100644 --- a/tests/ui/crashes/ice-7272.rs +++ b/tests/ui/crashes/ice-7272.rs @@ -1,4 +1,4 @@ -// aux-build:ice-7272-aux.rs +//@aux-build:ice-7272-aux.rs #![allow(clippy::no_effect)] diff --git a/tests/ui/crashes/ice-7410.rs b/tests/ui/crashes/ice-7410.rs index 85fa4210321..ffe20ab1c31 100644 --- a/tests/ui/crashes/ice-7410.rs +++ b/tests/ui/crashes/ice-7410.rs @@ -1,6 +1,6 @@ -// compile-flags: -Clink-arg=-nostartfiles -// ignore-macos -// ignore-windows +//@compile-flags: -Clink-arg=-nostartfiles +//@ignore-macos +//@ignore-windows #![feature(lang_items, start, libc)] #![no_std] diff --git a/tests/ui/crashes/ice-8681.rs b/tests/ui/crashes/ice-8681.rs index ee14f011f63..607b9caa324 100644 --- a/tests/ui/crashes/ice-8681.rs +++ b/tests/ui/crashes/ice-8681.rs @@ -1,4 +1,4 @@ -// aux-build: ice-8681-aux.rs +//@aux-build: ice-8681-aux.rs #![warn(clippy::undocumented_unsafe_blocks)] diff --git a/tests/ui/crate_in_macro_def.fixed b/tests/ui/crate_in_macro_def.fixed index 9fc594be311..12a7b9470b3 100644 --- a/tests/ui/crate_in_macro_def.fixed +++ b/tests/ui/crate_in_macro_def.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::crate_in_macro_def)] mod hygienic { diff --git a/tests/ui/crate_in_macro_def.rs b/tests/ui/crate_in_macro_def.rs index ac456108e4a..a1a9eabf639 100644 --- a/tests/ui/crate_in_macro_def.rs +++ b/tests/ui/crate_in_macro_def.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::crate_in_macro_def)] mod hygienic { diff --git a/tests/ui/crate_level_checks/entrypoint_recursion.rs b/tests/ui/crate_level_checks/entrypoint_recursion.rs index 1b3bcece6f1..d6cd594d7c9 100644 --- a/tests/ui/crate_level_checks/entrypoint_recursion.rs +++ b/tests/ui/crate_level_checks/entrypoint_recursion.rs @@ -1,4 +1,4 @@ -// ignore-macos +//@ignore-macos #![feature(rustc_attrs)] diff --git a/tests/ui/crate_level_checks/no_std_main_recursion.rs b/tests/ui/crate_level_checks/no_std_main_recursion.rs index e1c9fe30a9d..a382135bb69 100644 --- a/tests/ui/crate_level_checks/no_std_main_recursion.rs +++ b/tests/ui/crate_level_checks/no_std_main_recursion.rs @@ -1,5 +1,5 @@ -// compile-flags: -Clink-arg=-nostartfiles -// ignore-macos +//@compile-flags: -Clink-arg=-nostartfiles +//@ignore-macos #![feature(lang_items, start, libc)] #![no_std] diff --git a/tests/ui/create_dir.fixed b/tests/ui/create_dir.fixed index 8ed53a56ac0..5de3e9fea0b 100644 --- a/tests/ui/create_dir.fixed +++ b/tests/ui/create_dir.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused_must_use)] #![warn(clippy::create_dir)] diff --git a/tests/ui/create_dir.rs b/tests/ui/create_dir.rs index 19c8fc24ba2..d375bfb4a68 100644 --- a/tests/ui/create_dir.rs +++ b/tests/ui/create_dir.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused_must_use)] #![warn(clippy::create_dir)] diff --git a/tests/ui/dbg_macro.rs b/tests/ui/dbg_macro.rs index 25294e8c766..8701e3cd29f 100644 --- a/tests/ui/dbg_macro.rs +++ b/tests/ui/dbg_macro.rs @@ -1,4 +1,4 @@ -// compile-flags: --test +//@compile-flags: --test #![warn(clippy::dbg_macro)] fn foo(n: u32) -> u32 { diff --git a/tests/ui/decimal_literal_representation.fixed b/tests/ui/decimal_literal_representation.fixed index de391465125..a6eb8c21457 100644 --- a/tests/ui/decimal_literal_representation.fixed +++ b/tests/ui/decimal_literal_representation.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #[warn(clippy::decimal_literal_representation)] #[allow(unused_variables)] diff --git a/tests/ui/decimal_literal_representation.rs b/tests/ui/decimal_literal_representation.rs index 55d07698e7e..7c666d6d7a6 100644 --- a/tests/ui/decimal_literal_representation.rs +++ b/tests/ui/decimal_literal_representation.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #[warn(clippy::decimal_literal_representation)] #[allow(unused_variables)] diff --git a/tests/ui/def_id_nocore.rs b/tests/ui/def_id_nocore.rs index 1af77d1a25b..f7819068ac5 100644 --- a/tests/ui/def_id_nocore.rs +++ b/tests/ui/def_id_nocore.rs @@ -1,4 +1,4 @@ -// ignore-macos +//@ignore-macos #![feature(no_core, lang_items, start)] #![no_core] diff --git a/tests/ui/default_instead_of_iter_empty.fixed b/tests/ui/default_instead_of_iter_empty.fixed index f1abfdcd6ce..f44d34576f6 100644 --- a/tests/ui/default_instead_of_iter_empty.fixed +++ b/tests/ui/default_instead_of_iter_empty.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::default_instead_of_iter_empty)] #![allow(dead_code)] use std::collections::HashMap; diff --git a/tests/ui/default_instead_of_iter_empty.rs b/tests/ui/default_instead_of_iter_empty.rs index 2630519c46d..1c649df253c 100644 --- a/tests/ui/default_instead_of_iter_empty.rs +++ b/tests/ui/default_instead_of_iter_empty.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::default_instead_of_iter_empty)] #![allow(dead_code)] use std::collections::HashMap; diff --git a/tests/ui/default_numeric_fallback_f64.fixed b/tests/ui/default_numeric_fallback_f64.fixed index 42c15d6a70b..9520efe6329 100644 --- a/tests/ui/default_numeric_fallback_f64.fixed +++ b/tests/ui/default_numeric_fallback_f64.fixed @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build:proc_macros.rs +//@run-rustfix +//@aux-build:proc_macros.rs #![warn(clippy::default_numeric_fallback)] #![allow( diff --git a/tests/ui/default_numeric_fallback_f64.rs b/tests/ui/default_numeric_fallback_f64.rs index 7da7ea254e9..cacbdb4a95b 100644 --- a/tests/ui/default_numeric_fallback_f64.rs +++ b/tests/ui/default_numeric_fallback_f64.rs @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build:proc_macros.rs +//@run-rustfix +//@aux-build:proc_macros.rs #![warn(clippy::default_numeric_fallback)] #![allow( diff --git a/tests/ui/default_numeric_fallback_i32.fixed b/tests/ui/default_numeric_fallback_i32.fixed index b7485b73dcd..fbabb8bcf8e 100644 --- a/tests/ui/default_numeric_fallback_i32.fixed +++ b/tests/ui/default_numeric_fallback_i32.fixed @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build:proc_macros.rs +//@run-rustfix +//@aux-build:proc_macros.rs #![feature(lint_reasons)] #![warn(clippy::default_numeric_fallback)] diff --git a/tests/ui/default_numeric_fallback_i32.rs b/tests/ui/default_numeric_fallback_i32.rs index 7307d31354e..7bfc390e4bf 100644 --- a/tests/ui/default_numeric_fallback_i32.rs +++ b/tests/ui/default_numeric_fallback_i32.rs @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build:proc_macros.rs +//@run-rustfix +//@aux-build:proc_macros.rs #![feature(lint_reasons)] #![warn(clippy::default_numeric_fallback)] diff --git a/tests/ui/default_trait_access.fixed b/tests/ui/default_trait_access.fixed index 7842ef3ec40..bf5dca97641 100644 --- a/tests/ui/default_trait_access.fixed +++ b/tests/ui/default_trait_access.fixed @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build: proc_macros.rs +//@run-rustfix +//@aux-build: proc_macros.rs #![deny(clippy::default_trait_access)] #![allow(dead_code, unused_imports)] #![allow(clippy::uninlined_format_args)] diff --git a/tests/ui/default_trait_access.rs b/tests/ui/default_trait_access.rs index cbb3e59c970..5e8e9ce85b1 100644 --- a/tests/ui/default_trait_access.rs +++ b/tests/ui/default_trait_access.rs @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build: proc_macros.rs +//@run-rustfix +//@aux-build: proc_macros.rs #![deny(clippy::default_trait_access)] #![allow(dead_code, unused_imports)] #![allow(clippy::uninlined_format_args)] diff --git a/tests/ui/deref_addrof.fixed b/tests/ui/deref_addrof.fixed index ca5c03304c7..b27d3bc1002 100644 --- a/tests/ui/deref_addrof.fixed +++ b/tests/ui/deref_addrof.fixed @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build:proc_macros.rs +//@run-rustfix +//@aux-build:proc_macros.rs #![allow(clippy::return_self_not_must_use)] #![warn(clippy::deref_addrof)] diff --git a/tests/ui/deref_addrof.rs b/tests/ui/deref_addrof.rs index 3db5fafe944..825090c7c12 100644 --- a/tests/ui/deref_addrof.rs +++ b/tests/ui/deref_addrof.rs @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build:proc_macros.rs +//@run-rustfix +//@aux-build:proc_macros.rs #![allow(clippy::return_self_not_must_use)] #![warn(clippy::deref_addrof)] diff --git a/tests/ui/deref_addrof_macro.rs b/tests/ui/deref_addrof_macro.rs index 57c0be3f51e..c7e60f36506 100644 --- a/tests/ui/deref_addrof_macro.rs +++ b/tests/ui/deref_addrof_macro.rs @@ -1,4 +1,4 @@ -// aux-build:proc_macros.rs +//@aux-build:proc_macros.rs #![warn(clippy::deref_addrof)] diff --git a/tests/ui/deref_by_slicing.fixed b/tests/ui/deref_by_slicing.fixed index 257393e56ff..f91a425c65d 100644 --- a/tests/ui/deref_by_slicing.fixed +++ b/tests/ui/deref_by_slicing.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::deref_by_slicing)] #![allow(clippy::borrow_deref_ref)] diff --git a/tests/ui/deref_by_slicing.rs b/tests/ui/deref_by_slicing.rs index e288046f927..1bfdd0a981b 100644 --- a/tests/ui/deref_by_slicing.rs +++ b/tests/ui/deref_by_slicing.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::deref_by_slicing)] #![allow(clippy::borrow_deref_ref)] diff --git a/tests/ui/derivable_impls.fixed b/tests/ui/derivable_impls.fixed index 89ec33a0d8f..aa0efb85c29 100644 --- a/tests/ui/derivable_impls.fixed +++ b/tests/ui/derivable_impls.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(dead_code)] diff --git a/tests/ui/derivable_impls.rs b/tests/ui/derivable_impls.rs index def6e41162f..8dc999ad586 100644 --- a/tests/ui/derivable_impls.rs +++ b/tests/ui/derivable_impls.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(dead_code)] diff --git a/tests/ui/derive_partial_eq_without_eq.fixed b/tests/ui/derive_partial_eq_without_eq.fixed index bbbe467590f..a1f29430c30 100644 --- a/tests/ui/derive_partial_eq_without_eq.fixed +++ b/tests/ui/derive_partial_eq_without_eq.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused)] #![warn(clippy::derive_partial_eq_without_eq)] diff --git a/tests/ui/derive_partial_eq_without_eq.rs b/tests/ui/derive_partial_eq_without_eq.rs index 88d6fbd1af7..ff4d888559b 100644 --- a/tests/ui/derive_partial_eq_without_eq.rs +++ b/tests/ui/derive_partial_eq_without_eq.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused)] #![warn(clippy::derive_partial_eq_without_eq)] diff --git a/tests/ui/doc/doc-fixable.fixed b/tests/ui/doc/doc-fixable.fixed index ecb0bf3644e..d3aa2816cb6 100644 --- a/tests/ui/doc/doc-fixable.fixed +++ b/tests/ui/doc/doc-fixable.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix //! This file tests for the `DOC_MARKDOWN` lint. #![allow(dead_code, incomplete_features)] diff --git a/tests/ui/doc/doc-fixable.rs b/tests/ui/doc/doc-fixable.rs index 11c48dd103d..d1e7d8017d7 100644 --- a/tests/ui/doc/doc-fixable.rs +++ b/tests/ui/doc/doc-fixable.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix //! This file tests for the `DOC_MARKDOWN` lint. #![allow(dead_code, incomplete_features)] diff --git a/tests/ui/doc_unsafe.rs b/tests/ui/doc_unsafe.rs index 30674ce3708..0c8eac5ccff 100644 --- a/tests/ui/doc_unsafe.rs +++ b/tests/ui/doc_unsafe.rs @@ -1,4 +1,4 @@ -// aux-build:proc_macros.rs +//@aux-build:proc_macros.rs #![allow(clippy::let_unit_value)] diff --git a/tests/ui/double_comparison.fixed b/tests/ui/double_comparison.fixed index bb6cdaa667d..c80ff671a5d 100644 --- a/tests/ui/double_comparison.fixed +++ b/tests/ui/double_comparison.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix fn main() { let x = 1; diff --git a/tests/ui/double_comparison.rs b/tests/ui/double_comparison.rs index 9a2a9068a28..bc78694aa68 100644 --- a/tests/ui/double_comparison.rs +++ b/tests/ui/double_comparison.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix fn main() { let x = 1; diff --git a/tests/ui/duration_subsec.fixed b/tests/ui/duration_subsec.fixed index d92b8998e88..bfd30f0042d 100644 --- a/tests/ui/duration_subsec.fixed +++ b/tests/ui/duration_subsec.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(dead_code, clippy::needless_borrow)] #![warn(clippy::duration_subsec)] diff --git a/tests/ui/duration_subsec.rs b/tests/ui/duration_subsec.rs index 08da804996d..860233f084f 100644 --- a/tests/ui/duration_subsec.rs +++ b/tests/ui/duration_subsec.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(dead_code, clippy::needless_borrow)] #![warn(clippy::duration_subsec)] diff --git a/tests/ui/empty_drop.fixed b/tests/ui/empty_drop.fixed index 2e1b768461a..fd0a9a7081e 100644 --- a/tests/ui/empty_drop.fixed +++ b/tests/ui/empty_drop.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::empty_drop)] #![allow(unused)] diff --git a/tests/ui/empty_drop.rs b/tests/ui/empty_drop.rs index 75232b0334d..6c15cb93302 100644 --- a/tests/ui/empty_drop.rs +++ b/tests/ui/empty_drop.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::empty_drop)] #![allow(unused)] diff --git a/tests/ui/empty_line_after_outer_attribute.rs b/tests/ui/empty_line_after_outer_attribute.rs index 697412c0027..269e66ea0a8 100644 --- a/tests/ui/empty_line_after_outer_attribute.rs +++ b/tests/ui/empty_line_after_outer_attribute.rs @@ -1,4 +1,4 @@ -// aux-build:proc_macro_attr.rs +//@aux-build:proc_macro_attr.rs #![warn(clippy::empty_line_after_outer_attr)] #![allow(clippy::assertions_on_constants)] #![feature(custom_inner_attributes)] diff --git a/tests/ui/empty_loop.rs b/tests/ui/empty_loop.rs index 6a8e6b550c1..54e8fb4907c 100644 --- a/tests/ui/empty_loop.rs +++ b/tests/ui/empty_loop.rs @@ -1,4 +1,4 @@ -// aux-build:proc_macros.rs +//@aux-build:proc_macros.rs #![warn(clippy::empty_loop)] diff --git a/tests/ui/empty_loop_no_std.rs b/tests/ui/empty_loop_no_std.rs index e742b396fcd..d564b2d24f5 100644 --- a/tests/ui/empty_loop_no_std.rs +++ b/tests/ui/empty_loop_no_std.rs @@ -1,5 +1,5 @@ -// compile-flags: -Clink-arg=-nostartfiles -// ignore-macos +//@compile-flags: -Clink-arg=-nostartfiles +//@ignore-macos #![warn(clippy::empty_loop)] #![feature(lang_items, start, libc)] diff --git a/tests/ui/empty_structs_with_brackets.fixed b/tests/ui/empty_structs_with_brackets.fixed index 80f07603b8d..6fab3020839 100644 --- a/tests/ui/empty_structs_with_brackets.fixed +++ b/tests/ui/empty_structs_with_brackets.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::empty_structs_with_brackets)] #![allow(dead_code)] diff --git a/tests/ui/empty_structs_with_brackets.rs b/tests/ui/empty_structs_with_brackets.rs index 1d1ed4c7690..0caa3c49cd6 100644 --- a/tests/ui/empty_structs_with_brackets.rs +++ b/tests/ui/empty_structs_with_brackets.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::empty_structs_with_brackets)] #![allow(dead_code)] diff --git a/tests/ui/entry.fixed b/tests/ui/entry.fixed index dbe09e0ff3c..7e82390605c 100644 --- a/tests/ui/entry.fixed +++ b/tests/ui/entry.fixed @@ -1,5 +1,5 @@ -// needs-asm-support -// run-rustfix +//@needs-asm-support +//@run-rustfix #![allow(unused, clippy::needless_pass_by_value, clippy::collapsible_if)] #![warn(clippy::map_entry)] diff --git a/tests/ui/entry.rs b/tests/ui/entry.rs index 30fed34fc5d..742c9322535 100644 --- a/tests/ui/entry.rs +++ b/tests/ui/entry.rs @@ -1,5 +1,5 @@ -// needs-asm-support -// run-rustfix +//@needs-asm-support +//@run-rustfix #![allow(unused, clippy::needless_pass_by_value, clippy::collapsible_if)] #![warn(clippy::map_entry)] diff --git a/tests/ui/entry_btree.fixed b/tests/ui/entry_btree.fixed index 94979104556..3baaacffd20 100644 --- a/tests/ui/entry_btree.fixed +++ b/tests/ui/entry_btree.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::map_entry)] #![allow(dead_code)] diff --git a/tests/ui/entry_btree.rs b/tests/ui/entry_btree.rs index 080c1d959e8..770e8e91da2 100644 --- a/tests/ui/entry_btree.rs +++ b/tests/ui/entry_btree.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::map_entry)] #![allow(dead_code)] diff --git a/tests/ui/entry_with_else.fixed b/tests/ui/entry_with_else.fixed index 2332fa6313f..71fe04fd648 100644 --- a/tests/ui/entry_with_else.fixed +++ b/tests/ui/entry_with_else.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused, clippy::needless_pass_by_value, clippy::collapsible_if)] #![warn(clippy::map_entry)] diff --git a/tests/ui/entry_with_else.rs b/tests/ui/entry_with_else.rs index 2ff0c038efe..80f74649a60 100644 --- a/tests/ui/entry_with_else.rs +++ b/tests/ui/entry_with_else.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused, clippy::needless_pass_by_value, clippy::collapsible_if)] #![warn(clippy::map_entry)] diff --git a/tests/ui/enum_clike_unportable_variant.rs b/tests/ui/enum_clike_unportable_variant.rs index 7d6842f5b54..f17556ea907 100644 --- a/tests/ui/enum_clike_unportable_variant.rs +++ b/tests/ui/enum_clike_unportable_variant.rs @@ -1,4 +1,4 @@ -// ignore-x86 +//@ignore-x86 #![warn(clippy::enum_clike_unportable_variant)] #![allow(unused, non_upper_case_globals)] diff --git a/tests/ui/enum_glob_use.fixed b/tests/ui/enum_glob_use.fixed index a98216758bb..419370ffb1d 100644 --- a/tests/ui/enum_glob_use.fixed +++ b/tests/ui/enum_glob_use.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::enum_glob_use)] #![allow(unused)] diff --git a/tests/ui/enum_glob_use.rs b/tests/ui/enum_glob_use.rs index 5d929c9731d..645ed98325c 100644 --- a/tests/ui/enum_glob_use.rs +++ b/tests/ui/enum_glob_use.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::enum_glob_use)] #![allow(unused)] diff --git a/tests/ui/eq_op.rs b/tests/ui/eq_op.rs index e7379550265..cdd33ebe582 100644 --- a/tests/ui/eq_op.rs +++ b/tests/ui/eq_op.rs @@ -1,4 +1,4 @@ -// compile-flags: --test +//@compile-flags: --test #![warn(clippy::eq_op)] #![allow(clippy::double_parens, clippy::identity_op, clippy::nonminimal_bool)] diff --git a/tests/ui/equatable_if_let.fixed b/tests/ui/equatable_if_let.fixed index 007702ab550..53e62760bef 100644 --- a/tests/ui/equatable_if_let.fixed +++ b/tests/ui/equatable_if_let.fixed @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build:proc_macros.rs +//@run-rustfix +//@aux-build:proc_macros.rs #![allow(unused_variables, dead_code, clippy::derive_partial_eq_without_eq)] #![warn(clippy::equatable_if_let)] diff --git a/tests/ui/equatable_if_let.rs b/tests/ui/equatable_if_let.rs index 3bda7977645..55918a5bb11 100644 --- a/tests/ui/equatable_if_let.rs +++ b/tests/ui/equatable_if_let.rs @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build:proc_macros.rs +//@run-rustfix +//@aux-build:proc_macros.rs #![allow(unused_variables, dead_code, clippy::derive_partial_eq_without_eq)] #![warn(clippy::equatable_if_let)] diff --git a/tests/ui/err_expect.fixed b/tests/ui/err_expect.fixed index b63cbd8a8e6..6ade6f54689 100644 --- a/tests/ui/err_expect.fixed +++ b/tests/ui/err_expect.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused)] diff --git a/tests/ui/err_expect.rs b/tests/ui/err_expect.rs index c081a745fb4..a93fb59493f 100644 --- a/tests/ui/err_expect.rs +++ b/tests/ui/err_expect.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused)] diff --git a/tests/ui/eta.fixed b/tests/ui/eta.fixed index dc129591eac..b1baf462c0f 100644 --- a/tests/ui/eta.fixed +++ b/tests/ui/eta.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::redundant_closure, clippy::redundant_closure_for_method_calls)] #![allow(unused)] #![allow( diff --git a/tests/ui/eta.rs b/tests/ui/eta.rs index 025fd6a0b7a..e113c3d6cd6 100644 --- a/tests/ui/eta.rs +++ b/tests/ui/eta.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::redundant_closure, clippy::redundant_closure_for_method_calls)] #![allow(unused)] #![allow( diff --git a/tests/ui/excessive_precision.fixed b/tests/ui/excessive_precision.fixed index b74bda182be..0a07957386c 100644 --- a/tests/ui/excessive_precision.fixed +++ b/tests/ui/excessive_precision.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::excessive_precision)] #![allow(dead_code, unused_variables, clippy::print_literal)] diff --git a/tests/ui/excessive_precision.rs b/tests/ui/excessive_precision.rs index 6e84a71f24c..62a832caa67 100644 --- a/tests/ui/excessive_precision.rs +++ b/tests/ui/excessive_precision.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::excessive_precision)] #![allow(dead_code, unused_variables, clippy::print_literal)] diff --git a/tests/ui/exhaustive_items.fixed b/tests/ui/exhaustive_items.fixed index c209f5b4b72..6c7b1cab6f2 100644 --- a/tests/ui/exhaustive_items.fixed +++ b/tests/ui/exhaustive_items.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![deny(clippy::exhaustive_enums, clippy::exhaustive_structs)] #![allow(unused)] diff --git a/tests/ui/exhaustive_items.rs b/tests/ui/exhaustive_items.rs index 6f59dbf2da5..d205bac2d2a 100644 --- a/tests/ui/exhaustive_items.rs +++ b/tests/ui/exhaustive_items.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![deny(clippy::exhaustive_enums, clippy::exhaustive_structs)] #![allow(unused)] diff --git a/tests/ui/expect_fun_call.fixed b/tests/ui/expect_fun_call.fixed index 15172ae345c..8e97054fb6b 100644 --- a/tests/ui/expect_fun_call.fixed +++ b/tests/ui/expect_fun_call.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::expect_fun_call)] #![allow(clippy::to_string_in_format_args, clippy::uninlined_format_args)] diff --git a/tests/ui/expect_fun_call.rs b/tests/ui/expect_fun_call.rs index 0f448d00417..31e6bcc7ff6 100644 --- a/tests/ui/expect_fun_call.rs +++ b/tests/ui/expect_fun_call.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::expect_fun_call)] #![allow(clippy::to_string_in_format_args, clippy::uninlined_format_args)] diff --git a/tests/ui/explicit_auto_deref.fixed b/tests/ui/explicit_auto_deref.fixed index 5d40c850424..71a5ed96d5c 100644 --- a/tests/ui/explicit_auto_deref.fixed +++ b/tests/ui/explicit_auto_deref.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![feature(closure_lifetime_binder)] #![warn(clippy::explicit_auto_deref)] diff --git a/tests/ui/explicit_auto_deref.rs b/tests/ui/explicit_auto_deref.rs index 79e03f4d76c..9d0cafa150f 100644 --- a/tests/ui/explicit_auto_deref.rs +++ b/tests/ui/explicit_auto_deref.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![feature(closure_lifetime_binder)] #![warn(clippy::explicit_auto_deref)] diff --git a/tests/ui/explicit_deref_methods.fixed b/tests/ui/explicit_deref_methods.fixed index 6d32bbece1e..77e9f5fc1fd 100644 --- a/tests/ui/explicit_deref_methods.fixed +++ b/tests/ui/explicit_deref_methods.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::explicit_deref_methods)] #![allow(unused_variables)] #![allow( diff --git a/tests/ui/explicit_deref_methods.rs b/tests/ui/explicit_deref_methods.rs index 779909e4238..0c2cc7c2c3a 100644 --- a/tests/ui/explicit_deref_methods.rs +++ b/tests/ui/explicit_deref_methods.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::explicit_deref_methods)] #![allow(unused_variables)] #![allow( diff --git a/tests/ui/explicit_write.fixed b/tests/ui/explicit_write.fixed index 862c3fea9ee..213485bc221 100644 --- a/tests/ui/explicit_write.fixed +++ b/tests/ui/explicit_write.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::explicit_write)] #![allow(unused_imports)] #![allow(clippy::uninlined_format_args)] diff --git a/tests/ui/explicit_write.rs b/tests/ui/explicit_write.rs index 41d7c225573..64acd7108bf 100644 --- a/tests/ui/explicit_write.rs +++ b/tests/ui/explicit_write.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::explicit_write)] #![allow(unused_imports)] #![allow(clippy::uninlined_format_args)] diff --git a/tests/ui/extend_with_drain.fixed b/tests/ui/extend_with_drain.fixed index 71ebad24c16..594f2f6d413 100644 --- a/tests/ui/extend_with_drain.fixed +++ b/tests/ui/extend_with_drain.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::extend_with_drain)] #![allow(clippy::iter_with_drain)] use std::collections::BinaryHeap; diff --git a/tests/ui/extend_with_drain.rs b/tests/ui/extend_with_drain.rs index e9f011abb0e..3e2ad02052d 100644 --- a/tests/ui/extend_with_drain.rs +++ b/tests/ui/extend_with_drain.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::extend_with_drain)] #![allow(clippy::iter_with_drain)] use std::collections::BinaryHeap; diff --git a/tests/ui/extra_unused_lifetimes.rs b/tests/ui/extra_unused_lifetimes.rs index d6631e01290..cdfaf8d3afe 100644 --- a/tests/ui/extra_unused_lifetimes.rs +++ b/tests/ui/extra_unused_lifetimes.rs @@ -1,4 +1,4 @@ -// aux-build:proc_macro_derive.rs +//@aux-build:proc_macro_derive.rs #![allow( unused, diff --git a/tests/ui/extra_unused_type_parameters.fixed b/tests/ui/extra_unused_type_parameters.fixed index 19e71862558..adcd1f6d407 100644 --- a/tests/ui/extra_unused_type_parameters.fixed +++ b/tests/ui/extra_unused_type_parameters.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused, clippy::needless_lifetimes)] #![warn(clippy::extra_unused_type_parameters)] diff --git a/tests/ui/extra_unused_type_parameters.rs b/tests/ui/extra_unused_type_parameters.rs index e53bb587e89..c4c5227ac91 100644 --- a/tests/ui/extra_unused_type_parameters.rs +++ b/tests/ui/extra_unused_type_parameters.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused, clippy::needless_lifetimes)] #![warn(clippy::extra_unused_type_parameters)] diff --git a/tests/ui/field_reassign_with_default.rs b/tests/ui/field_reassign_with_default.rs index 0e208b3ed0e..2045b1eebcd 100644 --- a/tests/ui/field_reassign_with_default.rs +++ b/tests/ui/field_reassign_with_default.rs @@ -1,5 +1,5 @@ -// aux-build:proc_macro_derive.rs -// aux-build:proc_macros.rs +//@aux-build:proc_macro_derive.rs +//@aux-build:proc_macros.rs #![warn(clippy::field_reassign_with_default)] diff --git a/tests/ui/filter_map_identity.fixed b/tests/ui/filter_map_identity.fixed index a5860aa49b3..44665b451ad 100644 --- a/tests/ui/filter_map_identity.fixed +++ b/tests/ui/filter_map_identity.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused_imports, clippy::needless_return)] #![warn(clippy::filter_map_identity)] diff --git a/tests/ui/filter_map_identity.rs b/tests/ui/filter_map_identity.rs index 7e998b9cdf7..9832acb013f 100644 --- a/tests/ui/filter_map_identity.rs +++ b/tests/ui/filter_map_identity.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused_imports, clippy::needless_return)] #![warn(clippy::filter_map_identity)] diff --git a/tests/ui/filter_map_next_fixable.fixed b/tests/ui/filter_map_next_fixable.fixed index 462d46169fc..efb37f8b1b7 100644 --- a/tests/ui/filter_map_next_fixable.fixed +++ b/tests/ui/filter_map_next_fixable.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::all, clippy::pedantic)] #![allow(unused)] diff --git a/tests/ui/filter_map_next_fixable.rs b/tests/ui/filter_map_next_fixable.rs index 2ea00cf7307..b10e20d359e 100644 --- a/tests/ui/filter_map_next_fixable.rs +++ b/tests/ui/filter_map_next_fixable.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::all, clippy::pedantic)] #![allow(unused)] diff --git a/tests/ui/flat_map_identity.fixed b/tests/ui/flat_map_identity.fixed index 1f4b880ef5b..97091d6f1a5 100644 --- a/tests/ui/flat_map_identity.fixed +++ b/tests/ui/flat_map_identity.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused_imports, clippy::needless_return)] #![warn(clippy::flat_map_identity)] diff --git a/tests/ui/flat_map_identity.rs b/tests/ui/flat_map_identity.rs index de14a06d4e6..5607683a5d0 100644 --- a/tests/ui/flat_map_identity.rs +++ b/tests/ui/flat_map_identity.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused_imports, clippy::needless_return)] #![warn(clippy::flat_map_identity)] diff --git a/tests/ui/flat_map_option.fixed b/tests/ui/flat_map_option.fixed index 6a34f008995..eeab864c42f 100644 --- a/tests/ui/flat_map_option.fixed +++ b/tests/ui/flat_map_option.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::flat_map_option)] #![allow(clippy::redundant_closure, clippy::unnecessary_filter_map)] diff --git a/tests/ui/flat_map_option.rs b/tests/ui/flat_map_option.rs index 2479abddbf0..ebc389f7f02 100644 --- a/tests/ui/flat_map_option.rs +++ b/tests/ui/flat_map_option.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::flat_map_option)] #![allow(clippy::redundant_closure, clippy::unnecessary_filter_map)] diff --git a/tests/ui/floating_point_abs.fixed b/tests/ui/floating_point_abs.fixed index ca747fefc64..0cc572822e7 100644 --- a/tests/ui/floating_point_abs.fixed +++ b/tests/ui/floating_point_abs.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![feature(const_fn_floating_point_arithmetic)] #![warn(clippy::suboptimal_flops)] diff --git a/tests/ui/floating_point_abs.rs b/tests/ui/floating_point_abs.rs index e4b60657497..6c732d398f0 100644 --- a/tests/ui/floating_point_abs.rs +++ b/tests/ui/floating_point_abs.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![feature(const_fn_floating_point_arithmetic)] #![warn(clippy::suboptimal_flops)] diff --git a/tests/ui/floating_point_exp.fixed b/tests/ui/floating_point_exp.fixed index b9e3d89c2b2..1a33b8153ec 100644 --- a/tests/ui/floating_point_exp.fixed +++ b/tests/ui/floating_point_exp.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::imprecise_flops)] #![allow(clippy::unnecessary_cast)] diff --git a/tests/ui/floating_point_exp.rs b/tests/ui/floating_point_exp.rs index ef008dd9be0..4f4a5ec81ac 100644 --- a/tests/ui/floating_point_exp.rs +++ b/tests/ui/floating_point_exp.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::imprecise_flops)] #![allow(clippy::unnecessary_cast)] diff --git a/tests/ui/floating_point_hypot.fixed b/tests/ui/floating_point_hypot.fixed index bbe411b3f48..431cb270978 100644 --- a/tests/ui/floating_point_hypot.fixed +++ b/tests/ui/floating_point_hypot.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::imprecise_flops)] fn main() { diff --git a/tests/ui/floating_point_hypot.rs b/tests/ui/floating_point_hypot.rs index 586fd170ea1..e5506ed391c 100644 --- a/tests/ui/floating_point_hypot.rs +++ b/tests/ui/floating_point_hypot.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::imprecise_flops)] fn main() { diff --git a/tests/ui/floating_point_log.fixed b/tests/ui/floating_point_log.fixed index ee540646160..6582c0a0f6c 100644 --- a/tests/ui/floating_point_log.fixed +++ b/tests/ui/floating_point_log.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(dead_code, clippy::double_parens, clippy::unnecessary_cast)] #![warn(clippy::suboptimal_flops, clippy::imprecise_flops)] diff --git a/tests/ui/floating_point_log.rs b/tests/ui/floating_point_log.rs index 0590670a50b..854d269fff5 100644 --- a/tests/ui/floating_point_log.rs +++ b/tests/ui/floating_point_log.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(dead_code, clippy::double_parens, clippy::unnecessary_cast)] #![warn(clippy::suboptimal_flops, clippy::imprecise_flops)] diff --git a/tests/ui/floating_point_logbase.fixed b/tests/ui/floating_point_logbase.fixed index 7347bf72cbe..0783ecee1ee 100644 --- a/tests/ui/floating_point_logbase.fixed +++ b/tests/ui/floating_point_logbase.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::suboptimal_flops)] #![allow(clippy::unnecessary_cast)] diff --git a/tests/ui/floating_point_logbase.rs b/tests/ui/floating_point_logbase.rs index ba5b8d40692..80fcfab6825 100644 --- a/tests/ui/floating_point_logbase.rs +++ b/tests/ui/floating_point_logbase.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::suboptimal_flops)] #![allow(clippy::unnecessary_cast)] diff --git a/tests/ui/floating_point_mul_add.fixed b/tests/ui/floating_point_mul_add.fixed index d3e536ba350..8848981a11d 100644 --- a/tests/ui/floating_point_mul_add.fixed +++ b/tests/ui/floating_point_mul_add.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![feature(const_fn_floating_point_arithmetic)] #![warn(clippy::suboptimal_flops)] diff --git a/tests/ui/floating_point_mul_add.rs b/tests/ui/floating_point_mul_add.rs index 5d4a9e35cfc..b0edf5cb210 100644 --- a/tests/ui/floating_point_mul_add.rs +++ b/tests/ui/floating_point_mul_add.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![feature(const_fn_floating_point_arithmetic)] #![warn(clippy::suboptimal_flops)] diff --git a/tests/ui/floating_point_powf.fixed b/tests/ui/floating_point_powf.fixed index f7f93de2957..1e660b140c5 100644 --- a/tests/ui/floating_point_powf.fixed +++ b/tests/ui/floating_point_powf.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::suboptimal_flops, clippy::imprecise_flops)] #![allow(clippy::unnecessary_cast)] diff --git a/tests/ui/floating_point_powf.rs b/tests/ui/floating_point_powf.rs index 499fc0e15e4..71c2f529205 100644 --- a/tests/ui/floating_point_powf.rs +++ b/tests/ui/floating_point_powf.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::suboptimal_flops, clippy::imprecise_flops)] #![allow(clippy::unnecessary_cast)] diff --git a/tests/ui/floating_point_powi.fixed b/tests/ui/floating_point_powi.fixed index 8ffd4cc5137..41d5288d6e0 100644 --- a/tests/ui/floating_point_powi.fixed +++ b/tests/ui/floating_point_powi.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::suboptimal_flops)] #![allow(clippy::unnecessary_cast)] diff --git a/tests/ui/floating_point_powi.rs b/tests/ui/floating_point_powi.rs index 9ae3455a134..7951aab31be 100644 --- a/tests/ui/floating_point_powi.rs +++ b/tests/ui/floating_point_powi.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::suboptimal_flops)] #![allow(clippy::unnecessary_cast)] diff --git a/tests/ui/floating_point_rad.fixed b/tests/ui/floating_point_rad.fixed index 27674b8a455..af236452712 100644 --- a/tests/ui/floating_point_rad.fixed +++ b/tests/ui/floating_point_rad.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![feature(const_fn_floating_point_arithmetic)] #![warn(clippy::suboptimal_flops)] diff --git a/tests/ui/floating_point_rad.rs b/tests/ui/floating_point_rad.rs index f1ea73df398..d7612c56a3e 100644 --- a/tests/ui/floating_point_rad.rs +++ b/tests/ui/floating_point_rad.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![feature(const_fn_floating_point_arithmetic)] #![warn(clippy::suboptimal_flops)] diff --git a/tests/ui/fn_to_numeric_cast.rs b/tests/ui/fn_to_numeric_cast.rs index a456c085c87..4f6af870889 100644 --- a/tests/ui/fn_to_numeric_cast.rs +++ b/tests/ui/fn_to_numeric_cast.rs @@ -1,4 +1,4 @@ -// ignore-32bit +//@ignore-32bit #![warn(clippy::fn_to_numeric_cast, clippy::fn_to_numeric_cast_with_truncation)] diff --git a/tests/ui/fn_to_numeric_cast_32bit.rs b/tests/ui/fn_to_numeric_cast_32bit.rs index 04ee985c086..62ce97f098d 100644 --- a/tests/ui/fn_to_numeric_cast_32bit.rs +++ b/tests/ui/fn_to_numeric_cast_32bit.rs @@ -1,4 +1,4 @@ -// ignore-64bit +//@ignore-64bit #![warn(clippy::fn_to_numeric_cast, clippy::fn_to_numeric_cast_with_truncation)] diff --git a/tests/ui/fn_to_numeric_cast_32bit.stderr b/tests/ui/fn_to_numeric_cast_32bit.stderr index 08dd611d675..671347d2bcd 100644 --- a/tests/ui/fn_to_numeric_cast_32bit.stderr +++ b/tests/ui/fn_to_numeric_cast_32bit.stderr @@ -12,19 +12,19 @@ error: casting function pointer `foo` to `i16`, which truncates the value LL | let _ = foo as i16; | ^^^^^^^^^^ help: try: `foo as usize` -error: casting function pointer `foo` to `i32` +error: casting function pointer `foo` to `i32`, which truncates the value --> $DIR/fn_to_numeric_cast_32bit.rs:12:13 | LL | let _ = foo as i32; | ^^^^^^^^^^ help: try: `foo as usize` - | - = note: `-D clippy::fn-to-numeric-cast` implied by `-D warnings` error: casting function pointer `foo` to `i64` --> $DIR/fn_to_numeric_cast_32bit.rs:13:13 | LL | let _ = foo as i64; | ^^^^^^^^^^ help: try: `foo as usize` + | + = note: `-D clippy::fn-to-numeric-cast` implied by `-D warnings` error: casting function pointer `foo` to `i128` --> $DIR/fn_to_numeric_cast_32bit.rs:14:13 @@ -50,7 +50,7 @@ error: casting function pointer `foo` to `u16`, which truncates the value LL | let _ = foo as u16; | ^^^^^^^^^^ help: try: `foo as usize` -error: casting function pointer `foo` to `u32` +error: casting function pointer `foo` to `u32`, which truncates the value --> $DIR/fn_to_numeric_cast_32bit.rs:19:13 | LL | let _ = foo as u32; @@ -80,7 +80,7 @@ error: casting function pointer `abc` to `i16`, which truncates the value LL | let _ = abc as i16; | ^^^^^^^^^^ help: try: `abc as usize` -error: casting function pointer `abc` to `i32` +error: casting function pointer `abc` to `i32`, which truncates the value --> $DIR/fn_to_numeric_cast_32bit.rs:36:13 | LL | let _ = abc as i32; @@ -116,7 +116,7 @@ error: casting function pointer `abc` to `u16`, which truncates the value LL | let _ = abc as u16; | ^^^^^^^^^^ help: try: `abc as usize` -error: casting function pointer `abc` to `u32` +error: casting function pointer `abc` to `u32`, which truncates the value --> $DIR/fn_to_numeric_cast_32bit.rs:43:13 | LL | let _ = abc as u32; @@ -134,7 +134,7 @@ error: casting function pointer `abc` to `u128` LL | let _ = abc as u128; | ^^^^^^^^^^^ help: try: `abc as usize` -error: casting function pointer `f` to `i32` +error: casting function pointer `f` to `i32`, which truncates the value --> $DIR/fn_to_numeric_cast_32bit.rs:52:5 | LL | f as i32 diff --git a/tests/ui/for_loop_fixable.fixed b/tests/ui/for_loop_fixable.fixed index e9dd38fe40e..f578c98da15 100644 --- a/tests/ui/for_loop_fixable.fixed +++ b/tests/ui/for_loop_fixable.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(dead_code, unused)] #![allow(clippy::uninlined_format_args)] diff --git a/tests/ui/for_loop_fixable.rs b/tests/ui/for_loop_fixable.rs index 534fb4dd4ef..42bc6de0c7d 100644 --- a/tests/ui/for_loop_fixable.rs +++ b/tests/ui/for_loop_fixable.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(dead_code, unused)] #![allow(clippy::uninlined_format_args)] diff --git a/tests/ui/format.fixed b/tests/ui/format.fixed index beedf2c1db2..9288956f513 100644 --- a/tests/ui/format.fixed +++ b/tests/ui/format.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::useless_format)] #![allow( unused_tuple_struct_fields, diff --git a/tests/ui/format.rs b/tests/ui/format.rs index e805f181889..b2b817e0f4c 100644 --- a/tests/ui/format.rs +++ b/tests/ui/format.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::useless_format)] #![allow( unused_tuple_struct_fields, diff --git a/tests/ui/format_args.fixed b/tests/ui/format_args.fixed index 825e122be5a..ea383686135 100644 --- a/tests/ui/format_args.fixed +++ b/tests/ui/format_args.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::to_string_in_format_args)] #![allow(unused)] #![allow( diff --git a/tests/ui/format_args.rs b/tests/ui/format_args.rs index a41e53389e5..bfb32449246 100644 --- a/tests/ui/format_args.rs +++ b/tests/ui/format_args.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::to_string_in_format_args)] #![allow(unused)] #![allow( diff --git a/tests/ui/from_iter_instead_of_collect.fixed b/tests/ui/from_iter_instead_of_collect.fixed index 48f8093311c..915ff4fb079 100644 --- a/tests/ui/from_iter_instead_of_collect.fixed +++ b/tests/ui/from_iter_instead_of_collect.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::from_iter_instead_of_collect)] #![allow(unused_imports, unused_tuple_struct_fields)] diff --git a/tests/ui/from_iter_instead_of_collect.rs b/tests/ui/from_iter_instead_of_collect.rs index ebe0ad278be..e926f8c529d 100644 --- a/tests/ui/from_iter_instead_of_collect.rs +++ b/tests/ui/from_iter_instead_of_collect.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::from_iter_instead_of_collect)] #![allow(unused_imports, unused_tuple_struct_fields)] diff --git a/tests/ui/from_over_into.fixed b/tests/ui/from_over_into.fixed index 72d635c2ccd..fc6d937060d 100644 --- a/tests/ui/from_over_into.fixed +++ b/tests/ui/from_over_into.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![feature(type_alias_impl_trait)] #![warn(clippy::from_over_into)] diff --git a/tests/ui/from_over_into.rs b/tests/ui/from_over_into.rs index 965f4d5d785..fe1ebee35f1 100644 --- a/tests/ui/from_over_into.rs +++ b/tests/ui/from_over_into.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![feature(type_alias_impl_trait)] #![warn(clippy::from_over_into)] diff --git a/tests/ui/get_first.fixed b/tests/ui/get_first.fixed index def58afa4fb..ef132b79611 100644 --- a/tests/ui/get_first.fixed +++ b/tests/ui/get_first.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::get_first)] use std::collections::BTreeMap; use std::collections::HashMap; diff --git a/tests/ui/get_first.rs b/tests/ui/get_first.rs index 85a381854cd..4d872235614 100644 --- a/tests/ui/get_first.rs +++ b/tests/ui/get_first.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::get_first)] use std::collections::BTreeMap; use std::collections::HashMap; diff --git a/tests/ui/get_last_with_len.fixed b/tests/ui/get_last_with_len.fixed index 1e90b37687a..a58dfda7988 100644 --- a/tests/ui/get_last_with_len.fixed +++ b/tests/ui/get_last_with_len.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::get_last_with_len)] #![allow(unused)] diff --git a/tests/ui/get_last_with_len.rs b/tests/ui/get_last_with_len.rs index d63a731bd52..d626656c78f 100644 --- a/tests/ui/get_last_with_len.rs +++ b/tests/ui/get_last_with_len.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::get_last_with_len)] #![allow(unused)] diff --git a/tests/ui/get_unwrap.fixed b/tests/ui/get_unwrap.fixed index 5827fc7d76e..4950c47ddeb 100644 --- a/tests/ui/get_unwrap.fixed +++ b/tests/ui/get_unwrap.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused_mut, clippy::from_iter_instead_of_collect, clippy::get_first)] #![warn(clippy::unwrap_used)] diff --git a/tests/ui/get_unwrap.rs b/tests/ui/get_unwrap.rs index a2a323c14fb..6b1e8edb7bd 100644 --- a/tests/ui/get_unwrap.rs +++ b/tests/ui/get_unwrap.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused_mut, clippy::from_iter_instead_of_collect, clippy::get_first)] #![warn(clippy::unwrap_used)] diff --git a/tests/ui/identity_op.fixed b/tests/ui/identity_op.fixed index cac69ef42c4..beb16000eca 100644 --- a/tests/ui/identity_op.fixed +++ b/tests/ui/identity_op.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::identity_op)] #![allow(unused)] #![allow( diff --git a/tests/ui/identity_op.rs b/tests/ui/identity_op.rs index 33201aad4f6..072e00c00f0 100644 --- a/tests/ui/identity_op.rs +++ b/tests/ui/identity_op.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::identity_op)] #![allow(unused)] #![allow( diff --git a/tests/ui/implicit_clone.fixed b/tests/ui/implicit_clone.fixed index 8ccc3da7b47..e62db8b40be 100644 --- a/tests/ui/implicit_clone.fixed +++ b/tests/ui/implicit_clone.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::implicit_clone)] #![allow(clippy::clone_on_copy, clippy::redundant_clone)] use std::borrow::Borrow; diff --git a/tests/ui/implicit_clone.rs b/tests/ui/implicit_clone.rs index 59333312607..88352b06af3 100644 --- a/tests/ui/implicit_clone.rs +++ b/tests/ui/implicit_clone.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::implicit_clone)] #![allow(clippy::clone_on_copy, clippy::redundant_clone)] use std::borrow::Borrow; diff --git a/tests/ui/implicit_hasher.rs b/tests/ui/implicit_hasher.rs index 35d08a07bc3..ca7c1221372 100644 --- a/tests/ui/implicit_hasher.rs +++ b/tests/ui/implicit_hasher.rs @@ -1,4 +1,4 @@ -// aux-build:proc_macros.rs +//@aux-build:proc_macros.rs #![deny(clippy::implicit_hasher)] #![allow(unused)] diff --git a/tests/ui/implicit_return.fixed b/tests/ui/implicit_return.fixed index 5e55b8b6739..64813eafda6 100644 --- a/tests/ui/implicit_return.fixed +++ b/tests/ui/implicit_return.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![feature(lint_reasons)] #![warn(clippy::implicit_return)] #![allow(clippy::needless_return, clippy::needless_bool, unused, clippy::never_loop)] diff --git a/tests/ui/implicit_return.rs b/tests/ui/implicit_return.rs index 76f0a980352..39d47b110db 100644 --- a/tests/ui/implicit_return.rs +++ b/tests/ui/implicit_return.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![feature(lint_reasons)] #![warn(clippy::implicit_return)] #![allow(clippy::needless_return, clippy::needless_bool, unused, clippy::never_loop)] diff --git a/tests/ui/implicit_saturating_add.fixed b/tests/ui/implicit_saturating_add.fixed index 7d363d59a6f..7fc510d6b41 100644 --- a/tests/ui/implicit_saturating_add.fixed +++ b/tests/ui/implicit_saturating_add.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused)] #![warn(clippy::implicit_saturating_add)] diff --git a/tests/ui/implicit_saturating_add.rs b/tests/ui/implicit_saturating_add.rs index 31a5916277f..3dcd91f42fe 100644 --- a/tests/ui/implicit_saturating_add.rs +++ b/tests/ui/implicit_saturating_add.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused)] #![warn(clippy::implicit_saturating_add)] diff --git a/tests/ui/implicit_saturating_sub.fixed b/tests/ui/implicit_saturating_sub.fixed index 93df81b1a7f..1a11db0982f 100644 --- a/tests/ui/implicit_saturating_sub.fixed +++ b/tests/ui/implicit_saturating_sub.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused_assignments, unused_mut, clippy::assign_op_pattern)] #![warn(clippy::implicit_saturating_sub)] diff --git a/tests/ui/implicit_saturating_sub.rs b/tests/ui/implicit_saturating_sub.rs index 8340bc8264d..9369df67430 100644 --- a/tests/ui/implicit_saturating_sub.rs +++ b/tests/ui/implicit_saturating_sub.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused_assignments, unused_mut, clippy::assign_op_pattern)] #![warn(clippy::implicit_saturating_sub)] diff --git a/tests/ui/inconsistent_digit_grouping.fixed b/tests/ui/inconsistent_digit_grouping.fixed index dd683e7f746..06919809ee9 100644 --- a/tests/ui/inconsistent_digit_grouping.fixed +++ b/tests/ui/inconsistent_digit_grouping.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #[warn(clippy::inconsistent_digit_grouping)] #[deny(clippy::unreadable_literal)] #[allow(unused_variables, clippy::excessive_precision)] diff --git a/tests/ui/inconsistent_digit_grouping.rs b/tests/ui/inconsistent_digit_grouping.rs index d5d27c853c2..04d9125f2bf 100644 --- a/tests/ui/inconsistent_digit_grouping.rs +++ b/tests/ui/inconsistent_digit_grouping.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #[warn(clippy::inconsistent_digit_grouping)] #[deny(clippy::unreadable_literal)] #[allow(unused_variables, clippy::excessive_precision)] diff --git a/tests/ui/inconsistent_struct_constructor.fixed b/tests/ui/inconsistent_struct_constructor.fixed index 5aaa00f8517..620d45e6828 100644 --- a/tests/ui/inconsistent_struct_constructor.fixed +++ b/tests/ui/inconsistent_struct_constructor.fixed @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build:proc_macros.rs +//@run-rustfix +//@aux-build:proc_macros.rs #![warn(clippy::inconsistent_struct_constructor)] #![allow(clippy::redundant_field_names)] diff --git a/tests/ui/inconsistent_struct_constructor.rs b/tests/ui/inconsistent_struct_constructor.rs index 2b2dd7f59a4..10ffadcb2ba 100644 --- a/tests/ui/inconsistent_struct_constructor.rs +++ b/tests/ui/inconsistent_struct_constructor.rs @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build:proc_macros.rs +//@run-rustfix +//@aux-build:proc_macros.rs #![warn(clippy::inconsistent_struct_constructor)] #![allow(clippy::redundant_field_names)] diff --git a/tests/ui/inefficient_to_string.fixed b/tests/ui/inefficient_to_string.fixed index c972b9419ef..557f7fb7358 100644 --- a/tests/ui/inefficient_to_string.fixed +++ b/tests/ui/inefficient_to_string.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![deny(clippy::inefficient_to_string)] use std::borrow::Cow; diff --git a/tests/ui/inefficient_to_string.rs b/tests/ui/inefficient_to_string.rs index acdc55aa0d6..6503001e345 100644 --- a/tests/ui/inefficient_to_string.rs +++ b/tests/ui/inefficient_to_string.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![deny(clippy::inefficient_to_string)] use std::borrow::Cow; diff --git a/tests/ui/infallible_destructuring_match.fixed b/tests/ui/infallible_destructuring_match.fixed index 61985e56b76..e396ae94aaa 100644 --- a/tests/ui/infallible_destructuring_match.fixed +++ b/tests/ui/infallible_destructuring_match.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![feature(exhaustive_patterns, never_type)] #![allow(dead_code, unreachable_code, unused_variables)] #![allow(clippy::let_and_return)] diff --git a/tests/ui/infallible_destructuring_match.rs b/tests/ui/infallible_destructuring_match.rs index f2768245bbc..3fce7bbb6c7 100644 --- a/tests/ui/infallible_destructuring_match.rs +++ b/tests/ui/infallible_destructuring_match.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![feature(exhaustive_patterns, never_type)] #![allow(dead_code, unreachable_code, unused_variables)] #![allow(clippy::let_and_return)] diff --git a/tests/ui/inline_fn_without_body.fixed b/tests/ui/inline_fn_without_body.fixed index fe21a71a42c..9c5819558fe 100644 --- a/tests/ui/inline_fn_without_body.fixed +++ b/tests/ui/inline_fn_without_body.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::inline_fn_without_body)] #![allow(clippy::inline_always)] diff --git a/tests/ui/inline_fn_without_body.rs b/tests/ui/inline_fn_without_body.rs index 50746989466..43ffaf8122b 100644 --- a/tests/ui/inline_fn_without_body.rs +++ b/tests/ui/inline_fn_without_body.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::inline_fn_without_body)] #![allow(clippy::inline_always)] diff --git a/tests/ui/int_plus_one.fixed b/tests/ui/int_plus_one.fixed index 642830f24f5..5a36ec462d4 100644 --- a/tests/ui/int_plus_one.fixed +++ b/tests/ui/int_plus_one.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #[allow(clippy::no_effect, clippy::unnecessary_operation)] #[warn(clippy::int_plus_one)] diff --git a/tests/ui/int_plus_one.rs b/tests/ui/int_plus_one.rs index 0755a0c79d2..bffa4afd6b0 100644 --- a/tests/ui/int_plus_one.rs +++ b/tests/ui/int_plus_one.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #[allow(clippy::no_effect, clippy::unnecessary_operation)] #[warn(clippy::int_plus_one)] diff --git a/tests/ui/integer_arithmetic.rs b/tests/ui/integer_arithmetic.rs index d253d103127..ab9b6094c2c 100644 --- a/tests/ui/integer_arithmetic.rs +++ b/tests/ui/integer_arithmetic.rs @@ -1,4 +1,4 @@ -// aux-build:proc_macro_derive.rs +//@aux-build:proc_macro_derive.rs #![warn(clippy::integer_arithmetic, clippy::float_arithmetic)] #![allow(clippy::no_effect, clippy::unnecessary_operation, clippy::op_ref)] diff --git a/tests/ui/into_iter_on_ref.fixed b/tests/ui/into_iter_on_ref.fixed index b77f17944d8..9f550acb157 100644 --- a/tests/ui/into_iter_on_ref.fixed +++ b/tests/ui/into_iter_on_ref.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(clippy::useless_vec, clippy::needless_borrow)] #![warn(clippy::into_iter_on_ref)] diff --git a/tests/ui/into_iter_on_ref.rs b/tests/ui/into_iter_on_ref.rs index 3854bb05af8..3381ae04dce 100644 --- a/tests/ui/into_iter_on_ref.rs +++ b/tests/ui/into_iter_on_ref.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(clippy::useless_vec, clippy::needless_borrow)] #![warn(clippy::into_iter_on_ref)] diff --git a/tests/ui/invalid_null_ptr_usage.fixed b/tests/ui/invalid_null_ptr_usage.fixed index 4f5322ebf20..9264fb7e9e7 100644 --- a/tests/ui/invalid_null_ptr_usage.fixed +++ b/tests/ui/invalid_null_ptr_usage.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix fn main() { unsafe { diff --git a/tests/ui/invalid_null_ptr_usage.rs b/tests/ui/invalid_null_ptr_usage.rs index ae51c52d8af..80c942d7757 100644 --- a/tests/ui/invalid_null_ptr_usage.rs +++ b/tests/ui/invalid_null_ptr_usage.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix fn main() { unsafe { diff --git a/tests/ui/is_digit_ascii_radix.fixed b/tests/ui/is_digit_ascii_radix.fixed index c0ba647d707..bc43303a680 100644 --- a/tests/ui/is_digit_ascii_radix.fixed +++ b/tests/ui/is_digit_ascii_radix.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::is_digit_ascii_radix)] diff --git a/tests/ui/is_digit_ascii_radix.rs b/tests/ui/is_digit_ascii_radix.rs index 68e3f3243d9..93cba5c8e4e 100644 --- a/tests/ui/is_digit_ascii_radix.rs +++ b/tests/ui/is_digit_ascii_radix.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::is_digit_ascii_radix)] diff --git a/tests/ui/issue_2356.fixed b/tests/ui/issue_2356.fixed index a73ee0fb2e5..a69f5ebdc08 100644 --- a/tests/ui/issue_2356.fixed +++ b/tests/ui/issue_2356.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![deny(clippy::while_let_on_iterator)] #![allow(unused_mut)] #![allow(clippy::uninlined_format_args)] diff --git a/tests/ui/issue_2356.rs b/tests/ui/issue_2356.rs index 9dd9069609b..50e1bce1f8c 100644 --- a/tests/ui/issue_2356.rs +++ b/tests/ui/issue_2356.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![deny(clippy::while_let_on_iterator)] #![allow(unused_mut)] #![allow(clippy::uninlined_format_args)] diff --git a/tests/ui/iter_cloned_collect.fixed b/tests/ui/iter_cloned_collect.fixed index 9b862133580..88f08bb991b 100644 --- a/tests/ui/iter_cloned_collect.fixed +++ b/tests/ui/iter_cloned_collect.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused)] diff --git a/tests/ui/iter_cloned_collect.rs b/tests/ui/iter_cloned_collect.rs index 639f50665f2..d3438b7f51a 100644 --- a/tests/ui/iter_cloned_collect.rs +++ b/tests/ui/iter_cloned_collect.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused)] diff --git a/tests/ui/iter_count.fixed b/tests/ui/iter_count.fixed index 90a6eef7526..4367a12f820 100644 --- a/tests/ui/iter_count.fixed +++ b/tests/ui/iter_count.fixed @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build:option_helpers.rs +//@run-rustfix +//@aux-build:option_helpers.rs #![warn(clippy::iter_count)] #![allow( diff --git a/tests/ui/iter_count.rs b/tests/ui/iter_count.rs index 6681a480a28..8c7543cf03b 100644 --- a/tests/ui/iter_count.rs +++ b/tests/ui/iter_count.rs @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build:option_helpers.rs +//@run-rustfix +//@aux-build:option_helpers.rs #![warn(clippy::iter_count)] #![allow( diff --git a/tests/ui/iter_kv_map.fixed b/tests/ui/iter_kv_map.fixed index f2a4c284cb1..64201b553fd 100644 --- a/tests/ui/iter_kv_map.fixed +++ b/tests/ui/iter_kv_map.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::iter_kv_map)] #![allow(unused_mut, clippy::redundant_clone, clippy::suspicious_map, clippy::map_identity)] diff --git a/tests/ui/iter_kv_map.rs b/tests/ui/iter_kv_map.rs index ad6564df408..ec0231ba572 100644 --- a/tests/ui/iter_kv_map.rs +++ b/tests/ui/iter_kv_map.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::iter_kv_map)] #![allow(unused_mut, clippy::redundant_clone, clippy::suspicious_map, clippy::map_identity)] diff --git a/tests/ui/iter_next_slice.fixed b/tests/ui/iter_next_slice.fixed index f612d26aaab..d862abc34e0 100644 --- a/tests/ui/iter_next_slice.fixed +++ b/tests/ui/iter_next_slice.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::iter_next_slice)] fn main() { diff --git a/tests/ui/iter_next_slice.rs b/tests/ui/iter_next_slice.rs index 5195f1c8667..da6fc46e428 100644 --- a/tests/ui/iter_next_slice.rs +++ b/tests/ui/iter_next_slice.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::iter_next_slice)] fn main() { diff --git a/tests/ui/iter_nth.rs b/tests/ui/iter_nth.rs index 9c21dd82ee4..e7fb97d4fbc 100644 --- a/tests/ui/iter_nth.rs +++ b/tests/ui/iter_nth.rs @@ -1,4 +1,4 @@ -// aux-build:option_helpers.rs +//@aux-build:option_helpers.rs #![warn(clippy::iter_nth)] diff --git a/tests/ui/iter_nth_zero.fixed b/tests/ui/iter_nth_zero.fixed index f23671c26e4..587b0d1d366 100644 --- a/tests/ui/iter_nth_zero.fixed +++ b/tests/ui/iter_nth_zero.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::iter_nth_zero)] use std::collections::HashSet; diff --git a/tests/ui/iter_nth_zero.rs b/tests/ui/iter_nth_zero.rs index 7c968d49845..93b576ec56f 100644 --- a/tests/ui/iter_nth_zero.rs +++ b/tests/ui/iter_nth_zero.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::iter_nth_zero)] use std::collections::HashSet; diff --git a/tests/ui/iter_on_empty_collections.fixed b/tests/ui/iter_on_empty_collections.fixed index bd9b07aefbf..4616f0cdc45 100644 --- a/tests/ui/iter_on_empty_collections.fixed +++ b/tests/ui/iter_on_empty_collections.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::iter_on_empty_collections)] #![allow(clippy::iter_next_slice, clippy::redundant_clone)] diff --git a/tests/ui/iter_on_empty_collections.rs b/tests/ui/iter_on_empty_collections.rs index e15ba94bd46..81cc7265e11 100644 --- a/tests/ui/iter_on_empty_collections.rs +++ b/tests/ui/iter_on_empty_collections.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::iter_on_empty_collections)] #![allow(clippy::iter_next_slice, clippy::redundant_clone)] diff --git a/tests/ui/iter_on_single_items.fixed b/tests/ui/iter_on_single_items.fixed index 1fa4b03641b..80dbe454b47 100644 --- a/tests/ui/iter_on_single_items.fixed +++ b/tests/ui/iter_on_single_items.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::iter_on_single_items)] #![allow(clippy::iter_next_slice, clippy::redundant_clone)] diff --git a/tests/ui/iter_on_single_items.rs b/tests/ui/iter_on_single_items.rs index ea96d8066c5..71c8c7a3f94 100644 --- a/tests/ui/iter_on_single_items.rs +++ b/tests/ui/iter_on_single_items.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::iter_on_single_items)] #![allow(clippy::iter_next_slice, clippy::redundant_clone)] diff --git a/tests/ui/iter_overeager_cloned.fixed b/tests/ui/iter_overeager_cloned.fixed index c100705d017..bf576e9cbfb 100644 --- a/tests/ui/iter_overeager_cloned.fixed +++ b/tests/ui/iter_overeager_cloned.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::iter_overeager_cloned, clippy::redundant_clone, clippy::filter_next)] #![allow(dead_code, clippy::let_unit_value)] diff --git a/tests/ui/iter_overeager_cloned.rs b/tests/ui/iter_overeager_cloned.rs index 2caa8802066..df42d88eff0 100644 --- a/tests/ui/iter_overeager_cloned.rs +++ b/tests/ui/iter_overeager_cloned.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::iter_overeager_cloned, clippy::redundant_clone, clippy::filter_next)] #![allow(dead_code, clippy::let_unit_value)] diff --git a/tests/ui/iter_skip_next.fixed b/tests/ui/iter_skip_next.fixed index d56d623b526..8f2cefc4304 100644 --- a/tests/ui/iter_skip_next.fixed +++ b/tests/ui/iter_skip_next.fixed @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build:option_helpers.rs +//@run-rustfix +//@aux-build:option_helpers.rs #![warn(clippy::iter_skip_next)] #![allow(clippy::disallowed_names)] diff --git a/tests/ui/iter_skip_next.rs b/tests/ui/iter_skip_next.rs index 3ec5d1b8214..71d83384f3a 100644 --- a/tests/ui/iter_skip_next.rs +++ b/tests/ui/iter_skip_next.rs @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build:option_helpers.rs +//@run-rustfix +//@aux-build:option_helpers.rs #![warn(clippy::iter_skip_next)] #![allow(clippy::disallowed_names)] diff --git a/tests/ui/iter_with_drain.fixed b/tests/ui/iter_with_drain.fixed index 0330d554926..24a95c4d0fe 100644 --- a/tests/ui/iter_with_drain.fixed +++ b/tests/ui/iter_with_drain.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix // will emits unused mut warnings after fixing #![allow(unused_mut)] // will emits needless collect warnings after fixing diff --git a/tests/ui/iter_with_drain.rs b/tests/ui/iter_with_drain.rs index 993936fb8de..a118c981ee3 100644 --- a/tests/ui/iter_with_drain.rs +++ b/tests/ui/iter_with_drain.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix // will emits unused mut warnings after fixing #![allow(unused_mut)] // will emits needless collect warnings after fixing diff --git a/tests/ui/large_const_arrays.fixed b/tests/ui/large_const_arrays.fixed index c5af07c8a17..f7ce6fbe6bb 100644 --- a/tests/ui/large_const_arrays.fixed +++ b/tests/ui/large_const_arrays.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::large_const_arrays)] #![allow(dead_code)] diff --git a/tests/ui/large_const_arrays.rs b/tests/ui/large_const_arrays.rs index a160b9f8ad5..002ac77ddda 100644 --- a/tests/ui/large_const_arrays.rs +++ b/tests/ui/large_const_arrays.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::large_const_arrays)] #![allow(dead_code)] diff --git a/tests/ui/large_digit_groups.fixed b/tests/ui/large_digit_groups.fixed index ea18dac0683..f42fcd96d79 100644 --- a/tests/ui/large_digit_groups.fixed +++ b/tests/ui/large_digit_groups.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::large_digit_groups)] fn main() { diff --git a/tests/ui/large_digit_groups.rs b/tests/ui/large_digit_groups.rs index ac116d5dbda..3db9da6a3a5 100644 --- a/tests/ui/large_digit_groups.rs +++ b/tests/ui/large_digit_groups.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::large_digit_groups)] fn main() { diff --git a/tests/ui/large_enum_variant.rs b/tests/ui/large_enum_variant.rs index f09f8ae0ccc..ea8bc5b4aca 100644 --- a/tests/ui/large_enum_variant.rs +++ b/tests/ui/large_enum_variant.rs @@ -1,4 +1,4 @@ -// aux-build:proc_macros.rs +//@aux-build:proc_macros.rs #![allow(dead_code)] #![allow(unused_variables)] diff --git a/tests/ui/large_types_passed_by_value.rs b/tests/ui/large_types_passed_by_value.rs index 7601b5c66fa..f9e3c7192ad 100644 --- a/tests/ui/large_types_passed_by_value.rs +++ b/tests/ui/large_types_passed_by_value.rs @@ -1,5 +1,5 @@ -// normalize-stderr-test "\(\d+ byte\)" -> "(N byte)" -// normalize-stderr-test "\(limit: \d+ byte\)" -> "(limit: N byte)" +//@normalize-stderr-test: "\(\d+ byte\)" -> "(N byte)" +//@normalize-stderr-test: "\(limit: \d+ byte\)" -> "(limit: N byte)" #![warn(clippy::large_types_passed_by_value)] diff --git a/tests/ui/len_zero.fixed b/tests/ui/len_zero.fixed index c1c0b5ae40f..34b2021df45 100644 --- a/tests/ui/len_zero.fixed +++ b/tests/ui/len_zero.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::len_zero)] #![allow(dead_code, unused, clippy::len_without_is_empty)] diff --git a/tests/ui/len_zero.rs b/tests/ui/len_zero.rs index cc2eb05b6bf..c83ae2ac553 100644 --- a/tests/ui/len_zero.rs +++ b/tests/ui/len_zero.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::len_zero)] #![allow(dead_code, unused, clippy::len_without_is_empty)] diff --git a/tests/ui/len_zero_ranges.fixed b/tests/ui/len_zero_ranges.fixed index 79781766242..4b1241ec86b 100644 --- a/tests/ui/len_zero_ranges.fixed +++ b/tests/ui/len_zero_ranges.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::len_zero)] #![allow(unused)] diff --git a/tests/ui/len_zero_ranges.rs b/tests/ui/len_zero_ranges.rs index a0eb51cc976..4b47132c766 100644 --- a/tests/ui/len_zero_ranges.rs +++ b/tests/ui/len_zero_ranges.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::len_zero)] #![allow(unused)] diff --git a/tests/ui/let_unit.fixed b/tests/ui/let_unit.fixed index 76ff0645f41..8ba89ec78bb 100644 --- a/tests/ui/let_unit.fixed +++ b/tests/ui/let_unit.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![feature(lint_reasons)] #![warn(clippy::let_unit_value)] diff --git a/tests/ui/let_unit.rs b/tests/ui/let_unit.rs index 895ccfe366a..7e8764a482a 100644 --- a/tests/ui/let_unit.rs +++ b/tests/ui/let_unit.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![feature(lint_reasons)] #![warn(clippy::let_unit_value)] diff --git a/tests/ui/lines_filter_map_ok.fixed b/tests/ui/lines_filter_map_ok.fixed index f4033cd8ed8..64114f6585d 100644 --- a/tests/ui/lines_filter_map_ok.fixed +++ b/tests/ui/lines_filter_map_ok.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused, clippy::map_identity)] #![warn(clippy::lines_filter_map_ok)] diff --git a/tests/ui/lines_filter_map_ok.rs b/tests/ui/lines_filter_map_ok.rs index 7e11816b2ac..5aedc686336 100644 --- a/tests/ui/lines_filter_map_ok.rs +++ b/tests/ui/lines_filter_map_ok.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused, clippy::map_identity)] #![warn(clippy::lines_filter_map_ok)] diff --git a/tests/ui/lossy_float_literal.fixed b/tests/ui/lossy_float_literal.fixed index 24e372354fc..a2088575610 100644 --- a/tests/ui/lossy_float_literal.fixed +++ b/tests/ui/lossy_float_literal.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::lossy_float_literal)] fn main() { diff --git a/tests/ui/lossy_float_literal.rs b/tests/ui/lossy_float_literal.rs index 3dcf98fa0bd..1a75f214c85 100644 --- a/tests/ui/lossy_float_literal.rs +++ b/tests/ui/lossy_float_literal.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::lossy_float_literal)] fn main() { diff --git a/tests/ui/macro_use_imports.fixed b/tests/ui/macro_use_imports.fixed index 15f7a099a7d..9208fbcb783 100644 --- a/tests/ui/macro_use_imports.fixed +++ b/tests/ui/macro_use_imports.fixed @@ -1,8 +1,8 @@ -// aux-build:macro_rules.rs -// aux-build:macro_use_helper.rs -// aux-build:proc_macro_derive.rs -// run-rustfix -// ignore-32bit +//@aux-build:macro_rules.rs +//@aux-build:macro_use_helper.rs +//@aux-build:proc_macro_derive.rs +//@run-rustfix +//@ignore-32bit #![feature(lint_reasons)] #![allow(unused_imports, unreachable_code, unused_variables, dead_code, unused_attributes)] diff --git a/tests/ui/macro_use_imports.rs b/tests/ui/macro_use_imports.rs index b1a28733294..925a2c61f8d 100644 --- a/tests/ui/macro_use_imports.rs +++ b/tests/ui/macro_use_imports.rs @@ -1,8 +1,8 @@ -// aux-build:macro_rules.rs -// aux-build:macro_use_helper.rs -// aux-build:proc_macro_derive.rs -// run-rustfix -// ignore-32bit +//@aux-build:macro_rules.rs +//@aux-build:macro_use_helper.rs +//@aux-build:proc_macro_derive.rs +//@run-rustfix +//@ignore-32bit #![feature(lint_reasons)] #![allow(unused_imports, unreachable_code, unused_variables, dead_code, unused_attributes)] diff --git a/tests/ui/macro_use_imports_expect.rs b/tests/ui/macro_use_imports_expect.rs index 5aac5af26db..b9677851b92 100644 --- a/tests/ui/macro_use_imports_expect.rs +++ b/tests/ui/macro_use_imports_expect.rs @@ -1,7 +1,7 @@ -// aux-build:macro_rules.rs -// aux-build:macro_use_helper.rs -// aux-build:proc_macro_derive.rs -// ignore-32bit +//@aux-build:macro_rules.rs +//@aux-build:macro_use_helper.rs +//@aux-build:proc_macro_derive.rs +//@ignore-32bit #![feature(lint_reasons)] #![allow(unused_imports, unreachable_code, unused_variables, dead_code, unused_attributes)] diff --git a/tests/ui/manual_assert.edition2018.fixed b/tests/ui/manual_assert.edition2018.fixed index 8c7e919bf62..ab9b375dc03 100644 --- a/tests/ui/manual_assert.edition2018.fixed +++ b/tests/ui/manual_assert.edition2018.fixed @@ -1,7 +1,7 @@ -// revisions: edition2018 edition2021 -//[edition2018] edition:2018 -//[edition2021] edition:2021 -// run-rustfix +//@revisions: edition2018 edition2021 +//@[edition2018] edition:2018 +//@[edition2021] edition:2021 +//@run-rustfix #![warn(clippy::manual_assert)] #![allow(dead_code, unused_doc_comments)] diff --git a/tests/ui/manual_assert.edition2021.fixed b/tests/ui/manual_assert.edition2021.fixed index 8c7e919bf62..ab9b375dc03 100644 --- a/tests/ui/manual_assert.edition2021.fixed +++ b/tests/ui/manual_assert.edition2021.fixed @@ -1,7 +1,7 @@ -// revisions: edition2018 edition2021 -//[edition2018] edition:2018 -//[edition2021] edition:2021 -// run-rustfix +//@revisions: edition2018 edition2021 +//@[edition2018] edition:2018 +//@[edition2021] edition:2021 +//@run-rustfix #![warn(clippy::manual_assert)] #![allow(dead_code, unused_doc_comments)] diff --git a/tests/ui/manual_assert.rs b/tests/ui/manual_assert.rs index f037c5b8405..eac52d1b5de 100644 --- a/tests/ui/manual_assert.rs +++ b/tests/ui/manual_assert.rs @@ -1,7 +1,7 @@ -// revisions: edition2018 edition2021 -//[edition2018] edition:2018 -//[edition2021] edition:2021 -// run-rustfix +//@revisions: edition2018 edition2021 +//@[edition2018] edition:2018 +//@[edition2021] edition:2021 +//@run-rustfix #![warn(clippy::manual_assert)] #![allow(dead_code, unused_doc_comments)] diff --git a/tests/ui/manual_async_fn.fixed b/tests/ui/manual_async_fn.fixed index 5cc4a43af7e..e458f0d254f 100644 --- a/tests/ui/manual_async_fn.fixed +++ b/tests/ui/manual_async_fn.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::manual_async_fn)] #![allow(unused)] diff --git a/tests/ui/manual_async_fn.rs b/tests/ui/manual_async_fn.rs index ba504b8a823..dd5ca1c9b5b 100644 --- a/tests/ui/manual_async_fn.rs +++ b/tests/ui/manual_async_fn.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::manual_async_fn)] #![allow(unused)] diff --git a/tests/ui/manual_bits.fixed b/tests/ui/manual_bits.fixed index e7f8cd878ca..037de0262e2 100644 --- a/tests/ui/manual_bits.fixed +++ b/tests/ui/manual_bits.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::manual_bits)] #![allow( diff --git a/tests/ui/manual_bits.rs b/tests/ui/manual_bits.rs index 7b1d1549528..b15a531ec17 100644 --- a/tests/ui/manual_bits.rs +++ b/tests/ui/manual_bits.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::manual_bits)] #![allow( diff --git a/tests/ui/manual_filter.fixed b/tests/ui/manual_filter.fixed index ef6780dc96d..755caa664d5 100644 --- a/tests/ui/manual_filter.fixed +++ b/tests/ui/manual_filter.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::manual_filter)] #![allow(unused_variables, dead_code)] diff --git a/tests/ui/manual_filter.rs b/tests/ui/manual_filter.rs index ea0ce83172b..faccfe9db12 100644 --- a/tests/ui/manual_filter.rs +++ b/tests/ui/manual_filter.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::manual_filter)] #![allow(unused_variables, dead_code)] diff --git a/tests/ui/manual_filter_map.fixed b/tests/ui/manual_filter_map.fixed index 4936dc9b2e0..831323089e7 100644 --- a/tests/ui/manual_filter_map.fixed +++ b/tests/ui/manual_filter_map.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(dead_code)] #![warn(clippy::manual_filter_map)] #![allow(clippy::redundant_closure)] // FIXME suggestion may have redundant closure diff --git a/tests/ui/manual_filter_map.rs b/tests/ui/manual_filter_map.rs index 8c67e827b4c..2692303d313 100644 --- a/tests/ui/manual_filter_map.rs +++ b/tests/ui/manual_filter_map.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(dead_code)] #![warn(clippy::manual_filter_map)] #![allow(clippy::redundant_closure)] // FIXME suggestion may have redundant closure diff --git a/tests/ui/manual_find_fixable.fixed b/tests/ui/manual_find_fixable.fixed index 2bce6e624c9..9c5eb20c81c 100644 --- a/tests/ui/manual_find_fixable.fixed +++ b/tests/ui/manual_find_fixable.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::manual_find)] #![allow(unused)] #![allow(clippy::needless_return, clippy::uninlined_format_args)] diff --git a/tests/ui/manual_find_fixable.rs b/tests/ui/manual_find_fixable.rs index f5c6de37a25..7b670320ee3 100644 --- a/tests/ui/manual_find_fixable.rs +++ b/tests/ui/manual_find_fixable.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::manual_find)] #![allow(unused)] #![allow(clippy::needless_return, clippy::uninlined_format_args)] diff --git a/tests/ui/manual_find_map.fixed b/tests/ui/manual_find_map.fixed index 54302beceff..554613a30a9 100644 --- a/tests/ui/manual_find_map.fixed +++ b/tests/ui/manual_find_map.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(dead_code)] #![warn(clippy::manual_find_map)] #![allow(clippy::redundant_closure)] // FIXME suggestion may have redundant closure diff --git a/tests/ui/manual_find_map.rs b/tests/ui/manual_find_map.rs index afcc1825a9a..d6245758f9d 100644 --- a/tests/ui/manual_find_map.rs +++ b/tests/ui/manual_find_map.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(dead_code)] #![warn(clippy::manual_find_map)] #![allow(clippy::redundant_closure)] // FIXME suggestion may have redundant closure diff --git a/tests/ui/manual_instant_elapsed.fixed b/tests/ui/manual_instant_elapsed.fixed index 85a91543c89..55073c3b57c 100644 --- a/tests/ui/manual_instant_elapsed.fixed +++ b/tests/ui/manual_instant_elapsed.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::manual_instant_elapsed)] #![allow(clippy::unnecessary_operation)] #![allow(clippy::unchecked_duration_subtraction)] diff --git a/tests/ui/manual_instant_elapsed.rs b/tests/ui/manual_instant_elapsed.rs index c98cb15b916..c9029a04940 100644 --- a/tests/ui/manual_instant_elapsed.rs +++ b/tests/ui/manual_instant_elapsed.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::manual_instant_elapsed)] #![allow(clippy::unnecessary_operation)] #![allow(clippy::unchecked_duration_subtraction)] diff --git a/tests/ui/manual_is_ascii_check.fixed b/tests/ui/manual_is_ascii_check.fixed index 5b2b44c2fdb..87e86658668 100644 --- a/tests/ui/manual_is_ascii_check.fixed +++ b/tests/ui/manual_is_ascii_check.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused, dead_code)] #![warn(clippy::manual_is_ascii_check)] diff --git a/tests/ui/manual_is_ascii_check.rs b/tests/ui/manual_is_ascii_check.rs index c9433f33a1b..931f0f20276 100644 --- a/tests/ui/manual_is_ascii_check.rs +++ b/tests/ui/manual_is_ascii_check.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused, dead_code)] #![warn(clippy::manual_is_ascii_check)] diff --git a/tests/ui/manual_main_separator_str.fixed b/tests/ui/manual_main_separator_str.fixed index 50f46d6b355..7e7da8f20bb 100644 --- a/tests/ui/manual_main_separator_str.fixed +++ b/tests/ui/manual_main_separator_str.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused)] #![warn(clippy::manual_main_separator_str)] diff --git a/tests/ui/manual_main_separator_str.rs b/tests/ui/manual_main_separator_str.rs index 2dbb9e66151..cf90e12efc3 100644 --- a/tests/ui/manual_main_separator_str.rs +++ b/tests/ui/manual_main_separator_str.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused)] #![warn(clippy::manual_main_separator_str)] diff --git a/tests/ui/manual_map_option.fixed b/tests/ui/manual_map_option.fixed index e12ea7ec145..e8ff65cad6a 100644 --- a/tests/ui/manual_map_option.fixed +++ b/tests/ui/manual_map_option.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::manual_map)] #![allow( diff --git a/tests/ui/manual_map_option.rs b/tests/ui/manual_map_option.rs index 325a6db06c4..b06a96451ce 100644 --- a/tests/ui/manual_map_option.rs +++ b/tests/ui/manual_map_option.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::manual_map)] #![allow( diff --git a/tests/ui/manual_map_option_2.fixed b/tests/ui/manual_map_option_2.fixed index ebf3f8cabd4..dc722878248 100644 --- a/tests/ui/manual_map_option_2.fixed +++ b/tests/ui/manual_map_option_2.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::manual_map)] #![allow(clippy::toplevel_ref_arg)] diff --git a/tests/ui/manual_map_option_2.rs b/tests/ui/manual_map_option_2.rs index 1382d9af0aa..c495ab0fa6e 100644 --- a/tests/ui/manual_map_option_2.rs +++ b/tests/ui/manual_map_option_2.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::manual_map)] #![allow(clippy::toplevel_ref_arg)] diff --git a/tests/ui/manual_ok_or.fixed b/tests/ui/manual_ok_or.fixed index fc8511626b3..d8901dc3b03 100644 --- a/tests/ui/manual_ok_or.fixed +++ b/tests/ui/manual_ok_or.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::manual_ok_or)] #![allow(clippy::or_fun_call)] #![allow(clippy::disallowed_names)] diff --git a/tests/ui/manual_ok_or.rs b/tests/ui/manual_ok_or.rs index b5303d33f5f..7188a521357 100644 --- a/tests/ui/manual_ok_or.rs +++ b/tests/ui/manual_ok_or.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::manual_ok_or)] #![allow(clippy::or_fun_call)] #![allow(clippy::disallowed_names)] diff --git a/tests/ui/manual_rem_euclid.fixed b/tests/ui/manual_rem_euclid.fixed index 1f6df1b0a86..f2e44e56f02 100644 --- a/tests/ui/manual_rem_euclid.fixed +++ b/tests/ui/manual_rem_euclid.fixed @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build:proc_macros.rs +//@run-rustfix +//@aux-build:proc_macros.rs #![warn(clippy::manual_rem_euclid)] #![allow(clippy::let_with_type_underscore)] diff --git a/tests/ui/manual_rem_euclid.rs b/tests/ui/manual_rem_euclid.rs index b275e8a38d2..b2329c33a47 100644 --- a/tests/ui/manual_rem_euclid.rs +++ b/tests/ui/manual_rem_euclid.rs @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build:proc_macros.rs +//@run-rustfix +//@aux-build:proc_macros.rs #![warn(clippy::manual_rem_euclid)] #![allow(clippy::let_with_type_underscore)] diff --git a/tests/ui/manual_retain.fixed b/tests/ui/manual_retain.fixed index 8f25fea678f..d3cac666763 100644 --- a/tests/ui/manual_retain.fixed +++ b/tests/ui/manual_retain.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::manual_retain)] #![allow(unused, clippy::redundant_clone)] use std::collections::BTreeMap; diff --git a/tests/ui/manual_retain.rs b/tests/ui/manual_retain.rs index e6b3995a689..34f0c4d5029 100644 --- a/tests/ui/manual_retain.rs +++ b/tests/ui/manual_retain.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::manual_retain)] #![allow(unused, clippy::redundant_clone)] use std::collections::BTreeMap; diff --git a/tests/ui/manual_saturating_arithmetic.fixed b/tests/ui/manual_saturating_arithmetic.fixed index c4f53c446c9..7dd4521fa78 100644 --- a/tests/ui/manual_saturating_arithmetic.fixed +++ b/tests/ui/manual_saturating_arithmetic.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused_imports)] diff --git a/tests/ui/manual_saturating_arithmetic.rs b/tests/ui/manual_saturating_arithmetic.rs index cd83cf6e65e..463ee069289 100644 --- a/tests/ui/manual_saturating_arithmetic.rs +++ b/tests/ui/manual_saturating_arithmetic.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused_imports)] diff --git a/tests/ui/manual_slice_size_calculation.fixed b/tests/ui/manual_slice_size_calculation.fixed index 71368a25e22..ac85bd8d3ac 100644 --- a/tests/ui/manual_slice_size_calculation.fixed +++ b/tests/ui/manual_slice_size_calculation.fixed @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build:proc_macros.rs +//@run-rustfix +//@aux-build:proc_macros.rs #![allow(unused)] #![warn(clippy::manual_slice_size_calculation)] diff --git a/tests/ui/manual_slice_size_calculation.rs b/tests/ui/manual_slice_size_calculation.rs index 5dd14aaede0..1f824b12bc2 100644 --- a/tests/ui/manual_slice_size_calculation.rs +++ b/tests/ui/manual_slice_size_calculation.rs @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build:proc_macros.rs +//@run-rustfix +//@aux-build:proc_macros.rs #![allow(unused)] #![warn(clippy::manual_slice_size_calculation)] diff --git a/tests/ui/manual_split_once.fixed b/tests/ui/manual_split_once.fixed index 50b02019cc2..e317c597109 100644 --- a/tests/ui/manual_split_once.fixed +++ b/tests/ui/manual_split_once.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::manual_split_once)] #![allow(unused, clippy::iter_skip_next, clippy::iter_nth_zero)] diff --git a/tests/ui/manual_split_once.rs b/tests/ui/manual_split_once.rs index e1e8b71a9de..7e2dc22bc46 100644 --- a/tests/ui/manual_split_once.rs +++ b/tests/ui/manual_split_once.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::manual_split_once)] #![allow(unused, clippy::iter_skip_next, clippy::iter_nth_zero)] diff --git a/tests/ui/manual_str_repeat.fixed b/tests/ui/manual_str_repeat.fixed index 3d56f2a0ded..9468c3df904 100644 --- a/tests/ui/manual_str_repeat.fixed +++ b/tests/ui/manual_str_repeat.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::manual_str_repeat)] diff --git a/tests/ui/manual_str_repeat.rs b/tests/ui/manual_str_repeat.rs index e8240a949db..baa0a10260d 100644 --- a/tests/ui/manual_str_repeat.rs +++ b/tests/ui/manual_str_repeat.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::manual_str_repeat)] diff --git a/tests/ui/manual_string_new.fixed b/tests/ui/manual_string_new.fixed index a376411bfbc..0d1bab23304 100644 --- a/tests/ui/manual_string_new.fixed +++ b/tests/ui/manual_string_new.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::manual_string_new)] diff --git a/tests/ui/manual_string_new.rs b/tests/ui/manual_string_new.rs index 6bfc52fb1bc..2392ebfc322 100644 --- a/tests/ui/manual_string_new.rs +++ b/tests/ui/manual_string_new.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::manual_string_new)] diff --git a/tests/ui/manual_unwrap_or.fixed b/tests/ui/manual_unwrap_or.fixed index 7d68978216c..c17634bffe3 100644 --- a/tests/ui/manual_unwrap_or.fixed +++ b/tests/ui/manual_unwrap_or.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(dead_code)] #![allow(unused_variables, clippy::unnecessary_wraps)] diff --git a/tests/ui/manual_unwrap_or.rs b/tests/ui/manual_unwrap_or.rs index b937fe6f977..6d49a6949fa 100644 --- a/tests/ui/manual_unwrap_or.rs +++ b/tests/ui/manual_unwrap_or.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(dead_code)] #![allow(unused_variables, clippy::unnecessary_wraps)] diff --git a/tests/ui/map_clone.fixed b/tests/ui/map_clone.fixed index 0860dcf8e0d..d7474f35719 100644 --- a/tests/ui/map_clone.fixed +++ b/tests/ui/map_clone.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::map_clone)] #![allow( clippy::clone_on_copy, diff --git a/tests/ui/map_clone.rs b/tests/ui/map_clone.rs index b6987336834..74978ae8006 100644 --- a/tests/ui/map_clone.rs +++ b/tests/ui/map_clone.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::map_clone)] #![allow( clippy::clone_on_copy, diff --git a/tests/ui/map_collect_result_unit.fixed b/tests/ui/map_collect_result_unit.fixed index e66c9cc2420..b00c2cf284e 100644 --- a/tests/ui/map_collect_result_unit.fixed +++ b/tests/ui/map_collect_result_unit.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::map_collect_result_unit)] fn main() { diff --git a/tests/ui/map_collect_result_unit.rs b/tests/ui/map_collect_result_unit.rs index 6f08f4c3c53..ad2198ec1fe 100644 --- a/tests/ui/map_collect_result_unit.rs +++ b/tests/ui/map_collect_result_unit.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::map_collect_result_unit)] fn main() { diff --git a/tests/ui/map_flatten_fixable.fixed b/tests/ui/map_flatten_fixable.fixed index 8e2f11389f8..14816de1a63 100644 --- a/tests/ui/map_flatten_fixable.fixed +++ b/tests/ui/map_flatten_fixable.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::all, clippy::pedantic)] #![allow(clippy::let_underscore_untyped)] diff --git a/tests/ui/map_flatten_fixable.rs b/tests/ui/map_flatten_fixable.rs index a783a99c4ff..f38a00a59fa 100644 --- a/tests/ui/map_flatten_fixable.rs +++ b/tests/ui/map_flatten_fixable.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::all, clippy::pedantic)] #![allow(clippy::let_underscore_untyped)] diff --git a/tests/ui/map_identity.fixed b/tests/ui/map_identity.fixed index 2256e51f2d0..7fb7d8c1218 100644 --- a/tests/ui/map_identity.fixed +++ b/tests/ui/map_identity.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::map_identity)] #![allow(clippy::needless_return)] diff --git a/tests/ui/map_identity.rs b/tests/ui/map_identity.rs index ccfdc9ea76d..7891c242628 100644 --- a/tests/ui/map_identity.rs +++ b/tests/ui/map_identity.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::map_identity)] #![allow(clippy::needless_return)] diff --git a/tests/ui/map_unwrap_or.rs b/tests/ui/map_unwrap_or.rs index 32631024ca5..cb25d8567aa 100644 --- a/tests/ui/map_unwrap_or.rs +++ b/tests/ui/map_unwrap_or.rs @@ -1,4 +1,4 @@ -// aux-build:option_helpers.rs +//@aux-build:option_helpers.rs #![warn(clippy::map_unwrap_or)] #![allow(clippy::uninlined_format_args, clippy::unnecessary_lazy_evaluations)] diff --git a/tests/ui/map_unwrap_or_fixable.fixed b/tests/ui/map_unwrap_or_fixable.fixed index bd5b4f7165a..ea5b6a6691e 100644 --- a/tests/ui/map_unwrap_or_fixable.fixed +++ b/tests/ui/map_unwrap_or_fixable.fixed @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build:option_helpers.rs +//@run-rustfix +//@aux-build:option_helpers.rs #![warn(clippy::map_unwrap_or)] diff --git a/tests/ui/map_unwrap_or_fixable.rs b/tests/ui/map_unwrap_or_fixable.rs index 0b892caf20e..f8bb9d8ca6a 100644 --- a/tests/ui/map_unwrap_or_fixable.rs +++ b/tests/ui/map_unwrap_or_fixable.rs @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build:option_helpers.rs +//@run-rustfix +//@aux-build:option_helpers.rs #![warn(clippy::map_unwrap_or)] diff --git a/tests/ui/match_as_ref.fixed b/tests/ui/match_as_ref.fixed index ddfa1e741ad..8fa3f532587 100644 --- a/tests/ui/match_as_ref.fixed +++ b/tests/ui/match_as_ref.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused)] #![warn(clippy::match_as_ref)] diff --git a/tests/ui/match_as_ref.rs b/tests/ui/match_as_ref.rs index 025d475ae13..02a17791426 100644 --- a/tests/ui/match_as_ref.rs +++ b/tests/ui/match_as_ref.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused)] #![warn(clippy::match_as_ref)] diff --git a/tests/ui/match_expr_like_matches_macro.fixed b/tests/ui/match_expr_like_matches_macro.fixed index 55cd15bd5c3..7215660da67 100644 --- a/tests/ui/match_expr_like_matches_macro.fixed +++ b/tests/ui/match_expr_like_matches_macro.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::match_like_matches_macro)] #![allow( diff --git a/tests/ui/match_expr_like_matches_macro.rs b/tests/ui/match_expr_like_matches_macro.rs index 5d645e108e5..afdf1069f5e 100644 --- a/tests/ui/match_expr_like_matches_macro.rs +++ b/tests/ui/match_expr_like_matches_macro.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::match_like_matches_macro)] #![allow( diff --git a/tests/ui/match_ref_pats.fixed b/tests/ui/match_ref_pats.fixed index cf37fc6dc90..50c3dcc1e0a 100644 --- a/tests/ui/match_ref_pats.fixed +++ b/tests/ui/match_ref_pats.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::match_ref_pats)] #![allow(dead_code, unused_variables)] #![allow(clippy::enum_variant_names, clippy::equatable_if_let, clippy::uninlined_format_args)] diff --git a/tests/ui/match_ref_pats.rs b/tests/ui/match_ref_pats.rs index 3220b97d1b5..d29ddacc04a 100644 --- a/tests/ui/match_ref_pats.rs +++ b/tests/ui/match_ref_pats.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::match_ref_pats)] #![allow(dead_code, unused_variables)] #![allow(clippy::enum_variant_names, clippy::equatable_if_let, clippy::uninlined_format_args)] diff --git a/tests/ui/match_result_ok.fixed b/tests/ui/match_result_ok.fixed index 10ae1ee5245..fe67b225fa1 100644 --- a/tests/ui/match_result_ok.fixed +++ b/tests/ui/match_result_ok.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::match_result_ok)] #![allow(dead_code)] #![allow(clippy::boxed_local, clippy::uninlined_format_args)] diff --git a/tests/ui/match_result_ok.rs b/tests/ui/match_result_ok.rs index bc2c4b50e27..eac382e1f62 100644 --- a/tests/ui/match_result_ok.rs +++ b/tests/ui/match_result_ok.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::match_result_ok)] #![allow(dead_code)] #![allow(clippy::boxed_local, clippy::uninlined_format_args)] diff --git a/tests/ui/match_single_binding.fixed b/tests/ui/match_single_binding.fixed index 201301cc9b7..7c29bb08e64 100644 --- a/tests/ui/match_single_binding.fixed +++ b/tests/ui/match_single_binding.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::match_single_binding)] #![allow( unused, diff --git a/tests/ui/match_single_binding.rs b/tests/ui/match_single_binding.rs index 8b047b19ce9..c068d5e17c3 100644 --- a/tests/ui/match_single_binding.rs +++ b/tests/ui/match_single_binding.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::match_single_binding)] #![allow( unused, diff --git a/tests/ui/match_single_binding2.fixed b/tests/ui/match_single_binding2.fixed index e3cf56a4293..adfb4ba91f7 100644 --- a/tests/ui/match_single_binding2.fixed +++ b/tests/ui/match_single_binding2.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::match_single_binding)] #![allow(unused_variables)] #![allow(clippy::uninlined_format_args)] diff --git a/tests/ui/match_single_binding2.rs b/tests/ui/match_single_binding2.rs index 5a4bb8441ff..b5cfe3654a5 100644 --- a/tests/ui/match_single_binding2.rs +++ b/tests/ui/match_single_binding2.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::match_single_binding)] #![allow(unused_variables)] #![allow(clippy::uninlined_format_args)] diff --git a/tests/ui/match_str_case_mismatch.fixed b/tests/ui/match_str_case_mismatch.fixed index e436bcf495f..cd53b1f06fa 100644 --- a/tests/ui/match_str_case_mismatch.fixed +++ b/tests/ui/match_str_case_mismatch.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::match_str_case_mismatch)] #![allow(dead_code)] diff --git a/tests/ui/match_str_case_mismatch.rs b/tests/ui/match_str_case_mismatch.rs index 92e2a000ade..6885305662a 100644 --- a/tests/ui/match_str_case_mismatch.rs +++ b/tests/ui/match_str_case_mismatch.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::match_str_case_mismatch)] #![allow(dead_code)] diff --git a/tests/ui/match_wildcard_for_single_variants.fixed b/tests/ui/match_wildcard_for_single_variants.fixed index 9fd3739b69c..d2e6fef0759 100644 --- a/tests/ui/match_wildcard_for_single_variants.fixed +++ b/tests/ui/match_wildcard_for_single_variants.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::match_wildcard_for_single_variants)] #![allow(dead_code)] diff --git a/tests/ui/match_wildcard_for_single_variants.rs b/tests/ui/match_wildcard_for_single_variants.rs index 9a5c849e6ec..cff0c896065 100644 --- a/tests/ui/match_wildcard_for_single_variants.rs +++ b/tests/ui/match_wildcard_for_single_variants.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::match_wildcard_for_single_variants)] #![allow(dead_code)] diff --git a/tests/ui/mem_replace.fixed b/tests/ui/mem_replace.fixed index 7fd340173af..d37e97b0a06 100644 --- a/tests/ui/mem_replace.fixed +++ b/tests/ui/mem_replace.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused)] #![warn( diff --git a/tests/ui/mem_replace.rs b/tests/ui/mem_replace.rs index fa2903addbc..34e37f3dbbb 100644 --- a/tests/ui/mem_replace.rs +++ b/tests/ui/mem_replace.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused)] #![warn( diff --git a/tests/ui/mem_replace_macro.rs b/tests/ui/mem_replace_macro.rs index 3932e7d00c1..132873858b7 100644 --- a/tests/ui/mem_replace_macro.rs +++ b/tests/ui/mem_replace_macro.rs @@ -1,4 +1,4 @@ -// aux-build:proc_macros.rs +//@aux-build:proc_macros.rs #![warn(clippy::mem_replace_with_default)] extern crate proc_macros; diff --git a/tests/ui/methods.rs b/tests/ui/methods.rs index 1519e4da934..e0e2cac30a2 100644 --- a/tests/ui/methods.rs +++ b/tests/ui/methods.rs @@ -1,4 +1,4 @@ -// aux-build:option_helpers.rs +//@aux-build:option_helpers.rs #![warn(clippy::all, clippy::pedantic)] #![allow( diff --git a/tests/ui/methods_fixable.fixed b/tests/ui/methods_fixable.fixed index ee7c1b0da6d..dcbed5a4d99 100644 --- a/tests/ui/methods_fixable.fixed +++ b/tests/ui/methods_fixable.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::filter_next)] diff --git a/tests/ui/methods_fixable.rs b/tests/ui/methods_fixable.rs index 6d0f1b7bd51..3a976d23527 100644 --- a/tests/ui/methods_fixable.rs +++ b/tests/ui/methods_fixable.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::filter_next)] diff --git a/tests/ui/mismatched_target_os_non_unix.fixed b/tests/ui/mismatched_target_os_non_unix.fixed index f219a570e7f..f58e9a429b6 100644 --- a/tests/ui/mismatched_target_os_non_unix.fixed +++ b/tests/ui/mismatched_target_os_non_unix.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::mismatched_target_os)] #![allow(unused)] diff --git a/tests/ui/mismatched_target_os_non_unix.rs b/tests/ui/mismatched_target_os_non_unix.rs index 8a8ae756a4f..e00224f5ceb 100644 --- a/tests/ui/mismatched_target_os_non_unix.rs +++ b/tests/ui/mismatched_target_os_non_unix.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::mismatched_target_os)] #![allow(unused)] diff --git a/tests/ui/mismatched_target_os_unix.fixed b/tests/ui/mismatched_target_os_unix.fixed index 7d9d406d99d..330587a3c4c 100644 --- a/tests/ui/mismatched_target_os_unix.fixed +++ b/tests/ui/mismatched_target_os_unix.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::mismatched_target_os)] #![allow(unused)] diff --git a/tests/ui/mismatched_target_os_unix.rs b/tests/ui/mismatched_target_os_unix.rs index c1177f1eedc..5a90019a2e4 100644 --- a/tests/ui/mismatched_target_os_unix.rs +++ b/tests/ui/mismatched_target_os_unix.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::mismatched_target_os)] #![allow(unused)] diff --git a/tests/ui/missing_const_for_fn/cant_be_const.rs b/tests/ui/missing_const_for_fn/cant_be_const.rs index e6f88c6e622..5db73a7b8ea 100644 --- a/tests/ui/missing_const_for_fn/cant_be_const.rs +++ b/tests/ui/missing_const_for_fn/cant_be_const.rs @@ -2,8 +2,8 @@ //! compilation error. //! The .stderr output of this test should be empty. Otherwise it's a bug somewhere. -// aux-build:helper.rs -// aux-build:../../auxiliary/proc_macros.rs +//@aux-build:helper.rs +//@aux-build:../../auxiliary/proc_macros.rs #![warn(clippy::missing_const_for_fn)] #![feature(start)] diff --git a/tests/ui/missing_doc.rs b/tests/ui/missing_doc.rs index 5752048949c..bf587e774f7 100644 --- a/tests/ui/missing_doc.rs +++ b/tests/ui/missing_doc.rs @@ -1,5 +1,5 @@ -// needs-asm-support -// aux-build: proc_macros.rs +//@needs-asm-support +//@aux-build: proc_macros.rs #![warn(clippy::missing_docs_in_private_items)] // When denying at the crate level, be sure to not get random warnings from the diff --git a/tests/ui/missing_doc_impl.rs b/tests/ui/missing_doc_impl.rs index e2d49b0907d..520ddbe16b8 100644 --- a/tests/ui/missing_doc_impl.rs +++ b/tests/ui/missing_doc_impl.rs @@ -1,4 +1,4 @@ -// aux-build: proc_macros.rs +//@aux-build: proc_macros.rs #![warn(clippy::missing_docs_in_private_items)] #![allow(dead_code)] diff --git a/tests/ui/missing_spin_loop.fixed b/tests/ui/missing_spin_loop.fixed index aa89e04d26e..a15298dc37b 100644 --- a/tests/ui/missing_spin_loop.fixed +++ b/tests/ui/missing_spin_loop.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::missing_spin_loop)] #![allow(clippy::bool_comparison)] #![allow(unused_braces)] diff --git a/tests/ui/missing_spin_loop.rs b/tests/ui/missing_spin_loop.rs index 88745e47732..be74581ecd0 100644 --- a/tests/ui/missing_spin_loop.rs +++ b/tests/ui/missing_spin_loop.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::missing_spin_loop)] #![allow(clippy::bool_comparison)] #![allow(unused_braces)] diff --git a/tests/ui/missing_spin_loop_no_std.fixed b/tests/ui/missing_spin_loop_no_std.fixed index bb4b4795516..960e5c05fb6 100644 --- a/tests/ui/missing_spin_loop_no_std.fixed +++ b/tests/ui/missing_spin_loop_no_std.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::missing_spin_loop)] #![feature(lang_items, start, libc)] #![no_std] diff --git a/tests/ui/missing_spin_loop_no_std.rs b/tests/ui/missing_spin_loop_no_std.rs index a19bc72baf8..e532ca62dc5 100644 --- a/tests/ui/missing_spin_loop_no_std.rs +++ b/tests/ui/missing_spin_loop_no_std.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::missing_spin_loop)] #![feature(lang_items, start, libc)] #![no_std] diff --git a/tests/ui/mistyped_literal_suffix.fixed b/tests/ui/mistyped_literal_suffix.fixed index 9a47d7c56ed..62cfeafdc49 100644 --- a/tests/ui/mistyped_literal_suffix.fixed +++ b/tests/ui/mistyped_literal_suffix.fixed @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build: proc_macros.rs +//@run-rustfix +//@aux-build: proc_macros.rs #![allow( dead_code, diff --git a/tests/ui/mistyped_literal_suffix.rs b/tests/ui/mistyped_literal_suffix.rs index 04261cba55a..f83b7c3dbda 100644 --- a/tests/ui/mistyped_literal_suffix.rs +++ b/tests/ui/mistyped_literal_suffix.rs @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build: proc_macros.rs +//@run-rustfix +//@aux-build: proc_macros.rs #![allow( dead_code, diff --git a/tests/ui/module_name_repetitions.rs b/tests/ui/module_name_repetitions.rs index ebaa77cc283..fb2c7612343 100644 --- a/tests/ui/module_name_repetitions.rs +++ b/tests/ui/module_name_repetitions.rs @@ -1,4 +1,4 @@ -// compile-flags: --test +//@compile-flags: --test #![warn(clippy::module_name_repetitions)] #![allow(dead_code)] diff --git a/tests/ui/multiple_unsafe_ops_per_block.rs b/tests/ui/multiple_unsafe_ops_per_block.rs index 9082f1675a8..73ef35c8c36 100644 --- a/tests/ui/multiple_unsafe_ops_per_block.rs +++ b/tests/ui/multiple_unsafe_ops_per_block.rs @@ -1,4 +1,4 @@ -// aux-build:proc_macros.rs +//@aux-build:proc_macros.rs #![allow(unused)] #![allow(deref_nullptr)] #![allow(clippy::unnecessary_operation)] diff --git a/tests/ui/must_use_candidates.fixed b/tests/ui/must_use_candidates.fixed index bbbb3cf621e..0c275504d36 100644 --- a/tests/ui/must_use_candidates.fixed +++ b/tests/ui/must_use_candidates.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![feature(never_type)] #![allow(unused_mut, unused_tuple_struct_fields, clippy::redundant_allocation)] #![warn(clippy::must_use_candidate)] diff --git a/tests/ui/must_use_candidates.rs b/tests/ui/must_use_candidates.rs index 94d3c83bdb9..d1c9267732f 100644 --- a/tests/ui/must_use_candidates.rs +++ b/tests/ui/must_use_candidates.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![feature(never_type)] #![allow(unused_mut, unused_tuple_struct_fields, clippy::redundant_allocation)] #![warn(clippy::must_use_candidate)] diff --git a/tests/ui/must_use_unit.fixed b/tests/ui/must_use_unit.fixed index b7d375ff80e..4f7cf4e56d1 100644 --- a/tests/ui/must_use_unit.fixed +++ b/tests/ui/must_use_unit.fixed @@ -1,5 +1,5 @@ -//run-rustfix -// aux-build:proc_macros.rs +//@run-rustfix +//@aux-build:proc_macros.rs #![warn(clippy::must_use_unit)] #![allow(clippy::unused_unit)] diff --git a/tests/ui/must_use_unit.rs b/tests/ui/must_use_unit.rs index 74d6b4ca865..3a814ce1685 100644 --- a/tests/ui/must_use_unit.rs +++ b/tests/ui/must_use_unit.rs @@ -1,5 +1,5 @@ -//run-rustfix -// aux-build:proc_macros.rs +//@run-rustfix +//@aux-build:proc_macros.rs #![warn(clippy::must_use_unit)] #![allow(clippy::unused_unit)] diff --git a/tests/ui/mut_mut.rs b/tests/ui/mut_mut.rs index 06bb085442a..d838098de11 100644 --- a/tests/ui/mut_mut.rs +++ b/tests/ui/mut_mut.rs @@ -1,4 +1,4 @@ -// aux-build:proc_macros.rs +//@aux-build:proc_macros.rs #![warn(clippy::mut_mut)] #![allow(unused)] #![allow(clippy::no_effect, clippy::uninlined_format_args, clippy::unnecessary_operation)] diff --git a/tests/ui/mut_mutex_lock.fixed b/tests/ui/mut_mutex_lock.fixed index ecad10a8290..433817a4e03 100644 --- a/tests/ui/mut_mutex_lock.fixed +++ b/tests/ui/mut_mutex_lock.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(dead_code, unused_mut)] #![warn(clippy::mut_mutex_lock)] diff --git a/tests/ui/mut_mutex_lock.rs b/tests/ui/mut_mutex_lock.rs index f2b1d6fbfbc..567a0b59e70 100644 --- a/tests/ui/mut_mutex_lock.rs +++ b/tests/ui/mut_mutex_lock.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(dead_code, unused_mut)] #![warn(clippy::mut_mutex_lock)] diff --git a/tests/ui/needless_arbitrary_self_type.fixed b/tests/ui/needless_arbitrary_self_type.fixed index 9da21eb6b29..d7eb1a047ed 100644 --- a/tests/ui/needless_arbitrary_self_type.fixed +++ b/tests/ui/needless_arbitrary_self_type.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::needless_arbitrary_self_type)] #![allow(unused_mut, clippy::needless_lifetimes)] diff --git a/tests/ui/needless_arbitrary_self_type.rs b/tests/ui/needless_arbitrary_self_type.rs index 17aeaaf97ac..85a2a957f29 100644 --- a/tests/ui/needless_arbitrary_self_type.rs +++ b/tests/ui/needless_arbitrary_self_type.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::needless_arbitrary_self_type)] #![allow(unused_mut, clippy::needless_lifetimes)] diff --git a/tests/ui/needless_arbitrary_self_type_unfixable.rs b/tests/ui/needless_arbitrary_self_type_unfixable.rs index 02b43cce2bd..00871f9f450 100644 --- a/tests/ui/needless_arbitrary_self_type_unfixable.rs +++ b/tests/ui/needless_arbitrary_self_type_unfixable.rs @@ -1,4 +1,4 @@ -// aux-build:proc_macro_attr.rs +//@aux-build:proc_macro_attr.rs #![warn(clippy::needless_arbitrary_self_type)] diff --git a/tests/ui/needless_bitwise_bool.fixed b/tests/ui/needless_bitwise_bool.fixed index 5e1ea663a10..7543ab72ca2 100644 --- a/tests/ui/needless_bitwise_bool.fixed +++ b/tests/ui/needless_bitwise_bool.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::needless_bitwise_bool)] diff --git a/tests/ui/needless_bitwise_bool.rs b/tests/ui/needless_bitwise_bool.rs index f3075fba0a2..2cea701dce6 100644 --- a/tests/ui/needless_bitwise_bool.rs +++ b/tests/ui/needless_bitwise_bool.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::needless_bitwise_bool)] diff --git a/tests/ui/needless_bool/fixable.fixed b/tests/ui/needless_bool/fixable.fixed index 89dc13fd5b1..f860852e7b7 100644 --- a/tests/ui/needless_bool/fixable.fixed +++ b/tests/ui/needless_bool/fixable.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::needless_bool)] #![allow( diff --git a/tests/ui/needless_bool/fixable.rs b/tests/ui/needless_bool/fixable.rs index c11d9472e8d..6680dab5b6d 100644 --- a/tests/ui/needless_bool/fixable.rs +++ b/tests/ui/needless_bool/fixable.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::needless_bool)] #![allow( diff --git a/tests/ui/needless_borrow.fixed b/tests/ui/needless_borrow.fixed index 4cb7f6b687f..425e6eb6200 100644 --- a/tests/ui/needless_borrow.fixed +++ b/tests/ui/needless_borrow.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![feature(lint_reasons)] #![allow( unused, diff --git a/tests/ui/needless_borrow.rs b/tests/ui/needless_borrow.rs index 9a01190ed8d..3f7fa4a9d7d 100644 --- a/tests/ui/needless_borrow.rs +++ b/tests/ui/needless_borrow.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![feature(lint_reasons)] #![allow( unused, diff --git a/tests/ui/needless_borrowed_ref.fixed b/tests/ui/needless_borrowed_ref.fixed index 0c47ceb7b67..6663520da8a 100644 --- a/tests/ui/needless_borrowed_ref.fixed +++ b/tests/ui/needless_borrowed_ref.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::needless_borrowed_reference)] #![allow( diff --git a/tests/ui/needless_borrowed_ref.rs b/tests/ui/needless_borrowed_ref.rs index f883bb0c889..6c8efd2ce18 100644 --- a/tests/ui/needless_borrowed_ref.rs +++ b/tests/ui/needless_borrowed_ref.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::needless_borrowed_reference)] #![allow( diff --git a/tests/ui/needless_collect.fixed b/tests/ui/needless_collect.fixed index 2659ad38488..024c22de225 100644 --- a/tests/ui/needless_collect.fixed +++ b/tests/ui/needless_collect.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused, clippy::suspicious_map, clippy::iter_count)] diff --git a/tests/ui/needless_collect.rs b/tests/ui/needless_collect.rs index 535ec82982b..7ed7babec30 100644 --- a/tests/ui/needless_collect.rs +++ b/tests/ui/needless_collect.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused, clippy::suspicious_map, clippy::iter_count)] diff --git a/tests/ui/needless_for_each_fixable.fixed b/tests/ui/needless_for_each_fixable.fixed index 09e671b88e1..a04f9ec651e 100644 --- a/tests/ui/needless_for_each_fixable.fixed +++ b/tests/ui/needless_for_each_fixable.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::needless_for_each)] #![allow(unused)] #![allow( diff --git a/tests/ui/needless_for_each_fixable.rs b/tests/ui/needless_for_each_fixable.rs index abb4045b919..4975c705081 100644 --- a/tests/ui/needless_for_each_fixable.rs +++ b/tests/ui/needless_for_each_fixable.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::needless_for_each)] #![allow(unused)] #![allow( diff --git a/tests/ui/needless_late_init.fixed b/tests/ui/needless_late_init.fixed index 86d899bb46c..92f7b3f777a 100644 --- a/tests/ui/needless_late_init.fixed +++ b/tests/ui/needless_late_init.fixed @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build:proc_macros.rs +//@run-rustfix +//@aux-build:proc_macros.rs #![feature(let_chains)] #![allow(unused)] #![allow( diff --git a/tests/ui/needless_late_init.rs b/tests/ui/needless_late_init.rs index 969afb38edf..be378c42f95 100644 --- a/tests/ui/needless_late_init.rs +++ b/tests/ui/needless_late_init.rs @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build:proc_macros.rs +//@run-rustfix +//@aux-build:proc_macros.rs #![feature(let_chains)] #![allow(unused)] #![allow( diff --git a/tests/ui/needless_lifetimes.fixed b/tests/ui/needless_lifetimes.fixed index e6ead69d148..7b99042f744 100644 --- a/tests/ui/needless_lifetimes.fixed +++ b/tests/ui/needless_lifetimes.fixed @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build:proc_macros.rs +//@run-rustfix +//@aux-build:proc_macros.rs #![warn(clippy::needless_lifetimes)] #![allow( diff --git a/tests/ui/needless_lifetimes.rs b/tests/ui/needless_lifetimes.rs index 06eb430506f..6fcf1efc2ee 100644 --- a/tests/ui/needless_lifetimes.rs +++ b/tests/ui/needless_lifetimes.rs @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build:proc_macros.rs +//@run-rustfix +//@aux-build:proc_macros.rs #![warn(clippy::needless_lifetimes)] #![allow( diff --git a/tests/ui/needless_match.fixed b/tests/ui/needless_match.fixed index 7e47406798c..d8a0400a4f0 100644 --- a/tests/ui/needless_match.fixed +++ b/tests/ui/needless_match.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::needless_match)] #![allow(clippy::manual_map)] #![allow(dead_code)] diff --git a/tests/ui/needless_match.rs b/tests/ui/needless_match.rs index 809c694bf40..3de9bd6d7a1 100644 --- a/tests/ui/needless_match.rs +++ b/tests/ui/needless_match.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::needless_match)] #![allow(clippy::manual_map)] #![allow(dead_code)] diff --git a/tests/ui/needless_option_as_deref.fixed b/tests/ui/needless_option_as_deref.fixed index acd22c6bb43..70015fccf9e 100644 --- a/tests/ui/needless_option_as_deref.fixed +++ b/tests/ui/needless_option_as_deref.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused)] #![warn(clippy::needless_option_as_deref)] diff --git a/tests/ui/needless_option_as_deref.rs b/tests/ui/needless_option_as_deref.rs index 61eda5052a2..e2e35360cb3 100644 --- a/tests/ui/needless_option_as_deref.rs +++ b/tests/ui/needless_option_as_deref.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused)] #![warn(clippy::needless_option_as_deref)] diff --git a/tests/ui/needless_option_take.fixed b/tests/ui/needless_option_take.fixed index 29691e81666..bfc6d20d5a3 100644 --- a/tests/ui/needless_option_take.fixed +++ b/tests/ui/needless_option_take.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix fn main() { println!("Testing non erroneous option_take_on_temporary"); diff --git a/tests/ui/needless_option_take.rs b/tests/ui/needless_option_take.rs index 9f4109eb463..697eeab4207 100644 --- a/tests/ui/needless_option_take.rs +++ b/tests/ui/needless_option_take.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix fn main() { println!("Testing non erroneous option_take_on_temporary"); diff --git a/tests/ui/needless_parens_on_range_literals.fixed b/tests/ui/needless_parens_on_range_literals.fixed index f11330a8916..9b98f6ea7f7 100644 --- a/tests/ui/needless_parens_on_range_literals.fixed +++ b/tests/ui/needless_parens_on_range_literals.fixed @@ -1,5 +1,5 @@ -// run-rustfix -// edition:2018 +//@run-rustfix +//@edition:2018 #![warn(clippy::needless_parens_on_range_literals)] #![allow(clippy::almost_complete_range)] diff --git a/tests/ui/needless_parens_on_range_literals.rs b/tests/ui/needless_parens_on_range_literals.rs index 671c0009e23..088e7b2b98f 100644 --- a/tests/ui/needless_parens_on_range_literals.rs +++ b/tests/ui/needless_parens_on_range_literals.rs @@ -1,5 +1,5 @@ -// run-rustfix -// edition:2018 +//@run-rustfix +//@edition:2018 #![warn(clippy::needless_parens_on_range_literals)] #![allow(clippy::almost_complete_range)] diff --git a/tests/ui/needless_question_mark.fixed b/tests/ui/needless_question_mark.fixed index 7eaca571992..679b73d404a 100644 --- a/tests/ui/needless_question_mark.fixed +++ b/tests/ui/needless_question_mark.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::needless_question_mark)] #![allow( diff --git a/tests/ui/needless_question_mark.rs b/tests/ui/needless_question_mark.rs index 960bc7b7898..a993d3ec35d 100644 --- a/tests/ui/needless_question_mark.rs +++ b/tests/ui/needless_question_mark.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::needless_question_mark)] #![allow( diff --git a/tests/ui/needless_return.fixed b/tests/ui/needless_return.fixed index 57c08996ce2..ee4e5007dc5 100644 --- a/tests/ui/needless_return.fixed +++ b/tests/ui/needless_return.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![feature(lint_reasons)] #![feature(yeet_expr)] diff --git a/tests/ui/needless_return.rs b/tests/ui/needless_return.rs index 7c1feefbe32..cd999db4f40 100644 --- a/tests/ui/needless_return.rs +++ b/tests/ui/needless_return.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![feature(lint_reasons)] #![feature(yeet_expr)] diff --git a/tests/ui/needless_splitn.fixed b/tests/ui/needless_splitn.fixed index 5496031fefa..30a038312c8 100644 --- a/tests/ui/needless_splitn.fixed +++ b/tests/ui/needless_splitn.fixed @@ -1,5 +1,5 @@ -// run-rustfix -// edition:2018 +//@run-rustfix +//@edition:2018 #![warn(clippy::needless_splitn)] #![allow(clippy::iter_skip_next, clippy::iter_nth_zero, clippy::manual_split_once)] diff --git a/tests/ui/needless_splitn.rs b/tests/ui/needless_splitn.rs index 35c2465bae1..1b0b9a5981a 100644 --- a/tests/ui/needless_splitn.rs +++ b/tests/ui/needless_splitn.rs @@ -1,5 +1,5 @@ -// run-rustfix -// edition:2018 +//@run-rustfix +//@edition:2018 #![warn(clippy::needless_splitn)] #![allow(clippy::iter_skip_next, clippy::iter_nth_zero, clippy::manual_split_once)] diff --git a/tests/ui/neg_multiply.fixed b/tests/ui/neg_multiply.fixed index 58ab9e85678..e07e7c88d68 100644 --- a/tests/ui/neg_multiply.fixed +++ b/tests/ui/neg_multiply.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::neg_multiply)] #![allow(clippy::no_effect, clippy::unnecessary_operation, clippy::precedence)] #![allow(unused)] diff --git a/tests/ui/neg_multiply.rs b/tests/ui/neg_multiply.rs index 581290dc72e..2887af7b421 100644 --- a/tests/ui/neg_multiply.rs +++ b/tests/ui/neg_multiply.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::neg_multiply)] #![allow(clippy::no_effect, clippy::unnecessary_operation, clippy::precedence)] #![allow(unused)] diff --git a/tests/ui/non_octal_unix_permissions.fixed b/tests/ui/non_octal_unix_permissions.fixed index a9b2dcfb085..89d12752834 100644 --- a/tests/ui/non_octal_unix_permissions.fixed +++ b/tests/ui/non_octal_unix_permissions.fixed @@ -1,5 +1,5 @@ -// ignore-windows -// run-rustfix +//@ignore-windows +//@run-rustfix #![warn(clippy::non_octal_unix_permissions)] use std::fs::{DirBuilder, File, OpenOptions, Permissions}; use std::os::unix::fs::{DirBuilderExt, OpenOptionsExt, PermissionsExt}; diff --git a/tests/ui/non_octal_unix_permissions.rs b/tests/ui/non_octal_unix_permissions.rs index 7d2922f494e..1b3a322d726 100644 --- a/tests/ui/non_octal_unix_permissions.rs +++ b/tests/ui/non_octal_unix_permissions.rs @@ -1,5 +1,5 @@ -// ignore-windows -// run-rustfix +//@ignore-windows +//@run-rustfix #![warn(clippy::non_octal_unix_permissions)] use std::fs::{DirBuilder, File, OpenOptions, Permissions}; use std::os::unix::fs::{DirBuilderExt, OpenOptionsExt, PermissionsExt}; diff --git a/tests/ui/nonminimal_bool_methods.fixed b/tests/ui/nonminimal_bool_methods.fixed index aad44089de4..05802a2c865 100644 --- a/tests/ui/nonminimal_bool_methods.fixed +++ b/tests/ui/nonminimal_bool_methods.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused, clippy::diverging_sub_expression)] #![warn(clippy::nonminimal_bool)] diff --git a/tests/ui/nonminimal_bool_methods.rs b/tests/ui/nonminimal_bool_methods.rs index b9074da8427..cd5b576fa07 100644 --- a/tests/ui/nonminimal_bool_methods.rs +++ b/tests/ui/nonminimal_bool_methods.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused, clippy::diverging_sub_expression)] #![warn(clippy::nonminimal_bool)] diff --git a/tests/ui/numbered_fields.fixed b/tests/ui/numbered_fields.fixed index 68c987eb4c6..a52845e53a4 100644 --- a/tests/ui/numbered_fields.fixed +++ b/tests/ui/numbered_fields.fixed @@ -1,4 +1,4 @@ -//run-rustfix +//@run-rustfix #![warn(clippy::init_numbered_fields)] #![allow(unused_tuple_struct_fields)] diff --git a/tests/ui/numbered_fields.rs b/tests/ui/numbered_fields.rs index 2ef4fb4de53..ca93f7dce59 100644 --- a/tests/ui/numbered_fields.rs +++ b/tests/ui/numbered_fields.rs @@ -1,4 +1,4 @@ -//run-rustfix +//@run-rustfix #![warn(clippy::init_numbered_fields)] #![allow(unused_tuple_struct_fields)] diff --git a/tests/ui/obfuscated_if_else.fixed b/tests/ui/obfuscated_if_else.fixed index 62d932c2c6b..9e4f97253f8 100644 --- a/tests/ui/obfuscated_if_else.fixed +++ b/tests/ui/obfuscated_if_else.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::obfuscated_if_else)] diff --git a/tests/ui/obfuscated_if_else.rs b/tests/ui/obfuscated_if_else.rs index 273be9092a7..c2351d64c1c 100644 --- a/tests/ui/obfuscated_if_else.rs +++ b/tests/ui/obfuscated_if_else.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::obfuscated_if_else)] diff --git a/tests/ui/option_as_ref_deref.fixed b/tests/ui/option_as_ref_deref.fixed index d124d133faa..e1c0fa3f7fd 100644 --- a/tests/ui/option_as_ref_deref.fixed +++ b/tests/ui/option_as_ref_deref.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused, clippy::redundant_clone)] #![warn(clippy::option_as_ref_deref)] diff --git a/tests/ui/option_as_ref_deref.rs b/tests/ui/option_as_ref_deref.rs index 86e354c6716..6f4917fd149 100644 --- a/tests/ui/option_as_ref_deref.rs +++ b/tests/ui/option_as_ref_deref.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused, clippy::redundant_clone)] #![warn(clippy::option_as_ref_deref)] diff --git a/tests/ui/option_env_unwrap.rs b/tests/ui/option_env_unwrap.rs index 9a56cf40d8a..ee1fe3f1fc0 100644 --- a/tests/ui/option_env_unwrap.rs +++ b/tests/ui/option_env_unwrap.rs @@ -1,4 +1,4 @@ -// aux-build:proc_macros.rs +//@aux-build:proc_macros.rs #![warn(clippy::option_env_unwrap)] #![allow(clippy::map_flatten)] diff --git a/tests/ui/option_filter_map.fixed b/tests/ui/option_filter_map.fixed index b20f73f3110..93c250cfa73 100644 --- a/tests/ui/option_filter_map.fixed +++ b/tests/ui/option_filter_map.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::option_filter_map)] #![allow(clippy::map_flatten)] diff --git a/tests/ui/option_filter_map.rs b/tests/ui/option_filter_map.rs index 7abaaa0fb83..2c5f03250b9 100644 --- a/tests/ui/option_filter_map.rs +++ b/tests/ui/option_filter_map.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::option_filter_map)] #![allow(clippy::map_flatten)] diff --git a/tests/ui/option_if_let_else.fixed b/tests/ui/option_if_let_else.fixed index 0456005dce4..f7d2cf2c7d8 100644 --- a/tests/ui/option_if_let_else.fixed +++ b/tests/ui/option_if_let_else.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::option_if_let_else)] #![allow( unused_tuple_struct_fields, diff --git a/tests/ui/option_if_let_else.rs b/tests/ui/option_if_let_else.rs index 23b148752cb..1534572f6a2 100644 --- a/tests/ui/option_if_let_else.rs +++ b/tests/ui/option_if_let_else.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::option_if_let_else)] #![allow( unused_tuple_struct_fields, diff --git a/tests/ui/option_map_or_none.fixed b/tests/ui/option_map_or_none.fixed index 04bfac7735f..501757647bf 100644 --- a/tests/ui/option_map_or_none.fixed +++ b/tests/ui/option_map_or_none.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(clippy::bind_instead_of_map)] diff --git a/tests/ui/option_map_or_none.rs b/tests/ui/option_map_or_none.rs index bb84f8a48f4..4d8704e737d 100644 --- a/tests/ui/option_map_or_none.rs +++ b/tests/ui/option_map_or_none.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(clippy::bind_instead_of_map)] diff --git a/tests/ui/option_map_unit_fn_fixable.fixed b/tests/ui/option_map_unit_fn_fixable.fixed index 00264dcceaa..8f64451edf3 100644 --- a/tests/ui/option_map_unit_fn_fixable.fixed +++ b/tests/ui/option_map_unit_fn_fixable.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::option_map_unit_fn)] #![allow(unused)] #![allow(clippy::uninlined_format_args, clippy::unnecessary_wraps)] diff --git a/tests/ui/option_map_unit_fn_fixable.rs b/tests/ui/option_map_unit_fn_fixable.rs index f3363ebce54..2bf7a8e0f7d 100644 --- a/tests/ui/option_map_unit_fn_fixable.rs +++ b/tests/ui/option_map_unit_fn_fixable.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::option_map_unit_fn)] #![allow(unused)] #![allow(clippy::uninlined_format_args, clippy::unnecessary_wraps)] diff --git a/tests/ui/or_fun_call.fixed b/tests/ui/or_fun_call.fixed index be9a65506e1..f723a55f77f 100644 --- a/tests/ui/or_fun_call.fixed +++ b/tests/ui/or_fun_call.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::or_fun_call)] #![allow(dead_code)] #![allow(clippy::borrow_as_ptr, clippy::uninlined_format_args, clippy::unnecessary_wraps)] diff --git a/tests/ui/or_fun_call.rs b/tests/ui/or_fun_call.rs index 628c9704638..61ef6e27f32 100644 --- a/tests/ui/or_fun_call.rs +++ b/tests/ui/or_fun_call.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::or_fun_call)] #![allow(dead_code)] #![allow(clippy::borrow_as_ptr, clippy::uninlined_format_args, clippy::unnecessary_wraps)] diff --git a/tests/ui/or_then_unwrap.fixed b/tests/ui/or_then_unwrap.fixed index 844cc4b7a09..40badac4424 100644 --- a/tests/ui/or_then_unwrap.fixed +++ b/tests/ui/or_then_unwrap.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::or_then_unwrap)] #![allow(clippy::map_identity, clippy::let_unit_value)] diff --git a/tests/ui/or_then_unwrap.rs b/tests/ui/or_then_unwrap.rs index 1528ef9be96..76c9942fe6c 100644 --- a/tests/ui/or_then_unwrap.rs +++ b/tests/ui/or_then_unwrap.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::or_then_unwrap)] #![allow(clippy::map_identity, clippy::let_unit_value)] diff --git a/tests/ui/partialeq_to_none.fixed b/tests/ui/partialeq_to_none.fixed index 4644ea8f51d..81a716bd276 100644 --- a/tests/ui/partialeq_to_none.fixed +++ b/tests/ui/partialeq_to_none.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::partialeq_to_none)] struct Foobar; diff --git a/tests/ui/partialeq_to_none.rs b/tests/ui/partialeq_to_none.rs index 61011b3a8c5..f454715fa30 100644 --- a/tests/ui/partialeq_to_none.rs +++ b/tests/ui/partialeq_to_none.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::partialeq_to_none)] struct Foobar; diff --git a/tests/ui/path_buf_push_overwrite.fixed b/tests/ui/path_buf_push_overwrite.fixed index ef8856830fc..393fc6e1c69 100644 --- a/tests/ui/path_buf_push_overwrite.fixed +++ b/tests/ui/path_buf_push_overwrite.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix use std::path::PathBuf; #[warn(clippy::all, clippy::path_buf_push_overwrite)] diff --git a/tests/ui/path_buf_push_overwrite.rs b/tests/ui/path_buf_push_overwrite.rs index 6e2d483f454..18de6e06412 100644 --- a/tests/ui/path_buf_push_overwrite.rs +++ b/tests/ui/path_buf_push_overwrite.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix use std::path::PathBuf; #[warn(clippy::all, clippy::path_buf_push_overwrite)] diff --git a/tests/ui/patterns.fixed b/tests/ui/patterns.fixed index cd69014326e..a1da47d84fd 100644 --- a/tests/ui/patterns.fixed +++ b/tests/ui/patterns.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::all)] #![allow(unused)] #![allow(clippy::uninlined_format_args)] diff --git a/tests/ui/patterns.rs b/tests/ui/patterns.rs index 9128da420c0..399066b813e 100644 --- a/tests/ui/patterns.rs +++ b/tests/ui/patterns.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::all)] #![allow(unused)] #![allow(clippy::uninlined_format_args)] diff --git a/tests/ui/precedence.fixed b/tests/ui/precedence.fixed index 163bd044c17..af4d5636b61 100644 --- a/tests/ui/precedence.fixed +++ b/tests/ui/precedence.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::precedence)] #![allow(unused_must_use, clippy::no_effect, clippy::unnecessary_operation)] #![allow(clippy::identity_op)] diff --git a/tests/ui/precedence.rs b/tests/ui/precedence.rs index 8c849e3209b..e23ae912786 100644 --- a/tests/ui/precedence.rs +++ b/tests/ui/precedence.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::precedence)] #![allow(unused_must_use, clippy::no_effect, clippy::unnecessary_operation)] #![allow(clippy::identity_op)] diff --git a/tests/ui/print_stdout_build_script.rs b/tests/ui/print_stdout_build_script.rs index 997ebef8a69..91448cb0faf 100644 --- a/tests/ui/print_stdout_build_script.rs +++ b/tests/ui/print_stdout_build_script.rs @@ -1,4 +1,4 @@ -// compile-flags: --crate-name=build_script_build +//@compile-flags: --crate-name=build_script_build #![warn(clippy::print_stdout)] diff --git a/tests/ui/print_with_newline.rs b/tests/ui/print_with_newline.rs index b8c29d207ad..ff79ca75ffa 100644 --- a/tests/ui/print_with_newline.rs +++ b/tests/ui/print_with_newline.rs @@ -1,5 +1,5 @@ // FIXME: Ideally these suggestions would be fixed via rustfix. Blocked by rust-lang/rust#53934 -// // run-rustfix +// #![allow(clippy::print_literal)] #![warn(clippy::print_with_newline)] diff --git a/tests/ui/println_empty_string.fixed b/tests/ui/println_empty_string.fixed index 9760680927a..abf951ae22d 100644 --- a/tests/ui/println_empty_string.fixed +++ b/tests/ui/println_empty_string.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(clippy::match_single_binding)] fn main() { diff --git a/tests/ui/println_empty_string.rs b/tests/ui/println_empty_string.rs index 80fdb3e6e21..fd86e2543cc 100644 --- a/tests/ui/println_empty_string.rs +++ b/tests/ui/println_empty_string.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(clippy::match_single_binding)] fn main() { diff --git a/tests/ui/ptr_as_ptr.fixed b/tests/ui/ptr_as_ptr.fixed index ee7b998a0b2..2c2567d67cd 100644 --- a/tests/ui/ptr_as_ptr.fixed +++ b/tests/ui/ptr_as_ptr.fixed @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build:proc_macros.rs +//@run-rustfix +//@aux-build:proc_macros.rs #![warn(clippy::ptr_as_ptr)] diff --git a/tests/ui/ptr_as_ptr.rs b/tests/ui/ptr_as_ptr.rs index c88329ce4ec..6000e5c08ac 100644 --- a/tests/ui/ptr_as_ptr.rs +++ b/tests/ui/ptr_as_ptr.rs @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build:proc_macros.rs +//@run-rustfix +//@aux-build:proc_macros.rs #![warn(clippy::ptr_as_ptr)] diff --git a/tests/ui/ptr_eq.fixed b/tests/ui/ptr_eq.fixed index 209081e6e80..d5fa273d41f 100644 --- a/tests/ui/ptr_eq.fixed +++ b/tests/ui/ptr_eq.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::ptr_eq)] macro_rules! mac { diff --git a/tests/ui/ptr_eq.rs b/tests/ui/ptr_eq.rs index 69162870807..e033366a4aa 100644 --- a/tests/ui/ptr_eq.rs +++ b/tests/ui/ptr_eq.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::ptr_eq)] macro_rules! mac { diff --git a/tests/ui/ptr_offset_with_cast.fixed b/tests/ui/ptr_offset_with_cast.fixed index c57e2990fb9..f69bc131898 100644 --- a/tests/ui/ptr_offset_with_cast.fixed +++ b/tests/ui/ptr_offset_with_cast.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(clippy::unnecessary_cast)] fn main() { diff --git a/tests/ui/ptr_offset_with_cast.rs b/tests/ui/ptr_offset_with_cast.rs index 3de7997acdd..eae36c27729 100644 --- a/tests/ui/ptr_offset_with_cast.rs +++ b/tests/ui/ptr_offset_with_cast.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(clippy::unnecessary_cast)] fn main() { diff --git a/tests/ui/question_mark.fixed b/tests/ui/question_mark.fixed index 5c49d46da72..7f1660f31fa 100644 --- a/tests/ui/question_mark.fixed +++ b/tests/ui/question_mark.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unreachable_code)] #![allow(dead_code)] #![allow(clippy::unnecessary_wraps)] diff --git a/tests/ui/question_mark.rs b/tests/ui/question_mark.rs index d057df6a9b3..a90eae50ed4 100644 --- a/tests/ui/question_mark.rs +++ b/tests/ui/question_mark.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unreachable_code)] #![allow(dead_code)] #![allow(clippy::unnecessary_wraps)] diff --git a/tests/ui/range_contains.fixed b/tests/ui/range_contains.fixed index 4923731fe45..0a92ee7c8dd 100644 --- a/tests/ui/range_contains.fixed +++ b/tests/ui/range_contains.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::manual_range_contains)] #![allow(unused)] diff --git a/tests/ui/range_contains.rs b/tests/ui/range_contains.rs index d623ccb5da6..7a83be60957 100644 --- a/tests/ui/range_contains.rs +++ b/tests/ui/range_contains.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::manual_range_contains)] #![allow(unused)] diff --git a/tests/ui/range_plus_minus_one.fixed b/tests/ui/range_plus_minus_one.fixed index a16a3e54d45..79c133cb5e3 100644 --- a/tests/ui/range_plus_minus_one.fixed +++ b/tests/ui/range_plus_minus_one.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused_parens)] #![allow(clippy::iter_with_drain)] diff --git a/tests/ui/range_plus_minus_one.rs b/tests/ui/range_plus_minus_one.rs index bd6cb4d21be..689a6b7a17c 100644 --- a/tests/ui/range_plus_minus_one.rs +++ b/tests/ui/range_plus_minus_one.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused_parens)] #![allow(clippy::iter_with_drain)] diff --git a/tests/ui/rc_buffer.fixed b/tests/ui/rc_buffer.fixed index 8910c01b1fc..4cba292c1b7 100644 --- a/tests/ui/rc_buffer.fixed +++ b/tests/ui/rc_buffer.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::rc_buffer)] #![allow(dead_code, unused_imports)] diff --git a/tests/ui/rc_buffer.rs b/tests/ui/rc_buffer.rs index 1e63a43262e..d8a9aa2786d 100644 --- a/tests/ui/rc_buffer.rs +++ b/tests/ui/rc_buffer.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::rc_buffer)] #![allow(dead_code, unused_imports)] diff --git a/tests/ui/rc_buffer_arc.fixed b/tests/ui/rc_buffer_arc.fixed index 13dd6f5fcd1..ac51ac9e467 100644 --- a/tests/ui/rc_buffer_arc.fixed +++ b/tests/ui/rc_buffer_arc.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::rc_buffer)] #![allow(dead_code, unused_imports)] diff --git a/tests/ui/rc_buffer_arc.rs b/tests/ui/rc_buffer_arc.rs index 1a521bfeb7c..21dc27bc5fa 100644 --- a/tests/ui/rc_buffer_arc.rs +++ b/tests/ui/rc_buffer_arc.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::rc_buffer)] #![allow(dead_code, unused_imports)] diff --git a/tests/ui/redundant_allocation_fixable.fixed b/tests/ui/redundant_allocation_fixable.fixed index 6db02718c70..edb7715f42c 100644 --- a/tests/ui/redundant_allocation_fixable.fixed +++ b/tests/ui/redundant_allocation_fixable.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::all)] #![allow(clippy::boxed_local, clippy::needless_pass_by_value)] #![allow(clippy::disallowed_names, unused_variables, dead_code)] diff --git a/tests/ui/redundant_allocation_fixable.rs b/tests/ui/redundant_allocation_fixable.rs index c15806f30c0..c59422dd966 100644 --- a/tests/ui/redundant_allocation_fixable.rs +++ b/tests/ui/redundant_allocation_fixable.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::all)] #![allow(clippy::boxed_local, clippy::needless_pass_by_value)] #![allow(clippy::disallowed_names, unused_variables, dead_code)] diff --git a/tests/ui/redundant_async_block.fixed b/tests/ui/redundant_async_block.fixed index ad96993c4a7..328958491ee 100644 --- a/tests/ui/redundant_async_block.fixed +++ b/tests/ui/redundant_async_block.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused, clippy::manual_async_fn)] #![warn(clippy::redundant_async_block)] diff --git a/tests/ui/redundant_async_block.rs b/tests/ui/redundant_async_block.rs index 7ae23558369..cd189b31555 100644 --- a/tests/ui/redundant_async_block.rs +++ b/tests/ui/redundant_async_block.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused, clippy::manual_async_fn)] #![warn(clippy::redundant_async_block)] diff --git a/tests/ui/redundant_clone.fixed b/tests/ui/redundant_clone.fixed index 00b42745093..8bebb5183bc 100644 --- a/tests/ui/redundant_clone.fixed +++ b/tests/ui/redundant_clone.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix // rustfix-only-machine-applicable #![feature(lint_reasons)] #![allow(clippy::drop_non_drop, clippy::implicit_clone, clippy::uninlined_format_args)] diff --git a/tests/ui/redundant_clone.rs b/tests/ui/redundant_clone.rs index f899127db8d..b4bd5d16b1a 100644 --- a/tests/ui/redundant_clone.rs +++ b/tests/ui/redundant_clone.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix // rustfix-only-machine-applicable #![feature(lint_reasons)] #![allow(clippy::drop_non_drop, clippy::implicit_clone, clippy::uninlined_format_args)] diff --git a/tests/ui/redundant_closure_call_fixable.fixed b/tests/ui/redundant_closure_call_fixable.fixed index b987fd2ce6f..61aed2733fe 100644 --- a/tests/ui/redundant_closure_call_fixable.fixed +++ b/tests/ui/redundant_closure_call_fixable.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![feature(async_closure)] #![warn(clippy::redundant_closure_call)] diff --git a/tests/ui/redundant_closure_call_fixable.rs b/tests/ui/redundant_closure_call_fixable.rs index 633a2979d5d..56b28663539 100644 --- a/tests/ui/redundant_closure_call_fixable.rs +++ b/tests/ui/redundant_closure_call_fixable.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![feature(async_closure)] #![warn(clippy::redundant_closure_call)] diff --git a/tests/ui/redundant_field_names.fixed b/tests/ui/redundant_field_names.fixed index 276266a2dd8..d2a65399da6 100644 --- a/tests/ui/redundant_field_names.fixed +++ b/tests/ui/redundant_field_names.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::redundant_field_names)] #![allow(clippy::extra_unused_type_parameters, clippy::no_effect, dead_code, unused_variables)] diff --git a/tests/ui/redundant_field_names.rs b/tests/ui/redundant_field_names.rs index f674141c138..605ffd21e2f 100644 --- a/tests/ui/redundant_field_names.rs +++ b/tests/ui/redundant_field_names.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::redundant_field_names)] #![allow(clippy::extra_unused_type_parameters, clippy::no_effect, dead_code, unused_variables)] diff --git a/tests/ui/redundant_pattern_matching_drop_order.fixed b/tests/ui/redundant_pattern_matching_drop_order.fixed index ce3229f1759..bebdf89716f 100644 --- a/tests/ui/redundant_pattern_matching_drop_order.fixed +++ b/tests/ui/redundant_pattern_matching_drop_order.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix // Issue #5746 #![warn(clippy::redundant_pattern_matching)] diff --git a/tests/ui/redundant_pattern_matching_drop_order.rs b/tests/ui/redundant_pattern_matching_drop_order.rs index 29b8543cf47..8fb6ed5f7ec 100644 --- a/tests/ui/redundant_pattern_matching_drop_order.rs +++ b/tests/ui/redundant_pattern_matching_drop_order.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix // Issue #5746 #![warn(clippy::redundant_pattern_matching)] diff --git a/tests/ui/redundant_pattern_matching_ipaddr.fixed b/tests/ui/redundant_pattern_matching_ipaddr.fixed index 21bae909555..a9faf12cd5a 100644 --- a/tests/ui/redundant_pattern_matching_ipaddr.fixed +++ b/tests/ui/redundant_pattern_matching_ipaddr.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::all, clippy::redundant_pattern_matching)] #![allow(unused_must_use)] #![allow( diff --git a/tests/ui/redundant_pattern_matching_ipaddr.rs b/tests/ui/redundant_pattern_matching_ipaddr.rs index 4dd9171677e..574671d03d1 100644 --- a/tests/ui/redundant_pattern_matching_ipaddr.rs +++ b/tests/ui/redundant_pattern_matching_ipaddr.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::all, clippy::redundant_pattern_matching)] #![allow(unused_must_use)] #![allow( diff --git a/tests/ui/redundant_pattern_matching_option.fixed b/tests/ui/redundant_pattern_matching_option.fixed index a89845c1dd3..87100b97288 100644 --- a/tests/ui/redundant_pattern_matching_option.fixed +++ b/tests/ui/redundant_pattern_matching_option.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::all)] #![warn(clippy::redundant_pattern_matching)] diff --git a/tests/ui/redundant_pattern_matching_option.rs b/tests/ui/redundant_pattern_matching_option.rs index d6f44403487..0b69e13f655 100644 --- a/tests/ui/redundant_pattern_matching_option.rs +++ b/tests/ui/redundant_pattern_matching_option.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::all)] #![warn(clippy::redundant_pattern_matching)] diff --git a/tests/ui/redundant_pattern_matching_poll.fixed b/tests/ui/redundant_pattern_matching_poll.fixed index 3645f2c4bfd..bf3e692202c 100644 --- a/tests/ui/redundant_pattern_matching_poll.fixed +++ b/tests/ui/redundant_pattern_matching_poll.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::all)] #![warn(clippy::redundant_pattern_matching)] diff --git a/tests/ui/redundant_pattern_matching_poll.rs b/tests/ui/redundant_pattern_matching_poll.rs index 866c71b7cfa..892a21d9d29 100644 --- a/tests/ui/redundant_pattern_matching_poll.rs +++ b/tests/ui/redundant_pattern_matching_poll.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::all)] #![warn(clippy::redundant_pattern_matching)] diff --git a/tests/ui/redundant_pattern_matching_result.fixed b/tests/ui/redundant_pattern_matching_result.fixed index 42348df4480..c48d1522935 100644 --- a/tests/ui/redundant_pattern_matching_result.fixed +++ b/tests/ui/redundant_pattern_matching_result.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::all)] #![warn(clippy::redundant_pattern_matching)] #![allow(deprecated, unused_must_use)] diff --git a/tests/ui/redundant_pattern_matching_result.rs b/tests/ui/redundant_pattern_matching_result.rs index 5949cb2271c..26f37d169fa 100644 --- a/tests/ui/redundant_pattern_matching_result.rs +++ b/tests/ui/redundant_pattern_matching_result.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::all)] #![warn(clippy::redundant_pattern_matching)] #![allow(deprecated, unused_must_use)] diff --git a/tests/ui/redundant_pub_crate.fixed b/tests/ui/redundant_pub_crate.fixed index 106947de68c..f65c0fdd35d 100644 --- a/tests/ui/redundant_pub_crate.fixed +++ b/tests/ui/redundant_pub_crate.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(dead_code)] #![warn(clippy::redundant_pub_crate)] diff --git a/tests/ui/redundant_pub_crate.rs b/tests/ui/redundant_pub_crate.rs index f96cfd31843..fb07fed98be 100644 --- a/tests/ui/redundant_pub_crate.rs +++ b/tests/ui/redundant_pub_crate.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(dead_code)] #![warn(clippy::redundant_pub_crate)] diff --git a/tests/ui/redundant_slicing.fixed b/tests/ui/redundant_slicing.fixed index 8dd8d309237..56ddca71903 100644 --- a/tests/ui/redundant_slicing.fixed +++ b/tests/ui/redundant_slicing.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused, clippy::deref_by_slicing)] #![warn(clippy::redundant_slicing)] diff --git a/tests/ui/redundant_slicing.rs b/tests/ui/redundant_slicing.rs index 51c16dd8d65..d67b6665e26 100644 --- a/tests/ui/redundant_slicing.rs +++ b/tests/ui/redundant_slicing.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused, clippy::deref_by_slicing)] #![warn(clippy::redundant_slicing)] diff --git a/tests/ui/redundant_static_lifetimes.fixed b/tests/ui/redundant_static_lifetimes.fixed index bca777a890c..2651735d103 100644 --- a/tests/ui/redundant_static_lifetimes.fixed +++ b/tests/ui/redundant_static_lifetimes.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused)] diff --git a/tests/ui/redundant_static_lifetimes.rs b/tests/ui/redundant_static_lifetimes.rs index afe7644816d..7286652899d 100644 --- a/tests/ui/redundant_static_lifetimes.rs +++ b/tests/ui/redundant_static_lifetimes.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused)] diff --git a/tests/ui/rename.fixed b/tests/ui/rename.fixed index 5076f61334d..e8a00a9e7f7 100644 --- a/tests/ui/rename.fixed +++ b/tests/ui/rename.fixed @@ -2,7 +2,7 @@ // Use that command to update this file and do not edit by hand. // Manual edits will be overwritten. -// run-rustfix +//@run-rustfix #![allow(clippy::almost_complete_range)] #![allow(clippy::disallowed_names)] diff --git a/tests/ui/rename.rs b/tests/ui/rename.rs index 64bc1ca7116..c8ea70c2bcb 100644 --- a/tests/ui/rename.rs +++ b/tests/ui/rename.rs @@ -2,7 +2,7 @@ // Use that command to update this file and do not edit by hand. // Manual edits will be overwritten. -// run-rustfix +//@run-rustfix #![allow(clippy::almost_complete_range)] #![allow(clippy::disallowed_names)] diff --git a/tests/ui/renamed_builtin_attr.fixed b/tests/ui/renamed_builtin_attr.fixed index cb91b841d2c..0334c1e1a29 100644 --- a/tests/ui/renamed_builtin_attr.fixed +++ b/tests/ui/renamed_builtin_attr.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #[clippy::cognitive_complexity = "1"] fn main() {} diff --git a/tests/ui/renamed_builtin_attr.rs b/tests/ui/renamed_builtin_attr.rs index b3ce2758067..d350370c244 100644 --- a/tests/ui/renamed_builtin_attr.rs +++ b/tests/ui/renamed_builtin_attr.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #[clippy::cyclomatic_complexity = "1"] fn main() {} diff --git a/tests/ui/repeat_once.fixed b/tests/ui/repeat_once.fixed index dc197e50300..c517bfcc6aa 100644 --- a/tests/ui/repeat_once.fixed +++ b/tests/ui/repeat_once.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::repeat_once)] #[allow(unused, clippy::redundant_clone)] fn main() { diff --git a/tests/ui/repeat_once.rs b/tests/ui/repeat_once.rs index 0ec5127117c..9a30b47418f 100644 --- a/tests/ui/repeat_once.rs +++ b/tests/ui/repeat_once.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::repeat_once)] #[allow(unused, clippy::redundant_clone)] fn main() { diff --git a/tests/ui/result_map_or_into_option.fixed b/tests/ui/result_map_or_into_option.fixed index 331531b5165..119ff25918a 100644 --- a/tests/ui/result_map_or_into_option.fixed +++ b/tests/ui/result_map_or_into_option.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::result_map_or_into_option)] diff --git a/tests/ui/result_map_or_into_option.rs b/tests/ui/result_map_or_into_option.rs index 3058480e2ad..eeeef830af0 100644 --- a/tests/ui/result_map_or_into_option.rs +++ b/tests/ui/result_map_or_into_option.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::result_map_or_into_option)] diff --git a/tests/ui/result_map_unit_fn_fixable.fixed b/tests/ui/result_map_unit_fn_fixable.fixed index d8b56237e98..0583d29277b 100644 --- a/tests/ui/result_map_unit_fn_fixable.fixed +++ b/tests/ui/result_map_unit_fn_fixable.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::result_map_unit_fn)] #![allow(unused)] #![allow(clippy::uninlined_format_args)] diff --git a/tests/ui/result_map_unit_fn_fixable.rs b/tests/ui/result_map_unit_fn_fixable.rs index 44f50d21109..7ad3bdd04bd 100644 --- a/tests/ui/result_map_unit_fn_fixable.rs +++ b/tests/ui/result_map_unit_fn_fixable.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::result_map_unit_fn)] #![allow(unused)] #![allow(clippy::uninlined_format_args)] diff --git a/tests/ui/reversed_empty_ranges_fixable.fixed b/tests/ui/reversed_empty_ranges_fixable.fixed index c67edb36c67..30dfc977681 100644 --- a/tests/ui/reversed_empty_ranges_fixable.fixed +++ b/tests/ui/reversed_empty_ranges_fixable.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::reversed_empty_ranges)] #![allow(clippy::uninlined_format_args)] diff --git a/tests/ui/reversed_empty_ranges_fixable.rs b/tests/ui/reversed_empty_ranges_fixable.rs index 0a4fef5bfe8..1837249eae1 100644 --- a/tests/ui/reversed_empty_ranges_fixable.rs +++ b/tests/ui/reversed_empty_ranges_fixable.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::reversed_empty_ranges)] #![allow(clippy::uninlined_format_args)] diff --git a/tests/ui/reversed_empty_ranges_loops_fixable.fixed b/tests/ui/reversed_empty_ranges_loops_fixable.fixed index 78401e463d5..a74569599c7 100644 --- a/tests/ui/reversed_empty_ranges_loops_fixable.fixed +++ b/tests/ui/reversed_empty_ranges_loops_fixable.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::reversed_empty_ranges)] #![allow(clippy::uninlined_format_args)] diff --git a/tests/ui/reversed_empty_ranges_loops_fixable.rs b/tests/ui/reversed_empty_ranges_loops_fixable.rs index f9e0f7fcd6d..42f9957dfbd 100644 --- a/tests/ui/reversed_empty_ranges_loops_fixable.rs +++ b/tests/ui/reversed_empty_ranges_loops_fixable.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::reversed_empty_ranges)] #![allow(clippy::uninlined_format_args)] diff --git a/tests/ui/same_functions_in_if_condition.rs b/tests/ui/same_functions_in_if_condition.rs index e6198a1bc9a..aea1507cc5b 100644 --- a/tests/ui/same_functions_in_if_condition.rs +++ b/tests/ui/same_functions_in_if_condition.rs @@ -1,5 +1,5 @@ #![feature(adt_const_params)] -#![warn(clippy::same_functions_in_if_condition)] +#![deny(clippy::same_functions_in_if_condition)] // ifs_same_cond warning is different from `ifs_same_cond`. // clippy::if_same_then_else, clippy::comparison_chain -- all empty blocks #![allow(incomplete_features)] diff --git a/tests/ui/same_functions_in_if_condition.stderr b/tests/ui/same_functions_in_if_condition.stderr index f352ade150e..aade3b1fa45 100644 --- a/tests/ui/same_functions_in_if_condition.stderr +++ b/tests/ui/same_functions_in_if_condition.stderr @@ -9,7 +9,11 @@ note: same as this | LL | if function() { | ^^^^^^^^^^ - = note: `-D clippy::same-functions-in-if-condition` implied by `-D warnings` +note: the lint level is defined here + --> $DIR/same_functions_in_if_condition.rs:2:9 + | +LL | #![deny(clippy::same_functions_in_if_condition)] + | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ error: this `if` has the same function call as a previous `if` --> $DIR/same_functions_in_if_condition.rs:42:15 diff --git a/tests/ui/search_is_some.rs b/tests/ui/search_is_some.rs index 72f335153c1..670599b0dcf 100644 --- a/tests/ui/search_is_some.rs +++ b/tests/ui/search_is_some.rs @@ -1,4 +1,4 @@ -// aux-build:option_helpers.rs +//@aux-build:option_helpers.rs #![warn(clippy::search_is_some)] #![allow(dead_code)] extern crate option_helpers; diff --git a/tests/ui/search_is_some_fixable_none.fixed b/tests/ui/search_is_some_fixable_none.fixed index 5190c5304c7..9386618c123 100644 --- a/tests/ui/search_is_some_fixable_none.fixed +++ b/tests/ui/search_is_some_fixable_none.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(dead_code, clippy::explicit_auto_deref)] #![warn(clippy::search_is_some)] diff --git a/tests/ui/search_is_some_fixable_none.rs b/tests/ui/search_is_some_fixable_none.rs index 310d87333a9..6b2537a96c2 100644 --- a/tests/ui/search_is_some_fixable_none.rs +++ b/tests/ui/search_is_some_fixable_none.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(dead_code, clippy::explicit_auto_deref)] #![warn(clippy::search_is_some)] diff --git a/tests/ui/search_is_some_fixable_some.fixed b/tests/ui/search_is_some_fixable_some.fixed index 385a9986aba..e9116fc59f1 100644 --- a/tests/ui/search_is_some_fixable_some.fixed +++ b/tests/ui/search_is_some_fixable_some.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(dead_code, clippy::explicit_auto_deref)] #![warn(clippy::search_is_some)] diff --git a/tests/ui/search_is_some_fixable_some.rs b/tests/ui/search_is_some_fixable_some.rs index 67e190ee378..b1528399457 100644 --- a/tests/ui/search_is_some_fixable_some.rs +++ b/tests/ui/search_is_some_fixable_some.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(dead_code, clippy::explicit_auto_deref)] #![warn(clippy::search_is_some)] diff --git a/tests/ui/seek_from_current.fixed b/tests/ui/seek_from_current.fixed index 1309c91b81c..34c33baf686 100644 --- a/tests/ui/seek_from_current.fixed +++ b/tests/ui/seek_from_current.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::seek_from_current)] use std::fs::File; diff --git a/tests/ui/seek_from_current.rs b/tests/ui/seek_from_current.rs index 5d9b1424cf6..22bcff1bc40 100644 --- a/tests/ui/seek_from_current.rs +++ b/tests/ui/seek_from_current.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::seek_from_current)] use std::fs::File; diff --git a/tests/ui/seek_to_start_instead_of_rewind.fixed b/tests/ui/seek_to_start_instead_of_rewind.fixed index dc24d447c60..d8a6e6985d4 100644 --- a/tests/ui/seek_to_start_instead_of_rewind.fixed +++ b/tests/ui/seek_to_start_instead_of_rewind.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused)] #![warn(clippy::seek_to_start_instead_of_rewind)] diff --git a/tests/ui/seek_to_start_instead_of_rewind.rs b/tests/ui/seek_to_start_instead_of_rewind.rs index 4adde2c4018..fc6a6433c2b 100644 --- a/tests/ui/seek_to_start_instead_of_rewind.rs +++ b/tests/ui/seek_to_start_instead_of_rewind.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused)] #![warn(clippy::seek_to_start_instead_of_rewind)] diff --git a/tests/ui/semicolon_inside_block.fixed b/tests/ui/semicolon_inside_block.fixed index 42e97e1ca35..ee359f60cbd 100644 --- a/tests/ui/semicolon_inside_block.fixed +++ b/tests/ui/semicolon_inside_block.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow( unused, clippy::unused_unit, diff --git a/tests/ui/semicolon_inside_block.rs b/tests/ui/semicolon_inside_block.rs index f40848f702e..e8516f79b20 100644 --- a/tests/ui/semicolon_inside_block.rs +++ b/tests/ui/semicolon_inside_block.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow( unused, clippy::unused_unit, diff --git a/tests/ui/semicolon_outside_block.fixed b/tests/ui/semicolon_outside_block.fixed index 091eaa7518e..034c7f8c7c1 100644 --- a/tests/ui/semicolon_outside_block.fixed +++ b/tests/ui/semicolon_outside_block.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow( unused, clippy::unused_unit, diff --git a/tests/ui/semicolon_outside_block.rs b/tests/ui/semicolon_outside_block.rs index 7ce46431fac..4dc956d8a4b 100644 --- a/tests/ui/semicolon_outside_block.rs +++ b/tests/ui/semicolon_outside_block.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow( unused, clippy::unused_unit, diff --git a/tests/ui/shadow.rs b/tests/ui/shadow.rs index ab7800a2110..03337ec3564 100644 --- a/tests/ui/shadow.rs +++ b/tests/ui/shadow.rs @@ -1,4 +1,4 @@ -// aux-build:proc_macro_derive.rs +//@aux-build:proc_macro_derive.rs #![warn(clippy::shadow_same, clippy::shadow_reuse, clippy::shadow_unrelated)] #![allow(clippy::let_unit_value)] diff --git a/tests/ui/short_circuit_statement.fixed b/tests/ui/short_circuit_statement.fixed index dd22ecab0b5..1737d501441 100644 --- a/tests/ui/short_circuit_statement.fixed +++ b/tests/ui/short_circuit_statement.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::short_circuit_statement)] #![allow(clippy::nonminimal_bool)] diff --git a/tests/ui/short_circuit_statement.rs b/tests/ui/short_circuit_statement.rs index 73a55bf1f5e..ab93aa1ca5c 100644 --- a/tests/ui/short_circuit_statement.rs +++ b/tests/ui/short_circuit_statement.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::short_circuit_statement)] #![allow(clippy::nonminimal_bool)] diff --git a/tests/ui/significant_drop_in_scrutinee.rs b/tests/ui/significant_drop_in_scrutinee.rs index c65df9ece38..8c48b21f188 100644 --- a/tests/ui/significant_drop_in_scrutinee.rs +++ b/tests/ui/significant_drop_in_scrutinee.rs @@ -1,5 +1,5 @@ // FIXME: Ideally these suggestions would be fixed via rustfix. Blocked by rust-lang/rust#53934 -// // run-rustfix +// #![warn(clippy::significant_drop_in_scrutinee)] #![allow(dead_code, unused_assignments)] #![allow(clippy::match_single_binding, clippy::single_match, clippy::uninlined_format_args)] diff --git a/tests/ui/significant_drop_tightening.fixed b/tests/ui/significant_drop_tightening.fixed index da998c610bd..ee7f2b0631a 100644 --- a/tests/ui/significant_drop_tightening.fixed +++ b/tests/ui/significant_drop_tightening.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::significant_drop_tightening)] diff --git a/tests/ui/significant_drop_tightening.rs b/tests/ui/significant_drop_tightening.rs index 83823f95f68..9c139deb95f 100644 --- a/tests/ui/significant_drop_tightening.rs +++ b/tests/ui/significant_drop_tightening.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::significant_drop_tightening)] diff --git a/tests/ui/single_char_add_str.fixed b/tests/ui/single_char_add_str.fixed index 63a6d37a9cc..cbcf1ab21c9 100644 --- a/tests/ui/single_char_add_str.fixed +++ b/tests/ui/single_char_add_str.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::single_char_add_str)] macro_rules! get_string { diff --git a/tests/ui/single_char_add_str.rs b/tests/ui/single_char_add_str.rs index a799ea7d885..a1f005cc833 100644 --- a/tests/ui/single_char_add_str.rs +++ b/tests/ui/single_char_add_str.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::single_char_add_str)] macro_rules! get_string { diff --git a/tests/ui/single_char_pattern.fixed b/tests/ui/single_char_pattern.fixed index 68e26726724..dba89872070 100644 --- a/tests/ui/single_char_pattern.fixed +++ b/tests/ui/single_char_pattern.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused_must_use)] diff --git a/tests/ui/single_char_pattern.rs b/tests/ui/single_char_pattern.rs index 186202d78ec..6a145a14bfd 100644 --- a/tests/ui/single_char_pattern.rs +++ b/tests/ui/single_char_pattern.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused_must_use)] diff --git a/tests/ui/single_component_path_imports.fixed b/tests/ui/single_component_path_imports.fixed index 8c96c4715d3..d4d2cbbe57a 100644 --- a/tests/ui/single_component_path_imports.fixed +++ b/tests/ui/single_component_path_imports.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::single_component_path_imports)] #![allow(unused_imports)] diff --git a/tests/ui/single_component_path_imports.rs b/tests/ui/single_component_path_imports.rs index 8434bf7eaf1..80d72115f43 100644 --- a/tests/ui/single_component_path_imports.rs +++ b/tests/ui/single_component_path_imports.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::single_component_path_imports)] #![allow(unused_imports)] diff --git a/tests/ui/single_element_loop.fixed b/tests/ui/single_element_loop.fixed index a0dcc0172e8..1697a0cf29b 100644 --- a/tests/ui/single_element_loop.fixed +++ b/tests/ui/single_element_loop.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix // Tests from for_loop.rs that don't have suggestions #[warn(clippy::single_element_loop)] diff --git a/tests/ui/single_element_loop.rs b/tests/ui/single_element_loop.rs index bc014035c98..860424f42dd 100644 --- a/tests/ui/single_element_loop.rs +++ b/tests/ui/single_element_loop.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix // Tests from for_loop.rs that don't have suggestions #[warn(clippy::single_element_loop)] diff --git a/tests/ui/single_match_else.rs b/tests/ui/single_match_else.rs index 3c86f41f3a6..c8ac768b60f 100644 --- a/tests/ui/single_match_else.rs +++ b/tests/ui/single_match_else.rs @@ -1,4 +1,4 @@ -// aux-build: proc_macros.rs +//@aux-build: proc_macros.rs #![warn(clippy::single_match_else)] #![allow(clippy::needless_return, clippy::no_effect, clippy::uninlined_format_args)] diff --git a/tests/ui/skip_while_next.rs b/tests/ui/skip_while_next.rs index a551c19d98b..62574e2c8ce 100644 --- a/tests/ui/skip_while_next.rs +++ b/tests/ui/skip_while_next.rs @@ -1,4 +1,4 @@ -// aux-build:option_helpers.rs +//@aux-build:option_helpers.rs #![warn(clippy::skip_while_next)] #![allow(clippy::disallowed_names)] diff --git a/tests/ui/stable_sort_primitive.fixed b/tests/ui/stable_sort_primitive.fixed index f5f18169df2..1370dd2df4d 100644 --- a/tests/ui/stable_sort_primitive.fixed +++ b/tests/ui/stable_sort_primitive.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::stable_sort_primitive)] fn main() { diff --git a/tests/ui/stable_sort_primitive.rs b/tests/ui/stable_sort_primitive.rs index 8149c5638e0..cd344dd1238 100644 --- a/tests/ui/stable_sort_primitive.rs +++ b/tests/ui/stable_sort_primitive.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::stable_sort_primitive)] fn main() { diff --git a/tests/ui/starts_ends_with.fixed b/tests/ui/starts_ends_with.fixed index 983fac7afe6..29d56f852ed 100644 --- a/tests/ui/starts_ends_with.fixed +++ b/tests/ui/starts_ends_with.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(dead_code, unused_must_use)] fn main() {} diff --git a/tests/ui/starts_ends_with.rs b/tests/ui/starts_ends_with.rs index e3335dd2e2e..56bbe2574d4 100644 --- a/tests/ui/starts_ends_with.rs +++ b/tests/ui/starts_ends_with.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(dead_code, unused_must_use)] fn main() {} diff --git a/tests/ui/string_add.rs b/tests/ui/string_add.rs index 20edbe31fa9..de78dfe4d69 100644 --- a/tests/ui/string_add.rs +++ b/tests/ui/string_add.rs @@ -1,4 +1,4 @@ -// aux-build:proc_macros.rs +//@aux-build:proc_macros.rs extern crate proc_macros; use proc_macros::external; diff --git a/tests/ui/string_add_assign.fixed b/tests/ui/string_add_assign.fixed index b687f43b254..616c6daaf66 100644 --- a/tests/ui/string_add_assign.fixed +++ b/tests/ui/string_add_assign.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #[allow(clippy::string_add, unused)] #[warn(clippy::string_add_assign)] diff --git a/tests/ui/string_add_assign.rs b/tests/ui/string_add_assign.rs index e5dbde108fb..e1f8859757c 100644 --- a/tests/ui/string_add_assign.rs +++ b/tests/ui/string_add_assign.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #[allow(clippy::string_add, unused)] #[warn(clippy::string_add_assign)] diff --git a/tests/ui/string_extend.fixed b/tests/ui/string_extend.fixed index d200d7310fc..65c9abff3d4 100644 --- a/tests/ui/string_extend.fixed +++ b/tests/ui/string_extend.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #[derive(Copy, Clone)] struct HasChars; diff --git a/tests/ui/string_extend.rs b/tests/ui/string_extend.rs index 0dd96a3b210..5f72ffe2fda 100644 --- a/tests/ui/string_extend.rs +++ b/tests/ui/string_extend.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #[derive(Copy, Clone)] struct HasChars; diff --git a/tests/ui/string_from_utf8_as_bytes.fixed b/tests/ui/string_from_utf8_as_bytes.fixed index 6e665cdd563..9b315ae2b55 100644 --- a/tests/ui/string_from_utf8_as_bytes.fixed +++ b/tests/ui/string_from_utf8_as_bytes.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::string_from_utf8_as_bytes)] fn main() { diff --git a/tests/ui/string_from_utf8_as_bytes.rs b/tests/ui/string_from_utf8_as_bytes.rs index 670d206d367..043dd235082 100644 --- a/tests/ui/string_from_utf8_as_bytes.rs +++ b/tests/ui/string_from_utf8_as_bytes.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::string_from_utf8_as_bytes)] fn main() { diff --git a/tests/ui/string_lit_as_bytes.fixed b/tests/ui/string_lit_as_bytes.fixed index 506187fc125..058f2aa54da 100644 --- a/tests/ui/string_lit_as_bytes.fixed +++ b/tests/ui/string_lit_as_bytes.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(dead_code, unused_variables)] #![warn(clippy::string_lit_as_bytes)] diff --git a/tests/ui/string_lit_as_bytes.rs b/tests/ui/string_lit_as_bytes.rs index 2c339f1ddb8..b550bea001f 100644 --- a/tests/ui/string_lit_as_bytes.rs +++ b/tests/ui/string_lit_as_bytes.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(dead_code, unused_variables)] #![warn(clippy::string_lit_as_bytes)] diff --git a/tests/ui/strlen_on_c_strings.fixed b/tests/ui/strlen_on_c_strings.fixed index 947a59bcc02..ef207e28cca 100644 --- a/tests/ui/strlen_on_c_strings.fixed +++ b/tests/ui/strlen_on_c_strings.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::strlen_on_c_strings)] #![allow(dead_code)] diff --git a/tests/ui/strlen_on_c_strings.rs b/tests/ui/strlen_on_c_strings.rs index 1237f1ab03a..03ec5f79d09 100644 --- a/tests/ui/strlen_on_c_strings.rs +++ b/tests/ui/strlen_on_c_strings.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::strlen_on_c_strings)] #![allow(dead_code)] diff --git a/tests/ui/suspicious_doc_comments.fixed b/tests/ui/suspicious_doc_comments.fixed index b404df94d3c..bffda1cc412 100644 --- a/tests/ui/suspicious_doc_comments.fixed +++ b/tests/ui/suspicious_doc_comments.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused)] #![warn(clippy::suspicious_doc_comments)] diff --git a/tests/ui/suspicious_doc_comments.rs b/tests/ui/suspicious_doc_comments.rs index 46eff51e220..cdd972ee30f 100644 --- a/tests/ui/suspicious_doc_comments.rs +++ b/tests/ui/suspicious_doc_comments.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused)] #![warn(clippy::suspicious_doc_comments)] diff --git a/tests/ui/suspicious_else_formatting.rs b/tests/ui/suspicious_else_formatting.rs index 21753e5dc6a..e0153cdd8cd 100644 --- a/tests/ui/suspicious_else_formatting.rs +++ b/tests/ui/suspicious_else_formatting.rs @@ -1,4 +1,4 @@ -// aux-build:proc_macro_suspicious_else_formatting.rs +//@aux-build:proc_macro_suspicious_else_formatting.rs #![warn(clippy::suspicious_else_formatting)] #![allow(clippy::if_same_then_else, clippy::let_unit_value)] diff --git a/tests/ui/suspicious_operation_groupings.fixed b/tests/ui/suspicious_operation_groupings.fixed index ede8a39fed7..0e37701ec48 100644 --- a/tests/ui/suspicious_operation_groupings.fixed +++ b/tests/ui/suspicious_operation_groupings.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::suspicious_operation_groupings)] #![allow(dead_code, unused_parens, clippy::eq_op)] diff --git a/tests/ui/suspicious_operation_groupings.rs b/tests/ui/suspicious_operation_groupings.rs index 26ce97bb37f..dd4f3b71c37 100644 --- a/tests/ui/suspicious_operation_groupings.rs +++ b/tests/ui/suspicious_operation_groupings.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::suspicious_operation_groupings)] #![allow(dead_code, unused_parens, clippy::eq_op)] diff --git a/tests/ui/swap.fixed b/tests/ui/swap.fixed index 9703674d1a4..fd3569cf362 100644 --- a/tests/ui/swap.fixed +++ b/tests/ui/swap.fixed @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build: macro_rules.rs +//@run-rustfix +//@aux-build: macro_rules.rs #![warn(clippy::all)] #![allow( diff --git a/tests/ui/swap.rs b/tests/ui/swap.rs index a0228065e46..34fbce0524b 100644 --- a/tests/ui/swap.rs +++ b/tests/ui/swap.rs @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build: macro_rules.rs +//@run-rustfix +//@aux-build: macro_rules.rs #![warn(clippy::all)] #![allow( diff --git a/tests/ui/swap_ptr_to_ref.fixed b/tests/ui/swap_ptr_to_ref.fixed index 596b6ee919b..3bede3017a1 100644 --- a/tests/ui/swap_ptr_to_ref.fixed +++ b/tests/ui/swap_ptr_to_ref.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::swap_ptr_to_ref)] diff --git a/tests/ui/swap_ptr_to_ref.rs b/tests/ui/swap_ptr_to_ref.rs index 282f571211d..726b09d3764 100644 --- a/tests/ui/swap_ptr_to_ref.rs +++ b/tests/ui/swap_ptr_to_ref.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::swap_ptr_to_ref)] diff --git a/tests/ui/tabs_in_doc_comments.fixed b/tests/ui/tabs_in_doc_comments.fixed index 4bc4bc86c76..21020182c24 100644 --- a/tests/ui/tabs_in_doc_comments.fixed +++ b/tests/ui/tabs_in_doc_comments.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::tabs_in_doc_comments)] #[allow(dead_code)] diff --git a/tests/ui/tabs_in_doc_comments.rs b/tests/ui/tabs_in_doc_comments.rs index 9db3416e659..df704267dd2 100644 --- a/tests/ui/tabs_in_doc_comments.rs +++ b/tests/ui/tabs_in_doc_comments.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::tabs_in_doc_comments)] #[allow(dead_code)] diff --git a/tests/ui/tests_outside_test_module.rs b/tests/ui/tests_outside_test_module.rs index 1982b1d0107..21fdfdf9005 100644 --- a/tests/ui/tests_outside_test_module.rs +++ b/tests/ui/tests_outside_test_module.rs @@ -1,4 +1,4 @@ -// compile-flags: --test +//@compile-flags: --test #![allow(unused)] #![warn(clippy::tests_outside_test_module)] diff --git a/tests/ui/to_digit_is_some.fixed b/tests/ui/to_digit_is_some.fixed index 3c5e9642714..dc9be66d48a 100644 --- a/tests/ui/to_digit_is_some.fixed +++ b/tests/ui/to_digit_is_some.fixed @@ -1,4 +1,4 @@ -//run-rustfix +//@run-rustfix #![warn(clippy::to_digit_is_some)] diff --git a/tests/ui/to_digit_is_some.rs b/tests/ui/to_digit_is_some.rs index 4f247c06cee..d2a09ac30de 100644 --- a/tests/ui/to_digit_is_some.rs +++ b/tests/ui/to_digit_is_some.rs @@ -1,4 +1,4 @@ -//run-rustfix +//@run-rustfix #![warn(clippy::to_digit_is_some)] diff --git a/tests/ui/toplevel_ref_arg.fixed b/tests/ui/toplevel_ref_arg.fixed index 174c858a47d..ea30c1fda6f 100644 --- a/tests/ui/toplevel_ref_arg.fixed +++ b/tests/ui/toplevel_ref_arg.fixed @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build:proc_macros.rs +//@run-rustfix +//@aux-build:proc_macros.rs #![warn(clippy::toplevel_ref_arg)] #![allow(clippy::uninlined_format_args, unused)] diff --git a/tests/ui/toplevel_ref_arg.rs b/tests/ui/toplevel_ref_arg.rs index 4b81a06112f..7a3d33e5be5 100644 --- a/tests/ui/toplevel_ref_arg.rs +++ b/tests/ui/toplevel_ref_arg.rs @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build:proc_macros.rs +//@run-rustfix +//@aux-build:proc_macros.rs #![warn(clippy::toplevel_ref_arg)] #![allow(clippy::uninlined_format_args, unused)] diff --git a/tests/ui/toplevel_ref_arg_non_rustfix.rs b/tests/ui/toplevel_ref_arg_non_rustfix.rs index 2047593e7e4..8aaf47b1bd0 100644 --- a/tests/ui/toplevel_ref_arg_non_rustfix.rs +++ b/tests/ui/toplevel_ref_arg_non_rustfix.rs @@ -1,4 +1,4 @@ -// aux-build:proc_macros.rs +//@aux-build:proc_macros.rs #![warn(clippy::toplevel_ref_arg)] #![allow(unused)] diff --git a/tests/ui/track-diagnostics.rs b/tests/ui/track-diagnostics.rs index fa9221ed02d..6ab0bce770e 100644 --- a/tests/ui/track-diagnostics.rs +++ b/tests/ui/track-diagnostics.rs @@ -1,9 +1,8 @@ -// compile-flags: -Z track-diagnostics -// error-pattern: created at +//@compile-flags: -Z track-diagnostics // Normalize the emitted location so this doesn't need // updating everytime someone adds or removes a line. -// normalize-stderr-test ".rs:\d+:\d+" -> ".rs:LL:CC" +//@normalize-stderr-test: ".rs:\d+:\d+" -> ".rs:LL:CC" struct A; struct B; diff --git a/tests/ui/trait_duplication_in_bounds.fixed b/tests/ui/trait_duplication_in_bounds.fixed index 4ce5d421782..eef8024b131 100644 --- a/tests/ui/trait_duplication_in_bounds.fixed +++ b/tests/ui/trait_duplication_in_bounds.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![deny(clippy::trait_duplication_in_bounds)] #![allow(unused)] diff --git a/tests/ui/trait_duplication_in_bounds.rs b/tests/ui/trait_duplication_in_bounds.rs index 7f2e96a22e6..a7a1caf2880 100644 --- a/tests/ui/trait_duplication_in_bounds.rs +++ b/tests/ui/trait_duplication_in_bounds.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![deny(clippy::trait_duplication_in_bounds)] #![allow(unused)] diff --git a/tests/ui/transmute_32bit.rs b/tests/ui/transmute_32bit.rs index ffe22b12f55..8e1316ca39d 100644 --- a/tests/ui/transmute_32bit.rs +++ b/tests/ui/transmute_32bit.rs @@ -1,4 +1,4 @@ -// ignore-64bit +//@ignore-64bit #[warn(clippy::wrong_transmute)] fn main() { diff --git a/tests/ui/transmute_32bit.stderr b/tests/ui/transmute_32bit.stderr index 040519564b9..75ddca60d2a 100644 --- a/tests/ui/transmute_32bit.stderr +++ b/tests/ui/transmute_32bit.stderr @@ -1,28 +1,39 @@ -error: transmute from a `f32` to a pointer +error[E0512]: cannot transmute between types of different sizes, or dependently-sized types --> $DIR/transmute_32bit.rs:6:31 | LL | let _: *const usize = std::mem::transmute(6.0f32); - | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ + | ^^^^^^^^^^^^^^^^^^^ | - = note: `-D clippy::wrong-transmute` implied by `-D warnings` + = note: source type: `f32` (32 bits) + = note: target type: `*const usize` (64 bits) -error: transmute from a `f32` to a pointer +error[E0512]: cannot transmute between types of different sizes, or dependently-sized types --> $DIR/transmute_32bit.rs:8:29 | LL | let _: *mut usize = std::mem::transmute(6.0f32); - | ^^^^^^^^^^^^^^^^^^^^^^^^^^^ + | ^^^^^^^^^^^^^^^^^^^ + | + = note: source type: `f32` (32 bits) + = note: target type: `*mut usize` (64 bits) -error: transmute from a `char` to a pointer +error[E0512]: cannot transmute between types of different sizes, or dependently-sized types --> $DIR/transmute_32bit.rs:10:31 | LL | let _: *const usize = std::mem::transmute('x'); - | ^^^^^^^^^^^^^^^^^^^^^^^^ + | ^^^^^^^^^^^^^^^^^^^ + | + = note: source type: `char` (32 bits) + = note: target type: `*const usize` (64 bits) -error: transmute from a `char` to a pointer +error[E0512]: cannot transmute between types of different sizes, or dependently-sized types --> $DIR/transmute_32bit.rs:12:29 | LL | let _: *mut usize = std::mem::transmute('x'); - | ^^^^^^^^^^^^^^^^^^^^^^^^ + | ^^^^^^^^^^^^^^^^^^^ + | + = note: source type: `char` (32 bits) + = note: target type: `*mut usize` (64 bits) error: aborting due to 4 previous errors +For more information about this error, try `rustc --explain E0512`. diff --git a/tests/ui/transmute_64bit.rs b/tests/ui/transmute_64bit.rs index 00dc0b2c360..ceecf9b279f 100644 --- a/tests/ui/transmute_64bit.rs +++ b/tests/ui/transmute_64bit.rs @@ -1,4 +1,4 @@ -// ignore-32bit +//@ignore-32bit #[warn(clippy::wrong_transmute)] fn main() { diff --git a/tests/ui/transmute_ptr_to_ref.fixed b/tests/ui/transmute_ptr_to_ref.fixed index 074dae5fb28..575dadde906 100644 --- a/tests/ui/transmute_ptr_to_ref.fixed +++ b/tests/ui/transmute_ptr_to_ref.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::transmute_ptr_to_ref)] #![allow(clippy::match_single_binding)] diff --git a/tests/ui/transmute_ptr_to_ref.rs b/tests/ui/transmute_ptr_to_ref.rs index 2edc122cf47..4238ff80478 100644 --- a/tests/ui/transmute_ptr_to_ref.rs +++ b/tests/ui/transmute_ptr_to_ref.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::transmute_ptr_to_ref)] #![allow(clippy::match_single_binding)] diff --git a/tests/ui/transmutes_expressible_as_ptr_casts.fixed b/tests/ui/transmutes_expressible_as_ptr_casts.fixed index cc84ba25bd0..05aa86c479a 100644 --- a/tests/ui/transmutes_expressible_as_ptr_casts.fixed +++ b/tests/ui/transmutes_expressible_as_ptr_casts.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::transmutes_expressible_as_ptr_casts)] // These two warnings currently cover the cases transmutes_expressible_as_ptr_casts // would otherwise be responsible for diff --git a/tests/ui/transmutes_expressible_as_ptr_casts.rs b/tests/ui/transmutes_expressible_as_ptr_casts.rs index aa65ab4dd24..29fa6914cfd 100644 --- a/tests/ui/transmutes_expressible_as_ptr_casts.rs +++ b/tests/ui/transmutes_expressible_as_ptr_casts.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::transmutes_expressible_as_ptr_casts)] // These two warnings currently cover the cases transmutes_expressible_as_ptr_casts // would otherwise be responsible for diff --git a/tests/ui/trim_split_whitespace.fixed b/tests/ui/trim_split_whitespace.fixed index e4d352f7367..7909b319ddd 100644 --- a/tests/ui/trim_split_whitespace.fixed +++ b/tests/ui/trim_split_whitespace.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::trim_split_whitespace)] #![allow(clippy::let_unit_value)] diff --git a/tests/ui/trim_split_whitespace.rs b/tests/ui/trim_split_whitespace.rs index f98451a9837..0cf58979fb2 100644 --- a/tests/ui/trim_split_whitespace.rs +++ b/tests/ui/trim_split_whitespace.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::trim_split_whitespace)] #![allow(clippy::let_unit_value)] diff --git a/tests/ui/trivially_copy_pass_by_ref.rs b/tests/ui/trivially_copy_pass_by_ref.rs index c0af011d33d..48615583156 100644 --- a/tests/ui/trivially_copy_pass_by_ref.rs +++ b/tests/ui/trivially_copy_pass_by_ref.rs @@ -1,5 +1,5 @@ -// normalize-stderr-test "\(\d+ byte\)" -> "(N byte)" -// normalize-stderr-test "\(limit: \d+ byte\)" -> "(limit: N byte)" +//@normalize-stderr-test: "\(\d+ byte\)" -> "(N byte)" +//@normalize-stderr-test: "\(limit: \d+ byte\)" -> "(limit: N byte)" #![deny(clippy::trivially_copy_pass_by_ref)] #![allow( clippy::disallowed_names, diff --git a/tests/ui/try_err.fixed b/tests/ui/try_err.fixed index dc497b1690f..dc773ad4bad 100644 --- a/tests/ui/try_err.fixed +++ b/tests/ui/try_err.fixed @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build:proc_macros.rs +//@run-rustfix +//@aux-build:proc_macros.rs #![deny(clippy::try_err)] #![allow(clippy::unnecessary_wraps, clippy::needless_question_mark)] diff --git a/tests/ui/try_err.rs b/tests/ui/try_err.rs index 86aeb75cd96..7a7433a7ec2 100644 --- a/tests/ui/try_err.rs +++ b/tests/ui/try_err.rs @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build:proc_macros.rs +//@run-rustfix +//@aux-build:proc_macros.rs #![deny(clippy::try_err)] #![allow(clippy::unnecessary_wraps, clippy::needless_question_mark)] diff --git a/tests/ui/types.fixed b/tests/ui/types.fixed index 417da42edf1..4a2616a7a22 100644 --- a/tests/ui/types.fixed +++ b/tests/ui/types.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(dead_code, unused_variables)] #![warn(clippy::cast_lossless)] diff --git a/tests/ui/types.rs b/tests/ui/types.rs index b16e9e538b1..5e0917907db 100644 --- a/tests/ui/types.rs +++ b/tests/ui/types.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(dead_code, unused_variables)] #![warn(clippy::cast_lossless)] diff --git a/tests/ui/unchecked_duration_subtraction.fixed b/tests/ui/unchecked_duration_subtraction.fixed index a0e49a8beb1..757d1592184 100644 --- a/tests/ui/unchecked_duration_subtraction.fixed +++ b/tests/ui/unchecked_duration_subtraction.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::unchecked_duration_subtraction)] use std::time::{Duration, Instant}; diff --git a/tests/ui/unchecked_duration_subtraction.rs b/tests/ui/unchecked_duration_subtraction.rs index a14a7ea57cc..da7faab6753 100644 --- a/tests/ui/unchecked_duration_subtraction.rs +++ b/tests/ui/unchecked_duration_subtraction.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::unchecked_duration_subtraction)] use std::time::{Duration, Instant}; diff --git a/tests/ui/undocumented_unsafe_blocks.rs b/tests/ui/undocumented_unsafe_blocks.rs index c05eb447b2e..229d150851a 100644 --- a/tests/ui/undocumented_unsafe_blocks.rs +++ b/tests/ui/undocumented_unsafe_blocks.rs @@ -1,4 +1,4 @@ -// aux-build:proc_macro_unsafe.rs +//@aux-build:proc_macro_unsafe.rs #![warn(clippy::undocumented_unsafe_blocks, clippy::unnecessary_safety_comment)] #![allow(clippy::let_unit_value, clippy::missing_safety_doc)] diff --git a/tests/ui/unicode.fixed b/tests/ui/unicode.fixed index 94b4723452f..910968afa7f 100644 --- a/tests/ui/unicode.fixed +++ b/tests/ui/unicode.fixed @@ -1,5 +1,5 @@ -// run-rustfix -// compile-flags: --test +//@run-rustfix +//@compile-flags: --test #![allow(dead_code)] #[warn(clippy::invisible_characters)] diff --git a/tests/ui/unicode.rs b/tests/ui/unicode.rs index 6ad0b255b94..bc4b84d3435 100644 --- a/tests/ui/unicode.rs +++ b/tests/ui/unicode.rs @@ -1,5 +1,5 @@ -// run-rustfix -// compile-flags: --test +//@run-rustfix +//@compile-flags: --test #![allow(dead_code)] #[warn(clippy::invisible_characters)] diff --git a/tests/ui/uninlined_format_args.fixed b/tests/ui/uninlined_format_args.fixed index 3122081a44f..e25d123dd51 100644 --- a/tests/ui/uninlined_format_args.fixed +++ b/tests/ui/uninlined_format_args.fixed @@ -1,5 +1,5 @@ -// aux-build:proc_macros.rs -// run-rustfix +//@aux-build:proc_macros.rs +//@run-rustfix #![warn(clippy::uninlined_format_args)] #![allow(named_arguments_used_positionally, unused)] #![allow(clippy::eq_op, clippy::format_in_format_args, clippy::print_literal)] diff --git a/tests/ui/uninlined_format_args.rs b/tests/ui/uninlined_format_args.rs index b153ef256e0..6793ec24441 100644 --- a/tests/ui/uninlined_format_args.rs +++ b/tests/ui/uninlined_format_args.rs @@ -1,5 +1,5 @@ -// aux-build:proc_macros.rs -// run-rustfix +//@aux-build:proc_macros.rs +//@run-rustfix #![warn(clippy::uninlined_format_args)] #![allow(named_arguments_used_positionally, unused)] #![allow(clippy::eq_op, clippy::format_in_format_args, clippy::print_literal)] diff --git a/tests/ui/uninlined_format_args_panic.edition2018.fixed b/tests/ui/uninlined_format_args_panic.edition2018.fixed index 52b5343c351..559050b3df6 100644 --- a/tests/ui/uninlined_format_args_panic.edition2018.fixed +++ b/tests/ui/uninlined_format_args_panic.edition2018.fixed @@ -1,7 +1,7 @@ -// revisions: edition2018 edition2021 -//[edition2018] edition:2018 -//[edition2021] edition:2021 -// run-rustfix +//@revisions: edition2018 edition2021 +//@[edition2018] edition:2018 +//@[edition2021] edition:2021 +//@run-rustfix #![warn(clippy::uninlined_format_args)] diff --git a/tests/ui/uninlined_format_args_panic.edition2021.fixed b/tests/ui/uninlined_format_args_panic.edition2021.fixed index ee72065e28a..3a753b49caf 100644 --- a/tests/ui/uninlined_format_args_panic.edition2021.fixed +++ b/tests/ui/uninlined_format_args_panic.edition2021.fixed @@ -1,7 +1,7 @@ -// revisions: edition2018 edition2021 -//[edition2018] edition:2018 -//[edition2021] edition:2021 -// run-rustfix +//@revisions: edition2018 edition2021 +//@[edition2018] edition:2018 +//@[edition2021] edition:2021 +//@run-rustfix #![warn(clippy::uninlined_format_args)] diff --git a/tests/ui/uninlined_format_args_panic.rs b/tests/ui/uninlined_format_args_panic.rs index b4a0a0f496e..83fbb9afd2a 100644 --- a/tests/ui/uninlined_format_args_panic.rs +++ b/tests/ui/uninlined_format_args_panic.rs @@ -1,7 +1,7 @@ -// revisions: edition2018 edition2021 -//[edition2018] edition:2018 -//[edition2021] edition:2021 -// run-rustfix +//@revisions: edition2018 edition2021 +//@[edition2018] edition:2018 +//@[edition2021] edition:2021 +//@run-rustfix #![warn(clippy::uninlined_format_args)] diff --git a/tests/ui/unit_arg.rs b/tests/ui/unit_arg.rs index 674ae4f1df9..d082063c8e8 100644 --- a/tests/ui/unit_arg.rs +++ b/tests/ui/unit_arg.rs @@ -1,4 +1,4 @@ -// aux-build: proc_macros.rs +//@aux-build: proc_macros.rs #![warn(clippy::unit_arg)] #![allow(unused_must_use, unused_variables)] #![allow( diff --git a/tests/ui/unit_arg_empty_blocks.fixed b/tests/ui/unit_arg_empty_blocks.fixed index 5787471a32c..8c065115a74 100644 --- a/tests/ui/unit_arg_empty_blocks.fixed +++ b/tests/ui/unit_arg_empty_blocks.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::unit_arg)] #![allow(unused_must_use, unused_variables)] #![allow(clippy::no_effect, clippy::uninlined_format_args)] diff --git a/tests/ui/unit_arg_empty_blocks.rs b/tests/ui/unit_arg_empty_blocks.rs index 6a42c2ccf42..af166b56ff4 100644 --- a/tests/ui/unit_arg_empty_blocks.rs +++ b/tests/ui/unit_arg_empty_blocks.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::unit_arg)] #![allow(unused_must_use, unused_variables)] #![allow(clippy::no_effect, clippy::uninlined_format_args)] diff --git a/tests/ui/unknown_clippy_lints.fixed b/tests/ui/unknown_clippy_lints.fixed index 4249ff8a958..0c269d650c8 100644 --- a/tests/ui/unknown_clippy_lints.fixed +++ b/tests/ui/unknown_clippy_lints.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::pedantic)] // Should suggest lowercase diff --git a/tests/ui/unknown_clippy_lints.rs b/tests/ui/unknown_clippy_lints.rs index 5db345f5444..b60042923ea 100644 --- a/tests/ui/unknown_clippy_lints.rs +++ b/tests/ui/unknown_clippy_lints.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::pedantic)] // Should suggest lowercase diff --git a/tests/ui/unnecessary_cast.fixed b/tests/ui/unnecessary_cast.fixed index 2f7e2997e73..bcc231ea7bc 100644 --- a/tests/ui/unnecessary_cast.fixed +++ b/tests/ui/unnecessary_cast.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::unnecessary_cast)] #![allow( unused_must_use, diff --git a/tests/ui/unnecessary_cast.rs b/tests/ui/unnecessary_cast.rs index 54dd46ba59f..282b2f1283e 100644 --- a/tests/ui/unnecessary_cast.rs +++ b/tests/ui/unnecessary_cast.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::unnecessary_cast)] #![allow( unused_must_use, diff --git a/tests/ui/unnecessary_fold.fixed b/tests/ui/unnecessary_fold.fixed index 52300a3b640..2bed14973ca 100644 --- a/tests/ui/unnecessary_fold.fixed +++ b/tests/ui/unnecessary_fold.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(dead_code)] diff --git a/tests/ui/unnecessary_fold.rs b/tests/ui/unnecessary_fold.rs index 4028d80c0a3..a3cec8ea3d5 100644 --- a/tests/ui/unnecessary_fold.rs +++ b/tests/ui/unnecessary_fold.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(dead_code)] diff --git a/tests/ui/unnecessary_iter_cloned.fixed b/tests/ui/unnecessary_iter_cloned.fixed index e01e9f07baf..a0f8dd1a200 100644 --- a/tests/ui/unnecessary_iter_cloned.fixed +++ b/tests/ui/unnecessary_iter_cloned.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused_assignments)] #![warn(clippy::unnecessary_to_owned)] diff --git a/tests/ui/unnecessary_iter_cloned.rs b/tests/ui/unnecessary_iter_cloned.rs index 6ef2966c8b7..98f2dfe7549 100644 --- a/tests/ui/unnecessary_iter_cloned.rs +++ b/tests/ui/unnecessary_iter_cloned.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused_assignments)] #![warn(clippy::unnecessary_to_owned)] diff --git a/tests/ui/unnecessary_join.fixed b/tests/ui/unnecessary_join.fixed index 34795396025..e102df62599 100644 --- a/tests/ui/unnecessary_join.fixed +++ b/tests/ui/unnecessary_join.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::unnecessary_join)] #![allow(clippy::uninlined_format_args)] diff --git a/tests/ui/unnecessary_join.rs b/tests/ui/unnecessary_join.rs index 344918cd2a2..b87c15bc126 100644 --- a/tests/ui/unnecessary_join.rs +++ b/tests/ui/unnecessary_join.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::unnecessary_join)] #![allow(clippy::uninlined_format_args)] diff --git a/tests/ui/unnecessary_lazy_eval.fixed b/tests/ui/unnecessary_lazy_eval.fixed index 3b93800f8b7..c3728886ec9 100644 --- a/tests/ui/unnecessary_lazy_eval.fixed +++ b/tests/ui/unnecessary_lazy_eval.fixed @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build: proc_macros.rs +//@run-rustfix +//@aux-build: proc_macros.rs #![warn(clippy::unnecessary_lazy_evaluations)] #![allow(clippy::redundant_closure)] #![allow(clippy::bind_instead_of_map)] diff --git a/tests/ui/unnecessary_lazy_eval.rs b/tests/ui/unnecessary_lazy_eval.rs index 2851c0c5190..76e50fa5b03 100644 --- a/tests/ui/unnecessary_lazy_eval.rs +++ b/tests/ui/unnecessary_lazy_eval.rs @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build: proc_macros.rs +//@run-rustfix +//@aux-build: proc_macros.rs #![warn(clippy::unnecessary_lazy_evaluations)] #![allow(clippy::redundant_closure)] #![allow(clippy::bind_instead_of_map)] diff --git a/tests/ui/unnecessary_operation.fixed b/tests/ui/unnecessary_operation.fixed index b046694f8c6..fbd2d34591f 100644 --- a/tests/ui/unnecessary_operation.fixed +++ b/tests/ui/unnecessary_operation.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow( clippy::deref_addrof, diff --git a/tests/ui/unnecessary_operation.rs b/tests/ui/unnecessary_operation.rs index 9ed9679e938..b45298a6dc4 100644 --- a/tests/ui/unnecessary_operation.rs +++ b/tests/ui/unnecessary_operation.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow( clippy::deref_addrof, diff --git a/tests/ui/unnecessary_owned_empty_strings.fixed b/tests/ui/unnecessary_owned_empty_strings.fixed index 40052c41039..af12fd1d63d 100644 --- a/tests/ui/unnecessary_owned_empty_strings.fixed +++ b/tests/ui/unnecessary_owned_empty_strings.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::unnecessary_owned_empty_strings)] diff --git a/tests/ui/unnecessary_owned_empty_strings.rs b/tests/ui/unnecessary_owned_empty_strings.rs index 2304dff5192..a460b21af8c 100644 --- a/tests/ui/unnecessary_owned_empty_strings.rs +++ b/tests/ui/unnecessary_owned_empty_strings.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::unnecessary_owned_empty_strings)] diff --git a/tests/ui/unnecessary_self_imports.fixed b/tests/ui/unnecessary_self_imports.fixed index 1185eaa1d55..7fc978d3ef7 100644 --- a/tests/ui/unnecessary_self_imports.fixed +++ b/tests/ui/unnecessary_self_imports.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::unnecessary_self_imports)] #![allow(unused_imports, dead_code)] diff --git a/tests/ui/unnecessary_self_imports.rs b/tests/ui/unnecessary_self_imports.rs index 56bfbc09402..02424bc12b0 100644 --- a/tests/ui/unnecessary_self_imports.rs +++ b/tests/ui/unnecessary_self_imports.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::unnecessary_self_imports)] #![allow(unused_imports, dead_code)] diff --git a/tests/ui/unnecessary_sort_by.fixed b/tests/ui/unnecessary_sort_by.fixed index 21e2da474a8..165cabd8298 100644 --- a/tests/ui/unnecessary_sort_by.fixed +++ b/tests/ui/unnecessary_sort_by.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(clippy::stable_sort_primitive)] diff --git a/tests/ui/unnecessary_sort_by.rs b/tests/ui/unnecessary_sort_by.rs index 3365bf6e119..8a2158d5a84 100644 --- a/tests/ui/unnecessary_sort_by.rs +++ b/tests/ui/unnecessary_sort_by.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(clippy::stable_sort_primitive)] diff --git a/tests/ui/unnecessary_struct_initialization.fixed b/tests/ui/unnecessary_struct_initialization.fixed index b47129e4a36..bdf746cf2c4 100644 --- a/tests/ui/unnecessary_struct_initialization.fixed +++ b/tests/ui/unnecessary_struct_initialization.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused)] #![warn(clippy::unnecessary_struct_initialization)] diff --git a/tests/ui/unnecessary_struct_initialization.rs b/tests/ui/unnecessary_struct_initialization.rs index 63b11c626e5..7271e2f957a 100644 --- a/tests/ui/unnecessary_struct_initialization.rs +++ b/tests/ui/unnecessary_struct_initialization.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused)] #![warn(clippy::unnecessary_struct_initialization)] diff --git a/tests/ui/unnecessary_to_owned.fixed b/tests/ui/unnecessary_to_owned.fixed index 345f6d604c4..c879fdc3b6a 100644 --- a/tests/ui/unnecessary_to_owned.fixed +++ b/tests/ui/unnecessary_to_owned.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(clippy::needless_borrow, clippy::ptr_arg)] #![warn(clippy::unnecessary_to_owned)] diff --git a/tests/ui/unnecessary_to_owned.rs b/tests/ui/unnecessary_to_owned.rs index 7eb53df39e5..10588beb263 100644 --- a/tests/ui/unnecessary_to_owned.rs +++ b/tests/ui/unnecessary_to_owned.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(clippy::needless_borrow, clippy::ptr_arg)] #![warn(clippy::unnecessary_to_owned)] diff --git a/tests/ui/unnecessary_unsafety_doc.rs b/tests/ui/unnecessary_unsafety_doc.rs index 431093ab369..373b18470f6 100644 --- a/tests/ui/unnecessary_unsafety_doc.rs +++ b/tests/ui/unnecessary_unsafety_doc.rs @@ -1,4 +1,4 @@ -// aux-build:proc_macros.rs +//@aux-build:proc_macros.rs #![allow(clippy::let_unit_value)] #![warn(clippy::unnecessary_safety_doc)] diff --git a/tests/ui/unneeded_wildcard_pattern.fixed b/tests/ui/unneeded_wildcard_pattern.fixed index 12c3461c955..16c2de760e5 100644 --- a/tests/ui/unneeded_wildcard_pattern.fixed +++ b/tests/ui/unneeded_wildcard_pattern.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![feature(stmt_expr_attributes)] #![deny(clippy::unneeded_wildcard_pattern)] diff --git a/tests/ui/unneeded_wildcard_pattern.rs b/tests/ui/unneeded_wildcard_pattern.rs index 4ac01d5d23b..9d9eae1d903 100644 --- a/tests/ui/unneeded_wildcard_pattern.rs +++ b/tests/ui/unneeded_wildcard_pattern.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![feature(stmt_expr_attributes)] #![deny(clippy::unneeded_wildcard_pattern)] diff --git a/tests/ui/unnested_or_patterns.fixed b/tests/ui/unnested_or_patterns.fixed index 0a8e7b34dfa..8ec35ba4eea 100644 --- a/tests/ui/unnested_or_patterns.fixed +++ b/tests/ui/unnested_or_patterns.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![feature(box_patterns)] #![warn(clippy::unnested_or_patterns)] diff --git a/tests/ui/unnested_or_patterns.rs b/tests/ui/unnested_or_patterns.rs index 2c454adfe89..efdb91b2402 100644 --- a/tests/ui/unnested_or_patterns.rs +++ b/tests/ui/unnested_or_patterns.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![feature(box_patterns)] #![warn(clippy::unnested_or_patterns)] diff --git a/tests/ui/unnested_or_patterns2.fixed b/tests/ui/unnested_or_patterns2.fixed index d3539d79815..de40e936747 100644 --- a/tests/ui/unnested_or_patterns2.fixed +++ b/tests/ui/unnested_or_patterns2.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![feature(box_patterns)] #![warn(clippy::unnested_or_patterns)] diff --git a/tests/ui/unnested_or_patterns2.rs b/tests/ui/unnested_or_patterns2.rs index 9cea5cdea69..87f66d26c46 100644 --- a/tests/ui/unnested_or_patterns2.rs +++ b/tests/ui/unnested_or_patterns2.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![feature(box_patterns)] #![warn(clippy::unnested_or_patterns)] diff --git a/tests/ui/unreadable_literal.fixed b/tests/ui/unreadable_literal.fixed index 13e5feb1926..f5e87648a23 100644 --- a/tests/ui/unreadable_literal.fixed +++ b/tests/ui/unreadable_literal.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::unreadable_literal)] #![allow(unused_tuple_struct_fields)] diff --git a/tests/ui/unreadable_literal.rs b/tests/ui/unreadable_literal.rs index 82f04e7ced5..426bdf7d732 100644 --- a/tests/ui/unreadable_literal.rs +++ b/tests/ui/unreadable_literal.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::unreadable_literal)] #![allow(unused_tuple_struct_fields)] diff --git a/tests/ui/unseparated_prefix_literals.fixed b/tests/ui/unseparated_prefix_literals.fixed index f0c2ba7ccdf..b6241612d9d 100644 --- a/tests/ui/unseparated_prefix_literals.fixed +++ b/tests/ui/unseparated_prefix_literals.fixed @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build:proc_macro_derive.rs +//@run-rustfix +//@aux-build:proc_macro_derive.rs #![warn(clippy::unseparated_literal_suffix)] #![allow(dead_code)] diff --git a/tests/ui/unseparated_prefix_literals.rs b/tests/ui/unseparated_prefix_literals.rs index f44880b4147..ae583f4bde3 100644 --- a/tests/ui/unseparated_prefix_literals.rs +++ b/tests/ui/unseparated_prefix_literals.rs @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build:proc_macro_derive.rs +//@run-rustfix +//@aux-build:proc_macro_derive.rs #![warn(clippy::unseparated_literal_suffix)] #![allow(dead_code)] diff --git a/tests/ui/unused_rounding.fixed b/tests/ui/unused_rounding.fixed index f6f734c05ed..f02b55502a0 100644 --- a/tests/ui/unused_rounding.fixed +++ b/tests/ui/unused_rounding.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::unused_rounding)] fn main() { diff --git a/tests/ui/unused_rounding.rs b/tests/ui/unused_rounding.rs index a0267d8144a..c7bd4906d0b 100644 --- a/tests/ui/unused_rounding.rs +++ b/tests/ui/unused_rounding.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::unused_rounding)] fn main() { diff --git a/tests/ui/unused_unit.fixed b/tests/ui/unused_unit.fixed index 3dd640b86f0..7b8f7847dbf 100644 --- a/tests/ui/unused_unit.fixed +++ b/tests/ui/unused_unit.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix // The output for humans should just highlight the whole span without showing // the suggested replacement, but we also want to test that suggested diff --git a/tests/ui/unused_unit.rs b/tests/ui/unused_unit.rs index bddecf06fb7..fdde1ecadf0 100644 --- a/tests/ui/unused_unit.rs +++ b/tests/ui/unused_unit.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix // The output for humans should just highlight the whole span without showing // the suggested replacement, but we also want to test that suggested diff --git a/tests/ui/unwrap_or_else_default.fixed b/tests/ui/unwrap_or_else_default.fixed index 84f779569ff..59a0ca3f192 100644 --- a/tests/ui/unwrap_or_else_default.fixed +++ b/tests/ui/unwrap_or_else_default.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::unwrap_or_else_default)] #![allow(dead_code)] diff --git a/tests/ui/unwrap_or_else_default.rs b/tests/ui/unwrap_or_else_default.rs index 1735bd5808e..97cafa336ed 100644 --- a/tests/ui/unwrap_or_else_default.rs +++ b/tests/ui/unwrap_or_else_default.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::unwrap_or_else_default)] #![allow(dead_code)] diff --git a/tests/ui/use_self.fixed b/tests/ui/use_self.fixed index 3ac6217312a..89ea14759b7 100644 --- a/tests/ui/use_self.fixed +++ b/tests/ui/use_self.fixed @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build:proc_macro_derive.rs +//@run-rustfix +//@aux-build:proc_macro_derive.rs #![warn(clippy::use_self)] #![allow(dead_code, unreachable_code)] diff --git a/tests/ui/use_self.rs b/tests/ui/use_self.rs index 9dc5d1e3f9b..49e5bcb7ed9 100644 --- a/tests/ui/use_self.rs +++ b/tests/ui/use_self.rs @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build:proc_macro_derive.rs +//@run-rustfix +//@aux-build:proc_macro_derive.rs #![warn(clippy::use_self)] #![allow(dead_code, unreachable_code)] diff --git a/tests/ui/use_self_trait.fixed b/tests/ui/use_self_trait.fixed index 4e779308d02..4623aeeb0eb 100644 --- a/tests/ui/use_self_trait.fixed +++ b/tests/ui/use_self_trait.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::use_self)] #![allow(dead_code)] diff --git a/tests/ui/use_self_trait.rs b/tests/ui/use_self_trait.rs index 325dc73b21e..d7d76dd9623 100644 --- a/tests/ui/use_self_trait.rs +++ b/tests/ui/use_self_trait.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::use_self)] #![allow(dead_code)] diff --git a/tests/ui/used_underscore_binding.rs b/tests/ui/used_underscore_binding.rs index 8c29e15b145..c672eff1c27 100644 --- a/tests/ui/used_underscore_binding.rs +++ b/tests/ui/used_underscore_binding.rs @@ -1,4 +1,4 @@ -// aux-build:proc_macro_derive.rs +//@aux-build:proc_macro_derive.rs #![feature(rustc_private)] #![warn(clippy::all)] #![warn(clippy::used_underscore_binding)] diff --git a/tests/ui/useless_asref.fixed b/tests/ui/useless_asref.fixed index 38e4b9201e6..490d36ae6d6 100644 --- a/tests/ui/useless_asref.fixed +++ b/tests/ui/useless_asref.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![deny(clippy::useless_asref)] #![allow(clippy::explicit_auto_deref, clippy::uninlined_format_args)] diff --git a/tests/ui/useless_asref.rs b/tests/ui/useless_asref.rs index f1e83f9d396..f2681af924d 100644 --- a/tests/ui/useless_asref.rs +++ b/tests/ui/useless_asref.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![deny(clippy::useless_asref)] #![allow(clippy::explicit_auto_deref, clippy::uninlined_format_args)] diff --git a/tests/ui/useless_attribute.fixed b/tests/ui/useless_attribute.fixed index 871e4fb5c3a..de6660c95e6 100644 --- a/tests/ui/useless_attribute.fixed +++ b/tests/ui/useless_attribute.fixed @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build:proc_macro_derive.rs +//@run-rustfix +//@aux-build:proc_macro_derive.rs #![allow(unused)] #![warn(clippy::useless_attribute)] diff --git a/tests/ui/useless_attribute.rs b/tests/ui/useless_attribute.rs index cb50736ba39..8de4331e8a6 100644 --- a/tests/ui/useless_attribute.rs +++ b/tests/ui/useless_attribute.rs @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build:proc_macro_derive.rs +//@run-rustfix +//@aux-build:proc_macro_derive.rs #![allow(unused)] #![warn(clippy::useless_attribute)] diff --git a/tests/ui/useless_conversion.fixed b/tests/ui/useless_conversion.fixed index 94b206d8e58..01eb6c5b080 100644 --- a/tests/ui/useless_conversion.fixed +++ b/tests/ui/useless_conversion.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![deny(clippy::useless_conversion)] #![allow(clippy::unnecessary_wraps)] diff --git a/tests/ui/useless_conversion.rs b/tests/ui/useless_conversion.rs index c7ae927941b..34b43a6299b 100644 --- a/tests/ui/useless_conversion.rs +++ b/tests/ui/useless_conversion.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![deny(clippy::useless_conversion)] #![allow(clippy::unnecessary_wraps)] diff --git a/tests/ui/vec.fixed b/tests/ui/vec.fixed index 2518d804915..d77a4dd8e0b 100644 --- a/tests/ui/vec.fixed +++ b/tests/ui/vec.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::useless_vec)] #![allow(clippy::nonstandard_macro_braces, clippy::uninlined_format_args)] diff --git a/tests/ui/vec.rs b/tests/ui/vec.rs index e1492e2f3ae..dfed3a29a03 100644 --- a/tests/ui/vec.rs +++ b/tests/ui/vec.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::useless_vec)] #![allow(clippy::nonstandard_macro_braces, clippy::uninlined_format_args)] diff --git a/tests/ui/vec_box_sized.fixed b/tests/ui/vec_box_sized.fixed index a40d91fdb18..0d0f710b558 100644 --- a/tests/ui/vec_box_sized.fixed +++ b/tests/ui/vec_box_sized.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(dead_code)] diff --git a/tests/ui/vec_box_sized.rs b/tests/ui/vec_box_sized.rs index 843bbb64e71..fd3a7543ee1 100644 --- a/tests/ui/vec_box_sized.rs +++ b/tests/ui/vec_box_sized.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(dead_code)] diff --git a/tests/ui/while_let_on_iterator.fixed b/tests/ui/while_let_on_iterator.fixed index 5afa0a89f82..c2f216a8911 100644 --- a/tests/ui/while_let_on_iterator.fixed +++ b/tests/ui/while_let_on_iterator.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::while_let_on_iterator)] #![allow(dead_code, unreachable_code, unused_mut)] #![allow( diff --git a/tests/ui/while_let_on_iterator.rs b/tests/ui/while_let_on_iterator.rs index 3de586c9d8f..971bd5f0c4a 100644 --- a/tests/ui/while_let_on_iterator.rs +++ b/tests/ui/while_let_on_iterator.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![warn(clippy::while_let_on_iterator)] #![allow(dead_code, unreachable_code, unused_mut)] #![allow( diff --git a/tests/ui/wildcard_enum_match_arm.fixed b/tests/ui/wildcard_enum_match_arm.fixed index 293bf75a717..ccb40acfbe1 100644 --- a/tests/ui/wildcard_enum_match_arm.fixed +++ b/tests/ui/wildcard_enum_match_arm.fixed @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build:non-exhaustive-enum.rs +//@run-rustfix +//@aux-build:non-exhaustive-enum.rs #![deny(clippy::wildcard_enum_match_arm)] #![allow(dead_code, unreachable_code, unused_variables)] #![allow( diff --git a/tests/ui/wildcard_enum_match_arm.rs b/tests/ui/wildcard_enum_match_arm.rs index decd86165f3..3ce00b021a5 100644 --- a/tests/ui/wildcard_enum_match_arm.rs +++ b/tests/ui/wildcard_enum_match_arm.rs @@ -1,5 +1,5 @@ -// run-rustfix -// aux-build:non-exhaustive-enum.rs +//@run-rustfix +//@aux-build:non-exhaustive-enum.rs #![deny(clippy::wildcard_enum_match_arm)] #![allow(dead_code, unreachable_code, unused_variables)] #![allow( diff --git a/tests/ui/wildcard_imports.fixed b/tests/ui/wildcard_imports.fixed index 0baec6f0b64..bd845361fa8 100644 --- a/tests/ui/wildcard_imports.fixed +++ b/tests/ui/wildcard_imports.fixed @@ -1,6 +1,6 @@ -// edition:2015 -// run-rustfix -// aux-build:wildcard_imports_helper.rs +//@edition:2015 +//@run-rustfix +//@aux-build:wildcard_imports_helper.rs // the 2015 edition here is needed because edition 2018 changed the module system // (see https://doc.rust-lang.org/edition-guide/rust-2018/path-changes.html) which means the lint diff --git a/tests/ui/wildcard_imports.rs b/tests/ui/wildcard_imports.rs index db591d56ab4..fb51f7bdfcc 100644 --- a/tests/ui/wildcard_imports.rs +++ b/tests/ui/wildcard_imports.rs @@ -1,6 +1,6 @@ -// edition:2015 -// run-rustfix -// aux-build:wildcard_imports_helper.rs +//@edition:2015 +//@run-rustfix +//@aux-build:wildcard_imports_helper.rs // the 2015 edition here is needed because edition 2018 changed the module system // (see https://doc.rust-lang.org/edition-guide/rust-2018/path-changes.html) which means the lint diff --git a/tests/ui/wildcard_imports_2021.edition2018.fixed b/tests/ui/wildcard_imports_2021.edition2018.fixed index 6d534a10edc..3aea013fb3a 100644 --- a/tests/ui/wildcard_imports_2021.edition2018.fixed +++ b/tests/ui/wildcard_imports_2021.edition2018.fixed @@ -1,8 +1,8 @@ -// revisions: edition2018 edition2021 -//[edition2018] edition:2018 -//[edition2021] edition:2021 -// run-rustfix -// aux-build:wildcard_imports_helper.rs +//@revisions: edition2018 edition2021 +//@[edition2018] edition:2018 +//@[edition2021] edition:2021 +//@run-rustfix +//@aux-build:wildcard_imports_helper.rs #![warn(clippy::wildcard_imports)] #![allow(unused, clippy::unnecessary_wraps, clippy::let_unit_value)] diff --git a/tests/ui/wildcard_imports_2021.edition2021.fixed b/tests/ui/wildcard_imports_2021.edition2021.fixed index 6d534a10edc..3aea013fb3a 100644 --- a/tests/ui/wildcard_imports_2021.edition2021.fixed +++ b/tests/ui/wildcard_imports_2021.edition2021.fixed @@ -1,8 +1,8 @@ -// revisions: edition2018 edition2021 -//[edition2018] edition:2018 -//[edition2021] edition:2021 -// run-rustfix -// aux-build:wildcard_imports_helper.rs +//@revisions: edition2018 edition2021 +//@[edition2018] edition:2018 +//@[edition2021] edition:2021 +//@run-rustfix +//@aux-build:wildcard_imports_helper.rs #![warn(clippy::wildcard_imports)] #![allow(unused, clippy::unnecessary_wraps, clippy::let_unit_value)] diff --git a/tests/ui/wildcard_imports_2021.rs b/tests/ui/wildcard_imports_2021.rs index b5ed58e6813..40c2d07527d 100644 --- a/tests/ui/wildcard_imports_2021.rs +++ b/tests/ui/wildcard_imports_2021.rs @@ -1,8 +1,8 @@ -// revisions: edition2018 edition2021 -//[edition2018] edition:2018 -//[edition2021] edition:2021 -// run-rustfix -// aux-build:wildcard_imports_helper.rs +//@revisions: edition2018 edition2021 +//@[edition2018] edition:2018 +//@[edition2021] edition:2021 +//@run-rustfix +//@aux-build:wildcard_imports_helper.rs #![warn(clippy::wildcard_imports)] #![allow(unused, clippy::unnecessary_wraps, clippy::let_unit_value)] diff --git a/tests/ui/wildcard_imports_2021.stderr b/tests/ui/wildcard_imports_2021.stderr deleted file mode 100644 index 92f6d31530f..00000000000 --- a/tests/ui/wildcard_imports_2021.stderr +++ /dev/null @@ -1,132 +0,0 @@ -error: usage of wildcard import - --> $DIR/wildcard_imports_2021.rs:9:5 - | -LL | use crate::fn_mod::*; - | ^^^^^^^^^^^^^^^^ help: try: `crate::fn_mod::foo` - | - = note: `-D clippy::wildcard-imports` implied by `-D warnings` - -error: usage of wildcard import - --> $DIR/wildcard_imports_2021.rs:10:5 - | -LL | use crate::mod_mod::*; - | ^^^^^^^^^^^^^^^^^ help: try: `crate::mod_mod::inner_mod` - -error: usage of wildcard import - --> $DIR/wildcard_imports_2021.rs:11:5 - | -LL | use crate::multi_fn_mod::*; - | ^^^^^^^^^^^^^^^^^^^^^^ help: try: `crate::multi_fn_mod::{multi_bar, multi_foo, multi_inner_mod}` - -error: usage of wildcard import - --> $DIR/wildcard_imports_2021.rs:12:5 - | -LL | use crate::struct_mod::*; - | ^^^^^^^^^^^^^^^^^^^^ help: try: `crate::struct_mod::{A, inner_struct_mod}` - -error: usage of wildcard import - --> $DIR/wildcard_imports_2021.rs:15:5 - | -LL | use wildcard_imports_helper::inner::inner_for_self_import::*; - | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `wildcard_imports_helper::inner::inner_for_self_import::inner_extern_bar` - -error: usage of wildcard import - --> $DIR/wildcard_imports_2021.rs:17:5 - | -LL | use wildcard_imports_helper::*; - | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `wildcard_imports_helper::{ExternA, extern_foo}` - -error: usage of wildcard import - --> $DIR/wildcard_imports_2021.rs:87:13 - | -LL | use crate::fn_mod::*; - | ^^^^^^^^^^^^^^^^ help: try: `crate::fn_mod::foo` - -error: usage of wildcard import - --> $DIR/wildcard_imports_2021.rs:93:75 - | -LL | use wildcard_imports_helper::inner::inner_for_self_import::{self, *}; - | ^ help: try: `inner_extern_foo` - -error: usage of wildcard import - --> $DIR/wildcard_imports_2021.rs:94:13 - | -LL | use wildcard_imports_helper::*; - | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `wildcard_imports_helper::{ExternA, extern_foo}` - -error: usage of wildcard import - --> $DIR/wildcard_imports_2021.rs:105:20 - | -LL | use self::{inner::*, inner2::*}; - | ^^^^^^^^ help: try: `inner::inner_foo` - -error: usage of wildcard import - --> $DIR/wildcard_imports_2021.rs:105:30 - | -LL | use self::{inner::*, inner2::*}; - | ^^^^^^^^^ help: try: `inner2::inner_bar` - -error: usage of wildcard import - --> $DIR/wildcard_imports_2021.rs:112:13 - | -LL | use wildcard_imports_helper::*; - | ^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `wildcard_imports_helper::{ExternExportedEnum, ExternExportedStruct, extern_exported}` - -error: usage of wildcard import - --> $DIR/wildcard_imports_2021.rs:141:9 - | -LL | use crate::in_fn_test::*; - | ^^^^^^^^^^^^^^^^^^^^ help: try: `crate::in_fn_test::{ExportedEnum, ExportedStruct, exported}` - -error: usage of wildcard import - --> $DIR/wildcard_imports_2021.rs:150:9 - | -LL | use crate:: in_fn_test:: * ; - | ^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `crate:: in_fn_test::exported` - -error: usage of wildcard import - --> $DIR/wildcard_imports_2021.rs:151:9 - | -LL | use crate:: fn_mod:: - | _________^ -LL | | *; - | |_________^ help: try: `crate:: fn_mod::foo` - -error: usage of wildcard import - --> $DIR/wildcard_imports_2021.rs:162:13 - | -LL | use super::*; - | ^^^^^^^^ help: try: `super::foofoo` - -error: usage of wildcard import - --> $DIR/wildcard_imports_2021.rs:197:17 - | -LL | use super::*; - | ^^^^^^^^ help: try: `super::insidefoo` - -error: usage of wildcard import - --> $DIR/wildcard_imports_2021.rs:205:13 - | -LL | use crate::super_imports::*; - | ^^^^^^^^^^^^^^^^^^^^^^^ help: try: `crate::super_imports::foofoo` - -error: usage of wildcard import - --> $DIR/wildcard_imports_2021.rs:214:17 - | -LL | use super::super::*; - | ^^^^^^^^^^^^^^^ help: try: `super::super::foofoo` - -error: usage of wildcard import - --> $DIR/wildcard_imports_2021.rs:223:13 - | -LL | use super::super::super_imports::*; - | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^ help: try: `super::super::super_imports::foofoo` - -error: usage of wildcard import - --> $DIR/wildcard_imports_2021.rs:231:13 - | -LL | use super::*; - | ^^^^^^^^ help: try: `super::foofoo` - -error: aborting due to 21 previous errors - diff --git a/tests/ui/write_with_newline.rs b/tests/ui/write_with_newline.rs index b79364c8758..35bd9e7f3a0 100644 --- a/tests/ui/write_with_newline.rs +++ b/tests/ui/write_with_newline.rs @@ -1,5 +1,5 @@ // FIXME: Ideally these suggestions would be fixed via rustfix. Blocked by rust-lang/rust#53934 -// // run-rustfix +// #![allow(clippy::write_literal)] #![warn(clippy::write_with_newline)] @@ -54,7 +54,7 @@ fn main() { // Don't warn on CRLF (#4208) write!(v, "\r\n"); write!(v, "foo\r\n"); - write!(v, "\\r\n"); //~ ERROR + write!(v, "\\r\n"); write!(v, "foo\rbar\n"); // Ignore expanded format strings diff --git a/tests/ui/write_with_newline.stderr b/tests/ui/write_with_newline.stderr index 2baaea166d8..9035275b29d 100644 --- a/tests/ui/write_with_newline.stderr +++ b/tests/ui/write_with_newline.stderr @@ -106,13 +106,13 @@ LL ~ v error: using `write!()` with a format string that ends in a single newline --> $DIR/write_with_newline.rs:57:5 | -LL | write!(v, "/r/n"); //~ ERROR +LL | write!(v, "/r/n"); | ^^^^^^^^^^^^^^^^^^ | help: use `writeln!` instead | -LL - write!(v, "/r/n"); //~ ERROR -LL + writeln!(v, "/r"); //~ ERROR +LL - write!(v, "/r/n"); +LL + writeln!(v, "/r"); | error: aborting due to 9 previous errors diff --git a/tests/ui/writeln_empty_string.fixed b/tests/ui/writeln_empty_string.fixed index e7d94acd130..45dedd9ead6 100644 --- a/tests/ui/writeln_empty_string.fixed +++ b/tests/ui/writeln_empty_string.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused_must_use)] #![warn(clippy::writeln_empty_string)] diff --git a/tests/ui/writeln_empty_string.rs b/tests/ui/writeln_empty_string.rs index 662c62f0211..3b9f51a15d2 100644 --- a/tests/ui/writeln_empty_string.rs +++ b/tests/ui/writeln_empty_string.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![allow(unused_must_use)] #![warn(clippy::writeln_empty_string)] diff --git a/tests/ui/zero_ptr.fixed b/tests/ui/zero_ptr.fixed index 489aa4121a3..bed38ecafc7 100644 --- a/tests/ui/zero_ptr.fixed +++ b/tests/ui/zero_ptr.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix pub fn foo(_const: *const f32, _mut: *mut i64) {} fn main() { diff --git a/tests/ui/zero_ptr.rs b/tests/ui/zero_ptr.rs index c3b55ef9ebd..b7b778915a8 100644 --- a/tests/ui/zero_ptr.rs +++ b/tests/ui/zero_ptr.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix pub fn foo(_const: *const f32, _mut: *mut i64) {} fn main() { diff --git a/tests/ui/zero_ptr_no_std.fixed b/tests/ui/zero_ptr_no_std.fixed index 8906c776977..7afd80ccaca 100644 --- a/tests/ui/zero_ptr_no_std.fixed +++ b/tests/ui/zero_ptr_no_std.fixed @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![feature(lang_items, start, libc)] #![no_std] diff --git a/tests/ui/zero_ptr_no_std.rs b/tests/ui/zero_ptr_no_std.rs index 379c1b18d29..05a0587d22b 100644 --- a/tests/ui/zero_ptr_no_std.rs +++ b/tests/ui/zero_ptr_no_std.rs @@ -1,4 +1,4 @@ -// run-rustfix +//@run-rustfix #![feature(lang_items, start, libc)] #![no_std] -- cgit 1.4.1-3-g733a5 From 022baa5ce360d4d90b5ab7141ba1607112fa00a6 Mon Sep 17 00:00:00 2001 From: Alex Macleod Date: Sun, 23 Apr 2023 14:25:19 +0000 Subject: Remove check for `lib.register_*` and `src/docs*` in `cargo dev update_lints` This reverts commit 22d435b26627c1085c5b761846ca08870288794f. --- clippy_dev/src/update_lints.rs | 54 ------------------------------------------ 1 file changed, 54 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/update_lints.rs b/clippy_dev/src/update_lints.rs index dd90a38f757..7213c9dfede 100644 --- a/clippy_dev/src/update_lints.rs +++ b/clippy_dev/src/update_lints.rs @@ -36,60 +36,6 @@ pub enum UpdateMode { pub fn update(update_mode: UpdateMode) { let (lints, deprecated_lints, renamed_lints) = gather_all(); generate_lint_files(update_mode, &lints, &deprecated_lints, &renamed_lints); - remove_old_files(update_mode); -} - -/// Remove files no longer needed after -/// that may be reintroduced unintentionally -/// -/// FIXME: This is a temporary measure that should be removed when there are no more PRs that -/// include the stray files -fn remove_old_files(update_mode: UpdateMode) { - let mut failed = false; - let mut remove_file = |path: &Path| match update_mode { - UpdateMode::Check => { - if path.exists() { - failed = true; - println!("unexpected file: {}", path.display()); - } - }, - UpdateMode::Change => { - if fs::remove_file(path).is_ok() { - println!("removed file: {}", path.display()); - } - }, - }; - - let files = [ - "clippy_lints/src/lib.register_all.rs", - "clippy_lints/src/lib.register_cargo.rs", - "clippy_lints/src/lib.register_complexity.rs", - "clippy_lints/src/lib.register_correctness.rs", - "clippy_lints/src/lib.register_internal.rs", - "clippy_lints/src/lib.register_lints.rs", - "clippy_lints/src/lib.register_nursery.rs", - "clippy_lints/src/lib.register_pedantic.rs", - "clippy_lints/src/lib.register_perf.rs", - "clippy_lints/src/lib.register_restriction.rs", - "clippy_lints/src/lib.register_style.rs", - "clippy_lints/src/lib.register_suspicious.rs", - "src/docs.rs", - ]; - - for file in files { - remove_file(Path::new(file)); - } - - if let Ok(docs_dir) = fs::read_dir("src/docs") { - for doc_file in docs_dir { - let path = doc_file.unwrap().path(); - remove_file(&path); - } - } - - if failed { - exit_with_failure(); - } } fn generate_lint_files( -- cgit 1.4.1-3-g733a5 From 0f7b61d729e20fd486bb26663993f63cce5a68eb Mon Sep 17 00:00:00 2001 From: Alex Macleod Date: Fri, 5 May 2023 11:45:24 +0000 Subject: Inherit stdout/stderr for `cargo dev dogfood` --- clippy_dev/src/dogfood.rs | 8 +++----- clippy_dev/src/lib.rs | 13 +++++++++++++ clippy_dev/src/lint.rs | 17 +++-------------- 3 files changed, 19 insertions(+), 19 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/dogfood.rs b/clippy_dev/src/dogfood.rs index b69e9f649ec..a0d57f5ab48 100644 --- a/clippy_dev/src/dogfood.rs +++ b/clippy_dev/src/dogfood.rs @@ -1,4 +1,4 @@ -use crate::clippy_project_root; +use crate::{clippy_project_root, exit_if_err}; use std::process::Command; /// # Panics @@ -10,7 +10,7 @@ pub fn dogfood(fix: bool, allow_dirty: bool, allow_staged: bool) { cmd.current_dir(clippy_project_root()) .args(["test", "--test", "dogfood"]) .args(["--features", "internal"]) - .args(["--", "dogfood_clippy"]); + .args(["--", "dogfood_clippy", "--nocapture"]); let mut dogfood_args = Vec::new(); if fix { @@ -27,7 +27,5 @@ pub fn dogfood(fix: bool, allow_dirty: bool, allow_staged: bool) { cmd.env("__CLIPPY_DOGFOOD_ARGS", dogfood_args.join(" ")); - let output = cmd.output().expect("failed to run command"); - - println!("{}", String::from_utf8_lossy(&output.stdout)); + exit_if_err(cmd.status()); } diff --git a/clippy_dev/src/lib.rs b/clippy_dev/src/lib.rs index 3a8b070d735..56a269288c0 100644 --- a/clippy_dev/src/lib.rs +++ b/clippy_dev/src/lib.rs @@ -10,7 +10,9 @@ extern crate rustc_driver; extern crate rustc_lexer; +use std::io; use std::path::PathBuf; +use std::process::{self, ExitStatus}; pub mod bless; pub mod dogfood; @@ -58,3 +60,14 @@ pub fn clippy_project_root() -> PathBuf { } panic!("error: Can't determine root of project. Please run inside a Clippy working dir."); } + +pub fn exit_if_err(status: io::Result) { + match status.expect("failed to run command").code() { + Some(0) => {}, + Some(n) => process::exit(n), + None => { + eprintln!("Killed by signal"); + process::exit(1); + }, + } +} diff --git a/clippy_dev/src/lint.rs b/clippy_dev/src/lint.rs index aafd0f71a59..a19be1bca6c 100644 --- a/clippy_dev/src/lint.rs +++ b/clippy_dev/src/lint.rs @@ -1,17 +1,6 @@ -use crate::cargo_clippy_path; -use std::process::{self, Command, ExitStatus}; -use std::{fs, io}; - -fn exit_if_err(status: io::Result) { - match status.expect("failed to run command").code() { - Some(0) => {}, - Some(n) => process::exit(n), - None => { - eprintln!("Killed by signal"); - process::exit(1); - }, - } -} +use crate::{cargo_clippy_path, exit_if_err}; +use std::fs; +use std::process::{self, Command}; pub fn run<'a>(path: &str, args: impl Iterator) { let is_file = match fs::metadata(path) { -- cgit 1.4.1-3-g733a5 From a3438da42f0806225f7533f282ea32b9416c38f8 Mon Sep 17 00:00:00 2001 From: y21 <30553356+y21@users.noreply.github.com> Date: Tue, 23 May 2023 21:11:56 +0200 Subject: error out if lint name contains dash --- clippy_dev/src/main.rs | 9 ++++++++- 1 file changed, 8 insertions(+), 1 deletion(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index e2457e5a8a5..41fdbe099ae 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -180,7 +180,14 @@ fn get_clap_config() -> ArgMatches { .short('n') .long("name") .help("Name of the new lint in snake case, ex: fn_too_long") - .required(true), + .required(true) + .value_parser(|name: &str| { + if name.contains('-') { + Err("Lint name cannot contain `-`, use `_` instead.") + } else { + Ok(name.to_owned()) + } + }), Arg::new("category") .short('c') .long("category") -- cgit 1.4.1-3-g733a5 From 95b5a7bbe244eb598fe3eb0bfad9eba6dadd7172 Mon Sep 17 00:00:00 2001 From: y21 <30553356+y21@users.noreply.github.com> Date: Wed, 24 May 2023 16:10:09 +0200 Subject: replace `-` instead of erroring out --- clippy_dev/src/main.rs | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index 41fdbe099ae..99aa854bc43 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -5,6 +5,7 @@ use clap::{Arg, ArgAction, ArgMatches, Command}; use clippy_dev::{bless, dogfood, fmt, lint, new_lint, serve, setup, update_lints}; use indoc::indoc; +use std::convert::Infallible; fn main() { let matches = get_clap_config(); @@ -181,13 +182,7 @@ fn get_clap_config() -> ArgMatches { .long("name") .help("Name of the new lint in snake case, ex: fn_too_long") .required(true) - .value_parser(|name: &str| { - if name.contains('-') { - Err("Lint name cannot contain `-`, use `_` instead.") - } else { - Ok(name.to_owned()) - } - }), + .value_parser(|name: &str| Ok::<_, Infallible>(name.replace("-", "_"))), Arg::new("category") .short('c') .long("category") -- cgit 1.4.1-3-g733a5 From c70f2a2e50a44aa2c09b2179d6182588efb6804f Mon Sep 17 00:00:00 2001 From: Timo <30553356+y21@users.noreply.github.com> Date: Wed, 24 May 2023 16:45:18 +0200 Subject: apply suggestion Co-authored-by: Philipp Krones --- clippy_dev/src/main.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index 99aa854bc43..c03fbe9d275 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -182,7 +182,7 @@ fn get_clap_config() -> ArgMatches { .long("name") .help("Name of the new lint in snake case, ex: fn_too_long") .required(true) - .value_parser(|name: &str| Ok::<_, Infallible>(name.replace("-", "_"))), + .value_parser(|name: &str| Ok::<_, Infallible>(name.replace('-', "_"))), Arg::new("category") .short('c') .long("category") -- cgit 1.4.1-3-g733a5 From 46808be16f38c3c09e9b7af5d08e9b8abb7cab13 Mon Sep 17 00:00:00 2001 From: Alex Macleod Date: Thu, 8 Jun 2023 12:47:15 +0000 Subject: Direct towards late passes in `cargo dev new_lint` --- clippy_dev/src/main.rs | 4 ++-- clippy_dev/src/new_lint.rs | 12 ++++++++++-- 2 files changed, 12 insertions(+), 4 deletions(-) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index c03fbe9d275..97d6a8353a0 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -35,7 +35,7 @@ fn main() { }, Some(("new_lint", matches)) => { match new_lint::create( - matches.get_one::("pass"), + matches.get_one::("pass").unwrap(), matches.get_one::("name"), matches.get_one::("category").map(String::as_str), matches.get_one::("type").map(String::as_str), @@ -176,7 +176,7 @@ fn get_clap_config() -> ArgMatches { .help("Specify whether the lint runs during the early or late pass") .value_parser(["early", "late"]) .conflicts_with("type") - .required_unless_present("type"), + .default_value("late"), Arg::new("name") .short('n') .long("name") diff --git a/clippy_dev/src/new_lint.rs b/clippy_dev/src/new_lint.rs index 13a27703427..f970a32726b 100644 --- a/clippy_dev/src/new_lint.rs +++ b/clippy_dev/src/new_lint.rs @@ -37,7 +37,7 @@ impl Context for io::Result { /// /// This function errors out if the files couldn't be created or written to. pub fn create( - pass: Option<&String>, + pass: &String, lint_name: Option<&String>, category: Option<&str>, mut ty: Option<&str>, @@ -49,7 +49,7 @@ pub fn create( } let lint = LintData { - pass: pass.map_or("", String::as_str), + pass, name: lint_name.expect("`name` argument is validated by clap"), category: category.expect("`category` argument is validated by clap"), ty, @@ -63,6 +63,14 @@ pub fn create( add_lint(&lint, msrv).context("Unable to add lint to clippy_lints/src/lib.rs")?; } + if pass == "early" { + println!( + "\n\ + NOTE: Use a late pass unless you need something specific from\ + an early pass, as they lack many features and utilities" + ); + } + Ok(()) } -- cgit 1.4.1-3-g733a5 From aff9c01ab99dd7bb4a185df3a08e27f364fecf50 Mon Sep 17 00:00:00 2001 From: Kisaragi Marine Date: Wed, 14 Jun 2023 22:26:10 +0900 Subject: address or allow clippy::missing_panics_doc in clippy-dev --- clippy_dev/src/fmt.rs | 1 + clippy_dev/src/lib.rs | 6 ++++++ clippy_dev/src/new_lint.rs | 1 + 3 files changed, 8 insertions(+) (limited to 'clippy_dev/src') diff --git a/clippy_dev/src/fmt.rs b/clippy_dev/src/fmt.rs index 25623144181..ee559d45dd1 100644 --- a/clippy_dev/src/fmt.rs +++ b/clippy_dev/src/fmt.rs @@ -35,6 +35,7 @@ struct FmtContext { } // the "main" function of cargo dev fmt +#[allow(clippy::missing_panics_doc)] pub fn run(check: bool, verbose: bool) { fn try_run(context: &FmtContext) -> Result { let mut success = true; diff --git a/clippy_dev/src/lib.rs b/clippy_dev/src/lib.rs index 56a269288c0..8aaa029f776 100644 --- a/clippy_dev/src/lib.rs +++ b/clippy_dev/src/lib.rs @@ -29,6 +29,10 @@ static CARGO_CLIPPY_EXE: &str = "cargo-clippy"; static CARGO_CLIPPY_EXE: &str = "cargo-clippy.exe"; /// Returns the path to the `cargo-clippy` binary +/// +/// # Panics +/// +/// Panics if the path of current executable could not be retrieved. #[must_use] pub fn cargo_clippy_path() -> PathBuf { let mut path = std::env::current_exe().expect("failed to get current executable name"); @@ -61,6 +65,8 @@ pub fn clippy_project_root() -> PathBuf { panic!("error: Can't determine root of project. Please run inside a Clippy working dir."); } +/// # Panics +/// Panics if given command result was failed. pub fn exit_if_err(status: io::Result) { match status.expect("failed to run command").code() { Some(0) => {}, diff --git a/clippy_dev/src/new_lint.rs b/clippy_dev/src/new_lint.rs index f970a32726b..f0ccdb0fe10 100644 --- a/clippy_dev/src/new_lint.rs +++ b/clippy_dev/src/new_lint.rs @@ -36,6 +36,7 @@ impl Context for io::Result { /// # Errors /// /// This function errors out if the files couldn't be created or written to. +#[allow(clippy::missing_panics_doc)] pub fn create( pass: &String, lint_name: Option<&String>, -- cgit 1.4.1-3-g733a5 From 514b6d04bb63b08e76a3690973b7090b14a85799 Mon Sep 17 00:00:00 2001 From: Oli Scherer Date: Tue, 28 Feb 2023 16:12:10 +0000 Subject: Port clippy away from compiletest to ui_test --- .cargo/config.toml | 2 + Cargo.toml | 19 +- book/src/development/adding_lints.md | 17 +- book/src/development/basics.md | 2 +- clippy_dev/src/bless.rs | 60 ----- clippy_dev/src/lib.rs | 1 - clippy_dev/src/main.rs | 6 +- clippy_dev/src/new_lint.rs | 2 +- clippy_test_deps/Cargo.toml | 25 ++ clippy_test_deps/src/lib.rs | 14 ++ clippy_utils/src/lib.rs | 6 +- tests/compile-test.rs | 438 ++++++++++++----------------------- tests/missing-test-files.rs | 6 +- util/etc/vscode-tasks.json | 4 +- 14 files changed, 209 insertions(+), 393 deletions(-) delete mode 100644 clippy_dev/src/bless.rs create mode 100644 clippy_test_deps/Cargo.toml create mode 100644 clippy_test_deps/src/lib.rs (limited to 'clippy_dev/src') diff --git a/.cargo/config.toml b/.cargo/config.toml index 4d80d3ce63d..48a63e48568 100644 --- a/.cargo/config.toml +++ b/.cargo/config.toml @@ -1,5 +1,7 @@ [alias] uitest = "test --test compile-test" +uibless = "test --test compile-test -- -- --bless" +bless = "test -- -- --bless" dev = "run --package clippy_dev --bin clippy_dev --manifest-path clippy_dev/Cargo.toml --" lintcheck = "run --package lintcheck --bin lintcheck --manifest-path lintcheck/Cargo.toml -- " collect-metadata = "test --test dogfood --features internal -- run_metadata_collection_lint --ignored" diff --git a/Cargo.toml b/Cargo.toml index ca8bf9fac91..76c804f935e 100644 --- a/Cargo.toml +++ b/Cargo.toml @@ -27,27 +27,14 @@ tempfile = { version = "3.2", optional = true } termize = "0.1" [dev-dependencies] -compiletest_rs = { version = "0.10", features = ["tmp"] } +ui_test = "0.11.5" tester = "0.9" regex = "1.5" toml = "0.7.3" walkdir = "2.3" # This is used by the `collect-metadata` alias. filetime = "0.2" - -# UI test dependencies -clap = { version = "4.1.4", features = ["derive"] } -clippy_utils = { path = "clippy_utils" } -derive-new = "0.5" -if_chain = "1.0" itertools = "0.10.1" -quote = "1.0" -serde = { version = "1.0.125", features = ["derive"] } -syn = { version = "2.0", features = ["full"] } -futures = "0.3" -parking_lot = "0.12" -tokio = { version = "1", features = ["io-util"] } -rustc-semver = "1.1" [build-dependencies] rustc_tools_util = "0.3.0" @@ -60,3 +47,7 @@ internal = ["clippy_lints/internal", "tempfile"] [package.metadata.rust-analyzer] # This package uses #[feature(rustc_private)] rustc_private = true + +[[test]] +name = "compile-test" +harness = false diff --git a/book/src/development/adding_lints.md b/book/src/development/adding_lints.md index c26aa883eba..cfcb060c46e 100644 --- a/book/src/development/adding_lints.md +++ b/book/src/development/adding_lints.md @@ -122,20 +122,17 @@ fn main() { } ``` -Now we can run the test with `TESTNAME=foo_functions cargo uitest`, currently +Now we can run the test with `TESTNAME=foo_functions cargo uibless`, currently this test is meaningless though. While we are working on implementing our lint, we can keep running the UI test. -That allows us to check if the output is turning into what we want. +That allows us to check if the output is turning into what we want by checking the +`.stderr` file that gets updated on every test run. -Once we are satisfied with the output, we need to run `cargo dev bless` to -update the `.stderr` file for our lint. Please note that, we should run -`TESTNAME=foo_functions cargo uitest` every time before running `cargo dev -bless`. Running `TESTNAME=foo_functions cargo uitest` should pass then. When we +Running `TESTNAME=foo_functions cargo uitest` should pass on its own. When we commit our lint, we need to commit the generated `.stderr` files, too. In -general, you should only commit files changed by `cargo dev bless` for the -specific lint you are creating/editing. Note that if the generated files are -empty, they should be removed. +general, you should only commit files changed by `cargo bless` for the +specific lint you are creating/editing. > _Note:_ you can run multiple test files by specifying a comma separated list: > `TESTNAME=foo_functions,test2,test3`. @@ -169,7 +166,7 @@ additionally run [rustfix] for that test. Rustfix will apply the suggestions from the lint to the code of the test file and compare that to the contents of a `.fixed` file. -Use `cargo dev bless` to automatically generate the `.fixed` file after running +Use `cargo bless` to automatically generate the `.fixed` file while running the tests. [rustfix]: https://github.com/rust-lang/rustfix diff --git a/book/src/development/basics.md b/book/src/development/basics.md index 7615dc12f9e..f4c109ff119 100644 --- a/book/src/development/basics.md +++ b/book/src/development/basics.md @@ -66,7 +66,7 @@ If the output of a [UI test] differs from the expected output, you can update the reference file with: ```bash -cargo dev bless +cargo bless ``` For example, this is necessary if you fix a typo in an error message of a lint, diff --git a/clippy_dev/src/bless.rs b/clippy_dev/src/bless.rs deleted file mode 100644 index 92b2771f3fe..00000000000 --- a/clippy_dev/src/bless.rs +++ /dev/null @@ -1,60 +0,0 @@ -//! `bless` updates the reference files in the repo with changed output files -//! from the last test run. - -use crate::cargo_clippy_path; -use std::ffi::OsStr; -use std::fs; -use std::path::{Path, PathBuf}; -use std::sync::LazyLock; -use walkdir::{DirEntry, WalkDir}; - -static CLIPPY_BUILD_TIME: LazyLock> = - LazyLock::new(|| cargo_clippy_path().metadata().ok()?.modified().ok()); - -/// # Panics -/// -/// Panics if the path to a test file is broken -pub fn bless(ignore_timestamp: bool) { - let extensions = ["stdout", "stderr", "fixed"].map(OsStr::new); - - WalkDir::new(build_dir()) - .into_iter() - .map(Result::unwrap) - .filter(|entry| entry.path().extension().map_or(false, |ext| extensions.contains(&ext))) - .for_each(|entry| update_reference_file(&entry, ignore_timestamp)); -} - -fn update_reference_file(test_output_entry: &DirEntry, ignore_timestamp: bool) { - let test_output_path = test_output_entry.path(); - - let reference_file_name = test_output_entry.file_name().to_str().unwrap().replace(".stage-id", ""); - let reference_file_path = Path::new("tests") - .join(test_output_path.strip_prefix(build_dir()).unwrap()) - .with_file_name(reference_file_name); - - // If the test output was not updated since the last clippy build, it may be outdated - if !ignore_timestamp && !updated_since_clippy_build(test_output_entry).unwrap_or(true) { - return; - } - - let test_output_file = fs::read(test_output_path).expect("Unable to read test output file"); - let reference_file = fs::read(&reference_file_path).unwrap_or_default(); - - if test_output_file != reference_file { - // If a test run caused an output file to change, update the reference file - println!("updating {}", reference_file_path.display()); - fs::copy(test_output_path, &reference_file_path).expect("Could not update reference file"); - } -} - -fn updated_since_clippy_build(entry: &DirEntry) -> Option { - let clippy_build_time = (*CLIPPY_BUILD_TIME)?; - let modified = entry.metadata().ok()?.modified().ok()?; - Some(modified >= clippy_build_time) -} - -fn build_dir() -> PathBuf { - let mut path = std::env::current_exe().unwrap(); - path.set_file_name("test"); - path -} diff --git a/clippy_dev/src/lib.rs b/clippy_dev/src/lib.rs index 8aaa029f776..4624451cff4 100644 --- a/clippy_dev/src/lib.rs +++ b/clippy_dev/src/lib.rs @@ -14,7 +14,6 @@ use std::io; use std::path::PathBuf; use std::process::{self, ExitStatus}; -pub mod bless; pub mod dogfood; pub mod fmt; pub mod lint; diff --git a/clippy_dev/src/main.rs b/clippy_dev/src/main.rs index 97d6a8353a0..43eaccdf5a3 100644 --- a/clippy_dev/src/main.rs +++ b/clippy_dev/src/main.rs @@ -3,7 +3,7 @@ #![warn(rust_2018_idioms, unused_lifetimes)] use clap::{Arg, ArgAction, ArgMatches, Command}; -use clippy_dev::{bless, dogfood, fmt, lint, new_lint, serve, setup, update_lints}; +use clippy_dev::{dogfood, fmt, lint, new_lint, serve, setup, update_lints}; use indoc::indoc; use std::convert::Infallible; @@ -11,8 +11,8 @@ fn main() { let matches = get_clap_config(); match matches.subcommand() { - Some(("bless", matches)) => { - bless::bless(matches.get_flag("ignore-timestamp")); + Some(("bless", _)) => { + eprintln!("use `cargo bless` to automatically replace `.stderr` and `.fixed` files as tests are being run"); }, Some(("dogfood", matches)) => { dogfood::dogfood( diff --git a/clippy_dev/src/new_lint.rs b/clippy_dev/src/new_lint.rs index f0ccdb0fe10..f11aa547bd7 100644 --- a/clippy_dev/src/new_lint.rs +++ b/clippy_dev/src/new_lint.rs @@ -96,7 +96,7 @@ fn create_test(lint: &LintData<'_>) -> io::Result<()> { path.push("src"); fs::create_dir(&path)?; - let header = format!("// compile-flags: --crate-name={lint_name}"); + let header = format!("//@compile-flags: --crate-name={lint_name}"); write_file(path.join("main.rs"), get_test_file_contents(lint_name, Some(&header)))?; Ok(()) diff --git a/clippy_test_deps/Cargo.toml b/clippy_test_deps/Cargo.toml new file mode 100644 index 00000000000..6d053253fc3 --- /dev/null +++ b/clippy_test_deps/Cargo.toml @@ -0,0 +1,25 @@ +[package] +name = "clippy_test_deps" +version = "0.1.0" +edition = "2021" + +# See more keys and their definitions at https://doc.rust-lang.org/cargo/reference/manifest.html + +[dependencies] +clap = { version = "4.1.4", features = ["derive"] } +clippy_utils = { path = "../clippy_utils" } +derive-new = "0.5" +if_chain = "1.0" +itertools = "0.10.1" +quote = "1.0" +serde = { version = "1.0.125", features = ["derive"] } +syn = { version = "2.0", features = ["full"] } +futures = "0.3" +parking_lot = "0.12" +tokio = { version = "1", features = ["io-util"] } +rustc-semver = "1.1" +regex = "1.5" +clippy_lints = { path = "../clippy_lints" } + +[features] +internal = ["clippy_lints/internal"] diff --git a/clippy_test_deps/src/lib.rs b/clippy_test_deps/src/lib.rs new file mode 100644 index 00000000000..7d12d9af819 --- /dev/null +++ b/clippy_test_deps/src/lib.rs @@ -0,0 +1,14 @@ +pub fn add(left: usize, right: usize) -> usize { + left + right +} + +#[cfg(test)] +mod tests { + use super::*; + + #[test] + fn it_works() { + let result = add(2, 2); + assert_eq!(result, 4); + } +} diff --git a/clippy_utils/src/lib.rs b/clippy_utils/src/lib.rs index 5b5e9fba6af..078dcef1927 100644 --- a/clippy_utils/src/lib.rs +++ b/clippy_utils/src/lib.rs @@ -2397,7 +2397,7 @@ fn with_test_item_names(tcx: TyCtxt<'_>, module: LocalDefId, f: impl Fn(&[Symbol /// Checks if the function containing the given `HirId` is a `#[test]` function /// -/// Note: Add `// compile-flags: --test` to UI tests with a `#[test]` function +/// Note: Add `//@compile-flags: --test` to UI tests with a `#[test]` function pub fn is_in_test_function(tcx: TyCtxt<'_>, id: hir::HirId) -> bool { with_test_item_names(tcx, tcx.parent_module(id), |names| { tcx.hir() @@ -2419,7 +2419,7 @@ pub fn is_in_test_function(tcx: TyCtxt<'_>, id: hir::HirId) -> bool { /// Checks if the item containing the given `HirId` has `#[cfg(test)]` attribute applied /// -/// Note: Add `// compile-flags: --test` to UI tests with a `#[cfg(test)]` function +/// Note: Add `//@compile-flags: --test` to UI tests with a `#[cfg(test)]` function pub fn is_in_cfg_test(tcx: TyCtxt<'_>, id: hir::HirId) -> bool { fn is_cfg_test(attr: &Attribute) -> bool { if attr.has_name(sym::cfg) @@ -2441,7 +2441,7 @@ pub fn is_in_cfg_test(tcx: TyCtxt<'_>, id: hir::HirId) -> bool { /// Checks whether item either has `test` attribute applied, or /// is a module with `test` in its name. /// -/// Note: Add `// compile-flags: --test` to UI tests with a `#[test]` function +/// Note: Add `//@compile-flags: --test` to UI tests with a `#[test]` function pub fn is_test_module_or_function(tcx: TyCtxt<'_>, item: &Item<'_>) -> bool { is_in_test_function(tcx, item.hir_id()) || matches!(item.kind, ItemKind::Mod(..)) diff --git a/tests/compile-test.rs b/tests/compile-test.rs index 35d75cc51c2..281e778ada6 100644 --- a/tests/compile-test.rs +++ b/tests/compile-test.rs @@ -4,16 +4,14 @@ #![cfg_attr(feature = "deny-warnings", deny(warnings))] #![warn(rust_2018_idioms, unused_lifetimes)] -use compiletest_rs as compiletest; -use compiletest_rs::common::Mode as TestMode; +use compiletest::{status_emitter, CommandBuilder}; +use ui_test as compiletest; +use ui_test::Mode as TestMode; -use std::collections::HashMap; use std::env::{self, remove_var, set_var, var_os}; use std::ffi::{OsStr, OsString}; use std::fs; -use std::io; use std::path::{Path, PathBuf}; -use std::sync::LazyLock; use test_utils::IS_RUSTC_TEST_SUITE; mod test_utils; @@ -21,143 +19,41 @@ mod test_utils; // whether to run internal tests or not const RUN_INTERNAL_TESTS: bool = cfg!(feature = "internal"); -/// All crates used in UI tests are listed here -static TEST_DEPENDENCIES: &[&str] = &[ - "clippy_lints", - "clippy_utils", - "derive_new", - "futures", - "if_chain", - "itertools", - "quote", - "regex", - "serde", - "serde_derive", - "syn", - "tokio", - "parking_lot", - "rustc_semver", -]; - -// Test dependencies may need an `extern crate` here to ensure that they show up -// in the depinfo file (otherwise cargo thinks they are unused) -#[allow(unused_extern_crates)] -extern crate clippy_lints; -#[allow(unused_extern_crates)] -extern crate clippy_utils; -#[allow(unused_extern_crates)] -extern crate derive_new; -#[allow(unused_extern_crates)] -extern crate futures; -#[allow(unused_extern_crates)] -extern crate if_chain; -#[allow(unused_extern_crates)] -extern crate itertools; -#[allow(unused_extern_crates)] -extern crate parking_lot; -#[allow(unused_extern_crates)] -extern crate quote; -#[allow(unused_extern_crates)] -extern crate rustc_semver; -#[allow(unused_extern_crates)] -extern crate syn; -#[allow(unused_extern_crates)] -extern crate tokio; - -/// Produces a string with an `--extern` flag for all UI test crate -/// dependencies. -/// -/// The dependency files are located by parsing the depinfo file for this test -/// module. This assumes the `-Z binary-dep-depinfo` flag is enabled. All test -/// dependencies must be added to Cargo.toml at the project root. Test -/// dependencies that are not *directly* used by this test module require an -/// `extern crate` declaration. -static EXTERN_FLAGS: LazyLock = LazyLock::new(|| { - let current_exe_depinfo = { - let mut path = env::current_exe().unwrap(); - path.set_extension("d"); - fs::read_to_string(path).unwrap() - }; - let mut crates: HashMap<&str, &str> = HashMap::with_capacity(TEST_DEPENDENCIES.len()); - for line in current_exe_depinfo.lines() { - // each dependency is expected to have a Makefile rule like `/path/to/crate-hash.rlib:` - let parse_name_path = || { - if line.starts_with(char::is_whitespace) { - return None; - } - let path_str = line.strip_suffix(':')?; - let path = Path::new(path_str); - if !matches!(path.extension()?.to_str()?, "rlib" | "so" | "dylib" | "dll") { - return None; - } - let (name, _hash) = path.file_stem()?.to_str()?.rsplit_once('-')?; - // the "lib" prefix is not present for dll files - let name = name.strip_prefix("lib").unwrap_or(name); - Some((name, path_str)) - }; - if let Some((name, path)) = parse_name_path() { - if TEST_DEPENDENCIES.contains(&name) { - // A dependency may be listed twice if it is available in sysroot, - // and the sysroot dependencies are listed first. As of the writing, - // this only seems to apply to if_chain. - crates.insert(name, path); - } - } - } - let not_found: Vec<&str> = TEST_DEPENDENCIES - .iter() - .copied() - .filter(|n| !crates.contains_key(n)) - .collect(); - assert!( - not_found.is_empty(), - "dependencies not found in depinfo: {not_found:?}\n\ - help: Make sure the `-Z binary-dep-depinfo` rust flag is enabled\n\ - help: Try adding to dev-dependencies in Cargo.toml\n\ - help: Be sure to also add `extern crate ...;` to tests/compile-test.rs", - ); - crates - .into_iter() - .map(|(name, path)| format!(" --extern {name}={path}")) - .collect() -}); - fn base_config(test_dir: &str) -> compiletest::Config { let mut config = compiletest::Config { - edition: Some("2021".into()), - mode: TestMode::Ui, - strict_headers: true, - ..Default::default() + mode: TestMode::Yolo, + stderr_filters: vec![], + stdout_filters: vec![], + output_conflict_handling: if std::env::args().any(|arg| arg == "--bless") { + compiletest::OutputConflictHandling::Bless + } else { + compiletest::OutputConflictHandling::Error("cargo test -- -- --bless".into()) + }, + dependencies_crate_manifest_path: Some("clippy_test_deps/Cargo.toml".into()), + target: None, + out_dir: "target/ui_test".into(), + ..compiletest::Config::rustc(Path::new("tests").join(test_dir)) }; - if let Ok(filters) = env::var("TESTNAME") { - config.filters = filters.split(',').map(ToString::to_string).collect(); - } - - if let Some(path) = option_env!("RUSTC_LIB_PATH") { - let path = PathBuf::from(path); - config.run_lib_path = path.clone(); - config.compile_lib_path = path; + if let Some(_path) = option_env!("RUSTC_LIB_PATH") { + //let path = PathBuf::from(path); + //config.run_lib_path = path.clone(); + //config.compile_lib_path = path; } let current_exe_path = env::current_exe().unwrap(); let deps_path = current_exe_path.parent().unwrap(); let profile_path = deps_path.parent().unwrap(); - // Using `-L dependency={}` enforces that external dependencies are added with `--extern`. - // This is valuable because a) it allows us to monitor what external dependencies are used - // and b) it ensures that conflicting rlibs are resolved properly. - let host_libs = option_env!("HOST_LIBS") - .map(|p| format!(" -L dependency={}", Path::new(p).join("deps").display())) - .unwrap_or_default(); - config.target_rustcflags = Some(format!( - "--emit=metadata -Dwarnings -Zui-testing -L dependency={}{host_libs}{}", - deps_path.display(), - &*EXTERN_FLAGS, - )); - - config.src_base = Path::new("tests").join(test_dir); - config.build_base = profile_path.join("test").join(test_dir); - config.rustc_path = profile_path.join(if cfg!(windows) { + config.program.args.push("--emit=metadata".into()); + config.program.args.push("-Aunused".into()); + config.program.args.push("-Zui-testing".into()); + config.program.args.push("-Dwarnings".into()); + + // Normalize away slashes in windows paths. + config.stderr_filter(r#"\\"#, "/"); + + //config.build_base = profile_path.join("test").join(test_dir); + config.program.program = profile_path.join(if cfg!(windows) { "clippy-driver.exe" } else { "clippy-driver" @@ -165,9 +61,23 @@ fn base_config(test_dir: &str) -> compiletest::Config { config } +fn test_filter() -> Box bool> { + if let Ok(filters) = env::var("TESTNAME") { + let filters: Vec<_> = filters.split(',').map(ToString::to_string).collect(); + Box::new(move |path| { + filters.is_empty() + || filters + .iter() + .any(|f| path.file_stem().map_or(false, |stem| stem == f.as_str())) + }) + } else { + Box::new(|_| true) + } +} + fn run_ui() { - let mut config = base_config("ui"); - config.rustfix_coverage = true; + let config = base_config("ui"); + //config.rustfix_coverage = true; // use tests/clippy.toml let _g = VarGuard::set("CARGO_MANIFEST_DIR", fs::canonicalize("tests").unwrap()); let _threads = VarGuard::set( @@ -179,7 +89,19 @@ fn run_ui() { .to_string() }), ); - compiletest::run_tests(&config); + eprintln!(" Compiler: {}", config.program.display()); + + let name = config.root_dir.display().to_string(); + + let test_filter = test_filter(); + + compiletest::run_tests_generic( + config, + move |path| compiletest::default_file_filter(path) && test_filter(path), + compiletest::default_per_file_config, + (status_emitter::Text, status_emitter::Gha:: { name }), + ) + .unwrap(); check_rustfix_coverage(); } @@ -188,177 +110,114 @@ fn run_internal_tests() { if !RUN_INTERNAL_TESTS { return; } - let config = base_config("ui-internal"); - compiletest::run_tests(&config); + let mut config = base_config("ui-internal"); + config.dependency_builder.args.push("--features".into()); + config.dependency_builder.args.push("internal".into()); + compiletest::run_tests(config).unwrap(); } fn run_ui_toml() { - fn run_tests(config: &compiletest::Config, mut tests: Vec) -> Result { - let mut result = true; - let opts = compiletest::test_opts(config); - for dir in fs::read_dir(&config.src_base)? { - let dir = dir?; - if !dir.file_type()?.is_dir() { - continue; - } - let dir_path = dir.path(); - let _g = VarGuard::set("CARGO_MANIFEST_DIR", &dir_path); - for file in fs::read_dir(&dir_path)? { - let file = file?; - let file_path = file.path(); - if file.file_type()?.is_dir() { - continue; - } - if file_path.extension() != Some(OsStr::new("rs")) { - continue; - } - let paths = compiletest::common::TestPaths { - file: file_path, - base: config.src_base.clone(), - relative_dir: dir_path.file_name().unwrap().into(), - }; - let test_name = compiletest::make_test_name(config, &paths); - let index = tests - .iter() - .position(|test| test.desc.name == test_name) - .expect("The test should be in there"); - result &= tester::run_tests_console(&opts, vec![tests.swap_remove(index)])?; - } - } - Ok(result) - } - let mut config = base_config("ui-toml"); - config.src_base = config.src_base.canonicalize().unwrap(); - let tests = compiletest::make_tests(&config); + config.stderr_filter( + ®ex::escape( + &std::path::Path::new(file!()) + .parent() + .unwrap() + .canonicalize() + .unwrap() + .parent() + .unwrap() + .display() + .to_string() + .replace('\\', "/"), + ), + "$$DIR", + ); + + let name = config.root_dir.display().to_string(); - let res = run_tests(&config, tests); - match res { - Ok(true) => {}, - Ok(false) => panic!("Some tests failed"), - Err(e) => { - panic!("I/O failure during tests: {e:?}"); + let test_filter = test_filter(); + + ui_test::run_tests_generic( + config, + |path| test_filter(path) && path.extension() == Some("rs".as_ref()), + |config, path| { + let mut config = config.clone(); + config + .program + .envs + .push(("CLIPPY_CONF_DIR".into(), Some(path.parent().unwrap().into()))); + Some(config) }, - } + (status_emitter::Text, status_emitter::Gha:: { name }), + ) + .unwrap(); } fn run_ui_cargo() { - fn run_tests( - config: &compiletest::Config, - filters: &[String], - mut tests: Vec, - ) -> Result { - let mut result = true; - let opts = compiletest::test_opts(config); - - for dir in fs::read_dir(&config.src_base)? { - let dir = dir?; - if !dir.file_type()?.is_dir() { - continue; - } - - // Use the filter if provided - let dir_path = dir.path(); - for filter in filters { - if !dir_path.ends_with(filter) { - continue; - } - } - - for case in fs::read_dir(&dir_path)? { - let case = case?; - if !case.file_type()?.is_dir() { - continue; - } - - let src_path = case.path().join("src"); - - // When switching between branches, if the previous branch had a test - // that the current branch does not have, the directory is not removed - // because an ignored Cargo.lock file exists. - if !src_path.exists() { - continue; - } - - env::set_current_dir(&src_path)?; - - let cargo_toml_path = case.path().join("Cargo.toml"); - let cargo_content = fs::read(cargo_toml_path)?; - let cargo_parsed: toml::Value = toml::from_str( - std::str::from_utf8(&cargo_content).expect("`Cargo.toml` is not a valid utf-8 file!"), - ) - .expect("Can't parse `Cargo.toml`"); - - let _g = VarGuard::set("CARGO_MANIFEST_DIR", case.path()); - let _h = VarGuard::set( - "CARGO_PKG_RUST_VERSION", - cargo_parsed - .get("package") - .and_then(|p| p.get("rust-version")) - .and_then(toml::Value::as_str) - .unwrap_or(""), - ); - - for file in fs::read_dir(&src_path)? { - let file = file?; - if file.file_type()?.is_dir() { - continue; - } - - // Search for the main file to avoid running a test for each file in the project - let file_path = file.path(); - match file_path.file_name().and_then(OsStr::to_str) { - Some("main.rs") => {}, - _ => continue, - } - let _g = VarGuard::set("CLIPPY_CONF_DIR", case.path()); - let paths = compiletest::common::TestPaths { - file: file_path, - base: config.src_base.clone(), - relative_dir: src_path.strip_prefix(&config.src_base).unwrap().into(), - }; - let test_name = compiletest::make_test_name(config, &paths); - let index = tests - .iter() - .position(|test| test.desc.name == test_name) - .expect("The test should be in there"); - result &= tester::run_tests_console(&opts, vec![tests.swap_remove(index)])?; - } - } - } - Ok(result) - } - if IS_RUSTC_TEST_SUITE { return; } let mut config = base_config("ui-cargo"); - config.src_base = config.src_base.canonicalize().unwrap(); + config.program = CommandBuilder::cargo(); + config.program.args = vec!["clippy".into(), "--color".into(), "never".into(), "--quiet".into()]; + config + .program + .envs + .push(("RUSTFLAGS".into(), Some("-Dwarnings".into()))); + // We need to do this while we still have a rustc in the `program` field. + config.fill_host_and_target().unwrap(); + config.dependencies_crate_manifest_path = None; + config.program.program.set_file_name(if cfg!(windows) { + "cargo-clippy.exe" + } else { + "cargo-clippy" + }); + config.edition = None; - let tests = compiletest::make_tests(&config); + config.stderr_filter( + ®ex::escape( + &std::path::Path::new(file!()) + .parent() + .unwrap() + .canonicalize() + .unwrap() + .parent() + .unwrap() + .display() + .to_string() + .replace('\\', "/"), + ), + "$$DIR", + ); + + let name = config.root_dir.display().to_string(); - let current_dir = env::current_dir().unwrap(); - let res = run_tests(&config, &config.filters, tests); - env::set_current_dir(current_dir).unwrap(); + let test_filter = test_filter(); - match res { - Ok(true) => {}, - Ok(false) => panic!("Some tests failed"), - Err(e) => { - panic!("I/O failure during tests: {e:?}"); + ui_test::run_tests_generic( + config, + |path| test_filter(path) && path.ends_with("Cargo.toml"), + |config, path| { + let mut config = config.clone(); + config.out_dir = PathBuf::from("target/ui_test_cargo/").join(path.parent().unwrap()); + Some(config) }, - } + (status_emitter::Text, status_emitter::Gha:: { name }), + ) + .unwrap(); } -#[test] -fn compile_test() { +fn main() { set_var("CLIPPY_DISABLE_DOCS_LINKS", "true"); run_ui(); run_ui_toml(); run_ui_cargo(); run_internal_tests(); + rustfix_coverage_known_exceptions_accuracy(); + ui_cargo_toml_metadata(); } const RUSTFIX_COVERAGE_KNOWN_EXCEPTIONS: &[&str] = &[ @@ -384,7 +243,6 @@ const RUSTFIX_COVERAGE_KNOWN_EXCEPTIONS: &[&str] = &[ "needless_for_each_unfixable.rs", "nonminimal_bool.rs", "print_literal.rs", - "print_with_newline.rs", "redundant_static_lifetimes_multiple.rs", "ref_binding_to_reference.rs", "repl_uninit.rs", @@ -399,7 +257,6 @@ const RUSTFIX_COVERAGE_KNOWN_EXCEPTIONS: &[&str] = &[ "unnecessary_lazy_eval_unfixable.rs", "write_literal.rs", "write_literal_2.rs", - "write_with_newline.rs", ]; fn check_rustfix_coverage() { @@ -432,25 +289,16 @@ fn check_rustfix_coverage() { } } -#[test] fn rustfix_coverage_known_exceptions_accuracy() { for filename in RUSTFIX_COVERAGE_KNOWN_EXCEPTIONS { let rs_path = Path::new("tests/ui").join(filename); - assert!( - rs_path.exists(), - "`{}` does not exist", - rs_path.strip_prefix(env!("CARGO_MANIFEST_DIR")).unwrap().display() - ); + assert!(rs_path.exists(), "`{}` does not exist", rs_path.display()); let fixed_path = rs_path.with_extension("fixed"); - assert!( - !fixed_path.exists(), - "`{}` exists", - fixed_path.strip_prefix(env!("CARGO_MANIFEST_DIR")).unwrap().display() - ); + println!("{}", fixed_path.display()); + assert!(!fixed_path.exists(), "`{}` exists", fixed_path.display()); } } -#[test] fn ui_cargo_toml_metadata() { let ui_cargo_path = Path::new("tests/ui-cargo"); let cargo_common_metadata_path = ui_cargo_path.join("cargo_common_metadata"); diff --git a/tests/missing-test-files.rs b/tests/missing-test-files.rs index caedd5d76cd..0d35a22cd9a 100644 --- a/tests/missing-test-files.rs +++ b/tests/missing-test-files.rs @@ -41,8 +41,8 @@ fn explore_directory(dir: &Path) -> Vec { x.path().extension().and_then(OsStr::to_str), y.path().extension().and_then(OsStr::to_str), ) { - (Some("rs"), _) => Ordering::Less, - (_, Some("rs")) => Ordering::Greater, + (Some("rs" | "toml"), _) => Ordering::Less, + (_, Some("rs" | "toml")) => Ordering::Greater, _ => Ordering::Equal, } }); @@ -54,7 +54,7 @@ fn explore_directory(dir: &Path) -> Vec { let file_prefix = path.file_prefix().unwrap().to_str().unwrap().to_string(); if let Some(ext) = path.extension() { match ext.to_str().unwrap() { - "rs" => current_file = file_prefix.clone(), + "rs" | "toml" => current_file = file_prefix.clone(), "stderr" | "stdout" => { if file_prefix != current_file { missing_files.push(path.to_str().unwrap().to_string()); diff --git a/util/etc/vscode-tasks.json b/util/etc/vscode-tasks.json index ab98f9b4154..38e31b337a0 100644 --- a/util/etc/vscode-tasks.json +++ b/util/etc/vscode-tasks.json @@ -47,9 +47,9 @@ "group": "test" }, { - "label": "cargo dev bless", + "label": "bless ui tests", "type": "shell", - "command": "cargo dev bless", + "command": "cargo bless", "problemMatcher": [], "group": "none" } -- cgit 1.4.1-3-g733a5