From bdbe8fde42373987c9845200e4ac9801f039e28e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Emilio=20Cobos=20=C3=81lvarez?= Date: Fri, 6 Nov 2020 02:37:44 +0000 Subject: [PATCH] style: Shrink custom property maps before making them immutable. Differential Revision: https://phabricator.services.mozilla.com/D96132 --- components/style/custom_properties.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/components/style/custom_properties.rs b/components/style/custom_properties.rs index 4943fd1a74a..4a0bf5bed7a 100644 --- a/components/style/custom_properties.rs +++ b/components/style/custom_properties.rs @@ -662,6 +662,7 @@ impl<'a> CustomPropertiesBuilder<'a> { let inherited = self.inherited.as_ref().map(|m| &***m); substitute_all(&mut map, inherited, self.device); } + map.shrink_to_fit(); Some(Arc::new(map)) } }