Difference between declaring a C++ object with/without braces
<blockquote>
  <p><strong>Possible Duplicate:</strong><br>
  <a href="http://stackoverflow.com/questions/4283576/constructor-invocation-mechanism">constructor invocation mechanism</a>  </p>
</blockquote>



<p>It took me long to figure this problem. So I was curious to know the difference between them. Below is the code snippet:</p>

<pre><code>struct Test
{
  Test () { cout&lt;&lt;" Test()\n"; }
 ~Test () { cout&lt;&lt;"~Test()\n"; }
};
int main()
{
  Test obj(); // Remove braces of 'obj' &amp; constructor/destructor are printed
}
</code></pre>

<p>Wanted to know that, why such behavior ? Is there any fundamental difference between declaring an object with/without empty braces (here we talk only about the cases of default constructor). Code is compiled one of the latest versions of Ubuntu/g++. Sorry if, it's a repeat question.</p>
