Fix FunctionRef copy construction

The template constructor was mistaken as a copy constructor.
This commit is contained in:
Maxime Coste 2021-07-31 09:43:49 +10:00
parent b57dc7c512
commit 914f4f8c19

View File

@ -173,7 +173,7 @@ public:
}}
{}
template<typename Target>
template<typename Target, typename = std::enable_if_t<!std::is_same_v<FunctionRef, std::decay_t<Target>>>>
FunctionRef(Target&& target)
: m_target{&target},
m_invoker{[](void* target, Args... args) {