From 8fab88c56f95c03ffcb4be178f5dbb21b239d95e Mon Sep 17 00:00:00 2001 From: Bruce Hill Date: Sun, 3 Mar 2024 18:15:45 -0500 Subject: Rename Str -> Text --- builtins/string.h | 36 ------------------------------------ 1 file changed, 36 deletions(-) delete mode 100644 builtins/string.h (limited to 'builtins/string.h') diff --git a/builtins/string.h b/builtins/string.h deleted file mode 100644 index c24de72d..00000000 --- a/builtins/string.h +++ /dev/null @@ -1,36 +0,0 @@ -#pragma once -#include -#include -#include - -#include "types.h" - -#define String_t CORD -#define Str_t CORD - -typedef enum { WHERE_ANYWHERE, WHERE_START, WHERE_END } where_e; - -typedef struct { - enum { FIND_FAILURE, FIND_SUCCESS } status; - int32_t index; -} find_result_t; - -CORD Str__as_str(const void *str, bool colorize, const TypeInfo *info); -CORD Str__quoted(CORD str, bool colorize); -int Str__compare(CORD *x, CORD *y); -bool Str__equal(CORD *x, CORD *y); -uint32_t Str__hash(CORD *cord); -CORD Str__upper(CORD str); -CORD Str__lower(CORD str); -CORD Str__title(CORD str); -bool Str__has(CORD str, CORD target, where_e where); -CORD Str__without(CORD str, CORD target, where_e where); -CORD Str__trimmed(CORD str, CORD skip, where_e where); -find_result_t Str__find(CORD str, CORD pat); -CORD Str__replace(CORD text, CORD pat, CORD replacement, int64_t limit); -array_t Str__split(CORD str, CORD split); -CORD Str__join(CORD glue, array_t pieces); - -extern const TypeInfo Str; - -// vim: ts=4 sw=0 et cino=L2,l1,(0,W4,m1,\:0 -- cgit v1.2.3