deprecation message for custom derive
This commit is contained in:
parent
b7675cf04a
commit
9322332140
|
@ -175,7 +175,7 @@ pub fn expand_derive(cx: &mut ExtCtxt,
|
|||
feature_gate::GateIssue::Language,
|
||||
feature_gate::EXPLAIN_CUSTOM_DERIVE);
|
||||
} else {
|
||||
cx.span_warn(titem.span, EXPLAIN_DEPR_CUSTOM_DERIVE);
|
||||
cx.span_warn(titem.span, feature_gate::EXPLAIN_DEPR_CUSTOM_DERIVE);
|
||||
let name = intern_and_get_ident(&format!("derive_{}", tname));
|
||||
let mitem = cx.meta_word(titem.span, name);
|
||||
new_attributes.push(cx.attribute(mitem.span, mitem));
|
||||
|
|
|
@ -8,8 +8,10 @@
|
|||
// option. This file may not be copied, modified, or distributed
|
||||
// except according to those terms.
|
||||
|
||||
// ignore-tidy-linelength
|
||||
|
||||
#[derive(Eqr)]
|
||||
//~^ ERROR `#[derive]` for custom traits is not stable enough for use and is subject to change
|
||||
//~^ ERROR `#[derive]` for custom traits is not stable enough for use. It is deprecated and will be removed in v1.15 (see issue #29644)
|
||||
struct Foo;
|
||||
|
||||
pub fn main() {}
|
||||
|
|
Loading…
Reference in New Issue