RESOLVED FIXED 234192
Add a std::nullptr_t constructor for RefPtr
https://bugs.webkit.org/show_bug.cgi?id=234192
Summary Add a std::nullptr_t constructor for RefPtr
Don Olmstead
Reported 2021-12-10 21:08:18 PST
Both std::unique_ptr and std::shared_ptr have a constexpr default constructor and a constexpr constructor for std::nullptr_t. Do the same with RefPtr.
Attachments
WIP Patch (8.05 KB, patch)
2021-12-10 21:14 PST, Don Olmstead
ews-feeder: commit-queue-
WIP Patch (9.05 KB, patch)
2021-12-10 23:13 PST, Don Olmstead
ews-feeder: commit-queue-
WIP Patch (9.54 KB, patch)
2021-12-11 08:34 PST, Don Olmstead
no flags
Patch (13.19 KB, patch)
2021-12-11 09:31 PST, Don Olmstead
no flags
Don Olmstead
Comment 1 2021-12-10 21:14:57 PST Comment hidden (obsolete)
Don Olmstead
Comment 2 2021-12-10 23:13:16 PST Comment hidden (obsolete)
Don Olmstead
Comment 3 2021-12-11 08:34:02 PST Comment hidden (obsolete)
Don Olmstead
Comment 4 2021-12-11 09:31:04 PST
Yusuke Suzuki
Comment 5 2021-12-11 12:09:30 PST
Comment on attachment 446892 [details] Patch r=me
EWS
Comment 6 2021-12-11 12:50:17 PST
Committed r286917 (245143@main): <https://commits.webkit.org/245143@main> All reviewed patches have been landed. Closing bug and clearing flags on attachment 446892 [details].
Radar WebKit Bug Importer
Comment 7 2021-12-11 12:51:18 PST
Darin Adler
Comment 8 2021-12-14 20:36:45 PST
I don’t think this patch actually optimizes any generated code because I’m pretty sure the old constructor got inlined and collapsed to just zero-initialization. But I like that this catches us using 0 by accident, and that it's constexpr.
Note You need to log in before you can comment on or make changes to this bug.