Skip to content

Commit

Permalink
AK: Add nodiscard attribute to BinarySearch functions
Browse files Browse the repository at this point in the history
  • Loading branch information
ldm5180 authored and pull[bot] committed Jan 15, 2024
1 parent 3922837 commit a8b68eb
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion AK/BinarySearch.h
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ namespace AK {

struct DefaultComparator {
template<typename T, typename S>
constexpr int operator()(T& lhs, S& rhs)
[[nodiscard]] constexpr int operator()(T& lhs, S& rhs)
{
if (lhs > rhs)
return 1;
Expand Down

0 comments on commit a8b68eb

Please sign in to comment.