Fix failing C++17 test

* testsuite/24_iterators/range_access_cpp17.cc: Fix order of dg-do
	and dg-options directives. Fix invalid test.

From-SVN: r253019
This commit is contained in:
Jonathan Wakely 2017-09-20 17:34:53 +01:00 committed by Jonathan Wakely
parent 95ed529d34
commit e18f68c715
2 changed files with 5 additions and 2 deletions

View File

@ -1,5 +1,8 @@
2017-09-20 Jonathan Wakely <jwakely@redhat.com>
* testsuite/24_iterators/range_access_cpp17.cc: Fix order of dg-do
and dg-options directives. Fix invalid test.
PR libstdc++/81469
* libsupc++/exception (uncaught_exception): Deprecate for C++17.
* testsuite/18_support/exception_ptr/62258.cc: Add -Wno-deprecated.

View File

@ -1,5 +1,5 @@
// { dg-do compile { target c++17 } }
// { dg-options "-std=gnu++17" }
// { dg-do compile { target c++17 } }
// Copyright (C) 2017 Free Software Foundation, Inc.
//
@ -47,7 +47,7 @@ void
test03()
{
using std::reverse_iterator;
static std::initializer_list<int> il{1};
static constexpr std::initializer_list<int> il{1};
static_assert(std::cbegin(il) == il.begin());
static_assert(std::cend(il) == il.end());
static_assert(std::rbegin(il) == reverse_iterator<const int*>(il.end()));