Adding punctuation

pull/8511/head
Melinda Weed 2018-10-25 17:09:45 +03:00
parent 5cc5e47929
commit c8f9759b90
1 changed files with 7 additions and 7 deletions

View File

@ -43,7 +43,7 @@ struct Waiter;
* threads. * threads.
* *
* The thread that intends to wait on a ConditionVariable must: * The thread that intends to wait on a ConditionVariable must:
* - Acquire a lock on a mutex * - Acquire a lock on a mutex.
* - Execute `wait`, `wait_for` or `wait_until`. While the thread is waiting, * - Execute `wait`, `wait_for` or `wait_until`. While the thread is waiting,
* the mutex is unlocked. * the mutex is unlocked.
* - When the condition variable has been notified, or in the case of `wait_for` * - When the condition variable has been notified, or in the case of `wait_for`
@ -64,7 +64,7 @@ struct Waiter;
* function. * function.
* *
* ### Undefined behavior * ### Undefined behavior
* - The thread that is unblocked on ConditionVariable::notify_one is * - The thread that is unblocked on `ConditionVariable::notify_one` is
* undefined if there are multiple waiters. * undefined if there are multiple waiters.
* - Calling wait if the mutex is not locked by the current thread is undefined * - Calling wait if the mutex is not locked by the current thread is undefined
* behavior. * behavior.
@ -90,7 +90,7 @@ struct Waiter;
* Mutex mutex; * Mutex mutex;
* ConditionVariable cv(mutex); * ConditionVariable cv(mutex);
* *
* // These variables are protected by locking mutex * // These variables are protected by locking mutex.
* uint32_t work_count = 0; * uint32_t work_count = 0;
* bool done = false; * bool done = false;
* *
@ -102,7 +102,7 @@ struct Waiter;
* while (done == false) { * while (done == false) {
* printf("Worker thread: Count: %lu\r\n", work_count); * printf("Worker thread: Count: %lu\r\n", work_count);
* *
* // Wait for main thread to notify the condition variable * // Wait for main thread to notify the condition variable.
* printf("Worker thread: Waiting\r\n"); * printf("Worker thread: Waiting\r\n");
* cv.wait(); * cv.wait();
* } * }
@ -169,7 +169,7 @@ public:
* been met. * been met.
* *
* @note - The current thread releases the lock while inside the wait * @note - The current thread releases the lock while inside the wait
* function and reacquire it upon exiting the function. * function and reacquires it upon exiting the function.
* *
* Example: * Example:
* @code * @code
@ -229,7 +229,7 @@ public:
*/ */
bool wait_until(uint64_t millisec); bool wait_until(uint64_t millisec);
/** Wait for a notification or timeout /** Wait for a notification or timeout.
* *
* `Wait for` causes the current thread to block until the condition * `Wait for` causes the current thread to block until the condition
* variable receives a notification from another thread, or the timeout * variable receives a notification from another thread, or the timeout
@ -301,7 +301,7 @@ public:
*/ */
void notify_all(); void notify_all();
/** ConditionVariable destructor /** ConditionVariable destructor.
* *
* @note You cannot call this function from ISR context. * @note You cannot call this function from ISR context.
*/ */