Bug 97447 - sizeof(CSSRule) compile assertion failure
Summary: sizeof(CSSRule) compile assertion failure
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: WebCore Misc. (show other bugs)
Version: 528+ (Nightly build)
Hardware: PC Windows 7
: P1 Blocker
Assignee: Nobody
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2012-09-24 05:39 PDT by Jonathan Liu
Modified: 2012-09-24 07:40 PDT (History)
8 users (show)

See Also:


Attachments
Patch. (1.96 KB, patch)
2012-09-24 05:43 PDT, Jonathan Liu
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Jonathan Liu 2012-09-24 05:39:06 PDT
COMPILE_ASSERT(sizeof(CSSRule) == sizeof(SameSizeAsCSSRule), CSSRule_should_stay_small) fails when building with MinGW-w64 GCC 4.7.2. It previously compiled successfully with MinGW-w64 GCC 4.6.3.

The problem seems to be a change in the default behavior when padding bitfields. MinGW GCC 4.7.x uses -mms-bitfields by default while MinGW GCC 4.6.x doesn't. Since the underlying type is unsigned, it pads to 32-bit when it should really be padding to 8-bit.
Comment 1 Jonathan Liu 2012-09-24 05:43:45 PDT
Created attachment 165359 [details]
Patch.
Comment 2 WebKit Review Bot 2012-09-24 07:39:58 PDT
Comment on attachment 165359 [details]
Patch.

Clearing flags on attachment: 165359

Committed r129365: <http://trac.webkit.org/changeset/129365>
Comment 3 WebKit Review Bot 2012-09-24 07:40:01 PDT
All reviewed patches have been landed.  Closing bug.