[Webkit-unassigned] [Bug 221294] conic-gradient with stops starting after 1turn is blank
bugzilla-daemon at webkit.org
bugzilla-daemon at webkit.org
Mon Mar 22 13:12:21 PDT 2021
https://bugs.webkit.org/show_bug.cgi?id=221294
--- Comment #4 from Antti Koivisto <koivisto at iki.fi> ---
Comment on attachment 423887
--> https://bugs.webkit.org/attachment.cgi?id=423887
Patch
View in context: https://bugs.webkit.org/attachment.cgi?id=423887&action=review
>> Source/WebCore/ChangeLog:9
>> + Tests: web-platform-tests/css/css-images/normalization-conic-2.html
>
> Please add a description here of the bug and what you changed to fix it.
The test is currently marked failing in LayoutTests/TestExpectations. The patch should remove that line so the test runs.
> Source/WebCore/css/CSSGradientValue.cpp:243
> + while (firstZeroOrGreaterIndex < numStops && * stops[firstZeroOrGreaterIndex].offset < 0) {
WebKit coding style is '*stops' without a space. See https://webkit.org/code-style-guidelines/ for more.
> Source/WebCore/css/CSSGradientValue.cpp:245
> + firstZeroOrGreaterIndex++;
> }
"One-line control clauses should not use braces unless comments are included or a single statement spans multiple lines"
> Source/WebCore/css/CSSGradientValue.cpp:271
> + while (lastOneOrLessIndex > 0 && *stops[lastOneOrLessIndex].offset > 1) {
> + lastOneOrLessIndex--;
> }
same here
> Source/WebCore/css/CSSGradientValue.cpp:290
> - stops[i].offset = 1;
> + *stops[i].offset = 1;
I suppose this saves a branch if we know stop Optionals are already initialized. Not sure if that is meaningful, at least it should be done consistently in other offset assignments in this function too.
--
You are receiving this mail because:
You are the assignee for the bug.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.webkit.org/pipermail/webkit-unassigned/attachments/20210322/4d58d3bb/attachment.htm>
More information about the webkit-unassigned
mailing list