Original Post
struct v3df { float x; float y; float z; };
v3df operator*( v3df &a, float f ) {
v3df c = { a.x*f, a.y*f, a.z*f };
return( c );
}
void func( ) {
v3df move = { 3,4,5 };
float friction = 0.9;
v3df move_update = move * friction;
}The app runs correctly despite this error being produced:
error C2296: '*' : illegal, left operand has type 'v3df *'Is there a way to make my overloaded operator not get caught by the normal operator error checking?