Skip to content
This repository was archived by the owner on May 28, 2025. It is now read-only.

Commit 986c1fc

Browse files
committed
revise comments and descriptions of the helper functions
1 parent d560b50 commit 986c1fc

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

library/std/src/sys/hermit/mutex.rs

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -13,8 +13,7 @@ use crate::sys::hermit::abi;
1313
/// This structure behaves a lot like a common mutex. There are some differences:
1414
///
1515
/// - By using busy waiting, it can be used outside the runtime.
16-
/// - It is a so called ticket lock (https://en.wikipedia.org/wiki/Ticket_lock)
17-
/// and completly fair.
16+
/// - It is a so called ticket lock and is completly fair.
1817
#[cfg_attr(target_arch = "x86_64", repr(align(128)))]
1918
#[cfg_attr(not(target_arch = "x86_64"), repr(align(64)))]
2019
struct Spinlock<T: ?Sized> {
@@ -98,7 +97,7 @@ impl PriorityQueue {
9897
}
9998
}
10099

101-
/// Add a task handle by its priority to the queue
100+
/// Add a task id by its priority to the queue
102101
pub fn push(&mut self, prio: abi::Priority, id: abi::Tid) {
103102
let i: usize = prio.into().into();
104103
self.prio_bitmap |= (1 << i) as u64;

0 commit comments

Comments
 (0)