about summary refs log tree commit diff
diff options
context:
space:
mode:
authorBrendan Zabarauskas <bjzaba@yahoo.com.au>2014-02-07 21:18:58 +1100
committerBrendan Zabarauskas <bjzaba@yahoo.com.au>2014-02-08 04:43:51 +1100
commit1e55cae78350c4d58508afeeec99373254e33336 (patch)
tree0f21acb951ab786871889f8180964e1e04e60c1a
parent7e1cfc8893ecd220c517661a18eb0c94b9e342e3 (diff)
downloadrust-1e55cae78350c4d58508afeeec99373254e33336.tar.gz
rust-1e55cae78350c4d58508afeeec99373254e33336.zip
Add missing test for unreachable! macro
-rw-r--r--src/test/run-fail/unreachable-macro-fail.rs12
1 files changed, 12 insertions, 0 deletions
diff --git a/src/test/run-fail/unreachable-macro-fail.rs b/src/test/run-fail/unreachable-macro-fail.rs
new file mode 100644
index 00000000000..07e05c6fed9
--- /dev/null
+++ b/src/test/run-fail/unreachable-macro-fail.rs
@@ -0,0 +1,12 @@
+// Copyright 2014 The Rust Project Developers. See the COPYRIGHT
+// file at the top-level directory of this distribution and at
+// http://rust-lang.org/COPYRIGHT.
+//
+// Licensed under the Apache License, Version 2.0 <LICENSE-APACHE or
+// http://www.apache.org/licenses/LICENSE-2.0> or the MIT license
+// <LICENSE-MIT or http://opensource.org/licenses/MIT>, at your
+// option. This file may not be copied, modified, or distributed
+// except according to those terms.
+
+// error-pattern:internal error: entered unreachable code
+fn main() { unreachable!() }