Skip to content

Commit 719aac5

Browse files
reduce code in times.hpp.
1 parent d30e388 commit 719aac5

File tree

1 file changed

+1
-11
lines changed

1 file changed

+1
-11
lines changed

times.hpp

Lines changed: 1 addition & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -5,16 +5,6 @@
55

66
namespace mlib
77
{
8-
// this allows no recursion
9-
struct callable_wrapper
10-
{
11-
constexpr callable_wrapper() {}
12-
13-
constexpr auto operator()(auto callable, std::size_t index)
14-
{
15-
callable();
16-
}
17-
};
188

199
template<auto T>
2010
struct times
@@ -23,7 +13,7 @@ namespace mlib
2313
{
2414
[&] <std::size_t... indexes>(std::index_sequence<indexes...>)
2515
{
26-
(callable_wrapper{}(callable, indexes), ...);
16+
(callable, void(indexes), ...);
2717
}(std::make_index_sequence<T>{});
2818
}
2919
};

0 commit comments

Comments
 (0)