diff options
Diffstat (limited to 'absl/synchronization/notification.cc')
-rw-r--r-- | absl/synchronization/notification.cc | 13 |
1 files changed, 2 insertions, 11 deletions
diff --git a/absl/synchronization/notification.cc b/absl/synchronization/notification.cc index d691cfca..e91b9038 100644 --- a/absl/synchronization/notification.cc +++ b/absl/synchronization/notification.cc @@ -22,7 +22,7 @@ #include "absl/time/time.h" namespace absl { -inline namespace lts_2019_08_08 { +ABSL_NAMESPACE_BEGIN void Notification::Notify() { MutexLock l(&this->mutex_); @@ -45,15 +45,6 @@ Notification::~Notification() { MutexLock l(&this->mutex_); } -static inline bool HasBeenNotifiedInternal( - const std::atomic<bool> *notified_yet) { - return notified_yet->load(std::memory_order_acquire); -} - -bool Notification::HasBeenNotified() const { - return HasBeenNotifiedInternal(&this->notified_yet_); -} - void Notification::WaitForNotification() const { if (!HasBeenNotifiedInternal(&this->notified_yet_)) { this->mutex_.LockWhen(Condition(&HasBeenNotifiedInternal, @@ -83,5 +74,5 @@ bool Notification::WaitForNotificationWithDeadline(absl::Time deadline) const { return notified; } -} // inline namespace lts_2019_08_08 +ABSL_NAMESPACE_END } // namespace absl |