Skip to content

Commit 825ad68

Browse files
committed
docs(Export): fix example code
the repr part should be added to change the serialization behavior.
1 parent c33e89b commit 825ad68

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

gdnative-derive/src/lib.rs

+2
Original file line numberDiff line numberDiff line change
@@ -675,6 +675,8 @@ pub fn godot_wrap_method(input: TokenStream) -> TokenStream {
675675
/// use gdnative::prelude::*;
676676
///
677677
/// #[derive(Debug, PartialEq, Clone, Copy, Export, ToVariant, FromVariant)]
678+
/// #[variant(enum = "repr")]
679+
/// #[repr(i32)]
678680
/// enum Dir {
679681
/// Up = 1,
680682
/// Down = -1,

0 commit comments

Comments
 (0)