This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug c++/11952] New: REGRESSION: friend declaration handled function call concerning access.


PLEASE REPLY TO gcc-bugzilla@gcc.gnu.org ONLY, *NOT* gcc-bugs@gcc.gnu.org.

http://gcc.gnu.org/bugzilla/show_bug.cgi?id=11952

           Summary: REGRESSION: friend declaration handled function call
                    concerning access.
           Product: gcc
           Version: 3.4
            Status: UNCONFIRMED
          Severity: critical
          Priority: P2
         Component: c++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: carlo at alinoe dot com
                CC: gcc-bugs at gcc dot gnu dot org

Until recently, the following did always compile:

class A {
  void f();
};

struct B {
  friend void A::f();
};

But now I get:

>g++-cvs-3.4 -v -c troep.cc
Reading specs from /usr/local/gcc-cvs-3.4/lib/gcc/i686-pc-linux-gnu/3.4/specs
Configured with: /usr/src/gcc/gcc-cvs-3.4/configure
--prefix=/usr/local/gcc-cvs-3.4 --enable-shared --with-gnu-as --with-gnu-ld
--enable-languages=c++ --enable-debug --enable-threads
Thread model: posix
gcc version 3.4 20030816 (experimental)
 /usr/local/gcc-cvs-3.4/libexec/gcc/i686-pc-linux-gnu/3.4/cc1plus -quiet -v
-D_GNU_SOURCE troep.cc -quiet -dumpbase troep.cc -mtune=pentiumpro -auxbase
troep -version -o /tmp/ccKe2M6E.s
ignoring nonexistent directory
"/usr/local/gcc-cvs-3.4/lib/gcc/i686-pc-linux-gnu/3.4/../../../../i686-pc-linux-gnu/include"
#include "..." search starts here:
#include <...> search starts here:
 /usr/local/gcc-cvs-3.4/lib/gcc/i686-pc-linux-gnu/3.4/../../../../include/c++/3.4
 /usr/local/gcc-cvs-3.4/lib/gcc/i686-pc-linux-gnu/3.4/../../../../include/c++/3.4/i686-pc-linux-gnu
 /usr/local/gcc-cvs-3.4/lib/gcc/i686-pc-linux-gnu/3.4/../../../../include/c++/3.4/backward
 /usr/local/include
 /usr/local/gcc-cvs-3.4/include
 /usr/local/gcc-cvs-3.4/lib/gcc/i686-pc-linux-gnu/3.4/include
 /usr/include
End of search list.
GNU C++ version 3.4 20030816 (experimental) (i686-pc-linux-gnu)
        compiled by GNU C version 3.4 20030816 (experimental).
GGC heuristics: --param ggc-min-expand=90 --param ggc-min-heapsize=112969
troep.cc:2: error: `void A::f()' is private
troep.cc:6: error: within this context


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]