| 2271 | bool future_obtained; |
| 2272 | |
| 2273 | void lazy_init() |
| 2274 | { |
| 2275 | #if defined BOOST_THREAD_PROVIDES_PROMISE_LAZY |
| 2276 | #include <boost/thread/detail/atomic_undef_macros.hpp> |
| 2277 | if(!atomic_load(&future_)) |
| 2278 | { |
| 2279 | future_ptr blank; |
| 2280 | atomic_compare_exchange(&future_,&blank,future_ptr(new detail::shared_state<R>)); |
| 2281 | } |
| 2282 | #include <boost/thread/detail/atomic_redef_macros.hpp> |
| 2283 | #endif |
| 2284 | } |
| 2285 | |
| 2286 | public: |
| 2287 | BOOST_THREAD_MOVABLE_ONLY(promise) |
no test coverage detected