@@ -9,32 +9,28 @@ struct TestMin
99 {
1010 // 2 < 3
1111 T two (2 ), three (3 );
12- ASSERT_EQUAL (two, thrust:: min THRUST_PREVENT_MACRO_SUBSTITUTION (two, three));
13- ASSERT_EQUAL (two, thrust:: min THRUST_PREVENT_MACRO_SUBSTITUTION (two, three, thrust::less<T>()));
12+ ASSERT_EQUAL (two, :: cuda::std:: min (two, three));
13+ ASSERT_EQUAL (two, :: cuda::std:: min (two, three, thrust::less<T>()));
1414
15- ASSERT_EQUAL (two, thrust:: min THRUST_PREVENT_MACRO_SUBSTITUTION (three, two));
16- ASSERT_EQUAL (two, thrust:: min THRUST_PREVENT_MACRO_SUBSTITUTION (three, two, thrust::less<T>()));
15+ ASSERT_EQUAL (two, :: cuda::std:: min (three, two));
16+ ASSERT_EQUAL (two, :: cuda::std:: min (three, two, thrust::less<T>()));
1717
18- ASSERT_EQUAL (three, thrust:: min THRUST_PREVENT_MACRO_SUBSTITUTION (two, three, thrust::greater<T>()));
19- ASSERT_EQUAL (three, thrust:: min THRUST_PREVENT_MACRO_SUBSTITUTION (three, two, thrust::greater<T>()));
18+ ASSERT_EQUAL (three, :: cuda::std:: min (two, three, thrust::greater<T>()));
19+ ASSERT_EQUAL (three, :: cuda::std:: min (three, two, thrust::greater<T>()));
2020
2121 using KV = key_value<T, T>;
2222 KV two_and_two (two, two);
2323 KV two_and_three (two, three);
2424
2525 // the first element breaks ties
26- ASSERT_EQUAL_QUIET (two_and_two, thrust:: min THRUST_PREVENT_MACRO_SUBSTITUTION (two_and_two, two_and_three));
27- ASSERT_EQUAL_QUIET (two_and_three, thrust:: min THRUST_PREVENT_MACRO_SUBSTITUTION (two_and_three, two_and_two));
26+ ASSERT_EQUAL_QUIET (two_and_two, :: cuda::std:: min (two_and_two, two_and_three));
27+ ASSERT_EQUAL_QUIET (two_and_three, :: cuda::std:: min (two_and_three, two_and_two));
2828
29- ASSERT_EQUAL_QUIET (two_and_two,
30- thrust::min THRUST_PREVENT_MACRO_SUBSTITUTION (two_and_two, two_and_three, thrust::less<KV>()));
31- ASSERT_EQUAL_QUIET (two_and_three,
32- thrust::min THRUST_PREVENT_MACRO_SUBSTITUTION (two_and_three, two_and_two, thrust::less<KV>()));
29+ ASSERT_EQUAL_QUIET (two_and_two, ::cuda::std::min (two_and_two, two_and_three, thrust::less<KV>()));
30+ ASSERT_EQUAL_QUIET (two_and_three, ::cuda::std::min (two_and_three, two_and_two, thrust::less<KV>()));
3331
34- ASSERT_EQUAL_QUIET (
35- two_and_two, thrust::min THRUST_PREVENT_MACRO_SUBSTITUTION (two_and_two, two_and_three, thrust::greater<KV>()));
36- ASSERT_EQUAL_QUIET (
37- two_and_three, thrust::min THRUST_PREVENT_MACRO_SUBSTITUTION (two_and_three, two_and_two, thrust::greater<KV>()));
32+ ASSERT_EQUAL_QUIET (two_and_two, ::cuda::std::min (two_and_two, two_and_three, thrust::greater<KV>()));
33+ ASSERT_EQUAL_QUIET (two_and_three, ::cuda::std::min (two_and_three, two_and_two, thrust::greater<KV>()));
3834 }
3935};
4036SimpleUnitTest<TestMin, NumericTypes> TestMinInstance;
@@ -46,32 +42,28 @@ struct TestMax
4642 {
4743 // 2 < 3
4844 T two (2 ), three (3 );
49- ASSERT_EQUAL (three, thrust:: max THRUST_PREVENT_MACRO_SUBSTITUTION (two, three));
50- ASSERT_EQUAL (three, thrust:: max THRUST_PREVENT_MACRO_SUBSTITUTION (two, three, thrust::less<T>()));
45+ ASSERT_EQUAL (three, :: cuda::std:: max (two, three));
46+ ASSERT_EQUAL (three, :: cuda::std:: max (two, three, thrust::less<T>()));
5147
52- ASSERT_EQUAL (three, thrust:: max THRUST_PREVENT_MACRO_SUBSTITUTION (three, two));
53- ASSERT_EQUAL (three, thrust:: max THRUST_PREVENT_MACRO_SUBSTITUTION (three, two, thrust::less<T>()));
48+ ASSERT_EQUAL (three, :: cuda::std:: max (three, two));
49+ ASSERT_EQUAL (three, :: cuda::std:: max (three, two, thrust::less<T>()));
5450
55- ASSERT_EQUAL (two, thrust:: max THRUST_PREVENT_MACRO_SUBSTITUTION (two, three, thrust::greater<T>()));
56- ASSERT_EQUAL (two, thrust:: max THRUST_PREVENT_MACRO_SUBSTITUTION (three, two, thrust::greater<T>()));
51+ ASSERT_EQUAL (two, :: cuda::std:: max (two, three, thrust::greater<T>()));
52+ ASSERT_EQUAL (two, :: cuda::std:: max (three, two, thrust::greater<T>()));
5753
5854 using KV = key_value<T, T>;
5955 KV two_and_two (two, two);
6056 KV two_and_three (two, three);
6157
6258 // the first element breaks ties
63- ASSERT_EQUAL_QUIET (two_and_two, thrust:: max THRUST_PREVENT_MACRO_SUBSTITUTION (two_and_two, two_and_three));
64- ASSERT_EQUAL_QUIET (two_and_three, thrust:: max THRUST_PREVENT_MACRO_SUBSTITUTION (two_and_three, two_and_two));
59+ ASSERT_EQUAL_QUIET (two_and_two, :: cuda::std:: max (two_and_two, two_and_three));
60+ ASSERT_EQUAL_QUIET (two_and_three, :: cuda::std:: max (two_and_three, two_and_two));
6561
66- ASSERT_EQUAL_QUIET (two_and_two,
67- thrust::max THRUST_PREVENT_MACRO_SUBSTITUTION (two_and_two, two_and_three, thrust::less<KV>()));
68- ASSERT_EQUAL_QUIET (two_and_three,
69- thrust::max THRUST_PREVENT_MACRO_SUBSTITUTION (two_and_three, two_and_two, thrust::less<KV>()));
62+ ASSERT_EQUAL_QUIET (two_and_two, ::cuda::std::max (two_and_two, two_and_three, thrust::less<KV>()));
63+ ASSERT_EQUAL_QUIET (two_and_three, ::cuda::std::max (two_and_three, two_and_two, thrust::less<KV>()));
7064
71- ASSERT_EQUAL_QUIET (
72- two_and_two, thrust::max THRUST_PREVENT_MACRO_SUBSTITUTION (two_and_two, two_and_three, thrust::greater<KV>()));
73- ASSERT_EQUAL_QUIET (
74- two_and_three, thrust::max THRUST_PREVENT_MACRO_SUBSTITUTION (two_and_three, two_and_two, thrust::greater<KV>()));
65+ ASSERT_EQUAL_QUIET (two_and_two, ::cuda::std::max (two_and_two, two_and_three, thrust::greater<KV>()));
66+ ASSERT_EQUAL_QUIET (two_and_three, ::cuda::std::max (two_and_three, two_and_two, thrust::greater<KV>()));
7567 }
7668};
7769SimpleUnitTest<TestMax, NumericTypes> TestMaxInstance;
0 commit comments