proxygen
shared_cancellation_factory Struct Reference

Public Member Functions

auto operator() ()
 

Detailed Description

Definition at line 164 of file PushmiBenchmarks.cpp.

Member Function Documentation

auto shared_cancellation_factory::operator() ( )
inline

Definition at line 165 of file PushmiBenchmarks.cpp.

References folly::pushmi::shared_entangle(), and stop().

165  {
166  // boolean cancellation
167  bool stop = false;
168  auto set_stop = [](auto& stop) {
169  if (!!stop) {
170  *stop = true;
171  }
172  };
173  return mi::shared_entangle(stop, set_stop);
174  }
auto shared_entangle(First f, Second s) -> shared_entangled_pair< First, Second >
Definition: entangle.h:279
static void stop()

The documentation for this struct was generated from the following file: