Avoid more than one or two default arguments. If you have that many options on a function or constructor, rethink your interface. Specifying large numbers of options via function arguments is confusing and not very extensible. Having large numbers of options is also confusing.
Default arguments constitute a form of inline declaration. Specifically, a declaration with default arguments like this
class TFoo { public: void Bar(int iItem = 10); };
class TFoo { public: void Bar(int iItem); inline void Bar() { Bar(10); }; };
Bar(int iItem)
with a value of 10 is compiled directly into client code. There's no way to go back and make it call Bar() instead.If you ever want the option of changing what happens, use overloading instead of default arguments.