mirror of
https://github.com/serai-dex/serai.git
synced 2025-12-09 12:49:23 +00:00
We prior required they had the same encoding, yet this ensures they do by making them one and the same. This does require an large, ugly, From/TryInto block which is deemed preferable for moving this more and more into syntax (from semantics). Further improvements (notably re: Extra) is possible, and this already lets us strip some members from the Call enum.
10 lines
296 B
Rust
10 lines
296 B
Rust
#[derive(Clone, PartialEq, Eq, Debug, scale::Encode, scale::Decode, scale_info::TypeInfo)]
|
|
#[cfg_attr(feature = "serde", derive(serde::Serialize))]
|
|
#[cfg_attr(all(feature = "std", feature = "serde"), derive(serde::Deserialize))]
|
|
pub enum Call {
|
|
set {
|
|
#[codec(compact)]
|
|
now: u64,
|
|
},
|
|
}
|