From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 32659 invoked by alias); 11 Jan 2005 15:10:21 -0000 Mailing-List: contact gcc-bugs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-bugs-owner@gcc.gnu.org Received: (qmail 31953 invoked by uid 48); 11 Jan 2005 15:09:57 -0000 Date: Tue, 11 Jan 2005 15:10:00 -0000 From: "redi at gcc dot gnu dot org" To: gcc-bugs@gcc.gnu.org Message-ID: <20050111150953.19375.redi@gcc.gnu.org> Reply-To: gcc-bugzilla@gcc.gnu.org Subject: [Bug c++/19375] New: [3.4,4.0 regression] Access violation diagnostic given twice X-Bugzilla-Reason: CC X-SW-Source: 2005-01/txt/msg01342.txt.bz2 List-Id: I'm surprised I can't find this reported already, apologies if it has been. Given: class A { int i; }; class B : public A { int f() { return i; } }; GCC 3.4 and up prints the same diagnostic twice: access2.cc: In member function `int B::f()': access2.cc:1: error: `int A::i' is private access2.cc:3: error: within this context access2.cc:1: error: `int A::i' is private access2.cc:3: error: within this context GCC 2.95 - 3.3 only printed the diagnostic once: -- Summary: [3.4,4.0 regression] Access violation diagnostic given twice Product: gcc Version: 4.0.0 Status: UNCONFIRMED Keywords: diagnostic Severity: normal Priority: P2 Component: c++ AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: redi at gcc dot gnu dot org CC: gcc-bugs at gcc dot gnu dot org http://gcc.gnu.org/bugzilla/show_bug.cgi?id=19375