Add From<*::Call> for Call to serai-abi

This commit is contained in:
Luke Parker
2025-11-16 13:03:55 -05:00
parent f1f166c168
commit 9891ccade8

View File

@@ -61,6 +61,37 @@ pub enum Call {
InInstructions(in_instructions::Call) = 7, InInstructions(in_instructions::Call) = 7,
} }
impl From<coins::Call> for Call {
fn from(call: coins::Call) -> Self {
Self::Coins(call)
}
}
impl From<validator_sets::Call> for Call {
fn from(call: validator_sets::Call) -> Self {
Self::ValidatorSets(call)
}
}
impl From<signals::Call> for Call {
fn from(call: signals::Call) -> Self {
Self::Signals(call)
}
}
impl From<dex::Call> for Call {
fn from(call: dex::Call) -> Self {
Self::Dex(call)
}
}
impl From<genesis_liquidity::Call> for Call {
fn from(call: genesis_liquidity::Call) -> Self {
Self::GenesisLiquidity(call)
}
}
impl From<in_instructions::Call> for Call {
fn from(call: in_instructions::Call) -> Self {
Self::InInstructions(call)
}
}
impl Call { impl Call {
pub(crate) fn is_signed(&self) -> bool { pub(crate) fn is_signed(&self) -> bool {
match self { match self {