Skip to content

Commit

Permalink
Auto merge of #24646 - brson:stab, r=alexcrichton
Browse files Browse the repository at this point in the history
  • Loading branch information
bors committed Apr 21, 2015
2 parents 21c48c3 + bb407b1 commit 3860240
Show file tree
Hide file tree
Showing 3 changed files with 8 additions and 11 deletions.
6 changes: 3 additions & 3 deletions src/librustc/middle/stability.rs
Expand Up @@ -95,9 +95,9 @@ impl<'a> Annotator<'a> {
let tag = attr.name();
if tag == "unstable" || tag == "stable" || tag == "deprecated" {
attr::mark_used(attr);
self.sess.span_warn(attr.span(),
"stability attributes are deprecated \
and will soon become errors");
self.sess.span_err(attr.span(),
"stability attributes may not be used outside \
of the standard library");
}
}
f(self);
Expand Down
3 changes: 2 additions & 1 deletion src/librustc_data_structures/lib.rs
Expand Up @@ -22,11 +22,12 @@
#![unstable(feature = "rustc_private")]
#![crate_type = "dylib"]
#![crate_type = "rlib"]
#![staged_api]
#![doc(html_logo_url = "http://www.rust-lang.org/logos/rust-logo-128x128-blk-v2.png",
html_favicon_url = "http://www.rust-lang.org/favicon.ico",
html_root_url = "http://doc.rust-lang.org/nightly/")]

#![feature(rustc_private)]
#![feature(rustc_private, staged_api)]
#![cfg_attr(test, feature(test))]

#[macro_use] extern crate log;
Expand Down
10 changes: 3 additions & 7 deletions src/test/compile-fail/stability-attribute-non-staged.rs
Expand Up @@ -8,11 +8,7 @@
// option. This file may not be copied, modified, or distributed
// except according to those terms.

// These two generate an error to satisfy the compile-fail test
#![deny(warnings)]
#![feature(blah)] //~ ERROR

#[unstable] //~ WARNING: stability attributes are deprecated
#[stable] //~ WARNING: stability attributes are deprecated
#[deprecated] //~ WARNING: stability attributes are deprecated
#[unstable] //~ ERROR: stability attributes may not be used
#[stable] //~ ERROR: stability attributes may not be used
#[deprecated] //~ ERROR: stability attributes may not be used
fn main() { }

0 comments on commit 3860240

Please sign in to comment.