// Copyright 2018 The Chromium Authors // Use of this source code is governed by a BSD-style license that can be // found in the LICENSE file. #ifndef THIRD_PARTY_BLINK_RENDERER_PLATFORM_HEAP_HEAP_TRAITS_H_ #define THIRD_PARTY_BLINK_RENDERER_PLATFORM_HEAP_HEAP_TRAITS_H_ #include <type_traits> #include "third_party/blink/renderer/platform/heap/collection_support/heap_vector.h" #include "third_party/blink/renderer/platform/heap/member.h" #include "third_party/blink/renderer/platform/wtf/type_traits.h" namespace blink { // Given a type T, returns a type that is either Member<T> or just T depending // on whether T is a garbage-collected type. AddMemberIfNeeded; // Given a type T, returns a type that is either HeapVector<T>, // HeapVector<Member<T>> or Vector<T> depending on T. VectorOf; // Given types T and U, returns a type that is one of the following: // - HeapVector<std::pair<V, X>> // (where V is either T or Member<T> and X is either U or Member<U>) // - Vector<std::pair<T, U>> VectorOfPairs; } // namespace blink #endif // THIRD_PARTY_BLINK_RENDERER_PLATFORM_HEAP_HEAP_TRAITS_H_