title: Order of subobject destruction when an exception is thrown from the constructor
body: <p>This question is inspired by <a href="https://stackoverflow.com/questions/13067765/using-an-object-after-its-destructor-is-called">Using an object after it's destructor is called</a></p>
  
  <p>Let's consider the following code</p>
  
  <pre><code>class B 
    {
    public:
      B() { cout &lt;&lt; "Constructor B() " &lt;&lt; endl; }
      ~B() { cout &lt;&lt; "Destructor ~B() " &lt;&lt; endl; }
    };
  
  class A {
  public:
    B ob;
    A()
        try
        { 
        throw 4;
        }
      catch(...)
        {
        cout &lt;&lt; "Catch in A()\n";
        }
  
    A(int)
      {
      try
        {
        throw 4;
        }
      catch(...)
        {
        cout &lt;&lt; "Catch in A(int)\n";
        }
      }
    };
  
  int main()
    {
    try
    {
        A f;
    }
    catch (...)
    {
        cout &lt;&lt; "Catch in main()\n\n";
    }
    A g(1);
    }
  </code></pre>
  
  <p>It's output is </p>
  
  <pre><code>Constructor B() 
  Destructor ~B() 
  Catch in A()
  Catch in main()
  
  Constructor B() 
  Catch in A(int)
  Destructor ~B() 
  </code></pre>
  
  <p>In contrast to <code>A(int)</code>, constructor <code>A()</code> has the initializer list try/catch syntax. Why that makes a difference on the order of the subobject destruction? Why the exception thrown in <code>A()</code> propagates to <code>main()</code>?</p>