Skip to content

Commit f047591

Browse files
committed
feat(rustdoc-json-types): mark simple enums as copy
Fixes [rust-lang/rustdoc-types#26](rust-lang/rustdoc-types#26)
1 parent bfab34a commit f047591

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/rustdoc-json-types/lib.rs

+3-3
Original file line numberDiff line numberDiff line change
@@ -308,7 +308,7 @@ pub struct Id(pub u32);
308308
/// The fundamental kind of an item. Unlike [`ItemEnum`], this does not carry any aditional info.
309309
///
310310
/// Part of [`ItemSummary`].
311-
#[derive(Clone, Debug, PartialEq, Eq, Hash, Serialize, Deserialize)]
311+
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, Serialize, Deserialize)]
312312
#[serde(rename_all = "snake_case")]
313313
pub enum ItemKind {
314314
/// A module declaration, e.g. `mod foo;` or `mod foo {}`
@@ -892,7 +892,7 @@ pub enum GenericBound {
892892
}
893893

894894
/// A set of modifiers applied to a trait.
895-
#[derive(Clone, Debug, PartialEq, Eq, Hash, Serialize, Deserialize)]
895+
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, Serialize, Deserialize)]
896896
#[serde(rename_all = "snake_case")]
897897
pub enum TraitBoundModifier {
898898
/// Marks the absence of a modifier.
@@ -1193,7 +1193,7 @@ pub struct ProcMacro {
11931193
}
11941194

11951195
/// The way a [`ProcMacro`] is declared to be used.
1196-
#[derive(Clone, Debug, PartialEq, Eq, Hash, Serialize, Deserialize)]
1196+
#[derive(Clone, Copy, Debug, PartialEq, Eq, Hash, Serialize, Deserialize)]
11971197
#[serde(rename_all = "snake_case")]
11981198
pub enum MacroKind {
11991199
/// A bang macro `foo!()`.

0 commit comments

Comments
 (0)