add trait from<u128> to Num
This commit is contained in:
parent
f8c79609bb
commit
633649ad7e
|
@ -23,3 +23,9 @@ impl std::ops::Mul<u128> for Num {
|
|||
self.number * rhs
|
||||
}
|
||||
}
|
||||
|
||||
impl From<u128> for Num {
|
||||
fn from(number: u128) -> Self {
|
||||
Num { number }
|
||||
}
|
||||
}
|
Loading…
Reference in New Issue