5 #ifndef INCLUDE_CPPGC_INTERNAL_POINTER_POLICIES_H_
6 #define INCLUDE_CPPGC_INTERNAL_POINTER_POLICIES_H_
11 #include "cppgc/internal/write-barrier.h"
12 #include "cppgc/source-location.h"
18 class PersistentRegion;
21 class StrongMemberTag;
23 class UntracedMemberTag;
66 : location_(location) {}
88 #if CPPGC_SUPPORTS_OBJECT_NAMES
95 using IsStrongPersistent = std::true_type;
101 using IsStrongPersistent = std::false_type;
107 template <
typename T,
typename WeaknessPolicy,
108 typename LocationPolicy = DefaultLocationPolicy,
109 typename CheckingPolicy = DefaultCheckingPolicy>
111 template <
typename T,
typename WeaknessTag,
typename WriteBarrierPolicy,
112 typename CheckingPolicy = DefaultCheckingPolicy>
118 template <
typename T>
120 static constexpr intptr_t kSentinelValue = 1;
121 return reinterpret_cast<T*>(kSentinelValue);