Skip to content

Commit

Permalink
Add String::isEmpty()
Browse files Browse the repository at this point in the history
  • Loading branch information
alranel committed Nov 7, 2023
1 parent 65633ce commit cb3ab4c
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions api/String.h
Original file line number Diff line number Diff line change
Expand Up @@ -89,6 +89,7 @@ class String
// invalid string (i.e., "if (s)" will be true afterwards)
bool reserve(unsigned int size);
inline unsigned int length(void) const {return len;}
inline bool isEmpty(void) const { return length() == 0; }

// creates a copy of the assigned value. if the value is null or
// invalid, or if the memory allocation fails, the string will be
Expand Down

0 comments on commit cb3ab4c

Please sign in to comment.