diff options
Diffstat (limited to 'include/mutex')
-rw-r--r-- | include/mutex | 13 |
1 files changed, 7 insertions, 6 deletions
diff --git a/include/mutex b/include/mutex index 79befbeb56fe..8526533f1402 100644 --- a/include/mutex +++ b/include/mutex @@ -206,7 +206,7 @@ _LIBCPP_BEGIN_NAMESPACE_STD class _LIBCPP_TYPE_VIS recursive_mutex { - __libcpp_mutex_t __m_; + __libcpp_recursive_mutex_t __m_; public: recursive_mutex(); @@ -221,7 +221,8 @@ public: bool try_lock() _NOEXCEPT; void unlock() _NOEXCEPT; - typedef __libcpp_mutex_t* native_handle_type; + typedef __libcpp_recursive_mutex_t* native_handle_type; + _LIBCPP_INLINE_VISIBILITY native_handle_type native_handle() {return &__m_;} }; @@ -465,7 +466,7 @@ void __unlock(_L0& __l0, _L1& __l1, _L2& __l2, _L3&... __l3) { #endif // !_LIBCPP_HAS_NO_THREADS -struct _LIBCPP_TYPE_VIS_ONLY once_flag; +struct _LIBCPP_TEMPLATE_VIS once_flag; #ifndef _LIBCPP_HAS_NO_VARIADICS @@ -485,7 +486,7 @@ void call_once(once_flag&, const _Callable&); #endif // _LIBCPP_HAS_NO_VARIADICS -struct _LIBCPP_TYPE_VIS_ONLY once_flag +struct _LIBCPP_TEMPLATE_VIS once_flag { _LIBCPP_INLINE_VISIBILITY _LIBCPP_CONSTEXPR @@ -615,7 +616,7 @@ call_once(once_flag& __flag, const _Callable& __func) #if defined(_LIBCPP_ABI_VARIADIC_LOCK_GUARD) \ && !defined(_LIBCPP_CXX03_LANG) template <> -class _LIBCPP_TYPE_VIS_ONLY lock_guard<> { +class _LIBCPP_TEMPLATE_VIS lock_guard<> { public: explicit lock_guard() {} ~lock_guard() = default; @@ -628,7 +629,7 @@ public: }; template <class ..._MArgs> -class _LIBCPP_TYPE_VIS_ONLY lock_guard +class _LIBCPP_TEMPLATE_VIS lock_guard { static_assert(sizeof...(_MArgs) >= 2, "At least 2 lock types required"); typedef tuple<_MArgs&...> _MutexTuple; |