diff --git a/deps/nostalgia/deps/ox/src/ox/std/stringliteral.hpp b/deps/nostalgia/deps/ox/src/ox/std/stringliteral.hpp index a498075..986e8b9 100644 --- a/deps/nostalgia/deps/ox/src/ox/std/stringliteral.hpp +++ b/deps/nostalgia/deps/ox/src/ox/std/stringliteral.hpp @@ -20,26 +20,24 @@ namespace ox { * that is not a literal. * If you do this: * StringLiteral(str.c_str()) - * the resulting segfault is on you. + * the resulting segfault is on you. */ class StringLiteral: public detail::BaseStringView { public: constexpr StringLiteral() noexcept = default; - constexpr StringLiteral(StringLiteral const&sv) noexcept = default; + constexpr StringLiteral(StringLiteral const &sv) noexcept = default; constexpr explicit StringLiteral(std::nullptr_t) noexcept {} - constexpr explicit StringLiteral(const char *str, std::size_t len) noexcept: BaseStringView(str, len) {} + constexpr explicit StringLiteral(const char *str, std::size_t len) noexcept: BaseStringView{str, len} {} OX_ALLOW_UNSAFE_BUFFERS_BEGIN - constexpr explicit StringLiteral(char const *str) noexcept: StringLiteral(str, ox::strlen(str)) {} + constexpr explicit StringLiteral(char const *str) noexcept: StringLiteral{str, ox::strlen(str)} {} OX_ALLOW_UNSAFE_BUFFERS_END - constexpr StringLiteral &operator=(StringLiteral const&other) noexcept { - if (&other != this) { - set(other.data(), other.len()); - } + constexpr StringLiteral &operator=(StringLiteral const &other) noexcept { + set(other.data(), other.len()); return *this; }