From 99cae679b907eeff24c997a888d47d938e1ea03b Mon Sep 17 00:00:00 2001 From: aozhiwei Date: Tue, 16 May 2023 22:44:48 +0800 Subject: [PATCH] 1 --- server/robotserver/coroutine.cc | 12 ++---------- 1 file changed, 2 insertions(+), 10 deletions(-) diff --git a/server/robotserver/coroutine.cc b/server/robotserver/coroutine.cc index cccdaa9e..fbc05807 100644 --- a/server/robotserver/coroutine.cc +++ b/server/robotserver/coroutine.cc @@ -5,19 +5,11 @@ Coroutine::Coroutine(std::function cb) { cb_ = cb; - #if 0 source_ = std::make_shared::pull_type> ( - [&] (boost::coroutines2::coroutine::pull_type& sink) + [this] (boost::coroutines2::coroutine::push_type& sink) { - - }); - #endif - boost::coroutines2::coroutine::pull_type source - ( - [&] (boost::coroutines2::coroutine::push_type& sink) - { - + cb_(this); }); }