Why isn't the copy constructor called here?
<pre><code>#include &lt;iostream&gt;
#include &lt;conio.h&gt;

using namespace std;

class Base
{
      int a;
public:
      Base(const Base &amp; b)
      {
                 cout&lt;&lt;"inside copy constructor"&lt;&lt;endl;
      }  
      Base (int b)
      {
           cout&lt;&lt;"inside parameterized constructor"&lt;&lt;endl;
       } 

};

int main()
{
   Base b1 = Base(5); //Why isn't the copy constructor called here
   getch();
   return 0;
}
</code></pre>

<p>Base(5) will return a temporary object. Why isn't the copy constructor called when we assign it to b1.
When I write :</p>

<pre><code> Base b2(5);
 Base b1 = b2;
</code></pre>

<p>copy constructor is called. Why not in the previous case?</p>
