Move a couple types to the source they're used in
[openal-soft.git] / common / alstring.h
blob194e54a12480862d1e51210f5e6f2569eb236e17
1 #ifndef AL_STRING_H
2 #define AL_STRING_H
4 #include <cstddef>
5 #include <string>
7 #include "almalloc.h"
10 namespace al {
12 template<typename T, typename Tr=std::char_traits<T>>
13 using basic_string = std::basic_string<T, Tr, al::allocator<T>>;
15 using string = basic_string<char>;
16 using wstring = basic_string<wchar_t>;
17 using u16string = basic_string<char16_t>;
18 using u32string = basic_string<char32_t>;
21 /* These would be better served by using a string_view-like span/view with
22 * case-insensitive char traits.
24 int strcasecmp(const char *str0, const char *str1) noexcept;
25 int strncasecmp(const char *str0, const char *str1, std::size_t len) noexcept;
27 } // namespace al
29 #endif /* AL_STRING_H */