Bug 221677 - Rework RGB color types to be more declarative to reduce code duplication and make progress toward better automatic conversion
Summary: Rework RGB color types to be more declarative to reduce code duplication and ...
Status: RESOLVED FIXED
Alias: None
Product: WebKit
Classification: Unclassified
Component: Platform (show other bugs)
Version: WebKit Nightly Build
Hardware: Unspecified Unspecified
: P2 Normal
Assignee: Sam Weinig
URL:
Keywords: InRadar
Depends on:
Blocks:
 
Reported: 2021-02-10 08:47 PST by Sam Weinig
Modified: 2021-02-11 08:37 PST (History)
12 users (show)

See Also:


Attachments
Patch (73.41 KB, patch)
2021-02-10 11:14 PST, Sam Weinig
ews-feeder: commit-queue-
Details | Formatted Diff | Diff
Patch (73.26 KB, patch)
2021-02-10 17:20 PST, Sam Weinig
no flags Details | Formatted Diff | Diff

Note You need to log in before you can comment on or make changes to this bug.
Description Sam Weinig 2021-02-10 08:47:04 PST
Rework RGB color types to be more declarative to reduce code duplication and make progress toward better automatic conversion.
Comment 1 Sam Weinig 2021-02-10 11:14:10 PST Comment hidden (obsolete)
Comment 2 Sam Weinig 2021-02-10 17:20:05 PST
Created attachment 419927 [details]
Patch
Comment 3 Darin Adler 2021-02-11 08:15:52 PST
Comment on attachment 419927 [details]
Patch

View in context: https://bugs.webkit.org/attachment.cgi?id=419927&action=review

> Source/WebCore/ChangeLog:48
> +        more places now, and the deduction guides we had been using don't work, so we must explicitly specify

A little sad to lose the deduction guides.

> Source/WebCore/ChangeLog:54
> +        intend to remove in a previous patch, but I am not actual sure is necessary. While I work that out, 

Even though I am the one who pointed it out, I think it’s not necessary.
Comment 4 Sam Weinig 2021-02-11 08:31:58 PST
(In reply to Darin Adler from comment #3)
> Comment on attachment 419927 [details]
> Patch
> 
> View in context:
> https://bugs.webkit.org/attachment.cgi?id=419927&action=review
> 
> > Source/WebCore/ChangeLog:48
> > +        more places now, and the deduction guides we had been using don't work, so we must explicitly specify
> 
> A little sad to lose the deduction guides.

Me too, though I think it is the right tradeoff for the time being. I believe c++20 fixes this. Interestingly, it is the same paper that fixes the inherited constructor issue I noted in a previous patch - http://www.open-std.org/jtc1/sc22/wg21/docs/papers/2019/p1021r5.html

(I seem to running up against the limits of modern c++ :) ).
Comment 5 EWS 2021-02-11 08:36:36 PST
Committed r272731: <https://commits.webkit.org/r272731>

All reviewed patches have been landed. Closing bug and clearing flags on attachment 419927 [details].
Comment 6 Radar WebKit Bug Importer 2021-02-11 08:37:15 PST
<rdar://problem/74235403>