title: didMoveToParentViewController called twice
body: <p>I made a simple test to learn more about contained view controller.<br>
  I have a view controller where I added/removed a view controller using two buttons' action:</p>
  
  <pre><code>
  - (IBAction)myInfoAddAction:(id)sender {
      profileViewController = [[ProfileViewController alloc] init];
      [self addChildViewController: profileViewController];
      UIView *__view = profileViewController.view;
      [self.view addSubview: __view];
      [profileViewController didMoveToParentViewController: self];
  }
  
  - (IBAction)myInfoRemoveAction:(id)sender {
      [profileViewController willMoveToParentViewController: nil];
      [profileViewController.view removeFromSuperview];
      [profileViewController removeFromParentViewController];
  }
  </code></pre>
  
  <p>Class <code>ProfileViewController</code> extends <code>UIViewController</code> and override <code>willMoveToParentViewController</code> and <code>didMoveToParentViewController</code> methods</p>
  
  <pre><code>
  -( void)willMoveToParentViewController:(UIViewController *)parent
  {
      [super willMoveToParentViewController: parent];
      NSLog(@"willMoveToParentViewController -> %@", self);
  }
  
  -( void) didMoveToParentViewController:(UIViewController *)parent
  {
      [super didMoveToParentViewController: parent];
      NSLog(@"didMoveToParentViewController -> %@", self);
  }
  
  -( void)viewWillAppear:(BOOL)animated
  {
      NSLog(@"viewWillAppear -> %@", self);
  }
  
  -( void)viewDidDisappear:(BOOL)animated
  {
      NSLog(@"viewDidDisappear -> %@", self);
  }
  </code></pre>
  
  <p>When I add view controller, I got the following logs:</p>
  
  <pre><code>
  willMoveToParentViewController -> &lt;ProfileViewController: 0x8c52ea0&gt;
  viewWillAppear -> &lt;ProfileViewController: 0x8c52ea0&gt;
  didMoveToParentViewController -> &lt;ProfileViewController: 0x8c52ea0&gt;
  didMoveToParentViewController -> &lt;ProfileViewController: 0x8c52ea0&gt;
  </code></pre>
  
  <p>When I remove view controller:</p>
  
  <pre><code>
  willMoveToParentViewController -> &lt;ProfileViewController: 0x8c52ea0&gt;
  didMoveToParentViewController -> &lt;ProfileViewController: 0x8c52ea0&gt;
  viewDidDisappear -> &lt;ProfileViewController: 0x8c52ea0&gt;
  didMoveToParentViewController -> &lt;ProfileViewController: 0x8c52ea0&gt;
  </code></pre>
  
  <p>I'd like to know Why <code>didMoveToParentViewController</code> is invoked twice?</p>
  
  <p>Thanks!</p>