mirror of
https://github.com/bolero-MURAKAMI/Sprout.git
synced 2025-07-02 14:04:20 +00:00
fix non-modidying operation algorithm iteration
This commit is contained in:
parent
db20f64991
commit
cf593ffeff
7 changed files with 37 additions and 27 deletions
|
@ -19,7 +19,7 @@ namespace sprout {
|
|||
std::size_t n
|
||||
)
|
||||
{
|
||||
return first + n == last || !comp(first[n], first[(n - 1) / 2]) ? first + n
|
||||
return sprout::next(first, n) == last || !comp(first[n], first[(n - 1) / 2]) ? sprout::next(first, n)
|
||||
: sprout::detail::is_heap_until_impl(first, last, comp, n + 1)
|
||||
;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue