[cfe-commits] [libcxx] r104960 - /libcxx/trunk/test/iterators/predef.iterators/reverse.iterators/reverse.iterator/types.pass.cpp

Howard Hinnant hhinnant at apple.com
Fri May 28 09:53:29 PDT 2010


Author: hhinnant
Date: Fri May 28 11:53:29 2010
New Revision: 104960

URL: http://llvm.org/viewvc/llvm-project?rev=104960&view=rev
Log:
Corrected a test bug in reverse_iterator

Modified:
    libcxx/trunk/test/iterators/predef.iterators/reverse.iterators/reverse.iterator/types.pass.cpp

Modified: libcxx/trunk/test/iterators/predef.iterators/reverse.iterators/reverse.iterator/types.pass.cpp
URL: http://llvm.org/viewvc/llvm-project/libcxx/trunk/test/iterators/predef.iterators/reverse.iterators/reverse.iterator/types.pass.cpp?rev=104960&r1=104959&r2=104960&view=diff
==============================================================================
--- libcxx/trunk/test/iterators/predef.iterators/reverse.iterators/reverse.iterator/types.pass.cpp (original)
+++ libcxx/trunk/test/iterators/predef.iterators/reverse.iterators/reverse.iterator/types.pass.cpp Fri May 28 11:53:29 2010
@@ -18,11 +18,11 @@
 // protected: 
 //   Iter current; 
 // public: 
-//   typedef Iter iterator_type; 
-//   typedef Iter::value_type value_type; 
-//   typedef Iter::difference_type difference_type; 
-//   typedef Iter::reference reference; 
-//   typedef Iter::pointer pointer; 
+//   iterator<typename iterator_traits<Iterator>::iterator_category,
+//   typename iterator_traits<Iterator>::value_type,
+//   typename iterator_traits<Iterator>::difference_type,
+//   typename iterator_traits<Iterator>::pointer,
+//   typename iterator_traits<Iterator>::reference> {
 // };
 
 #include <iterator>
@@ -49,7 +49,7 @@
     static_assert((std::is_same<typename R::value_type, typename T::value_type>::value), "");
     static_assert((std::is_same<typename R::difference_type, typename T::difference_type>::value), "");
     static_assert((std::is_same<typename R::reference, typename T::reference>::value), "");
-    static_assert((std::is_same<typename R::pointer, It>::value), "");
+    static_assert((std::is_same<typename R::pointer, typename std::iterator_traits<It>::pointer>::value), "");
     static_assert((std::is_same<typename R::iterator_category, typename T::iterator_category>::value), "");
 }
 





More information about the cfe-commits mailing list