title: Python: testing for None, testing for boolean value
body: <p>Is there any low-level, implementation-related difference (performance-ish) between these approaches..?</p>
  
  <pre><code># check if string is empty
  # the preferred way it seems [1]
  if string:
      print string
  else:
      print "It's empty."
  
  # versus [2]
  if string is '':
  
  # or [3]
  if string == '':
  </code></pre>
  
  <p>For example, when testing for <code>None</code>, I still find it more readable and explicit to do:</p>
  
  <pre><code>if some_var is not None:
  </code></pre>
  
  <p>..instead of..</p>
  
  <pre><code>if not some_var:
  </code></pre>
  
  <p><code>if not some_var</code>, at least for me, always reads "if some_var does not exist".</p>
  
  <p>Which is better to use, what are the proper use cases for <code>==</code>, <code>is</code> and bool-testing?</p>