Ok, i'm new to c++ and im looking at classes and overloading. I keep getting this error in vis studio:
error C2679: binary '<<' : no operator defined which takes a right-hand operand of type 'class CVector2' (or there is no acceptable conversion)
all my main does is this at the mo:
What does the error mean? and what am I doing wrong... if you need the class code, then just shout, tyCode:int main() { CVector2 Vector1(0,1), Vector2(1,0), result; result = Vector1 + Vector2; cout << "Result: " << result << endl; /* line with error */ return 0; }
Code tagged By Hammer



LinkBack URL
About LinkBacks



