Преглед изворни кода

docs/sphinx: Update atomic API

jpark37 пре 4 година
родитељ
комит
5cf40bf818
1 измењених фајлова са 26 додато и 2 уклоњено
  1. 26 2
      docs/sphinx/reference-libobs-util-threading.rst

+ 26 - 2
docs/sphinx/reference-libobs-util-threading.rst

@@ -164,9 +164,21 @@ Atomic Inline Functions
 
 ---------------------
 
+.. function:: void os_atomic_store_long(volatile long *ptr, long val)
+
+   Stores the value of a long variable atomically.
+
+---------------------
+
 .. function:: long os_atomic_set_long(volatile long *ptr, long val)
 
-   Sets the value of a long variable atomically.
+   Exchanges the value of a long variable atomically. Badly named.
+
+---------------------
+
+.. function:: long os_atomic_exchange_long(volatile long *ptr, long val)
+
+   Exchanges the value of a long variable atomically. Properly named.
 
 ---------------------
 
@@ -182,9 +194,21 @@ Atomic Inline Functions
 
 ---------------------
 
+.. function:: void os_atomic_store_bool(volatile bool *ptr, bool val)
+
+   Stores the value of a boolean variable atomically.
+
+---------------------
+
 .. function:: bool os_atomic_set_bool(volatile bool *ptr, bool val)
 
-   Sets the value of a boolean variable atomically.
+   Exchanges the value of a boolean variable atomically. Badly named.
+
+---------------------
+
+.. function:: bool os_atomic_exchange_bool(volatile bool *ptr, bool val)
+
+   Exchanges the value of a boolean variable atomically. Properly named.
 
 ---------------------