Skip to content

Commit 5c57e69

Browse files
committed
Derive Default for MyEnum in example of Properties macro
1 parent 914526f commit 5c57e69

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

glib-macros/src/lib.rs

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1408,9 +1408,10 @@ pub fn cstr_bytes(item: TokenStream) -> TokenStream {
14081408
/// nick: String,
14091409
/// }
14101410
///
1411-
/// #[derive(Debug, Copy, Clone, PartialEq, Eq, glib::Enum)]
1411+
/// #[derive(Debug, Copy, Clone, PartialEq, Eq, glib::Enum, Default)]
14121412
/// #[enum_type(name = "MyEnum")]
14131413
/// enum MyEnum {
1414+
/// #[default]
14141415
/// Val,
14151416
/// OtherVal
14161417
/// }

0 commit comments

Comments
 (0)