add a comment about not modifying ticktimer APIs due to libstd dependency

This commit is contained in:
bunnie 2022-03-26 02:35:38 +08:00
parent 91d0511fa4
commit 319e0e0641

View file

@ -1,3 +1,4 @@
/// Do not modify the discriminants in this structure. They are used in `libstd` directly.
#[derive(num_derive::FromPrimitive, num_derive::ToPrimitive, Debug)]
pub(crate) enum Opcode {
/// Get the elapsed time in milliseconds
@ -19,31 +20,31 @@ pub(crate) enum Opcode {
GetVersion = 5,
/// Lock the given Mutex, blocking if it is already locked.
///
///
/// # Arguments
///
///
/// *arg1*: An integer of some sort, such as the address of the Mutex
LockMutex = 6,
/// Unlock the given Mutex
///
///
/// # Arguments
///
///
/// *arg1*: An integer of some sort, such as the address of the Mutex
UnlockMutex = 7,
/// Wait for a given condition to be signalled
///
///
/// # Arguments
///
///
/// *arg1*: An integer of some sort, such as the address of the Condvar
/// *arg2*: The number of milliseconds to wait, or 0 to wait forever
WaitForCondition = 8,
/// Notify a condition
///
///
/// # Arguments
///
///
/// *arg1*: An integer of some sort, such as the address of the Condvar
/// *arg2*: The number of conditions to notify
NotifyCondition = 9,