about summary refs log tree commit diff
diff options
context:
space:
mode:
authorNick Cameron <ncameron@mozilla.com>2016-10-11 16:27:09 +1300
committerNick Cameron <ncameron@mozilla.com>2016-10-27 11:44:42 +1300
commitd1b08b136c47c37cce91d65dc58f375af0d085e1 (patch)
tree7f480dfde932ba5d96e71a88210443101ec7b547
parent121e903f1747881ebdf0b010a54b116dfb367d12 (diff)
deprecate no_debug
-rw-r--r--src/libsyntax/feature_gate.rs2
-rw-r--r--src/test/compile-fail/feature-gate-no-debug-2.rs15
2 files changed, 16 insertions, 1 deletions
diff --git a/src/libsyntax/feature_gate.rs b/src/libsyntax/feature_gate.rs
index 07b52d4c9aa..352479d1b1d 100644
--- a/src/libsyntax/feature_gate.rs
+++ b/src/libsyntax/feature_gate.rs
@@ -643,7 +643,7 @@ pub const KNOWN_ATTRIBUTES: &'static [(&'static str, AttributeType, AttributeGat
     ("link_section", Whitelisted, Ungated),
     ("no_builtins", Whitelisted, Ungated),
     ("no_mangle", Whitelisted, Ungated),
-    ("no_debug", Whitelisted, Gated(Stability::Unstable,
+    ("no_debug", Whitelisted, Gated(Stability::Deprecated,
                                     "no_debug",
                                     "the `#[no_debug]` attribute \
                                      is an experimental feature",
diff --git a/src/test/compile-fail/feature-gate-no-debug-2.rs b/src/test/compile-fail/feature-gate-no-debug-2.rs
new file mode 100644
index 00000000000..853aaea8ef9
--- /dev/null
+++ b/src/test/compile-fail/feature-gate-no-debug-2.rs
@@ -0,0 +1,15 @@
+// Copyright 2016 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.
+
+#![deny(deprecated)]
+#![feature(no_debug)]
+
+#[no_debug] //~ ERROR use of deprecated attribute: no_debug
+fn main() {}