servo: Merge #10751 - Report lines starting with && in tidy (from zwn:tidy-start-operator); r=Wafflespeanut

Partial implementation of the issue #10692 (the easy part).

Source-Repo: https://github.com/servo/servo
Source-Revision: d926b5d3762a101d5280266f806f2b979f73b695
This commit is contained in:
Zbynek Winkler
2016-04-22 10:40:06 -07:00
parent a287f99021
commit a2221f5bbe
14 changed files with 37 additions and 31 deletions

View File

@@ -32,6 +32,9 @@ impl test {
}
fn test_fun2(y : &String, z : &Vec<f32>) -> f32 {
1
let x = true;
x
&& x;
}
}

View File

@@ -70,6 +70,7 @@ class CheckTidiness(unittest.TestCase):
self.assertEqual('extra space before :', errors.next()[2])
self.assertEqual('use &[T] instead of &Vec<T>', errors.next()[2])
self.assertEqual('use &str instead of &String', errors.next()[2])
self.assertEqual('operators should go at the end of the first line', errors.next()[2])
self.assertNoMoreErrors(errors)
def test_spec_link(self):