Bug (typo?) in stl_deque.h

Carlo Wood carlo@node1500a.a2000.nl
Sun Dec 5 17:46:00 GMT 1999


Hi,

in g++-2.95.1, but also in the latest CVS version (19991205)
I found the following:

In stl/stl_deque.h, line 345 (CVS, date 19991205) reads:

  typedef _Deque_iterator<_Tp,const _Tp&,const _Tp&, __bufsiz> const_iterator;

This should be:

  typedef _Deque_iterator<_Tp,const _Tp&,const _Tp*, __bufsiz> const_iterator;
                                                  ^
                                                  |
                                           must be a pointer

Thanks,

Carlo Wood

PS Because the README file in that directory says

  Note that this is based on a pre-Draft Standard for C++.
  Things are likely to change.  For example, the header file names
  are very likely to change.  The Allocator interface will change.  Etc, etc.
  CYGNUS MAKES NO COMMITTMENT (yet) TO SUPPORT BACKWARD COMPATIBILITY FOR STL.

I assume you won't have a problem fixing this ;).  I suppose it will
break a lot of code that use deque<>::const_iterator in shared libraries.
(Until said libraries are recompiled).  Nevertheless you might want to
change it NOW, not later.


More information about the Gcc-bugs mailing list