Replace std::result_of_t with std::invoke_result_t following its deprecation in C++17
This fixes the build against libc++ with -std=c++20, for which std::result_of_t is not declared.
Thanks to Dmitry Kalinkin for the fix.
This fixes the build against libc++ with -std=c++20, for which std::result_of_t is not declared.
Thanks to Dmitry Kalinkin for the fix.