about summary refs log tree commit diff
path: root/src/test/ui/error-codes
diff options
context:
space:
mode:
authorcsmoe <35686186+csmoe@users.noreply.github.com>2018-10-09 22:55:07 +0800
committercsmoe <35686186+csmoe@users.noreply.github.com>2018-10-20 11:11:31 +0800
commitfb7c76bad551255b174958ccbfe7b7cda7f53897 (patch)
tree0f50481d72f1d54e4a1cddf2d2868619b2fc740c /src/test/ui/error-codes
parentd3b018ccdba328389ca90cff8795e5f6b97e5c13 (diff)
downloadrust-fb7c76bad551255b174958ccbfe7b7cda7f53897.tar.gz
rust-fb7c76bad551255b174958ccbfe7b7cda7f53897.zip
update meta item checking test
Diffstat (limited to 'src/test/ui/error-codes')
-rw-r--r--src/test/ui/error-codes/E0565-2.rs15
-rw-r--r--src/test/ui/error-codes/E0565-2.stderr9
2 files changed, 24 insertions, 0 deletions
diff --git a/src/test/ui/error-codes/E0565-2.rs b/src/test/ui/error-codes/E0565-2.rs
new file mode 100644
index 00000000000..eb13e432751
--- /dev/null
+++ b/src/test/ui/error-codes/E0565-2.rs
@@ -0,0 +1,15 @@
+// Copyright 2018 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.
+
+// repr currently doesn't support literals
+#[deprecated(since = b"1.29", note = "hi")] //~ ERROR E0565
+struct A {  }
+
+fn main() {  }
diff --git a/src/test/ui/error-codes/E0565-2.stderr b/src/test/ui/error-codes/E0565-2.stderr
new file mode 100644
index 00000000000..46125b71420
--- /dev/null
+++ b/src/test/ui/error-codes/E0565-2.stderr
@@ -0,0 +1,9 @@
+error[E0565]: unsupported literal
+  --> $DIR/E0565-2.rs:12:22
+   |
+LL | #[deprecated(since = b"1.29", note = "hi")] //~ ERROR E0565
+   |                      ^^^^^^^ help: consider removing the prefix: `"1.29"`
+
+error: aborting due to previous error
+
+For more information about this error, try `rustc --explain E0565`.