diff options
Diffstat (limited to 'libbutl/utility.ixx')
-rw-r--r-- | libbutl/utility.ixx | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/libbutl/utility.ixx b/libbutl/utility.ixx index e17462a..1aa116b 100644 --- a/libbutl/utility.ixx +++ b/libbutl/utility.ixx @@ -213,11 +213,11 @@ namespace butl return nullopt; } - template <typename F> + template <typename F, typename P> inline F - function_cast (void* p) + function_cast (P* p) { - union { void* p; F f; } r; + union { P* p; F f; } r; r.p = p; return r.f; } |