diff options
author | bors[bot] <26634292+bors[bot]@users.noreply.github.com> | 2020-02-19 10:38:27 +0000 |
---|---|---|
committer | GitHub <[email protected]> | 2020-02-19 10:38:27 +0000 |
commit | d07f043ef1c99491cb172f3c3474b31c97501d7a (patch) | |
tree | 41099b8ebd3f8ca0aea64ac8623e8ac1140ca572 /crates/ra_assists/src | |
parent | 20252efb32bfdfe7392934a95a6c6d6b583d10e7 (diff) | |
parent | d06733efebc5d8b378398f1cbb4bbd9f3deb8270 (diff) |
Merge #3229
3229: Fix a crash with non-ascii whitespace in doc-comments r=matklad a=sinkuu
2nd commit is a random drive-by cleanup.
Co-authored-by: Shotaro Yamada <[email protected]>
Diffstat (limited to 'crates/ra_assists/src')
-rw-r--r-- | crates/ra_assists/src/lib.rs | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/crates/ra_assists/src/lib.rs b/crates/ra_assists/src/lib.rs index a0e7fe17e..f4a7497db 100644 --- a/crates/ra_assists/src/lib.rs +++ b/crates/ra_assists/src/lib.rs | |||
@@ -38,7 +38,7 @@ pub struct GroupLabel(pub String); | |||
38 | impl AssistLabel { | 38 | impl AssistLabel { |
39 | pub(crate) fn new(label: String, id: AssistId) -> AssistLabel { | 39 | pub(crate) fn new(label: String, id: AssistId) -> AssistLabel { |
40 | // FIXME: make fields private, so that this invariant can't be broken | 40 | // FIXME: make fields private, so that this invariant can't be broken |
41 | assert!(label.chars().next().unwrap().is_uppercase()); | 41 | assert!(label.starts_with(|c: char| c.is_uppercase())); |
42 | AssistLabel { label, id } | 42 | AssistLabel { label, id } |
43 | } | 43 | } |
44 | } | 44 | } |