Skip to content

Commit 76b4ecc

Browse files
Update SDL_atomic.inc to 3.4.4
1 parent 37d4499 commit 76b4ecc

2 files changed

Lines changed: 21 additions & 2 deletions

File tree

units/SDL3.pas

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -119,7 +119,7 @@ interface
119119
{$I SDL_messagebox.inc} // 3.4.4
120120
{$I SDL_time.inc} // 3.4.4
121121
{$I SDL_filesystem.inc} // 3.4.4
122-
{$I SDL_atomic.inc} // 3.2.0
122+
{$I SDL_atomic.inc} // 3.4.4
123123
{$I SDL_hidapi.inc} // 3.2.0
124124
{$I SDL_metal.inc} // 3.2.0
125125
{$I SDL_vulkan.inc} // 3.2.0

units/SDL_atomic.inc

Lines changed: 20 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -383,7 +383,7 @@ function SDL_AddAtomicInt(a: PSDL_AtomicInt; v: cint): cint; cdecl;
383383
*
384384
* ***Note: If you don't know what this macro is for, you shouldn't use it!***
385385
*
386-
* \param a a Pointer to an SDL_AtomicInt to increment.
386+
* \param a a Pointer to an SDL_AtomicInt to decrement.
387387
* \returns the previous value of the atomic variable.
388388
*
389389
* \threadsafety It is safe to call this macro from any thread.
@@ -504,6 +504,25 @@ function SDL_SetAtomicU32(a: PSDL_AtomicU32; v: cuint32): cuint32; cdecl;
504504
function SDL_GetAtomicU32(a: PSDL_AtomicU32): cuint32; cdecl;
505505
external SDL_LibName {$IFDEF DELPHI} {$IFDEF MACOS} name '_SDL_GetAtomicU32' {$ENDIF} {$ENDIF};
506506

507+
{*
508+
* Add to an atomic variable.
509+
*
510+
* This function also acts as a full memory barrier.
511+
*
512+
* ***Note: If you don't know what this function is for, you shouldn't use
513+
* it!***
514+
*
515+
* \param a a Pointer to an SDL_AtomicU32 variable to be modified.
516+
* \param v the desired value to add or subtract.
517+
* \returns the previous value of the atomic variable.
518+
*
519+
* \threadsafety It is safe to call this function from any thread.
520+
*
521+
* \since This function is available since SDL 3.4.0.
522+
}
523+
function SDL_AddAtomicU32(a: PSDL_AtomicU32; v: cint): cuint32; cdecl;
524+
external SDL_LibName {$IFDEF DELPHI} {$IFDEF MACOS} name '_SDL_AddAtomicU32' {$ENDIF} {$ENDIF};
525+
507526
{*
508527
* Set a Pointer to a new value if it is currently an old value.
509528
*

0 commit comments

Comments
 (0)