2
0
mirror of https://github.com/boostorg/hof.git synced 2026-01-25 06:12:25 +00:00
Files
hof/test/repeat.cpp
2015-09-26 22:19:20 -07:00

19 lines
364 B
C++

#include <fit/repeat.h>
#include "test.h"
struct increment
{
template<class T>
constexpr T operator()(T x) const
{
return x + 1;
}
};
FIT_TEST_CASE()
{
FIT_TEST_CHECK(fit::repeat(std::integral_constant<int, 5>())(increment())(1) == 6);
FIT_STATIC_TEST_CHECK(fit::repeat(std::integral_constant<int, 5>())(increment())(1) == 6);
}