[Webkit-unassigned] [Bug 184012] Unable to use HashMap<WebCore::SecurityOriginData, Ref<WebSWServerToContextConnection>> type in StorageProcess.h

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Tue Mar 27 10:07:59 PDT 2018


https://bugs.webkit.org/show_bug.cgi?id=184012

--- Comment #6 from Chris Dumez <cdumez at apple.com> ---
(In reply to Darin Adler from comment #5)
> So we consider it a programming error to move from a Ref that is null. But
> we want to use null values in the hash table. I think the best way to work
> around this is in the hash table machinery rather than in Ref; I don’t think
> we should use a value other than nullptr for empty since I think it would
> hurt efficiency.
> 
> For this specific case, I think we could figure out how to make
> emptyValueIsZero be true for SecurityOriginData. I am pretty sure that works
> even for std::optional.

Fixing it only for SecurityOriginData would not be optimal IMO. Someone else is going to get caught by this in the future for another key type's whose emptyValueIsZero is false.

-- 
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/20180327/58be9526/attachment-0001.html>


More information about the webkit-unassigned mailing list