aboutsummaryrefslogtreecommitdiffstats
path: root/Alc/alstring.h
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2017-04-04 06:58:53 -0700
committerChris Robinson <[email protected]>2017-04-04 06:58:53 -0700
commit26144ca9dffd935c3e7499b417ccb9a6ef93eea0 (patch)
treecc2cf8d930485be834d9f1d3f78e76825a7c4838 /Alc/alstring.h
parentb78ddc7ef7bd145a3468e520e9bc4be5c551a952 (diff)
Rename al_string_* functions to alstr_*
Diffstat (limited to 'Alc/alstring.h')
-rw-r--r--Alc/alstring.h36
1 files changed, 18 insertions, 18 deletions
diff --git a/Alc/alstring.h b/Alc/alstring.h
index 6167f5ce..a7513516 100644
--- a/Alc/alstring.h
+++ b/Alc/alstring.h
@@ -10,40 +10,40 @@ typedef char al_string_char_type;
TYPEDEF_VECTOR(al_string_char_type, al_string)
TYPEDEF_VECTOR(al_string, vector_al_string)
-inline void al_string_deinit(al_string *str)
+inline void alstr_reset(al_string *str)
{ VECTOR_DEINIT(*str); }
#define AL_STRING_INIT(_x) do { (_x) = (al_string)NULL; } while(0)
#define AL_STRING_INIT_STATIC() ((al_string)NULL)
-#define AL_STRING_DEINIT(_x) al_string_deinit(&(_x))
+#define AL_STRING_DEINIT(_x) alstr_reset(&(_x))
-inline size_t al_string_length(const_al_string str)
+inline size_t alstr_length(const_al_string str)
{ return VECTOR_SIZE(str); }
-inline ALboolean al_string_empty(const_al_string str)
-{ return al_string_length(str) == 0; }
+inline ALboolean alstr_empty(const_al_string str)
+{ return alstr_length(str) == 0; }
-inline const al_string_char_type *al_string_get_cstr(const_al_string str)
+inline const al_string_char_type *alstr_get_cstr(const_al_string str)
{ return str ? &VECTOR_FRONT(str) : ""; }
-void al_string_clear(al_string *str);
+void alstr_clear(al_string *str);
-int al_string_cmp(const_al_string str1, const_al_string str2);
-int al_string_cmp_cstr(const_al_string str1, const al_string_char_type *str2);
+int alstr_cmp(const_al_string str1, const_al_string str2);
+int alstr_cmp_cstr(const_al_string str1, const al_string_char_type *str2);
-void al_string_copy(al_string *str, const_al_string from);
-void al_string_copy_cstr(al_string *str, const al_string_char_type *from);
-void al_string_copy_range(al_string *str, const al_string_char_type *from, const al_string_char_type *to);
+void alstr_copy(al_string *str, const_al_string from);
+void alstr_copy_cstr(al_string *str, const al_string_char_type *from);
+void alstr_copy_range(al_string *str, const al_string_char_type *from, const al_string_char_type *to);
-void al_string_append_char(al_string *str, const al_string_char_type c);
-void al_string_append_cstr(al_string *str, const al_string_char_type *from);
-void al_string_append_range(al_string *str, const al_string_char_type *from, const al_string_char_type *to);
+void alstr_append_char(al_string *str, const al_string_char_type c);
+void alstr_append_cstr(al_string *str, const al_string_char_type *from);
+void alstr_append_range(al_string *str, const al_string_char_type *from, const al_string_char_type *to);
#ifdef _WIN32
#include <wchar.h>
/* Windows-only methods to deal with WideChar strings. */
-void al_string_copy_wcstr(al_string *str, const wchar_t *from);
-void al_string_append_wcstr(al_string *str, const wchar_t *from);
-void al_string_append_wrange(al_string *str, const wchar_t *from, const wchar_t *to);
+void alstr_copy_wcstr(al_string *str, const wchar_t *from);
+void alstr_append_wcstr(al_string *str, const wchar_t *from);
+void alstr_append_wrange(al_string *str, const wchar_t *from, const wchar_t *to);
#endif
#endif /* ALSTRING_H */