|
-
May 1st, 2003, 05:43 AM
#1
problem with operator overloading!
i wanted to do this :
class vector3d {
private :
int x,y,z;
public :
int operator==(vector3d,vector3d);
friend int operator==(vector3d,float);
friend int operator==(float,vector3d);
};
after this declareration i have made the 3 functions,
but when i try to do :
vector3d v1,v2;
float f1=10;
cout << f1==v2;
i get an error!
why?
thnaks in advance
peleg
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|