Possible Duplicate:
Operator Overloading in C++ as int + obj
I override the * operator as following:
Point Point::operator *(float scale){
Point point(this->x*scale, this->y*scale);
return point;
}
How can I fix this:
Point p1 (5.0, 10.0);
Point p2 = p1*4; //works fine
Point p3 = 4*p1 //error: no match for 'operator*'