We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent bfc4c7e commit 47fec5fCopy full SHA for 47fec5f
fly/types/string/detail/string_lexer.hpp
@@ -101,8 +101,6 @@ class BasicStringLexer
101
template <typename Condition>
102
constexpr std::optional<char_type> consume_if(Condition condition);
103
104
- static constexpr const auto s_null_terminator = FLY_CHR(char_type, '\0');
105
-
106
const std::size_t m_size;
107
const view_type m_view;
108
@@ -113,7 +111,7 @@ class BasicStringLexer
113
111
template <typename StringType>
114
112
template <std::size_t N>
115
constexpr BasicStringLexer<StringType>::BasicStringLexer(const char_type (&literals)[N]) noexcept :
116
- m_size(N - ((literals[N - 1] == s_null_terminator) ? 1 : 0)),
+ m_size(classifier::size(literals)),
117
m_view(literals, m_size)
118
{
119
}
0 commit comments