Title
Access in base-specifiers of friend and nested classes
Status
cd1
Section
11.8.4 [class.friend]
Submitter
Andreas Hommel

Created on 2005-01-25.00:00:00 last changed 196 months ago

Messages

Date: 2006-10-15.00:00:00

[Voted into WP at the October, 2006 meeting.]

Date: 2005-10-15.00:00:00

Proposed resolution (October, 2005):

This issue is resolved by the resolution of issue 372.

Date: 2005-04-15.00:00:00

Notes from the April, 2005 meeting:

In discussing issue 372, the CWG decided that access in the base-specifiers of a class should be the same as for its members, and that resolution will apply to friend declarations, as well.

Date: 2005-01-25.00:00:00

I don't know the reason for this distinction, but it seems to be surprising that Base::A is legal and D is illegal in this example:

    class D;
    class Base
    {
        class A;
        class B;
        friend class D;
    };
    class Base::B
    {
    };
    class Base::A : public Base::B  // OK because of issue 45
    {
    };
    class D : public Base::B        // illegal because of 11.4p4
    {
    };

Shouldn't this be consistent (either way)?

History
Date User Action Args
2008-10-05 00:00:00adminsetstatus: wp -> cd1
2007-05-06 00:00:00adminsetstatus: dr -> wp
2006-11-05 00:00:00adminsetmessages: + msg1440
2006-11-05 00:00:00adminsetstatus: ready -> dr
2006-04-22 00:00:00adminsetstatus: review -> ready
2005-10-22 00:00:00adminsetmessages: + msg1246
2005-10-22 00:00:00adminsetstatus: drafting -> review
2005-05-01 00:00:00adminsetmessages: + msg1161
2005-05-01 00:00:00adminsetstatus: open -> drafting
2005-01-25 00:00:00admincreate