commit d97bb71f4e0cb7735e78ab879dae82886bdc6482
Author: Jonathan Wakely <jwakely@redhat.com>
Date: Wed Nov 23 15:08:17 2016 +0000
Replace unsupported effective-target with dg-options
* testsuite/24_iterators/reverse_iterator/71771.cc: Replace calls to
C++14 std::rbeing and std::rend. Use dg-options instead of
effective-target.
* testsuite/27_io/headers/cstdio/functions_neg.cc: Use dg-options
instead of effective-target.
* testsuite/experimental/numeric/77801.cc: Likewise.
@@ -15,7 +15,8 @@
// with this library; see the file COPYING3. If not see
// <http://www.gnu.org/licenses/>.
-// { dg-do compile { target c++11 } }
+// { dg-options "-std=gnu++11" }
+// { dg-do compile }
#include <iterator>
#include <testsuite_iterators.h>
@@ -39,5 +40,7 @@ test01()
int i[2];
__gnu_test::test_container<int, __gnu_test::bidirectional_iterator_wrapper>
c(i);
- diff2(std::rbegin(c), std::rend(c));
+ using reverse_iterator
+ = std::reverse_iterator<__gnu_test::bidirectional_iterator_wrapper<int>>;
+ diff2(reverse_iterator(c.end()), reverse_iterator(c.begin()));
}
@@ -1,4 +1,5 @@
-// { dg-do compile { target c++14 } }
+// { dg-options "-std=gnu++14" }
+// { dg-do compile }
// Copyright (C) 2007-2016 Free Software Foundation, Inc.
//
@@ -15,7 +15,8 @@
// with this library; see the file COPYING3. If not see
// <http://www.gnu.org/licenses/>.
-// { dg-do compile { target c++14 } }
+// { dg-options "-std=gnu++14" }
+// { dg-do compile }
#include <cstdlib>
#include <experimental/numeric>