This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC 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]

[Bug libstdc++/59170] pretty printers: end iterator invalid pointer


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=59170

--- Comment #5 from Jonathan Wakely <redi at gcc dot gnu.org> ---
I think it's simply wrong to automatically dereference iterators. GDB doesn't
do that when printing pointers, so why do the pretty printers do it for
iterators?

There are loads of cases where it does the wrong thing, not only for
past-the-end iterators but also for default-constructed ones that might contain
uninitialized pointers.

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