diff --git a/clang/runtime/dpct-rt/include/dpct/dpl_extras/algorithm.h b/clang/runtime/dpct-rt/include/dpct/dpl_extras/algorithm.h index 66ec11f1e43a..f8b40c2e63ca 100644 --- a/clang/runtime/dpct-rt/include/dpct/dpl_extras/algorithm.h +++ b/clang/runtime/dpct-rt/include/dpct/dpl_extras/algorithm.h @@ -213,10 +213,7 @@ Iter partition_point(Policy &&policy, Iter first, Iter last, Pred p) { std::is_same::iterator_category, std::random_access_iterator_tag>::value, "Iterators passed to algorithms must be random-access iterators."); - if (std::is_partitioned(policy, first, last, p)) - return std::find_if_not(std::forward(policy), first, last, p); - else - return first; + return std::find_if_not(std::forward(policy), first, last, p); } template