mirror of
https://github.com/servo/servo.git
synced 2025-08-09 07:25:35 +01:00
Return zero when computing distance of Option with both value is none.
This commit is contained in:
parent
849bdc958c
commit
95b272d9aa
1 changed files with 1 additions and 0 deletions
|
@ -853,6 +853,7 @@ impl <T> Animatable for Option<T>
|
|||
(&Some(ref this), &Some(ref other)) => {
|
||||
this.compute_squared_distance(other)
|
||||
},
|
||||
(&None, &None) => Ok(0.0),
|
||||
_ => Err(()),
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue