[Bug c++/12050] New: [3.4 regression] typedef'ed name not accepted as friend

benko at sztaki dot hu gcc-bugzilla@gcc.gnu.org
Mon Aug 25 10:35:00 GMT 2003


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

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

           Summary: [3.4 regression] typedef'ed name not accepted as friend
           Product: gcc
           Version: 3.4
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: c++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: benko at sztaki dot hu
                CC: gcc-bugs at gcc dot gnu dot org

A week ago this code was accepted:

hydra:~/c/proba$ cat friend_typedef.cc
struct a {};

struct b
{
  typedef a t_t;

  friend class t_t;
};
hydra:~/c/proba$ g++-cvs friend_typedef.cc
friend_typedef.cc:7: error: using typedef-name `b::t_t' after `class'
zsh: exit 1     g++-cvs friend_typedef.cc
hydra:~/c/proba$ g++-cvs -v
Reading specs from /gml/shared/gcc-cvs/lib/gcc/i686-pc-linux-gnu/3.4/specs
Configured with: '../gcc/configure' '--prefix=/gml/shared/gcc-cvs
'--enable-languages=c++
Thread model: posix
gcc version 3.4 20030825 (experimental)
hydra:~/c/proba$



More information about the Gcc-bugs mailing list