1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-07-25 16:47:36 +00:00

AK+LibRegex: Disable construction of views from temporary Strings

This commit is contained in:
Idan Horowitz 2021-09-04 17:53:43 +03:00 committed by Andreas Kling
parent e606ff3751
commit e8f6840471
3 changed files with 6 additions and 0 deletions

View file

@ -48,6 +48,8 @@ public:
StringView(const String&);
StringView(const FlyString&);
explicit StringView(String&&) = delete;
[[nodiscard]] constexpr bool is_null() const { return !m_characters; }
[[nodiscard]] constexpr bool is_empty() const { return m_length == 0; }