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++/12622] New: Incoherent handling of member function template instansiations using template arguments


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

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

           Summary: Incoherent handling of member function template
                    instansiations using template arguments
           Product: gcc
           Version: 3.3.1
            Status: UNCONFIRMED
          Severity: minor
          Priority: P3
         Component: c++
        AssignedTo: unassigned at gcc dot gnu dot org
        ReportedBy: dfg at decode dot is
                CC: gcc-bugs at gcc dot gnu dot org

I get a parse error in B::i() in the following code, which is inconsistent with 
not getting a parse error in B::g().

class A {
public:
  template<class T>
  void f() {}
};

class B {
public:
  void g() {
    A a;
    a.f<double>();
  }
  template<class T>
  void h() {
    A a;
    a.template f<double>();
  }
  template<class T>
  void i() {
    A a;
    a.f<double>();
  }
};


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