Simplify a few "if" structures

This commit is contained in:
François Garillot
2019-12-02 07:30:54 -08:00
committed by Pratyush Mishra
parent 53a51eb4dc
commit b42d5f8d36
5 changed files with 10 additions and 12 deletions

View File

@@ -183,7 +183,7 @@ impl UInt8 {
impl PartialEq for UInt8 {
fn eq(&self, other: &Self) -> bool {
!self.value.is_none() && !other.value.is_none() && self.value == other.value
self.value.is_some() && other.value.is_some() && self.value == other.value
}
}