diff options
| author | Aleksey Kladov <aleksey.kladov@gmail.com> | 2019-10-26 19:08:13 +0300 |
|---|---|---|
| committer | Aleksey Kladov <aleksey.kladov@gmail.com> | 2019-10-26 19:08:13 +0300 |
| commit | a5cbd8d5e8aca0d0d8dde175ba13bfa995a753c0 (patch) | |
| tree | a3dfa55e7fadcb7e7e8299ce03d9f7beaee4a79b /xtask/src/codegen | |
| parent | 2f7d1f10c1614d9448604da5c105b75c43cc6f2b (diff) | |
| download | rust-a5cbd8d5e8aca0d0d8dde175ba13bfa995a753c0.tar.gz rust-a5cbd8d5e8aca0d0d8dde175ba13bfa995a753c0.zip | |
check style for assist docs
Diffstat (limited to 'xtask/src/codegen')
| -rw-r--r-- | xtask/src/codegen/gen_assists_docs.rs | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/xtask/src/codegen/gen_assists_docs.rs b/xtask/src/codegen/gen_assists_docs.rs index 2ca7cda63db..8dca2ed06e3 100644 --- a/xtask/src/codegen/gen_assists_docs.rs +++ b/xtask/src/codegen/gen_assists_docs.rs @@ -52,6 +52,12 @@ fn collect_assists() -> Result<Vec<Assist>> { ); let doc = take_until(lines.by_ref(), "```").trim().to_string(); + assert!( + doc.chars().next().unwrap().is_ascii_uppercase() && doc.ends_with("."), + "\n\n{}: assist docs should be proper sentences, with capitalization and a full stop at the end.\n\n{}\n\n", + id, doc, + ); + let before = take_until(lines.by_ref(), "```"); assert_eq!(lines.next().unwrap().as_str(), "->"); |
