aboutsummaryrefslogtreecommitdiff
path: root/xtask
diff options
context:
space:
mode:
authorBenjamin Coenen <[email protected]>2020-04-18 16:14:24 +0100
committerBenjamin Coenen <[email protected]>2020-04-18 16:14:24 +0100
commitaf3c19e85f55db9277ce9ad5b784df2ccfe3c9e4 (patch)
tree7a777f22f5fa79704b8d2c9aa8d67255d12123be /xtask
parent379787858bbfb2691e134942d94fcbc70c5d1d7f (diff)
parent84e3304a9bf0d68e30d58b1e37a6db2e9ec97525 (diff)
Merge branch 'master' of github.com:rust-analyzer/rust-analyzer
Diffstat (limited to 'xtask')
-rw-r--r--xtask/tests/tidy-tests/main.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/xtask/tests/tidy-tests/main.rs b/xtask/tests/tidy-tests/main.rs
index 101ae19bd..ead642acc 100644
--- a/xtask/tests/tidy-tests/main.rs
+++ b/xtask/tests/tidy-tests/main.rs
@@ -35,7 +35,7 @@ fn check_todo(path: &Path, text: &str) {
35 } 35 }
36 if text.contains("TODO") || text.contains("TOOD") || text.contains("todo!") { 36 if text.contains("TODO") || text.contains("TOOD") || text.contains("todo!") {
37 panic!( 37 panic!(
38 "\nTODO markers should not be committed to the master branch,\n\ 38 "\nTODO markers or todo! macros should not be committed to the master branch,\n\
39 use FIXME instead\n\ 39 use FIXME instead\n\
40 {}\n", 40 {}\n",
41 path.display(), 41 path.display(),
@@ -47,9 +47,9 @@ fn check_trailing_ws(path: &Path, text: &str) {
47 if is_exclude_dir(path, &["test_data"]) { 47 if is_exclude_dir(path, &["test_data"]) {
48 return; 48 return;
49 } 49 }
50 for line in text.lines() { 50 for (line_number, line) in text.lines().enumerate() {
51 if line.chars().last().map(char::is_whitespace) == Some(true) { 51 if line.chars().last().map(char::is_whitespace) == Some(true) {
52 panic!("Trailing whitespace in {}", path.display()) 52 panic!("Trailing whitespace in {} at line {}", path.display(), line_number)
53 } 53 }
54 } 54 }
55} 55}