aboutsummaryrefslogtreecommitdiff
path: root/system/lib/libcxx/future.cpp
diff options
context:
space:
mode:
authorAlon Zakai <alonzakai@gmail.com>2013-04-01 12:55:33 -0700
committerAlon Zakai <alonzakai@gmail.com>2013-04-01 12:55:33 -0700
commit8408257cd66435af849f493c10c7f0e8d1d5fa3b (patch)
tree8b05963e8608b22f71620f512679d7cd5b1de548 /system/lib/libcxx/future.cpp
parenta8e4801c7d38033fff760ea26a4579aa324e303e (diff)
parent36600f34ef0ec2cf75165be3753567e256f514db (diff)
Merge branch 'incoming'
Diffstat (limited to 'system/lib/libcxx/future.cpp')
-rw-r--r--system/lib/libcxx/future.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/system/lib/libcxx/future.cpp b/system/lib/libcxx/future.cpp
index ff591105..7d9a5b5d 100644
--- a/system/lib/libcxx/future.cpp
+++ b/system/lib/libcxx/future.cpp
@@ -29,7 +29,7 @@ __future_error_category::name() const _NOEXCEPT
string
__future_error_category::message(int ev) const
{
- switch (ev)
+ switch (static_cast<future_errc>(ev))
{
case future_errc::broken_promise:
return string("The associated promise has been destructed prior "
@@ -47,7 +47,7 @@ __future_error_category::message(int ev) const
}
const error_category&
-future_category()
+future_category() _NOEXCEPT
{
static __future_error_category __f;
return __f;
@@ -78,8 +78,8 @@ __assoc_sub_state::set_value()
throw future_error(make_error_code(future_errc::promise_already_satisfied));
#endif
__state_ |= __constructed | ready;
- __lk.unlock();
__cv_.notify_all();
+ __lk.unlock();
}
void
@@ -152,9 +152,9 @@ __assoc_sub_state::__sub_wait(unique_lock<mutex>& __lk)
{
if (!__is_ready())
{
- if (__state_ & deferred)
+ if (__state_ & static_cast<unsigned>(deferred))
{
- __state_ &= ~deferred;
+ __state_ &= ~static_cast<unsigned>(deferred);
__lk.unlock();
__execute();
}