diff -r f1b2146d4805 -r 6af5798342e8 src/ucx/string.h --- a/src/ucx/string.h Sun Apr 01 09:51:01 2018 +0200 +++ b/src/ucx/string.h Tue May 08 12:49:56 2018 +0200 @@ -76,6 +76,7 @@ const char *ptr; size_t length; } scstr_t; + #ifdef __cplusplus } #endif @@ -168,7 +169,9 @@ * @param ... all other strings * @return the cumulated length of all strings */ -size_t sstrnlen(size_t count, sstr_t string, ...); +size_t ucx_strnlen(size_t count, ...); + +#define sstrnlen(count, ...) ucx_strnlen(count, __VA_ARGS__) /** * Concatenates two or more strings. @@ -185,7 +188,9 @@ * @param ... all remaining strings * @return the concatenated string */ -sstr_t sstrcat(size_t count, sstr_t s1, sstr_t s2, ...); +sstr_t ucx_strcat(size_t count, scstr_t s1, ...); + +#define sstrcat(count, s1, ...) ucx_strcat(count, SCSTR(s1), __VA_ARGS__) /** * Concatenates two or more strings using a UcxAllocator. @@ -199,8 +204,9 @@ * @param ... all remaining strings * @return the concatenated string */ -sstr_t sstrcat_a(UcxAllocator *a, size_t count, sstr_t s1, sstr_t s2, ...); +sstr_t ucx_strcat_a(UcxAllocator *a, size_t count, scstr_t s1, ...); +#define sstrcat_a(count, s1, ...) ucx_strcat_a(count, SCSTR(s1), __VA_ARGS__) /** * Returns a substring starting at the specified location.