mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 19:27:44 +00:00
StringView: Rename characters() to characters_without_null_termination().
This should make you think twice before trying to use the const char* from a StringView as if it's a null-terminated string.
This commit is contained in:
parent
567551bc12
commit
0e75aba7c3
21 changed files with 57 additions and 46 deletions
|
@ -35,7 +35,7 @@ public:
|
|||
|
||||
bool is_null() const { return !m_characters; }
|
||||
bool is_empty() const { return m_length == 0; }
|
||||
const char* characters() const { return m_characters; }
|
||||
const char* characters_without_null_termination() const { return m_characters; }
|
||||
int length() const { return m_length; }
|
||||
char operator[](int index) const { return m_characters[index]; }
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue