mirror of
https://github.com/RGBCube/serenity
synced 2025-05-31 12:28:12 +00:00
Refactor: Change the AK::binary_search signature to use AK::Span.
This commit is contained in:
parent
ac9c2bc492
commit
707d92db61
5 changed files with 20 additions and 19 deletions
|
@ -878,7 +878,7 @@ Vector<Line::CompletionSuggestion> Shell::complete_path(const String& base, cons
|
|||
|
||||
Vector<Line::CompletionSuggestion> Shell::complete_program_name(const String& name, size_t offset)
|
||||
{
|
||||
auto match = binary_search(cached_path.data(), cached_path.size(), name, [](const String& name, const String& program) -> int {
|
||||
auto match = binary_search(cached_path.span(), name, [](const String& name, const String& program) -> int {
|
||||
return strncmp(name.characters(), program.characters(), name.length());
|
||||
});
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue