mirror of
https://github.com/RGBCube/serenity
synced 2025-07-25 03:27:44 +00:00
AK: Make binary_search signature more generic.
This commit is contained in:
parent
35c4338625
commit
50d24e4f98
6 changed files with 63 additions and 53 deletions
|
@ -112,7 +112,7 @@ u32 CanonicalCode::read_symbol(InputBitStream& stream) const
|
|||
|
||||
// FIXME: This seems really inefficient, this could be an index into an array instead.
|
||||
size_t index;
|
||||
if (AK::binary_search(m_symbol_codes.span(), code_bits, AK::integral_compare<u32>, &index))
|
||||
if (AK::binary_search(m_symbol_codes.span(), code_bits, &index))
|
||||
return m_symbol_values[index];
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue