We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent de36d42 commit 3bdc691Copy full SHA for 3bdc691
clippy_dev/src/lib.rs
@@ -58,10 +58,10 @@ impl Lint {
58
}
59
60
pub fn gather_all() -> impl Iterator<Item=Lint> {
61
- lint_files().flat_map(gather_from_file)
+ lint_files().flat_map(|f| gather_from_file(&f))
62
63
64
-fn gather_from_file(dir_entry: fs::DirEntry) -> impl Iterator<Item=Lint> {
+fn gather_from_file(dir_entry: &fs::DirEntry) -> impl Iterator<Item=Lint> {
65
let mut file = fs::File::open(dir_entry.path()).unwrap();
66
let mut content = String::new();
67
file.read_to_string(&mut content).unwrap();
0 commit comments