WebKit Bugzilla
New
Browse
Search+
Log In
×
Sign in with GitHub
or
Remember my login
Create Account
·
Forgot Password
Forgotten password account recovery
RESOLVED FIXED
285143
FIXME: replace by a switch statement in CSSPrimitiveValue::primitiveType()
https://bugs.webkit.org/show_bug.cgi?id=285143
Summary
FIXME: replace by a switch statement in CSSPrimitiveValue::primitiveType()
Karl Dubost
Reported
2024-12-25 01:15:43 PST
https://searchfox.org/wubkat/rev/86e4a015037fed5778aab8eb507f495e5d974875/Source/WebCore/css/CSSPrimitiveValue.cpp#243-259
```cpp CSSUnitType CSSPrimitiveValue::primitiveType() const { // FIXME: Use a switch statement here. if (primitiveUnitType() == CSSUnitType::CSS_PROPERTY_ID || primitiveUnitType() == CSSUnitType::CSS_VALUE_ID || primitiveUnitType() == CSSUnitType::CustomIdent) return CSSUnitType::CSS_IDENT; // Web-exposed content expects font family values to have CSSUnitType::CSS_STRING primitive type // so we need to map our internal CSSUnitType::CSS_FONT_FAMILY type here. if (primitiveUnitType() == CSSUnitType::CSS_FONT_FAMILY) return CSSUnitType::CSS_STRING; if (!isCalculated()) return primitiveUnitType(); return m_value.calc->primitiveType(); } ```
Attachments
Add attachment
proposed patch, testcase, etc.
Karl Dubost
Comment 1
2024-12-25 01:18:32 PST
Using this as an example for an article on helping WebKit contributions.
Radar WebKit Bug Importer
Comment 2
2024-12-25 01:47:43 PST
<
rdar://problem/142020781
>
Karl Dubost
Comment 3
2024-12-25 01:50:59 PST
Pull request:
https://github.com/WebKit/WebKit/pull/38371
EWS
Comment 4
2024-12-25 04:44:17 PST
Committed
288286@main
(3bb614e73c44): <
https://commits.webkit.org/288286@main
> Reviewed commits have been landed. Closing PR #38371 and removing active labels.
Note
You need to
log in
before you can comment on or make changes to this bug.
Top of Page
Format For Printing
XML
Clone This Bug