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
303746
Improve readability of StyleLogicalHeight by adopting a switch on statement.
https://bugs.webkit.org/show_bug.cgi?id=303746
Summary
Improve readability of StyleLogicalHeight by adopting a switch on statement.
Karl Dubost
Reported
2025-12-08 04:13:56 PST
See Sam Weining comment on
https://github.com/WebKit/WebKit/pull/54635#discussion_r2583134648
Please consider using the switchOn() form here. While a bit more verbose, I think it ends up making things more clear. WTF::switchOn(styleLogicalHeight, [&](const Style::PreferredSize::Fixed& fixed) { ... }, [&](Style::IsPercentageOrCalc auto const& percentageOrCalc) { ... }, [&](const CSS::Keyword::FitContent&) { ... }, [&](const CSS::Keyword::WebkitFillAvailable&) { ... }, [&](const CSS::Keyword::MinContent&) { ... }, [&](const CSS::Keyword::MaxContent&) { ... }, [&](const CSS::Keyword::Intrinsic&) { ... }, [&](const CSS::Keyword::MinIntrinsic&) { ... }, [&](const CSS::Keyword::Auto&) { ... } );
Attachments
Add attachment
proposed patch, testcase, etc.
Radar WebKit Bug Importer
Comment 1
2025-12-15 04:14:11 PST
<
rdar://problem/166529986
>
zak ridouh
Comment 2
2026-02-19 23:12:36 PST
Pull request:
https://github.com/WebKit/WebKit/pull/59062
EWS
Comment 3
2026-07-18 15:55:57 PDT
Committed
317491@main
(27059d44ca36): <
https://commits.webkit.org/317491@main
> Reviewed commits have been landed. Closing PR #59062 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