title: swift when static variable was released
body: <p>I want to know when <code>static</code> variable will be released, so i create like below:</p>
  
  <pre><code>class A {
      init() {
          print("A init")
      }
  
      deinit {
          print("A deinit")
      }
  }
  
  class B {
      static let a = A()
  
      deinit {
          print("B deinit")
      }
  
      init() {
          print("B init")
      }
  }
  
  var b: B? = B()
  B.a
  b = nil
  </code></pre>
  
  <p>When variable <code>a</code>'s <code>deinit</code> was called? If <code>b = nil</code> then <code>A</code>'s <code>deinit</code> wasn't called.</p>