Possible Duplicate:
Default value to a parameter while passing by reference in C++
Is it possible to do something like this:
// definition
bool MyFun(int nMyInt, char* szMyChar, double& nMyReferencedDouble = 0.0);
Then the function can be called either like this:
MyFun(nMyInt, szMyChar, nMyReferencedDouble);
or like this:
MyFun(nMyInt, szMyChar);
My compiler (VS 98) complains. Is there a way to do this?