This is the mail archive of the
gcc@gcc.gnu.org
mailing list for the GCC project.
Re: GCC 3.4.3 and fiend decleration.
- From: Andrew Pinski <pinskia at physics dot uc dot edu>
- To: ggrabler at gmail dot com
- Cc: gcc at gcc dot gnu dot org
- Date: Mon, 27 Dec 2004 09:04:59 -0500
- Subject: Re: GCC 3.4.3 and fiend decleration.
- References: <200412271440.12249.ggrabler@gmail.com>
On Dec 27, 2004, at 9:40 AM, Georg Grabler wrote:
Hello everybody.
First of all i'm sorry to post to this list, but it seems as if it was
the
only list read by some people.
I've a problem with a code as follows:
class a
{
protected:
virtual int f() const;
};
class b
{
friend int a::f() const; // error - a::f() is protected and
inaccessable
};
It worked on prior versions of GCC (according to people in my
company), and
i've found several postings on the web about this topic.
What i'd like to know is:
Will this be the same for future versions of GCC? What else could i
use for
this?
I've had a similar piece of code out of Stroustrups c++ "bible"...
Does not matter, this is invalid C++ (the standard which is the bible
really).
Thanks,
Andrew Pinski