about summary refs log tree commit diff
path: root/src/test/ui/reachable/expr_block.rs
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/ui/reachable/expr_block.rs')
-rw-r--r--src/test/ui/reachable/expr_block.rs31
1 files changed, 0 insertions, 31 deletions
diff --git a/src/test/ui/reachable/expr_block.rs b/src/test/ui/reachable/expr_block.rs
deleted file mode 100644
index 136bccce881..00000000000
--- a/src/test/ui/reachable/expr_block.rs
+++ /dev/null
@@ -1,31 +0,0 @@
-#![allow(unused_variables)]
-#![allow(unused_assignments)]
-#![allow(dead_code)]
-#![deny(unreachable_code)]
-
-fn a() {
-    // Here the tail expression is considered unreachable:
-    let x = {
-        return;
-        22 //~ ERROR unreachable
-    };
-}
-
-fn b() {
-    // Here the `x` assignment is considered unreachable, not the block:
-    let x = {
-        return;
-    };
-}
-
-fn c() {
-    // Here the `println!` is unreachable:
-    let x = {
-        return;
-        println!("foo");
-        //~^ ERROR unreachable statement
-        22
-    };
-}
-
-fn main() { }