summaryrefslogtreecommitdiffstats
path: root/libcxx/test/std/algorithms
diff options
context:
space:
mode:
authorMarshall Clow <mclow.lists@gmail.com>2018-01-15 19:32:32 +0000
committerMarshall Clow <mclow.lists@gmail.com>2018-01-15 19:32:32 +0000
commit404ee020f017bc3fffaadcdbc50f8f49a3674046 (patch)
tree3f7596ec3e7449b4fc2b7ab85d127343e4440d29 /libcxx/test/std/algorithms
parent8694428e365648723f5519af0a6818eb24ecb990 (diff)
downloadbcm5719-llvm-404ee020f017bc3fffaadcdbc50f8f49a3674046.tar.gz
bcm5719-llvm-404ee020f017bc3fffaadcdbc50f8f49a3674046.zip
Some of the tests from earlier today had 'int' as the return type when it should have been 'bool'. Fix that. It doesn't change the behavior of any of the tests, but it's more accurate.
llvm-svn: 322505
Diffstat (limited to 'libcxx/test/std/algorithms')
-rw-r--r--libcxx/test/std/algorithms/alg.modifying.operations/alg.partitions/is_partitioned.pass.cpp2
-rw-r--r--libcxx/test/std/algorithms/alg.modifying.operations/alg.partitions/partition_point.pass.cpp2
-rw-r--r--libcxx/test/std/algorithms/alg.nonmodifying/alg.all_of/all_of.pass.cpp2
-rw-r--r--libcxx/test/std/algorithms/alg.nonmodifying/alg.any_of/any_of.pass.cpp2
-rw-r--r--libcxx/test/std/algorithms/alg.nonmodifying/alg.is_permutation/is_permutation.pass.cpp2
-rw-r--r--libcxx/test/std/algorithms/alg.nonmodifying/alg.is_permutation/is_permutation_pred.pass.cpp2
-rw-r--r--libcxx/test/std/algorithms/alg.nonmodifying/alg.none_of/none_of.pass.cpp2
-rw-r--r--libcxx/test/std/algorithms/alg.sorting/alg.heap.operations/is.heap/is_heap.pass.cpp2
-rw-r--r--libcxx/test/std/algorithms/alg.sorting/alg.heap.operations/is.heap/is_heap_comp.pass.cpp2
-rw-r--r--libcxx/test/std/algorithms/alg.sorting/alg.heap.operations/is.heap/is_heap_until.pass.cpp2
-rw-r--r--libcxx/test/std/algorithms/alg.sorting/alg.heap.operations/is.heap/is_heap_until_comp.pass.cpp2
-rw-r--r--libcxx/test/std/algorithms/alg.sorting/alg.sort/is.sorted/is_sorted.pass.cpp2
-rw-r--r--libcxx/test/std/algorithms/alg.sorting/alg.sort/is.sorted/is_sorted_comp.pass.cpp2
-rw-r--r--libcxx/test/std/algorithms/alg.sorting/alg.sort/is.sorted/is_sorted_until.pass.cpp2
-rw-r--r--libcxx/test/std/algorithms/alg.sorting/alg.sort/is.sorted/is_sorted_until_comp.pass.cpp2
15 files changed, 15 insertions, 15 deletions
diff --git a/libcxx/test/std/algorithms/alg.modifying.operations/alg.partitions/is_partitioned.pass.cpp b/libcxx/test/std/algorithms/alg.modifying.operations/alg.partitions/is_partitioned.pass.cpp
index eb9be71c2b5..b68b28de47c 100644
--- a/libcxx/test/std/algorithms/alg.modifying.operations/alg.partitions/is_partitioned.pass.cpp
+++ b/libcxx/test/std/algorithms/alg.modifying.operations/alg.partitions/is_partitioned.pass.cpp
@@ -27,7 +27,7 @@ struct is_odd {
};
#if TEST_STD_VER > 17
-TEST_CONSTEXPR int test_constexpr() {
+TEST_CONSTEXPR bool test_constexpr() {
int ia[] = {1, 3, 5, 2, 4, 6};
int ib[] = {1, 2, 3, 4, 5, 6};
return std::is_partitioned(std::begin(ia), std::end(ia), is_odd())
diff --git a/libcxx/test/std/algorithms/alg.modifying.operations/alg.partitions/partition_point.pass.cpp b/libcxx/test/std/algorithms/alg.modifying.operations/alg.partitions/partition_point.pass.cpp
index a08912bad57..1ea9885c1bd 100644
--- a/libcxx/test/std/algorithms/alg.modifying.operations/alg.partitions/partition_point.pass.cpp
+++ b/libcxx/test/std/algorithms/alg.modifying.operations/alg.partitions/partition_point.pass.cpp
@@ -26,7 +26,7 @@ struct is_odd
#if TEST_STD_VER > 17
-TEST_CONSTEXPR int test_constexpr() {
+TEST_CONSTEXPR bool test_constexpr() {
int ia[] = {1, 3, 5, 2, 4, 6};
int ib[] = {1, 2, 3, 4, 5, 6};
return (std::partition_point(std::begin(ia), std::end(ia), is_odd()) == ia+3)
diff --git a/libcxx/test/std/algorithms/alg.nonmodifying/alg.all_of/all_of.pass.cpp b/libcxx/test/std/algorithms/alg.nonmodifying/alg.all_of/all_of.pass.cpp
index 0a5998105ef..3840350a03c 100644
--- a/libcxx/test/std/algorithms/alg.nonmodifying/alg.all_of/all_of.pass.cpp
+++ b/libcxx/test/std/algorithms/alg.nonmodifying/alg.all_of/all_of.pass.cpp
@@ -28,7 +28,7 @@ struct test1
};
#if TEST_STD_VER > 17
-TEST_CONSTEXPR int test_constexpr() {
+TEST_CONSTEXPR bool test_constexpr() {
int ia[] = {2, 4, 6, 8};
int ib[] = {2, 4, 5, 8};
return std::all_of(std::begin(ia), std::end(ia), test1())
diff --git a/libcxx/test/std/algorithms/alg.nonmodifying/alg.any_of/any_of.pass.cpp b/libcxx/test/std/algorithms/alg.nonmodifying/alg.any_of/any_of.pass.cpp
index d21a691e7b3..7c80f718f43 100644
--- a/libcxx/test/std/algorithms/alg.nonmodifying/alg.any_of/any_of.pass.cpp
+++ b/libcxx/test/std/algorithms/alg.nonmodifying/alg.any_of/any_of.pass.cpp
@@ -28,7 +28,7 @@ struct test1
};
#if TEST_STD_VER > 17
-TEST_CONSTEXPR int test_constexpr() {
+TEST_CONSTEXPR bool test_constexpr() {
int ia[] = {2, 4, 6, 8};
int ib[] = {1, 3, 5, 7};
return std::any_of(std::begin(ia), std::end(ia), test1())
diff --git a/libcxx/test/std/algorithms/alg.nonmodifying/alg.is_permutation/is_permutation.pass.cpp b/libcxx/test/std/algorithms/alg.nonmodifying/alg.is_permutation/is_permutation.pass.cpp
index cde76d5ca06..52ad7befc64 100644
--- a/libcxx/test/std/algorithms/alg.nonmodifying/alg.is_permutation/is_permutation.pass.cpp
+++ b/libcxx/test/std/algorithms/alg.nonmodifying/alg.is_permutation/is_permutation.pass.cpp
@@ -22,7 +22,7 @@
#include "test_macros.h"
#if TEST_STD_VER > 17
-TEST_CONSTEXPR int test_constexpr() {
+TEST_CONSTEXPR bool test_constexpr() {
int ia[] = {0, 0, 0};
int ib[] = {1, 1, 0};
int ic[] = {1, 0, 1};
diff --git a/libcxx/test/std/algorithms/alg.nonmodifying/alg.is_permutation/is_permutation_pred.pass.cpp b/libcxx/test/std/algorithms/alg.nonmodifying/alg.is_permutation/is_permutation_pred.pass.cpp
index 13129289629..1d7db8cbc74 100644
--- a/libcxx/test/std/algorithms/alg.nonmodifying/alg.is_permutation/is_permutation_pred.pass.cpp
+++ b/libcxx/test/std/algorithms/alg.nonmodifying/alg.is_permutation/is_permutation_pred.pass.cpp
@@ -29,7 +29,7 @@ bool counting_equals ( const T &a, const T &b ) {
}
#if TEST_STD_VER > 17
-TEST_CONSTEXPR int test_constexpr() {
+TEST_CONSTEXPR bool test_constexpr() {
int ia[] = {0, 0, 0};
int ib[] = {1, 1, 0};
int ic[] = {1, 0, 1};
diff --git a/libcxx/test/std/algorithms/alg.nonmodifying/alg.none_of/none_of.pass.cpp b/libcxx/test/std/algorithms/alg.nonmodifying/alg.none_of/none_of.pass.cpp
index f3b8e778168..356c2fbb8a7 100644
--- a/libcxx/test/std/algorithms/alg.nonmodifying/alg.none_of/none_of.pass.cpp
+++ b/libcxx/test/std/algorithms/alg.nonmodifying/alg.none_of/none_of.pass.cpp
@@ -28,7 +28,7 @@ struct test1
};
#if TEST_STD_VER > 17
-TEST_CONSTEXPR int test_constexpr() {
+TEST_CONSTEXPR bool test_constexpr() {
int ia[] = {1, 3, 6, 7};
int ib[] = {1, 3, 5, 7};
return !std::none_of(std::begin(ia), std::end(ia), test1())
diff --git a/libcxx/test/std/algorithms/alg.sorting/alg.heap.operations/is.heap/is_heap.pass.cpp b/libcxx/test/std/algorithms/alg.sorting/alg.heap.operations/is.heap/is_heap.pass.cpp
index 8df07dad1a5..c3d6fd919cb 100644
--- a/libcxx/test/std/algorithms/alg.sorting/alg.heap.operations/is.heap/is_heap.pass.cpp
+++ b/libcxx/test/std/algorithms/alg.sorting/alg.heap.operations/is.heap/is_heap.pass.cpp
@@ -20,7 +20,7 @@
#include "test_macros.h"
#if TEST_STD_VER > 17
-TEST_CONSTEXPR int test_constexpr() {
+TEST_CONSTEXPR bool test_constexpr() {
int ia[] = {1, 1, 1, 1, 0, 1, 1};
int ib[] = {0, 0, 1, 0, 0, 0, 0};
return std::is_heap(std::begin(ia), std::end(ia))
diff --git a/libcxx/test/std/algorithms/alg.sorting/alg.heap.operations/is.heap/is_heap_comp.pass.cpp b/libcxx/test/std/algorithms/alg.sorting/alg.heap.operations/is.heap/is_heap_comp.pass.cpp
index 80b5cd36f20..3f290bb2944 100644
--- a/libcxx/test/std/algorithms/alg.sorting/alg.heap.operations/is.heap/is_heap_comp.pass.cpp
+++ b/libcxx/test/std/algorithms/alg.sorting/alg.heap.operations/is.heap/is_heap_comp.pass.cpp
@@ -21,7 +21,7 @@
#include "test_macros.h"
#if TEST_STD_VER > 17
-TEST_CONSTEXPR int test_constexpr() {
+TEST_CONSTEXPR bool test_constexpr() {
int ia[] = {0, 0, 1, 1, 1};
int ib[] = {1, 0, 4, 1, 0};
return std::is_heap(std::begin(ia), std::end(ia), std::greater<int>())
diff --git a/libcxx/test/std/algorithms/alg.sorting/alg.heap.operations/is.heap/is_heap_until.pass.cpp b/libcxx/test/std/algorithms/alg.sorting/alg.heap.operations/is.heap/is_heap_until.pass.cpp
index 5616401da79..96369eb6053 100644
--- a/libcxx/test/std/algorithms/alg.sorting/alg.heap.operations/is.heap/is_heap_until.pass.cpp
+++ b/libcxx/test/std/algorithms/alg.sorting/alg.heap.operations/is.heap/is_heap_until.pass.cpp
@@ -20,7 +20,7 @@
#include "test_macros.h"
#if TEST_STD_VER > 17
-TEST_CONSTEXPR int test_constexpr() {
+TEST_CONSTEXPR bool test_constexpr() {
int ia[] = {0, 0, 0, 0, 1, 0};
int ib[] = {0, 0, 0, 1, 1, 1};
return (std::is_heap_until(std::begin(ia), std::end(ia)) == ia+4)
diff --git a/libcxx/test/std/algorithms/alg.sorting/alg.heap.operations/is.heap/is_heap_until_comp.pass.cpp b/libcxx/test/std/algorithms/alg.sorting/alg.heap.operations/is.heap/is_heap_until_comp.pass.cpp
index dba4a0c7ffe..edd27b0d790 100644
--- a/libcxx/test/std/algorithms/alg.sorting/alg.heap.operations/is.heap/is_heap_until_comp.pass.cpp
+++ b/libcxx/test/std/algorithms/alg.sorting/alg.heap.operations/is.heap/is_heap_until_comp.pass.cpp
@@ -21,7 +21,7 @@
#include "test_macros.h"
#if TEST_STD_VER > 17
-TEST_CONSTEXPR int test_constexpr() {
+TEST_CONSTEXPR bool test_constexpr() {
int ia[] = {1, 0, 0, 0};
int ib[] = {0, 1, 1, 0};
return (std::is_heap_until(std::begin(ia), std::end(ia), std::greater<int>()) == ia+1)
diff --git a/libcxx/test/std/algorithms/alg.sorting/alg.sort/is.sorted/is_sorted.pass.cpp b/libcxx/test/std/algorithms/alg.sorting/alg.sort/is.sorted/is_sorted.pass.cpp
index e50aae8ef18..3652c089cfb 100644
--- a/libcxx/test/std/algorithms/alg.sorting/alg.sort/is.sorted/is_sorted.pass.cpp
+++ b/libcxx/test/std/algorithms/alg.sorting/alg.sort/is.sorted/is_sorted.pass.cpp
@@ -20,7 +20,7 @@
#include "test_iterators.h"
#if TEST_STD_VER > 17
-TEST_CONSTEXPR int test_constexpr() {
+TEST_CONSTEXPR bool test_constexpr() {
int ia[] = {0, 0, 1, 1};
int ib[] = {1, 1, 0, 0};
return std::is_sorted(std::begin(ia), std::end(ia))
diff --git a/libcxx/test/std/algorithms/alg.sorting/alg.sort/is.sorted/is_sorted_comp.pass.cpp b/libcxx/test/std/algorithms/alg.sorting/alg.sort/is.sorted/is_sorted_comp.pass.cpp
index a1562d7c1ed..228aacac622 100644
--- a/libcxx/test/std/algorithms/alg.sorting/alg.sort/is.sorted/is_sorted_comp.pass.cpp
+++ b/libcxx/test/std/algorithms/alg.sorting/alg.sort/is.sorted/is_sorted_comp.pass.cpp
@@ -21,7 +21,7 @@
#include "test_iterators.h"
#if TEST_STD_VER > 17
-TEST_CONSTEXPR int test_constexpr() {
+TEST_CONSTEXPR bool test_constexpr() {
int ia[] = {1, 1, 0, 0};
int ib[] = {0, 0, 1, 1};
return std::is_sorted(std::begin(ia), std::end(ia), std::greater<int>())
diff --git a/libcxx/test/std/algorithms/alg.sorting/alg.sort/is.sorted/is_sorted_until.pass.cpp b/libcxx/test/std/algorithms/alg.sorting/alg.sort/is.sorted/is_sorted_until.pass.cpp
index 5d30532c825..b2ed76f519a 100644
--- a/libcxx/test/std/algorithms/alg.sorting/alg.sort/is.sorted/is_sorted_until.pass.cpp
+++ b/libcxx/test/std/algorithms/alg.sorting/alg.sort/is.sorted/is_sorted_until.pass.cpp
@@ -20,7 +20,7 @@
#include "test_iterators.h"
#if TEST_STD_VER > 17
-TEST_CONSTEXPR int test_constexpr() {
+TEST_CONSTEXPR bool test_constexpr() {
int ia[] = {0, 1, 0};
int ib[] = {0, 1, 1};
return (std::is_sorted_until(std::begin(ia), std::end(ia)) == ia+2)
diff --git a/libcxx/test/std/algorithms/alg.sorting/alg.sort/is.sorted/is_sorted_until_comp.pass.cpp b/libcxx/test/std/algorithms/alg.sorting/alg.sort/is.sorted/is_sorted_until_comp.pass.cpp
index 37b5e44da35..76724bc397e 100644
--- a/libcxx/test/std/algorithms/alg.sorting/alg.sort/is.sorted/is_sorted_until_comp.pass.cpp
+++ b/libcxx/test/std/algorithms/alg.sorting/alg.sort/is.sorted/is_sorted_until_comp.pass.cpp
@@ -21,7 +21,7 @@
#include "test_iterators.h"
#if TEST_STD_VER > 17
-TEST_CONSTEXPR int test_constexpr() {
+TEST_CONSTEXPR bool test_constexpr() {
int ia[] = {1, 0, 1};
int ib[] = {1, 1, 0};
return (std::is_sorted_until(std::begin(ia), std::end(ia), std::greater<int>()) == ia+2)
OpenPOWER on IntegriCloud