summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorEric Fiselier <eric@efcs.ca>2015-07-19 00:38:37 +0000
committerEric Fiselier <eric@efcs.ca>2015-07-19 00:38:37 +0000
commit6af41ab8c201de73cccd1760281ed862ae730add (patch)
tree604c095f82b05562a615aa9016521837d37c6689
parent18dbed95969596840835876627ecd102b4fc51e1 (diff)
downloadexternal_libcxx-6af41ab8c201de73cccd1760281ed862ae730add.tar.gz
external_libcxx-6af41ab8c201de73cccd1760281ed862ae730add.tar.bz2
external_libcxx-6af41ab8c201de73cccd1760281ed862ae730add.zip
Fix warnings in forwardlist
git-svn-id: https://llvm.org/svn/llvm-project/libcxx/trunk@242633 91177308-0d34-0410-b5e6-96231b3b80d8
-rw-r--r--test/std/containers/sequences/forwardlist/forwardlist.ops/splice_after_one.pass.cpp4
-rw-r--r--test/std/containers/sequences/forwardlist/forwardlist.spec/equal.pass.cpp4
-rw-r--r--test/std/containers/sequences/forwardlist/forwardlist.spec/relational.pass.cpp4
3 files changed, 6 insertions, 6 deletions
diff --git a/test/std/containers/sequences/forwardlist/forwardlist.ops/splice_after_one.pass.cpp b/test/std/containers/sequences/forwardlist/forwardlist.ops/splice_after_one.pass.cpp
index 296ffcd69..349a3872d 100644
--- a/test/std/containers/sequences/forwardlist/forwardlist.ops/splice_after_one.pass.cpp
+++ b/test/std/containers/sequences/forwardlist/forwardlist.ops/splice_after_one.pass.cpp
@@ -15,6 +15,7 @@
#include <cassert>
#include <iterator>
+#include "test_macros.h"
#include "min_allocator.h"
typedef int T;
@@ -44,7 +45,6 @@ tests(const C& c, int p, int f)
{
typename C::const_iterator i = c.begin();
int n = 0;
- int d = 1;
if (p == f || p == f+1)
{
for (n = 0; n < size_t1; ++n, ++i)
@@ -106,7 +106,7 @@ int main()
}
}
}
-#if __cplusplus >= 201103L
+#if TEST_STD_VER >= 11
{
// splicing different containers
typedef std::forward_list<T, min_allocator<T>> C;
diff --git a/test/std/containers/sequences/forwardlist/forwardlist.spec/equal.pass.cpp b/test/std/containers/sequences/forwardlist/forwardlist.spec/equal.pass.cpp
index ca673b583..9f01fed66 100644
--- a/test/std/containers/sequences/forwardlist/forwardlist.spec/equal.pass.cpp
+++ b/test/std/containers/sequences/forwardlist/forwardlist.spec/equal.pass.cpp
@@ -22,12 +22,12 @@
#include <algorithm>
#include <cassert>
+#include "test_macros.h"
#include "min_allocator.h"
template <class C>
void test(int N, int M)
{
- typedef typename C::value_type T;
C c1;
for (int i = 0; i < N; ++i)
c1.push_front(i);
@@ -52,7 +52,7 @@ int main()
for (int i = 0; i < 10; ++i)
for (int j = 0; j < 10; ++j)
test<std::forward_list<int> >(i, j);
-#if __cplusplus >= 201103L
+#if TEST_STD_VER >= 11
for (int i = 0; i < 10; ++i)
for (int j = 0; j < 10; ++j)
test<std::forward_list<int, min_allocator<int>> >(i, j);
diff --git a/test/std/containers/sequences/forwardlist/forwardlist.spec/relational.pass.cpp b/test/std/containers/sequences/forwardlist/forwardlist.spec/relational.pass.cpp
index 42e245d00..e65e064ff 100644
--- a/test/std/containers/sequences/forwardlist/forwardlist.spec/relational.pass.cpp
+++ b/test/std/containers/sequences/forwardlist/forwardlist.spec/relational.pass.cpp
@@ -30,12 +30,12 @@
#include <algorithm>
#include <cassert>
+#include "test_macros.h"
#include "min_allocator.h"
template <class C>
void test(int N, int M)
{
- typedef typename C::value_type T;
C c1;
for (int i = 0; i < N; ++i)
c1.push_front(i);
@@ -57,7 +57,7 @@ int main()
for (int i = 0; i < 10; ++i)
for (int j = 0; j < 10; ++j)
test<std::forward_list<int> >(i, j);
-#if __cplusplus >= 201103L
+#if TEST_STD_VER >= 11
for (int i = 0; i < 10; ++i)
for (int j = 0; j < 10; ++j)
test<std::forward_list<int, min_allocator<int>> >(i, j);