mirror of
https://github.com/RGBCube/serenity
synced 2025-07-27 19:27:35 +00:00
AK: Add String{,Utils}::to_snakecase()
This is an improved version of WrapperGenerator's snake_name(), which seems like the kind of thing that could be useful elsewhere but would end up getting duplicated - so let's add this to AK::String instead, like to_{lowercase,uppercase}().
This commit is contained in:
parent
43948aee51
commit
4fafe14691
5 changed files with 50 additions and 0 deletions
|
@ -72,6 +72,8 @@ bool contains(const StringView&, const StringView&, CaseSensitivity);
|
|||
bool is_whitespace(const StringView&);
|
||||
StringView trim_whitespace(const StringView&, TrimMode mode);
|
||||
Optional<size_t> find(const StringView& haystack, const StringView& needle);
|
||||
String to_snakecase(const StringView&);
|
||||
|
||||
}
|
||||
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue