Skip to content

Commit 629c2a8

Browse files
committed
Generate stability attributes for derived impls
The attributes are copied from the item for which the trait impl is derived
1 parent be91042 commit 629c2a8

File tree

1 file changed

+1
-1
lines changed
  • src/libsyntax/ext/deriving/generic

1 file changed

+1
-1
lines changed

src/libsyntax/ext/deriving/generic/mod.rs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -417,7 +417,7 @@ impl<'a> TraitDef<'a> {
417417
let mut attrs = newitem.attrs.clone();
418418
attrs.extend(item.attrs.iter().filter(|a| {
419419
match &a.name()[..] {
420-
"allow" | "warn" | "deny" | "forbid" => true,
420+
"allow" | "warn" | "deny" | "forbid" | "stable" | "unstable" => true,
421421
_ => false,
422422
}
423423
}).cloned());

0 commit comments

Comments
 (0)