Add atomically refcounted data

GArcBox is the atomic reference counting version of GRcBox. Unlike
GRcBox, the reference acquisition and release on GArcBox are guaranteed
to be atomic, and thus they can be performed from different threads.

This is similar to Rust's Arc<Box<T>> combination of traits.
This commit is contained in:
Emmanuele Bassi
2018-06-11 11:52:54 +01:00
parent c5d2417d07
commit b607927a43
8 changed files with 447 additions and 32 deletions

View File

@@ -121,6 +121,7 @@
<xi:include href="gvariant-text.xml"/>
<xi:include href="xml/refcount.xml"/>
<xi:include href="xml/rcbox.xml"/>
<xi:include href="xml/arcbox.xml"/>
</chapter>
<chapter id="deprecated">

View File

@@ -3478,3 +3478,15 @@ g_rc_box_acquire
g_rc_box_release
g_rc_box_release_full
</SECTION>
<SECTION>
<FILE>arcbox</FILE>
g_arc_box_alloc
g_arc_box_alloc0
g_arc_box_new
g_arc_box_new0
g_arc_box_dup
g_arc_box_acquire
g_arc_box_release
g_arc_box_release_full
</SECTION>