I have a problem with template specialization which boils down to the following snippet:
#include
struct Class
{
template
Well, I'd say it is most likely legal c++ code as I compile and run it fine with:
g++ -ansi -gstabs+ -Wall -o fun fun.cpp
g++ -std=c++98 -gstabs+ -Wall -o fun fun.cpp
g++ -std=c++0x -gstabs+ -Wall -o fun fun.cpp
I'm suspecting it's the same bug mentioned here: http://msdn.microsoft.com/en-us/library/cx7k7hcf(v=vs.80).aspx
Particularly:
The explicit specialization of a member function outside the class is not valid if the function has already been explicitly specialized via a template class specialization. (C2910).
from http://msdn.microsoft.com/en-us/library/h62s5036(v=vs.80).aspx