Commit f7bf375c authored by Yedidya Feldblum's avatar Yedidya Feldblum Committed by Facebook Github Bot

"Upgrade" wording in Synchronized

Summary:
[Folly] "Upgrade" wording in `Synchronized`.

(Note: this ignores all push blocking failures!)

Reviewed By: aary

Differential Revision: D13484147

fbshipit-source-id: 5ccaac2de5e03986885000869a862d2a37ab5751
parent 15be4529
...@@ -232,7 +232,7 @@ class SynchronizedBase<Subclass, detail::MutexLevel::SHARED> { ...@@ -232,7 +232,7 @@ class SynchronizedBase<Subclass, detail::MutexLevel::SHARED> {
* *
* This class provides all the functionality provided by the SynchronizedBase * This class provides all the functionality provided by the SynchronizedBase
* specialization for shared mutexes and a ulock() method that returns an * specialization for shared mutexes and a ulock() method that returns an
* upgradable lock RAII proxy * upgrade lock RAII proxy
*/ */
template <class Subclass> template <class Subclass>
class SynchronizedBase<Subclass, detail::MutexLevel::UPGRADE> class SynchronizedBase<Subclass, detail::MutexLevel::UPGRADE>
...@@ -1444,8 +1444,8 @@ class LockedPtr : public LockedPtrBase< ...@@ -1444,8 +1444,8 @@ class LockedPtr : public LockedPtrBase<
} }
/*************************************************************************** /***************************************************************************
* Upgradable lock methods. * Upgrade lock methods.
* These are disabled via SFINAE when the mutex is not upgradable * These are disabled via SFINAE when the mutex is not an upgrade mutex.
**************************************************************************/ **************************************************************************/
/** /**
* Move the locked ptr from an upgrade state to an exclusive state. The * Move the locked ptr from an upgrade state to an exclusive state. The
......
...@@ -375,7 +375,7 @@ TEST_F(SynchronizedLockTest, TestCopyConstructibleValues) { ...@@ -375,7 +375,7 @@ TEST_F(SynchronizedLockTest, TestCopyConstructibleValues) {
std::is_copy_assignable<folly::Synchronized<CopyConstructible>>::value); std::is_copy_assignable<folly::Synchronized<CopyConstructible>>::value);
} }
TEST_F(SynchronizedLockTest, UpgradableLocking) { TEST_F(SynchronizedLockTest, UpgradeLocking) {
folly::Synchronized<int, FakeAllPowerfulAssertingMutex> sync; folly::Synchronized<int, FakeAllPowerfulAssertingMutex> sync;
// sanity assert // sanity assert
...@@ -456,7 +456,7 @@ TEST_F(SynchronizedLockTest, UpgradableLocking) { ...@@ -456,7 +456,7 @@ TEST_F(SynchronizedLockTest, UpgradableLocking) {
FakeAllPowerfulAssertingMutexInternal::CurrentLockState::UNLOCKED); FakeAllPowerfulAssertingMutexInternal::CurrentLockState::UNLOCKED);
} }
TEST_F(SynchronizedLockTest, UpgradableLockingWithULock) { TEST_F(SynchronizedLockTest, UpgradeLockingWithULock) {
folly::Synchronized<int, FakeAllPowerfulAssertingMutex> sync; folly::Synchronized<int, FakeAllPowerfulAssertingMutex> sync;
// sanity assert // sanity assert
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment