Drop String::empty()

This method causes confuction and bugs by having the same name, but
different meaning versus std::string::empty().

Bug: 295394788
Test: make checkbuild
Change-Id: I15aadc023b20559930e4ec79f43f7032e8cd90d0
This commit is contained in:
Tomasz Wasilczyk 2023-08-14 15:47:29 +00:00
parent d1e04d2123
commit 6d1b644930

View file

@ -52,8 +52,6 @@ public:
explicit String8(const char32_t* o, size_t numChars);
~String8();
static inline const String8 empty();
static String8 format(const char* fmt, ...) __attribute__((format (printf, 1, 2)));
static String8 formatV(const char* fmt, va_list args);
@ -240,10 +238,6 @@ inline int strictly_order_type(const String8& lhs, const String8& rhs)
return compare_type(lhs, rhs) < 0;
}
inline const String8 String8::empty() {
return String8();
}
inline const char* String8::c_str() const
{
return mString;