M
Martin Vorbrodt
SO i have a class:
template<typename T>
class Vector {
public:
static const Vector<T> UNIT_X();
};
template<typename T>
static const Vector<T> UNIT_X() {
static const Vector<T> unit_x(1,0,0);
return unit_x;
}
GCC 3.4 tell me i can't declare UNIT_X member function to have static
linkage.
How do i go about having such static function.
I want to be able to do Vector<int>::UNIX_X();
Please help.
Martin
template<typename T>
class Vector {
public:
static const Vector<T> UNIT_X();
};
template<typename T>
static const Vector<T> UNIT_X() {
static const Vector<T> unit_x(1,0,0);
return unit_x;
}
GCC 3.4 tell me i can't declare UNIT_X member function to have static
linkage.
How do i go about having such static function.
I want to be able to do Vector<int>::UNIX_X();
Please help.
Martin