ucx/string.c

changeset 31
287484519844
parent 23
b26390e77237
--- a/ucx/string.c	Fri Dec 12 10:42:53 2025 +0100
+++ b/ucx/string.c	Fri Dec 19 17:22:03 2025 +0100
@@ -25,7 +25,8 @@
  * ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
  * POSSIBILITY OF SUCH DAMAGE.
  */
-#ifdef MEMRCHR_NEED_GNU
+
+#ifdef WITH_MEMRCHR
 #define _GNU_SOURCE
 #endif
 
@@ -46,28 +47,6 @@
 #define cx_strcasecmp_impl strncasecmp
 #endif
 
-cxmutstr cx_mutstr(char *cstring) {
-    return (cxmutstr) {cstring, cstring == NULL ? 0 : strlen(cstring)};
-}
-
-cxmutstr cx_mutstrn(
-        char *cstring,
-        size_t length
-) {
-    return (cxmutstr) {cstring, length};
-}
-
-cxstring cx_str(const char *cstring) {
-    return (cxstring) {cstring, cstring == NULL ? 0 : strlen(cstring)};
-}
-
-cxstring cx_strn(
-        const char *cstring,
-        size_t length
-) {
-    return (cxstring) {cstring, length};
-}
-
 void cx_strfree(cxmutstr *str) {
     if (str == NULL) return;
     cxFreeDefault(str->ptr);

mercurial