Make cv_status a class enum. Fixes PR18314. Thanks to Andersca for the report and the patch.

git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@197921 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
Marshall Clow
2013-12-23 22:14:27 +00:00
parent f1ebe26bdb
commit 239bc42b53
2 changed files with 7 additions and 13 deletions

View File

@@ -254,19 +254,13 @@ void
swap(unique_lock<_Mutex>& __x, unique_lock<_Mutex>& __y) _NOEXCEPT
{__x.swap(__y);}
struct _LIBCPP_TYPE_VIS cv_status
//enum class cv_status
_LIBCPP_DECLARE_STRONG_ENUM(cv_status)
{
enum __lx {
no_timeout,
timeout
};
__lx __v_;
_LIBCPP_INLINE_VISIBILITY cv_status(__lx __v) : __v_(__v) {}
_LIBCPP_INLINE_VISIBILITY operator int() const {return __v_;}
no_timeout,
timeout
};
_LIBCPP_DECLARE_STRONG_ENUM_EPILOG(cv_status)
class _LIBCPP_TYPE_VIS condition_variable
{