Change namespace name so it's a lot less verbose.
All checks were successful
continuous-integration/drone/push Build is passing

This commit is contained in:
2020-05-26 17:21:08 +02:00
parent 2ae108517d
commit 3dc96de34b
10 changed files with 35 additions and 35 deletions

View File

@@ -4,7 +4,7 @@
#include <unordered_map>
#include "../Assert.hpp"
namespace Arbutils::Collections {
namespace ArbUt::Collections {
template <class KeyT, class ValueT> class Dictionary {
private:
std::unordered_map<KeyT, ValueT> _map;

View File

@@ -5,7 +5,7 @@
#include <stdexcept>
#include <vector>
namespace Arbutils::Collections {
namespace ArbUt::Collections {
template <class ValueT> class List {
private:
std::vector<ValueT> _vector;

View File

@@ -1,5 +1,5 @@
#include "ConstString.hpp"
Arbutils::__ConstStringCharHolder* Arbutils::CaseInsensitiveConstString::__emptyString =
ArbUt::__ConstStringCharHolder* ArbUt::CaseInsensitiveConstString::__emptyString =
new __ConstStringCharHolder("", 0);
Arbutils::__ConstStringCharHolder* Arbutils::ConstString::__emptyString = new __ConstStringCharHolder("", 0);
ArbUt::__ConstStringCharHolder* ArbUt::ConstString::__emptyString = new __ConstStringCharHolder("", 0);

View File

@@ -8,7 +8,7 @@
#include <string>
#include "__ConstStringCore.hpp"
namespace Arbutils {
namespace ArbUt {
class __ConstStringCharHolder {
char* _value;
std::atomic<size_t> _references;
@@ -39,12 +39,12 @@ ConstStringCore(
return (*input) ? static_cast<uint32_t>((*input)) + 33 * Hash(input + 1) : 5381;
};)
inline constexpr Arbutils::ConstString_Literal
inline constexpr ArbUt::ConstString_Literal
operator"" _const(const char* c, size_t l) {
return Arbutils::ConstString_Literal(c, l);
return ArbUt::ConstString_Literal(c, l);
}
inline constexpr Arbutils::ConstString_Literal operator"" _c(const char* c, size_t l) {
return Arbutils::ConstString_Literal(c, l);
inline constexpr ArbUt::ConstString_Literal operator"" _c(const char* c, size_t l) {
return ArbUt::ConstString_Literal(c, l);
}
ConstStringCore(
@@ -55,11 +55,11 @@ ConstStringCore(
return charToLower(*input) ? static_cast<uint32_t>(charToLower(*input)) + 33 * Hash(input + 1) : 5381;
};);
inline constexpr Arbutils::CaseInsensitiveConstString_Literal operator"" _const_nocase(const char* c, size_t l) {
return Arbutils::CaseInsensitiveConstString_Literal(c, l);
inline constexpr ArbUt::CaseInsensitiveConstString_Literal operator"" _const_nocase(const char* c, size_t l) {
return ArbUt::CaseInsensitiveConstString_Literal(c, l);
}
inline constexpr Arbutils::CaseInsensitiveConstString_Literal operator"" _cnc(const char* c, size_t l) {
return Arbutils::CaseInsensitiveConstString_Literal(c, l);
inline constexpr ArbUt::CaseInsensitiveConstString_Literal operator"" _cnc(const char* c, size_t l) {
return ArbUt::CaseInsensitiveConstString_Literal(c, l);
}
#endif // ARBUTILS_CONSTSTRING_HPP

View File

@@ -7,7 +7,7 @@
#include "../extern/pcg_random.hpp"
#include "Assert.hpp"
namespace Arbutils {
namespace ArbUt {
template <class RandomT> class BaseRandom {
private:

View File

@@ -8,7 +8,7 @@
#endif
#define ConstStringCore(name, hashFunction) \
namespace Arbutils { \
namespace ArbUt { \
class name { \
private: \
__ConstStringCharHolder* _str; \
@@ -112,11 +112,11 @@
} \
\
namespace std { \
template <> struct hash<Arbutils::name> { \
constexpr std::size_t operator()(Arbutils::name const& s) const noexcept { return s.GetHash(); } \
template <> struct hash<ArbUt::name> { \
constexpr std::size_t operator()(ArbUt::name const& s) const noexcept { return s.GetHash(); } \
}; \
template <> struct hash<Arbutils::name##_Literal> { \
constexpr std::size_t operator()(Arbutils::name##_Literal const& s) const noexcept { return s.GetHash(); } \
template <> struct hash<ArbUt::name##_Literal> { \
constexpr std::size_t operator()(ArbUt::name##_Literal const& s) const noexcept { return s.GetHash(); } \
}; \
}