The RetainPtr smart pointer class can't be used in HashMaps or HashSets. It needs hashing code like that in RefPtr and COMPtr.
Created attachment 59283 [details] Patch that mimics COMPtr.h's handling of hashing code.
Attachment 59283 [details] did not pass style-queue: Failed to run "['WebKitTools/Scripts/check-webkit-style', '--no-squash']" exit_code: 1 JavaScriptCore/wtf/RetainPtr.h:219: More than one command on the same line [whitespace/newline] [4] Total errors found: 1 in 2 files If any of these errors are false positives, please file a bug against check-webkit-style.
Comment on attachment 59283 [details] Patch that mimics COMPtr.h's handling of hashing code. > +++ JavaScriptCore/wtf/RetainPtr.h (working copy) > @@ -24,6 +24,7 @@ > #include "TypeTraits.h" > #include <algorithm> > #include <CoreFoundation/CoreFoundation.h> > +#include <WTF/HashTraits.h> It looks like intra-WTF includes are supposed to use quotes and no wtf/ prefix: #include "HashTraits.h" r=me
The style complaint is a false positive. I filed <https://bugs.webkit.org/show_bug.cgi?id=40941>.
Fixed in http://trac.webkit.org/changeset/61576