]> git.proxmox.com Git - rustc.git/blobdiff - src/test/compile-fail/lint-type-limits.rs
Imported Upstream version 1.9.0+dfsg1
[rustc.git] / src / test / compile-fail / lint-type-limits.rs
index 0b414ad73db6f9109bd33fc5106102bae088e7e5..29929c120c30f75784f2e4bd67adce7ad37be3e1 100644 (file)
@@ -24,11 +24,6 @@ fn bar() -> i8 {
     return 123;
 }
 
-fn baz() -> bool {
-    128 > bar() //~ ERROR comparison is useless due to type limits
-                //~^ WARNING literal out of range for i8
-}
-
 fn bleh() {
     let u = 42u8;
     let _ = u > 255; //~ ERROR comparison is useless due to type limits
@@ -40,11 +35,3 @@ fn bleh() {
     let _ = u >= 0; //~ ERROR comparison is useless due to type limits
     let _ = 0 <= u; //~ ERROR comparison is useless due to type limits
 }
-
-fn qux() {
-    let mut i = 1i8;
-    while 200 != i { //~ ERROR comparison is useless due to type limits
-                     //~^ WARNING literal out of range for i8
-        i += 1;
-    }
-}