common/parent_of_member: Replace TYPED_STORAGE define with template alias

Provides the same construct, but makes it obey namespacing.
This commit is contained in:
Lioncash 2021-01-11 17:59:02 -05:00
parent eb3cb54aa5
commit 703c57a119
2 changed files with 11 additions and 9 deletions

View file

@ -533,7 +533,7 @@ private:
}
private:
static constexpr TYPED_STORAGE(Derived) DerivedStorage = {};
static constexpr TypedStorage<Derived> DerivedStorage = {};
static_assert(GetParent(GetNode(GetPointer(DerivedStorage))) == GetPointer(DerivedStorage));
};
@ -549,7 +549,7 @@ public:
using TreeTypeImpl = impl::IntrusiveRedBlackTreeImpl;
static constexpr bool IsValid() {
TYPED_STORAGE(Derived) DerivedStorage = {};
TypedStorage<Derived> DerivedStorage = {};
return GetParent(GetNode(GetPointer(DerivedStorage))) == GetPointer(DerivedStorage);
}