Remove CStr::Right

It was only a wrapper around `std::string::substr`. The interface
matches the usecase more. In some places it's better to use
`std::string::ends_with`.
This commit is contained in:
phosit
2026-08-24 13:34:37 +02:00
parent 60824e77b9
commit 058cdf78d9
4 changed files with 6 additions and 31 deletions
-7
View File
@@ -293,13 +293,6 @@ CStr CStr::UpperCase() const
return newStr;
}
// Retrieve the substring of the last n characters
CStr CStr::Right(size_t len) const
{
ENSURE(len <= length());
return substr(length()-len, len);
}
// Retrieve the substring following the last occurrence of Str
// (or the whole string if it doesn't contain Str)
CStr CStr::AfterLast(const CStr& str, size_t startPos) const