This is the mail archive of the libstdc++@gcc.gnu.org mailing list for the libstdc++ project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH] Minor improvements to testsuite iterator utilities


On 29/10/19 17:15 +0000, Jonathan Wakely wrote:
	* testsuite/util/testsuite_iterators.h (BoundsContainer::size()): Add
	new member function.
	(WritableObject::operator=): Constrain with enable_if when available.
	(remove_cv): Use std::remove_if when available.
	(test_container::it(int)): Use size().
	(test_container::size()): Use BoundsContainer::size().

Tested powerpc64le-linux, committed to trunk.


@@ -182,10 +184,14 @@ namespace __gnu_test
    void operator,(const T&, const output_iterator_wrapper<U>&) = delete;
#endif

+#if __cplusplus >= 2011L

Oops! That should be 201103L.

Fixed by the attached patch, which I'll commit shortly.

commit 069df87c7e936d568a142df3930c700306546acc
Author: Jonathan Wakely <jwakely@redhat.com>
Date:   Wed Oct 30 14:32:53 2019 +0000

    Fix typo in preprocessor check
    
            * testsuite/util/testsuite_iterators.h: Fix typo in __cplusplus check.

diff --git a/libstdc++-v3/testsuite/util/testsuite_iterators.h b/libstdc++-v3/testsuite/util/testsuite_iterators.h
index 70c1f9b6689..c5ae5b123fe 100644
--- a/libstdc++-v3/testsuite/util/testsuite_iterators.h
+++ b/libstdc++-v3/testsuite/util/testsuite_iterators.h
@@ -184,7 +184,7 @@ namespace __gnu_test
     void operator,(const T&, const output_iterator_wrapper<U>&) = delete;
 #endif
 
-#if __cplusplus >= 2011L
+#if __cplusplus >= 201103L
   using std::remove_cv;
 #else
   template<typename T> struct remove_cv { typedef T type; };

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]