src/cx/compare.h

changeset 1634
006e076a8db7
parent 1632
f74e4fc496a2
--- a/src/cx/compare.h	Fri Dec 19 17:24:18 2025 +0100
+++ b/src/cx/compare.h	Fri Dec 19 17:37:17 2025 +0100
@@ -534,18 +534,7 @@
 cx_attr_nonnull cx_attr_nodiscard
 CX_EXPORT int cx_cmp_ptr(const void *ptr1, const void *ptr2);
 
-/**
- * A @c cx_compare_func2 compatible wrapper for @c memcmp().
- *
- * @param ptr1 pointer one
- * @param ptr2 pointer two
- * @param n (@c size_t*) a pointer to the length
- * @return the result of @c memcmp()
- */
-cx_attr_nonnull cx_attr_nodiscard
-CX_EXPORT int cx_ccmp_memcmp(const void *ptr1, const void *ptr2, void *n);
-
-/** Wraps a compare function for cx_ccmp_wrap. */
+/** Wraps a compare function for cx_cmp_wrap. */
 typedef struct {
     /** The wrapped compare function */
     cx_compare_func cmp;
@@ -554,20 +543,14 @@
 /**
  * A @c cx_compare_func2 wrapper for a @c cx_compare_func().
  *
- * This is not strictly compatible with a @c cx_compare_func2 because
- * ISO C does not define conversions between function and object pointers.
- *
- * But it works on all tested platforms to cast a pointer to this function to
- * a @c cx_compare_func2.
- *
  * @param ptr1 pointer one
  * @param ptr2 pointer two
  * @param cmp_wrapper a pointer to a @c cx_compare_func_wrapper
  * @return the result of the invoked compare function
- * @see cx_compare_func_wrapper_s
+ * @see cx_compare_func_wrapper
  */
 cx_attr_nonnull cx_attr_nodiscard
-CX_EXPORT int cx_ccmp_wrap(const void *ptr1, const void *ptr2, void* cmp_wrapper);
+CX_EXPORT int cx_cmp_wrap(const void *ptr1, const void *ptr2, void* cmp_wrapper);
 
 #ifdef __cplusplus
 } // extern "C"

mercurial