Implement n4169 - Add invoke function template
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@242195 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
@@ -2447,6 +2447,15 @@ struct _LIBCPP_TYPE_VIS_ONLY hash
|
||||
};
|
||||
#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
|
||||
|
Reference in New Issue
Block a user