diff options
Diffstat (limited to 'src/corelib/kernel/qpropertyprivate.h')
-rw-r--r-- | src/corelib/kernel/qpropertyprivate.h | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/src/corelib/kernel/qpropertyprivate.h b/src/corelib/kernel/qpropertyprivate.h index adc347db84..6f0e563a28 100644 --- a/src/corelib/kernel/qpropertyprivate.h +++ b/src/corelib/kernel/qpropertyprivate.h @@ -178,6 +178,15 @@ namespace detail { template<typename T, typename C> struct ExtractClassFromFunctionPointer<T C::*> { using Class = C; }; + + constexpr size_t getOffset(size_t o) + { + return o; + } + constexpr size_t getOffset(size_t (*offsetFn)()) + { + return offsetFn(); + } } // type erased guard functions, casts its arguments to the correct types |