#ifndef INCLUDE_CPPGC_INTERNAL_FINALIZER_TRAIT_H_
#define INCLUDE_CPPGC_INTERNAL_FINALIZER_TRAIT_H_
#include <type_traits>
#include "cppgc/type-traits.h"
namespace cppgc {
namespace internal {
FinalizationCallback;
template <typename T, typename = void>
struct HasFinalizeGarbageCollectedObject : std::false_type { … };
HasFinalizeGarbageCollectedObject<T, std::void_t<decltype(std::declval<T>().FinalizeGarbageCollectedObject())>>;
template <typename T, bool isFinalized>
struct FinalizerTraitImpl;
FinalizerTraitImpl<T, true>;
FinalizerTraitImpl<T, false>;
template <typename T>
struct FinalizerTrait { … };
template <typename T>
constexpr FinalizationCallback FinalizerTrait<T>::kCallback;
}
}
#endif