Skip to content

Commit e798086

Browse files
committed
Fixing various compilation regressions
- flyby: rename test - flyby: adding missing test targets Signed-off-by: Hartmut Kaiser <hartmut.kaiser@gmail.com>
1 parent cbb2b5b commit e798086

6 files changed

Lines changed: 28 additions & 28 deletions

File tree

.circleci/tests.unit1.algorithms

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,3 +35,6 @@ tests.unit.modules.algorithms.algorithms.findfirstof
3535
tests.unit.modules.algorithms.algorithms.findfirstof_binary
3636
tests.unit.modules.algorithms.algorithms.findif
3737
tests.unit.modules.algorithms.algorithms.findifnot
38+
tests.unit.modules.algorithms.algorithms.find_last
39+
tests.unit.modules.algorithms.algorithms.find_last_if
40+
tests.unit.modules.algorithms.algorithms.find_last_if_not

.github/test-targets/tests.unit1.algorithms

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -35,3 +35,6 @@ tests.unit.modules.algorithms.algorithms.findfirstof
3535
tests.unit.modules.algorithms.algorithms.findfirstof_binary
3636
tests.unit.modules.algorithms.algorithms.findif
3737
tests.unit.modules.algorithms.algorithms.findifnot
38+
tests.unit.modules.algorithms.algorithms.find_last
39+
tests.unit.modules.algorithms.algorithms.find_last_if
40+
tests.unit.modules.algorithms.algorithms.find_last_if_not

libs/core/algorithms/include/hpx/parallel/algorithms/find.hpp

Lines changed: 1 addition & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1898,8 +1898,7 @@ namespace hpx::parallel::detail {
18981898
base_idx, it, part_size, tok, val, HPX_FORWARD(Proj, proj));
18991899
};
19001900

1901-
auto f2 = [tok, count, first, last](
1902-
auto&&... data) mutable -> Iter {
1901+
auto f2 = [tok, first, last](auto&&... data) mutable -> Iter {
19031902
static_assert(sizeof...(data) < 2);
19041903
if constexpr (sizeof...(data) == 1)
19051904
{

libs/core/algorithms/include/hpx/parallel/container_algorithms/find.hpp

Lines changed: 16 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -2053,9 +2053,8 @@ namespace hpx::ranges {
20532053
)
20542054
// clang-format on
20552055
friend hpx::parallel::util::detail::algorithm_result_t<ExPolicy,
2056-
hpx::traits::range_iterator_t<Rng>>
2057-
tag_fallback_invoke(find_t, ExPolicy&& policy, Rng&& rng, T const& val,
2058-
Proj proj = Proj())
2056+
hpx::traits::range_iterator_t<Rng>> tag_fallback_invoke(find_t,
2057+
ExPolicy&& policy, Rng&& rng, T const& val, Proj proj = Proj())
20592058
{
20602059
using iterator_type = hpx::traits::range_iterator_t<Rng>;
20612060

@@ -2128,9 +2127,8 @@ namespace hpx::ranges {
21282127
)
21292128
// clang-format on
21302129
friend typename hpx::parallel::util::detail::algorithm_result<ExPolicy,
2131-
Iter>::type
2132-
tag_fallback_invoke(find_if_t, ExPolicy&& policy, Iter first, Sent last,
2133-
Pred&& pred, Proj&& proj = Proj())
2130+
Iter>::type tag_fallback_invoke(find_if_t, ExPolicy&& policy,
2131+
Iter first, Sent last, Pred&& pred, Proj&& proj = Proj())
21342132
{
21352133
static_assert(hpx::traits::is_forward_iterator_v<Iter>,
21362134
"Requires at least forward iterator.");
@@ -2155,9 +2153,8 @@ namespace hpx::ranges {
21552153
)
21562154
// clang-format on
21572155
friend hpx::parallel::util::detail::algorithm_result_t<ExPolicy,
2158-
hpx::traits::range_iterator_t<Rng>>
2159-
tag_fallback_invoke(find_if_t, ExPolicy&& policy, Rng&& rng, Pred pred,
2160-
Proj proj = Proj())
2156+
hpx::traits::range_iterator_t<Rng>> tag_fallback_invoke(find_if_t,
2157+
ExPolicy&& policy, Rng&& rng, Pred pred, Proj proj = Proj())
21612158
{
21622159
using iterator_type = hpx::traits::range_iterator_t<Rng>;
21632160

@@ -2344,10 +2341,9 @@ namespace hpx::ranges {
23442341
)
23452342
// clang-format on
23462343
friend hpx::parallel::util::detail::algorithm_result_t<ExPolicy,
2347-
hpx::traits::range_iterator_t<Rng1>>
2348-
tag_fallback_invoke(find_end_t, ExPolicy&& policy, Rng1&& rng1,
2349-
Rng2&& rng2, Pred op = Pred(), Proj1 proj1 = Proj1(),
2350-
Proj2 proj2 = Proj2())
2344+
hpx::traits::range_iterator_t<Rng1>> tag_fallback_invoke(find_end_t,
2345+
ExPolicy&& policy, Rng1&& rng1, Rng2&& rng2, Pred op = Pred(),
2346+
Proj1 proj1 = Proj1(), Proj2 proj2 = Proj2())
23512347
{
23522348
using iterator_type = hpx::traits::range_iterator_t<Rng1>;
23532349

@@ -2591,8 +2587,8 @@ namespace hpx::ranges {
25912587
: hpx::detail::tag_parallel_algorithm<find_last_t>
25922588
{
25932589
private:
2594-
template <typename ExPolicy, typename Iter, typename Sent,
2595-
typename Proj = hpx::identity, typename T>
2590+
template <typename ExPolicy, typename Iter, typename Sent, typename T,
2591+
typename Proj = hpx::identity>
25962592
// clang-format off
25972593
requires(
25982594
hpx::is_execution_policy_v<ExPolicy> &&
@@ -2632,8 +2628,8 @@ namespace hpx::ranges {
26322628
}
26332629
}
26342630

2635-
template <typename ExPolicy, typename Rng,
2636-
typename Proj = hpx::identity, typename T>
2631+
template <typename ExPolicy, typename Rng, typename T,
2632+
typename Proj = hpx::identity>
26372633
// clang-format off
26382634
requires(
26392635
hpx::is_execution_policy_v<ExPolicy> &&
@@ -2659,8 +2655,8 @@ namespace hpx::ranges {
26592655
hpx::util::end(rng), val, HPX_MOVE(proj)));
26602656
}
26612657

2662-
template <typename Iter, typename Sent, typename Proj = hpx::identity,
2663-
typename T>
2658+
template <typename Iter, typename Sent, typename T,
2659+
typename Proj = hpx::identity>
26642660
// clang-format off
26652661
requires(
26662662
hpx::traits::is_sentinel_for_v<Sent, Iter> &&
@@ -2680,7 +2676,7 @@ namespace hpx::ranges {
26802676
last);
26812677
}
26822678

2683-
template <typename Rng, typename Proj = hpx::identity, typename T>
2679+
template <typename Rng, typename T, typename Proj = hpx::identity>
26842680
// clang-format off
26852681
requires(
26862682
hpx::traits::is_range_v<Rng> &&

libs/core/runtime_local/tests/unit/CMakeLists.txt

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,13 @@
1-
# Copyright (c) 2020 Hartmut Kaiser
1+
# Copyright (c) 2020-2026 Hartmut Kaiser
22
#
33
# SPDX-License-Identifier: BSL-1.0
44
# Distributed under the Boost Software License, Version 1.0. (See accompanying
55
# file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
66

7-
set(tests thread_mapper test_termination_detection)
7+
set(tests thread_mapper termination_detection)
88

99
set(thread_mapper_PARAMETERS THREADS_PER_LOCALITY 4)
10-
set(test_termination_detection_PARAMETERS THREADS_PER_LOCALITY 4)
10+
set(termination_detection_PARAMETERS THREADS_PER_LOCALITY 4)
1111

1212
foreach(test ${tests})
1313
set(sources ${test}.cpp)

libs/core/runtime_local/tests/unit/test_termination_detection.cpp renamed to libs/core/runtime_local/tests/unit/termination_detection.cpp

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,13 +1,12 @@
1-
// Copyright (c) 2025 Arpit Khandelwal
1+
// Copyright (c) 2026 Arpit Khandelwal
22
//
33
// SPDX-License-Identifier: BSL-1.0
44
// Distributed under the Boost Software License, Version 1.0. (See accompanying
55
// file LICENSE_1_0.txt or copy at http://www.boost.org/LICENSE_1_0.txt)
66

77
#include <hpx/config.hpp>
88
#include <hpx/hpx_init.hpp>
9-
#include <hpx/include/async.hpp>
10-
#include <hpx/include/post.hpp>
9+
#include <hpx/modules/async_local.hpp>
1110
#include <hpx/modules/runtime_local.hpp>
1211
#include <hpx/modules/synchronization.hpp>
1312
#include <hpx/modules/testing.hpp>

0 commit comments

Comments
 (0)