title: Exception handled in constructor propagated back. How?
body: <p>I have a class whose constructor will throw an exception. I also have a catch block to handle that exception. But still, I see that the exception is propagated back to the caller even though it is handled. I know, there should be an exception to inform the caller that construction failed. But in this case how does it (re-throw) happen?</p>
  
  <pre><code>class Test
  {
      public:
          Test()
          try
          {
              std::cout &lt;&lt; "in child constructor" &lt;&lt; std::endl;
              throw 3.2;
          }
          catch(int &amp;e)
          {
              std::cout &lt;&lt; "in int catch: " &lt;&lt; e &lt;&lt; std::endl;
          }
          catch (double &amp;e)
          {
              std::cout &lt;&lt; "in double catch: " &lt;&lt; e &lt;&lt; std::endl;
          }
  };
  
  int main (void)
  {
      try
      {
          Test obj;
      }
      catch (int &amp;e)
      {
          std::cout &lt;&lt; "in main int catch: " &lt;&lt; e &lt;&lt; std::endl;
      }
      catch (double &amp;e)
      {
          std::cout &lt;&lt; "in main double catch: " &lt;&lt; e &lt;&lt; std::endl;
      }
  
      return 0;
  }
  </code></pre>
  
  <p>The output I got is</p>
  
  <pre><code>in child constructor
  in double catch: 3.2
  in main double catch: 3.2
  </code></pre>