mirror of
https://github.com/rust-lang/rust.git
synced 2025-09-29 15:48:52 +00:00

Use `splice` to avoid shifting the other items twice. Put `extern crate std;` first so it's already resolved when we resolve `::std::prelude::rust_20XX`.
16 lines
451 B
Plaintext
16 lines
451 B
Plaintext
#[attr = MacroUse {arguments: UseAll}]
|
|
extern crate std;
|
|
#[prelude_import]
|
|
use ::std::prelude::rust_2015::*;
|
|
//@ compile-flags: -Zunpretty=hir
|
|
//@ check-pass
|
|
//@ edition: 2015
|
|
|
|
#[diagnostic::on_unimplemented(message =
|
|
"My Message for `ImportantTrait<{A}>` implemented for `{Self}`", label =
|
|
"My Label", note = "Note 1", note = "Note 2")]
|
|
trait ImportantTrait<A> { }
|
|
|
|
#[diagnostic::do_not_recommend]
|
|
impl <T> ImportantTrait<T> for T where T: Clone { }
|