diff options
| author | David Majnemer <david.majnemer@gmail.com> | 2014-03-17 20:19:44 +0000 |
|---|---|---|
| committer | David Majnemer <david.majnemer@gmail.com> | 2014-03-17 20:19:44 +0000 |
| commit | 7ec93f9b1c17c389a3e8a78c43f4178aa9ed1e72 (patch) | |
| tree | 64f42a233e77c43c5b2084ab59ef5378d7302b6e /libcxx/include/shared_mutex | |
| parent | 2fd6f512e5850beba380424f8cf677d452bd0f63 (diff) | |
| download | bcm5719-llvm-7ec93f9b1c17c389a3e8a78c43f4178aa9ed1e72.tar.gz bcm5719-llvm-7ec93f9b1c17c389a3e8a78c43f4178aa9ed1e72.zip | |
Implement N3891: A proposal to rename shared_mutex to shared_timed_mutex
This is as straightforward as it sounds, a renamed from shared_mutex to
shared_timed_mutex.
Note that libcxx .dylib and .so files built with c++14 support need to
be rebuilt.
llvm-svn: 204078
Diffstat (limited to 'libcxx/include/shared_mutex')
| -rw-r--r-- | libcxx/include/shared_mutex | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/libcxx/include/shared_mutex b/libcxx/include/shared_mutex index 5b1f53aafe8..76610548df8 100644 --- a/libcxx/include/shared_mutex +++ b/libcxx/include/shared_mutex @@ -19,14 +19,14 @@ namespace std { -class shared_mutex +class shared_timed_mutex { public: - shared_mutex(); - ~shared_mutex(); + shared_timed_mutex(); + ~shared_timed_mutex(); - shared_mutex(const shared_mutex&) = delete; - shared_mutex& operator=(const shared_mutex&) = delete; + shared_timed_mutex(const shared_timed_mutex&) = delete; + shared_timed_mutex& operator=(const shared_timed_mutex&) = delete; // Exclusive ownership void lock(); // blocking @@ -114,7 +114,7 @@ template <class Mutex> _LIBCPP_BEGIN_NAMESPACE_STD -class _LIBCPP_TYPE_VIS shared_mutex +class _LIBCPP_TYPE_VIS shared_timed_mutex { mutex __mut_; condition_variable __gate1_; @@ -124,11 +124,11 @@ class _LIBCPP_TYPE_VIS shared_mutex static const unsigned __write_entered_ = 1U << (sizeof(unsigned)*__CHAR_BIT__ - 1); static const unsigned __n_readers_ = ~__write_entered_; public: - shared_mutex(); - _LIBCPP_INLINE_VISIBILITY ~shared_mutex() = default; + shared_timed_mutex(); + _LIBCPP_INLINE_VISIBILITY ~shared_timed_mutex() = default; - shared_mutex(const shared_mutex&) = delete; - shared_mutex& operator=(const shared_mutex&) = delete; + shared_timed_mutex(const shared_timed_mutex&) = delete; + shared_timed_mutex& operator=(const shared_timed_mutex&) = delete; // Exclusive ownership void lock(); @@ -163,7 +163,7 @@ public: template <class _Clock, class _Duration> bool -shared_mutex::try_lock_until( +shared_timed_mutex::try_lock_until( const chrono::time_point<_Clock, _Duration>& __abs_time) { unique_lock<mutex> __lk(__mut_); @@ -198,7 +198,7 @@ shared_mutex::try_lock_until( template <class _Clock, class _Duration> bool -shared_mutex::try_lock_shared_until( +shared_timed_mutex::try_lock_shared_until( const chrono::time_point<_Clock, _Duration>& __abs_time) { unique_lock<mutex> __lk(__mut_); |

