title: Why Xcode says that 'instance will be immediately deallocated'?
body: <p>I'm trying to find out why am I getting the following message in Xcode:</p>
  <pre><code>Instance will be immediately deallocated because property 'delegate' is 'weak'
  </code></pre>
  <p>Here's a code:</p>
  <pre class="lang-swift prettyprint-override"><code>import ARKit
       
  class OtherViewController: NSObject, ARSCNViewDelegate { }
      
  class ViewController: UIViewController, ARSCNViewDelegate {
          
      var arView = ARSCNView(frame: .zero)
      let otherVC = OtherViewController()
          
      override func viewDidLoad() {
          super.viewDidLoad()
  
          // I'M USING ONE OF THESE
          
          arView.delegate = self                // works fine
          arView.delegate = otherVC             // works fine
          arView.delegate = ViewController()    // PRINTS WARNING
      }
  }
  </code></pre>
  <p>Question:</p>
  <p>I understand that the delegate is a <code>weak</code> and optional:</p>
  <pre class="lang-swift prettyprint-override"><code>weak var delegate: ARSCNViewDelegate? { get set }
  </code></pre>
  <p>However, why <code>arView.delegate = self</code> or <code>arView.delegate = otherVC</code> works FINE but <code>arView.delegate = ViewController()</code> prints a warning?</p>