diff options
| author | varkor <github@varkor.com> | 2018-07-23 14:12:35 +0100 |
|---|---|---|
| committer | varkor <github@varkor.com> | 2018-08-05 15:54:49 +0100 |
| commit | bd66cbb806ee2a4d288d2e22626dff39ee9cc336 (patch) | |
| tree | ce4631cb54adb3c38bdc185a9fa2ca2b1537c542 | |
| parent | af77c42e3800d033f501b6e179fb4189c02deb8a (diff) | |
| download | rust-bd66cbb806ee2a4d288d2e22626dff39ee9cc336.tar.gz rust-bd66cbb806ee2a4d288d2e22626dff39ee9cc336.zip | |
Remove obsolete tests in tidy
These have been replaced by more reliable checks in the compiler itself.
| -rw-r--r-- | src/tools/tidy/src/features.rs | 35 |
1 files changed, 3 insertions, 32 deletions
diff --git a/src/tools/tidy/src/features.rs b/src/tools/tidy/src/features.rs index f68ba0b095b..1dc36221bd2 100644 --- a/src/tools/tidy/src/features.rs +++ b/src/tools/tidy/src/features.rs @@ -50,34 +50,6 @@ pub struct Feature { pub tracking_issue: Option<u32>, } -impl Feature { - fn check_match(&self, other: &Feature)-> Result<(), Vec<&'static str>> { - let mut mismatches = Vec::new(); - if self.level != other.level { - mismatches.push("stability level"); - } - if self.level == Status::Stable || other.level == Status::Stable { - // As long as a feature is unstable, the since field tracks - // when the given part of the feature has been implemented. - // Mismatches are tolerable as features evolve and functionality - // gets added. - // Once a feature is stable, the since field tracks the first version - // it was part of the stable distribution, and mismatches are disallowed. - if self.since != other.since { - mismatches.push("since"); - } - } - if self.tracking_issue != other.tracking_issue { - mismatches.push("tracking issue"); - } - if mismatches.is_empty() { - Ok(()) - } else { - Err(mismatches) - } - } -} - pub type Features = HashMap<String, Feature>; pub fn check(path: &Path, bad: &mut bool, quiet: bool) { @@ -310,13 +282,12 @@ fn get_and_check_lib_features(base_src_path: &Path, Ok((name, f)) => { let mut check_features = |f: &Feature, list: &Features, display: &str| { if let Some(ref s) = list.get(name) { - if let Err(m) = (&f).check_match(s) { + if f.tracking_issue != s.tracking_issue { tidy_error!(bad, - "{}:{}: mismatches to {} in: {:?}", + "{}:{}: mismatches the `issue` in {}", file.display(), line, - display, - &m); + display); } } }; |
