diff options
author | Aleksey Kladov <[email protected]> | 2021-03-08 18:25:44 +0000 |
---|---|---|
committer | Aleksey Kladov <[email protected]> | 2021-03-08 18:45:43 +0000 |
commit | 095b9110b5e4e166c86501a1f0603cf626a48127 (patch) | |
tree | 681c69a7341c95a19de7d606be8d17c4136d29fb /xtask/src | |
parent | 1eb61203b725684fd2c7e25ac7e2d53eef10c64c (diff) |
Unused params
Diffstat (limited to 'xtask/src')
-rw-r--r-- | xtask/src/codegen.rs | 6 | ||||
-rw-r--r-- | xtask/src/codegen/gen_assists_docs.rs | 4 | ||||
-rw-r--r-- | xtask/src/codegen/gen_diagnostic_docs.rs | 4 | ||||
-rw-r--r-- | xtask/src/codegen/gen_feature_docs.rs | 4 | ||||
-rw-r--r-- | xtask/src/tidy.rs | 2 |
5 files changed, 10 insertions, 10 deletions
diff --git a/xtask/src/codegen.rs b/xtask/src/codegen.rs index 7cdd8f251..2248a079f 100644 --- a/xtask/src/codegen.rs +++ b/xtask/src/codegen.rs | |||
@@ -27,9 +27,9 @@ pub(crate) use self::{ | |||
27 | 27 | ||
28 | pub(crate) fn docs() -> Result<()> { | 28 | pub(crate) fn docs() -> Result<()> { |
29 | // We don't commit docs to the repo, so we can just overwrite them. | 29 | // We don't commit docs to the repo, so we can just overwrite them. |
30 | gen_assists_docs::generate_assists_docs(Mode::Overwrite)?; | 30 | gen_assists_docs::generate_assists_docs()?; |
31 | gen_feature_docs::generate_feature_docs(Mode::Overwrite)?; | 31 | gen_feature_docs::generate_feature_docs()?; |
32 | gen_diagnostic_docs::generate_diagnostic_docs(Mode::Overwrite)?; | 32 | gen_diagnostic_docs::generate_diagnostic_docs()?; |
33 | Ok(()) | 33 | Ok(()) |
34 | } | 34 | } |
35 | 35 | ||
diff --git a/xtask/src/codegen/gen_assists_docs.rs b/xtask/src/codegen/gen_assists_docs.rs index c469b388d..a5af1331d 100644 --- a/xtask/src/codegen/gen_assists_docs.rs +++ b/xtask/src/codegen/gen_assists_docs.rs | |||
@@ -12,12 +12,12 @@ pub(crate) fn generate_assists_tests(mode: Mode) -> Result<()> { | |||
12 | generate_tests(&assists, mode) | 12 | generate_tests(&assists, mode) |
13 | } | 13 | } |
14 | 14 | ||
15 | pub(crate) fn generate_assists_docs(mode: Mode) -> Result<()> { | 15 | pub(crate) fn generate_assists_docs() -> Result<()> { |
16 | let assists = Assist::collect()?; | 16 | let assists = Assist::collect()?; |
17 | let contents = assists.into_iter().map(|it| it.to_string()).collect::<Vec<_>>().join("\n\n"); | 17 | let contents = assists.into_iter().map(|it| it.to_string()).collect::<Vec<_>>().join("\n\n"); |
18 | let contents = format!("//{}\n{}\n", PREAMBLE, contents.trim()); | 18 | let contents = format!("//{}\n{}\n", PREAMBLE, contents.trim()); |
19 | let dst = project_root().join("docs/user/generated_assists.adoc"); | 19 | let dst = project_root().join("docs/user/generated_assists.adoc"); |
20 | codegen::update(&dst, &contents, mode) | 20 | codegen::update(&dst, &contents, Mode::Overwrite) |
21 | } | 21 | } |
22 | 22 | ||
23 | #[derive(Debug)] | 23 | #[derive(Debug)] |
diff --git a/xtask/src/codegen/gen_diagnostic_docs.rs b/xtask/src/codegen/gen_diagnostic_docs.rs index a2561817b..2504e09ef 100644 --- a/xtask/src/codegen/gen_diagnostic_docs.rs +++ b/xtask/src/codegen/gen_diagnostic_docs.rs | |||
@@ -7,13 +7,13 @@ use crate::{ | |||
7 | project_root, rust_files, Result, | 7 | project_root, rust_files, Result, |
8 | }; | 8 | }; |
9 | 9 | ||
10 | pub(crate) fn generate_diagnostic_docs(mode: Mode) -> Result<()> { | 10 | pub(crate) fn generate_diagnostic_docs() -> Result<()> { |
11 | let diagnostics = Diagnostic::collect()?; | 11 | let diagnostics = Diagnostic::collect()?; |
12 | let contents = | 12 | let contents = |
13 | diagnostics.into_iter().map(|it| it.to_string()).collect::<Vec<_>>().join("\n\n"); | 13 | diagnostics.into_iter().map(|it| it.to_string()).collect::<Vec<_>>().join("\n\n"); |
14 | let contents = format!("//{}\n{}\n", PREAMBLE, contents.trim()); | 14 | let contents = format!("//{}\n{}\n", PREAMBLE, contents.trim()); |
15 | let dst = project_root().join("docs/user/generated_diagnostic.adoc"); | 15 | let dst = project_root().join("docs/user/generated_diagnostic.adoc"); |
16 | codegen::update(&dst, &contents, mode)?; | 16 | codegen::update(&dst, &contents, Mode::Overwrite)?; |
17 | Ok(()) | 17 | Ok(()) |
18 | } | 18 | } |
19 | 19 | ||
diff --git a/xtask/src/codegen/gen_feature_docs.rs b/xtask/src/codegen/gen_feature_docs.rs index cad7ff477..8509fec26 100644 --- a/xtask/src/codegen/gen_feature_docs.rs +++ b/xtask/src/codegen/gen_feature_docs.rs | |||
@@ -7,12 +7,12 @@ use crate::{ | |||
7 | project_root, rust_files, Result, | 7 | project_root, rust_files, Result, |
8 | }; | 8 | }; |
9 | 9 | ||
10 | pub(crate) fn generate_feature_docs(mode: Mode) -> Result<()> { | 10 | pub(crate) fn generate_feature_docs() -> Result<()> { |
11 | let features = Feature::collect()?; | 11 | let features = Feature::collect()?; |
12 | let contents = features.into_iter().map(|it| it.to_string()).collect::<Vec<_>>().join("\n\n"); | 12 | let contents = features.into_iter().map(|it| it.to_string()).collect::<Vec<_>>().join("\n\n"); |
13 | let contents = format!("//{}\n{}\n", PREAMBLE, contents.trim()); | 13 | let contents = format!("//{}\n{}\n", PREAMBLE, contents.trim()); |
14 | let dst = project_root().join("docs/user/generated_features.adoc"); | 14 | let dst = project_root().join("docs/user/generated_features.adoc"); |
15 | codegen::update(&dst, &contents, mode)?; | 15 | codegen::update(&dst, &contents, Mode::Overwrite)?; |
16 | Ok(()) | 16 | Ok(()) |
17 | } | 17 | } |
18 | 18 | ||
diff --git a/xtask/src/tidy.rs b/xtask/src/tidy.rs index 03b4c0092..096bc3af1 100644 --- a/xtask/src/tidy.rs +++ b/xtask/src/tidy.rs | |||
@@ -31,7 +31,7 @@ fn generate_assists_tests() { | |||
31 | #[test] | 31 | #[test] |
32 | #[ignore] | 32 | #[ignore] |
33 | fn generate_lint_completions() { | 33 | fn generate_lint_completions() { |
34 | codegen::generate_lint_completions(Mode::Overwrite).unwrap() | 34 | codegen::generate_lint_completions(Mode::Ensure).unwrap() |
35 | } | 35 | } |
36 | 36 | ||
37 | #[test] | 37 | #[test] |