Implement n4169 - Add invoke function template
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@242195 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/include/functional b/include/functional
index 90972bc..5ee9417 100644
--- a/include/functional
+++ b/include/functional
@@ -2447,6 +2447,15 @@
};
#endif
+
+#if _LIBCPP_STD_VER > 14
+template <class _Fn, class ..._Args>
+result_of_t<_Fn&&(_Args&&...)>
+invoke(_Fn&& __f, _Args&&... __args) {
+ return __invoke(_VSTD::forward<_Fn>(__f), _VSTD::forward<_Args>(__args)...);
+}
+#endif
+
// struct hash<T*> in <memory>
_LIBCPP_END_NAMESPACE_STD