docs/Writerside/topics/array_list.h.md

changeset 1622
27e7a4bf1a39
parent 1621
c52a4c67e29e
child 1625
89a2d53308e4
--- a/docs/Writerside/topics/array_list.h.md	Thu Dec 18 12:26:25 2025 +0100
+++ b/docs/Writerside/topics/array_list.h.md	Thu Dec 18 14:53:16 2025 +0100
@@ -144,17 +144,36 @@
 #include <cx/array_list.h>
 
 int cx_array_insert_sorted(CxArray array,
-        cx_compare_func cmp_func, const void *element);
+        const void *element,
+        cx_compare_func cmp_func);
 
 int cx_array_insert_sorted_array(CxArray array,
-        cx_compare_func cmp_func, const void *sorted_data, size_t n);
+        const void *sorted_data, size_t n,
+        cx_compare_func cmp_func);
 
 int cx_array_insert_sorted_a(const CxAllocator *allocator,
-        CxArray array, cx_compare_func cmp_func, const void *element);
+        CxArray array, const void *element,
+        cx_compare_func cmp_func);
 
 int cx_array_insert_sorted_array_a(const CxAllocator *allocator,
-        CxArray array, cx_compare_func cmp_func,
-        const void *sorted_data, size_t n);
+        CxArray array, const void *sorted_data, size_t n,
+        cx_compare_func cmp_func);
+
+int cx_array_insert_sorted_c(CxArray array,
+        const void *element,
+        cx_compare_func2 cmp_func, void *context);
+
+int cx_array_insert_sorted_array_c(CxArray array,
+        const void *sorted_data, size_t n,
+        cx_compare_func2 cmp_func, void *context);
+
+int cx_array_insert_sorted_ca(const CxAllocator *allocator,
+        CxArray array, const void *element,
+        cx_compare_func2 cmp_func, void *context);
+
+int cx_array_insert_sorted_array_ca(const CxAllocator *allocator,
+        CxArray array, const void *sorted_data, size_t n,
+        cx_compare_func2 cmp_func, void *context);
 ```
 
 The above functions are equivalent to `cx_array_insert()` and `cx_array_insert_array()`,
@@ -167,17 +186,36 @@
 #include <cx/array_list.h>
 
 int cx_array_insert_unique(CxArray array,
-        cx_compare_func cmp_func, const void *element);
+        const void *element,
+        cx_compare_func cmp_func);
 
 int cx_array_insert_unique_array(CxArray array,
-        cx_compare_func cmp_func, const void *sorted_data, size_t n);
+        const void *sorted_data, size_t n,
+        cx_compare_func cmp_func);
 
 int cx_array_insert_unique_a(const CxAllocator *allocator,
-        CxArray array, cx_compare_func cmp_func, const void *element);
+        CxArray array, const void *element,
+        cx_compare_func cmp_func);
 
 int cx_array_insert_unique_array_a(const CxAllocator *allocator,
-        CxArray array, cx_compare_func cmp_func,
-        const void *sorted_data, size_t n);
+        CxArray array, const void *sorted_data, size_t n,
+        cx_compare_func cmp_func);
+
+int cx_array_insert_unique_c(CxArray array,
+        const void *element,
+        cx_compare_func2 cmp_func, void *context);
+
+int cx_array_insert_unique_array_c(CxArray array,
+        const void *sorted_data, size_t n,
+        cx_compare_func2 cmp_func, void *context);
+
+int cx_array_insert_unique_ca(const CxAllocator *allocator,
+        CxArray array, const void *element,
+        cx_compare_func2 cmp_func, void *context);
+
+int cx_array_insert_unique_array_ca(const CxAllocator *allocator,
+        CxArray array, const void *sorted_data, size_t n,
+        cx_compare_func2 cmp_func, void *context);
 ```
 
 The above functions are similar to the functions for insertion sort,

mercurial