From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 13452 invoked by alias); 24 Aug 2014 10:35:34 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org Received: (qmail 13418 invoked by uid 48); 24 Aug 2014 10:35:29 -0000 From: "redi at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug libstdc++/62169] map iterators under _GLIBCXX_DEBUG diverge Date: Sun, 24 Aug 2014 10:35:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: libstdc++ X-Bugzilla-Version: 4.8.1 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: redi at gcc dot gnu.org X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2014-08/txt/msg01630.txt.bz2 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=3D62169 --- Comment #6 from Jonathan Wakely --- It's not an option IMHO. See http://www=E2=80=8B.stroustrup.com/SCARY.pdf f= or the benefits of the current design. Those benefits outweigh the advantage of ha= ving non-portable code diagnosed. Debug iterators can't be SCARY because they ha= ve a pointer back to their patent container so have to depend on the exact type. >>From gcc-bugs-return-459134-listarch-gcc-bugs=gcc.gnu.org@gcc.gnu.org Sun Aug 24 10:45:50 2014 Return-Path: Delivered-To: listarch-gcc-bugs@gcc.gnu.org Received: (qmail 17162 invoked by alias); 24 Aug 2014 10:45:49 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Id: List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org Delivered-To: mailing list gcc-bugs@gcc.gnu.org Received: (qmail 17111 invoked by uid 48); 24 Aug 2014 10:45:44 -0000 From: "redi at gcc dot gnu.org" To: gcc-bugs@gcc.gnu.org Subject: [Bug libstdc++/62169] map iterators under _GLIBCXX_DEBUG diverge Date: Sun, 24 Aug 2014 10:45:00 -0000 X-Bugzilla-Reason: CC X-Bugzilla-Type: changed X-Bugzilla-Watch-Reason: None X-Bugzilla-Product: gcc X-Bugzilla-Component: libstdc++ X-Bugzilla-Version: 4.8.1 X-Bugzilla-Keywords: X-Bugzilla-Severity: normal X-Bugzilla-Who: redi at gcc dot gnu.org X-Bugzilla-Status: UNCONFIRMED X-Bugzilla-Priority: P3 X-Bugzilla-Assigned-To: unassigned at gcc dot gnu.org X-Bugzilla-Target-Milestone: --- X-Bugzilla-Flags: X-Bugzilla-Changed-Fields: Message-ID: In-Reply-To: References: Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit X-Bugzilla-URL: http://gcc.gnu.org/bugzilla/ Auto-Submitted: auto-generated MIME-Version: 1.0 X-SW-Source: 2014-08/txt/msg01631.txt.bz2 Content-length: 394 https://gcc.gnu.org/bugzilla/show_bug.cgi?id=62169 --- Comment #7 from Jonathan Wakely --- (In reply to Jonathan Wakely from comment #6) > they have a pointer back to their patent container s/patent/parent/ As for solving the problem of switching containers, use a typedef for the container, or auto for the iterator. It doesn't need to be solved by the compiler.