Strange GCC 'expected primary expression...' error

Posted by uj2 on Stack Overflow See other posts from Stack Overflow or by uj2
Published on 2010-06-16T17:34:03Z Indexed on 2010/06/16 17:42 UTC
Read the original article Hit count: 176

Filed under:
|
|
|
template <typename T>
struct A
{
    template <int I>
    void f();
};

template <typename T>
void F(A<T> &a)
{
    a.f<0>(); // expected primary-expression before ‘)’ token
}

int main()
{
    A<int> a;

    a.f<0>(); // This one is ok.
}

What it's all about?

© Stack Overflow or respective owner

Related posts about c++

Related posts about error