| Index: Source/platform/heap/Visitor.h
|
| diff --git a/Source/platform/heap/Visitor.h b/Source/platform/heap/Visitor.h
|
| index 09f8b613f08e67fd420b0943ab0d366c912195a0..c918e95976fc1c1147cd5d8e9281508b6c242b9d 100644
|
| --- a/Source/platform/heap/Visitor.h
|
| +++ b/Source/platform/heap/Visitor.h
|
| @@ -923,6 +923,23 @@ private:
|
| #define WILL_BE_USING_GARBAGE_COLLECTED_MIXIN(TYPE)
|
| #endif
|
|
|
| +// Template to determine if a class is a GarbageCollectedMixin by checking if it
|
| +// has IsGarbageCollectedMixinMarker
|
| +template<typename T>
|
| +struct IsGarbageCollectedMixin {
|
| +private:
|
| + typedef char YesType;
|
| + struct NoType {
|
| + char padding[8];
|
| + };
|
| +
|
| + template <typename U> static YesType checkMarker(typename U::IsGarbageCollectedMixinMarker*);
|
| + template <typename U> static NoType checkMarker(...);
|
| +
|
| +public:
|
| + static const bool value = sizeof(checkMarker<T>(nullptr)) == sizeof(YesType);
|
| +};
|
| +
|
| #if ENABLE(GC_PROFILING)
|
| template<typename T>
|
| struct TypenameStringTrait {
|
|
|