title: calling one constructor from another in same class
body: <p>1) First Code</p>
  
  <pre><code>class A
  {
  public:
      int i;
      int b;
      A(int temp){
          i=temp;
          A();
          b=0;
      }
  
      A(){
          b=0;
      }
  
      void display(){
          printf("%d %d\n",i,b);//1 0
      }
  };
  
  int  main(){
      A Aobj(1);
      Aobj.display();
      return 0;
  }
  </code></pre>
  
  <p>Output: 1 0</p>
  
  <p>2) Second Code</p>
  
  <pre><code>class A
  {
  public:
      int i;
      int b;
      A(int temp) : i(temp), A(), b(0) {}//Error
      A() : b(0) {}
      void display(){
          printf("%d %d\n",b,i);
      }
  };
  
  int  main()
  {
      A Aobj(1);
      Aobj.display();
      return 0;
  }
  </code></pre>
  
  <p>I was expecting that both the codes will show same behavior and will produce an error as calling one constructor from the other in the same class is not permitted. <strong>It's not C++11.</strong></p>
  
  <p>So why does using the intializer list make a difference? 
  I compiled this codes in g++ 4.3.4 .</p>