Skip to content

Commit

Permalink
Fix incorrect doc comments.
Browse files Browse the repository at this point in the history
  • Loading branch information
Thomas Bächler committed Jun 17, 2020
1 parent b27fc51 commit 1347de0
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
5 changes: 5 additions & 0 deletions lock_api/src/mutex.rs
Original file line number Diff line number Diff line change
Expand Up @@ -94,6 +94,11 @@ pub unsafe trait RawMutexFair: RawMutex {
/// by `lock`, however it can be much more efficient in the case where there
/// are no waiting threads.
///
/// # Safety
///
/// This method may only be called if the mutex is held in the current context, see
/// the documentation of [`unlock`].
///
/// [`unlock`]: trait.RawMutex.html#tymethod.unlock
unsafe fn bump(&self) {
self.unlock_fair();
Expand Down
2 changes: 2 additions & 0 deletions lock_api/src/remutex.rs
Original file line number Diff line number Diff line change
Expand Up @@ -161,6 +161,8 @@ impl<R: RawMutexFair, G: GetThreadId> RawReentrantMutex<R, G> {
/// by `lock`, however it can be much more efficient in the case where there
/// are no waiting threads.
///
/// # Safety
///
/// This method may only be called if the mutex is held by the current thread.
#[inline]
pub unsafe fn bump(&self) {
Expand Down

0 comments on commit 1347de0

Please sign in to comment.