Core/OffsetOf: Remove constexpr (cannot be used because of reinterpret_cast)

Former-commit-id: 78142eb9033a1969f20055b2cecf1bc78152e896
This commit is contained in:
Lynix
2015-06-17 23:32:48 +02:00
parent e89b87044d
commit 80208b0dc5
3 changed files with 2 additions and 5 deletions

View File

@@ -14,8 +14,9 @@ template <typename T, typename M> T NzImplGetClassType(M T::*);
template <typename T, typename M> M NzImplGetMemberType(M T::*);
template <typename T, typename R, R T::*M>
constexpr std::size_t NzImplOffsetOf()
std::size_t NzImplOffsetOf()
{
///FIXME: reinterpret_cast is not allowed in constexpr functions
return reinterpret_cast<std::size_t>(&((static_cast<T*>(0))->*M));
}