Skip to content

Commit eb178cb

Browse files
Deprecate and replace THRUST_STATIC_ASSERT (NVIDIA#3971)
1 parent 0d84574 commit eb178cb

17 files changed

+139
-216
lines changed

thrust/testing/complex.cu

+4-4
Original file line numberDiff line numberDiff line change
@@ -48,11 +48,11 @@ struct TestComplexSizeAndAlignment
4848
{
4949
void operator()()
5050
{
51-
THRUST_STATIC_ASSERT(sizeof(thrust::complex<T>) == sizeof(T) * 2);
52-
THRUST_STATIC_ASSERT(alignof(thrust::complex<T>) == alignof(T) * 2);
51+
static_assert(sizeof(thrust::complex<T>) == sizeof(T) * 2);
52+
static_assert(alignof(thrust::complex<T>) == alignof(T) * 2);
5353

54-
THRUST_STATIC_ASSERT(sizeof(thrust::complex<T const>) == sizeof(T) * 2);
55-
THRUST_STATIC_ASSERT(alignof(thrust::complex<T const>) == alignof(T) * 2);
54+
static_assert(sizeof(thrust::complex<T const>) == sizeof(T) * 2);
55+
static_assert(alignof(thrust::complex<T const>) == alignof(T) * 2);
5656
}
5757
};
5858
SimpleUnitTest<TestComplexSizeAndAlignment, FloatingPointTypes> TestComplexSizeAndAlignmentInstance;

thrust/testing/cuda/complex.cu

+4-4
Original file line numberDiff line numberDiff line change
@@ -9,11 +9,11 @@
99
template <typename T, typename VectorT>
1010
void TestComplexAlignment()
1111
{
12-
THRUST_STATIC_ASSERT(sizeof(thrust::complex<T>) == sizeof(VectorT));
13-
THRUST_STATIC_ASSERT(alignof(thrust::complex<T>) == alignof(VectorT));
12+
static_assert(sizeof(thrust::complex<T>) == sizeof(VectorT));
13+
static_assert(alignof(thrust::complex<T>) == alignof(VectorT));
1414

15-
THRUST_STATIC_ASSERT(sizeof(thrust::complex<T const>) == sizeof(VectorT));
16-
THRUST_STATIC_ASSERT(alignof(thrust::complex<T const>) == alignof(VectorT));
15+
static_assert(sizeof(thrust::complex<T const>) == sizeof(VectorT));
16+
static_assert(alignof(thrust::complex<T const>) == alignof(VectorT));
1717
}
1818
DECLARE_UNITTEST_WITH_NAME(THRUST_PP_EXPAND_ARGS(TestComplexAlignment<char, char2>), TestComplexCharAlignment);
1919
DECLARE_UNITTEST_WITH_NAME(THRUST_PP_EXPAND_ARGS(TestComplexAlignment<short, short2>), TestComplexShortAlignment);

thrust/testing/is_contiguous_iterator.cu

+53-78
Original file line numberDiff line numberDiff line change
@@ -19,61 +19,40 @@
1919

2020
#include <unittest/unittest.h>
2121

22-
THRUST_STATIC_ASSERT((thrust::is_contiguous_iterator<std::string::iterator>::value));
23-
24-
THRUST_STATIC_ASSERT((thrust::is_contiguous_iterator<std::wstring::iterator>::value));
25-
26-
THRUST_STATIC_ASSERT((thrust::is_contiguous_iterator<std::string_view::iterator>::value));
27-
28-
THRUST_STATIC_ASSERT((thrust::is_contiguous_iterator<std::wstring_view::iterator>::value));
29-
30-
THRUST_STATIC_ASSERT((!thrust::is_contiguous_iterator<std::vector<bool>::iterator>::value));
22+
static_assert(thrust::is_contiguous_iterator<std::string::iterator>::value);
23+
static_assert(thrust::is_contiguous_iterator<std::wstring::iterator>::value);
24+
static_assert(thrust::is_contiguous_iterator<std::string_view::iterator>::value);
25+
static_assert(thrust::is_contiguous_iterator<std::wstring_view::iterator>::value);
26+
static_assert(!thrust::is_contiguous_iterator<std::vector<bool>::iterator>::value);
3127

3228
template <typename T>
3329
_CCCL_HOST void test_is_contiguous_iterator()
3430
{
35-
THRUST_STATIC_ASSERT((thrust::is_contiguous_iterator<T*>::value));
36-
37-
THRUST_STATIC_ASSERT((thrust::is_contiguous_iterator<T const*>::value));
38-
39-
THRUST_STATIC_ASSERT((thrust::is_contiguous_iterator<thrust::device_ptr<T>>::value));
40-
41-
THRUST_STATIC_ASSERT((thrust::is_contiguous_iterator<typename std::vector<T>::iterator>::value));
42-
43-
THRUST_STATIC_ASSERT((!thrust::is_contiguous_iterator<typename std::vector<T>::reverse_iterator>::value));
44-
45-
THRUST_STATIC_ASSERT((thrust::is_contiguous_iterator<typename std::array<T, 1>::iterator>::value));
46-
47-
THRUST_STATIC_ASSERT((!thrust::is_contiguous_iterator<typename std::list<T>::iterator>::value));
48-
49-
THRUST_STATIC_ASSERT((!thrust::is_contiguous_iterator<typename std::deque<T>::iterator>::value));
50-
51-
THRUST_STATIC_ASSERT((!thrust::is_contiguous_iterator<typename std::set<T>::iterator>::value));
52-
53-
THRUST_STATIC_ASSERT((!thrust::is_contiguous_iterator<typename std::multiset<T>::iterator>::value));
54-
55-
THRUST_STATIC_ASSERT((!thrust::is_contiguous_iterator<typename std::map<T, T>::iterator>::value));
56-
57-
THRUST_STATIC_ASSERT((!thrust::is_contiguous_iterator<typename std::multimap<T, T>::iterator>::value));
58-
59-
THRUST_STATIC_ASSERT((!thrust::is_contiguous_iterator<typename std::unordered_set<T>::iterator>::value));
60-
61-
THRUST_STATIC_ASSERT((!thrust::is_contiguous_iterator<typename std::unordered_multiset<T>::iterator>::value));
62-
63-
THRUST_STATIC_ASSERT((!thrust::is_contiguous_iterator<typename std::unordered_map<T, T>::iterator>::value));
64-
65-
THRUST_STATIC_ASSERT((!thrust::is_contiguous_iterator<typename std::unordered_multimap<T, T>::iterator>::value));
66-
67-
THRUST_STATIC_ASSERT((!thrust::is_contiguous_iterator<std::istream_iterator<T>>::value));
68-
69-
THRUST_STATIC_ASSERT((!thrust::is_contiguous_iterator<std::ostream_iterator<T>>::value));
31+
static_assert(thrust::is_contiguous_iterator<T*>::value);
32+
static_assert(thrust::is_contiguous_iterator<T const*>::value);
33+
static_assert(thrust::is_contiguous_iterator<thrust::device_ptr<T>>::value);
34+
static_assert(thrust::is_contiguous_iterator<typename std::vector<T>::iterator>::value);
35+
static_assert(!thrust::is_contiguous_iterator<typename std::vector<T>::reverse_iterator>::value);
36+
static_assert(thrust::is_contiguous_iterator<typename std::array<T, 1>::iterator>::value);
37+
static_assert(!thrust::is_contiguous_iterator<typename std::list<T>::iterator>::value);
38+
static_assert(!thrust::is_contiguous_iterator<typename std::deque<T>::iterator>::value);
39+
static_assert(!thrust::is_contiguous_iterator<typename std::set<T>::iterator>::value);
40+
static_assert(!thrust::is_contiguous_iterator<typename std::multiset<T>::iterator>::value);
41+
static_assert(!thrust::is_contiguous_iterator<typename std::map<T, T>::iterator>::value);
42+
static_assert(!thrust::is_contiguous_iterator<typename std::multimap<T, T>::iterator>::value);
43+
static_assert(!thrust::is_contiguous_iterator<typename std::unordered_set<T>::iterator>::value);
44+
static_assert(!thrust::is_contiguous_iterator<typename std::unordered_multiset<T>::iterator>::value);
45+
static_assert(!thrust::is_contiguous_iterator<typename std::unordered_map<T, T>::iterator>::value);
46+
static_assert(!thrust::is_contiguous_iterator<typename std::unordered_multimap<T, T>::iterator>::value);
47+
static_assert(!thrust::is_contiguous_iterator<std::istream_iterator<T>>::value);
48+
static_assert(!thrust::is_contiguous_iterator<std::ostream_iterator<T>>::value);
7049
}
7150
DECLARE_GENERIC_UNITTEST(test_is_contiguous_iterator);
7251

7352
template <typename Vector>
7453
_CCCL_HOST void test_is_contiguous_iterator_vectors()
7554
{
76-
THRUST_STATIC_ASSERT((thrust::is_contiguous_iterator<typename Vector::iterator>::value));
55+
static_assert(thrust::is_contiguous_iterator<typename Vector::iterator>::value);
7756
}
7857
DECLARE_VECTOR_UNITTEST(test_is_contiguous_iterator_vectors);
7958

@@ -98,38 +77,34 @@ template <typename T>
9877
void test_try_unwrap_contiguous_iterator()
9978
{
10079
// Raw pointers should pass whether expecting pointers or passthrough.
101-
THRUST_STATIC_ASSERT((check_unwrapped_iterator<T*, T*, expect_pointer>::value));
102-
THRUST_STATIC_ASSERT((check_unwrapped_iterator<T*, T*, expect_passthrough>::value));
103-
THRUST_STATIC_ASSERT((check_unwrapped_iterator<T const*, T const*, expect_pointer>::value));
104-
THRUST_STATIC_ASSERT((check_unwrapped_iterator<T const*, T const*, expect_passthrough>::value));
105-
106-
THRUST_STATIC_ASSERT((check_unwrapped_iterator<thrust::device_ptr<T>, T*, expect_pointer>::value));
107-
THRUST_STATIC_ASSERT((check_unwrapped_iterator<thrust::device_ptr<T const>, T const*, expect_pointer>::value));
108-
THRUST_STATIC_ASSERT((check_unwrapped_iterator<typename std::vector<T>::iterator, T*, expect_pointer>::value));
109-
THRUST_STATIC_ASSERT(
110-
(check_unwrapped_iterator<typename std::vector<T>::reverse_iterator, T*, expect_passthrough>::value));
111-
THRUST_STATIC_ASSERT((check_unwrapped_iterator<typename std::array<T, 1>::iterator, T*, expect_pointer>::value));
112-
THRUST_STATIC_ASSERT(
113-
(check_unwrapped_iterator<typename std::array<T const, 1>::iterator, T const*, expect_pointer>::value));
114-
THRUST_STATIC_ASSERT((check_unwrapped_iterator<typename std::list<T>::iterator, T*, expect_passthrough>::value));
115-
THRUST_STATIC_ASSERT((check_unwrapped_iterator<typename std::deque<T>::iterator, T*, expect_passthrough>::value));
116-
THRUST_STATIC_ASSERT((check_unwrapped_iterator<typename std::set<T>::iterator, T*, expect_passthrough>::value));
117-
THRUST_STATIC_ASSERT((check_unwrapped_iterator<typename std::multiset<T>::iterator, T*, expect_passthrough>::value));
118-
THRUST_STATIC_ASSERT(
119-
(check_unwrapped_iterator<typename std::map<T, T>::iterator, std::pair<T const, T>*, expect_passthrough>::value));
120-
THRUST_STATIC_ASSERT((
121-
check_unwrapped_iterator<typename std::multimap<T, T>::iterator, std::pair<T const, T>*, expect_passthrough>::value));
122-
THRUST_STATIC_ASSERT(
123-
(check_unwrapped_iterator<typename std::unordered_set<T>::iterator, T*, expect_passthrough>::value));
124-
THRUST_STATIC_ASSERT(
125-
(check_unwrapped_iterator<typename std::unordered_multiset<T>::iterator, T*, expect_passthrough>::value));
126-
THRUST_STATIC_ASSERT(
127-
(check_unwrapped_iterator<typename std::unordered_map<T, T>::iterator, std::pair<T const, T>*, expect_passthrough>::
128-
value));
129-
THRUST_STATIC_ASSERT((check_unwrapped_iterator<typename std::unordered_multimap<T, T>::iterator,
130-
std::pair<T const, T>*,
131-
expect_passthrough>::value));
132-
THRUST_STATIC_ASSERT((check_unwrapped_iterator<std::istream_iterator<T>, T*, expect_passthrough>::value));
133-
THRUST_STATIC_ASSERT((check_unwrapped_iterator<std::ostream_iterator<T>, void, expect_passthrough>::value));
80+
static_assert(check_unwrapped_iterator<T*, T*, expect_pointer>::value);
81+
static_assert(check_unwrapped_iterator<T*, T*, expect_passthrough>::value);
82+
static_assert(check_unwrapped_iterator<T const*, T const*, expect_pointer>::value);
83+
static_assert(check_unwrapped_iterator<T const*, T const*, expect_passthrough>::value);
84+
85+
static_assert(check_unwrapped_iterator<thrust::device_ptr<T>, T*, expect_pointer>::value);
86+
static_assert(check_unwrapped_iterator<thrust::device_ptr<T const>, T const*, expect_pointer>::value);
87+
static_assert(check_unwrapped_iterator<typename std::vector<T>::iterator, T*, expect_pointer>::value);
88+
static_assert(check_unwrapped_iterator<typename std::vector<T>::reverse_iterator, T*, expect_passthrough>::value);
89+
static_assert(check_unwrapped_iterator<typename std::array<T, 1>::iterator, T*, expect_pointer>::value);
90+
static_assert(check_unwrapped_iterator<typename std::array<T const, 1>::iterator, T const*, expect_pointer>::value);
91+
static_assert(check_unwrapped_iterator<typename std::list<T>::iterator, T*, expect_passthrough>::value);
92+
static_assert(check_unwrapped_iterator<typename std::deque<T>::iterator, T*, expect_passthrough>::value);
93+
static_assert(check_unwrapped_iterator<typename std::set<T>::iterator, T*, expect_passthrough>::value);
94+
static_assert(check_unwrapped_iterator<typename std::multiset<T>::iterator, T*, expect_passthrough>::value);
95+
static_assert(
96+
check_unwrapped_iterator<typename std::map<T, T>::iterator, std::pair<T const, T>*, expect_passthrough>::value);
97+
static_assert(
98+
check_unwrapped_iterator<typename std::multimap<T, T>::iterator, std::pair<T const, T>*, expect_passthrough>::value);
99+
static_assert(check_unwrapped_iterator<typename std::unordered_set<T>::iterator, T*, expect_passthrough>::value);
100+
static_assert(check_unwrapped_iterator<typename std::unordered_multiset<T>::iterator, T*, expect_passthrough>::value);
101+
static_assert(
102+
check_unwrapped_iterator<typename std::unordered_map<T, T>::iterator, std::pair<T const, T>*, expect_passthrough>::
103+
value);
104+
static_assert(check_unwrapped_iterator<typename std::unordered_multimap<T, T>::iterator,
105+
std::pair<T const, T>*,
106+
expect_passthrough>::value);
107+
static_assert(check_unwrapped_iterator<std::istream_iterator<T>, T*, expect_passthrough>::value);
108+
static_assert(check_unwrapped_iterator<std::ostream_iterator<T>, void, expect_passthrough>::value);
134109
}
135110
DECLARE_GENERIC_UNITTEST(test_try_unwrap_contiguous_iterator);

thrust/testing/is_operator_function_object.cu

+41-77
Original file line numberDiff line numberDiff line change
@@ -4,104 +4,68 @@
44

55
#include <unittest/unittest.h>
66

7-
THRUST_STATIC_ASSERT((thrust::is_operator_less_function_object<std::less<>>::value));
8-
9-
THRUST_STATIC_ASSERT((thrust::is_operator_greater_function_object<std::greater<>>::value));
10-
11-
THRUST_STATIC_ASSERT((thrust::is_operator_less_or_greater_function_object<std::less<>>::value));
12-
13-
THRUST_STATIC_ASSERT((thrust::is_operator_less_or_greater_function_object<std::greater<>>::value));
14-
15-
THRUST_STATIC_ASSERT((thrust::is_operator_plus_function_object<std::plus<>>::value));
7+
static_assert(thrust::is_operator_less_function_object<std::less<>>::value);
8+
static_assert(thrust::is_operator_greater_function_object<std::greater<>>::value);
9+
static_assert(thrust::is_operator_less_or_greater_function_object<std::less<>>::value);
10+
static_assert(thrust::is_operator_less_or_greater_function_object<std::greater<>>::value);
11+
static_assert(thrust::is_operator_plus_function_object<std::plus<>>::value);
1612

1713
template <typename T>
1814
_CCCL_HOST void test_is_operator_less_function_object()
1915
{
20-
THRUST_STATIC_ASSERT((thrust::is_operator_less_function_object<thrust::less<T>>::value));
21-
22-
THRUST_STATIC_ASSERT((!thrust::is_operator_less_function_object<thrust::greater<T>>::value));
23-
24-
THRUST_STATIC_ASSERT((!thrust::is_operator_less_function_object<thrust::less_equal<T>>::value));
25-
26-
THRUST_STATIC_ASSERT((!thrust::is_operator_less_function_object<thrust::greater_equal<T>>::value));
27-
28-
THRUST_STATIC_ASSERT((thrust::is_operator_less_function_object<std::less<T>>::value));
29-
30-
THRUST_STATIC_ASSERT((!thrust::is_operator_less_function_object<std::greater<T>>::value));
31-
32-
THRUST_STATIC_ASSERT((!thrust::is_operator_less_function_object<std::less_equal<T>>::value));
33-
34-
THRUST_STATIC_ASSERT((!thrust::is_operator_less_function_object<std::greater_equal<T>>::value));
35-
36-
THRUST_STATIC_ASSERT((!thrust::is_operator_less_function_object<T>::value));
16+
static_assert(thrust::is_operator_less_function_object<thrust::less<T>>::value);
17+
static_assert(!thrust::is_operator_less_function_object<thrust::greater<T>>::value);
18+
static_assert(!thrust::is_operator_less_function_object<thrust::less_equal<T>>::value);
19+
static_assert(!thrust::is_operator_less_function_object<thrust::greater_equal<T>>::value);
20+
static_assert(thrust::is_operator_less_function_object<std::less<T>>::value);
21+
static_assert(!thrust::is_operator_less_function_object<std::greater<T>>::value);
22+
static_assert(!thrust::is_operator_less_function_object<std::less_equal<T>>::value);
23+
static_assert(!thrust::is_operator_less_function_object<std::greater_equal<T>>::value);
24+
static_assert(!thrust::is_operator_less_function_object<T>::value);
3725
}
3826
DECLARE_GENERIC_UNITTEST(test_is_operator_less_function_object);
3927

4028
template <typename T>
4129
_CCCL_HOST void test_is_operator_greater_function_object()
4230
{
43-
THRUST_STATIC_ASSERT((!thrust::is_operator_greater_function_object<thrust::less<T>>::value));
44-
45-
THRUST_STATIC_ASSERT((thrust::is_operator_greater_function_object<thrust::greater<T>>::value));
46-
47-
THRUST_STATIC_ASSERT((!thrust::is_operator_greater_function_object<thrust::less_equal<T>>::value));
48-
49-
THRUST_STATIC_ASSERT((!thrust::is_operator_greater_function_object<thrust::greater_equal<T>>::value));
50-
51-
THRUST_STATIC_ASSERT((!thrust::is_operator_greater_function_object<std::less<T>>::value));
52-
53-
THRUST_STATIC_ASSERT((thrust::is_operator_greater_function_object<std::greater<T>>::value));
54-
55-
THRUST_STATIC_ASSERT((!thrust::is_operator_greater_function_object<std::less_equal<T>>::value));
56-
57-
THRUST_STATIC_ASSERT((!thrust::is_operator_greater_function_object<std::greater_equal<T>>::value));
58-
59-
THRUST_STATIC_ASSERT((!thrust::is_operator_greater_function_object<T>::value));
31+
static_assert(!thrust::is_operator_greater_function_object<thrust::less<T>>::value);
32+
static_assert(thrust::is_operator_greater_function_object<thrust::greater<T>>::value);
33+
static_assert(!thrust::is_operator_greater_function_object<thrust::less_equal<T>>::value);
34+
static_assert(!thrust::is_operator_greater_function_object<thrust::greater_equal<T>>::value);
35+
static_assert(!thrust::is_operator_greater_function_object<std::less<T>>::value);
36+
static_assert(thrust::is_operator_greater_function_object<std::greater<T>>::value);
37+
static_assert(!thrust::is_operator_greater_function_object<std::less_equal<T>>::value);
38+
static_assert(!thrust::is_operator_greater_function_object<std::greater_equal<T>>::value);
39+
static_assert(!thrust::is_operator_greater_function_object<T>::value);
6040
}
6141
DECLARE_GENERIC_UNITTEST(test_is_operator_greater_function_object);
6242

6343
template <typename T>
6444
_CCCL_HOST void test_is_operator_less_or_greater_function_object()
6545
{
66-
THRUST_STATIC_ASSERT((thrust::is_operator_less_or_greater_function_object<thrust::less<T>>::value));
67-
68-
THRUST_STATIC_ASSERT((thrust::is_operator_less_or_greater_function_object<thrust::greater<T>>::value));
69-
70-
THRUST_STATIC_ASSERT((!thrust::is_operator_less_or_greater_function_object<thrust::less_equal<T>>::value));
71-
72-
THRUST_STATIC_ASSERT((!thrust::is_operator_less_or_greater_function_object<thrust::greater_equal<T>>::value));
73-
74-
THRUST_STATIC_ASSERT((thrust::is_operator_less_or_greater_function_object<std::less<T>>::value));
75-
76-
THRUST_STATIC_ASSERT((thrust::is_operator_less_or_greater_function_object<std::greater<T>>::value));
77-
78-
THRUST_STATIC_ASSERT((!thrust::is_operator_less_or_greater_function_object<std::less_equal<T>>::value));
79-
80-
THRUST_STATIC_ASSERT((!thrust::is_operator_less_or_greater_function_object<std::greater_equal<T>>::value));
81-
82-
THRUST_STATIC_ASSERT((!thrust::is_operator_less_or_greater_function_object<T>::value));
46+
static_assert(thrust::is_operator_less_or_greater_function_object<thrust::less<T>>::value);
47+
static_assert(thrust::is_operator_less_or_greater_function_object<thrust::greater<T>>::value);
48+
static_assert(!thrust::is_operator_less_or_greater_function_object<thrust::less_equal<T>>::value);
49+
static_assert(!thrust::is_operator_less_or_greater_function_object<thrust::greater_equal<T>>::value);
50+
static_assert(thrust::is_operator_less_or_greater_function_object<std::less<T>>::value);
51+
static_assert(thrust::is_operator_less_or_greater_function_object<std::greater<T>>::value);
52+
static_assert(!thrust::is_operator_less_or_greater_function_object<std::less_equal<T>>::value);
53+
static_assert(!thrust::is_operator_less_or_greater_function_object<std::greater_equal<T>>::value);
54+
static_assert(!thrust::is_operator_less_or_greater_function_object<T>::value);
8355
}
8456
DECLARE_GENERIC_UNITTEST(test_is_operator_less_or_greater_function_object);
8557

8658
template <typename T>
8759
_CCCL_HOST void test_is_operator_plus_function_object()
8860
{
89-
THRUST_STATIC_ASSERT((thrust::is_operator_plus_function_object<thrust::plus<T>>::value));
90-
91-
THRUST_STATIC_ASSERT((!thrust::is_operator_plus_function_object<thrust::minus<T>>::value));
92-
93-
THRUST_STATIC_ASSERT((!thrust::is_operator_plus_function_object<thrust::less<T>>::value));
94-
95-
THRUST_STATIC_ASSERT((!thrust::is_operator_plus_function_object<thrust::greater<T>>::value));
96-
97-
THRUST_STATIC_ASSERT((thrust::is_operator_plus_function_object<std::plus<T>>::value));
98-
99-
THRUST_STATIC_ASSERT((!thrust::is_operator_plus_function_object<std::minus<T>>::value));
100-
101-
THRUST_STATIC_ASSERT((!thrust::is_operator_plus_function_object<std::less<T>>::value));
102-
103-
THRUST_STATIC_ASSERT((!thrust::is_operator_plus_function_object<std::greater<T>>::value));
104-
105-
THRUST_STATIC_ASSERT((!thrust::is_operator_plus_function_object<T>::value));
61+
static_assert(thrust::is_operator_plus_function_object<thrust::plus<T>>::value);
62+
static_assert(!thrust::is_operator_plus_function_object<thrust::minus<T>>::value);
63+
static_assert(!thrust::is_operator_plus_function_object<thrust::less<T>>::value);
64+
static_assert(!thrust::is_operator_plus_function_object<thrust::greater<T>>::value);
65+
static_assert(thrust::is_operator_plus_function_object<std::plus<T>>::value);
66+
static_assert(!thrust::is_operator_plus_function_object<std::minus<T>>::value);
67+
static_assert(!thrust::is_operator_plus_function_object<std::less<T>>::value);
68+
static_assert(!thrust::is_operator_plus_function_object<std::greater<T>>::value);
69+
static_assert(!thrust::is_operator_plus_function_object<T>::value);
10670
}
10771
DECLARE_GENERIC_UNITTEST(test_is_operator_plus_function_object);

0 commit comments

Comments
 (0)