diff options
| author | flip1995 <hello@philkrones.com> | 2020-04-02 22:08:10 +0200 |
|---|---|---|
| committer | flip1995 <hello@philkrones.com> | 2020-04-03 21:19:33 +0200 |
| commit | d89bb50f72e1db538d6ae18023c0edb746b119f9 (patch) | |
| tree | bf9b77d21ce55c02dce54d23e3b02d7d765042c8 /clippy_dev/src | |
| parent | a186d9fafd7424feab7b5bde044219a0e8e58c9f (diff) | |
Make lint modules private
Diffstat (limited to 'clippy_dev/src')
| -rw-r--r-- | clippy_dev/src/lib.rs | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/clippy_dev/src/lib.rs b/clippy_dev/src/lib.rs index 10056e8f03e..1f8510f43a6 100644 --- a/clippy_dev/src/lib.rs +++ b/clippy_dev/src/lib.rs @@ -105,7 +105,7 @@ pub fn gen_modules_list<'a>(lints: impl Iterator<Item = &'a Lint>) -> Vec<String lints .map(|l| &l.module) .unique() - .map(|module| format!("pub mod {};", module)) + .map(|module| format!("mod {};", module)) .sorted() .collect::<Vec<String>>() } @@ -503,10 +503,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![ - "pub mod another_module;".to_string(), - "pub mod module_name;".to_string(), - ]; + let expected = vec!["mod another_module;".to_string(), "mod module_name;".to_string()]; assert_eq!(expected, gen_modules_list(lints.iter())); } |
