Branch: refs/heads/main Home: https://github.com/WebKit/WebKit Commit: dcf98ac5a51f1c64283ce400354032109be95cef https://github.com/WebKit/WebKit/commit/dcf98ac5a51f1c64283ce400354032109be95cef Author: Sam Weinig <wei...@apple.com> Date: 2022-11-03 (Thu, 03 Nov 2022)
Changed paths: M Source/WebCore/css/parser/CSSPropertyParserHelpers.cpp Log Message: ----------- Add helper function to match identifiers and return a corresponding enum mapped enum value for CSS property parser https://bugs.webkit.org/show_bug.cgi?id=247326 rdar://101878937 Reviewed by Simon Fraser. Utilize SortedArrayMap and two new helpers (consume/peekIdentUsingMapping) to create a consistent pattern for mapping CSSValueIDs to enum values. * Source/WebCore/css/parser/CSSPropertyParserHelpers.cpp: (WebCore::CSSPropertyParserHelpers::consumeIdentUsingMapping): (WebCore::CSSPropertyParserHelpers::peekIdentUsingMapping): (WebCore::CSSPropertyParserHelpers::parseColorContrastFunctionParameters): (WebCore::CSSPropertyParserHelpers::consumeHueInterpolationMethod): (WebCore::CSSPropertyParserHelpers::consumePrefixedRadialGradient): (WebCore::CSSPropertyParserHelpers::consumeRadialGradient): (WebCore::CSSPropertyParserHelpers::consumePrefixedLinearGradient): (WebCore::CSSPropertyParserHelpers::consumeLinearGradient): Canonical link: https://commits.webkit.org/256290@main _______________________________________________ webkit-changes mailing list webkit-changes@lists.webkit.org https://lists.webkit.org/mailman/listinfo/webkit-changes