Capture this instead of all references in scope for call to std::visit to route CoordinatorWorker messages
This commit is contained in:
parent
25fdb1a1f0
commit
7e6ec8bb26
@ -142,7 +142,7 @@ class CoordinatorWorker {
|
||||
Message message = queue_.Pop();
|
||||
|
||||
const bool should_continue =
|
||||
std::visit([&](auto &&msg) { return Process(std::forward<decltype(msg)>(msg)); }, std::move(message));
|
||||
std::visit([this](auto &&msg) { return Process(std::forward<decltype(msg)>(msg)); }, std::move(message));
|
||||
|
||||
if (!should_continue) {
|
||||
return;
|
||||
|
Loading…
Reference in New Issue
Block a user