From 123e5d33c222dad31bb2030e176156d261c7e3b7 Mon Sep 17 00:00:00 2001 From: Hiroyuki Ikezoe Date: Thu, 27 Jul 2017 06:20:33 +0900 Subject: [PATCH] MatrixDecomposed3D.add_weighted() is called with zero value for other_portion in case of iteration composite. In the case where we accumulate transform:none onto decomposed matrix for iteration composite whose iteration count is over 2, we pass zero other_portion and self_portion which is over 1.0. We should care about the case. --- components/style/properties/helpers/animated_properties.mako.rs | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/components/style/properties/helpers/animated_properties.mako.rs b/components/style/properties/helpers/animated_properties.mako.rs index 17c10809afc..4b734167c7a 100644 --- a/components/style/properties/helpers/animated_properties.mako.rs +++ b/components/style/properties/helpers/animated_properties.mako.rs @@ -2274,7 +2274,7 @@ impl Animatable for MatrixDecomposed3D { use std::f64; debug_assert!((self_portion + other_portion - 1.0f64).abs() <= f64::EPSILON || - other_portion == 1.0f64, + other_portion == 1.0f64 || other_portion == 0.0f64, "add_weighted should only be used for interpolating or accumulating transforms"); let mut sum = *self;