N
none
In a template class I declare a function:
bool LoadFile(std::string filename, bool multi=false, bool endian=false);
and in the .cpp file I define it:
template< typename M, unsigned int Dimension>
bool
MyTestClass<M,Dimension>::LoadFile(std::string filename, bool multi = false, bool endian = false) {
....
}
But when I compile I get the error:
error: default argument given for parameter 3 of ‘bool MyTestClass<M,
Dimension>::LoadFile(std::string, bool, bool)’
It compiles fine on windows with visual studio 2008, but why does it not compile on linux?
bool LoadFile(std::string filename, bool multi=false, bool endian=false);
and in the .cpp file I define it:
template< typename M, unsigned int Dimension>
bool
MyTestClass<M,Dimension>::LoadFile(std::string filename, bool multi = false, bool endian = false) {
....
}
But when I compile I get the error:
error: default argument given for parameter 3 of ‘bool MyTestClass<M,
Dimension>::LoadFile(std::string, bool, bool)’
It compiles fine on windows with visual studio 2008, but why does it not compile on linux?