Skip to content

Commit 1b08215

Browse files
authored
Fix a problem with unsignedness
1 parent 29a80a3 commit 1b08215

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

include/sorting_algorithms/sort.hpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -192,7 +192,7 @@ inline void selection_sort(BidirectionalIterator first, BidirectionalIterator la
192192
template <class RandomAccessIterator, class Compare>
193193
inline void
194194
heapify_down(RandomAccessIterator first, RandomAccessIterator last, std::size_t i, Compare compare) noexcept {
195-
std::size_t n = last - first;
195+
auto n = last - first;
196196
while (true) {
197197
auto left = i * 2 + 1;
198198
auto right = i * 2 + 2;

0 commit comments

Comments
 (0)