fix non-modidying operation algorithm iteration

This commit is contained in:
bolero-MURAKAMI 2012-04-03 21:58:23 +09:00
parent db20f64991
commit cf593ffeff
7 changed files with 37 additions and 27 deletions

View file

@ -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)
;
}