[webkit-changes] [WebKit/WebKit] ec3382: Fix handling of calculated values in CSSStyleValue...

Chris Dumez noreply at github.com
Wed Nov 30 19:12:17 PST 2022


  Branch: refs/heads/main
  Home:   https://github.com/WebKit/WebKit
  Commit: ec3382a6412fca39ba4041e39c660f4c4c6355e5
      https://github.com/WebKit/WebKit/commit/ec3382a6412fca39ba4041e39c660f4c4c6355e5
  Author: Chris Dumez <cdumez at apple.com>
  Date:   2022-11-30 (Wed, 30 Nov 2022)

  Changed paths:
    M LayoutTests/imported/w3c/web-platform-tests/css/css-typed-om/idlharness-expected.txt
    M LayoutTests/imported/w3c/web-platform-tests/css/css-typed-om/stylevalue-normalization/transformvalue-normalization.tentative-expected.txt
    M Source/WebCore/css/calc/CSSCalcValue.h
    M Source/WebCore/css/typedom/CSSNumericValue.cpp
    M Source/WebCore/css/typedom/CSSNumericValue.h
    M Source/WebCore/css/typedom/CSSStyleValueFactory.cpp

  Log Message:
  -----------
  Fix handling of calculated values in CSSStyleValue.parse()
https://bugs.webkit.org/show_bug.cgi?id=248414

Reviewed by Geoffrey Garen.

Calling CSSStyleValue.parse() with a `calc()` would return a generic CSSStyleValue
instead of the correct CSSMathValue subclass (e.g. CSSMathSum). This was causing
the CSSMathSum tests to fail in idlharness.html.

* LayoutTests/imported/w3c/web-platform-tests/css/css-typed-om/idlharness-expected.txt:
* LayoutTests/imported/w3c/web-platform-tests/css/css-typed-om/stylevalue-normalization/transformvalue-normalization.tentative-expected.txt:
* Source/WebCore/css/calc/CSSCalcValue.h:
* Source/WebCore/css/typedom/CSSNumericValue.cpp:
(WebCore::reifyMathExpression):
(WebCore::reifyMathExpressions):
(WebCore::CSSNumericValue::reifyMathExpression):
* Source/WebCore/css/typedom/CSSNumericValue.h:
* Source/WebCore/css/typedom/CSSStyleValue.cpp:
(WebCore::CSSStyleValue::parse):
* Source/WebCore/css/typedom/CSSStyleValueFactory.cpp:
(WebCore::CSSStyleValueFactory::reifyValue):

Canonical link: https://commits.webkit.org/257215@main




More information about the webkit-changes mailing list