src/cx/list.h

changeset 666
b5dd654deb3b
parent 664
af5bf4603a5d
child 667
2f88a7c13a28
--- a/src/cx/list.h	Mon Mar 20 18:05:12 2023 +0100
+++ b/src/cx/list.h	Mon Mar 20 19:09:08 2023 +0100
@@ -227,7 +227,7 @@
 typedef struct cx_list_s CxList;
 
 /**
- * Invokes the destructor function for a specific element.
+ * Invokes the configured destructor function for a specific element.
  *
  * Usually only used by list implementations. There should be no need
  * to invoke this function manually.
@@ -242,6 +242,36 @@
 );
 
 /**
+ * Invokes the simple destructor function for a specific element.
+ *
+ * Usually only used by list implementations. There should be no need
+ * to invoke this function manually.
+ *
+ * @param list the list
+ * @param elem the element
+ */
+__attribute__((__nonnull__))
+void cx_list_invoke_simple_destructor(
+        struct cx_list_s const *list,
+        void *elem
+);
+
+/**
+ * Invokes the advanced destructor function for a specific element.
+ *
+ * Usually only used by list implementations. There should be no need
+ * to invoke this function manually.
+ *
+ * @param list the list
+ * @param elem the element
+ */
+__attribute__((__nonnull__))
+void cx_list_invoke_advanced_destructor(
+        struct cx_list_s const *list,
+        void *elem
+);
+
+/**
  * Advises the list to store copies of the objects (default mode of operation).
  *
  * Retrieving objects from this list will yield pointers to the copies stored
@@ -276,7 +306,7 @@
  * @see cxListStorePointers()
  */
 __attribute__((__nonnull__))
-bool cxListIsStoringPointers(CxList *list);
+bool cxListIsStoringPointers(CxList const *list);
 
 /**
  * Adds an item to the end of the list.

mercurial