summaryrefslogtreecommitdiff
path: root/test/std/utilities/function.objects/comparisons/greater.pass.cpp
diff options
context:
space:
mode:
authorDimitry Andric <dim@FreeBSD.org>2016-07-23 20:47:26 +0000
committerDimitry Andric <dim@FreeBSD.org>2016-07-23 20:47:26 +0000
commit51072bd6bf79ef2bc6a922079bff57c31c1effbc (patch)
tree91a2effbc9e6f80bdbbf9eb70e06c51ad0867ea0 /test/std/utilities/function.objects/comparisons/greater.pass.cpp
parentbb5e33f003797b67974a8893f7f2930fc51b8210 (diff)
Notes
Diffstat (limited to 'test/std/utilities/function.objects/comparisons/greater.pass.cpp')
-rw-r--r--test/std/utilities/function.objects/comparisons/greater.pass.cpp10
1 files changed, 9 insertions, 1 deletions
diff --git a/test/std/utilities/function.objects/comparisons/greater.pass.cpp b/test/std/utilities/function.objects/comparisons/greater.pass.cpp
index 164f09aa605c..50bdcceee1c9 100644
--- a/test/std/utilities/function.objects/comparisons/greater.pass.cpp
+++ b/test/std/utilities/function.objects/comparisons/greater.pass.cpp
@@ -15,6 +15,9 @@
#include <type_traits>
#include <cassert>
+#include "test_macros.h"
+#include "pointer_comparison_test_helper.hpp"
+
int main()
{
typedef std::greater<int> F;
@@ -25,7 +28,12 @@ int main()
assert(!f(36, 36));
assert(f(36, 6));
assert(!f(6, 36));
-#if _LIBCPP_STD_VER > 11
+ {
+ // test total ordering of int* for greater<int*> and
+ // greater<void>.
+ do_pointer_comparison_test<int, std::greater>();
+ }
+#if TEST_STD_VER > 11
typedef std::greater<> F2;
const F2 f2 = F2();
assert(!f2(36, 36));