Chromium Code Reviews| Index: third_party/WebKit/Source/wtf/ListHashSet.h |
| diff --git a/third_party/WebKit/Source/wtf/ListHashSet.h b/third_party/WebKit/Source/wtf/ListHashSet.h |
| index 1c98df110f5a925a06b40833f13a92fc0a6f979d..7295dc934c282ab1b56eebbb97d5059f56a67883 100644 |
| --- a/third_party/WebKit/Source/wtf/ListHashSet.h |
| +++ b/third_party/WebKit/Source/wtf/ListHashSet.h |
| @@ -538,6 +538,11 @@ class ListHashSetIterator { |
| operator const_iterator() const { return m_iterator; } |
| + template <typename VisitorDispatcher> |
| + void trace(VisitorDispatcher visitor) { |
| + m_iterator.trace(visitor); |
| + } |
| + |
| private: |
| Node* getNode() { return m_iterator.getNode(); } |
| @@ -595,6 +600,12 @@ class ListHashSetConstIterator { |
| return m_position != other.m_position; |
| } |
| + template <typename VisitorDispatcher> |
| + void trace(VisitorDispatcher visitor) { |
| + visitor->trace(*m_set); |
| + visitor->trace(m_position); |
| + } |
| + |
| private: |
| Node* getNode() { return m_position; } |
| @@ -649,6 +660,11 @@ class ListHashSetReverseIterator { |
| operator const_reverse_iterator() const { return m_iterator; } |
| + template <typename VisitorDispatcher> |
| + void trace(VisitorDispatcher visitor) { |
| + m_iterator.trace(visitor); |
|
haraken
2016/12/20 02:53:05
Just to confirm: This iterator is just pointing to
sof
2016/12/20 06:37:08
Yes, the nodes in this list are separately allocat
|
| + } |
| + |
| private: |
| Node* getNode() { return m_iterator.node(); } |
| @@ -706,6 +722,12 @@ class ListHashSetConstReverseIterator { |
| return m_position != other.m_position; |
| } |
| + template <typename VisitorDispatcher> |
| + void trace(VisitorDispatcher visitor) { |
| + visitor->trace(*m_set); |
| + visitor->trace(m_position); |
| + } |
| + |
| private: |
| Node* getNode() { return m_position; } |