diff options
| author | Dimitry Andric <dim@FreeBSD.org> | 2016-05-26 18:52:49 +0000 |
|---|---|---|
| committer | Dimitry Andric <dim@FreeBSD.org> | 2016-05-26 18:52:49 +0000 |
| commit | 9729cf09342823ba32d77ab1ea12b7ae84f7c904 (patch) | |
| tree | 87163f0ca4abe85acc120b605dcfa6b9c46b29cd /contrib/libc++/src/future.cpp | |
| parent | d3dd0204252966f7ae13a28bba0f49356b4d3311 (diff) | |
| parent | bb5e33f003797b67974a8893f7f2930fc51b8210 (diff) | |
Notes
Diffstat (limited to 'contrib/libc++/src/future.cpp')
| -rw-r--r-- | contrib/libc++/src/future.cpp | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/contrib/libc++/src/future.cpp b/contrib/libc++/src/future.cpp index 3132b1861af2..e1758f39df3a 100644 --- a/contrib/libc++/src/future.cpp +++ b/contrib/libc++/src/future.cpp @@ -221,10 +221,12 @@ promise<void>::~promise() { if (__state_) { +#ifndef _LIBCPP_NO_EXCEPTIONS if (!__state_->__has_value() && __state_->use_count() > 1) __state_->set_exception(make_exception_ptr( future_error(make_error_code(future_errc::broken_promise)) )); +#endif // _LIBCPP_NO_EXCEPTIONS __state_->__release_shared(); } } |
