sdl3-bindgen-sys
Safe HaskellNone
LanguageGHC2021

SDL3.Sys.Bindgen.AtomicShims.Safe

Synopsis

Documentation

lithon_SDL_AtomicIncRef Source #

Arguments

:: Ptr SDL_AtomicInt
a
a pointer to an SDL_AtomicInt to increment.
-> IO CInt 

Increment an atomic variable used as a reference count.

The SDL_AtomicIncRef macro as a function.

Returns
the previous value of the atomic variable.
Thread safety
It is safe to call this function from any thread.
See also
SDL_AtomicDecRef
C declaration
lithon_SDL_AtomicIncRef, defined at sdl3-bindgen-sys/SDL_atomic_shims.h 38:23

Since: 3.2.0

lithon_SDL_AtomicDecRef Source #

Arguments

:: Ptr SDL_AtomicInt
a
a pointer to an SDL_AtomicInt to decrement.
-> IO CBool 

Decrement an atomic variable used as a reference count.

The SDL_AtomicDecRef macro as a function.

Returns
true if the variable reached zero after decrementing, false otherwise.
Thread safety
It is safe to call this function from any thread.
See also
SDL_AtomicIncRef
C declaration
lithon_SDL_AtomicDecRef, defined at sdl3-bindgen-sys/SDL_atomic_shims.h 58:24

Since: 3.2.0