Index: Source/heap/Visitor.h |
diff --git a/Source/heap/Visitor.h b/Source/heap/Visitor.h |
index 0bbad103de055e9d05846b8e632373c3ed7a6735..116b5199ec0623a214e1e11f4ba94ee3134da6ca 100644 |
--- a/Source/heap/Visitor.h |
+++ b/Source/heap/Visitor.h |
@@ -32,6 +32,7 @@ |
#define Visitor_h |
#include <wtf/Forward.h> |
+#include <wtf/HashSet.h> |
namespace WebCore { |
@@ -118,6 +119,20 @@ public: |
visit(*it); |
} |
+ template<typename T, size_t N> |
+ void visit(const Vector<Member<T>, N>& vector) |
+ { |
+ for (typename Vector<Member<T> >::const_iterator it = vector.begin(); it != vector.end(); ++it) |
+ visit(*it); |
+ } |
+ |
+ template<typename T> |
+ void visit(const HashSet<Member<T> >& vector) |
+ { |
+ for (typename HashSet<Member<T> >::const_iterator it = vector.begin(); it != vector.end(); ++it) |
+ visit(*it); |
+ } |
+ |
// This method adds the object to the set of objects that should have their |
// accept method called. Since not all objects have vtables we have to have |
// the callback as an explicit argument, but we can use the templated |