5#ifndef INCLUDE_CPPGC_OBJECT_SIZE_TRAIT_H_
6#define INCLUDE_CPPGC_OBJECT_SIZE_TRAIT_H_
32template <
typename T,
bool = IsGarbageCollectedMixinTypeV<T>>
37 static_assert(
sizeof(T),
"T must be fully defined");
38 static_assert(IsGarbageCollectedTypeV<T>,
39 "T must be of type GarbageCollected or GarbageCollectedMixin");
42 return GetObjectSizeForGarbageCollected(&
object);
48 static_assert(
sizeof(T),
"T must be fully defined");
51 return GetObjectSizeForGarbageCollectedMixin(&
object);
Definition: allocation.h:38
Definition: object-size-trait.h:17
static size_t GetObjectSizeForGarbageCollected(const void *)
static size_t GetObjectSizeForGarbageCollectedMixin(const void *)
static size_t GetSize(const T &object)
Definition: object-size-trait.h:41
static size_t GetSize(const T &object)
Definition: object-size-trait.h:50
Definition: object-size-trait.h:33
#define V8_EXPORT
Definition: v8config.h:793