| Summary: | Implement CSSNumericValue.mul, div, add, sub, max, and min | ||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
| Product: | WebKit | Reporter: | Alex Christensen <achristensen> | ||||||||||
| Component: | New Bugs | Assignee: | Alex Christensen <achristensen> | ||||||||||
| Status: | RESOLVED FIXED | ||||||||||||
| Severity: | Normal | CC: | esprehn+autocc, ews-watchlist, glenn, gyuyoung.kim, macpherson, menard, simon.fraser, webkit-bug-importer | ||||||||||
| Priority: | P2 | Keywords: | InRadar | ||||||||||
| Version: | WebKit Nightly Build | ||||||||||||
| Hardware: | Unspecified | ||||||||||||
| OS: | Unspecified | ||||||||||||
| Attachments: |
|
||||||||||||
|
Description
Alex Christensen
2022-03-21 14:02:50 PDT
Created attachment 455275 [details]
Patch
Created attachment 455278 [details]
Patch
Created attachment 455279 [details]
Patch
Comment on attachment 455279 [details] Patch View in context: https://bugs.webkit.org/attachment.cgi?id=455279&action=review > Source/WebCore/css/typedom/CSSNumericValue.cpp:56 > + return static_cast<CSSMathNegate&>(value.get()).value(); Shouldn't we be using is<> and downcast<> here and everywhere? > Source/WebCore/css/typedom/CSSNumericValue.cpp:72 > + if (thisValue.unit() == "number") { Maybe units should be AtomStrings. (In reply to Simon Fraser (smfr) from comment #4) > Comment on attachment 455279 [details] > Patch > > View in context: > https://bugs.webkit.org/attachment.cgi?id=455279&action=review > > > Source/WebCore/css/typedom/CSSNumericValue.cpp:56 > > + return static_cast<CSSMathNegate&>(value.get()).value(); > > Shouldn't we be using is<> and downcast<> here and everywhere? Yes. That makes the code much nicer. > > Source/WebCore/css/typedom/CSSNumericValue.cpp:72 > > + if (thisValue.unit() == "number") { > > Maybe units should be AtomStrings. Or just CSSUnitType. I added a fixme comment because that's more involved and less related to the other changes. Created attachment 455316 [details]
Patch
Committed r291597 (248690@main): <https://commits.webkit.org/248690@main> All reviewed patches have been landed. Closing bug and clearing flags on attachment 455316 [details]. |