From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 17447 invoked by alias); 18 Nov 2003 00:13:28 -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 17438 invoked by uid 48); 18 Nov 2003 00:13:27 -0000 Date: Tue, 18 Nov 2003 00:13:00 -0000 From: "reichelt at gcc dot gnu dot org" To: gcc-bugs@gcc.gnu.org Message-ID: <20031118001326.13095.reichelt@gcc.gnu.org> Reply-To: gcc-bugzilla@gcc.gnu.org Subject: [Bug c++/13095] New: GCC accepts invalid using declaration X-Bugzilla-Reason: CC X-SW-Source: 2003-11/txt/msg01560.txt.bz2 List-Id: The following code in invalid IMHO, since using declarations shall refer to members of base classes (according to [7.3.3]/4), but B is not a base class. =========================================== template struct A { int i; }; template struct B : A { using B::i; int foo() { return i; } }; =========================================== However, gcc accepts the code since at least 2.95.x. -- Summary: GCC accepts invalid using declaration Product: gcc Version: unknown Status: UNCONFIRMED Keywords: accepts-invalid Severity: normal Priority: P2 Component: c++ AssignedTo: unassigned at gcc dot gnu dot org ReportedBy: reichelt at gcc dot gnu dot org CC: gcc-bugs at gcc dot gnu dot org http://gcc.gnu.org/bugzilla/show_bug.cgi?id=13095