OLD | NEW |
1 // Copyright 2015 The Chromium Authors. All rights reserved. | 1 // Copyright 2015 The Chromium Authors. All rights reserved. |
2 // Use of this source code is governed by a BSD-style license that can be | 2 // Use of this source code is governed by a BSD-style license that can be |
3 // found in the LICENSE file. | 3 // found in the LICENSE file. |
4 | 4 |
5 #ifndef HeapAllocator_h | 5 #ifndef HeapAllocator_h |
6 #define HeapAllocator_h | 6 #define HeapAllocator_h |
7 | 7 |
8 #include "platform/heap/Heap.h" | 8 #include "platform/heap/Heap.h" |
9 #include "platform/heap/Persistent.h" | 9 #include "platform/heap/Persistent.h" |
10 #include "platform/heap/TraceTraits.h" | 10 #include "platform/heap/TraceTraits.h" |
(...skipping 719 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
730 // objects. | 730 // objects. |
731 static const bool value = true; | 731 static const bool value = true; |
732 }; | 732 }; |
733 | 733 |
734 template <typename T, size_t inlineCapacity> | 734 template <typename T, size_t inlineCapacity> |
735 struct IsGarbageCollectedType< | 735 struct IsGarbageCollectedType< |
736 ListHashSetNode<T, blink::HeapListHashSetAllocator<T, inlineCapacity>>> { | 736 ListHashSetNode<T, blink::HeapListHashSetAllocator<T, inlineCapacity>>> { |
737 static const bool value = true; | 737 static const bool value = true; |
738 }; | 738 }; |
739 | 739 |
| 740 template <typename Set> |
| 741 struct IsGarbageCollectedType<ListHashSetIterator<Set>> { |
| 742 static const bool value = IsGarbageCollectedType<Set>::value; |
| 743 }; |
| 744 |
| 745 template <typename Set> |
| 746 struct IsGarbageCollectedType<ListHashSetConstIterator<Set>> { |
| 747 static const bool value = IsGarbageCollectedType<Set>::value; |
| 748 }; |
| 749 |
| 750 template <typename Set> |
| 751 struct IsGarbageCollectedType<ListHashSetReverseIterator<Set>> { |
| 752 static const bool value = IsGarbageCollectedType<Set>::value; |
| 753 }; |
| 754 |
| 755 template <typename Set> |
| 756 struct IsGarbageCollectedType<ListHashSetConstReverseIterator<Set>> { |
| 757 static const bool value = IsGarbageCollectedType<Set>::value; |
| 758 }; |
| 759 |
740 template <typename T, typename H> | 760 template <typename T, typename H> |
741 struct HandleHashTraits : SimpleClassHashTraits<H> { | 761 struct HandleHashTraits : SimpleClassHashTraits<H> { |
742 STATIC_ONLY(HandleHashTraits); | 762 STATIC_ONLY(HandleHashTraits); |
743 // TODO: The distinction between PeekInType and PassInType is there for | 763 // TODO: The distinction between PeekInType and PassInType is there for |
744 // the sake of the reference counting handles. When they are gone the two | 764 // the sake of the reference counting handles. When they are gone the two |
745 // types can be merged into PassInType. | 765 // types can be merged into PassInType. |
746 // TODO: Implement proper const'ness for iterator types. Requires support | 766 // TODO: Implement proper const'ness for iterator types. Requires support |
747 // in the marking Visitor. | 767 // in the marking Visitor. |
748 using PeekInType = T*; | 768 using PeekInType = T*; |
749 using PassInType = T*; | 769 using PassInType = T*; |
(...skipping 35 matching lines...) Expand 10 before | Expand all | Expand 10 after Loading... |
785 const blink::HeapHashCountedSet<Value, HashFunctions, Traits>& set, | 805 const blink::HeapHashCountedSet<Value, HashFunctions, Traits>& set, |
786 VectorType& vector) { | 806 VectorType& vector) { |
787 copyToVector(static_cast<const HashCountedSet<Value, HashFunctions, Traits, | 807 copyToVector(static_cast<const HashCountedSet<Value, HashFunctions, Traits, |
788 blink::HeapAllocator>&>(set), | 808 blink::HeapAllocator>&>(set), |
789 vector); | 809 vector); |
790 } | 810 } |
791 | 811 |
792 } // namespace WTF | 812 } // namespace WTF |
793 | 813 |
794 #endif | 814 #endif |
OLD | NEW |