https://bugs.webkit.org/show_bug.cgi?id=75635
Reviewed by Tony Chang.
Tightened the compile-time assertion.
* css/CSSValue.cpp:
git-svn-id: https://svn.webkit.org/repository/webkit/trunk@104236
268f45cc-cd09-0410-ab3c-
d52691b4dbfc
+2012-01-05 Ryosuke Niwa <rniwa@webkit.org>
+
+ Add a compile-time assertion for the size of CSSValue
+ https://bugs.webkit.org/show_bug.cgi?id=75635
+
+ Reviewed by Tony Chang.
+
+ Tightened the compile-time assertion.
+
+ * css/CSSValue.cpp:
+
2012-01-05 Adam Barth <abarth@webkit.org>
[V8] CodeGeneration for SerializedScriptValue doesn't play nice with [Constructor]
namespace WebCore {
-#ifdef NDEBUG
-COMPILE_ASSERT((sizeof(CSSValue) - sizeof(RefCounted<CSSValue>)) <= 4, CSS_value_packs_into_four_bytes);
-#endif
+class SameSizeAsCSSValue : public RefCounted<SameSizeAsCSSValue> {
+ unsigned char bitfields[2];
+};
+
+COMPILE_ASSERT(sizeof(CSSValue) == sizeof(SameSizeAsCSSValue), CSS_value_should_stay_small);
CSSValue::Type CSSValue::cssValueType() const
{