title: How to deinit class object in swift?
body: <p>Sorry, I have a question about memory management.<br>
  I create a "user" object.<br>
  And when I end of using, I want to make it nil to lease memory. <br>
  I try it but I fail.<br>
  What's wrong with me?<br></p>
  
  <pre><code>var user:User? = User(userId)
  user?.fromJson(data["user"])
  self.users[userId] = user
  user?.updateDb()
  user = nil
  </code></pre>