[webkit-reviews] review granted: [Bug 92137] Create a specialized pair for use in HashMap iterators : [Attachment 154102] Patch

bugzilla-daemon at webkit.org bugzilla-daemon at webkit.org
Tue Jul 24 10:48:39 PDT 2012


Ryosuke Niwa <rniwa at webkit.org> has granted Caio Marcelo de Oliveira Filho
<cmarcelo at webkit.org>'s request for review:
Bug 92137: Create a specialized pair for use in HashMap iterators
https://bugs.webkit.org/show_bug.cgi?id=92137

Attachment 154102: Patch
https://bugs.webkit.org/attachment.cgi?id=154102&action=review

------- Additional Comments from Ryosuke Niwa <rniwa at webkit.org>
View in context: https://bugs.webkit.org/attachment.cgi?id=154102&action=review


> Source/WTF/wtf/HashTable.h:294
> +    template<typename T, typename U> inline void
hashTableSwap(KeyValuePair<T, U>& a, KeyValuePair<T, U>& b)

Do we need to keep the one with std::pair?

> Source/WTF/wtf/HashTraits.h:195
> +	   KeyValuePair() : first(), second() { }
> +	   KeyValuePair(const KeyTypeArg& key, const ValueTypeArg& value) :
first(key), second(value) { }
> +
> +	   template <typename OtherKeyType, typename OtherValueType>
> +	   KeyValuePair(const KeyValuePair<OtherKeyType, OtherValueType>&
other) : first(other.first), second(other.second) { }

Please put each variable initialization on a separate line.

> Source/WebKit2/Platform/CoreIPC/ArgumentCoders.h:76
> +    static void encode(ArgumentEncoder* encoder, const
WTF::KeyValuePair<KeyType, ValueType>& pair)

Do we need to keep the one with std::pair?


More information about the webkit-reviews mailing list