docs: Added more '\threadsafety` tags.

Reference Issue #7140.
This commit is contained in:
Ryan C. Gordon
2024-10-24 14:36:06 -04:00
parent 731853077a
commit 10e52e1899
7 changed files with 127 additions and 14 deletions

View File

@@ -90,6 +90,8 @@ typedef int SDL_SpinLock;
* \param lock a pointer to a lock variable.
* \returns true if the lock succeeded, false if the lock is already held.
*
* \threadsafety It is safe to call this function from any thread.
*
* \since This function is available since SDL 3.1.3.
*
* \sa SDL_LockSpinlock
@@ -105,6 +107,8 @@ extern SDL_DECLSPEC bool SDLCALL SDL_TryLockSpinlock(SDL_SpinLock *lock);
*
* \param lock a pointer to a lock variable.
*
* \threadsafety It is safe to call this function from any thread.
*
* \since This function is available since SDL 3.1.3.
*
* \sa SDL_TryLockSpinlock
@@ -122,6 +126,8 @@ extern SDL_DECLSPEC void SDLCALL SDL_LockSpinlock(SDL_SpinLock *lock);
*
* \param lock a pointer to a lock variable.
*
* \threadsafety It is safe to call this function from any thread.
*
* \since This function is available since SDL 3.1.3.
*
* \sa SDL_LockSpinlock
@@ -415,6 +421,8 @@ extern SDL_DECLSPEC int SDLCALL SDL_AddAtomicInt(SDL_AtomicInt *a, int v);
* \param a a pointer to an SDL_AtomicInt to increment.
* \returns the previous value of the atomic variable.
*
* \threadsafety It is safe to call this macro from any thread.
*
* \since This macro is available since SDL 3.1.3.
*
* \sa SDL_AtomicDecRef
@@ -433,6 +441,8 @@ extern SDL_DECLSPEC int SDLCALL SDL_AddAtomicInt(SDL_AtomicInt *a, int v);
* \returns true if the variable reached zero after decrementing, false
* otherwise.
*
* \threadsafety It is safe to call this macro from any thread.
*
* \since This macro is available since SDL 3.1.3.
*
* \sa SDL_AtomicIncRef