2017-07-11 14:30:10 +02:00
|
|
|
// This test just shows that a crate-level `#![deprecated]` does not
|
|
|
|
// signal a warning or error. (This file sits on its own because a
|
|
|
|
// crate-level `#![deprecated]` causes all that crate's item
|
|
|
|
// definitions to be deprecated, which is a pain to work with.)
|
|
|
|
//
|
|
|
|
// (For non-crate-level cases, see issue-43106-gating-of-builtin-attrs.rs)
|
|
|
|
|
2018-10-31 13:08:01 +01:00
|
|
|
// compile-pass
|
|
|
|
// skip-codegen
|
2017-07-11 14:30:10 +02:00
|
|
|
#![allow(dead_code)]
|
|
|
|
#![deprecated = "1100"]
|
|
|
|
|
|
|
|
// Since we expect for the mix of attributes used here to compile
|
|
|
|
// successfully, and we are just testing for the expected warnings of
|
|
|
|
// various (mis)uses of attributes, we use the `rustc_error` attribute
|
|
|
|
// on the `fn main()`.
|
|
|
|
|
2018-10-31 13:08:01 +01:00
|
|
|
|
|
|
|
fn main() {
|
2017-07-11 14:30:10 +02:00
|
|
|
println!("Hello World");
|
|
|
|
}
|