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++/17585] New: g++ generates errors on a legal code.


Compile the following code with g++ creates the following errors:

template <void (*p)(void)> struct S03 {};
class C03 {
public:
        static void f(void) {}
	void g(void) { S03<&f> s03; }
};

In member function `void C03::g()':
error: missing `>' to terminate the template argument list
error: template argument 1 is invalid
error: expected `;' before "f"

-- 
           Summary: g++ generates errors on a legal code.
           Product: gcc
           Version: 3.4.2
            Status: UNCONFIRMED
          Severity: normal
          Priority: P2
         Component: c++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: tal dot agmon at nsc dot com
                CC: gcc-bugs at gcc dot gnu dot org,paul dot woegerer at nsc
                    dot com
 GCC build triplet: i686-pc-linux-gnu
  GCC host triplet: i686-pc-linux-gnu
GCC target triplet: i686-pc-linux-gnu


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


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