| 635 | } |
| 636 | |
| 637 | bool SmallStringBase::ends_with(const char* str, bool case_sensitive) const |
| 638 | { |
| 639 | const u32 other_length = static_cast<u32>(std::strlen(str)); |
| 640 | if (other_length > m_length) |
| 641 | return false; |
| 642 | |
| 643 | u32 start_offset = m_length - other_length; |
| 644 | return (case_sensitive) ? (std::strncmp(str, m_buffer + start_offset, other_length) == 0) : |
| 645 | (CASE_N_COMPARE(str, m_buffer + start_offset, other_length) == 0); |
| 646 | } |
| 647 | |
| 648 | bool SmallStringBase::ends_with(const SmallStringBase& str, bool case_sensitive) const |
| 649 | { |
no test coverage detected