about summary refs log tree commit diff
diff options
context:
space:
mode:
authorCorey Farwell <coreyf@rwell.org>2016-10-01 21:18:33 -0400
committerCorey Farwell <coreyf@rwell.org>2016-10-02 21:58:22 -0400
commitb55468c8fef3dbe493f32e78d78ae176ef8f9ec1 (patch)
tree30a95d21b21bf1253bd1f341c651994973ca48da
parent5b9ba4c5505f3f3c1c42c50004f2bab010dec0b0 (diff)
downloadrust-b55468c8fef3dbe493f32e78d78ae176ef8f9ec1.tar.gz
rust-b55468c8fef3dbe493f32e78d78ae176ef8f9ec1.zip
Simplify equality checks.
-rw-r--r--src/librustdoc/test.rs6
1 files changed, 3 insertions, 3 deletions
diff --git a/src/librustdoc/test.rs b/src/librustdoc/test.rs
index 5221679e6cd..ed9efca77e7 100644
--- a/src/librustdoc/test.rs
+++ b/src/librustdoc/test.rs
@@ -264,9 +264,9 @@ fn runtest(test: &str, cratename: &str, cfgs: Vec<String>, libs: SearchPaths,
         Ok(r) => {
             match r {
                 Err(count) => {
-                    if count > 0 && compile_fail == false {
+                    if count > 0 && !compile_fail {
                         sess.fatal("aborting due to previous error(s)")
-                    } else if count == 0 && compile_fail == true {
+                    } else if count == 0 && compile_fail {
                         panic!("test compiled while it wasn't supposed to")
                     }
                     if count > 0 && error_codes.len() > 0 {
@@ -279,7 +279,7 @@ fn runtest(test: &str, cratename: &str, cfgs: Vec<String>, libs: SearchPaths,
             }
         }
         Err(_) => {
-            if compile_fail == false {
+            if !compile_fail {
                 panic!("couldn't compile the test");
             }
             if error_codes.len() > 0 {