From 95b272d9aaaa6c9b7469b168aebf5d97c43bc806 Mon Sep 17 00:00:00 2001 From: Mantaroh Yoshinaga Date: Wed, 14 Jun 2017 11:03:53 +0900 Subject: [PATCH] Return zero when computing distance of Option with both value is none. --- components/style/properties/helpers/animated_properties.mako.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/components/style/properties/helpers/animated_properties.mako.rs b/components/style/properties/helpers/animated_properties.mako.rs index a03d55070aa..857c0b10491 100644 --- a/components/style/properties/helpers/animated_properties.mako.rs +++ b/components/style/properties/helpers/animated_properties.mako.rs @@ -853,6 +853,7 @@ impl Animatable for Option (&Some(ref this), &Some(ref other)) => { this.compute_squared_distance(other) }, + (&None, &None) => Ok(0.0), _ => Err(()), } }