This is the mail archive of the
gcc-bugs@gcc.gnu.org
mailing list for the GCC project.
stl_iterator.h: class iterator ?
- To: egcs-bugs at cygnus dot com
- Subject: stl_iterator.h: class iterator ?
- From: Jens Maurer <jmaurer at menuett dot rhein-main dot de>
- Date: Wed, 20 Jan 1999 22:18:17 +0100
Hi,
while implementing my own iterators, I noticed the
following code in stl_iterator.h (included from <iterator>)
(libstdc++ from egcs-1.1.1 release)
#ifdef __STL_USE_NAMESPACES
template <class Category, class T, class Distance = ptrdiff_t,
class Pointer = T*, class Reference = T&>
struct iterator {
typedef Category iterator_category;
typedef T value_type;
typedef Distance difference_type;
typedef Pointer pointer;
typedef Reference reference;
};
#endif /* __STL_USE_NAMESPACES */
I think the #ifdef / #endif around this class definition
is bogus and should be removed. I did that locally and
no evident damage has emerged so far.
Jens Maurer.