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++/16393] New: Strange syntax errors in g++ 3.4.0


There are two issues I ran into.

I was trying to compile the Psion link protocol package (plptools 0.91).

1.) For some reason, a member variable with the typename "link" is not acceptable.
ie.

class link;

class socket
{
  link *abc;
};

fails. It worked when I changed the name (I chose link_t).



The other issue has to do with static variables of template classes. The
following construct failed for the initialisation of the static variable. It
complained that there were too few template parameter lists:

template < typename T >
class Enum
{
  class impl { /* stuff */ };

  static impl p_impl;
};

Enum< MyType >::impl Enum< MyType >::p_impl;
^----- THIS FAILS!!!!!!!

-- 
           Summary: Strange syntax errors in g++ 3.4.0
           Product: gcc
           Version: 3.4.0
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: c++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: wynand at realtimerodeo dot net
                CC: gcc-bugs at gcc dot gnu dot org
 GCC build triplet: i686-linux-3.4.0
  GCC host triplet: i686-linux-3.4.0
GCC target triplet: i686-linux-3.4.0


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


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