How to set default parameter as class object in c++?
<p>I want to set my function with class object parameter set as default. But when I try to do that it fails in compilation.</p>

<pre><code>class base {
 // ...
};

int myfunc(int a, base b = NULL) {
    if (NULL = b) {
        // DO SOMETHING
    } else {
    // DO SOMETHING
    }
}
</code></pre>

<p>Here when i am trying to compile it, this gives me error that "Default Argument base b have int type"</p>
