10 #ifndef LIBPMEMOBJ_CPP_POOL_DATA_HPP
11 #define LIBPMEMOBJ_CPP_POOL_DATA_HPP
30 set_cleanup(std::function<
void()> cleanup)
32 bool expected =
false;
36 if (initialized.compare_exchange_strong(
37 expected,
true, std::memory_order_release,
38 std::memory_order_relaxed)) {
39 this->cleanup = cleanup;
43 std::atomic<bool> initialized;
44 std::function<void()> cleanup;
Persistent memory namespace.
Definition: allocation_flag.hpp:15