Very Strange Constructor behaviour
<p>I have the following situation</p>

<pre><code>Class A
{

public:
   A(/* x number of arguments */);

};


A::A(/*.....*/)
{
    std::set&lt;__int64&gt;  tmpSet;
    tmpSet.insert( /*&lt;num&gt;*/ );     // repeat statement for some  30 K or more 
    tmpSet.insert( /*&lt;num&gt;*/ ); 

 //-----repeat statement for some  30K or more times

}

main()
{
   A obj(/*arguments */);    // Run time Error : Stack over flow 


}
</code></pre>

<p>What I observed , when I reduced the number of inserts in the constructor the Error disappeared  .  I wonder how did the compiler knew at run time to calculate the size of the container before the object was created .</p>
