add trait to convert Num to u128

This commit is contained in:
b1ek 2023-08-02 20:21:38 +10:00
parent 8f3bb2cd58
commit 14915d8f31
Signed by: blek
GPG Key ID: 14546221E3595D0C
1 changed files with 6 additions and 0 deletions

View File

@ -29,3 +29,9 @@ impl From<u128> for Num {
Num { number }
}
}
impl From<Num> for u128 {
fn from(value: Num) -> Self {
value.number
}
}