From 188a3cf74cba3ad8a19157614d556c134b5ebf47 Mon Sep 17 00:00:00 2001 From: Lioncash Date: Mon, 7 Sep 2020 00:47:43 -0400 Subject: blocking_worker: Make use of templated lambda We can simplify this a little by explicitly specifying the typename for the lambda function. --- src/core/hle/service/sockets/blocking_worker.h | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) (limited to 'src/core/hle') diff --git a/src/core/hle/service/sockets/blocking_worker.h b/src/core/hle/service/sockets/blocking_worker.h index f2be6ce5c..2d53e52b6 100644 --- a/src/core/hle/service/sockets/blocking_worker.h +++ b/src/core/hle/service/sockets/blocking_worker.h @@ -109,9 +109,8 @@ private: while (keep_running) { work_event.Wait(); - const auto visit_fn = [service, &keep_running](auto&& w) { - using T = std::decay_t; - if constexpr (std::is_same_v) { + const auto visit_fn = [service, &keep_running](T&& w) { + if constexpr (std::is_same_v, std::monostate>) { keep_running = false; } else { w.Execute(service); -- cgit v1.2.3