Move monitor related object routines to object-inl.h
Also pass through readily available self Thread. Remove unused wait method.
Rename ObjectLock.Wait to document it doesn't honor interrupts.
Change-Id: I991e5036997b3f60ee4fdf1a420beabab9a70c85
diff --git a/src/object_utils.h b/src/object_utils.h
index ea4de90..18ad312 100644
--- a/src/object_utils.h
+++ b/src/object_utils.h
@@ -46,16 +46,16 @@
obj_->MonitorExit(self_);
}
- void Wait() SHARED_LOCKS_REQUIRED(Locks::mutator_lock_) {
- return Monitor::Wait(self_, obj_, 0, 0, false, kWaiting);
+ void WaitIgnoringInterrupts() SHARED_LOCKS_REQUIRED(Locks::mutator_lock_) {
+ Monitor::Wait(self_, obj_, 0, 0, false, kWaiting);
}
void Notify() SHARED_LOCKS_REQUIRED(Locks::mutator_lock_) {
- obj_->Notify();
+ obj_->Notify(self_);
}
void NotifyAll() SHARED_LOCKS_REQUIRED(Locks::mutator_lock_) {
- obj_->NotifyAll();
+ obj_->NotifyAll(self_);
}
private: