From d3e65000be4f6e19b5b85ab471b9e2a620dbb559 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Emilio=20Cobos=20=C3=81lvarez?= Date: Thu, 19 Dec 2019 20:43:06 +0000 Subject: [PATCH] style: Workaround LLVM ABI bug. All the gory details in https://bugzilla.mozilla.org/show_bug.cgi?id=1600735 and related LLVM / GCC bugs. Avoid the issue by forcing the relevant enum to be 32-bit wide, so as to not trigger the LLVM bug. Differential Revision: https://phabricator.services.mozilla.com/D57868 --- components/style/properties/properties.mako.rs | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/components/style/properties/properties.mako.rs b/components/style/properties/properties.mako.rs index 30a03f79290..e4a07da1c77 100644 --- a/components/style/properties/properties.mako.rs +++ b/components/style/properties/properties.mako.rs @@ -1803,8 +1803,11 @@ impl ToCss for PropertyId { } /// The counted unknown property list which is used for css use counters. +/// +/// FIXME: This should be just #[repr(u8)], but can't be because of ABI issues, +/// see https://bugs.llvm.org/show_bug.cgi?id=44228. #[derive(Clone, Copy, Debug, Eq, FromPrimitive, Hash, PartialEq)] -#[repr(u8)] +#[repr(u32)] pub enum CountedUnknownProperty { % for prop in data.counted_unknown_properties: /// ${prop.name}