about summary refs log tree commit diff
path: root/src/test
diff options
context:
space:
mode:
authorMichael Woerister <michaelwoerister@posteo>2017-10-19 14:32:39 +0200
committerMichael Woerister <michaelwoerister@posteo>2017-10-25 15:43:48 +0200
commitf55425dfcd2a156ff2f17e6dd4f9dcfaee9f5905 (patch)
tree37a89dc6c2ccbdacc2393bcff49f4e8afb92e14c /src/test
parent686d2a7f14d5a8068b70d59476cd564c62a5677d (diff)
downloadrust-f55425dfcd2a156ff2f17e6dd4f9dcfaee9f5905.tar.gz
rust-f55425dfcd2a156ff2f17e6dd4f9dcfaee9f5905.zip
incr.comp.: Implement query diagnostic persistence.
Diffstat (limited to 'src/test')
-rw-r--r--src/test/incremental/warnings-reemitted.rs19
1 files changed, 19 insertions, 0 deletions
diff --git a/src/test/incremental/warnings-reemitted.rs b/src/test/incremental/warnings-reemitted.rs
new file mode 100644
index 00000000000..bf66ac7829c
--- /dev/null
+++ b/src/test/incremental/warnings-reemitted.rs
@@ -0,0 +1,19 @@
+// Copyright 2017 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.
+
+// revisions: cfail1 cfail2 cfail3
+// compile-flags: -Coverflow-checks=on
+// must-compile-successfully
+
+#![allow(warnings)]
+
+fn main() {
+    255u8 + 1; //~ WARNING this expression will panic at run-time
+}