stl_iterator.h (__normal_iterator<>): Qualify dependent names with `typename'.
authorGabriel Dos Reis <gdr@merlin.codesourcery.com>
Tue, 26 Jun 2001 06:36:33 +0000 (06:36 +0000)
committerGabriel Dos Reis <gdr@gcc.gnu.org>
Tue, 26 Jun 2001 06:36:33 +0000 (06:36 +0000)
* include/bits/stl_iterator.h (__normal_iterator<>): Qualify
dependent names with `typename'.  Bring in various required
iterator_traits members.  Can't imagine why that used to work.

From-SVN: r43568

libstdc++-v3/ChangeLog
libstdc++-v3/include/bits/stl_iterator.h

index af4453e..5bd0669 100644 (file)
@@ -1,3 +1,9 @@
+2001-06-26  Gabriel Dos Reis  <gdr@merlin.codesourcery.com>
+
+       * include/bits/stl_iterator.h (__normal_iterator<>): Qualify
+       dependent names with `typename'.  Bring in various required
+       iterator_traits members.  Can't imagine why that used to work.
+
 2001-06-25  Phil Edwards  <pme@sources.redhat.com>
             Kurt Garloff <garloff@suse.de>
 
index 148cad6..7127a21 100644 (file)
@@ -443,18 +443,24 @@ private:
 // _Iterator parameter is the same.
 template<typename _Iterator, typename _Container>
 class __normal_iterator
-  : public iterator<iterator_traits<_Iterator>::iterator_category,
-                    iterator_traits<_Iterator>::value_type,
-                    iterator_traits<_Iterator>::difference_type,
-                    iterator_traits<_Iterator>::pointer,
-                    iterator_traits<_Iterator>::reference>
+  : public 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>
 {
-
+  typedef iterator_traits<_Iterator> _Traits;
+  
 protected:
   _Iterator _M_current;
 
 public:
   typedef __normal_iterator<_Iterator, _Container> normal_iterator_type;
+  typedef typename _Traits::iterator_category iterator_category;
+  typedef typename _Traits::value_type value_type;
+  typedef typename _Traits::difference_type difference_type;
+  typedef typename _Traits::pointer pointer;
+  typedef typename _Traits::reference reference;
 
   __normal_iterator() : _M_current(_Iterator()) { }