1
Fork 0
mirror of https://github.com/RGBCube/serenity synced 2025-05-14 09:24:57 +00:00

AK: Add StringView::find_last_not

This commit is contained in:
Undefine 2022-09-30 21:19:53 +02:00 committed by Andrew Kaster
parent 48aea321c5
commit 9718667bcf
3 changed files with 11 additions and 0 deletions

View file

@ -107,6 +107,7 @@ public:
}
[[nodiscard]] Optional<size_t> find(StringView needle, size_t start = 0) const { return StringUtils::find(*this, needle, start); }
[[nodiscard]] Optional<size_t> find_last(char needle) const { return StringUtils::find_last(*this, needle); }
[[nodiscard]] Optional<size_t> find_last_not(char needle) const { return StringUtils::find_last_not(*this, needle); }
// FIXME: Implement find_last(StringView) for API symmetry.
[[nodiscard]] Vector<size_t> find_all(StringView needle) const;