We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent 6351807 commit 600e7feCopy full SHA for 600e7fe
src/MoveOnlyFunction.h
@@ -28,6 +28,9 @@ SOFTWARE.
28
#define _ANY_INVOKABLE_H_
29
30
#include <functional>
31
+
32
+#if !defined(__cpp_lib_move_only_function) || __cpp_lib_move_only_function < 202110L
33
34
#include <memory>
35
#include <type_traits>
36
@@ -374,4 +377,13 @@ namespace uWS {
374
377
using MoveOnlyFunction = ofats::any_invocable<T>;
375
378
}
376
379
380
+#else // !defined(__cpp_lib_move_only_function) || __cpp_lib_move_only_function < 202110L
381
382
+namespace uWS {
383
+ template <class T>
384
+ using MoveOnlyFunction = std::move_only_function<T>;
385
+}
386
387
+#endif
388
389
#endif // _ANY_INVOKABLE_H_
0 commit comments