From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 7620 invoked by alias); 2 Jan 2003 04:56:00 -0000 Mailing-List: contact gcc-prs-help@gcc.gnu.org; run by ezmlm Precedence: bulk List-Archive: List-Post: List-Help: Sender: gcc-prs-owner@gcc.gnu.org Received: (qmail 7602 invoked by uid 71); 2 Jan 2003 04:56:00 -0000 Resent-Date: 2 Jan 2003 04:56:00 -0000 Resent-Message-ID: <20030102045600.7601.qmail@sources.redhat.com> Resent-From: gcc-gnats@gcc.gnu.org (GNATS Filer) Resent-Cc: gcc-prs@gcc.gnu.org, gcc-bugs@gcc.gnu.org Resent-Reply-To: gcc-gnats@gcc.gnu.org, hou_zhenyu@hotmail.com Received: (qmail 7524 invoked by uid 61); 2 Jan 2003 04:55:00 -0000 Message-Id: <20030102045500.7523.qmail@sources.redhat.com> Date: Thu, 02 Jan 2003 04:56:00 -0000 From: hou_zhenyu@hotmail.com Reply-To: hou_zhenyu@hotmail.com To: gcc-gnats@gcc.gnu.org X-Send-Pr-Version: gnatsweb-2.9.3 (1.1.1.1.2.31) Subject: c++/9122: qualified name forced to be used in non-public derived class X-SW-Source: 2003-01/txt/msg00105.txt.bz2 List-Id: >Number: 9122 >Category: c++ >Synopsis: qualified name forced to be used in non-public derived class >Confidential: no >Severity: serious >Priority: medium >Responsible: unassigned >State: open >Class: sw-bug >Submitter-Id: net >Arrival-Date: Wed Jan 01 20:56:00 PST 2003 >Closed-Date: >Last-Modified: >Originator: hou_zhenyu@hotmail.com >Release: unknown-1.0 >Organization: >Environment: Win2k + mingw2.0(gcc3.2, and rc2 of gcc3.2.1); Redhad Linux 8.0 + gcc3.2 >Description: If a class inhereit from another class which further non-publicly inherit yet another third class. Any member or parameters that use not full qualified name of the third class will fail to compile. "`class XXX' is inaccessible" in which XXX is the name of the third class. gcc 2.95-3 does not has this problem. >How-To-Repeat: // test.cpp, compile with "g++ -c test.cpp" class A {}; class B : A {}; class C : public B { public: A* p; // compiler report : `class A' is inaccessible }; >Fix: // test.cpp class A {}; class B : A {}; class C : public B { public: ::A* p; // full qualified, ok }; >Release-Note: >Audit-Trail: >Unformatted: