Hi.
Simple question, is this valid C++:
class Foo
{
void Foo::doSomething();
};
The point of the question: is that repeated use of the class name and double colon before the method name valid inside the class declaration?
I'm having issues compiling code that does this using g++ 4.2.3. I would love to see a reference to something describing the syntax here, before digging in and changing the code. Or downgrading the compiler; this does build with g++ 3.3.6.
The error I'm getting is (roughly):
Foo.h:3: error: extra qualification ‘Foo::’ on member ‘doSomething’
I did Google, but couldn't come up with something. I don't have the standard, and even if I did it would probably take me quite a while to find anything authoritative. I'm no C++ language lawyer.