From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 32661 invoked by alias); 6 Oct 2004 19:58:51 -0000 Mailing-List: contact gcc-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-owner@gcc.gnu.org Received: (qmail 32652 invoked from network); 6 Oct 2004 19:58:50 -0000 Received: from unknown (HELO palrel11.hp.com) (156.153.255.246) by sourceware.org with SMTP; 6 Oct 2004 19:58:50 -0000 Received: from smtp2.ptp.hp.com (smtp2.ptp.hp.com [15.1.28.240]) by palrel11.hp.com (Postfix) with ESMTP id 3CC992D9 for ; Wed, 6 Oct 2004 12:58:50 -0700 (PDT) Received: from hpsje.cup.hp.com (hpsje.cup.hp.com [15.244.96.221]) by smtp2.ptp.hp.com (Postfix) with ESMTP id 1C10AC637 for ; Wed, 6 Oct 2004 12:58:10 +0000 (UTC) Received: (from sje@localhost) by hpsje.cup.hp.com (8.9.3 (PHNE_24419+JAGae58098)/8.7.3 TIS Messaging 5.0) id MAA15669 for gcc@gcc.gnu.org; Wed, 6 Oct 2004 12:58:50 -0700 (PDT) Date: Wed, 06 Oct 2004 20:19:00 -0000 From: Steve Ellcey Message-Id: <200410061958.MAA15669@hpsje.cup.hp.com> To: gcc@gcc.gnu.org Subject: legal C++ ? Reply-To: sje@cup.hp.com Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-SW-Source: 2004-10/txt/msg00229.txt.bz2 The following program compiles with the latest g++ but not with a couple of other C++ compilers I tried. It seems like g++ should not be accepting this, is this a bug? Should I submit a bug report against g++? class A { public: void l(); friend class C; }; class B : protected A { }; class C { void v(B * g) { g->l(); } }; Steve Ellcey sje@cup.hp.com