[prev in list] [next in list] [prev in thread] [next in thread]
List: hpux-cxx-dev
Subject: Re: CXX-DEV: accessing protected structures with aCC
From: Dennis Handly <dhandly () hpcllmx ! cup ! hp ! com>
Date: 1998-07-28 7:43:06
[Download RAW message or body]
Error 182: struct ProtStruct2 cannot access
protected member struct ProtStruct1.
ProtStruct1* p;
^^^^^^^^^^^
class foo {
protected:
struct ProtStruct1 { int ps1, ps2; };
struct ProtStruct2 { ProtStruct1* p; };
};
>Is this a bug or a feature?
This is the ANSI C++ Standard.
Only derived classes and non-nested class members get special access to
protected members. Not nested classes.
_________________________________________________________________
To leave this mailing list, send mail to majordomo@cxx.cup.hp.com
with the message UNSUBSCRIBE cxx-dev
To reply to the list, send mail to cxx-dev@cxx.cup.hp.com
_________________________________________________________________
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic