diff --git a/AK/StringView.h b/AK/StringView.h index f08ac13525f..1ec0ec20228 100644 --- a/AK/StringView.h +++ b/AK/StringView.h @@ -227,6 +227,11 @@ public: return *cp == '\0'; } + constexpr bool operator==(char const c) const + { + return m_length == 1 && *m_characters == c; + } + constexpr bool operator!=(char const* cstring) const { return !(*this == cstring);