From 64449198588abc90ea81eb4f4810bf4ae23d59b4 Mon Sep 17 00:00:00 2001 From: Ben Caimano Date: Wed, 15 Jul 2020 22:15:46 +0000 Subject: SERVER-49548 Convert ServiceExecutor to use unique_function --- src/mongo/transport/service_executor.h | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'src/mongo/transport/service_executor.h') diff --git a/src/mongo/transport/service_executor.h b/src/mongo/transport/service_executor.h index 6a1410ae86b..d44bb704c66 100644 --- a/src/mongo/transport/service_executor.h +++ b/src/mongo/transport/service_executor.h @@ -36,6 +36,7 @@ #include "mongo/platform/bitwise_enum_operators.h" #include "mongo/transport/transport_mode.h" #include "mongo/util/duration.h" +#include "mongo/util/functional.h" namespace mongo { // This needs to be forward declared here because the service_context.h is a circular dependency. @@ -49,7 +50,7 @@ namespace transport { class ServiceExecutor { public: virtual ~ServiceExecutor() = default; - using Task = std::function; + using Task = unique_function; enum ScheduleFlags { // No flags (kEmptyFlags) specifies that this is a normal task and that the executor should // launch new threads as needed to run the task. -- cgit v1.2.1